var Uf=e=>{throw TypeError(e)};var kl=(e,t,n)=>t.has(e)||Uf("Cannot "+n);var A=(e,t,n)=>(kl(e,t,"read from private field"),n?n.call(e):t.get(e)),J=(e,t,n)=>t.has(e)?Uf("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),W=(e,t,n,r)=>(kl(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),Ne=(e,t,n)=>(kl(e,t,"access private method"),n);var ms=(e,t,n,r)=>({set _(o){W(e,t,o,n)},get _(){return A(e,t,r)}});function jw(e,t){for(var n=0;nr[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 i of o)if(i.type==="childList")for(const s of i.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&r(s)}).observe(document,{childList:!0,subtree:!0});function n(o){const i={};return o.integrity&&(i.integrity=o.integrity),o.referrerPolicy&&(i.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?i.credentials="include":o.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(o){if(o.ep)return;o.ep=!0;const i=n(o);fetch(o.href,i)}})();function ig(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var sg={exports:{}},Ua={},ag={exports:{}},X={};/** * @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 es=Symbol.for("react.element"),_w=Symbol.for("react.portal"),Iw=Symbol.for("react.fragment"),Fw=Symbol.for("react.strict_mode"),Vw=Symbol.for("react.profiler"),zw=Symbol.for("react.provider"),Bw=Symbol.for("react.context"),$w=Symbol.for("react.forward_ref"),Uw=Symbol.for("react.suspense"),Ww=Symbol.for("react.memo"),Hw=Symbol.for("react.lazy"),Wf=Symbol.iterator;function Kw(e){return e===null||typeof e!="object"?null:(e=Wf&&e[Wf]||e["@@iterator"],typeof e=="function"?e:null)}var lg={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},ug=Object.assign,cg={};function Fo(e,t,n){this.props=e,this.context=t,this.refs=cg,this.updater=n||lg}Fo.prototype.isReactComponent={};Fo.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")};Fo.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function dg(){}dg.prototype=Fo.prototype;function Kc(e,t,n){this.props=e,this.context=t,this.refs=cg,this.updater=n||lg}var Gc=Kc.prototype=new dg;Gc.constructor=Kc;ug(Gc,Fo.prototype);Gc.isPureReactComponent=!0;var Hf=Array.isArray,fg=Object.prototype.hasOwnProperty,Qc={current:null},hg={key:!0,ref:!0,__self:!0,__source:!0};function pg(e,t,n){var r,o={},i=null,s=null;if(t!=null)for(r in t.ref!==void 0&&(s=t.ref),t.key!==void 0&&(i=""+t.key),t)fg.call(t,r)&&!hg.hasOwnProperty(r)&&(o[r]=t[r]);var a=arguments.length-2;if(a===1)o.children=n;else if(1>>1,z=k[H];if(0>>1;Ho(xe,j))Meo(ee,xe)?(k[H]=ee,k[Me]=j,H=Me):(k[H]=xe,k[q]=j,H=q);else if(Meo(ee,j))k[H]=ee,k[Me]=j,H=Me;else break e}}return R}function o(k,R){var j=k.sortIndex-R.sortIndex;return j!==0?j:k.id-R.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var s=Date,a=s.now();e.unstable_now=function(){return s.now()-a}}var l=[],u=[],c=1,d=null,f=3,h=!1,v=!1,g=!1,x=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,p=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function y(k){for(var R=n(u);R!==null;){if(R.callback===null)r(u);else if(R.startTime<=k)r(u),R.sortIndex=R.expirationTime,t(l,R);else break;R=n(u)}}function S(k){if(g=!1,y(k),!v)if(n(l)!==null)v=!0,$(C);else{var R=n(u);R!==null&&F(S,R.startTime-k)}}function C(k,R){v=!1,g&&(g=!1,m(b),b=-1),h=!0;var j=f;try{for(y(R),d=n(l);d!==null&&(!(d.expirationTime>R)||k&&!V());){var H=d.callback;if(typeof H=="function"){d.callback=null,f=d.priorityLevel;var z=H(d.expirationTime<=R);R=e.unstable_now(),typeof z=="function"?d.callback=z:d===n(l)&&r(l),y(R)}else r(l);d=n(l)}if(d!==null)var Y=!0;else{var q=n(u);q!==null&&F(S,q.startTime-R),Y=!1}return Y}finally{d=null,f=j,h=!1}}var P=!1,T=null,b=-1,D=5,N=-1;function V(){return!(e.unstable_now()-Nk||125H?(k.sortIndex=j,t(u,k),n(l)===null&&k===n(u)&&(g?(m(b),b=-1):g=!0,F(S,j-H))):(k.sortIndex=z,t(l,k),v||h||(v=!0,$(C))),k},e.unstable_shouldYield=V,e.unstable_wrapCallback=function(k){var R=f;return function(){var j=f;f=R;try{return k.apply(this,arguments)}finally{f=j}}}})(wg);xg.exports=wg;var r1=xg.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 o1=w,st=r1;function M(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),wu=Object.prototype.hasOwnProperty,i1=/^[: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]*$/,Gf={},Qf={};function s1(e){return wu.call(Qf,e)?!0:wu.call(Gf,e)?!1:i1.test(e)?Qf[e]=!0:(Gf[e]=!0,!1)}function a1(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 l1(e,t,n,r){if(t===null||typeof t>"u"||a1(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,i,s){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=i,this.removeEmptyString=s}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 Xc=/[\-:]([a-z])/g;function qc(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(Xc,qc);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(Xc,qc);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(Xc,qc);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 Zc(e,t,n,r){var o=Re.hasOwnProperty(t)?Re[t]:null;(o!==null?o.type!==0:r||!(2a||o[s]!==i[a]){var l=` `+o[s].replace(" at new "," at ");return e.displayName&&l.includes("")&&(l=l.replace("",e.displayName)),l}while(1<=s&&0<=a);break}}}finally{Ml=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?ii(e):""}function u1(e){switch(e.tag){case 5:return ii(e.type);case 16:return ii("Lazy");case 13:return ii("Suspense");case 19:return ii("SuspenseList");case 0:case 2:case 15:return e=Nl(e.type,!1),e;case 11:return e=Nl(e.type.render,!1),e;case 1:return e=Nl(e.type,!0),e;default:return""}}function Pu(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 Kr:return"Fragment";case Hr:return"Portal";case Su:return"Profiler";case Jc:return"StrictMode";case Eu:return"Suspense";case Cu:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Cg:return(e.displayName||"Context")+".Consumer";case Eg:return(e._context.displayName||"Context")+".Provider";case ed:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case td:return t=e.displayName||null,t!==null?t:Pu(e.type)||"Memo";case Rn:t=e._payload,e=e._init;try{return Pu(e(t))}catch{}}return null}function c1(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 Pu(t);case 8:return t===Jc?"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 Yn(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Tg(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function d1(e){var t=Tg(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,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(s){r=""+s,i.call(this,s)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(s){r=""+s},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function vs(e){e._valueTracker||(e._valueTracker=d1(e))}function bg(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Tg(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function ia(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 Tu(e,t){var n=t.checked;return he({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Xf(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Yn(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 kg(e,t){t=t.checked,t!=null&&Zc(e,"checked",t,!1)}function bu(e,t){kg(e,t);var n=Yn(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")?ku(e,t.type,n):t.hasOwnProperty("defaultValue")&&ku(e,t.type,Yn(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function qf(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 ku(e,t,n){(t!=="number"||ia(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var si=Array.isArray;function lo(e,t,n,r){if(e=e.options,t){t={};for(var o=0;o"+t.valueOf().toString()+"",t=xs.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function ki(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var fi={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},f1=["Webkit","ms","Moz","O"];Object.keys(fi).forEach(function(e){f1.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),fi[t]=fi[e]})});function Ng(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||fi.hasOwnProperty(e)&&fi[e]?(""+t).trim():t+"px"}function Dg(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,o=Ng(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,o):e[n]=o}}var h1=he({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 Mu(e,t){if(t){if(h1[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(M(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(M(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(M(61))}if(t.style!=null&&typeof t.style!="object")throw Error(M(62))}}function Nu(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 Du=null;function nd(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Ou=null,uo=null,co=null;function eh(e){if(e=rs(e)){if(typeof Ou!="function")throw Error(M(280));var t=e.stateNode;t&&(t=Qa(t),Ou(e.stateNode,e.type,t))}}function Og(e){uo?co?co.push(e):co=[e]:uo=e}function Lg(){if(uo){var e=uo,t=co;if(co=uo=null,eh(e),t)for(e=0;e>>=0,e===0?32:31-(P1(e)/T1|0)|0}var ws=64,Ss=4194304;function ai(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 ua(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,o=e.suspendedLanes,i=e.pingedLanes,s=n&268435455;if(s!==0){var a=s&~o;a!==0?r=ai(a):(i&=s,i!==0&&(r=ai(i)))}else s=n&~o,s!==0?r=ai(s):i!==0&&(r=ai(i));if(r===0)return 0;if(t!==0&&t!==r&&!(t&o)&&(o=r&-r,i=t&-t,o>=i||o===16&&(i&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function ts(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Dt(t),e[t]=n}function R1(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=pi),uh=" ",ch=!1;function ey(e,t){switch(e){case"keyup":return rS.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function ty(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Gr=!1;function iS(e,t){switch(e){case"compositionend":return ty(t);case"keypress":return t.which!==32?null:(ch=!0,uh);case"textInput":return e=t.data,e===uh&&ch?null:e;default:return null}}function sS(e,t){if(Gr)return e==="compositionend"||!cd&&ey(e,t)?(e=Zg(),Ws=ad=Fn=null,Gr=!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)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=ph(n)}}function iy(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?iy(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function sy(){for(var e=window,t=ia();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=ia(e.document)}return t}function dd(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 mS(e){var t=sy(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&iy(n.ownerDocument.documentElement,n)){if(r!==null&&dd(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,i=Math.min(r.start,o);r=r.end===void 0?i:Math.min(r.end,o),!e.extend&&i>r&&(o=r,r=i,i=o),o=mh(n,i);var s=mh(n,r);o&&s&&(e.rangeCount!==1||e.anchorNode!==o.node||e.anchorOffset!==o.offset||e.focusNode!==s.node||e.focusOffset!==s.offset)&&(t=t.createRange(),t.setStart(o.node,o.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(s.node,s.offset)):(t.setEnd(s.node,s.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=document.documentMode,Qr=null,Vu=null,gi=null,zu=!1;function gh(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;zu||Qr==null||Qr!==ia(r)||(r=Qr,"selectionStart"in r&&dd(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}),gi&&Oi(gi,r)||(gi=r,r=fa(Vu,"onSelect"),0qr||(e.current=Ku[qr],Ku[qr]=null,qr--)}function re(e,t){qr++,Ku[qr]=e.current,e.current=t}var Xn={},Fe=or(Xn),Qe=or(!1),Ar=Xn;function ko(e,t){var n=e.type.contextTypes;if(!n)return Xn;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o={},i;for(i in n)o[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function Ye(e){return e=e.childContextTypes,e!=null}function pa(){se(Qe),se(Fe)}function Ch(e,t,n){if(Fe.current!==Xn)throw Error(M(168));re(Fe,t),re(Qe,n)}function my(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(M(108,c1(e)||"Unknown",o));return he({},n,r)}function ma(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Xn,Ar=Fe.current,re(Fe,e),re(Qe,Qe.current),!0}function Ph(e,t,n){var r=e.stateNode;if(!r)throw Error(M(169));n?(e=my(e,t,Ar),r.__reactInternalMemoizedMergedChildContext=e,se(Qe),se(Fe),re(Fe,e)):se(Qe),re(Qe,n)}var nn=null,Ya=!1,Hl=!1;function gy(e){nn===null?nn=[e]:nn.push(e)}function kS(e){Ya=!0,gy(e)}function ir(){if(!Hl&&nn!==null){Hl=!0;var e=0,t=te;try{var n=nn;for(te=1;e>=s,o-=s,on=1<<32-Dt(t)+o|n<b?(D=T,T=null):D=T.sibling;var N=f(m,T,y[b],S);if(N===null){T===null&&(T=D);break}e&&T&&N.alternate===null&&t(m,T),p=i(N,p,b),P===null?C=N:P.sibling=N,P=N,T=D}if(b===y.length)return n(m,T),ue&&dr(m,b),C;if(T===null){for(;bb?(D=T,T=null):D=T.sibling;var V=f(m,T,N.value,S);if(V===null){T===null&&(T=D);break}e&&T&&V.alternate===null&&t(m,T),p=i(V,p,b),P===null?C=V:P.sibling=V,P=V,T=D}if(N.done)return n(m,T),ue&&dr(m,b),C;if(T===null){for(;!N.done;b++,N=y.next())N=d(m,N.value,S),N!==null&&(p=i(N,p,b),P===null?C=N:P.sibling=N,P=N);return ue&&dr(m,b),C}for(T=r(m,T);!N.done;b++,N=y.next())N=h(T,m,b,N.value,S),N!==null&&(e&&N.alternate!==null&&T.delete(N.key===null?b:N.key),p=i(N,p,b),P===null?C=N:P.sibling=N,P=N);return e&&T.forEach(function(_){return t(m,_)}),ue&&dr(m,b),C}function x(m,p,y,S){if(typeof y=="object"&&y!==null&&y.type===Kr&&y.key===null&&(y=y.props.children),typeof y=="object"&&y!==null){switch(y.$$typeof){case ys:e:{for(var C=y.key,P=p;P!==null;){if(P.key===C){if(C=y.type,C===Kr){if(P.tag===7){n(m,P.sibling),p=o(P,y.props.children),p.return=m,m=p;break e}}else if(P.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===Rn&&kh(C)===P.type){n(m,P.sibling),p=o(P,y.props),p.ref=Jo(m,P,y),p.return=m,m=p;break e}n(m,P);break}else t(m,P);P=P.sibling}y.type===Kr?(p=br(y.props.children,m.mode,S,y.key),p.return=m,m=p):(S=Zs(y.type,y.key,y.props,null,m.mode,S),S.ref=Jo(m,p,y),S.return=m,m=S)}return s(m);case Hr:e:{for(P=y.key;p!==null;){if(p.key===P)if(p.tag===4&&p.stateNode.containerInfo===y.containerInfo&&p.stateNode.implementation===y.implementation){n(m,p.sibling),p=o(p,y.children||[]),p.return=m,m=p;break e}else{n(m,p);break}else t(m,p);p=p.sibling}p=Jl(y,m.mode,S),p.return=m,m=p}return s(m);case Rn:return P=y._init,x(m,p,P(y._payload),S)}if(si(y))return v(m,p,y,S);if(Qo(y))return g(m,p,y,S);As(m,y)}return typeof y=="string"&&y!==""||typeof y=="number"?(y=""+y,p!==null&&p.tag===6?(n(m,p.sibling),p=o(p,y),p.return=m,m=p):(n(m,p),p=Zl(y,m.mode,S),p.return=m,m=p),s(m)):n(m,p)}return x}var Ro=wy(!0),Sy=wy(!1),va=or(null),xa=null,eo=null,md=null;function gd(){md=eo=xa=null}function yd(e){var t=va.current;se(va),e._currentValue=t}function Yu(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 ho(e,t){xa=e,md=eo=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Ge=!0),e.firstContext=null)}function vt(e){var t=e._currentValue;if(md!==e)if(e={context:e,memoizedValue:t,next:null},eo===null){if(xa===null)throw Error(M(308));eo=e,xa.dependencies={lanes:0,firstContext:e}}else eo=eo.next=e;return t}var gr=null;function vd(e){gr===null?gr=[e]:gr.push(e)}function Ey(e,t,n,r){var o=t.interleaved;return o===null?(n.next=n,vd(t)):(n.next=o.next,o.next=n),t.interleaved=n,fn(e,r)}function fn(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 Mn=!1;function xd(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Cy(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 an(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Hn(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,fn(e,n)}return o=r.interleaved,o===null?(t.next=t,vd(r)):(t.next=o.next,o.next=t),r.interleaved=t,fn(e,n)}function Ks(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,od(e,n)}}function Ah(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var o=null,i=null;if(n=n.firstBaseUpdate,n!==null){do{var s={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};i===null?o=i=s:i=i.next=s,n=n.next}while(n!==null);i===null?o=i=t:i=i.next=t}else o=i=t;n={baseState:r.baseState,firstBaseUpdate:o,lastBaseUpdate:i,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 wa(e,t,n,r){var o=e.updateQueue;Mn=!1;var i=o.firstBaseUpdate,s=o.lastBaseUpdate,a=o.shared.pending;if(a!==null){o.shared.pending=null;var l=a,u=l.next;l.next=null,s===null?i=u:s.next=u,s=l;var c=e.alternate;c!==null&&(c=c.updateQueue,a=c.lastBaseUpdate,a!==s&&(a===null?c.firstBaseUpdate=u:a.next=u,c.lastBaseUpdate=l))}if(i!==null){var d=o.baseState;s=0,c=u=l=null,a=i;do{var f=a.lane,h=a.eventTime;if((r&f)===f){c!==null&&(c=c.next={eventTime:h,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var v=e,g=a;switch(f=t,h=n,g.tag){case 1:if(v=g.payload,typeof v=="function"){d=v.call(h,d,f);break e}d=v;break e;case 3:v.flags=v.flags&-65537|128;case 0:if(v=g.payload,f=typeof v=="function"?v.call(h,d,f):v,f==null)break e;d=he({},d,f);break e;case 2:Mn=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,f=o.effects,f===null?o.effects=[a]:f.push(a))}else h={eventTime:h,lane:f,tag:a.tag,payload:a.payload,callback:a.callback,next:null},c===null?(u=c=h,l=d):c=c.next=h,s|=f;if(a=a.next,a===null){if(a=o.shared.pending,a===null)break;f=a,a=f.next,f.next=null,o.lastBaseUpdate=f,o.shared.pending=null}}while(!0);if(c===null&&(l=d),o.baseState=l,o.firstBaseUpdate=u,o.lastBaseUpdate=c,t=o.shared.interleaved,t!==null){o=t;do s|=o.lane,o=o.next;while(o!==t)}else i===null&&(o.shared.lanes=0);Nr|=s,e.lanes=s,e.memoizedState=d}}function Rh(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=Gl.transition;Gl.transition={};try{e(!1),t()}finally{te=n,Gl.transition=r}}function zy(){return xt().memoizedState}function NS(e,t,n){var r=Gn(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},By(e))$y(t,n);else if(n=Ey(e,t,n,r),n!==null){var o=$e();Ot(n,e,r,o),Uy(n,t,r)}}function DS(e,t,n){var r=Gn(e),o={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(By(e))$y(t,o);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var s=t.lastRenderedState,a=i(s,n);if(o.hasEagerState=!0,o.eagerState=a,Lt(a,s)){var l=t.interleaved;l===null?(o.next=o,vd(t)):(o.next=l.next,l.next=o),t.interleaved=o;return}}catch{}finally{}n=Ey(e,t,o,r),n!==null&&(o=$e(),Ot(n,e,r,o),Uy(n,t,r))}}function By(e){var t=e.alternate;return e===fe||t!==null&&t===fe}function $y(e,t){yi=Ea=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Uy(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,od(e,n)}}var Ca={readContext:vt,useCallback:De,useContext:De,useEffect:De,useImperativeHandle:De,useInsertionEffect:De,useLayoutEffect:De,useMemo:De,useReducer:De,useRef:De,useState:De,useDebugValue:De,useDeferredValue:De,useTransition:De,useMutableSource:De,useSyncExternalStore:De,useId:De,unstable_isNewReconciler:!1},OS={readContext:vt,useCallback:function(e,t){return Vt().memoizedState=[e,t===void 0?null:t],e},useContext:vt,useEffect:Nh,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Qs(4194308,4,jy.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Qs(4194308,4,e,t)},useInsertionEffect:function(e,t){return Qs(4,2,e,t)},useMemo:function(e,t){var n=Vt();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Vt();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=NS.bind(null,fe,e),[r.memoizedState,e]},useRef:function(e){var t=Vt();return e={current:e},t.memoizedState=e},useState:Mh,useDebugValue:kd,useDeferredValue:function(e){return Vt().memoizedState=e},useTransition:function(){var e=Mh(!1),t=e[0];return e=MS.bind(null,e[1]),Vt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=fe,o=Vt();if(ue){if(n===void 0)throw Error(M(407));n=n()}else{if(n=t(),Te===null)throw Error(M(349));Mr&30||ky(r,t,n)}o.memoizedState=n;var i={value:n,getSnapshot:t};return o.queue=i,Nh(Ry.bind(null,r,i,e),[e]),r.flags|=2048,Bi(9,Ay.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=Vt(),t=Te.identifierPrefix;if(ue){var n=sn,r=on;n=(r&~(1<<32-Dt(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Vi++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=s.createElement(n,{is:r.is}):(e=s.createElement(n),n==="select"&&(s=e,r.multiple?s.multiple=!0:r.size&&(s.size=r.size))):e=s.createElementNS(e,n),e[Ut]=t,e[_i]=r,Jy(e,t,!1,!1),t.stateNode=e;e:{switch(s=Nu(n,r),n){case"dialog":ie("cancel",e),ie("close",e),o=r;break;case"iframe":case"object":case"embed":ie("load",e),o=r;break;case"video":case"audio":for(o=0;oDo&&(t.flags|=128,r=!0,ei(i,!1),t.lanes=4194304)}else{if(!r)if(e=Sa(s),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),ei(i,!0),i.tail===null&&i.tailMode==="hidden"&&!s.alternate&&!ue)return Oe(t),null}else 2*ve()-i.renderingStartTime>Do&&n!==1073741824&&(t.flags|=128,r=!0,ei(i,!1),t.lanes=4194304);i.isBackwards?(s.sibling=t.child,t.child=s):(n=i.last,n!==null?n.sibling=s:t.child=s,i.last=s)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=ve(),t.sibling=null,n=ce.current,re(ce,r?n&1|2:n&1),t):(Oe(t),null);case 22:case 23:return Od(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Je&1073741824&&(Oe(t),t.subtreeFlags&6&&(t.flags|=8192)):Oe(t),null;case 24:return null;case 25:return null}throw Error(M(156,t.tag))}function BS(e,t){switch(hd(t),t.tag){case 1:return Ye(t.type)&&pa(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Mo(),se(Qe),se(Fe),Ed(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Sd(t),null;case 13:if(se(ce),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(M(340));Ao()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return se(ce),null;case 4:return Mo(),null;case 10:return yd(t.type._context),null;case 22:case 23:return Od(),null;case 24:return null;default:return null}}var Ms=!1,_e=!1,$S=typeof WeakSet=="function"?WeakSet:Set,I=null;function to(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 oc(e,t,n){try{n()}catch(r){ge(e,t,r)}}var $h=!1;function US(e,t){if(Bu=ca,e=sy(),dd(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,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var s=0,a=-1,l=-1,u=0,c=0,d=e,f=null;t:for(;;){for(var h;d!==n||o!==0&&d.nodeType!==3||(a=s+o),d!==i||r!==0&&d.nodeType!==3||(l=s+r),d.nodeType===3&&(s+=d.nodeValue.length),(h=d.firstChild)!==null;)f=d,d=h;for(;;){if(d===e)break t;if(f===n&&++u===o&&(a=s),f===i&&++c===r&&(l=s),(h=d.nextSibling)!==null)break;d=f,f=d.parentNode}d=h}n=a===-1||l===-1?null:{start:a,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for($u={focusedElem:e,selectionRange:n},ca=!1,I=t;I!==null;)if(t=I,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,I=e;else for(;I!==null;){t=I;try{var v=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(v!==null){var g=v.memoizedProps,x=v.memoizedState,m=t.stateNode,p=m.getSnapshotBeforeUpdate(t.elementType===t.type?g:bt(t.type,g),x);m.__reactInternalSnapshotBeforeUpdate=p}break;case 3:var y=t.stateNode.containerInfo;y.nodeType===1?y.textContent="":y.nodeType===9&&y.documentElement&&y.removeChild(y.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(M(163))}}catch(S){ge(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,I=e;break}I=t.return}return v=$h,$h=!1,v}function vi(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 i=o.destroy;o.destroy=void 0,i!==void 0&&oc(t,n,i)}o=o.next}while(o!==r)}}function Za(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 ic(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 nv(e){var t=e.alternate;t!==null&&(e.alternate=null,nv(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Ut],delete t[_i],delete t[Hu],delete t[TS],delete t[bS])),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 rv(e){return e.tag===5||e.tag===3||e.tag===4}function Uh(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||rv(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 sc(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=ha));else if(r!==4&&(e=e.child,e!==null))for(sc(e,t,n),e=e.sibling;e!==null;)sc(e,t,n),e=e.sibling}function ac(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(ac(e,t,n),e=e.sibling;e!==null;)ac(e,t,n),e=e.sibling}var be=null,Mt=!1;function Pn(e,t,n){for(n=n.child;n!==null;)ov(e,t,n),n=n.sibling}function ov(e,t,n){if(Ht&&typeof Ht.onCommitFiberUnmount=="function")try{Ht.onCommitFiberUnmount(Wa,n)}catch{}switch(n.tag){case 5:_e||to(n,t);case 6:var r=be,o=Mt;be=null,Pn(e,t,n),be=r,Mt=o,be!==null&&(Mt?(e=be,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):be.removeChild(n.stateNode));break;case 18:be!==null&&(Mt?(e=be,n=n.stateNode,e.nodeType===8?Wl(e.parentNode,n):e.nodeType===1&&Wl(e,n),Ni(e)):Wl(be,n.stateNode));break;case 4:r=be,o=Mt,be=n.stateNode.containerInfo,Mt=!0,Pn(e,t,n),be=r,Mt=o;break;case 0:case 11:case 14:case 15:if(!_e&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){o=r=r.next;do{var i=o,s=i.destroy;i=i.tag,s!==void 0&&(i&2||i&4)&&oc(n,t,s),o=o.next}while(o!==r)}Pn(e,t,n);break;case 1:if(!_e&&(to(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)}Pn(e,t,n);break;case 21:Pn(e,t,n);break;case 22:n.mode&1?(_e=(r=_e)||n.memoizedState!==null,Pn(e,t,n),_e=r):Pn(e,t,n);break;default:Pn(e,t,n)}}function Wh(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new $S),t.forEach(function(r){var o=ZS.bind(null,e,r);n.has(r)||(n.add(r),r.then(o,o))})}}function Ct(e,t){var n=t.deletions;if(n!==null)for(var r=0;ro&&(o=s),r&=~i}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*HS(r/1960))-r,10e?16:e,Vn===null)var r=!1;else{if(e=Vn,Vn=null,ba=0,Z&6)throw Error(M(331));var o=Z;for(Z|=4,I=e.current;I!==null;){var i=I,s=i.child;if(I.flags&16){var a=i.deletions;if(a!==null){for(var l=0;lve()-Nd?Tr(e,0):Md|=n),Xe(e,t)}function fv(e,t){t===0&&(e.mode&1?(t=Ss,Ss<<=1,!(Ss&130023424)&&(Ss=4194304)):t=1);var n=$e();e=fn(e,t),e!==null&&(ts(e,t,n),Xe(e,n))}function qS(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),fv(e,n)}function ZS(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(M(314))}r!==null&&r.delete(t),fv(e,n)}var hv;hv=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Qe.current)Ge=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Ge=!1,VS(e,t,n);Ge=!!(e.flags&131072)}else Ge=!1,ue&&t.flags&1048576&&yy(t,ya,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Ys(e,t),e=t.pendingProps;var o=ko(t,Fe.current);ho(t,n),o=Pd(null,t,r,e,o,n);var i=Td();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,Ye(r)?(i=!0,ma(t)):i=!1,t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,xd(t),o.updater=qa,t.stateNode=o,o._reactInternals=t,qu(t,r,e,n),t=ec(null,t,r,!0,i,n)):(t.tag=0,ue&&i&&fd(t),ze(null,t,o,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Ys(e,t),e=t.pendingProps,o=r._init,r=o(r._payload),t.type=r,o=t.tag=eE(r),e=bt(r,e),o){case 0:t=Ju(null,t,r,e,n);break e;case 1:t=Vh(null,t,r,e,n);break e;case 11:t=Ih(null,t,r,e,n);break e;case 14:t=Fh(null,t,r,bt(r.type,e),n);break e}throw Error(M(306,r,""))}return t;case 0:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:bt(r,o),Ju(e,t,r,o,n);case 1:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:bt(r,o),Vh(e,t,r,o,n);case 3:e:{if(Xy(t),e===null)throw Error(M(387));r=t.pendingProps,i=t.memoizedState,o=i.element,Cy(e,t),wa(t,r,null,n);var s=t.memoizedState;if(r=s.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){o=No(Error(M(423)),t),t=zh(e,t,r,n,o);break e}else if(r!==o){o=No(Error(M(424)),t),t=zh(e,t,r,n,o);break e}else for(tt=Wn(t.stateNode.containerInfo.firstChild),nt=t,ue=!0,Nt=null,n=Sy(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Ao(),r===o){t=hn(e,t,n);break e}ze(e,t,r,n)}t=t.child}return t;case 5:return Py(t),e===null&&Qu(t),r=t.type,o=t.pendingProps,i=e!==null?e.memoizedProps:null,s=o.children,Uu(r,o)?s=null:i!==null&&Uu(r,i)&&(t.flags|=32),Yy(e,t),ze(e,t,s,n),t.child;case 6:return e===null&&Qu(t),null;case 13:return qy(e,t,n);case 4:return wd(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Ro(t,null,r,n):ze(e,t,r,n),t.child;case 11:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:bt(r,o),Ih(e,t,r,o,n);case 7:return ze(e,t,t.pendingProps,n),t.child;case 8:return ze(e,t,t.pendingProps.children,n),t.child;case 12:return ze(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,o=t.pendingProps,i=t.memoizedProps,s=o.value,re(va,r._currentValue),r._currentValue=s,i!==null)if(Lt(i.value,s)){if(i.children===o.children&&!Qe.current){t=hn(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var a=i.dependencies;if(a!==null){s=i.child;for(var l=a.firstContext;l!==null;){if(l.context===r){if(i.tag===1){l=an(-1,n&-n),l.tag=2;var u=i.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}i.lanes|=n,l=i.alternate,l!==null&&(l.lanes|=n),Yu(i.return,n,t),a.lanes|=n;break}l=l.next}}else if(i.tag===10)s=i.type===t.type?null:i.child;else if(i.tag===18){if(s=i.return,s===null)throw Error(M(341));s.lanes|=n,a=s.alternate,a!==null&&(a.lanes|=n),Yu(s,n,t),s=i.sibling}else s=i.child;if(s!==null)s.return=i;else for(s=i;s!==null;){if(s===t){s=null;break}if(i=s.sibling,i!==null){i.return=s.return,s=i;break}s=s.return}i=s}ze(e,t,o.children,n),t=t.child}return t;case 9:return o=t.type,r=t.pendingProps.children,ho(t,n),o=vt(o),r=r(o),t.flags|=1,ze(e,t,r,n),t.child;case 14:return r=t.type,o=bt(r,t.pendingProps),o=bt(r.type,o),Fh(e,t,r,o,n);case 15:return Gy(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:bt(r,o),Ys(e,t),t.tag=1,Ye(r)?(e=!0,ma(t)):e=!1,ho(t,n),Wy(t,r,o),qu(t,r,o,n),ec(null,t,r,!0,e,n);case 19:return Zy(e,t,n);case 22:return Qy(e,t,n)}throw Error(M(156,t.tag))};function pv(e,t){return Bg(e,t)}function JS(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 gt(e,t,n,r){return new JS(e,t,n,r)}function jd(e){return e=e.prototype,!(!e||!e.isReactComponent)}function eE(e){if(typeof e=="function")return jd(e)?1:0;if(e!=null){if(e=e.$$typeof,e===ed)return 11;if(e===td)return 14}return 2}function Qn(e,t){var n=e.alternate;return n===null?(n=gt(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 Zs(e,t,n,r,o,i){var s=2;if(r=e,typeof e=="function")jd(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case Kr:return br(n.children,o,i,t);case Jc:s=8,o|=8;break;case Su:return e=gt(12,n,t,o|2),e.elementType=Su,e.lanes=i,e;case Eu:return e=gt(13,n,t,o),e.elementType=Eu,e.lanes=i,e;case Cu:return e=gt(19,n,t,o),e.elementType=Cu,e.lanes=i,e;case Pg:return el(n,o,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Eg:s=10;break e;case Cg:s=9;break e;case ed:s=11;break e;case td:s=14;break e;case Rn:s=16,r=null;break e}throw Error(M(130,e==null?e:typeof e,""))}return t=gt(s,n,t,o),t.elementType=e,t.type=r,t.lanes=i,t}function br(e,t,n,r){return e=gt(7,e,r,t),e.lanes=n,e}function el(e,t,n,r){return e=gt(22,e,r,t),e.elementType=Pg,e.lanes=n,e.stateNode={isHidden:!1},e}function Zl(e,t,n){return e=gt(6,e,null,t),e.lanes=n,e}function Jl(e,t,n){return t=gt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function tE(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=Ol(0),this.expirationTimes=Ol(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ol(0),this.identifierPrefix=r,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function _d(e,t,n,r,o,i,s,a,l){return e=new tE(e,t,n,a,l),t===1?(t=1,i===!0&&(t|=8)):t=0,i=gt(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},xd(i),e}function nE(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(vv)}catch(e){console.error(e)}}vv(),vg.exports=lt;var is=vg.exports;const xv=ig(is);var wv,Zh=is;wv=Zh.createRoot,Zh.hydrateRoot;var il=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(){}},sl=typeof window>"u"||"Deno"in globalThis;function kt(){}function aE(e,t){return typeof e=="function"?e(t):e}function lE(e){return typeof e=="number"&&e>=0&&e!==1/0}function uE(e,t){return Math.max(e+(t||0)-Date.now(),0)}function fc(e,t){return typeof e=="function"?e(t):e}function cE(e,t){return typeof e=="function"?e(t):e}function Jh(e,t){const{type:n="all",exact:r,fetchStatus:o,predicate:i,queryKey:s,stale:a}=e;if(s){if(r){if(t.queryHash!==zd(s,t.options))return!1}else if(!Wi(t.queryKey,s))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||i&&!i(t))}function ep(e,t){const{exact:n,status:r,predicate:o,mutationKey:i}=e;if(i){if(!t.options.mutationKey)return!1;if(n){if(Ui(t.options.mutationKey)!==Ui(i))return!1}else if(!Wi(t.options.mutationKey,i))return!1}return!(r&&t.state.status!==r||o&&!o(t))}function zd(e,t){return((t==null?void 0:t.queryKeyHashFn)||Ui)(e)}function Ui(e){return JSON.stringify(e,(t,n)=>hc(n)?Object.keys(n).sort().reduce((r,o)=>(r[o]=n[o],r),{}):n)}function Wi(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(n=>Wi(e[n],t[n])):!1}function Sv(e,t){if(e===t)return e;const n=tp(e)&&tp(t);if(n||hc(e)&&hc(t)){const r=n?e:Object.keys(e),o=r.length,i=n?t:Object.keys(t),s=i.length,a=n?[]:{},l=new Set(r);let u=0;for(let c=0;c{setTimeout(t,e)})}function fE(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?Sv(e,t):t}function hE(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function pE(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var Bd=Symbol();function Ev(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===Bd?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var xr,On,vo,qm,mE=(qm=class extends il{constructor(){super();J(this,xr);J(this,On);J(this,vo);W(this,vo,t=>{if(!sl&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){A(this,On)||this.setEventListener(A(this,vo))}onUnsubscribe(){var t;this.hasListeners()||((t=A(this,On))==null||t.call(this),W(this,On,void 0))}setEventListener(t){var n;W(this,vo,t),(n=A(this,On))==null||n.call(this),W(this,On,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){A(this,xr)!==t&&(W(this,xr,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof A(this,xr)=="boolean"?A(this,xr):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},xr=new WeakMap,On=new WeakMap,vo=new WeakMap,qm),Cv=new mE,xo,Ln,wo,Zm,gE=(Zm=class extends il{constructor(){super();J(this,xo,!0);J(this,Ln);J(this,wo);W(this,wo,t=>{if(!sl&&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(){A(this,Ln)||this.setEventListener(A(this,wo))}onUnsubscribe(){var t;this.hasListeners()||((t=A(this,Ln))==null||t.call(this),W(this,Ln,void 0))}setEventListener(t){var n;W(this,wo,t),(n=A(this,Ln))==null||n.call(this),W(this,Ln,t(this.setOnline.bind(this)))}setOnline(t){A(this,xo)!==t&&(W(this,xo,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return A(this,xo)}},xo=new WeakMap,Ln=new WeakMap,wo=new WeakMap,Zm),Ra=new gE;function yE(){let e,t;const n=new Promise((o,i)=>{e=o,t=i});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 vE(e){return Math.min(1e3*2**e,3e4)}function Pv(e){return(e??"online")==="online"?Ra.isOnline():!0}var Tv=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function eu(e){return e instanceof Tv}function bv(e){let t=!1,n=0,r=!1,o;const i=yE(),s=g=>{var x;r||(f(new Tv(g)),(x=e.abort)==null||x.call(e))},a=()=>{t=!0},l=()=>{t=!1},u=()=>Cv.isFocused()&&(e.networkMode==="always"||Ra.isOnline())&&e.canRun(),c=()=>Pv(e.networkMode)&&e.canRun(),d=g=>{var x;r||(r=!0,(x=e.onSuccess)==null||x.call(e,g),o==null||o(),i.resolve(g))},f=g=>{var x;r||(r=!0,(x=e.onError)==null||x.call(e,g),o==null||o(),i.reject(g))},h=()=>new Promise(g=>{var x;o=m=>{(r||u())&&g(m)},(x=e.onPause)==null||x.call(e)}).then(()=>{var g;o=void 0,r||(g=e.onContinue)==null||g.call(e)}),v=()=>{if(r)return;let g;const x=n===0?e.initialPromise:void 0;try{g=x??e.fn()}catch(m){g=Promise.reject(m)}Promise.resolve(g).then(d).catch(m=>{var P;if(r)return;const p=e.retry??(sl?0:3),y=e.retryDelay??vE,S=typeof y=="function"?y(n,m):y,C=p===!0||typeof p=="number"&&nu()?void 0:h()).then(()=>{t?f(m):v()})})};return{promise:i,cancel:s,continue:()=>(o==null||o(),i),cancelRetry:a,continueRetry:l,canStart:c,start:()=>(c()?v():h().then(v),i)}}var xE=e=>setTimeout(e,0);function wE(){let e=[],t=0,n=a=>{a()},r=a=>{a()},o=xE;const i=a=>{t?e.push(a):o(()=>{n(a)})},s=()=>{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||s()}return l},batchCalls:a=>(...l)=>{i(()=>{a(...l)})},schedule:i,setNotifyFunction:a=>{n=a},setBatchNotifyFunction:a=>{r=a},setScheduler:a=>{o=a}}}var Be=wE(),wr,Jm,kv=(Jm=class{constructor(){J(this,wr)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),lE(this.gcTime)&&W(this,wr,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(sl?1/0:5*60*1e3))}clearGcTimeout(){A(this,wr)&&(clearTimeout(A(this,wr)),W(this,wr,void 0))}},wr=new WeakMap,Jm),So,Sr,ht,Er,Le,Zi,Cr,At,en,eg,SE=(eg=class extends kv{constructor(t){super();J(this,At);J(this,So);J(this,Sr);J(this,ht);J(this,Er);J(this,Le);J(this,Zi);J(this,Cr);W(this,Cr,!1),W(this,Zi,t.defaultOptions),this.setOptions(t.options),this.observers=[],W(this,Er,t.client),W(this,ht,A(this,Er).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,W(this,So,CE(this.options)),this.state=t.state??A(this,So),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=A(this,Le))==null?void 0:t.promise}setOptions(t){this.options={...A(this,Zi),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&A(this,ht).remove(this)}setData(t,n){const r=fE(this.state.data,t,this.options);return Ne(this,At,en).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){Ne(this,At,en).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,o;const n=(r=A(this,Le))==null?void 0:r.promise;return(o=A(this,Le))==null||o.cancel(t),n?n.then(kt).catch(kt):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(A(this,So))}isActive(){return this.observers.some(t=>cE(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Bd||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>fc(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:!uE(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=A(this,Le))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=A(this,Le))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),A(this,ht).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(A(this,Le)&&(A(this,Cr)?A(this,Le).cancel({revert:!0}):A(this,Le).cancelRetry()),this.scheduleGc()),A(this,ht).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Ne(this,At,en).call(this,{type:"invalidate"})}fetch(t,n){var u,c,d;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(A(this,Le))return A(this,Le).continueRetry(),A(this,Le).promise}if(t&&this.setOptions(t),!this.options.queryFn){const f=this.observers.find(h=>h.options.queryFn);f&&this.setOptions(f.options)}const r=new AbortController,o=f=>{Object.defineProperty(f,"signal",{enumerable:!0,get:()=>(W(this,Cr,!0),r.signal)})},i=()=>{const f=Ev(this.options,n),v=(()=>{const g={client:A(this,Er),queryKey:this.queryKey,meta:this.meta};return o(g),g})();return W(this,Cr,!1),this.options.persister?this.options.persister(f,v,this):f(v)},a=(()=>{const f={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:A(this,Er),state:this.state,fetchFn:i};return o(f),f})();(u=this.options.behavior)==null||u.onFetch(a,this),W(this,Sr,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((c=a.fetchOptions)==null?void 0:c.meta))&&Ne(this,At,en).call(this,{type:"fetch",meta:(d=a.fetchOptions)==null?void 0:d.meta});const l=f=>{var h,v,g,x;eu(f)&&f.silent||Ne(this,At,en).call(this,{type:"error",error:f}),eu(f)||((v=(h=A(this,ht).config).onError)==null||v.call(h,f,this),(x=(g=A(this,ht).config).onSettled)==null||x.call(g,this.state.data,f,this)),this.scheduleGc()};return W(this,Le,bv({initialPromise:n==null?void 0:n.initialPromise,fn:a.fetchFn,abort:r.abort.bind(r),onSuccess:f=>{var h,v,g,x;if(f===void 0){l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(f)}catch(m){l(m);return}(v=(h=A(this,ht).config).onSuccess)==null||v.call(h,f,this),(x=(g=A(this,ht).config).onSettled)==null||x.call(g,f,this.state.error,this),this.scheduleGc()},onError:l,onFail:(f,h)=>{Ne(this,At,en).call(this,{type:"failed",failureCount:f,error:h})},onPause:()=>{Ne(this,At,en).call(this,{type:"pause"})},onContinue:()=>{Ne(this,At,en).call(this,{type:"continue"})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0})),A(this,Le).start()}},So=new WeakMap,Sr=new WeakMap,ht=new WeakMap,Er=new WeakMap,Le=new WeakMap,Zi=new WeakMap,Cr=new WeakMap,At=new WeakSet,en=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,...EE(r.data,this.options),fetchMeta:t.meta??null};case"success":return W(this,Sr,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 eu(o)&&o.revert&&A(this,Sr)?{...A(this,Sr),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),Be.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),A(this,ht).notify({query:this,type:"updated",action:t})})},eg);function EE(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Pv(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function CE(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 zt,tg,PE=(tg=class extends il{constructor(t={}){super();J(this,zt);this.config=t,W(this,zt,new Map)}build(t,n,r){const o=n.queryKey,i=n.queryHash??zd(o,n);let s=this.get(i);return s||(s=new SE({client:t,queryKey:o,queryHash:i,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(o)}),this.add(s)),s}add(t){A(this,zt).has(t.queryHash)||(A(this,zt).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=A(this,zt).get(t.queryHash);n&&(t.destroy(),n===t&&A(this,zt).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){Be.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return A(this,zt).get(t)}getAll(){return[...A(this,zt).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>Jh(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>Jh(t,r)):n}notify(t){Be.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){Be.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){Be.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},zt=new WeakMap,tg),Bt,Ve,Pr,$t,kn,ng,TE=(ng=class extends kv{constructor(t){super();J(this,$t);J(this,Bt);J(this,Ve);J(this,Pr);this.mutationId=t.mutationId,W(this,Ve,t.mutationCache),W(this,Bt,[]),this.state=t.state||bE(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){A(this,Bt).includes(t)||(A(this,Bt).push(t),this.clearGcTimeout(),A(this,Ve).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){W(this,Bt,A(this,Bt).filter(n=>n!==t)),this.scheduleGc(),A(this,Ve).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){A(this,Bt).length||(this.state.status==="pending"?this.scheduleGc():A(this,Ve).remove(this))}continue(){var t;return((t=A(this,Pr))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var i,s,a,l,u,c,d,f,h,v,g,x,m,p,y,S,C,P,T,b;const n=()=>{Ne(this,$t,kn).call(this,{type:"continue"})};W(this,Pr,bv({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(D,N)=>{Ne(this,$t,kn).call(this,{type:"failed",failureCount:D,error:N})},onPause:()=>{Ne(this,$t,kn).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>A(this,Ve).canRun(this)}));const r=this.state.status==="pending",o=!A(this,Pr).canStart();try{if(r)n();else{Ne(this,$t,kn).call(this,{type:"pending",variables:t,isPaused:o}),await((s=(i=A(this,Ve).config).onMutate)==null?void 0:s.call(i,t,this));const N=await((l=(a=this.options).onMutate)==null?void 0:l.call(a,t));N!==this.state.context&&Ne(this,$t,kn).call(this,{type:"pending",context:N,variables:t,isPaused:o})}const D=await A(this,Pr).start();return await((c=(u=A(this,Ve).config).onSuccess)==null?void 0:c.call(u,D,t,this.state.context,this)),await((f=(d=this.options).onSuccess)==null?void 0:f.call(d,D,t,this.state.context)),await((v=(h=A(this,Ve).config).onSettled)==null?void 0:v.call(h,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)),Ne(this,$t,kn).call(this,{type:"success",data:D}),D}catch(D){try{throw await((p=(m=A(this,Ve).config).onError)==null?void 0:p.call(m,D,t,this.state.context,this)),await((S=(y=this.options).onError)==null?void 0:S.call(y,D,t,this.state.context)),await((P=(C=A(this,Ve).config).onSettled)==null?void 0:P.call(C,void 0,D,this.state.variables,this.state.context,this)),await((b=(T=this.options).onSettled)==null?void 0:b.call(T,void 0,D,t,this.state.context)),D}finally{Ne(this,$t,kn).call(this,{type:"error",error:D})}}finally{A(this,Ve).runNext(this)}}},Bt=new WeakMap,Ve=new WeakMap,Pr=new WeakMap,$t=new WeakSet,kn=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),Be.batch(()=>{A(this,Bt).forEach(r=>{r.onMutationUpdate(t)}),A(this,Ve).notify({mutation:this,type:"updated",action:t})})},ng);function bE(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var rn,Rt,Ji,rg,kE=(rg=class extends il{constructor(t={}){super();J(this,rn);J(this,Rt);J(this,Ji);this.config=t,W(this,rn,new Set),W(this,Rt,new Map),W(this,Ji,0)}build(t,n,r){const o=new TE({mutationCache:this,mutationId:++ms(this,Ji)._,options:t.defaultMutationOptions(n),state:r});return this.add(o),o}add(t){A(this,rn).add(t);const n=Os(t);if(typeof n=="string"){const r=A(this,Rt).get(n);r?r.push(t):A(this,Rt).set(n,[t])}this.notify({type:"added",mutation:t})}remove(t){if(A(this,rn).delete(t)){const n=Os(t);if(typeof n=="string"){const r=A(this,Rt).get(n);if(r)if(r.length>1){const o=r.indexOf(t);o!==-1&&r.splice(o,1)}else r[0]===t&&A(this,Rt).delete(n)}}this.notify({type:"removed",mutation:t})}canRun(t){const n=Os(t);if(typeof n=="string"){const r=A(this,Rt).get(n),o=r==null?void 0:r.find(i=>i.state.status==="pending");return!o||o===t}else return!0}runNext(t){var r;const n=Os(t);if(typeof n=="string"){const o=(r=A(this,Rt).get(n))==null?void 0:r.find(i=>i!==t&&i.state.isPaused);return(o==null?void 0:o.continue())??Promise.resolve()}else return Promise.resolve()}clear(){Be.batch(()=>{A(this,rn).forEach(t=>{this.notify({type:"removed",mutation:t})}),A(this,rn).clear(),A(this,Rt).clear()})}getAll(){return Array.from(A(this,rn))}find(t){const n={exact:!0,...t};return this.getAll().find(r=>ep(n,r))}findAll(t={}){return this.getAll().filter(n=>ep(t,n))}notify(t){Be.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return Be.batch(()=>Promise.all(t.map(n=>n.continue().catch(kt))))}},rn=new WeakMap,Rt=new WeakMap,Ji=new WeakMap,rg);function Os(e){var t;return(t=e.options.scope)==null?void 0:t.id}function rp(e){return{onFetch:(t,n)=>{var c,d,f,h,v;const r=t.options,o=(f=(d=(c=t.fetchOptions)==null?void 0:c.meta)==null?void 0:d.fetchMore)==null?void 0:f.direction,i=((h=t.state.data)==null?void 0:h.pages)||[],s=((v=t.state.data)==null?void 0:v.pageParams)||[];let a={pages:[],pageParams:[]},l=0;const u=async()=>{let g=!1;const x=y=>{Object.defineProperty(y,"signal",{enumerable:!0,get:()=>(t.signal.aborted?g=!0:t.signal.addEventListener("abort",()=>{g=!0}),t.signal)})},m=Ev(t.options,t.fetchOptions),p=async(y,S,C)=>{if(g)return Promise.reject();if(S==null&&y.pages.length)return Promise.resolve(y);const T=(()=>{const V={client:t.client,queryKey:t.queryKey,pageParam:S,direction:C?"backward":"forward",meta:t.options.meta};return x(V),V})(),b=await m(T),{maxPages:D}=t.options,N=C?pE:hE;return{pages:N(y.pages,b,D),pageParams:N(y.pageParams,S,D)}};if(o&&i.length){const y=o==="backward",S=y?AE:op,C={pages:i,pageParams:s},P=S(r,C);a=await p(C,P,y)}else{const y=e??i.length;do{const S=l===0?s[0]??r.initialPageParam:op(r,a);if(l>0&&S==null)break;a=await p(a,S),l++}while(l{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 op(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 AE(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 pe,jn,_n,Eo,Co,In,Po,To,og,RE=(og=class{constructor(e={}){J(this,pe);J(this,jn);J(this,_n);J(this,Eo);J(this,Co);J(this,In);J(this,Po);J(this,To);W(this,pe,e.queryCache||new PE),W(this,jn,e.mutationCache||new kE),W(this,_n,e.defaultOptions||{}),W(this,Eo,new Map),W(this,Co,new Map),W(this,In,0)}mount(){ms(this,In)._++,A(this,In)===1&&(W(this,Po,Cv.subscribe(async e=>{e&&(await this.resumePausedMutations(),A(this,pe).onFocus())})),W(this,To,Ra.subscribe(async e=>{e&&(await this.resumePausedMutations(),A(this,pe).onOnline())})))}unmount(){var e,t;ms(this,In)._--,A(this,In)===0&&((e=A(this,Po))==null||e.call(this),W(this,Po,void 0),(t=A(this,To))==null||t.call(this),W(this,To,void 0))}isFetching(e){return A(this,pe).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return A(this,jn).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=A(this,pe).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=A(this,pe).build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(fc(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return A(this,pe).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=A(this,pe).get(r.queryHash),i=o==null?void 0:o.state.data,s=aE(t,i);if(s!==void 0)return A(this,pe).build(this,r).setData(s,{...n,manual:!0})}setQueriesData(e,t,n){return Be.batch(()=>A(this,pe).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=A(this,pe).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=A(this,pe);Be.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=A(this,pe);return Be.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=Be.batch(()=>A(this,pe).findAll(e).map(o=>o.cancel(n)));return Promise.all(r).then(kt).catch(kt)}invalidateQueries(e,t={}){return Be.batch(()=>(A(this,pe).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=Be.batch(()=>A(this,pe).findAll(e).filter(o=>!o.isDisabled()&&!o.isStatic()).map(o=>{let i=o.fetch(void 0,n);return n.throwOnError||(i=i.catch(kt)),o.state.fetchStatus==="paused"?Promise.resolve():i}));return Promise.all(r).then(kt)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=A(this,pe).build(this,t);return n.isStaleByTime(fc(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(kt).catch(kt)}fetchInfiniteQuery(e){return e.behavior=rp(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(kt).catch(kt)}ensureInfiniteQueryData(e){return e.behavior=rp(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Ra.isOnline()?A(this,jn).resumePausedMutations():Promise.resolve()}getQueryCache(){return A(this,pe)}getMutationCache(){return A(this,jn)}getDefaultOptions(){return A(this,_n)}setDefaultOptions(e){W(this,_n,e)}setQueryDefaults(e,t){A(this,Eo).set(Ui(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...A(this,Eo).values()],n={};return t.forEach(r=>{Wi(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){A(this,Co).set(Ui(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...A(this,Co).values()],n={};return t.forEach(r=>{Wi(e,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...A(this,_n).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=zd(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===Bd&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...A(this,_n).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){A(this,pe).clear(),A(this,jn).clear()}},pe=new WeakMap,jn=new WeakMap,_n=new WeakMap,Eo=new WeakMap,Co=new WeakMap,In=new WeakMap,Po=new WeakMap,To=new WeakMap,og),ME=w.createContext(void 0),NE=({client:e,children:t})=>(w.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),E.jsx(ME.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 Ma(){return Ma=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function Av(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function OE(){return Math.random().toString(36).substr(2,8)}function sp(e,t){return{usr:e.state,key:e.key,idx:t}}function pc(e,t,n,r){return n===void 0&&(n=null),Ma({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?al(t):t,{state:n,key:t&&t.key||r||OE()})}function Rv(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 al(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 LE(e,t,n,r){r===void 0&&(r={});let{window:o=document.defaultView,v5Compat:i=!1}=r,s=o.history,a=zn.Pop,l=null,u=c();u==null&&(u=0,s.replaceState(Ma({},s.state,{idx:u}),""));function c(){return(s.state||{idx:null}).idx}function d(){a=zn.Pop;let x=c(),m=x==null?null:x-u;u=x,l&&l({action:a,location:g.location,delta:m})}function f(x,m){a=zn.Push;let p=pc(g.location,x,m);u=c()+1;let y=sp(p,u),S=g.createHref(p);try{s.pushState(y,"",S)}catch(C){if(C instanceof DOMException&&C.name==="DataCloneError")throw C;o.location.assign(S)}i&&l&&l({action:a,location:g.location,delta:1})}function h(x,m){a=zn.Replace;let p=pc(g.location,x,m);u=c();let y=sp(p,u),S=g.createHref(p);s.replaceState(y,"",S),i&&l&&l({action:a,location:g.location,delta:0})}function v(x){let m=o.location.origin!=="null"?o.location.origin:o.location.href,p=typeof x=="string"?x:Rv(x);return p=p.replace(/ $/,"%20"),qe(m,"No window.location.(origin|href) available to create URL for href: "+p),new URL(p,m)}let g={get action(){return a},get location(){return e(o,s)},listen(x){if(l)throw new Error("A history only accepts one active listener");return o.addEventListener(ip,d),l=x,()=>{o.removeEventListener(ip,d),l=null}},createHref(x){return t(o,x)},createURL:v,encodeLocation(x){let m=v(x);return{pathname:m.pathname,search:m.search,hash:m.hash}},push:f,replace:h,go(x){return s.go(x)}};return g}var ap;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(ap||(ap={}));function jE(e,t,n){return n===void 0&&(n="/"),_E(e,t,n,!1)}function _E(e,t,n,r){let o=typeof t=="string"?al(t):t,i=Dv(o.pathname||"/",n);if(i==null)return null;let s=Mv(e);IE(s);let a=null;for(let l=0;a==null&&l{let l={relativePath:a===void 0?i.path||"":a,caseSensitive:i.caseSensitive===!0,childrenIndex:s,route:i};l.relativePath.startsWith("/")&&(qe(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=mo([r,l.relativePath]),c=n.concat(l);i.children&&i.children.length>0&&(qe(i.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+u+'".')),Mv(i.children,t,c,u)),!(i.path==null&&!i.index)&&t.push({path:u,score:WE(u,i.index),routesMeta:c})};return e.forEach((i,s)=>{var a;if(i.path===""||!((a=i.path)!=null&&a.includes("?")))o(i,s);else for(let l of Nv(i.path))o(i,s,l)}),t}function Nv(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,o=n.endsWith("?"),i=n.replace(/\?$/,"");if(r.length===0)return o?[i,""]:[i];let s=Nv(r.join("/")),a=[];return a.push(...s.map(l=>l===""?i:[i,l].join("/"))),o&&a.push(...s),a.map(l=>e.startsWith("/")&&l===""?"/":l)}function IE(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:HE(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const FE=/^:[\w-]+$/,VE=3,zE=2,BE=1,$E=10,UE=-2,lp=e=>e==="*";function WE(e,t){let n=e.split("/"),r=n.length;return n.some(lp)&&(r+=UE),t&&(r+=zE),n.filter(o=>!lp(o)).reduce((o,i)=>o+(FE.test(i)?VE:i===""?BE:$E),r)}function HE(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 KE(e,t,n){let{routesMeta:r}=e,o={},i="/",s=[];for(let a=0;a{let{paramName:f,isOptional:h}=c;if(f==="*"){let g=a[d]||"";s=i.slice(0,i.length-g.length).replace(/(.)\/+$/,"$1")}const v=a[d];return h&&!v?u[f]=void 0:u[f]=(v||"").replace(/%2F/g,"/"),u},{}),pathname:i,pathnameBase:s,pattern:e}}function GE(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),Av(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,(s,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 QE(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Av(!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 Dv(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 mo=e=>e.join("/").replace(/\/\/+/g,"/"),YE=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/");function XE(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const Ov=["post","put","patch","delete"];new Set(Ov);const qE=["get",...Ov];new Set(qE);/** * 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 Na(){return Na=Object.assign?Object.assign.bind():function(e){for(var t=1;tObject.assign({},x,{params:Object.assign({},a,x.params),pathname:mo([l,o.encodeLocation?o.encodeLocation(x.pathname).pathname:x.pathname]),pathnameBase:x.pathnameBase==="/"?l:mo([l,o.encodeLocation?o.encodeLocation(x.pathnameBase).pathname:x.pathnameBase])})),i,n,r);return t&&g?w.createElement(ll.Provider,{value:{location:Na({pathname:"/",search:"",hash:"",state:null,key:"default"},c),navigationType:zn.Pop}},g):g}function nC(){let e=cC(),t=XE(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 w.createElement(w.Fragment,null,w.createElement("h2",null,"Unexpected Application Error!"),w.createElement("h3",{style:{fontStyle:"italic"}},t),n?w.createElement("pre",{style:o},n):null,null)}const rC=w.createElement(nC,null);class oC extends w.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?w.createElement(ul.Provider,{value:this.props.routeContext},w.createElement(jv.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function iC(e){let{routeContext:t,match:n,children:r}=e,o=w.useContext(ZE);return o&&o.static&&o.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(o.staticContext._deepestRenderedBoundaryId=n.route.id),w.createElement(ul.Provider,{value:t},r)}function sC(e,t,n,r){var o;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var i;if(!n)return null;if(n.errors)e=n.matches;else if((i=r)!=null&&i.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let s=e,a=(o=n)==null?void 0:o.errors;if(a!=null){let c=s.findIndex(d=>d.route.id&&(a==null?void 0:a[d.route.id])!==void 0);c>=0||qe(!1),s=s.slice(0,Math.min(s.length,c+1))}let l=!1,u=-1;if(n&&r&&r.v7_partialHydration)for(let c=0;c=0?s=s.slice(0,u+1):s=[s[0]];break}}}return s.reduceRight((c,d,f)=>{let h,v=!1,g=null,x=null;n&&(h=a&&d.route.id?a[d.route.id]:void 0,g=d.route.errorElement||rC,l&&(u<0&&f===0?(v=!0,x=null):u===f&&(v=!0,x=d.route.hydrateFallbackElement||null)));let m=t.concat(s.slice(0,f+1)),p=()=>{let y;return h?y=g:v?y=x:d.route.Component?y=w.createElement(d.route.Component,null):d.route.element?y=d.route.element:y=c,w.createElement(iC,{match:d,routeContext:{outlet:c,matches:m,isDataRoute:n!=null},children:y})};return n&&(d.route.ErrorBoundary||d.route.errorElement||f===0)?w.createElement(oC,{location:n.location,revalidation:n.revalidation,component:g,error:h,children:p(),routeContext:{outlet:null,matches:m,isDataRoute:!0}}):p()},null)}var mc=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}(mc||{});function aC(e){let t=w.useContext(JE);return t||qe(!1),t}function lC(e){let t=w.useContext(ul);return t||qe(!1),t}function uC(e){let t=lC(),n=t.matches[t.matches.length-1];return n.route.id||qe(!1),n.route.id}function cC(){var e;let t=w.useContext(jv),n=aC(mc.UseRouteError),r=uC(mc.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function dC(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function gc(e){qe(!1)}function fC(e){let{basename:t="/",children:n=null,location:r,navigationType:o=zn.Pop,navigator:i,static:s=!1,future:a}=e;$d()&&qe(!1);let l=t.replace(/^\/*/,"/"),u=w.useMemo(()=>({basename:l,navigator:i,static:s,future:Na({v7_relativeSplatPath:!1},a)}),[l,a,i,s]);typeof r=="string"&&(r=al(r));let{pathname:c="/",search:d="",hash:f="",state:h=null,key:v="default"}=r,g=w.useMemo(()=>{let x=Dv(c,l);return x==null?null:{location:{pathname:x,search:d,hash:f,state:h,key:v},navigationType:o}},[l,c,d,f,h,v,o]);return g==null?null:w.createElement(Lv.Provider,{value:u},w.createElement(ll.Provider,{children:n,value:g}))}function hC(e){let{children:t,location:n}=e;return eC(yc(t),n)}new Promise(()=>{});function yc(e,t){t===void 0&&(t=[]);let n=[];return w.Children.forEach(e,(r,o)=>{if(!w.isValidElement(r))return;let i=[...t,o];if(r.type===w.Fragment){n.push.apply(n,yc(r.props.children,i));return}r.type!==gc&&qe(!1),!r.props.index||!r.props.children||qe(!1);let s={id:r.props.id||i.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&&(s.children=yc(r.props.children,i)),n.push(s)}),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 pC="6";try{window.__reactRouterVersion=pC}catch{}const mC="startTransition",cp=gg[mC];function gC(e){let{basename:t,children:n,future:r,window:o}=e,i=w.useRef();i.current==null&&(i.current=DE({window:o,v5Compat:!0}));let s=i.current,[a,l]=w.useState({action:s.action,location:s.location}),{v7_startTransition:u}=r||{},c=w.useCallback(d=>{u&&cp?cp(()=>l(d)):l(d)},[l,u]);return w.useLayoutEffect(()=>s.listen(c),[s,c]),w.useEffect(()=>dC(r),[r]),w.createElement(fC,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:s,future:r})}var dp;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(dp||(dp={}));var fp;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(fp||(fp={}));var hp=["light","dark"],yC="(prefers-color-scheme: dark)",vC=w.createContext(void 0),xC={setTheme:e=>{},themes:[]},wC=()=>{var e;return(e=w.useContext(vC))!=null?e:xC};w.memo(({forcedTheme:e,storageKey:t,attribute:n,enableSystem:r,enableColorScheme:o,defaultTheme:i,value:s,attrs:a,nonce:l})=>{let u=i==="system",c=n==="class"?`var d=document.documentElement,c=d.classList;${`c.remove(${a.map(v=>`'${v}'`).join(",")})`};`:`var d=document.documentElement,n='${n}',s='setAttribute';`,d=o?hp.includes(i)&&i?`if(e==='light'||e==='dark'||!e)d.style.colorScheme=e||'${i}'`:"if(e==='light'||e==='dark')d.style.colorScheme=e":"",f=(v,g=!1,x=!0)=>{let m=s?s[v]:v,p=g?v+"|| ''":`'${m}'`,y="";return o&&x&&!g&&hp.includes(v)&&(y+=`d.style.colorScheme = '${v}';`),n==="class"?g||m?y+=`c.add(${p})`:y+="null":m&&(y+=`d[s](n,${p})`),y},h=e?`!function(){${c}${f(e)}}()`:r?`!function(){try{${c}var e=localStorage.getItem('${t}');if('system'===e||(!e&&${u})){var t='${yC}',m=window.matchMedia(t);if(m.media!==t||m.matches){${f("dark")}}else{${f("light")}}}else if(e){${s?`var x=${JSON.stringify(s)};`:""}${f(s?"x[e]":"e",!0)}}${u?"":"else{"+f(i,!1,!1)+"}"}${d}}catch(e){}}()`:`!function(){try{${c}var e=localStorage.getItem('${t}');if(e){${s?`var x=${JSON.stringify(s)};`:""}${f(s?"x[e]":"e",!0)}}else{${f(i,!1,!1)};}${d}}catch(t){}}();`;return w.createElement("script",{nonce:l,dangerouslySetInnerHTML:{__html:h}})});var SC=e=>{switch(e){case"success":return PC;case"info":return bC;case"warning":return TC;case"error":return kC;default:return null}},EC=Array(12).fill(0),CC=({visible:e,className:t})=>O.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},O.createElement("div",{className:"sonner-spinner"},EC.map((n,r)=>O.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),PC=O.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},O.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"})),TC=O.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},O.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"})),bC=O.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},O.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"})),kC=O.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},O.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"})),AC=O.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"},O.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),O.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),RC=()=>{let[e,t]=O.useState(document.hidden);return O.useEffect(()=>{let n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e},vc=1,MC=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:vc++,i=this.toasts.find(a=>a.id===o),s=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(o)&&this.dismissedToasts.delete(o),i?this.toasts=this.toasts.map(a=>a.id===o?(this.publish({...a,...e,id:o,title:n}),{...a,...e,id:o,dismissible:s,title:n}):a):this.addToast({title:n,...r,dismissible:s,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,i,s=r.then(async l=>{if(i=["resolve",l],O.isValidElement(l))o=!1,this.create({id:n,type:"default",message:l});else if(DC(l)&&!l.ok){o=!1;let u=typeof t.error=="function"?await t.error(`HTTP error! status: ${l.status}`):t.error,c=typeof t.description=="function"?await t.description(`HTTP error! status: ${l.status}`):t.description;this.create({id:n,type:"error",message:u,description:c})}else if(t.success!==void 0){o=!1;let u=typeof t.success=="function"?await t.success(l):t.success,c=typeof t.description=="function"?await t.description(l):t.description;this.create({id:n,type:"success",message:u,description:c})}}).catch(async l=>{if(i=["reject",l],t.error!==void 0){o=!1;let u=typeof t.error=="function"?await t.error(l):t.error,c=typeof t.description=="function"?await t.description(l):t.description;this.create({id:n,type:"error",message:u,description:c})}}).finally(()=>{var l;o&&(this.dismiss(n),n=void 0),(l=t.finally)==null||l.call(t)}),a=()=>new Promise((l,u)=>s.then(()=>i[0]==="reject"?u(i[1]):l(i[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)||vc++;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}},He=new MC,NC=(e,t)=>{let n=(t==null?void 0:t.id)||vc++;return He.addToast({title:e,...t,id:n}),n},DC=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",OC=NC,LC=()=>He.toasts,jC=()=>He.getActiveToasts();Object.assign(OC,{success:He.success,info:He.info,warning:He.warning,error:He.error,custom:He.custom,message:He.message,promise:He.promise,dismiss:He.dismiss,loading:He.loading},{getHistory:LC,getToasts:jC});function _C(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))}_C(`: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 Ls(e){return e.label!==void 0}var IC=3,FC="32px",VC="16px",pp=4e3,zC=356,BC=14,$C=20,UC=200;function Pt(...e){return e.filter(Boolean).join(" ")}function WC(e){let[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}var HC=e=>{var t,n,r,o,i,s,a,l,u,c,d;let{invert:f,toast:h,unstyled:v,interacting:g,setHeights:x,visibleToasts:m,heights:p,index:y,toasts:S,expanded:C,removeToast:P,defaultRichColors:T,closeButton:b,style:D,cancelButtonStyle:N,actionButtonStyle:V,className:_="",descriptionClassName:G="",duration:L,position:Q,gap:$,loadingIcon:F,expandByDefault:k,classNames:R,icons:j,closeButtonAriaLabel:H="Close toast",pauseWhenPageIsHidden:z}=e,[Y,q]=O.useState(null),[xe,Me]=O.useState(null),[ee,Fr]=O.useState(!1),[vn,ar]=O.useState(!1),[xn,Vr]=O.useState(!1),[wn,fs]=O.useState(!1),[Cl,hs]=O.useState(!1),[Pl,Ko]=O.useState(0),[zr,If]=O.useState(0),Go=O.useRef(h.duration||L||pp),Ff=O.useRef(null),lr=O.useRef(null),bw=y===0,kw=y+1<=m,ct=h.type,Br=h.dismissible!==!1,Aw=h.className||"",Rw=h.descriptionClassName||"",ps=O.useMemo(()=>p.findIndex(U=>U.toastId===h.id)||0,[p,h.id]),Mw=O.useMemo(()=>{var U;return(U=h.closeButton)!=null?U:b},[h.closeButton,b]),Vf=O.useMemo(()=>h.duration||L||pp,[h.duration,L]),Tl=O.useRef(0),$r=O.useRef(0),zf=O.useRef(0),Ur=O.useRef(null),[Nw,Dw]=Q.split("-"),Bf=O.useMemo(()=>p.reduce((U,ne,le)=>le>=ps?U:U+ne.height,0),[p,ps]),$f=RC(),Ow=h.invert||f,bl=ct==="loading";$r.current=O.useMemo(()=>ps*$+Bf,[ps,Bf]),O.useEffect(()=>{Go.current=Vf},[Vf]),O.useEffect(()=>{Fr(!0)},[]),O.useEffect(()=>{let U=lr.current;if(U){let ne=U.getBoundingClientRect().height;return If(ne),x(le=>[{toastId:h.id,height:ne,position:h.position},...le]),()=>x(le=>le.filter(wt=>wt.toastId!==h.id))}},[x,h.id]),O.useLayoutEffect(()=>{if(!ee)return;let U=lr.current,ne=U.style.height;U.style.height="auto";let le=U.getBoundingClientRect().height;U.style.height=ne,If(le),x(wt=>wt.find(St=>St.toastId===h.id)?wt.map(St=>St.toastId===h.id?{...St,height:le}:St):[{toastId:h.id,height:le,position:h.position},...wt])},[ee,h.title,h.description,x,h.id]);let Sn=O.useCallback(()=>{ar(!0),Ko($r.current),x(U=>U.filter(ne=>ne.toastId!==h.id)),setTimeout(()=>{P(h)},UC)},[h,P,x,$r]);O.useEffect(()=>{if(h.promise&&ct==="loading"||h.duration===1/0||h.type==="loading")return;let U;return C||g||z&&$f?(()=>{if(zf.current{var ne;(ne=h.onAutoClose)==null||ne.call(h,h),Sn()},Go.current)),()=>clearTimeout(U)},[C,g,h,ct,z,$f,Sn]),O.useEffect(()=>{h.delete&&Sn()},[Sn,h.delete]);function Lw(){var U,ne,le;return j!=null&&j.loading?O.createElement("div",{className:Pt(R==null?void 0:R.loader,(U=h==null?void 0:h.classNames)==null?void 0:U.loader,"sonner-loader"),"data-visible":ct==="loading"},j.loading):F?O.createElement("div",{className:Pt(R==null?void 0:R.loader,(ne=h==null?void 0:h.classNames)==null?void 0:ne.loader,"sonner-loader"),"data-visible":ct==="loading"},F):O.createElement(CC,{className:Pt(R==null?void 0:R.loader,(le=h==null?void 0:h.classNames)==null?void 0:le.loader),visible:ct==="loading"})}return O.createElement("li",{tabIndex:0,ref:lr,className:Pt(_,Aw,R==null?void 0:R.toast,(t=h==null?void 0:h.classNames)==null?void 0:t.toast,R==null?void 0:R.default,R==null?void 0:R[ct],(n=h==null?void 0:h.classNames)==null?void 0:n[ct]),"data-sonner-toast":"","data-rich-colors":(r=h.richColors)!=null?r:T,"data-styled":!(h.jsx||h.unstyled||v),"data-mounted":ee,"data-promise":!!h.promise,"data-swiped":Cl,"data-removed":vn,"data-visible":kw,"data-y-position":Nw,"data-x-position":Dw,"data-index":y,"data-front":bw,"data-swiping":xn,"data-dismissible":Br,"data-type":ct,"data-invert":Ow,"data-swipe-out":wn,"data-swipe-direction":xe,"data-expanded":!!(C||k&&ee),style:{"--index":y,"--toasts-before":y,"--z-index":S.length-y,"--offset":`${vn?Pl:$r.current}px`,"--initial-height":k?"auto":`${zr}px`,...D,...h.style},onDragEnd:()=>{Vr(!1),q(null),Ur.current=null},onPointerDown:U=>{bl||!Br||(Ff.current=new Date,Ko($r.current),U.target.setPointerCapture(U.pointerId),U.target.tagName!=="BUTTON"&&(Vr(!0),Ur.current={x:U.clientX,y:U.clientY}))},onPointerUp:()=>{var U,ne,le,wt;if(wn||!Br)return;Ur.current=null;let St=Number(((U=lr.current)==null?void 0:U.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),En=Number(((ne=lr.current)==null?void 0:ne.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),ur=new Date().getTime()-((le=Ff.current)==null?void 0:le.getTime()),Et=Y==="x"?St:En,Cn=Math.abs(Et)/ur;if(Math.abs(Et)>=$C||Cn>.11){Ko($r.current),(wt=h.onDismiss)==null||wt.call(h,h),Me(Y==="x"?St>0?"right":"left":En>0?"down":"up"),Sn(),fs(!0),hs(!1);return}Vr(!1),q(null)},onPointerMove:U=>{var ne,le,wt,St;if(!Ur.current||!Br||((ne=window.getSelection())==null?void 0:ne.toString().length)>0)return;let En=U.clientY-Ur.current.y,ur=U.clientX-Ur.current.x,Et=(le=e.swipeDirections)!=null?le:WC(Q);!Y&&(Math.abs(ur)>1||Math.abs(En)>1)&&q(Math.abs(ur)>Math.abs(En)?"x":"y");let Cn={x:0,y:0};Y==="y"?(Et.includes("top")||Et.includes("bottom"))&&(Et.includes("top")&&En<0||Et.includes("bottom")&&En>0)&&(Cn.y=En):Y==="x"&&(Et.includes("left")||Et.includes("right"))&&(Et.includes("left")&&ur<0||Et.includes("right")&&ur>0)&&(Cn.x=ur),(Math.abs(Cn.x)>0||Math.abs(Cn.y)>0)&&hs(!0),(wt=lr.current)==null||wt.style.setProperty("--swipe-amount-x",`${Cn.x}px`),(St=lr.current)==null||St.style.setProperty("--swipe-amount-y",`${Cn.y}px`)}},Mw&&!h.jsx?O.createElement("button",{"aria-label":H,"data-disabled":bl,"data-close-button":!0,onClick:bl||!Br?()=>{}:()=>{var U;Sn(),(U=h.onDismiss)==null||U.call(h,h)},className:Pt(R==null?void 0:R.closeButton,(o=h==null?void 0:h.classNames)==null?void 0:o.closeButton)},(i=j==null?void 0:j.close)!=null?i:AC):null,h.jsx||w.isValidElement(h.title)?h.jsx?h.jsx:typeof h.title=="function"?h.title():h.title:O.createElement(O.Fragment,null,ct||h.icon||h.promise?O.createElement("div",{"data-icon":"",className:Pt(R==null?void 0:R.icon,(s=h==null?void 0:h.classNames)==null?void 0:s.icon)},h.promise||h.type==="loading"&&!h.icon?h.icon||Lw():null,h.type!=="loading"?h.icon||(j==null?void 0:j[ct])||SC(ct):null):null,O.createElement("div",{"data-content":"",className:Pt(R==null?void 0:R.content,(a=h==null?void 0:h.classNames)==null?void 0:a.content)},O.createElement("div",{"data-title":"",className:Pt(R==null?void 0:R.title,(l=h==null?void 0:h.classNames)==null?void 0:l.title)},typeof h.title=="function"?h.title():h.title),h.description?O.createElement("div",{"data-description":"",className:Pt(G,Rw,R==null?void 0:R.description,(u=h==null?void 0:h.classNames)==null?void 0:u.description)},typeof h.description=="function"?h.description():h.description):null),w.isValidElement(h.cancel)?h.cancel:h.cancel&&Ls(h.cancel)?O.createElement("button",{"data-button":!0,"data-cancel":!0,style:h.cancelButtonStyle||N,onClick:U=>{var ne,le;Ls(h.cancel)&&Br&&((le=(ne=h.cancel).onClick)==null||le.call(ne,U),Sn())},className:Pt(R==null?void 0:R.cancelButton,(c=h==null?void 0:h.classNames)==null?void 0:c.cancelButton)},h.cancel.label):null,w.isValidElement(h.action)?h.action:h.action&&Ls(h.action)?O.createElement("button",{"data-button":!0,"data-action":!0,style:h.actionButtonStyle||V,onClick:U=>{var ne,le;Ls(h.action)&&((le=(ne=h.action).onClick)==null||le.call(ne,U),!U.defaultPrevented&&Sn())},className:Pt(R==null?void 0:R.actionButton,(d=h==null?void 0:h.classNames)==null?void 0:d.actionButton)},h.action.label):null))};function mp(){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 KC(e,t){let n={};return[e,t].forEach((r,o)=>{let i=o===1,s=i?"--mobile-offset":"--offset",a=i?VC:FC;function l(u){["top","right","bottom","left"].forEach(c=>{n[`${s}-${c}`]=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[`${s}-${u}`]=a:n[`${s}-${u}`]=typeof r[u]=="number"?`${r[u]}px`:r[u]}):l(a)}),n}var GC=w.forwardRef(function(e,t){let{invert:n,position:r="bottom-right",hotkey:o=["altKey","KeyT"],expand:i,closeButton:s,className:a,offset:l,mobileOffset:u,theme:c="light",richColors:d,duration:f,style:h,visibleToasts:v=IC,toastOptions:g,dir:x=mp(),gap:m=BC,loadingIcon:p,icons:y,containerAriaLabel:S="Notifications",pauseWhenPageIsHidden:C}=e,[P,T]=O.useState([]),b=O.useMemo(()=>Array.from(new Set([r].concat(P.filter(z=>z.position).map(z=>z.position)))),[P,r]),[D,N]=O.useState([]),[V,_]=O.useState(!1),[G,L]=O.useState(!1),[Q,$]=O.useState(c!=="system"?c:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),F=O.useRef(null),k=o.join("+").replace(/Key/g,"").replace(/Digit/g,""),R=O.useRef(null),j=O.useRef(!1),H=O.useCallback(z=>{T(Y=>{var q;return(q=Y.find(xe=>xe.id===z.id))!=null&&q.delete||He.dismiss(z.id),Y.filter(({id:xe})=>xe!==z.id)})},[]);return O.useEffect(()=>He.subscribe(z=>{if(z.dismiss){T(Y=>Y.map(q=>q.id===z.id?{...q,delete:!0}:q));return}setTimeout(()=>{xv.flushSync(()=>{T(Y=>{let q=Y.findIndex(xe=>xe.id===z.id);return q!==-1?[...Y.slice(0,q),{...Y[q],...z},...Y.slice(q+1)]:[z,...Y]})})})}),[]),O.useEffect(()=>{if(c!=="system"){$(c);return}if(c==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?$("dark"):$("light")),typeof window>"u")return;let z=window.matchMedia("(prefers-color-scheme: dark)");try{z.addEventListener("change",({matches:Y})=>{$(Y?"dark":"light")})}catch{z.addListener(({matches:q})=>{try{$(q?"dark":"light")}catch(xe){console.error(xe)}})}},[c]),O.useEffect(()=>{P.length<=1&&_(!1)},[P]),O.useEffect(()=>{let z=Y=>{var q,xe;o.every(Me=>Y[Me]||Y.code===Me)&&(_(!0),(q=F.current)==null||q.focus()),Y.code==="Escape"&&(document.activeElement===F.current||(xe=F.current)!=null&&xe.contains(document.activeElement))&&_(!1)};return document.addEventListener("keydown",z),()=>document.removeEventListener("keydown",z)},[o]),O.useEffect(()=>{if(F.current)return()=>{R.current&&(R.current.focus({preventScroll:!0}),R.current=null,j.current=!1)}},[F.current]),O.createElement("section",{ref:t,"aria-label":`${S} ${k}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},b.map((z,Y)=>{var q;let[xe,Me]=z.split("-");return P.length?O.createElement("ol",{key:z,dir:x==="auto"?mp():x,tabIndex:-1,ref:F,className:a,"data-sonner-toaster":!0,"data-theme":Q,"data-y-position":xe,"data-lifted":V&&P.length>1&&!i,"data-x-position":Me,style:{"--front-toast-height":`${((q=D[0])==null?void 0:q.height)||0}px`,"--width":`${zC}px`,"--gap":`${m}px`,...h,...KC(l,u)},onBlur:ee=>{j.current&&!ee.currentTarget.contains(ee.relatedTarget)&&(j.current=!1,R.current&&(R.current.focus({preventScroll:!0}),R.current=null))},onFocus:ee=>{ee.target instanceof HTMLElement&&ee.target.dataset.dismissible==="false"||j.current||(j.current=!0,R.current=ee.relatedTarget)},onMouseEnter:()=>_(!0),onMouseMove:()=>_(!0),onMouseLeave:()=>{G||_(!1)},onDragEnd:()=>_(!1),onPointerDown:ee=>{ee.target instanceof HTMLElement&&ee.target.dataset.dismissible==="false"||L(!0)},onPointerUp:()=>L(!1)},P.filter(ee=>!ee.position&&Y===0||ee.position===z).map((ee,Fr)=>{var vn,ar;return O.createElement(HC,{key:ee.id,icons:y,index:Fr,toast:ee,defaultRichColors:d,duration:(vn=g==null?void 0:g.duration)!=null?vn:f,className:g==null?void 0:g.className,descriptionClassName:g==null?void 0:g.descriptionClassName,invert:n,visibleToasts:v,closeButton:(ar=g==null?void 0:g.closeButton)!=null?ar:s,interacting:G,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:H,toasts:P.filter(xn=>xn.position==ee.position),heights:D.filter(xn=>xn.position==ee.position),setHeights:N,expandByDefault:i,gap:m,loadingIcon:p,expanded:V,pauseWhenPageIsHidden:C,swipeDirections:e.swipeDirections})})):null}))});const QC=({...e})=>{const{theme:t="system"}=wC();return E.jsx(GC,{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})},YC=1,XC=1e6;let tu=0;function qC(){return tu=(tu+1)%Number.MAX_SAFE_INTEGER,tu.toString()}const nu=new Map,gp=e=>{if(nu.has(e))return;const t=setTimeout(()=>{nu.delete(e),Si({type:"REMOVE_TOAST",toastId:e})},XC);nu.set(e,t)},ZC=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,YC)};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?gp(n):e.toasts.forEach(r=>{gp(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)}}},Js=[];let ea={toasts:[]};function Si(e){ea=ZC(ea,e),Js.forEach(t=>{t(ea)})}function JC({...e}){const t=qC(),n=o=>Si({type:"UPDATE_TOAST",toast:{...o,id:t}}),r=()=>Si({type:"DISMISS_TOAST",toastId:t});return Si({type:"ADD_TOAST",toast:{...e,id:t,open:!0,onOpenChange:o=>{o||r()}}}),{id:t,dismiss:r,update:n}}function eP(){const[e,t]=w.useState(ea);return w.useEffect(()=>(Js.push(t),()=>{const n=Js.indexOf(t);n>-1&&Js.splice(n,1)}),[e]),{...e,toast:JC,dismiss:n=>Si({type:"DISMISS_TOAST",toastId:n})}}function Ee(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 yp(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Iv(...e){return t=>{let n=!1;const r=e.map(o=>{const i=yp(o,t);return!n&&typeof i=="function"&&(n=!0),i});if(n)return()=>{for(let o=0;o{var m;const{scope:f,children:h,...v}=d,g=((m=f==null?void 0:f[e])==null?void 0:m[l])||a,x=w.useMemo(()=>v,Object.values(v));return E.jsx(g.Provider,{value:x,children:h})};u.displayName=i+"Provider";function c(d,f){var g;const h=((g=f==null?void 0:f[e])==null?void 0:g[l])||a,v=w.useContext(h);if(v)return v;if(s!==void 0)return s;throw new Error(`\`${d}\` must be used within \`${i}\``)}return[u,c]}const o=()=>{const i=n.map(s=>w.createContext(s));return function(a){const l=(a==null?void 0:a[e])||i;return w.useMemo(()=>({[`__scope${e}`]:{...a,[e]:l}}),[a,l])}};return o.scopeName=e,[r,tP(o,...t)]}function tP(...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(i){const s=r.reduce((a,{useScope:l,scopeName:u})=>{const d=l(i)[`__scope${u}`];return{...a,...d}},{});return w.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return n.scopeName=t.scopeName,n}function xc(e){const t=nP(e),n=w.forwardRef((r,o)=>{const{children:i,...s}=r,a=w.Children.toArray(i),l=a.find(oP);if(l){const u=l.props.children,c=a.map(d=>d===l?w.Children.count(u)>1?w.Children.only(null):w.isValidElement(u)?u.props.children:null:d);return E.jsx(t,{...s,ref:o,children:w.isValidElement(u)?w.cloneElement(u,void 0,c):null})}return E.jsx(t,{...s,ref:o,children:i})});return n.displayName=`${e}.Slot`,n}function nP(e){const t=w.forwardRef((n,r)=>{const{children:o,...i}=n;if(w.isValidElement(o)){const s=sP(o),a=iP(i,o.props);return o.type!==w.Fragment&&(a.ref=r?Iv(r,s):s),w.cloneElement(o,a)}return w.Children.count(o)>1?w.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Fv=Symbol("radix.slottable");function rP(e){const t=({children:n})=>E.jsx(E.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=Fv,t}function oP(e){return w.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Fv}function iP(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...a)=>{const l=i(...a);return o(...a),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...i}:r==="className"&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}function sP(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 aP(e){const t=e+"CollectionProvider",[n,r]=cl(t),[o,i]=n(t,{collectionRef:{current:null},itemMap:new Map}),s=g=>{const{scope:x,children:m}=g,p=O.useRef(null),y=O.useRef(new Map).current;return E.jsx(o,{scope:x,itemMap:y,collectionRef:p,children:m})};s.displayName=t;const a=e+"CollectionSlot",l=xc(a),u=O.forwardRef((g,x)=>{const{scope:m,children:p}=g,y=i(a,m),S=jt(x,y.collectionRef);return E.jsx(l,{ref:S,children:p})});u.displayName=a;const c=e+"CollectionItemSlot",d="data-radix-collection-item",f=xc(c),h=O.forwardRef((g,x)=>{const{scope:m,children:p,...y}=g,S=O.useRef(null),C=jt(x,S),P=i(c,m);return O.useEffect(()=>(P.itemMap.set(S,{ref:S,...y}),()=>void P.itemMap.delete(S))),E.jsx(f,{[d]:"",ref:C,children:p})});h.displayName=c;function v(g){const x=i(e+"CollectionConsumer",g);return O.useCallback(()=>{const p=x.collectionRef.current;if(!p)return[];const y=Array.from(p.querySelectorAll(`[${d}]`));return Array.from(x.itemMap.values()).sort((P,T)=>y.indexOf(P.ref.current)-y.indexOf(T.ref.current))},[x.collectionRef,x.itemMap])}return[{Provider:s,Slot:u,ItemSlot:h},v,r]}var lP=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Ze=lP.reduce((e,t)=>{const n=xc(`Primitive.${t}`),r=w.forwardRef((o,i)=>{const{asChild:s,...a}=o,l=s?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),E.jsx(l,{...a,ref:i})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Vv(e,t){e&&is.flushSync(()=>e.dispatchEvent(t))}function qn(e){const t=w.useRef(e);return w.useEffect(()=>{t.current=e}),w.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function uP(e,t=globalThis==null?void 0:globalThis.document){const n=qn(e);w.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 cP="DismissableLayer",wc="dismissableLayer.update",dP="dismissableLayer.pointerDownOutside",fP="dismissableLayer.focusOutside",vp,zv=w.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Ud=w.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:i,onInteractOutside:s,onDismiss:a,...l}=e,u=w.useContext(zv),[c,d]=w.useState(null),f=(c==null?void 0:c.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,h]=w.useState({}),v=jt(t,T=>d(T)),g=Array.from(u.layers),[x]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),m=g.indexOf(x),p=c?g.indexOf(c):-1,y=u.layersWithOutsidePointerEventsDisabled.size>0,S=p>=m,C=pP(T=>{const b=T.target,D=[...u.branches].some(N=>N.contains(b));!S||D||(o==null||o(T),s==null||s(T),T.defaultPrevented||a==null||a())},f),P=mP(T=>{const b=T.target;[...u.branches].some(N=>N.contains(b))||(i==null||i(T),s==null||s(T),T.defaultPrevented||a==null||a())},f);return uP(T=>{p===u.layers.size-1&&(r==null||r(T),!T.defaultPrevented&&a&&(T.preventDefault(),a()))},f),w.useEffect(()=>{if(c)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(vp=f.body.style.pointerEvents,f.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(c)),u.layers.add(c),xp(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(f.body.style.pointerEvents=vp)}},[c,f,n,u]),w.useEffect(()=>()=>{c&&(u.layers.delete(c),u.layersWithOutsidePointerEventsDisabled.delete(c),xp())},[c,u]),w.useEffect(()=>{const T=()=>h({});return document.addEventListener(wc,T),()=>document.removeEventListener(wc,T)},[]),E.jsx(Ze.div,{...l,ref:v,style:{pointerEvents:y?S?"auto":"none":void 0,...e.style},onFocusCapture:Ee(e.onFocusCapture,P.onFocusCapture),onBlurCapture:Ee(e.onBlurCapture,P.onBlurCapture),onPointerDownCapture:Ee(e.onPointerDownCapture,C.onPointerDownCapture)})});Ud.displayName=cP;var hP="DismissableLayerBranch",Bv=w.forwardRef((e,t)=>{const n=w.useContext(zv),r=w.useRef(null),o=jt(t,r);return w.useEffect(()=>{const i=r.current;if(i)return n.branches.add(i),()=>{n.branches.delete(i)}},[n.branches]),E.jsx(Ze.div,{...e,ref:o})});Bv.displayName=hP;function pP(e,t=globalThis==null?void 0:globalThis.document){const n=qn(e),r=w.useRef(!1),o=w.useRef(()=>{});return w.useEffect(()=>{const i=a=>{if(a.target&&!r.current){let l=function(){$v(dP,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},s=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",i),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function mP(e,t=globalThis==null?void 0:globalThis.document){const n=qn(e),r=w.useRef(!1);return w.useEffect(()=>{const o=i=>{i.target&&!r.current&&$v(fP,n,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function xp(){const e=new CustomEvent(wc);document.dispatchEvent(e)}function $v(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Vv(o,i):o.dispatchEvent(i)}var gP=Ud,yP=Bv,Zn=globalThis!=null&&globalThis.document?w.useLayoutEffect:()=>{},vP="Portal",Uv=w.forwardRef((e,t)=>{var a;const{container:n,...r}=e,[o,i]=w.useState(!1);Zn(()=>i(!0),[]);const s=n||o&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return s?xv.createPortal(E.jsx(Ze.div,{...r,ref:t}),s):null});Uv.displayName=vP;function xP(e,t){return w.useReducer((n,r)=>t[n][r]??n,e)}var Wd=e=>{const{present:t,children:n}=e,r=wP(t),o=typeof n=="function"?n({present:r.isPresent}):w.Children.only(n),i=jt(r.ref,SP(o));return typeof n=="function"||r.isPresent?w.cloneElement(o,{ref:i}):null};Wd.displayName="Presence";function wP(e){const[t,n]=w.useState(),r=w.useRef(null),o=w.useRef(e),i=w.useRef("none"),s=e?"mounted":"unmounted",[a,l]=xP(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return w.useEffect(()=>{const u=js(r.current);i.current=a==="mounted"?u:"none"},[a]),Zn(()=>{const u=r.current,c=o.current;if(c!==e){const f=i.current,h=js(u);e?l("MOUNT"):h==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(c&&f!==h?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,l]),Zn(()=>{if(t){let u;const c=t.ownerDocument.defaultView??window,d=h=>{const g=js(r.current).includes(h.animationName);if(h.target===t&&g&&(l("ANIMATION_END"),!o.current)){const x=t.style.animationFillMode;t.style.animationFillMode="forwards",u=c.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=x)})}},f=h=>{h.target===t&&(i.current=js(r.current))};return t.addEventListener("animationstart",f),t.addEventListener("animationcancel",d),t.addEventListener("animationend",d),()=>{c.clearTimeout(u),t.removeEventListener("animationstart",f),t.removeEventListener("animationcancel",d),t.removeEventListener("animationend",d)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:w.useCallback(u=>{r.current=u?getComputedStyle(u):null,n(u)},[])}}function js(e){return(e==null?void 0:e.animationName)||"none"}function SP(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 EP=gg[" useInsertionEffect ".trim().toString()]||Zn;function CP({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,i,s]=PP({defaultProp:t,onChange:n}),a=e!==void 0,l=a?e:o;{const c=w.useRef(e!==void 0);w.useEffect(()=>{const d=c.current;d!==a&&console.warn(`${r} is changing from ${d?"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.`),c.current=a},[a,r])}const u=w.useCallback(c=>{var d;if(a){const f=TP(c)?c(e):c;f!==e&&((d=s.current)==null||d.call(s,f))}else i(c)},[a,e,i,s]);return[l,u]}function PP({defaultProp:e,onChange:t}){const[n,r]=w.useState(e),o=w.useRef(n),i=w.useRef(t);return EP(()=>{i.current=t},[t]),w.useEffect(()=>{var s;o.current!==n&&((s=i.current)==null||s.call(i,n),o.current=n)},[n,o]),[n,r,i]}function TP(e){return typeof e=="function"}var bP=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"}),kP="VisuallyHidden",dl=w.forwardRef((e,t)=>E.jsx(Ze.span,{...e,ref:t,style:{...bP,...e.style}}));dl.displayName=kP;var AP=dl,Hd="ToastProvider",[Kd,RP,MP]=aP("Toast"),[Wv,pN]=cl("Toast",[MP]),[NP,fl]=Wv(Hd),Hv=e=>{const{__scopeToast:t,label:n="Notification",duration:r=5e3,swipeDirection:o="right",swipeThreshold:i=50,children:s}=e,[a,l]=w.useState(null),[u,c]=w.useState(0),d=w.useRef(!1),f=w.useRef(!1);return n.trim()||console.error(`Invalid prop \`label\` supplied to \`${Hd}\`. Expected non-empty \`string\`.`),E.jsx(Kd.Provider,{scope:t,children:E.jsx(NP,{scope:t,label:n,duration:r,swipeDirection:o,swipeThreshold:i,toastCount:u,viewport:a,onViewportChange:l,onToastAdd:w.useCallback(()=>c(h=>h+1),[]),onToastRemove:w.useCallback(()=>c(h=>h-1),[]),isFocusedToastEscapeKeyDownRef:d,isClosePausedRef:f,children:s})})};Hv.displayName=Hd;var Kv="ToastViewport",DP=["F8"],Sc="toast.viewportPause",Ec="toast.viewportResume",Gv=w.forwardRef((e,t)=>{const{__scopeToast:n,hotkey:r=DP,label:o="Notifications ({hotkey})",...i}=e,s=fl(Kv,n),a=RP(n),l=w.useRef(null),u=w.useRef(null),c=w.useRef(null),d=w.useRef(null),f=jt(t,d,s.onViewportChange),h=r.join("+").replace(/Key/g,"").replace(/Digit/g,""),v=s.toastCount>0;w.useEffect(()=>{const x=m=>{var y;r.length!==0&&r.every(S=>m[S]||m.code===S)&&((y=d.current)==null||y.focus())};return document.addEventListener("keydown",x),()=>document.removeEventListener("keydown",x)},[r]),w.useEffect(()=>{const x=l.current,m=d.current;if(v&&x&&m){const p=()=>{if(!s.isClosePausedRef.current){const P=new CustomEvent(Sc);m.dispatchEvent(P),s.isClosePausedRef.current=!0}},y=()=>{if(s.isClosePausedRef.current){const P=new CustomEvent(Ec);m.dispatchEvent(P),s.isClosePausedRef.current=!1}},S=P=>{!x.contains(P.relatedTarget)&&y()},C=()=>{x.contains(document.activeElement)||y()};return x.addEventListener("focusin",p),x.addEventListener("focusout",S),x.addEventListener("pointermove",p),x.addEventListener("pointerleave",C),window.addEventListener("blur",p),window.addEventListener("focus",y),()=>{x.removeEventListener("focusin",p),x.removeEventListener("focusout",S),x.removeEventListener("pointermove",p),x.removeEventListener("pointerleave",C),window.removeEventListener("blur",p),window.removeEventListener("focus",y)}}},[v,s.isClosePausedRef]);const g=w.useCallback(({tabbingDirection:x})=>{const p=a().map(y=>{const S=y.ref.current,C=[S,...HP(S)];return x==="forwards"?C:C.reverse()});return(x==="forwards"?p.reverse():p).flat()},[a]);return w.useEffect(()=>{const x=d.current;if(x){const m=p=>{var C,P,T;const y=p.altKey||p.ctrlKey||p.metaKey;if(p.key==="Tab"&&!y){const b=document.activeElement,D=p.shiftKey;if(p.target===x&&D){(C=u.current)==null||C.focus();return}const _=g({tabbingDirection:D?"backwards":"forwards"}),G=_.findIndex(L=>L===b);ru(_.slice(G+1))?p.preventDefault():D?(P=u.current)==null||P.focus():(T=c.current)==null||T.focus()}};return x.addEventListener("keydown",m),()=>x.removeEventListener("keydown",m)}},[a,g]),E.jsxs(yP,{ref:l,role:"region","aria-label":o.replace("{hotkey}",h),tabIndex:-1,style:{pointerEvents:v?void 0:"none"},children:[v&&E.jsx(Cc,{ref:u,onFocusFromOutsideViewport:()=>{const x=g({tabbingDirection:"forwards"});ru(x)}}),E.jsx(Kd.Slot,{scope:n,children:E.jsx(Ze.ol,{tabIndex:-1,...i,ref:f})}),v&&E.jsx(Cc,{ref:c,onFocusFromOutsideViewport:()=>{const x=g({tabbingDirection:"backwards"});ru(x)}})]})});Gv.displayName=Kv;var Qv="ToastFocusProxy",Cc=w.forwardRef((e,t)=>{const{__scopeToast:n,onFocusFromOutsideViewport:r,...o}=e,i=fl(Qv,n);return E.jsx(dl,{"aria-hidden":!0,tabIndex:0,...o,ref:t,style:{position:"fixed"},onFocus:s=>{var u;const a=s.relatedTarget;!((u=i.viewport)!=null&&u.contains(a))&&r()}})});Cc.displayName=Qv;var ss="Toast",OP="toast.swipeStart",LP="toast.swipeMove",jP="toast.swipeCancel",_P="toast.swipeEnd",Yv=w.forwardRef((e,t)=>{const{forceMount:n,open:r,defaultOpen:o,onOpenChange:i,...s}=e,[a,l]=CP({prop:r,defaultProp:o??!0,onChange:i,caller:ss});return E.jsx(Wd,{present:n||a,children:E.jsx(VP,{open:a,...s,ref:t,onClose:()=>l(!1),onPause:qn(e.onPause),onResume:qn(e.onResume),onSwipeStart:Ee(e.onSwipeStart,u=>{u.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:Ee(e.onSwipeMove,u=>{const{x:c,y:d}=u.detail.delta;u.currentTarget.setAttribute("data-swipe","move"),u.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${c}px`),u.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${d}px`)}),onSwipeCancel:Ee(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:Ee(e.onSwipeEnd,u=>{const{x:c,y:d}=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",`${c}px`),u.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${d}px`),l(!1)})})})});Yv.displayName=ss;var[IP,FP]=Wv(ss,{onClose(){}}),VP=w.forwardRef((e,t)=>{const{__scopeToast:n,type:r="foreground",duration:o,open:i,onClose:s,onEscapeKeyDown:a,onPause:l,onResume:u,onSwipeStart:c,onSwipeMove:d,onSwipeCancel:f,onSwipeEnd:h,...v}=e,g=fl(ss,n),[x,m]=w.useState(null),p=jt(t,L=>m(L)),y=w.useRef(null),S=w.useRef(null),C=o||g.duration,P=w.useRef(0),T=w.useRef(C),b=w.useRef(0),{onToastAdd:D,onToastRemove:N}=g,V=qn(()=>{var Q;(x==null?void 0:x.contains(document.activeElement))&&((Q=g.viewport)==null||Q.focus()),s()}),_=w.useCallback(L=>{!L||L===1/0||(window.clearTimeout(b.current),P.current=new Date().getTime(),b.current=window.setTimeout(V,L))},[V]);w.useEffect(()=>{const L=g.viewport;if(L){const Q=()=>{_(T.current),u==null||u()},$=()=>{const F=new Date().getTime()-P.current;T.current=T.current-F,window.clearTimeout(b.current),l==null||l()};return L.addEventListener(Sc,$),L.addEventListener(Ec,Q),()=>{L.removeEventListener(Sc,$),L.removeEventListener(Ec,Q)}}},[g.viewport,C,l,u,_]),w.useEffect(()=>{i&&!g.isClosePausedRef.current&&_(C)},[i,C,g.isClosePausedRef,_]),w.useEffect(()=>(D(),()=>N()),[D,N]);const G=w.useMemo(()=>x?n0(x):null,[x]);return g.viewport?E.jsxs(E.Fragment,{children:[G&&E.jsx(zP,{__scopeToast:n,role:"status","aria-live":r==="foreground"?"assertive":"polite","aria-atomic":!0,children:G}),E.jsx(IP,{scope:n,onClose:V,children:is.createPortal(E.jsx(Kd.ItemSlot,{scope:n,children:E.jsx(gP,{asChild:!0,onEscapeKeyDown:Ee(a,()=>{g.isFocusedToastEscapeKeyDownRef.current||V(),g.isFocusedToastEscapeKeyDownRef.current=!1}),children:E.jsx(Ze.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":i?"open":"closed","data-swipe-direction":g.swipeDirection,...v,ref:p,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:Ee(e.onKeyDown,L=>{L.key==="Escape"&&(a==null||a(L.nativeEvent),L.nativeEvent.defaultPrevented||(g.isFocusedToastEscapeKeyDownRef.current=!0,V()))}),onPointerDown:Ee(e.onPointerDown,L=>{L.button===0&&(y.current={x:L.clientX,y:L.clientY})}),onPointerMove:Ee(e.onPointerMove,L=>{if(!y.current)return;const Q=L.clientX-y.current.x,$=L.clientY-y.current.y,F=!!S.current,k=["left","right"].includes(g.swipeDirection),R=["left","up"].includes(g.swipeDirection)?Math.min:Math.max,j=k?R(0,Q):0,H=k?0:R(0,$),z=L.pointerType==="touch"?10:2,Y={x:j,y:H},q={originalEvent:L,delta:Y};F?(S.current=Y,_s(LP,d,q,{discrete:!1})):wp(Y,g.swipeDirection,z)?(S.current=Y,_s(OP,c,q,{discrete:!1}),L.target.setPointerCapture(L.pointerId)):(Math.abs(Q)>z||Math.abs($)>z)&&(y.current=null)}),onPointerUp:Ee(e.onPointerUp,L=>{const Q=S.current,$=L.target;if($.hasPointerCapture(L.pointerId)&&$.releasePointerCapture(L.pointerId),S.current=null,y.current=null,Q){const F=L.currentTarget,k={originalEvent:L,delta:Q};wp(Q,g.swipeDirection,g.swipeThreshold)?_s(_P,h,k,{discrete:!0}):_s(jP,f,k,{discrete:!0}),F.addEventListener("click",R=>R.preventDefault(),{once:!0})}})})})}),g.viewport)})]}):null}),zP=e=>{const{__scopeToast:t,children:n,...r}=e,o=fl(ss,t),[i,s]=w.useState(!1),[a,l]=w.useState(!1);return UP(()=>s(!0)),w.useEffect(()=>{const u=window.setTimeout(()=>l(!0),1e3);return()=>window.clearTimeout(u)},[]),a?null:E.jsx(Uv,{asChild:!0,children:E.jsx(dl,{...r,children:i&&E.jsxs(E.Fragment,{children:[o.label," ",n]})})})},BP="ToastTitle",Xv=w.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e;return E.jsx(Ze.div,{...r,ref:t})});Xv.displayName=BP;var $P="ToastDescription",qv=w.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e;return E.jsx(Ze.div,{...r,ref:t})});qv.displayName=$P;var Zv="ToastAction",Jv=w.forwardRef((e,t)=>{const{altText:n,...r}=e;return n.trim()?E.jsx(t0,{altText:n,asChild:!0,children:E.jsx(Gd,{...r,ref:t})}):(console.error(`Invalid prop \`altText\` supplied to \`${Zv}\`. Expected non-empty \`string\`.`),null)});Jv.displayName=Zv;var e0="ToastClose",Gd=w.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e,o=FP(e0,n);return E.jsx(t0,{asChild:!0,children:E.jsx(Ze.button,{type:"button",...r,ref:t,onClick:Ee(e.onClick,o.onClose)})})});Gd.displayName=e0;var t0=w.forwardRef((e,t)=>{const{__scopeToast:n,altText:r,...o}=e;return E.jsx(Ze.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":r||void 0,...o,ref:t})});function n0(e){const t=[];return Array.from(e.childNodes).forEach(r=>{if(r.nodeType===r.TEXT_NODE&&r.textContent&&t.push(r.textContent),WP(r)){const o=r.ariaHidden||r.hidden||r.style.display==="none",i=r.dataset.radixToastAnnounceExclude==="";if(!o)if(i){const s=r.dataset.radixToastAnnounceAlt;s&&t.push(s)}else t.push(...n0(r))}}),t}function _s(e,t,n,{discrete:r}){const o=n.originalEvent.currentTarget,i=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Vv(o,i):o.dispatchEvent(i)}var wp=(e,t,n=0)=>{const r=Math.abs(e.x),o=Math.abs(e.y),i=r>o;return t==="left"||t==="right"?i&&r>n:!i&&o>n};function UP(e=()=>{}){const t=qn(e);Zn(()=>{let n=0,r=0;return n=window.requestAnimationFrame(()=>r=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(n),window.cancelAnimationFrame(r)}},[t])}function WP(e){return e.nodeType===e.ELEMENT_NODE}function HP(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 ru(e){const t=document.activeElement;return e.some(n=>n===t?!0:(n.focus(),document.activeElement!==t))}var KP=Hv,r0=Gv,o0=Yv,i0=Xv,s0=qv,a0=Jv,l0=Gd;function u0(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;ttypeof e=="boolean"?`${e}`:e===0?"0":e,Ep=c0,GP=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return Ep(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:o,defaultVariants:i}=t,s=Object.keys(o).map(u=>{const c=n==null?void 0:n[u],d=i==null?void 0:i[u];if(c===null)return null;const f=Sp(c)||Sp(d);return o[u][f]}),a=n&&Object.entries(n).reduce((u,c)=>{let[d,f]=c;return f===void 0||(u[d]=f),u},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((u,c)=>{let{class:d,className:f,...h}=c;return Object.entries(h).every(v=>{let[g,x]=v;return Array.isArray(x)?x.includes({...i,...a}[g]):{...i,...a}[g]===x})?[...u,d,f]:u},[]);return Ep(e,s,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 QP=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),d0=(...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 YP={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 XP=w.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:i,iconNode:s,...a},l)=>w.createElement("svg",{ref:l,...YP,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:d0("lucide",o),...a},[...s.map(([u,c])=>w.createElement(u,c)),...Array.isArray(i)?i:[i]]));/** * @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 qt=(e,t)=>{const n=w.forwardRef(({className:r,...o},i)=>w.createElement(XP,{ref:i,iconNode:t,className:d0(`lucide-${QP(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 qP=qt("Bot",[["path",{d:"M12 8V4H8",key:"hb8ula"}],["rect",{width:"16",height:"12",x:"4",y:"8",rx:"2",key:"enze0r"}],["path",{d:"M2 14h2",key:"vft8re"}],["path",{d:"M20 14h2",key:"4cs60a"}],["path",{d:"M15 13v2",key:"1xurst"}],["path",{d:"M9 13v2",key:"rq6x2g"}]]);/** * @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 ZP=qt("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/** * @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 JP=qt("Send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]);/** * @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 eT=qt("ShieldCheck",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/** * @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 tT=qt("Shield",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]]);/** * @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 nT=qt("Sparkles",[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z",key:"4pj2yx"}],["path",{d:"M20 3v4",key:"1olli1"}],["path",{d:"M22 5h-4",key:"1gvqau"}],["path",{d:"M4 17v2",key:"vumght"}],["path",{d:"M5 18H3",key:"zchphs"}]]);/** * @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 rT=qt("TrendingUp",[["polyline",{points:"22 7 13.5 15.5 8.5 10.5 2 17",key:"126l90"}],["polyline",{points:"16 7 22 7 22 13",key:"kwv8wd"}]]);/** * @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 oT=qt("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]);/** * @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 iT=qt("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/** * @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 sT=qt("Zap",[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]]),Qd="-",aT=e=>{const t=uT(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{const a=s.split(Qd);return a[0]===""&&a.length!==1&&a.shift(),f0(a,t)||lT(s)},getConflictingClassGroupIds:(s,a)=>{const l=n[s]||[];return a&&r[s]?[...l,...r[s]]:l}}},f0=(e,t)=>{var s;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),o=r?f0(e.slice(1),r):void 0;if(o)return o;if(t.validators.length===0)return;const i=e.join(Qd);return(s=t.validators.find(({validator:a})=>a(i)))==null?void 0:s.classGroupId},Cp=/^\[(.+)\]$/,lT=e=>{if(Cp.test(e)){const t=Cp.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},uT=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return dT(Object.entries(e.classGroups),n).forEach(([i,s])=>{Pc(s,r,i,t)}),r},Pc=(e,t,n,r)=>{e.forEach(o=>{if(typeof o=="string"){const i=o===""?t:Pp(t,o);i.classGroupId=n;return}if(typeof o=="function"){if(cT(o)){Pc(o(r),t,n,r);return}t.validators.push({validator:o,classGroupId:n});return}Object.entries(o).forEach(([i,s])=>{Pc(s,Pp(t,i),n,r)})})},Pp=(e,t)=>{let n=e;return t.split(Qd).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},cT=e=>e.isThemeGetter,dT=(e,t)=>t?e.map(([n,r])=>{const o=r.map(i=>typeof i=="string"?t+i:typeof i=="object"?Object.fromEntries(Object.entries(i).map(([s,a])=>[t+s,a])):i);return[n,o]}):e,fT=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const o=(i,s)=>{n.set(i,s),t++,t>e&&(t=0,r=n,n=new Map)};return{get(i){let s=n.get(i);if(s!==void 0)return s;if((s=r.get(i))!==void 0)return o(i,s),s},set(i,s){n.has(i)?n.set(i,s):o(i,s)}}},h0="!",hT=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,o=t[0],i=t.length,s=a=>{const l=[];let u=0,c=0,d;for(let x=0;xc?d-c:void 0;return{modifiers:l,hasImportantModifier:h,baseClassName:v,maybePostfixModifierPosition:g}};return n?a=>n({className:a,parseClassName:s}):s},pT=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},mT=e=>({cache:fT(e.cacheSize),parseClassName:hT(e),...aT(e)}),gT=/\s+/,yT=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o}=t,i=[],s=e.trim().split(gT);let a="";for(let l=s.length-1;l>=0;l-=1){const u=s[l],{modifiers:c,hasImportantModifier:d,baseClassName:f,maybePostfixModifierPosition:h}=n(u);let v=!!h,g=r(v?f.substring(0,h):f);if(!g){if(!v){a=u+(a.length>0?" "+a:a);continue}if(g=r(f),!g){a=u+(a.length>0?" "+a:a);continue}v=!1}const x=pT(c).join(":"),m=d?x+h0:x,p=m+g;if(i.includes(p))continue;i.push(p);const y=o(g,v);for(let S=0;S0?" "+a:a)}return a};function vT(){let e=0,t,n,r="";for(;e{if(typeof e=="string")return e;let t,n="";for(let r=0;rd(c),e());return n=mT(u),r=n.cache.get,o=n.cache.set,i=a,a(l)}function a(l){const u=r(l);if(u)return u;const c=yT(l,n);return o(l,c),c}return function(){return i(vT.apply(null,arguments))}}const oe=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},m0=/^\[(?:([a-z-]+):)?(.+)\]$/i,wT=/^\d+\/\d+$/,ST=new Set(["px","full","screen"]),ET=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,CT=/\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$/,PT=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,TT=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,bT=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Jt=e=>go(e)||ST.has(e)||wT.test(e),Tn=e=>Bo(e,"length",LT),go=e=>!!e&&!Number.isNaN(Number(e)),ou=e=>Bo(e,"number",go),ni=e=>!!e&&Number.isInteger(Number(e)),kT=e=>e.endsWith("%")&&go(e.slice(0,-1)),K=e=>m0.test(e),bn=e=>ET.test(e),AT=new Set(["length","size","percentage"]),RT=e=>Bo(e,AT,g0),MT=e=>Bo(e,"position",g0),NT=new Set(["image","url"]),DT=e=>Bo(e,NT,_T),OT=e=>Bo(e,"",jT),ri=()=>!0,Bo=(e,t,n)=>{const r=m0.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},LT=e=>CT.test(e)&&!PT.test(e),g0=()=>!1,jT=e=>TT.test(e),_T=e=>bT.test(e),IT=()=>{const e=oe("colors"),t=oe("spacing"),n=oe("blur"),r=oe("brightness"),o=oe("borderColor"),i=oe("borderRadius"),s=oe("borderSpacing"),a=oe("borderWidth"),l=oe("contrast"),u=oe("grayscale"),c=oe("hueRotate"),d=oe("invert"),f=oe("gap"),h=oe("gradientColorStops"),v=oe("gradientColorStopPositions"),g=oe("inset"),x=oe("margin"),m=oe("opacity"),p=oe("padding"),y=oe("saturate"),S=oe("scale"),C=oe("sepia"),P=oe("skew"),T=oe("space"),b=oe("translate"),D=()=>["auto","contain","none"],N=()=>["auto","hidden","clip","visible","scroll"],V=()=>["auto",K,t],_=()=>[K,t],G=()=>["",Jt,Tn],L=()=>["auto",go,K],Q=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],$=()=>["solid","dashed","dotted","double","none"],F=()=>["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"],R=()=>["","0",K],j=()=>["auto","avoid","all","avoid-page","page","left","right","column"],H=()=>[go,K];return{cacheSize:500,separator:":",theme:{colors:[ri],spacing:[Jt,Tn],blur:["none","",bn,K],brightness:H(),borderColor:[e],borderRadius:["none","","full",bn,K],borderSpacing:_(),borderWidth:G(),contrast:H(),grayscale:R(),hueRotate:H(),invert:R(),gap:_(),gradientColorStops:[e],gradientColorStopPositions:[kT,Tn],inset:V(),margin:V(),opacity:H(),padding:_(),saturate:H(),scale:H(),sepia:R(),skew:H(),space:_(),translate:_()},classGroups:{aspect:[{aspect:["auto","square","video",K]}],container:["container"],columns:[{columns:[bn]}],"break-after":[{"break-after":j()}],"break-before":[{"break-before":j()}],"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:[...Q(),K]}],overflow:[{overflow:N()}],"overflow-x":[{"overflow-x":N()}],"overflow-y":[{"overflow-y":N()}],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",ni,K]}],basis:[{basis:V()}],"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:R()}],shrink:[{shrink:R()}],order:[{order:["first","last","none",ni,K]}],"grid-cols":[{"grid-cols":[ri]}],"col-start-end":[{col:["auto",{span:["full",ni,K]},K]}],"col-start":[{"col-start":L()}],"col-end":[{"col-end":L()}],"grid-rows":[{"grid-rows":[ri]}],"row-start-end":[{row:["auto",{span:[ni,K]},K]}],"row-start":[{"row-start":L()}],"row-end":[{"row-end":L()}],"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:[f]}],"gap-x":[{"gap-x":[f]}],"gap-y":[{"gap-y":[f]}],"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:[p]}],px:[{px:[p]}],py:[{py:[p]}],ps:[{ps:[p]}],pe:[{pe:[p]}],pt:[{pt:[p]}],pr:[{pr:[p]}],pb:[{pb:[p]}],pl:[{pl:[p]}],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":[T]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[T]}],"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,Tn]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",ou]}],"font-family":[{font:[ri]}],"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",go,ou]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Jt,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":[m]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[m]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...$(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Jt,Tn]}],"underline-offset":[{"underline-offset":["auto",Jt,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":[m]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...Q(),MT]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",RT]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},DT]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[v]}],"gradient-via-pos":[{via:[v]}],"gradient-to-pos":[{to:[v]}],"gradient-from":[{from:[h]}],"gradient-via":[{via:[h]}],"gradient-to":[{to:[h]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"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":[m]}],"border-style":[{border:[...$(),"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":[m]}],"divide-style":[{divide:$()}],"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:["",...$()]}],"outline-offset":[{"outline-offset":[Jt,K]}],"outline-w":[{outline:[Jt,Tn]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:G()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[m]}],"ring-offset-w":[{"ring-offset":[Jt,Tn]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",bn,OT]}],"shadow-color":[{shadow:[ri]}],opacity:[{opacity:[m]}],"mix-blend":[{"mix-blend":[...F(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":F()}],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":[c]}],invert:[{invert:[d]}],saturate:[{saturate:[y]}],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":[c]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[m]}],"backdrop-saturate":[{"backdrop-saturate":[y]}],"backdrop-sepia":[{"backdrop-sepia":[C]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[s]}],"border-spacing-x":[{"border-spacing-x":[s]}],"border-spacing-y":[{"border-spacing-y":[s]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",K]}],duration:[{duration:H()}],ease:[{ease:["linear","in","out","in-out",K]}],delay:[{delay:H()}],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:[ni,K]}],"translate-x":[{"translate-x":[b]}],"translate-y":[{"translate-y":[b]}],"skew-x":[{"skew-x":[P]}],"skew-y":[{"skew-y":[P]}],"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:[Jt,Tn,ou]}],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"]}}},FT=xT(IT);function _r(...e){return FT(c0(e))}const VT=KP,y0=w.forwardRef(({className:e,...t},n)=>E.jsx(r0,{ref:n,className:_r("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}));y0.displayName=r0.displayName;const zT=GP("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"}}),v0=w.forwardRef(({className:e,variant:t,...n},r)=>E.jsx(o0,{ref:r,className:_r(zT({variant:t}),e),...n}));v0.displayName=o0.displayName;const BT=w.forwardRef(({className:e,...t},n)=>E.jsx(a0,{ref:n,className:_r("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}));BT.displayName=a0.displayName;const x0=w.forwardRef(({className:e,...t},n)=>E.jsx(l0,{ref:n,className:_r("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:E.jsx(iT,{className:"h-4 w-4"})}));x0.displayName=l0.displayName;const w0=w.forwardRef(({className:e,...t},n)=>E.jsx(i0,{ref:n,className:_r("text-sm font-semibold",e),...t}));w0.displayName=i0.displayName;const S0=w.forwardRef(({className:e,...t},n)=>E.jsx(s0,{ref:n,className:_r("text-sm opacity-90",e),...t}));S0.displayName=s0.displayName;function $T(){const{toasts:e}=eP();return E.jsxs(VT,{children:[e.map(function({id:t,title:n,description:r,action:o,...i}){return E.jsxs(v0,{...i,children:[E.jsxs("div",{className:"grid gap-1",children:[n&&E.jsx(w0,{children:n}),r&&E.jsx(S0,{children:r})]}),o,E.jsx(x0,{})]},t)}),E.jsx(y0,{})]})}const UT=["top","right","bottom","left"],Jn=Math.min,et=Math.max,Da=Math.round,Is=Math.floor,Gt=e=>({x:e,y:e}),WT={left:"right",right:"left",bottom:"top",top:"bottom"},HT={start:"end",end:"start"};function Tc(e,t,n){return et(e,Jn(t,n))}function pn(e,t){return typeof e=="function"?e(t):e}function mn(e){return e.split("-")[0]}function $o(e){return e.split("-")[1]}function Yd(e){return e==="x"?"y":"x"}function Xd(e){return e==="y"?"height":"width"}const KT=new Set(["top","bottom"]);function Wt(e){return KT.has(mn(e))?"y":"x"}function qd(e){return Yd(Wt(e))}function GT(e,t,n){n===void 0&&(n=!1);const r=$o(e),o=qd(e),i=Xd(o);let s=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(s=Oa(s)),[s,Oa(s)]}function QT(e){const t=Oa(e);return[bc(e),t,bc(t)]}function bc(e){return e.replace(/start|end/g,t=>HT[t])}const Tp=["left","right"],bp=["right","left"],YT=["top","bottom"],XT=["bottom","top"];function qT(e,t,n){switch(e){case"top":case"bottom":return n?t?bp:Tp:t?Tp:bp;case"left":case"right":return t?YT:XT;default:return[]}}function ZT(e,t,n,r){const o=$o(e);let i=qT(mn(e),n==="start",r);return o&&(i=i.map(s=>s+"-"+o),t&&(i=i.concat(i.map(bc)))),i}function Oa(e){return e.replace(/left|right|bottom|top/g,t=>WT[t])}function JT(e){return{top:0,right:0,bottom:0,left:0,...e}}function E0(e){return typeof e!="number"?JT(e):{top:e,right:e,bottom:e,left:e}}function La(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 kp(e,t,n){let{reference:r,floating:o}=e;const i=Wt(t),s=qd(t),a=Xd(s),l=mn(t),u=i==="y",c=r.x+r.width/2-o.width/2,d=r.y+r.height/2-o.height/2,f=r[a]/2-o[a]/2;let h;switch(l){case"top":h={x:c,y:r.y-o.height};break;case"bottom":h={x:c,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:d};break;case"left":h={x:r.x-o.width,y:d};break;default:h={x:r.x,y:r.y}}switch($o(t)){case"start":h[s]-=f*(n&&u?-1:1);break;case"end":h[s]+=f*(n&&u?-1:1);break}return h}const eb=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:s}=n,a=i.filter(Boolean),l=await(s.isRTL==null?void 0:s.isRTL(t));let u=await s.getElementRects({reference:e,floating:t,strategy:o}),{x:c,y:d}=kp(u,r,l),f=r,h={},v=0;for(let g=0;g({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:i,platform:s,elements:a,middlewareData:l}=t,{element:u,padding:c=0}=pn(e,t)||{};if(u==null)return{};const d=E0(c),f={x:n,y:r},h=qd(o),v=Xd(h),g=await s.getDimensions(u),x=h==="y",m=x?"top":"left",p=x?"bottom":"right",y=x?"clientHeight":"clientWidth",S=i.reference[v]+i.reference[h]-f[h]-i.floating[v],C=f[h]-i.reference[h],P=await(s.getOffsetParent==null?void 0:s.getOffsetParent(u));let T=P?P[y]:0;(!T||!await(s.isElement==null?void 0:s.isElement(P)))&&(T=a.floating[y]||i.floating[v]);const b=S/2-C/2,D=T/2-g[v]/2-1,N=Jn(d[m],D),V=Jn(d[p],D),_=N,G=T-g[v]-V,L=T/2-g[v]/2+b,Q=Tc(_,L,G),$=!l.arrow&&$o(o)!=null&&L!==Q&&i.reference[v]/2-(L<_?N:V)-g[v]/2<0,F=$?L<_?L-_:L-G:0;return{[h]:f[h]+F,data:{[h]:Q,centerOffset:L-Q-F,...$&&{alignmentOffset:F}},reset:$}}}),nb=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:i,rects:s,initialPlacement:a,platform:l,elements:u}=t,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:v="none",flipAlignment:g=!0,...x}=pn(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};const m=mn(o),p=Wt(a),y=mn(a)===a,S=await(l.isRTL==null?void 0:l.isRTL(u.floating)),C=f||(y||!g?[Oa(a)]:QT(a)),P=v!=="none";!f&&P&&C.push(...ZT(a,g,v,S));const T=[a,...C],b=await Hi(t,x),D=[];let N=((r=i.flip)==null?void 0:r.overflows)||[];if(c&&D.push(b[m]),d){const L=GT(o,s,S);D.push(b[L[0]],b[L[1]])}if(N=[...N,{placement:o,overflows:D}],!D.every(L=>L<=0)){var V,_;const L=(((V=i.flip)==null?void 0:V.index)||0)+1,Q=T[L];if(Q&&(!(d==="alignment"?p!==Wt(Q):!1)||N.every(k=>k.overflows[0]>0&&Wt(k.placement)===p)))return{data:{index:L,overflows:N},reset:{placement:Q}};let $=(_=N.filter(F=>F.overflows[0]<=0).sort((F,k)=>F.overflows[1]-k.overflows[1])[0])==null?void 0:_.placement;if(!$)switch(h){case"bestFit":{var G;const F=(G=N.filter(k=>{if(P){const R=Wt(k.placement);return R===p||R==="y"}return!0}).map(k=>[k.placement,k.overflows.filter(R=>R>0).reduce((R,j)=>R+j,0)]).sort((k,R)=>k[1]-R[1])[0])==null?void 0:G[0];F&&($=F);break}case"initialPlacement":$=a;break}if(o!==$)return{reset:{placement:$}}}return{}}}};function Ap(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Rp(e){return UT.some(t=>e[t]>=0)}const rb=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=pn(e,t);switch(r){case"referenceHidden":{const i=await Hi(t,{...o,elementContext:"reference"}),s=Ap(i,n.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:Rp(s)}}}case"escaped":{const i=await Hi(t,{...o,altBoundary:!0}),s=Ap(i,n.floating);return{data:{escapedOffsets:s,escaped:Rp(s)}}}default:return{}}}}},C0=new Set(["left","top"]);async function ob(e,t){const{placement:n,platform:r,elements:o}=e,i=await(r.isRTL==null?void 0:r.isRTL(o.floating)),s=mn(n),a=$o(n),l=Wt(n)==="y",u=C0.has(s)?-1:1,c=i&&l?-1:1,d=pn(t,e);let{mainAxis:f,crossAxis:h,alignmentAxis:v}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&typeof v=="number"&&(h=a==="end"?v*-1:v),l?{x:h*c,y:f*u}:{x:f*u,y:h*c}}const ib=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:i,placement:s,middlewareData:a}=t,l=await ob(t,e);return s===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:o+l.x,y:i+l.y,data:{...l,placement:s}}}}},sb=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:i=!0,crossAxis:s=!1,limiter:a={fn:x=>{let{x:m,y:p}=x;return{x:m,y:p}}},...l}=pn(e,t),u={x:n,y:r},c=await Hi(t,l),d=Wt(mn(o)),f=Yd(d);let h=u[f],v=u[d];if(i){const x=f==="y"?"top":"left",m=f==="y"?"bottom":"right",p=h+c[x],y=h-c[m];h=Tc(p,h,y)}if(s){const x=d==="y"?"top":"left",m=d==="y"?"bottom":"right",p=v+c[x],y=v-c[m];v=Tc(p,v,y)}const g=a.fn({...t,[f]:h,[d]:v});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[f]:i,[d]:s}}}}}},ab=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:i,middlewareData:s}=t,{offset:a=0,mainAxis:l=!0,crossAxis:u=!0}=pn(e,t),c={x:n,y:r},d=Wt(o),f=Yd(d);let h=c[f],v=c[d];const g=pn(a,t),x=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(l){const y=f==="y"?"height":"width",S=i.reference[f]-i.floating[y]+x.mainAxis,C=i.reference[f]+i.reference[y]-x.mainAxis;hC&&(h=C)}if(u){var m,p;const y=f==="y"?"width":"height",S=C0.has(mn(o)),C=i.reference[d]-i.floating[y]+(S&&((m=s.offset)==null?void 0:m[d])||0)+(S?0:x.crossAxis),P=i.reference[d]+i.reference[y]+(S?0:((p=s.offset)==null?void 0:p[d])||0)-(S?x.crossAxis:0);vP&&(v=P)}return{[f]:h,[d]:v}}}},lb=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:i,platform:s,elements:a}=t,{apply:l=()=>{},...u}=pn(e,t),c=await Hi(t,u),d=mn(o),f=$o(o),h=Wt(o)==="y",{width:v,height:g}=i.floating;let x,m;d==="top"||d==="bottom"?(x=d,m=f===(await(s.isRTL==null?void 0:s.isRTL(a.floating))?"start":"end")?"left":"right"):(m=d,x=f==="end"?"top":"bottom");const p=g-c.top-c.bottom,y=v-c.left-c.right,S=Jn(g-c[x],p),C=Jn(v-c[m],y),P=!t.middlewareData.shift;let T=S,b=C;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(b=y),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(T=p),P&&!f){const N=et(c.left,0),V=et(c.right,0),_=et(c.top,0),G=et(c.bottom,0);h?b=v-2*(N!==0||V!==0?N+V:et(c.left,c.right)):T=g-2*(_!==0||G!==0?_+G:et(c.top,c.bottom))}await l({...t,availableWidth:b,availableHeight:T});const D=await s.getDimensions(a.floating);return v!==D.width||g!==D.height?{reset:{rects:!0}}:{}}}};function hl(){return typeof window<"u"}function Uo(e){return P0(e)?(e.nodeName||"").toLowerCase():"#document"}function rt(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Zt(e){var t;return(t=(P0(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function P0(e){return hl()?e instanceof Node||e instanceof rt(e).Node:!1}function _t(e){return hl()?e instanceof Element||e instanceof rt(e).Element:!1}function Xt(e){return hl()?e instanceof HTMLElement||e instanceof rt(e).HTMLElement:!1}function Mp(e){return!hl()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof rt(e).ShadowRoot}const ub=new Set(["inline","contents"]);function as(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=It(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!ub.has(o)}const cb=new Set(["table","td","th"]);function db(e){return cb.has(Uo(e))}const fb=[":popover-open",":modal"];function pl(e){return fb.some(t=>{try{return e.matches(t)}catch{return!1}})}const hb=["transform","translate","scale","rotate","perspective"],pb=["transform","translate","scale","rotate","perspective","filter"],mb=["paint","layout","strict","content"];function Zd(e){const t=Jd(),n=_t(e)?It(e):e;return hb.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)||pb.some(r=>(n.willChange||"").includes(r))||mb.some(r=>(n.contain||"").includes(r))}function gb(e){let t=er(e);for(;Xt(t)&&!Oo(t);){if(Zd(t))return t;if(pl(t))return null;t=er(t)}return null}function Jd(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const yb=new Set(["html","body","#document"]);function Oo(e){return yb.has(Uo(e))}function It(e){return rt(e).getComputedStyle(e)}function ml(e){return _t(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function er(e){if(Uo(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Mp(e)&&e.host||Zt(e);return Mp(t)?t.host:t}function T0(e){const t=er(e);return Oo(t)?e.ownerDocument?e.ownerDocument.body:e.body:Xt(t)&&as(t)?t:T0(t)}function Ki(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=T0(e),i=o===((r=e.ownerDocument)==null?void 0:r.body),s=rt(o);if(i){const a=kc(s);return t.concat(s,s.visualViewport||[],as(o)?o:[],a&&n?Ki(a):[])}return t.concat(o,Ki(o,[],n))}function kc(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function b0(e){const t=It(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Xt(e),i=o?e.offsetWidth:n,s=o?e.offsetHeight:r,a=Da(n)!==i||Da(r)!==s;return a&&(n=i,r=s),{width:n,height:r,$:a}}function ef(e){return _t(e)?e:e.contextElement}function yo(e){const t=ef(e);if(!Xt(t))return Gt(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:i}=b0(t);let s=(i?Da(n.width):n.width)/r,a=(i?Da(n.height):n.height)/o;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}const vb=Gt(0);function k0(e){const t=rt(e);return!Jd()||!t.visualViewport?vb:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function xb(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==rt(e)?!1:t}function Or(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),i=ef(e);let s=Gt(1);t&&(r?_t(r)&&(s=yo(r)):s=yo(e));const a=xb(i,n,r)?k0(i):Gt(0);let l=(o.left+a.x)/s.x,u=(o.top+a.y)/s.y,c=o.width/s.x,d=o.height/s.y;if(i){const f=rt(i),h=r&&_t(r)?rt(r):r;let v=f,g=kc(v);for(;g&&r&&h!==v;){const x=yo(g),m=g.getBoundingClientRect(),p=It(g),y=m.left+(g.clientLeft+parseFloat(p.paddingLeft))*x.x,S=m.top+(g.clientTop+parseFloat(p.paddingTop))*x.y;l*=x.x,u*=x.y,c*=x.x,d*=x.y,l+=y,u+=S,v=rt(g),g=kc(v)}}return La({width:c,height:d,x:l,y:u})}function tf(e,t){const n=ml(e).scrollLeft;return t?t.left+n:Or(Zt(e)).left+n}function A0(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-(n?0:tf(e,r)),i=r.top+t.scrollTop;return{x:o,y:i}}function wb(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const i=o==="fixed",s=Zt(r),a=t?pl(t.floating):!1;if(r===s||a&&i)return n;let l={scrollLeft:0,scrollTop:0},u=Gt(1);const c=Gt(0),d=Xt(r);if((d||!d&&!i)&&((Uo(r)!=="body"||as(s))&&(l=ml(r)),Xt(r))){const h=Or(r);u=yo(r),c.x=h.x+r.clientLeft,c.y=h.y+r.clientTop}const f=s&&!d&&!i?A0(s,l,!0):Gt(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-l.scrollLeft*u.x+c.x+f.x,y:n.y*u.y-l.scrollTop*u.y+c.y+f.y}}function Sb(e){return Array.from(e.getClientRects())}function Eb(e){const t=Zt(e),n=ml(e),r=e.ownerDocument.body,o=et(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=et(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let s=-n.scrollLeft+tf(e);const a=-n.scrollTop;return It(r).direction==="rtl"&&(s+=et(t.clientWidth,r.clientWidth)-o),{width:o,height:i,x:s,y:a}}function Cb(e,t){const n=rt(e),r=Zt(e),o=n.visualViewport;let i=r.clientWidth,s=r.clientHeight,a=0,l=0;if(o){i=o.width,s=o.height;const u=Jd();(!u||u&&t==="fixed")&&(a=o.offsetLeft,l=o.offsetTop)}return{width:i,height:s,x:a,y:l}}const Pb=new Set(["absolute","fixed"]);function Tb(e,t){const n=Or(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,i=Xt(e)?yo(e):Gt(1),s=e.clientWidth*i.x,a=e.clientHeight*i.y,l=o*i.x,u=r*i.y;return{width:s,height:a,x:l,y:u}}function Np(e,t,n){let r;if(t==="viewport")r=Cb(e,n);else if(t==="document")r=Eb(Zt(e));else if(_t(t))r=Tb(t,n);else{const o=k0(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return La(r)}function R0(e,t){const n=er(e);return n===t||!_t(n)||Oo(n)?!1:It(n).position==="fixed"||R0(n,t)}function bb(e,t){const n=t.get(e);if(n)return n;let r=Ki(e,[],!1).filter(a=>_t(a)&&Uo(a)!=="body"),o=null;const i=It(e).position==="fixed";let s=i?er(e):e;for(;_t(s)&&!Oo(s);){const a=It(s),l=Zd(s);!l&&a.position==="fixed"&&(o=null),(i?!l&&!o:!l&&a.position==="static"&&!!o&&Pb.has(o.position)||as(s)&&!l&&R0(e,s))?r=r.filter(c=>c!==s):o=a,s=er(s)}return t.set(e,r),r}function kb(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const s=[...n==="clippingAncestors"?pl(t)?[]:bb(t,this._c):[].concat(n),r],a=s[0],l=s.reduce((u,c)=>{const d=Np(t,c,o);return u.top=et(d.top,u.top),u.right=Jn(d.right,u.right),u.bottom=Jn(d.bottom,u.bottom),u.left=et(d.left,u.left),u},Np(t,a,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function Ab(e){const{width:t,height:n}=b0(e);return{width:t,height:n}}function Rb(e,t,n){const r=Xt(t),o=Zt(t),i=n==="fixed",s=Or(e,!0,i,t);let a={scrollLeft:0,scrollTop:0};const l=Gt(0);function u(){l.x=tf(o)}if(r||!r&&!i)if((Uo(t)!=="body"||as(o))&&(a=ml(t)),r){const h=Or(t,!0,i,t);l.x=h.x+t.clientLeft,l.y=h.y+t.clientTop}else o&&u();i&&!r&&o&&u();const c=o&&!r&&!i?A0(o,a):Gt(0),d=s.left+a.scrollLeft-l.x-c.x,f=s.top+a.scrollTop-l.y-c.y;return{x:d,y:f,width:s.width,height:s.height}}function iu(e){return It(e).position==="static"}function Dp(e,t){if(!Xt(e)||It(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Zt(e)===n&&(n=n.ownerDocument.body),n}function M0(e,t){const n=rt(e);if(pl(e))return n;if(!Xt(e)){let o=er(e);for(;o&&!Oo(o);){if(_t(o)&&!iu(o))return o;o=er(o)}return n}let r=Dp(e,t);for(;r&&db(r)&&iu(r);)r=Dp(r,t);return r&&Oo(r)&&iu(r)&&!Zd(r)?n:r||gb(e)||n}const Mb=async function(e){const t=this.getOffsetParent||M0,n=this.getDimensions,r=await n(e.floating);return{reference:Rb(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Nb(e){return It(e).direction==="rtl"}const Db={convertOffsetParentRelativeRectToViewportRelativeRect:wb,getDocumentElement:Zt,getClippingRect:kb,getOffsetParent:M0,getElementRects:Mb,getClientRects:Sb,getDimensions:Ab,getScale:yo,isElement:_t,isRTL:Nb};function N0(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Ob(e,t){let n=null,r;const o=Zt(e);function i(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function s(a,l){a===void 0&&(a=!1),l===void 0&&(l=1),i();const u=e.getBoundingClientRect(),{left:c,top:d,width:f,height:h}=u;if(a||t(),!f||!h)return;const v=Is(d),g=Is(o.clientWidth-(c+f)),x=Is(o.clientHeight-(d+h)),m=Is(c),y={rootMargin:-v+"px "+-g+"px "+-x+"px "+-m+"px",threshold:et(0,Jn(1,l))||1};let S=!0;function C(P){const T=P[0].intersectionRatio;if(T!==l){if(!S)return s();T?s(!1,T):r=setTimeout(()=>{s(!1,1e-7)},1e3)}T===1&&!N0(u,e.getBoundingClientRect())&&s(),S=!1}try{n=new IntersectionObserver(C,{...y,root:o.ownerDocument})}catch{n=new IntersectionObserver(C,y)}n.observe(e)}return s(!0),i}function Lb(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,u=ef(e),c=o||i?[...u?Ki(u):[],...Ki(t)]:[];c.forEach(m=>{o&&m.addEventListener("scroll",n,{passive:!0}),i&&m.addEventListener("resize",n)});const d=u&&a?Ob(u,n):null;let f=-1,h=null;s&&(h=new ResizeObserver(m=>{let[p]=m;p&&p.target===u&&h&&(h.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var y;(y=h)==null||y.observe(t)})),n()}),u&&!l&&h.observe(u),h.observe(t));let v,g=l?Or(e):null;l&&x();function x(){const m=Or(e);g&&!N0(g,m)&&n(),g=m,v=requestAnimationFrame(x)}return n(),()=>{var m;c.forEach(p=>{o&&p.removeEventListener("scroll",n),i&&p.removeEventListener("resize",n)}),d==null||d(),(m=h)==null||m.disconnect(),h=null,l&&cancelAnimationFrame(v)}}const jb=ib,_b=sb,Ib=nb,Fb=lb,Vb=rb,Op=tb,zb=ab,Bb=(e,t,n)=>{const r=new Map,o={platform:Db,...n},i={...o.platform,_c:r};return eb(e,t,{...o,platform:i})};var $b=typeof document<"u",Ub=function(){},ta=$b?w.useLayoutEffect:Ub;function ja(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(!ja(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 i=o[r];if(!(i==="_owner"&&e.$$typeof)&&!ja(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function D0(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Lp(e,t){const n=D0(e);return Math.round(t*n)/n}function su(e){const t=w.useRef(e);return ta(()=>{t.current=e}),t}function Wb(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:i,floating:s}={},transform:a=!0,whileElementsMounted:l,open:u}=e,[c,d]=w.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,h]=w.useState(r);ja(f,r)||h(r);const[v,g]=w.useState(null),[x,m]=w.useState(null),p=w.useCallback(k=>{k!==P.current&&(P.current=k,g(k))},[]),y=w.useCallback(k=>{k!==T.current&&(T.current=k,m(k))},[]),S=i||v,C=s||x,P=w.useRef(null),T=w.useRef(null),b=w.useRef(c),D=l!=null,N=su(l),V=su(o),_=su(u),G=w.useCallback(()=>{if(!P.current||!T.current)return;const k={placement:t,strategy:n,middleware:f};V.current&&(k.platform=V.current),Bb(P.current,T.current,k).then(R=>{const j={...R,isPositioned:_.current!==!1};L.current&&!ja(b.current,j)&&(b.current=j,is.flushSync(()=>{d(j)}))})},[f,t,n,V,_]);ta(()=>{u===!1&&b.current.isPositioned&&(b.current.isPositioned=!1,d(k=>({...k,isPositioned:!1})))},[u]);const L=w.useRef(!1);ta(()=>(L.current=!0,()=>{L.current=!1}),[]),ta(()=>{if(S&&(P.current=S),C&&(T.current=C),S&&C){if(N.current)return N.current(S,C,G);G()}},[S,C,G,N,D]);const Q=w.useMemo(()=>({reference:P,floating:T,setReference:p,setFloating:y}),[p,y]),$=w.useMemo(()=>({reference:S,floating:C}),[S,C]),F=w.useMemo(()=>{const k={position:n,left:0,top:0};if(!$.floating)return k;const R=Lp($.floating,c.x),j=Lp($.floating,c.y);return a?{...k,transform:"translate("+R+"px, "+j+"px)",...D0($.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:R,top:j}},[n,a,$.floating,c.x,c.y]);return w.useMemo(()=>({...c,update:G,refs:Q,elements:$,floatingStyles:F}),[c,G,Q,$,F])}const Hb=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?Op({element:r.current,padding:o}).fn(n):{}:r?Op({element:r,padding:o}).fn(n):{}}}},Kb=(e,t)=>({...jb(e),options:[e,t]}),Gb=(e,t)=>({..._b(e),options:[e,t]}),Qb=(e,t)=>({...zb(e),options:[e,t]}),Yb=(e,t)=>({...Ib(e),options:[e,t]}),Xb=(e,t)=>({...Fb(e),options:[e,t]}),qb=(e,t)=>({...Vb(e),options:[e,t]}),Zb=(e,t)=>({...Hb(e),options:[e,t]});var Jb="Arrow",O0=w.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...i}=e;return E.jsx(Ze.svg,{...i,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:E.jsx("polygon",{points:"0,0 30,0 15,10"})})});O0.displayName=Jb;var ek=O0;function tk(e){const[t,n]=w.useState(void 0);return Zn(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const i=o[0];let s,a;if("borderBoxSize"in i){const l=i.borderBoxSize,u=Array.isArray(l)?l[0]:l;s=u.inlineSize,a=u.blockSize}else s=e.offsetWidth,a=e.offsetHeight;n({width:s,height:a})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var L0="Popper",[j0,_0]=cl(L0),[mN,I0]=j0(L0),F0="PopperAnchor",V0=w.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,i=I0(F0,n),s=w.useRef(null),a=jt(t,s);return w.useEffect(()=>{i.onAnchorChange((r==null?void 0:r.current)||s.current)}),r?null:E.jsx(Ze.div,{...o,ref:a})});V0.displayName=F0;var nf="PopperContent",[nk,rk]=j0(nf),z0=w.forwardRef((e,t)=>{var ee,Fr,vn,ar,xn,Vr;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:i="center",alignOffset:s=0,arrowPadding:a=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:c=0,sticky:d="partial",hideWhenDetached:f=!1,updatePositionStrategy:h="optimized",onPlaced:v,...g}=e,x=I0(nf,n),[m,p]=w.useState(null),y=jt(t,wn=>p(wn)),[S,C]=w.useState(null),P=tk(S),T=(P==null?void 0:P.width)??0,b=(P==null?void 0:P.height)??0,D=r+(i!=="center"?"-"+i:""),N=typeof c=="number"?c:{top:0,right:0,bottom:0,left:0,...c},V=Array.isArray(u)?u:[u],_=V.length>0,G={padding:N,boundary:V.filter(ik),altBoundary:_},{refs:L,floatingStyles:Q,placement:$,isPositioned:F,middlewareData:k}=Wb({strategy:"fixed",placement:D,whileElementsMounted:(...wn)=>Lb(...wn,{animationFrame:h==="always"}),elements:{reference:x.anchor},middleware:[Kb({mainAxis:o+b,alignmentAxis:s}),l&&Gb({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?Qb():void 0,...G}),l&&Yb({...G}),Xb({...G,apply:({elements:wn,rects:fs,availableWidth:Cl,availableHeight:hs})=>{const{width:Pl,height:Ko}=fs.reference,zr=wn.floating.style;zr.setProperty("--radix-popper-available-width",`${Cl}px`),zr.setProperty("--radix-popper-available-height",`${hs}px`),zr.setProperty("--radix-popper-anchor-width",`${Pl}px`),zr.setProperty("--radix-popper-anchor-height",`${Ko}px`)}}),S&&Zb({element:S,padding:a}),sk({arrowWidth:T,arrowHeight:b}),f&&qb({strategy:"referenceHidden",...G})]}),[R,j]=U0($),H=qn(v);Zn(()=>{F&&(H==null||H())},[F,H]);const z=(ee=k.arrow)==null?void 0:ee.x,Y=(Fr=k.arrow)==null?void 0:Fr.y,q=((vn=k.arrow)==null?void 0:vn.centerOffset)!==0,[xe,Me]=w.useState();return Zn(()=>{m&&Me(window.getComputedStyle(m).zIndex)},[m]),E.jsx("div",{ref:L.setFloating,"data-radix-popper-content-wrapper":"",style:{...Q,transform:F?Q.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:xe,"--radix-popper-transform-origin":[(ar=k.transformOrigin)==null?void 0:ar.x,(xn=k.transformOrigin)==null?void 0:xn.y].join(" "),...((Vr=k.hide)==null?void 0:Vr.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:E.jsx(nk,{scope:n,placedSide:R,onArrowChange:C,arrowX:z,arrowY:Y,shouldHideArrow:q,children:E.jsx(Ze.div,{"data-side":R,"data-align":j,...g,ref:y,style:{...g.style,animation:F?void 0:"none"}})})})});z0.displayName=nf;var B0="PopperArrow",ok={top:"bottom",right:"left",bottom:"top",left:"right"},$0=w.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,i=rk(B0,r),s=ok[i.placedSide];return E.jsx("span",{ref:i.onArrowChange,style:{position:"absolute",left:i.arrowX,top:i.arrowY,[s]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[i.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[i.placedSide],visibility:i.shouldHideArrow?"hidden":void 0},children:E.jsx(ek,{...o,ref:n,style:{...o.style,display:"block"}})})});$0.displayName=B0;function ik(e){return e!==null}var sk=e=>({name:"transformOrigin",options:e,fn(t){var x,m,p;const{placement:n,rects:r,middlewareData:o}=t,s=((x=o.arrow)==null?void 0:x.centerOffset)!==0,a=s?0:e.arrowWidth,l=s?0:e.arrowHeight,[u,c]=U0(n),d={start:"0%",center:"50%",end:"100%"}[c],f=(((m=o.arrow)==null?void 0:m.x)??0)+a/2,h=(((p=o.arrow)==null?void 0:p.y)??0)+l/2;let v="",g="";return u==="bottom"?(v=s?d:`${f}px`,g=`${-l}px`):u==="top"?(v=s?d:`${f}px`,g=`${r.floating.height+l}px`):u==="right"?(v=`${-l}px`,g=s?d:`${h}px`):u==="left"&&(v=`${r.floating.width+l}px`,g=s?d:`${h}px`),{data:{x:v,y:g}}}});function U0(e){const[t,n="center"]=e.split("-");return[t,n]}var ak=V0,lk=z0,uk=$0,[gl,gN]=cl("Tooltip",[_0]),rf=_0(),W0="TooltipProvider",ck=700,jp="tooltip.open",[dk,H0]=gl(W0),K0=e=>{const{__scopeTooltip:t,delayDuration:n=ck,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:i}=e,s=w.useRef(!0),a=w.useRef(!1),l=w.useRef(0);return w.useEffect(()=>{const u=l.current;return()=>window.clearTimeout(u)},[]),E.jsx(dk,{scope:t,isOpenDelayedRef:s,delayDuration:n,onOpen:w.useCallback(()=>{window.clearTimeout(l.current),s.current=!1},[]),onClose:w.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>s.current=!0,r)},[r]),isPointerInTransitRef:a,onPointerInTransitChange:w.useCallback(u=>{a.current=u},[]),disableHoverableContent:o,children:i})};K0.displayName=W0;var G0="Tooltip",[yN,yl]=gl(G0),Ac="TooltipTrigger",fk=w.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=yl(Ac,n),i=H0(Ac,n),s=rf(n),a=w.useRef(null),l=jt(t,a,o.onTriggerChange),u=w.useRef(!1),c=w.useRef(!1),d=w.useCallback(()=>u.current=!1,[]);return w.useEffect(()=>()=>document.removeEventListener("pointerup",d),[d]),E.jsx(ak,{asChild:!0,...s,children:E.jsx(Ze.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:l,onPointerMove:Ee(e.onPointerMove,f=>{f.pointerType!=="touch"&&!c.current&&!i.isPointerInTransitRef.current&&(o.onTriggerEnter(),c.current=!0)}),onPointerLeave:Ee(e.onPointerLeave,()=>{o.onTriggerLeave(),c.current=!1}),onPointerDown:Ee(e.onPointerDown,()=>{o.open&&o.onClose(),u.current=!0,document.addEventListener("pointerup",d,{once:!0})}),onFocus:Ee(e.onFocus,()=>{u.current||o.onOpen()}),onBlur:Ee(e.onBlur,o.onClose),onClick:Ee(e.onClick,o.onClose)})})});fk.displayName=Ac;var hk="TooltipPortal",[vN,pk]=gl(hk,{forceMount:void 0}),Lo="TooltipContent",Q0=w.forwardRef((e,t)=>{const n=pk(Lo,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...i}=e,s=yl(Lo,e.__scopeTooltip);return E.jsx(Wd,{present:r||s.open,children:s.disableHoverableContent?E.jsx(Y0,{side:o,...i,ref:t}):E.jsx(mk,{side:o,...i,ref:t})})}),mk=w.forwardRef((e,t)=>{const n=yl(Lo,e.__scopeTooltip),r=H0(Lo,e.__scopeTooltip),o=w.useRef(null),i=jt(t,o),[s,a]=w.useState(null),{trigger:l,onClose:u}=n,c=o.current,{onPointerInTransitChange:d}=r,f=w.useCallback(()=>{a(null),d(!1)},[d]),h=w.useCallback((v,g)=>{const x=v.currentTarget,m={x:v.clientX,y:v.clientY},p=wk(m,x.getBoundingClientRect()),y=Sk(m,p),S=Ek(g.getBoundingClientRect()),C=Pk([...y,...S]);a(C),d(!0)},[d]);return w.useEffect(()=>()=>f(),[f]),w.useEffect(()=>{if(l&&c){const v=x=>h(x,c),g=x=>h(x,l);return l.addEventListener("pointerleave",v),c.addEventListener("pointerleave",g),()=>{l.removeEventListener("pointerleave",v),c.removeEventListener("pointerleave",g)}}},[l,c,h,f]),w.useEffect(()=>{if(s){const v=g=>{const x=g.target,m={x:g.clientX,y:g.clientY},p=(l==null?void 0:l.contains(x))||(c==null?void 0:c.contains(x)),y=!Ck(m,s);p?f():y&&(f(),u())};return document.addEventListener("pointermove",v),()=>document.removeEventListener("pointermove",v)}},[l,c,s,u,f]),E.jsx(Y0,{...e,ref:i})}),[gk,yk]=gl(G0,{isInside:!1}),vk=rP("TooltipContent"),Y0=w.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:i,onPointerDownOutside:s,...a}=e,l=yl(Lo,n),u=rf(n),{onClose:c}=l;return w.useEffect(()=>(document.addEventListener(jp,c),()=>document.removeEventListener(jp,c)),[c]),w.useEffect(()=>{if(l.trigger){const d=f=>{const h=f.target;h!=null&&h.contains(l.trigger)&&c()};return window.addEventListener("scroll",d,{capture:!0}),()=>window.removeEventListener("scroll",d,{capture:!0})}},[l.trigger,c]),E.jsx(Ud,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:i,onPointerDownOutside:s,onFocusOutside:d=>d.preventDefault(),onDismiss:c,children:E.jsxs(lk,{"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:[E.jsx(vk,{children:r}),E.jsx(gk,{scope:n,isInside:!0,children:E.jsx(AP,{id:l.contentId,role:"tooltip",children:o||r})})]})})});Q0.displayName=Lo;var X0="TooltipArrow",xk=w.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=rf(n);return yk(X0,n).isInside?null:E.jsx(uk,{...o,...r,ref:t})});xk.displayName=X0;function wk(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),i=Math.abs(t.left-e.x);switch(Math.min(n,r,o,i)){case i:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function Sk(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 Ek(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 Ck(e,t){const{x:n,y:r}=e;let o=!1;for(let i=0,s=t.length-1;ir!=f>r&&n<(d-u)*(r-c)/(f-c)+u&&(o=!o)}return o}function Pk(e){const t=e.slice();return t.sort((n,r)=>n.xr.x?1:n.yr.y?1:0),Tk(t)}function Tk(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r=2;){const i=t[t.length-1],s=t[t.length-2];if((i.x-s.x)*(o.y-s.y)>=(i.y-s.y)*(o.x-s.x))t.pop();else break}t.push(o)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;n.length>=2;){const i=n[n.length-1],s=n[n.length-2];if((i.x-s.x)*(o.y-s.y)>=(i.y-s.y)*(o.x-s.x))n.pop();else break}n.push(o)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var bk=K0,q0=Q0;const kk=bk,Ak=w.forwardRef(({className:e,sideOffset:t=4,...n},r)=>E.jsx(q0,{ref:r,sideOffset:t,className:_r("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}));Ak.displayName=q0.displayName;const Z0=w.createContext({});function Rk(e){const t=w.useRef(null);return t.current===null&&(t.current=e()),t.current}const of=w.createContext(null),J0=w.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function Mk(e=!0){const t=w.useContext(of);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:o}=t,i=w.useId();w.useEffect(()=>{e&&o(i)},[e]);const s=w.useCallback(()=>e&&r&&r(i),[i,r,e]);return!n&&r?[!1,s]:[!0]}const sf=typeof window<"u",Nk=sf?w.useLayoutEffect:w.useEffect,ot=e=>e;let Rc=ot;function af(e){let t;return()=>(t===void 0&&(t=e()),t)}const jo=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r},ln=e=>e*1e3,un=e=>e/1e3,Dk={skipAnimations:!1,useManualTiming:!1};function Ok(e){let t=new Set,n=new Set,r=!1,o=!1;const i=new WeakSet;let s={delta:0,timestamp:0,isProcessing:!1};function a(u){i.has(u)&&(l.schedule(u),e()),u(s)}const l={schedule:(u,c=!1,d=!1)=>{const h=d&&r?t:n;return c&&i.add(u),h.has(u)||h.add(u),u},cancel:u=>{n.delete(u),i.delete(u)},process:u=>{if(s=u,r){o=!0;return}r=!0,[t,n]=[n,t],t.forEach(a),t.clear(),r=!1,o&&(o=!1,l.process(u))}};return l}const Fs=["read","resolveKeyframes","update","preRender","render","postRender"],Lk=40;function ex(e,t){let n=!1,r=!0;const o={delta:0,timestamp:0,isProcessing:!1},i=()=>n=!0,s=Fs.reduce((m,p)=>(m[p]=Ok(i),m),{}),{read:a,resolveKeyframes:l,update:u,preRender:c,render:d,postRender:f}=s,h=()=>{const m=performance.now();n=!1,o.delta=r?1e3/60:Math.max(Math.min(m-o.timestamp,Lk),1),o.timestamp=m,o.isProcessing=!0,a.process(o),l.process(o),u.process(o),c.process(o),d.process(o),f.process(o),o.isProcessing=!1,n&&t&&(r=!1,e(h))},v=()=>{n=!0,r=!0,o.isProcessing||e(h)};return{schedule:Fs.reduce((m,p)=>{const y=s[p];return m[p]=(S,C=!1,P=!1)=>(n||v(),y.schedule(S,C,P)),m},{}),cancel:m=>{for(let p=0;p_p[e].some(n=>!!t[n])};function jk(e){for(const t in e)_o[t]={..._o[t],...e[t]}}const _k=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function _a(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||_k.has(e)}let nx=e=>!_a(e);function Ik(e){e&&(nx=t=>t.startsWith("on")?!_a(t):e(t))}try{Ik(require("@emotion/is-prop-valid").default)}catch{}function Fk(e,t,n){const r={};for(const o in e)o==="values"&&typeof e.values=="object"||(nx(o)||n===!0&&_a(o)||!t&&!_a(o)||e.draggable&&o.startsWith("onDrag"))&&(r[o]=e[o]);return r}function Vk(e){if(typeof Proxy>"u")return e;const t=new Map,n=(...r)=>e(...r);return new Proxy(n,{get:(r,o)=>o==="create"?e:(t.has(o)||t.set(o,e(o)),t.get(o))})}const vl=w.createContext({});function Gi(e){return typeof e=="string"||Array.isArray(e)}function xl(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}const lf=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],uf=["initial",...lf];function wl(e){return xl(e.animate)||uf.some(t=>Gi(e[t]))}function rx(e){return!!(wl(e)||e.variants)}function zk(e,t){if(wl(e)){const{initial:n,animate:r}=e;return{initial:n===!1||Gi(n)?n:void 0,animate:Gi(r)?r:void 0}}return e.inherit!==!1?t:{}}function Bk(e){const{initial:t,animate:n}=zk(e,w.useContext(vl));return w.useMemo(()=>({initial:t,animate:n}),[Ip(t),Ip(n)])}function Ip(e){return Array.isArray(e)?e.join(" "):e}const $k=Symbol.for("motionComponentSymbol");function ro(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function Uk(e,t,n){return w.useCallback(r=>{r&&e.onMount&&e.onMount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):ro(n)&&(n.current=r))},[t])}const cf=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),Wk="framerAppearId",ox="data-"+cf(Wk),{schedule:df,cancel:xN}=ex(queueMicrotask,!1),ix=w.createContext({});function Hk(e,t,n,r,o){var i,s;const{visualElement:a}=w.useContext(vl),l=w.useContext(tx),u=w.useContext(of),c=w.useContext(J0).reducedMotion,d=w.useRef(null);r=r||l.renderer,!d.current&&r&&(d.current=r(e,{visualState:t,parent:a,props:n,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:c}));const f=d.current,h=w.useContext(ix);f&&!f.projection&&o&&(f.type==="html"||f.type==="svg")&&Kk(d.current,n,o,h);const v=w.useRef(!1);w.useInsertionEffect(()=>{f&&v.current&&f.update(n,u)});const g=n[ox],x=w.useRef(!!g&&!(!((i=window.MotionHandoffIsComplete)===null||i===void 0)&&i.call(window,g))&&((s=window.MotionHasOptimisedAnimation)===null||s===void 0?void 0:s.call(window,g)));return Nk(()=>{f&&(v.current=!0,window.MotionIsMounted=!0,f.updateFeatures(),df.render(f.render),x.current&&f.animationState&&f.animationState.animateChanges())}),w.useEffect(()=>{f&&(!x.current&&f.animationState&&f.animationState.animateChanges(),x.current&&(queueMicrotask(()=>{var m;(m=window.MotionHandoffMarkAsComplete)===null||m===void 0||m.call(window,g)}),x.current=!1))}),f}function Kk(e,t,n,r){const{layoutId:o,layout:i,drag:s,dragConstraints:a,layoutScroll:l,layoutRoot:u}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:sx(e.parent)),e.projection.setOptions({layoutId:o,layout:i,alwaysMeasureLayout:!!s||a&&ro(a),visualElement:e,animationType:typeof i=="string"?i:"both",initialPromotionConfig:r,layoutScroll:l,layoutRoot:u})}function sx(e){if(e)return e.options.allowProjection!==!1?e.projection:sx(e.parent)}function Gk({preloadedFeatures:e,createVisualElement:t,useRender:n,useVisualState:r,Component:o}){var i,s;e&&jk(e);function a(u,c){let d;const f={...w.useContext(J0),...u,layoutId:Qk(u)},{isStatic:h}=f,v=Bk(u),g=r(u,h);if(!h&&sf){Yk();const x=Xk(f);d=x.MeasureLayout,v.visualElement=Hk(o,g,f,t,x.ProjectionNode)}return E.jsxs(vl.Provider,{value:v,children:[d&&v.visualElement?E.jsx(d,{visualElement:v.visualElement,...f}):null,n(o,u,Uk(g,v.visualElement,c),g,h,v.visualElement)]})}a.displayName=`motion.${typeof o=="string"?o:`create(${(s=(i=o.displayName)!==null&&i!==void 0?i:o.name)!==null&&s!==void 0?s:""})`}`;const l=w.forwardRef(a);return l[$k]=o,l}function Qk({layoutId:e}){const t=w.useContext(Z0).id;return t&&e!==void 0?t+"-"+e:e}function Yk(e,t){w.useContext(tx).strict}function Xk(e){const{drag:t,layout:n}=_o;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:t!=null&&t.isEnabled(e)||n!=null&&n.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}const qk=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function ff(e){return typeof e!="string"||e.includes("-")?!1:!!(qk.indexOf(e)>-1||/[A-Z]/u.test(e))}function Fp(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function hf(e,t,n,r){if(typeof t=="function"){const[o,i]=Fp(r);t=t(n!==void 0?n:e.custom,o,i)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[o,i]=Fp(r);t=t(n!==void 0?n:e.custom,o,i)}return t}const Mc=e=>Array.isArray(e),Zk=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),Jk=e=>Mc(e)?e[e.length-1]||0:e,Ie=e=>!!(e&&e.getVelocity);function na(e){const t=Ie(e)?e.get():e;return Zk(t)?t.toValue():t}function eA({scrapeMotionValuesFromProps:e,createRenderState:t,onUpdate:n},r,o,i){const s={latestValues:tA(r,o,i,e),renderState:t()};return n&&(s.onMount=a=>n({props:r,current:a,...s}),s.onUpdate=a=>n(a)),s}const ax=e=>(t,n)=>{const r=w.useContext(vl),o=w.useContext(of),i=()=>eA(e,t,r,o);return n?i():Rk(i)};function tA(e,t,n,r){const o={},i=r(e,{});for(const f in i)o[f]=na(i[f]);let{initial:s,animate:a}=e;const l=wl(e),u=rx(e);t&&u&&!l&&e.inherit!==!1&&(s===void 0&&(s=t.initial),a===void 0&&(a=t.animate));let c=n?n.initial===!1:!1;c=c||s===!1;const d=c?a:s;if(d&&typeof d!="boolean"&&!xl(d)){const f=Array.isArray(d)?d:[d];for(let h=0;ht=>typeof t=="string"&&t.startsWith(e),ux=lx("--"),nA=lx("var(--"),pf=e=>nA(e)?rA.test(e.split("/*")[0].trim()):!1,rA=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,cx=(e,t)=>t&&typeof e=="number"?t.transform(e):e,gn=(e,t,n)=>n>t?t:ntypeof e=="number",parse:parseFloat,transform:e=>e},Qi={...Ho,transform:e=>gn(0,1,e)},Vs={...Ho,default:1},ls=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),An=ls("deg"),Qt=ls("%"),B=ls("px"),oA=ls("vh"),iA=ls("vw"),Vp={...Qt,parse:e=>Qt.parse(e)/100,transform:e=>Qt.transform(e*100)},sA={borderWidth:B,borderTopWidth:B,borderRightWidth:B,borderBottomWidth:B,borderLeftWidth:B,borderRadius:B,radius:B,borderTopLeftRadius:B,borderTopRightRadius:B,borderBottomRightRadius:B,borderBottomLeftRadius:B,width:B,maxWidth:B,height:B,maxHeight:B,top:B,right:B,bottom:B,left:B,padding:B,paddingTop:B,paddingRight:B,paddingBottom:B,paddingLeft:B,margin:B,marginTop:B,marginRight:B,marginBottom:B,marginLeft:B,backgroundPositionX:B,backgroundPositionY:B},aA={rotate:An,rotateX:An,rotateY:An,rotateZ:An,scale:Vs,scaleX:Vs,scaleY:Vs,scaleZ:Vs,skew:An,skewX:An,skewY:An,distance:B,translateX:B,translateY:B,translateZ:B,x:B,y:B,z:B,perspective:B,transformPerspective:B,opacity:Qi,originX:Vp,originY:Vp,originZ:B},zp={...Ho,transform:Math.round},mf={...sA,...aA,zIndex:zp,size:B,fillOpacity:Qi,strokeOpacity:Qi,numOctaves:zp},lA={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},uA=Wo.length;function cA(e,t,n){let r="",o=!0;for(let i=0;i({style:{},transform:{},transformOrigin:{},vars:{}}),dx=()=>({...vf(),attrs:{}}),xf=e=>typeof e=="string"&&e.toLowerCase()==="svg";function fx(e,{style:t,vars:n},r,o){Object.assign(e.style,t,o&&o.getProjectionStyles(r));for(const i in n)e.style.setProperty(i,n[i])}const hx=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function px(e,t,n,r){fx(e,t,void 0,r);for(const o in t.attrs)e.setAttribute(hx.has(o)?o:cf(o),t.attrs[o])}const Ia={};function mA(e){Object.assign(Ia,e)}function mx(e,{layout:t,layoutId:n}){return Ir.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Ia[e]||e==="opacity")}function wf(e,t,n){var r;const{style:o}=e,i={};for(const s in o)(Ie(o[s])||t.style&&Ie(t.style[s])||mx(s,e)||((r=n==null?void 0:n.getValue(s))===null||r===void 0?void 0:r.liveStyle)!==void 0)&&(i[s]=o[s]);return i}function gx(e,t,n){const r=wf(e,t,n);for(const o in e)if(Ie(e[o])||Ie(t[o])){const i=Wo.indexOf(o)!==-1?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o;r[i]=e[o]}return r}function gA(e,t){try{t.dimensions=typeof e.getBBox=="function"?e.getBBox():e.getBoundingClientRect()}catch{t.dimensions={x:0,y:0,width:0,height:0}}}const $p=["x","y","width","height","cx","cy","r"],yA={useVisualState:ax({scrapeMotionValuesFromProps:gx,createRenderState:dx,onUpdate:({props:e,prevProps:t,current:n,renderState:r,latestValues:o})=>{if(!n)return;let i=!!e.drag;if(!i){for(const a in o)if(Ir.has(a)){i=!0;break}}if(!i)return;let s=!t;if(t)for(let a=0;a<$p.length;a++){const l=$p[a];e[l]!==t[l]&&(s=!0)}s&&ae.read(()=>{gA(n,r),ae.render(()=>{yf(r,o,xf(n.tagName),e.transformTemplate),px(n,r)})})}})},vA={useVisualState:ax({scrapeMotionValuesFromProps:wf,createRenderState:vf})};function yx(e,t,n){for(const r in t)!Ie(t[r])&&!mx(r,n)&&(e[r]=t[r])}function xA({transformTemplate:e},t){return w.useMemo(()=>{const n=vf();return gf(n,t,e),Object.assign({},n.vars,n.style)},[t])}function wA(e,t){const n=e.style||{},r={};return yx(r,n,e),Object.assign(r,xA(e,t)),r}function SA(e,t){const n={},r=wA(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}function EA(e,t,n,r){const o=w.useMemo(()=>{const i=dx();return yf(i,t,xf(r),e.transformTemplate),{...i.attrs,style:{...i.style}}},[t]);if(e.style){const i={};yx(i,e.style,e),o.style={...i,...o.style}}return o}function CA(e=!1){return(n,r,o,{latestValues:i},s)=>{const l=(ff(n)?EA:SA)(r,i,s,n),u=Fk(r,typeof n=="string",e),c=n!==w.Fragment?{...u,...l,ref:o}:{},{children:d}=r,f=w.useMemo(()=>Ie(d)?d.get():d,[d]);return w.createElement(n,{...c,children:f})}}function PA(e,t){return function(r,{forwardMotionProps:o}={forwardMotionProps:!1}){const s={...ff(r)?yA:vA,preloadedFeatures:e,useRender:CA(o),createVisualElement:t,Component:r};return Gk(s)}}function vx(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;rwindow.ScrollTimeline!==void 0);class bA{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}get finished(){return Promise.all(this.animations.map(t=>"finished"in t?t.finished:t))}getAll(t){return this.animations[0][t]}setAll(t,n){for(let r=0;r{if(TA()&&o.attachTimeline)return o.attachTimeline(t);if(typeof n=="function")return n(o)});return()=>{r.forEach((o,i)=>{o&&o(),this.animations[i].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get startTime(){return this.getAll("startTime")}get duration(){let t=0;for(let n=0;nn[t]())}flatten(){this.runAll("flatten")}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}class kA extends bA{then(t,n){return Promise.all(this.animations).then(t).catch(n)}}function Sf(e,t){return e?e[t]||e.default||e:void 0}const Nc=2e4;function xx(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t=Nc?1/0:t}function Ef(e){return typeof e=="function"}function Up(e,t){e.timeline=t,e.onfinish=null}const Cf=e=>Array.isArray(e)&&typeof e[0]=="number",AA={linearEasing:void 0};function RA(e,t){const n=af(e);return()=>{var r;return(r=AA[t])!==null&&r!==void 0?r:n()}}const Fa=RA(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),wx=(e,t,n=10)=>{let r="";const o=Math.max(Math.round(t/n),2);for(let i=0;i`cubic-bezier(${e}, ${t}, ${n}, ${r})`,Dc={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:ui([0,.65,.55,1]),circOut:ui([.55,0,1,.45]),backIn:ui([.31,.01,.66,-.59]),backOut:ui([.33,1.53,.69,.99])};function Ex(e,t){if(e)return typeof e=="function"&&Fa()?wx(e,t):Cf(e)?ui(e):Array.isArray(e)?e.map(n=>Ex(n,t)||Dc.easeOut):Dc[e]}const Tt={x:!1,y:!1};function Cx(){return Tt.x||Tt.y}function MA(e,t,n){var r;if(e instanceof Element)return[e];if(typeof e=="string"){let o=document;const i=(r=void 0)!==null&&r!==void 0?r:o.querySelectorAll(e);return i?Array.from(i):[]}return Array.from(e)}function Px(e,t){const n=MA(e),r=new AbortController,o={passive:!0,...t,signal:r.signal};return[n,o,()=>r.abort()]}function Wp(e){return t=>{t.pointerType==="touch"||Cx()||e(t)}}function NA(e,t,n={}){const[r,o,i]=Px(e,n),s=Wp(a=>{const{target:l}=a,u=t(a);if(typeof u!="function"||!l)return;const c=Wp(d=>{u(d),l.removeEventListener("pointerleave",c)});l.addEventListener("pointerleave",c,o)});return r.forEach(a=>{a.addEventListener("pointerenter",s,o)}),i}const Tx=(e,t)=>t?e===t?!0:Tx(e,t.parentElement):!1,Pf=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,DA=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function OA(e){return DA.has(e.tagName)||e.tabIndex!==-1}const ci=new WeakSet;function Hp(e){return t=>{t.key==="Enter"&&e(t)}}function lu(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const LA=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=Hp(()=>{if(ci.has(n))return;lu(n,"down");const o=Hp(()=>{lu(n,"up")}),i=()=>lu(n,"cancel");n.addEventListener("keyup",o,t),n.addEventListener("blur",i,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function Kp(e){return Pf(e)&&!Cx()}function jA(e,t,n={}){const[r,o,i]=Px(e,n),s=a=>{const l=a.currentTarget;if(!Kp(a)||ci.has(l))return;ci.add(l);const u=t(a),c=(h,v)=>{window.removeEventListener("pointerup",d),window.removeEventListener("pointercancel",f),!(!Kp(h)||!ci.has(l))&&(ci.delete(l),typeof u=="function"&&u(h,{success:v}))},d=h=>{c(h,n.useGlobalTarget||Tx(l,h.target))},f=h=>{c(h,!1)};window.addEventListener("pointerup",d,o),window.addEventListener("pointercancel",f,o)};return r.forEach(a=>{!OA(a)&&a.getAttribute("tabindex")===null&&(a.tabIndex=0),(n.useGlobalTarget?window:a).addEventListener("pointerdown",s,o),a.addEventListener("focus",u=>LA(u,o),o)}),i}function _A(e){return e==="x"||e==="y"?Tt[e]?null:(Tt[e]=!0,()=>{Tt[e]=!1}):Tt.x||Tt.y?null:(Tt.x=Tt.y=!0,()=>{Tt.x=Tt.y=!1})}const bx=new Set(["width","height","top","left","right","bottom",...Wo]);let ra;function IA(){ra=void 0}const Yt={now:()=>(ra===void 0&&Yt.set(ke.isProcessing||Dk.useManualTiming?ke.timestamp:performance.now()),ra),set:e=>{ra=e,queueMicrotask(IA)}};function Tf(e,t){e.indexOf(t)===-1&&e.push(t)}function bf(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class kf{constructor(){this.subscriptions=[]}add(t){return Tf(this.subscriptions,t),()=>bf(this.subscriptions,t)}notify(t,n,r){const o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](t,n,r);else for(let i=0;i!isNaN(parseFloat(e));class VA{constructor(t,n={}){this.version="11.18.2",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(r,o=!0)=>{const i=Yt.now();this.updatedAt!==i&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),o&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=Yt.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=FA(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new kf);const r=this.events[t].add(n);return t==="change"?()=>{r(),ae.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t,n=!0){!n||!this.passiveEffect?this.updateAndNotify(t,n):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=Yt.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Gp)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Gp);return kx(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Yi(e,t){return new VA(e,t)}function zA(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Yi(n))}function BA(e,t){const n=Sl(e,t);let{transitionEnd:r={},transition:o={},...i}=n||{};i={...i,...r};for(const s in i){const a=Jk(i[s]);zA(e,s,a)}}function $A(e){return!!(Ie(e)&&e.add)}function Oc(e,t){const n=e.getValue("willChange");if($A(n))return n.add(t)}function Ax(e){return e.props[ox]}const Rx=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,UA=1e-7,WA=12;function HA(e,t,n,r,o){let i,s,a=0;do s=t+(n-t)/2,i=Rx(s,r,o)-e,i>0?n=s:t=s;while(Math.abs(i)>UA&&++aHA(i,0,1,e,n);return i=>i===0||i===1?i:Rx(o(i),t,r)}const Mx=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,Nx=e=>t=>1-e(1-t),Dx=us(.33,1.53,.69,.99),Af=Nx(Dx),Ox=Mx(Af),Lx=e=>(e*=2)<1?.5*Af(e):.5*(2-Math.pow(2,-10*(e-1))),Rf=e=>1-Math.sin(Math.acos(e)),jx=Nx(Rf),_x=Mx(Rf),Ix=e=>/^0[^.\s]+$/u.test(e);function KA(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||Ix(e):!0}const Ei=e=>Math.round(e*1e5)/1e5,Mf=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function GA(e){return e==null}const QA=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Nf=(e,t)=>n=>!!(typeof n=="string"&&QA.test(n)&&n.startsWith(e)||t&&!GA(n)&&Object.prototype.hasOwnProperty.call(n,t)),Fx=(e,t,n)=>r=>{if(typeof r!="string")return r;const[o,i,s,a]=r.match(Mf);return{[e]:parseFloat(o),[t]:parseFloat(i),[n]:parseFloat(s),alpha:a!==void 0?parseFloat(a):1}},YA=e=>gn(0,255,e),uu={...Ho,transform:e=>Math.round(YA(e))},vr={test:Nf("rgb","red"),parse:Fx("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+uu.transform(e)+", "+uu.transform(t)+", "+uu.transform(n)+", "+Ei(Qi.transform(r))+")"};function XA(e){let t="",n="",r="",o="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),o=e.substring(4,5),t+=t,n+=n,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}}const Lc={test:Nf("#"),parse:XA,transform:vr.transform},oo={test:Nf("hsl","hue"),parse:Fx("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Qt.transform(Ei(t))+", "+Qt.transform(Ei(n))+", "+Ei(Qi.transform(r))+")"},je={test:e=>vr.test(e)||Lc.test(e)||oo.test(e),parse:e=>vr.test(e)?vr.parse(e):oo.test(e)?oo.parse(e):Lc.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?vr.transform(e):oo.transform(e)},qA=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function ZA(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(Mf))===null||t===void 0?void 0:t.length)||0)+(((n=e.match(qA))===null||n===void 0?void 0:n.length)||0)>0}const Vx="number",zx="color",JA="var",eR="var(",Qp="${}",tR=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Xi(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},o=[];let i=0;const a=t.replace(tR,l=>(je.test(l)?(r.color.push(i),o.push(zx),n.push(je.parse(l))):l.startsWith(eR)?(r.var.push(i),o.push(JA),n.push(l)):(r.number.push(i),o.push(Vx),n.push(parseFloat(l))),++i,Qp)).split(Qp);return{values:n,split:a,indexes:r,types:o}}function Bx(e){return Xi(e).values}function $x(e){const{split:t,types:n}=Xi(e),r=t.length;return o=>{let i="";for(let s=0;stypeof e=="number"?0:e;function rR(e){const t=Bx(e);return $x(e)(t.map(nR))}const nr={test:ZA,parse:Bx,createTransformer:$x,getAnimatableNone:rR},oR=new Set(["brightness","contrast","saturate","opacity"]);function iR(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Mf)||[];if(!r)return e;const o=n.replace(r,"");let i=oR.has(t)?1:0;return r!==n&&(i*=100),t+"("+i+o+")"}const sR=/\b([a-z-]*)\(.*?\)/gu,jc={...nr,getAnimatableNone:e=>{const t=e.match(sR);return t?t.map(iR).join(" "):e}},aR={...mf,color:je,backgroundColor:je,outlineColor:je,fill:je,stroke:je,borderColor:je,borderTopColor:je,borderRightColor:je,borderBottomColor:je,borderLeftColor:je,filter:jc,WebkitFilter:jc},Df=e=>aR[e];function Ux(e,t){let n=Df(e);return n!==jc&&(n=nr),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const lR=new Set(["auto","none","0"]);function uR(e,t,n){let r=0,o;for(;re===Ho||e===B,Xp=(e,t)=>parseFloat(e.split(", ")[t]),qp=(e,t)=>(n,{transform:r})=>{if(r==="none"||!r)return 0;const o=r.match(/^matrix3d\((.+)\)$/u);if(o)return Xp(o[1],t);{const i=r.match(/^matrix\((.+)\)$/u);return i?Xp(i[1],e):0}},cR=new Set(["x","y","z"]),dR=Wo.filter(e=>!cR.has(e));function fR(e){const t=[];return dR.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const Io={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:qp(4,13),y:qp(5,14)};Io.translateX=Io.x;Io.translateY=Io.y;const kr=new Set;let _c=!1,Ic=!1;function Wx(){if(Ic){const e=Array.from(kr).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const o=fR(r);o.length&&(n.set(r,o),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const o=n.get(r);o&&o.forEach(([i,s])=>{var a;(a=r.getValue(i))===null||a===void 0||a.set(s)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}Ic=!1,_c=!1,kr.forEach(e=>e.complete()),kr.clear()}function Hx(){kr.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Ic=!0)})}function hR(){Hx(),Wx()}class Of{constructor(t,n,r,o,i,s=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=o,this.element=i,this.isAsync=s}scheduleResolve(){this.isScheduled=!0,this.isAsync?(kr.add(this),_c||(_c=!0,ae.read(Hx),ae.resolveKeyframes(Wx))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:o}=this;for(let i=0;i/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),pR=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function mR(e){const t=pR.exec(e);if(!t)return[,];const[,n,r,o]=t;return[`--${n??r}`,o]}function Gx(e,t,n=1){const[r,o]=mR(e);if(!r)return;const i=window.getComputedStyle(t).getPropertyValue(r);if(i){const s=i.trim();return Kx(s)?parseFloat(s):s}return pf(o)?Gx(o,t,n+1):o}const Qx=e=>t=>t.test(e),gR={test:e=>e==="auto",parse:e=>e},Yx=[Ho,B,Qt,An,iA,oA,gR],Zp=e=>Yx.find(Qx(e));class Xx extends Of{constructor(t,n,r,o,i){super(t,n,r,o,i,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let l=0;l{n.getValue(l).set(u)}),this.resolveNoneKeyframes()}}const Jp=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(nr.test(e)||e==="0")&&!e.startsWith("url("));function yR(e){const t=e[0];if(e.length===1)return!0;for(let n=0;ne!==null;function El(e,{repeat:t,repeatType:n="loop"},r){const o=e.filter(xR),i=t&&n!=="loop"&&t%2===1?0:o.length-1;return!i||r===void 0?o[i]:r}const wR=40;class qx{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:o=0,repeatDelay:i=0,repeatType:s="loop",...a}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=Yt.now(),this.options={autoplay:t,delay:n,type:r,repeat:o,repeatDelay:i,repeatType:s,...a},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt?this.resolvedAt-this.createdAt>wR?this.resolvedAt:this.createdAt:this.createdAt}get resolved(){return!this._resolved&&!this.hasAttemptedResolve&&hR(),this._resolved}onKeyframesResolved(t,n){this.resolvedAt=Yt.now(),this.hasAttemptedResolve=!0;const{name:r,type:o,velocity:i,delay:s,onComplete:a,onUpdate:l,isGenerator:u}=this.options;if(!u&&!vR(t,r,o,i))if(s)this.options.duration=0;else{l&&l(El(t,this.options,n)),a&&a(),this.resolveFinishedPromise();return}const c=this.initPlayback(t,n);c!==!1&&(this._resolved={keyframes:t,finalKeyframe:n,...c},this.onPostResolved())}onPostResolved(){}then(t,n){return this.currentFinishedPromise.then(t,n)}flatten(){this.options.type="keyframes",this.options.ease="linear"}updateFinishedPromise(){this.currentFinishedPromise=new Promise(t=>{this.resolveFinishedPromise=t})}}const de=(e,t,n)=>e+(t-e)*n;function cu(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function SR({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let o=0,i=0,s=0;if(!t)o=i=s=n;else{const a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;o=cu(l,a,e+1/3),i=cu(l,a,e),s=cu(l,a,e-1/3)}return{red:Math.round(o*255),green:Math.round(i*255),blue:Math.round(s*255),alpha:r}}function Va(e,t){return n=>n>0?t:e}const du=(e,t,n)=>{const r=e*e,o=n*(t*t-r)+r;return o<0?0:Math.sqrt(o)},ER=[Lc,vr,oo],CR=e=>ER.find(t=>t.test(e));function em(e){const t=CR(e);if(!t)return!1;let n=t.parse(e);return t===oo&&(n=SR(n)),n}const tm=(e,t)=>{const n=em(e),r=em(t);if(!n||!r)return Va(e,t);const o={...n};return i=>(o.red=du(n.red,r.red,i),o.green=du(n.green,r.green,i),o.blue=du(n.blue,r.blue,i),o.alpha=de(n.alpha,r.alpha,i),vr.transform(o))},PR=(e,t)=>n=>t(e(n)),cs=(...e)=>e.reduce(PR),Fc=new Set(["none","hidden"]);function TR(e,t){return Fc.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function bR(e,t){return n=>de(e,t,n)}function Lf(e){return typeof e=="number"?bR:typeof e=="string"?pf(e)?Va:je.test(e)?tm:RR:Array.isArray(e)?Zx:typeof e=="object"?je.test(e)?tm:kR:Va}function Zx(e,t){const n=[...e],r=n.length,o=e.map((i,s)=>Lf(i)(i,t[s]));return i=>{for(let s=0;s{for(const i in r)n[i]=r[i](o);return n}}function AR(e,t){var n;const r=[],o={color:0,var:0,number:0};for(let i=0;i{const n=nr.createTransformer(t),r=Xi(e),o=Xi(t);return r.indexes.var.length===o.indexes.var.length&&r.indexes.color.length===o.indexes.color.length&&r.indexes.number.length>=o.indexes.number.length?Fc.has(e)&&!o.values.length||Fc.has(t)&&!r.values.length?TR(e,t):cs(Zx(AR(r,o),o.values),n):Va(e,t)};function Jx(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?de(e,t,n):Lf(e)(e,t)}const MR=5;function ew(e,t,n){const r=Math.max(t-MR,0);return kx(n-e(r),t-r)}const me={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},fu=.001;function NR({duration:e=me.duration,bounce:t=me.bounce,velocity:n=me.velocity,mass:r=me.mass}){let o,i,s=1-t;s=gn(me.minDamping,me.maxDamping,s),e=gn(me.minDuration,me.maxDuration,un(e)),s<1?(o=u=>{const c=u*s,d=c*e,f=c-n,h=Vc(u,s),v=Math.exp(-d);return fu-f/h*v},i=u=>{const d=u*s*e,f=d*n+n,h=Math.pow(s,2)*Math.pow(u,2)*e,v=Math.exp(-d),g=Vc(Math.pow(u,2),s);return(-o(u)+fu>0?-1:1)*((f-h)*v)/g}):(o=u=>{const c=Math.exp(-u*e),d=(u-n)*e+1;return-fu+c*d},i=u=>{const c=Math.exp(-u*e),d=(n-u)*(e*e);return c*d});const a=5/e,l=OR(o,i,a);if(e=ln(e),isNaN(l))return{stiffness:me.stiffness,damping:me.damping,duration:e};{const u=Math.pow(l,2)*r;return{stiffness:u,damping:s*2*Math.sqrt(r*u),duration:e}}}const DR=12;function OR(e,t,n){let r=n;for(let o=1;oe[n]!==void 0)}function _R(e){let t={velocity:me.velocity,stiffness:me.stiffness,damping:me.damping,mass:me.mass,isResolvedFromDuration:!1,...e};if(!nm(e,jR)&&nm(e,LR))if(e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),o=r*r,i=2*gn(.05,1,1-(e.bounce||0))*Math.sqrt(o);t={...t,mass:me.mass,stiffness:o,damping:i}}else{const n=NR(e);t={...t,...n,mass:me.mass},t.isResolvedFromDuration=!0}return t}function tw(e=me.visualDuration,t=me.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:o}=n;const i=n.keyframes[0],s=n.keyframes[n.keyframes.length-1],a={done:!1,value:i},{stiffness:l,damping:u,mass:c,duration:d,velocity:f,isResolvedFromDuration:h}=_R({...n,velocity:-un(n.velocity||0)}),v=f||0,g=u/(2*Math.sqrt(l*c)),x=s-i,m=un(Math.sqrt(l/c)),p=Math.abs(x)<5;r||(r=p?me.restSpeed.granular:me.restSpeed.default),o||(o=p?me.restDelta.granular:me.restDelta.default);let y;if(g<1){const C=Vc(m,g);y=P=>{const T=Math.exp(-g*m*P);return s-T*((v+g*m*x)/C*Math.sin(C*P)+x*Math.cos(C*P))}}else if(g===1)y=C=>s-Math.exp(-m*C)*(x+(v+m*x)*C);else{const C=m*Math.sqrt(g*g-1);y=P=>{const T=Math.exp(-g*m*P),b=Math.min(C*P,300);return s-T*((v+g*m*x)*Math.sinh(b)+C*x*Math.cosh(b))/C}}const S={calculatedDuration:h&&d||null,next:C=>{const P=y(C);if(h)a.done=C>=d;else{let T=0;g<1&&(T=C===0?ln(v):ew(y,C,P));const b=Math.abs(T)<=r,D=Math.abs(s-P)<=o;a.done=b&&D}return a.value=a.done?s:P,a},toString:()=>{const C=Math.min(xx(S),Nc),P=wx(T=>S.next(C*T).value,C,30);return C+"ms "+P}};return S}function rm({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:i=500,modifyTarget:s,min:a,max:l,restDelta:u=.5,restSpeed:c}){const d=e[0],f={done:!1,value:d},h=b=>a!==void 0&&bl,v=b=>a===void 0?l:l===void 0||Math.abs(a-b)-g*Math.exp(-b/r),y=b=>m+p(b),S=b=>{const D=p(b),N=y(b);f.done=Math.abs(D)<=u,f.value=f.done?m:N};let C,P;const T=b=>{h(f.value)&&(C=b,P=tw({keyframes:[f.value,v(f.value)],velocity:ew(y,b,f.value),damping:o,stiffness:i,restDelta:u,restSpeed:c}))};return T(0),{calculatedDuration:null,next:b=>{let D=!1;return!P&&C===void 0&&(D=!0,S(b),T(b)),C!==void 0&&b>=C?P.next(b-C):(!D&&S(b),f)}}}const IR=us(.42,0,1,1),FR=us(0,0,.58,1),nw=us(.42,0,.58,1),VR=e=>Array.isArray(e)&&typeof e[0]!="number",om={linear:ot,easeIn:IR,easeInOut:nw,easeOut:FR,circIn:Rf,circInOut:_x,circOut:jx,backIn:Af,backInOut:Ox,backOut:Dx,anticipate:Lx},im=e=>{if(Cf(e)){Rc(e.length===4);const[t,n,r,o]=e;return us(t,n,r,o)}else if(typeof e=="string")return Rc(om[e]!==void 0),om[e];return e};function zR(e,t,n){const r=[],o=n||Jx,i=e.length-1;for(let s=0;st[0];if(i===2&&t[0]===t[1])return()=>t[1];const s=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=zR(t,r,o),l=a.length,u=c=>{if(s&&c1)for(;du(gn(e[0],e[i-1],c)):u}function $R(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const o=jo(0,t,r);e.push(de(n,1,o))}}function UR(e){const t=[0];return $R(t,e.length-1),t}function WR(e,t){return e.map(n=>n*t)}function HR(e,t){return e.map(()=>t||nw).splice(0,e.length-1)}function za({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const o=VR(r)?r.map(im):im(r),i={done:!1,value:t[0]},s=WR(n&&n.length===t.length?n:UR(t),e),a=BR(s,t,{ease:Array.isArray(o)?o:HR(t,o)});return{calculatedDuration:e,next:l=>(i.value=a(l),i.done=l>=e,i)}}const KR=e=>{const t=({timestamp:n})=>e(n);return{start:()=>ae.update(t,!0),stop:()=>tr(t),now:()=>ke.isProcessing?ke.timestamp:Yt.now()}},GR={decay:rm,inertia:rm,tween:za,keyframes:za,spring:tw},QR=e=>e/100;class jf extends qx{constructor(t){super(t),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.teardown();const{onStop:l}=this.options;l&&l()};const{name:n,motionValue:r,element:o,keyframes:i}=this.options,s=(o==null?void 0:o.KeyframeResolver)||Of,a=(l,u)=>this.onKeyframesResolved(l,u);this.resolver=new s(i,a,n,r,o),this.resolver.scheduleResolve()}flatten(){super.flatten(),this._resolved&&Object.assign(this._resolved,this.initPlayback(this._resolved.keyframes))}initPlayback(t){const{type:n="keyframes",repeat:r=0,repeatDelay:o=0,repeatType:i,velocity:s=0}=this.options,a=Ef(n)?n:GR[n]||za;let l,u;a!==za&&typeof t[0]!="number"&&(l=cs(QR,Jx(t[0],t[1])),t=[0,100]);const c=a({...this.options,keyframes:t});i==="mirror"&&(u=a({...this.options,keyframes:[...t].reverse(),velocity:-s})),c.calculatedDuration===null&&(c.calculatedDuration=xx(c));const{calculatedDuration:d}=c,f=d+o,h=f*(r+1)-o;return{generator:c,mirroredGenerator:u,mapPercentToKeyframes:l,calculatedDuration:d,resolvedDuration:f,totalDuration:h}}onPostResolved(){const{autoplay:t=!0}=this.options;this.play(),this.pendingPlayState==="paused"||!t?this.pause():this.state=this.pendingPlayState}tick(t,n=!1){const{resolved:r}=this;if(!r){const{keyframes:b}=this.options;return{done:!0,value:b[b.length-1]}}const{finalKeyframe:o,generator:i,mirroredGenerator:s,mapPercentToKeyframes:a,keyframes:l,calculatedDuration:u,totalDuration:c,resolvedDuration:d}=r;if(this.startTime===null)return i.next(0);const{delay:f,repeat:h,repeatType:v,repeatDelay:g,onUpdate:x}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-c/this.speed,this.startTime)),n?this.currentTime=t:this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=Math.round(t-this.startTime)*this.speed;const m=this.currentTime-f*(this.speed>=0?1:-1),p=this.speed>=0?m<0:m>c;this.currentTime=Math.max(m,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=c);let y=this.currentTime,S=i;if(h){const b=Math.min(this.currentTime,c)/d;let D=Math.floor(b),N=b%1;!N&&b>=1&&(N=1),N===1&&D--,D=Math.min(D,h+1),!!(D%2)&&(v==="reverse"?(N=1-N,g&&(N-=g/d)):v==="mirror"&&(S=s)),y=gn(0,1,N)*d}const C=p?{done:!1,value:l[0]}:S.next(y);a&&(C.value=a(C.value));let{done:P}=C;!p&&u!==null&&(P=this.speed>=0?this.currentTime>=c:this.currentTime<=0);const T=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&P);return T&&o!==void 0&&(C.value=El(l,this.options,o)),x&&x(C.value),T&&this.finish(),C}get duration(){const{resolved:t}=this;return t?un(t.calculatedDuration):0}get time(){return un(this.currentTime)}set time(t){t=ln(t),this.currentTime=t,this.holdTime!==null||this.speed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.speed)}get speed(){return this.playbackSpeed}set speed(t){const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=un(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;const{driver:t=KR,onPlay:n,startTime:r}=this.options;this.driver||(this.driver=t(i=>this.tick(i))),n&&n();const o=this.driver.now();this.holdTime!==null?this.startTime=o-this.holdTime:this.startTime?this.state==="finished"&&(this.startTime=o):this.startTime=r??this.calcStartTime(),this.state==="finished"&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var t;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=(t=this.currentTime)!==null&&t!==void 0?t:0}complete(){this.state!=="running"&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:t}=this.options;t&&t()}cancel(){this.cancelTime!==null&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}}const YR=new Set(["opacity","clipPath","filter","transform"]);function XR(e,t,n,{delay:r=0,duration:o=300,repeat:i=0,repeatType:s="loop",ease:a="easeInOut",times:l}={}){const u={[t]:n};l&&(u.offset=l);const c=Ex(a,o);return Array.isArray(c)&&(u.easing=c),e.animate(u,{delay:r,duration:o,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:i+1,direction:s==="reverse"?"alternate":"normal"})}const qR=af(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),Ba=10,ZR=2e4;function JR(e){return Ef(e.type)||e.type==="spring"||!Sx(e.ease)}function e2(e,t){const n=new jf({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0});let r={done:!1,value:e[0]};const o=[];let i=0;for(;!r.done&&ithis.onKeyframesResolved(s,a),n,r,o),this.resolver.scheduleResolve()}initPlayback(t,n){let{duration:r=300,times:o,ease:i,type:s,motionValue:a,name:l,startTime:u}=this.options;if(!a.owner||!a.owner.current)return!1;if(typeof i=="string"&&Fa()&&t2(i)&&(i=rw[i]),JR(this.options)){const{onComplete:d,onUpdate:f,motionValue:h,element:v,...g}=this.options,x=e2(t,g);t=x.keyframes,t.length===1&&(t[1]=t[0]),r=x.duration,o=x.times,i=x.ease,s="keyframes"}const c=XR(a.owner.current,l,t,{...this.options,duration:r,times:o,ease:i});return c.startTime=u??this.calcStartTime(),this.pendingTimeline?(Up(c,this.pendingTimeline),this.pendingTimeline=void 0):c.onfinish=()=>{const{onComplete:d}=this.options;a.set(El(t,this.options,n)),d&&d(),this.cancel(),this.resolveFinishedPromise()},{animation:c,duration:r,times:o,type:s,ease:i,keyframes:t}}get duration(){const{resolved:t}=this;if(!t)return 0;const{duration:n}=t;return un(n)}get time(){const{resolved:t}=this;if(!t)return 0;const{animation:n}=t;return un(n.currentTime||0)}set time(t){const{resolved:n}=this;if(!n)return;const{animation:r}=n;r.currentTime=ln(t)}get speed(){const{resolved:t}=this;if(!t)return 1;const{animation:n}=t;return n.playbackRate}set speed(t){const{resolved:n}=this;if(!n)return;const{animation:r}=n;r.playbackRate=t}get state(){const{resolved:t}=this;if(!t)return"idle";const{animation:n}=t;return n.playState}get startTime(){const{resolved:t}=this;if(!t)return null;const{animation:n}=t;return n.startTime}attachTimeline(t){if(!this._resolved)this.pendingTimeline=t;else{const{resolved:n}=this;if(!n)return ot;const{animation:r}=n;Up(r,t)}return ot}play(){if(this.isStopped)return;const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.playState==="finished"&&this.updateFinishedPromise(),n.play()}pause(){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.resolveFinishedPromise(),this.updateFinishedPromise();const{resolved:t}=this;if(!t)return;const{animation:n,keyframes:r,duration:o,type:i,ease:s,times:a}=t;if(n.playState==="idle"||n.playState==="finished")return;if(this.time){const{motionValue:u,onUpdate:c,onComplete:d,element:f,...h}=this.options,v=new jf({...h,keyframes:r,duration:o,type:i,ease:s,times:a,isGenerator:!0}),g=ln(this.time);u.setWithVelocity(v.sample(g-Ba).value,v.sample(g).value,Ba)}const{onStop:l}=this.options;l&&l(),this.cancel()}complete(){const{resolved:t}=this;t&&t.animation.finish()}cancel(){const{resolved:t}=this;t&&t.animation.cancel()}static supports(t){const{motionValue:n,name:r,repeatDelay:o,repeatType:i,damping:s,type:a}=t;if(!n||!n.owner||!(n.owner.current instanceof HTMLElement))return!1;const{onUpdate:l,transformTemplate:u}=n.owner.getProps();return qR()&&r&&YR.has(r)&&!l&&!u&&!o&&i!=="mirror"&&s!==0&&a!=="inertia"}}const n2={type:"spring",stiffness:500,damping:25,restSpeed:10},r2=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),o2={type:"keyframes",duration:.8},i2={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},s2=(e,{keyframes:t})=>t.length>2?o2:Ir.has(e)?e.startsWith("scale")?r2(t[1]):n2:i2;function a2({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:o,repeat:i,repeatType:s,repeatDelay:a,from:l,elapsed:u,...c}){return!!Object.keys(c).length}const _f=(e,t,n,r={},o,i)=>s=>{const a=Sf(r,e)||{},l=a.delay||r.delay||0;let{elapsed:u=0}=r;u=u-ln(l);let c={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-u,onUpdate:f=>{t.set(f),a.onUpdate&&a.onUpdate(f)},onComplete:()=>{s(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:i?void 0:o};a2(a)||(c={...c,...s2(e,c)}),c.duration&&(c.duration=ln(c.duration)),c.repeatDelay&&(c.repeatDelay=ln(c.repeatDelay)),c.from!==void 0&&(c.keyframes[0]=c.from);let d=!1;if((c.type===!1||c.duration===0&&!c.repeatDelay)&&(c.duration=0,c.delay===0&&(d=!0)),d&&!i&&t.get()!==void 0){const f=El(c.keyframes,a);if(f!==void 0)return ae.update(()=>{c.onUpdate(f),c.onComplete()}),new kA([])}return!i&&sm.supports(c)?new sm(c):new jf(c)};function l2({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function ow(e,t,{delay:n=0,transitionOverride:r,type:o}={}){var i;let{transition:s=e.getDefaultTransition(),transitionEnd:a,...l}=t;r&&(s=r);const u=[],c=o&&e.animationState&&e.animationState.getState()[o];for(const d in l){const f=e.getValue(d,(i=e.latestValues[d])!==null&&i!==void 0?i:null),h=l[d];if(h===void 0||c&&l2(c,d))continue;const v={delay:n,...Sf(s||{},d)};let g=!1;if(window.MotionHandoffAnimation){const m=Ax(e);if(m){const p=window.MotionHandoffAnimation(m,d,ae);p!==null&&(v.startTime=p,g=!0)}}Oc(e,d),f.start(_f(d,f,h,e.shouldReduceMotion&&bx.has(d)?{type:!1}:v,e,g));const x=f.animation;x&&u.push(x)}return a&&Promise.all(u).then(()=>{ae.update(()=>{a&&BA(e,a)})}),u}function zc(e,t,n={}){var r;const o=Sl(e,t,n.type==="exit"?(r=e.presenceContext)===null||r===void 0?void 0:r.custom:void 0);let{transition:i=e.getDefaultTransition()||{}}=o||{};n.transitionOverride&&(i=n.transitionOverride);const s=o?()=>Promise.all(ow(e,o,n)):()=>Promise.resolve(),a=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:c=0,staggerChildren:d,staggerDirection:f}=i;return u2(e,t,c+u,d,f,n)}:()=>Promise.resolve(),{when:l}=i;if(l){const[u,c]=l==="beforeChildren"?[s,a]:[a,s];return u().then(()=>c())}else return Promise.all([s(),a(n.delay)])}function u2(e,t,n=0,r=0,o=1,i){const s=[],a=(e.variantChildren.size-1)*r,l=o===1?(u=0)=>u*r:(u=0)=>a-u*r;return Array.from(e.variantChildren).sort(c2).forEach((u,c)=>{u.notify("AnimationStart",t),s.push(zc(u,t,{...i,delay:n+l(c)}).then(()=>u.notify("AnimationComplete",t)))}),Promise.all(s)}function c2(e,t){return e.sortNodePosition(t)}function d2(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const o=t.map(i=>zc(e,i,n));r=Promise.all(o)}else if(typeof t=="string")r=zc(e,t,n);else{const o=typeof t=="function"?Sl(e,t,n.custom):t;r=Promise.all(ow(e,o,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}const f2=uf.length;function iw(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?iw(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;nPromise.all(t.map(({animation:n,options:r})=>d2(e,n,r)))}function g2(e){let t=m2(e),n=am(),r=!0;const o=l=>(u,c)=>{var d;const f=Sl(e,c,l==="exit"?(d=e.presenceContext)===null||d===void 0?void 0:d.custom:void 0);if(f){const{transition:h,transitionEnd:v,...g}=f;u={...u,...g,...v}}return u};function i(l){t=l(e)}function s(l){const{props:u}=e,c=iw(e.parent)||{},d=[],f=new Set;let h={},v=1/0;for(let x=0;xv&&S,D=!1;const N=Array.isArray(y)?y:[y];let V=N.reduce(o(m),{});C===!1&&(V={});const{prevResolvedValues:_={}}=p,G={..._,...V},L=F=>{b=!0,f.has(F)&&(D=!0,f.delete(F)),p.needsAnimating[F]=!0;const k=e.getValue(F);k&&(k.liveStyle=!1)};for(const F in G){const k=V[F],R=_[F];if(h.hasOwnProperty(F))continue;let j=!1;Mc(k)&&Mc(R)?j=!vx(k,R):j=k!==R,j?k!=null?L(F):f.add(F):k!==void 0&&f.has(F)?L(F):p.protectedKeys[F]=!0}p.prevProp=y,p.prevResolvedValues=V,p.isActive&&(h={...h,...V}),r&&e.blockInitialAnimation&&(b=!1),b&&(!(P&&T)||D)&&d.push(...N.map(F=>({animation:F,options:{type:m}})))}if(f.size){const x={};f.forEach(m=>{const p=e.getBaseTarget(m),y=e.getValue(m);y&&(y.liveStyle=!0),x[m]=p??null}),d.push({animation:x})}let g=!!d.length;return r&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(g=!1),r=!1,g?t(d):Promise.resolve()}function a(l,u){var c;if(n[l].isActive===u)return Promise.resolve();(c=e.variantChildren)===null||c===void 0||c.forEach(f=>{var h;return(h=f.animationState)===null||h===void 0?void 0:h.setActive(l,u)}),n[l].isActive=u;const d=s(l);for(const f in n)n[f].protectedKeys={};return d}return{animateChanges:s,setActive:a,setAnimateFunction:i,getState:()=>n,reset:()=>{n=am(),r=!0}}}function y2(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!vx(t,e):!1}function cr(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function am(){return{animate:cr(!0),whileInView:cr(),whileHover:cr(),whileTap:cr(),whileDrag:cr(),whileFocus:cr(),exit:cr()}}class sr{constructor(t){this.isMounted=!1,this.node=t}update(){}}class v2 extends sr{constructor(t){super(t),t.animationState||(t.animationState=g2(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();xl(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)===null||t===void 0||t.call(this)}}let x2=0;class w2 extends sr{constructor(){super(...arguments),this.id=x2++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;const o=this.node.animationState.setActive("exit",!t);n&&!t&&o.then(()=>n(this.id))}mount(){const{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}}const S2={animation:{Feature:v2},exit:{Feature:w2}};function qi(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function ds(e){return{point:{x:e.pageX,y:e.pageY}}}const E2=e=>t=>Pf(t)&&e(t,ds(t));function Ci(e,t,n,r){return qi(e,t,E2(n),r)}const lm=(e,t)=>Math.abs(e-t);function C2(e,t){const n=lm(e.x,t.x),r=lm(e.y,t.y);return Math.sqrt(n**2+r**2)}class sw{constructor(t,n,{transformPagePoint:r,contextWindow:o,dragSnapToOrigin:i=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const d=pu(this.lastMoveEventInfo,this.history),f=this.startEvent!==null,h=C2(d.offset,{x:0,y:0})>=3;if(!f&&!h)return;const{point:v}=d,{timestamp:g}=ke;this.history.push({...v,timestamp:g});const{onStart:x,onMove:m}=this.handlers;f||(x&&x(this.lastMoveEvent,d),this.startEvent=this.lastMoveEvent),m&&m(this.lastMoveEvent,d)},this.handlePointerMove=(d,f)=>{this.lastMoveEvent=d,this.lastMoveEventInfo=hu(f,this.transformPagePoint),ae.update(this.updatePoint,!0)},this.handlePointerUp=(d,f)=>{this.end();const{onEnd:h,onSessionEnd:v,resumeAnimation:g}=this.handlers;if(this.dragSnapToOrigin&&g&&g(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const x=pu(d.type==="pointercancel"?this.lastMoveEventInfo:hu(f,this.transformPagePoint),this.history);this.startEvent&&h&&h(d,x),v&&v(d,x)},!Pf(t))return;this.dragSnapToOrigin=i,this.handlers=n,this.transformPagePoint=r,this.contextWindow=o||window;const s=ds(t),a=hu(s,this.transformPagePoint),{point:l}=a,{timestamp:u}=ke;this.history=[{...l,timestamp:u}];const{onSessionStart:c}=n;c&&c(t,pu(a,this.history)),this.removeListeners=cs(Ci(this.contextWindow,"pointermove",this.handlePointerMove),Ci(this.contextWindow,"pointerup",this.handlePointerUp),Ci(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),tr(this.updatePoint)}}function hu(e,t){return t?{point:t(e.point)}:e}function um(e,t){return{x:e.x-t.x,y:e.y-t.y}}function pu({point:e},t){return{point:e,delta:um(e,aw(t)),offset:um(e,P2(t)),velocity:T2(t,.1)}}function P2(e){return e[0]}function aw(e){return e[e.length-1]}function T2(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const o=aw(e);for(;n>=0&&(r=e[n],!(o.timestamp-r.timestamp>ln(t)));)n--;if(!r)return{x:0,y:0};const i=un(o.timestamp-r.timestamp);if(i===0)return{x:0,y:0};const s={x:(o.x-r.x)/i,y:(o.y-r.y)/i};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}const lw=1e-4,b2=1-lw,k2=1+lw,uw=.01,A2=0-uw,R2=0+uw;function at(e){return e.max-e.min}function M2(e,t,n){return Math.abs(e-t)<=n}function cm(e,t,n,r=.5){e.origin=r,e.originPoint=de(t.min,t.max,e.origin),e.scale=at(n)/at(t),e.translate=de(n.min,n.max,e.origin)-e.originPoint,(e.scale>=b2&&e.scale<=k2||isNaN(e.scale))&&(e.scale=1),(e.translate>=A2&&e.translate<=R2||isNaN(e.translate))&&(e.translate=0)}function Pi(e,t,n,r){cm(e.x,t.x,n.x,r?r.originX:void 0),cm(e.y,t.y,n.y,r?r.originY:void 0)}function dm(e,t,n){e.min=n.min+t.min,e.max=e.min+at(t)}function N2(e,t,n){dm(e.x,t.x,n.x),dm(e.y,t.y,n.y)}function fm(e,t,n){e.min=t.min-n.min,e.max=e.min+at(t)}function Ti(e,t,n){fm(e.x,t.x,n.x),fm(e.y,t.y,n.y)}function D2(e,{min:t,max:n},r){return t!==void 0&&en&&(e=r?de(n,e,r.max):Math.min(e,n)),e}function hm(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function O2(e,{top:t,left:n,bottom:r,right:o}){return{x:hm(e.x,n,o),y:hm(e.y,t,r)}}function pm(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.minr?n=jo(t.min,t.max-r,e.min):r>o&&(n=jo(e.min,e.max-o,t.min)),gn(0,1,n)}function _2(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Bc=.35;function I2(e=Bc){return e===!1?e=0:e===!0&&(e=Bc),{x:mm(e,"left","right"),y:mm(e,"top","bottom")}}function mm(e,t,n){return{min:gm(e,t),max:gm(e,n)}}function gm(e,t){return typeof e=="number"?e:e[t]||0}const ym=()=>({translate:0,scale:1,origin:0,originPoint:0}),io=()=>({x:ym(),y:ym()}),vm=()=>({min:0,max:0}),ye=()=>({x:vm(),y:vm()});function ft(e){return[e("x"),e("y")]}function cw({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function F2({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function V2(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function mu(e){return e===void 0||e===1}function $c({scale:e,scaleX:t,scaleY:n}){return!mu(e)||!mu(t)||!mu(n)}function hr(e){return $c(e)||dw(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function dw(e){return xm(e.x)||xm(e.y)}function xm(e){return e&&e!=="0%"}function $a(e,t,n){const r=e-n,o=t*r;return n+o}function wm(e,t,n,r,o){return o!==void 0&&(e=$a(e,o,r)),$a(e,n,r)+t}function Uc(e,t=0,n=1,r,o){e.min=wm(e.min,t,n,r,o),e.max=wm(e.max,t,n,r,o)}function fw(e,{x:t,y:n}){Uc(e.x,t.translate,t.scale,t.originPoint),Uc(e.y,n.translate,n.scale,n.originPoint)}const Sm=.999999999999,Em=1.0000000000001;function z2(e,t,n,r=!1){const o=n.length;if(!o)return;t.x=t.y=1;let i,s;for(let a=0;aSm&&(t.x=1),t.ySm&&(t.y=1)}function so(e,t){e.min=e.min+t,e.max=e.max+t}function Cm(e,t,n,r,o=.5){const i=de(e.min,e.max,o);Uc(e,t,n,i,r)}function ao(e,t){Cm(e.x,t.x,t.scaleX,t.scale,t.originX),Cm(e.y,t.y,t.scaleY,t.scale,t.originY)}function hw(e,t){return cw(V2(e.getBoundingClientRect(),t))}function B2(e,t,n){const r=hw(e,n),{scroll:o}=t;return o&&(so(r.x,o.offset.x),so(r.y,o.offset.y)),r}const pw=({current:e})=>e?e.ownerDocument.defaultView:null,$2=new WeakMap;class U2{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=ye(),this.visualElement=t}start(t,{snapToCursor:n=!1}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const o=c=>{const{dragSnapToOrigin:d}=this.getProps();d?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(ds(c).point)},i=(c,d)=>{const{drag:f,dragPropagation:h,onDragStart:v}=this.getProps();if(f&&!h&&(this.openDragLock&&this.openDragLock(),this.openDragLock=_A(f),!this.openDragLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),ft(x=>{let m=this.getAxisMotionValue(x).get()||0;if(Qt.test(m)){const{projection:p}=this.visualElement;if(p&&p.layout){const y=p.layout.layoutBox[x];y&&(m=at(y)*(parseFloat(m)/100))}}this.originPoint[x]=m}),v&&ae.postRender(()=>v(c,d)),Oc(this.visualElement,"transform");const{animationState:g}=this.visualElement;g&&g.setActive("whileDrag",!0)},s=(c,d)=>{const{dragPropagation:f,dragDirectionLock:h,onDirectionLock:v,onDrag:g}=this.getProps();if(!f&&!this.openDragLock)return;const{offset:x}=d;if(h&&this.currentDirection===null){this.currentDirection=W2(x),this.currentDirection!==null&&v&&v(this.currentDirection);return}this.updateAxis("x",d.point,x),this.updateAxis("y",d.point,x),this.visualElement.render(),g&&g(c,d)},a=(c,d)=>this.stop(c,d),l=()=>ft(c=>{var d;return this.getAnimationState(c)==="paused"&&((d=this.getAxisMotionValue(c).animation)===null||d===void 0?void 0:d.play())}),{dragSnapToOrigin:u}=this.getProps();this.panSession=new sw(t,{onSessionStart:o,onStart:i,onMove:s,onSessionEnd:a,resumeAnimation:l},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,contextWindow:pw(this.visualElement)})}stop(t,n){const r=this.isDragging;if(this.cancel(),!r)return;const{velocity:o}=n;this.startAnimation(o);const{onDragEnd:i}=this.getProps();i&&ae.postRender(()=>i(t,n))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:o}=this.getProps();if(!r||!zs(t,o,this.currentDirection))return;const i=this.getAxisMotionValue(t);let s=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(s=D2(s,this.constraints[t],this.elastic[t])),i.set(s)}resolveConstraints(){var t;const{dragConstraints:n,dragElastic:r}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(t=this.visualElement.projection)===null||t===void 0?void 0:t.layout,i=this.constraints;n&&ro(n)?this.constraints||(this.constraints=this.resolveRefConstraints()):n&&o?this.constraints=O2(o.layoutBox,n):this.constraints=!1,this.elastic=I2(r),i!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&ft(s=>{this.constraints!==!1&&this.getAxisMotionValue(s)&&(this.constraints[s]=_2(o.layoutBox[s],this.constraints[s]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!ro(t))return!1;const r=t.current,{projection:o}=this.visualElement;if(!o||!o.layout)return!1;const i=B2(r,o.root,this.visualElement.getTransformPagePoint());let s=L2(o.layout.layoutBox,i);if(n){const a=n(F2(s));this.hasMutatedConstraints=!!a,a&&(s=cw(a))}return s}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:o,dragTransition:i,dragSnapToOrigin:s,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},u=ft(c=>{if(!zs(c,n,this.currentDirection))return;let d=l&&l[c]||{};s&&(d={min:0,max:0});const f=o?200:1e6,h=o?40:1e7,v={type:"inertia",velocity:r?t[c]:0,bounceStiffness:f,bounceDamping:h,timeConstant:750,restDelta:1,restSpeed:10,...i,...d};return this.startAxisValueAnimation(c,v)});return Promise.all(u).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return Oc(this.visualElement,t),r.start(_f(t,r,0,n,this.visualElement,!1))}stopAnimation(){ft(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){ft(t=>{var n;return(n=this.getAxisMotionValue(t).animation)===null||n===void 0?void 0:n.pause()})}getAnimationState(t){var n;return(n=this.getAxisMotionValue(t).animation)===null||n===void 0?void 0:n.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),o=r[n];return o||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){ft(n=>{const{drag:r}=this.getProps();if(!zs(n,r,this.currentDirection))return;const{projection:o}=this.visualElement,i=this.getAxisMotionValue(n);if(o&&o.layout){const{min:s,max:a}=o.layout.layoutBox[n];i.set(t[n]-de(s,a,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!ro(n)||!r||!this.constraints)return;this.stopAnimation();const o={x:0,y:0};ft(s=>{const a=this.getAxisMotionValue(s);if(a&&this.constraints!==!1){const l=a.get();o[s]=j2({min:l,max:l},this.constraints[s])}});const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),ft(s=>{if(!zs(s,t,null))return;const a=this.getAxisMotionValue(s),{min:l,max:u}=this.constraints[s];a.set(de(l,u,o[s]))})}addListeners(){if(!this.visualElement.current)return;$2.set(this.visualElement,this);const t=this.visualElement.current,n=Ci(t,"pointerdown",l=>{const{drag:u,dragListener:c=!0}=this.getProps();u&&c&&this.start(l)}),r=()=>{const{dragConstraints:l}=this.getProps();ro(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:o}=this.visualElement,i=o.addEventListener("measure",r);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),ae.read(r);const s=qi(window,"resize",()=>this.scalePositionWithinConstraints()),a=o.addEventListener("didUpdate",({delta:l,hasLayoutChanged:u})=>{this.isDragging&&u&&(ft(c=>{const d=this.getAxisMotionValue(c);d&&(this.originPoint[c]+=l[c].translate,d.set(d.get()+l[c].translate))}),this.visualElement.render())});return()=>{s(),n(),i(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:o=!1,dragConstraints:i=!1,dragElastic:s=Bc,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:o,dragConstraints:i,dragElastic:s,dragMomentum:a}}}function zs(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function W2(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class H2 extends sr{constructor(t){super(t),this.removeGroupControls=ot,this.removeListeners=ot,this.controls=new U2(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||ot}unmount(){this.removeGroupControls(),this.removeListeners()}}const Pm=e=>(t,n)=>{e&&ae.postRender(()=>e(t,n))};class K2 extends sr{constructor(){super(...arguments),this.removePointerDownListener=ot}onPointerDown(t){this.session=new sw(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:pw(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:o}=this.node.getProps();return{onSessionStart:Pm(t),onStart:Pm(n),onMove:r,onEnd:(i,s)=>{delete this.session,o&&ae.postRender(()=>o(i,s))}}}mount(){this.removePointerDownListener=Ci(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const oa={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function Tm(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const oi={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(B.test(e))e=parseFloat(e);else return e;const n=Tm(e,t.target.x),r=Tm(e,t.target.y);return`${n}% ${r}%`}},G2={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,o=nr.parse(e);if(o.length>5)return r;const i=nr.createTransformer(e),s=typeof o[0]!="number"?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;o[0+s]/=a,o[1+s]/=l;const u=de(a,l,.5);return typeof o[2+s]=="number"&&(o[2+s]/=u),typeof o[3+s]=="number"&&(o[3+s]/=u),i(o)}};class Q2 extends w.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:o}=this.props,{projection:i}=t;mA(Y2),i&&(n.group&&n.group.add(i),r&&r.register&&o&&r.register(i),i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),oa.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:o,isPresent:i}=this.props,s=r.projection;return s&&(s.isPresent=i,o||t.layoutDependency!==n||n===void 0?s.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?s.promote():s.relegate()||ae.postRender(()=>{const a=s.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),df.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:o}=t;o&&(o.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(o),r&&r.deregister&&r.deregister(o))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function mw(e){const[t,n]=Mk(),r=w.useContext(Z0);return E.jsx(Q2,{...e,layoutGroup:r,switchLayoutGroup:w.useContext(ix),isPresent:t,safeToRemove:n})}const Y2={borderRadius:{...oi,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:oi,borderTopRightRadius:oi,borderBottomLeftRadius:oi,borderBottomRightRadius:oi,boxShadow:G2};function X2(e,t,n){const r=Ie(e)?e:Yi(e);return r.start(_f("",r,t,n)),r.animation}function q2(e){return e instanceof SVGElement&&e.tagName!=="svg"}const Z2=(e,t)=>e.depth-t.depth;class J2{constructor(){this.children=[],this.isDirty=!1}add(t){Tf(this.children,t),this.isDirty=!0}remove(t){bf(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(Z2),this.isDirty=!1,this.children.forEach(t)}}function eM(e,t){const n=Yt.now(),r=({timestamp:o})=>{const i=o-n;i>=t&&(tr(r),e(i-t))};return ae.read(r,!0),()=>tr(r)}const gw=["TopLeft","TopRight","BottomLeft","BottomRight"],tM=gw.length,bm=e=>typeof e=="string"?parseFloat(e):e,km=e=>typeof e=="number"||B.test(e);function nM(e,t,n,r,o,i){o?(e.opacity=de(0,n.opacity!==void 0?n.opacity:1,rM(r)),e.opacityExit=de(t.opacity!==void 0?t.opacity:1,0,oM(r))):i&&(e.opacity=de(t.opacity!==void 0?t.opacity:1,n.opacity!==void 0?n.opacity:1,r));for(let s=0;srt?1:n(jo(e,t,r))}function Rm(e,t){e.min=t.min,e.max=t.max}function dt(e,t){Rm(e.x,t.x),Rm(e.y,t.y)}function Mm(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function Nm(e,t,n,r,o){return e-=t,e=$a(e,1/n,r),o!==void 0&&(e=$a(e,1/o,r)),e}function iM(e,t=0,n=1,r=.5,o,i=e,s=e){if(Qt.test(t)&&(t=parseFloat(t),t=de(s.min,s.max,t/100)-s.min),typeof t!="number")return;let a=de(i.min,i.max,r);e===i&&(a-=t),e.min=Nm(e.min,t,n,a,o),e.max=Nm(e.max,t,n,a,o)}function Dm(e,t,[n,r,o],i,s){iM(e,t[n],t[r],t[o],t.scale,i,s)}const sM=["x","scaleX","originX"],aM=["y","scaleY","originY"];function Om(e,t,n,r){Dm(e.x,t,sM,n?n.x:void 0,r?r.x:void 0),Dm(e.y,t,aM,n?n.y:void 0,r?r.y:void 0)}function Lm(e){return e.translate===0&&e.scale===1}function vw(e){return Lm(e.x)&&Lm(e.y)}function jm(e,t){return e.min===t.min&&e.max===t.max}function lM(e,t){return jm(e.x,t.x)&&jm(e.y,t.y)}function _m(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function xw(e,t){return _m(e.x,t.x)&&_m(e.y,t.y)}function Im(e){return at(e.x)/at(e.y)}function Fm(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class uM{constructor(){this.members=[]}add(t){Tf(this.members,t),t.scheduleRender()}remove(t){if(bf(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(o=>t===o);if(n===0)return!1;let r;for(let o=n;o>=0;o--){const i=this.members[o];if(i.isPresent!==!1){r=i;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:o}=t.options;o===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function cM(e,t,n){let r="";const o=e.x.translate/t.x,i=e.y.translate/t.y,s=(n==null?void 0:n.z)||0;if((o||i||s)&&(r=`translate3d(${o}px, ${i}px, ${s}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:u,rotate:c,rotateX:d,rotateY:f,skewX:h,skewY:v}=n;u&&(r=`perspective(${u}px) ${r}`),c&&(r+=`rotate(${c}deg) `),d&&(r+=`rotateX(${d}deg) `),f&&(r+=`rotateY(${f}deg) `),h&&(r+=`skewX(${h}deg) `),v&&(r+=`skewY(${v}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return(a!==1||l!==1)&&(r+=`scale(${a}, ${l})`),r||"none"}const pr={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},di=typeof window<"u"&&window.MotionDebug!==void 0,gu=["","X","Y","Z"],dM={visibility:"hidden"},Vm=1e3;let fM=0;function yu(e,t,n,r){const{latestValues:o}=t;o[e]&&(n[e]=o[e],t.setStaticValue(e,0),r&&(r[e]=0))}function ww(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=Ax(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:o,layoutId:i}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",ae,!(o||i))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&ww(r)}function Sw({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(s={},a=t==null?void 0:t()){this.id=fM++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,di&&(pr.totalNodes=pr.resolvedTargetDeltas=pr.recalculatedProjection=0),this.nodes.forEach(mM),this.nodes.forEach(wM),this.nodes.forEach(SM),this.nodes.forEach(gM),di&&window.MotionDebug.record(pr)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;lthis.root.updateBlockedByResize=!1;e(s,()=>{this.root.updateBlockedByResize=!0,d&&d(),d=eM(f,250),oa.hasAnimatedSinceResize&&(oa.hasAnimatedSinceResize=!1,this.nodes.forEach(Bm))})}l&&this.root.registerSharedNode(l,this),this.options.animate!==!1&&c&&(l||u)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:f,hasRelativeTargetChanged:h,layout:v})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const g=this.options.transition||c.getDefaultTransition()||bM,{onLayoutAnimationStart:x,onLayoutAnimationComplete:m}=c.getProps(),p=!this.targetLayout||!xw(this.targetLayout,v)||h,y=!f&&h;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||y||f&&(p||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(d,y);const S={...Sf(g,"layout"),onPlay:x,onComplete:m};(c.shouldReduceMotion||this.options.layoutRoot)&&(S.delay=0,S.type=!1),this.startAnimation(S)}else f||Bm(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=v})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,tr(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(EM),this.animationId++)}getTransformTemplate(){const{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&ww(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let c=0;c{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l{const C=S/1e3;$m(d.x,s.x,C),$m(d.y,s.y,C),this.setTargetDelta(d),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Ti(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox),PM(this.relativeTarget,this.relativeTargetOrigin,f,C),y&&lM(this.relativeTarget,y)&&(this.isProjectionDirty=!1),y||(y=ye()),dt(y,this.relativeTarget)),g&&(this.animationValues=c,nM(c,u,this.latestValues,C,p,m)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=C},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(tr(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=ae.update(()=>{oa.hasAnimatedSinceResize=!0,this.currentAnimation=X2(0,Vm,{...s,onUpdate:a=>{this.mixTargetDelta(a),s.onUpdate&&s.onUpdate(a)},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Vm),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:a,target:l,layout:u,latestValues:c}=s;if(!(!a||!l||!u)){if(this!==s&&this.layout&&u&&Ew(this.options.animationType,this.layout.layoutBox,u.layoutBox)){l=this.target||ye();const d=at(this.layout.layoutBox.x);l.x.min=s.target.x.min,l.x.max=l.x.min+d;const f=at(this.layout.layoutBox.y);l.y.min=s.target.y.min,l.y.max=l.y.min+f}dt(a,l),ao(a,c),Pi(this.projectionDeltaWithTransform,this.layoutCorrected,a,c)}}registerSharedNode(s,a){this.sharedNodes.has(s)||this.sharedNodes.set(s,new uM),this.sharedNodes.get(s).add(a);const u=a.options.initialPromotionConfig;a.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(a):void 0})}isLead(){const s=this.getStack();return s?s.lead===this:!0}getLead(){var s;const{layoutId:a}=this.options;return a?((s=this.getStack())===null||s===void 0?void 0:s.lead)||this:this}getPrevLead(){var s;const{layoutId:a}=this.options;return a?(s=this.getStack())===null||s===void 0?void 0:s.prevLead:void 0}getStack(){const{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:a,preserveFollowOpacity:l}={}){const u=this.getStack();u&&u.promote(this,l),s&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){const{visualElement:s}=this.options;if(!s)return;let a=!1;const{latestValues:l}=s;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const u={};l.z&&yu("z",s,u,this.animationValues);for(let c=0;c{var a;return(a=s.currentAnimation)===null||a===void 0?void 0:a.stop()}),this.root.nodes.forEach(zm),this.root.sharedNodes.clear()}}}function hM(e){e.updateLayout()}function pM(e){var t;const n=((t=e.resumeFrom)===null||t===void 0?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:o}=e.layout,{animationType:i}=e.options,s=n.source!==e.layout.source;i==="size"?ft(d=>{const f=s?n.measuredBox[d]:n.layoutBox[d],h=at(f);f.min=r[d].min,f.max=f.min+h}):Ew(i,n.layoutBox,r)&&ft(d=>{const f=s?n.measuredBox[d]:n.layoutBox[d],h=at(r[d]);f.max=f.min+h,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+h)});const a=io();Pi(a,r,n.layoutBox);const l=io();s?Pi(l,e.applyTransform(o,!0),n.measuredBox):Pi(l,r,n.layoutBox);const u=!vw(a);let c=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:f,layout:h}=d;if(f&&h){const v=ye();Ti(v,n.layoutBox,f.layoutBox);const g=ye();Ti(g,r,h.layoutBox),xw(v,g)||(c=!0),d.options.layoutRoot&&(e.relativeTarget=g,e.relativeTargetOrigin=v,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:n,delta:l,layoutDelta:a,hasLayoutChanged:u,hasRelativeTargetChanged:c})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function mM(e){di&&pr.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function gM(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function yM(e){e.clearSnapshot()}function zm(e){e.clearMeasurements()}function vM(e){e.isLayoutDirty=!1}function xM(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Bm(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function wM(e){e.resolveTargetDelta()}function SM(e){e.calcProjection()}function EM(e){e.resetSkewAndRotation()}function CM(e){e.removeLeadSnapshot()}function $m(e,t,n){e.translate=de(t.translate,0,n),e.scale=de(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Um(e,t,n,r){e.min=de(t.min,n.min,r),e.max=de(t.max,n.max,r)}function PM(e,t,n,r){Um(e.x,t.x,n.x,r),Um(e.y,t.y,n.y,r)}function TM(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const bM={duration:.45,ease:[.4,0,.1,1]},Wm=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Hm=Wm("applewebkit/")&&!Wm("chrome/")?Math.round:ot;function Km(e){e.min=Hm(e.min),e.max=Hm(e.max)}function kM(e){Km(e.x),Km(e.y)}function Ew(e,t,n){return e==="position"||e==="preserve-aspect"&&!M2(Im(t),Im(n),.2)}function AM(e){var t;return e!==e.root&&((t=e.scroll)===null||t===void 0?void 0:t.wasRoot)}const RM=Sw({attachResizeListener:(e,t)=>qi(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),vu={current:void 0},Cw=Sw({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!vu.current){const e=new RM({});e.mount(window),e.setOptions({layoutScroll:!0}),vu.current=e}return vu.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),MM={pan:{Feature:K2},drag:{Feature:H2,ProjectionNode:Cw,MeasureLayout:mw}};function Gm(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const o="onHover"+n,i=r[o];i&&ae.postRender(()=>i(t,ds(t)))}class NM extends sr{mount(){const{current:t}=this.node;t&&(this.unmount=NA(t,n=>(Gm(this.node,n,"Start"),r=>Gm(this.node,r,"End"))))}unmount(){}}class DM extends sr{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=cs(qi(this.node.current,"focus",()=>this.onFocus()),qi(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Qm(e,t,n){const{props:r}=e;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const o="onTap"+(n==="End"?"":n),i=r[o];i&&ae.postRender(()=>i(t,ds(t)))}class OM extends sr{mount(){const{current:t}=this.node;t&&(this.unmount=jA(t,n=>(Qm(this.node,n,"Start"),(r,{success:o})=>Qm(this.node,r,o?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Wc=new WeakMap,xu=new WeakMap,LM=e=>{const t=Wc.get(e.target);t&&t(e)},jM=e=>{e.forEach(LM)};function _M({root:e,...t}){const n=e||document;xu.has(n)||xu.set(n,{});const r=xu.get(n),o=JSON.stringify(t);return r[o]||(r[o]=new IntersectionObserver(jM,{root:e,...t})),r[o]}function IM(e,t,n){const r=_M(t);return Wc.set(e,n),r.observe(e),()=>{Wc.delete(e),r.unobserve(e)}}const FM={some:0,all:1};class VM extends sr{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:o="some",once:i}=t,s={root:n?n.current:void 0,rootMargin:r,threshold:typeof o=="number"?o:FM[o]},a=l=>{const{isIntersecting:u}=l;if(this.isInView===u||(this.isInView=u,i&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:c,onViewportLeave:d}=this.node.getProps(),f=u?c:d;f&&f(l)};return IM(this.node.current,s,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(zM(t,n))&&this.startObserver()}unmount(){}}function zM({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const BM={inView:{Feature:VM},tap:{Feature:OM},focus:{Feature:DM},hover:{Feature:NM}},$M={layout:{ProjectionNode:Cw,MeasureLayout:mw}},Hc={current:null},Pw={current:!1};function UM(){if(Pw.current=!0,!!sf)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Hc.current=e.matches;e.addListener(t),t()}else Hc.current=!1}const WM=[...Yx,je,nr],HM=e=>WM.find(Qx(e)),Ym=new WeakMap;function KM(e,t,n){for(const r in t){const o=t[r],i=n[r];if(Ie(o))e.addValue(r,o);else if(Ie(i))e.addValue(r,Yi(o,{owner:e}));else if(i!==o)if(e.hasValue(r)){const s=e.getValue(r);s.liveStyle===!0?s.jump(o):s.hasAnimated||s.set(o)}else{const s=e.getStaticValue(r);e.addValue(r,Yi(s!==void 0?s:o,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const Xm=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class GM{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:o,blockInitialAnimation:i,visualState:s},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Of,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const h=Yt.now();this.renderScheduledAtthis.bindToMotionValue(r,n)),Pw.current||UM(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Hc.current,this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){Ym.delete(this.current),this.projection&&this.projection.unmount(),tr(this.notifyUpdate),tr(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const n=this.features[t];n&&(n.unmount(),n.isMounted=!1)}this.current=null}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const r=Ir.has(t),o=n.on("change",a=>{this.latestValues[t]=a,this.props.onUpdate&&ae.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0)}),i=n.on("renderRequest",this.scheduleRender);let s;window.MotionCheckAppearSync&&(s=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{o(),i(),s&&s(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in _o){const n=_o[t];if(!n)continue;const{isEnabled:r,Feature:o}=n;if(!this.features[t]&&o&&r(this.props)&&(this.features[t]=new o(this)),this.features[t]){const i=this.features[t];i.isMounted?i.update():(i.mount(),i.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):ye()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;rn.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Yi(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){var r;let o=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(r=this.getBaseTargetFromProps(this.props,t))!==null&&r!==void 0?r:this.readValueFromInstance(this.current,t,this.options);return o!=null&&(typeof o=="string"&&(Kx(o)||Ix(o))?o=parseFloat(o):!HM(o)&&nr.test(n)&&(o=Ux(t,n)),this.setBaseTarget(t,Ie(o)?o.get():o)),Ie(o)?o.get():o}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var n;const{initial:r}=this.props;let o;if(typeof r=="string"||typeof r=="object"){const s=hf(this.props,r,(n=this.presenceContext)===null||n===void 0?void 0:n.custom);s&&(o=s[t])}if(r&&o!==void 0)return o;const i=this.getBaseTargetFromProps(this.props,t);return i!==void 0&&!Ie(i)?i:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new kf),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}}class Tw extends GM{constructor(){super(...arguments),this.KeyframeResolver=Xx}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Ie(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function QM(e){return window.getComputedStyle(e)}class YM extends Tw{constructor(){super(...arguments),this.type="html",this.renderInstance=fx}readValueFromInstance(t,n){if(Ir.has(n)){const r=Df(n);return r&&r.default||0}else{const r=QM(t),o=(ux(n)?r.getPropertyValue(n):r[n])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:n}){return hw(t,n)}build(t,n,r){gf(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return wf(t,n,r)}}class XM extends Tw{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=ye}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Ir.has(n)){const r=Df(n);return r&&r.default||0}return n=hx.has(n)?n:cf(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return gx(t,n,r)}build(t,n,r){yf(t,n,this.isSVGTag,r.transformTemplate)}renderInstance(t,n,r,o){px(t,n,r,o)}mount(t){this.isSVGTag=xf(t.tagName),super.mount(t)}}const qM=(e,t)=>ff(e)?new XM(t):new YM(t,{allowProjection:e!==w.Fragment}),ZM=PA({...S2,...BM,...MM,...$M},qM),it=Vk(ZM),JM="/assets/hero-dashboard-BeVMuCSW.png",eN=()=>E.jsxs("section",{className:"relative min-h-screen flex items-center overflow-hidden",children:[E.jsx("div",{className:"absolute inset-0 gradient-radial"}),E.jsx("div",{className:"absolute top-0 left-1/2 -translate-x-1/2 w-[800px] h-[800px] rounded-full bg-primary/5 blur-[120px]"}),E.jsx("div",{className:"container mx-auto px-4 py-20 relative z-10",children:E.jsxs("div",{className:"grid lg:grid-cols-2 gap-12 items-center",children:[E.jsxs(it.div,{initial:{opacity:0,x:-40},animate:{opacity:1,x:0},transition:{duration:.7},children:[E.jsxs("div",{className:"inline-flex items-center gap-2 px-4 py-2 rounded-full border border-primary/30 bg-primary/10 mb-6",children:[E.jsx("span",{className:"w-2 h-2 rounded-full bg-primary animate-pulse-neon"}),E.jsx("span",{className:"text-sm text-primary font-medium",children:"🚀 Lançamento Exclusivo"})]}),E.jsxs("h1",{className:"text-4xl md:text-5xl lg:text-6xl font-extrabold leading-tight mb-6",children:["PARE DE PERDER TEMPO!"," ",E.jsx("span",{className:"text-primary neon-text",children:"TURBINE SUAS VENDAS COM WHATSAPP PRO"})]}),E.jsx("p",{className:"text-lg md:text-xl text-muted-foreground mb-8 max-w-lg",children:"Automatize mensagens, gere leads e venda todos os dias no automático."}),E.jsx(it.a,{href:"#oferta",whileHover:{scale:1.05},whileTap:{scale:.97},className:"inline-flex items-center gap-3 px-8 py-4 rounded-lg bg-primary text-primary-foreground font-bold text-lg neon-glow hover:brightness-110 transition-all",children:"👉 QUERO VENDER TODOS OS DIAS"}),E.jsxs("div",{className:"flex items-center gap-6 mt-8 text-sm text-muted-foreground",children:[E.jsx("span",{className:"flex items-center gap-2",children:"🔒 Compra segura"}),E.jsx("span",{className:"flex items-center gap-2",children:"⚡ Acesso imediato"})]})]}),E.jsx(it.div,{initial:{opacity:0,y:40},animate:{opacity:1,y:0},transition:{duration:.7,delay:.3},className:"relative",children:E.jsxs("div",{className:"relative rounded-2xl overflow-hidden neon-border border-2 animate-float",children:[E.jsx("img",{src:JM,alt:"Wsender Plus - Sistema de automação WhatsApp",className:"w-full h-auto rounded-2xl"}),E.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-background/60 to-transparent"})]})})]})})]}),tN=[{icon:JP,title:"Disparos em massa ilimitados",desc:"Envie milhares de mensagens com poucos cliques."},{icon:oT,title:"Extrator de contatos e leads",desc:"Extraia contatos de grupos e crie listas segmentadas."},{icon:qP,title:"Bot inteligente 24h",desc:"Responda automaticamente e converta enquanto dorme."},{icon:rT,title:"Geração automática de clientes",desc:"Funil automatizado que traz clientes todos os dias."},{icon:sT,title:"Fácil de usar",desc:"Mesmo para iniciantes, sem conhecimento técnico."}],nN=()=>E.jsxs("section",{className:"py-24 relative",children:[E.jsx("div",{className:"absolute inset-0 gradient-radial opacity-50"}),E.jsxs("div",{className:"container mx-auto px-4 relative z-10",children:[E.jsxs(it.div,{initial:{opacity:0,y:30},whileInView:{opacity:1,y:0},viewport:{once:!0},className:"text-center mb-16",children:[E.jsxs("h2",{className:"text-3xl md:text-4xl font-bold mb-4",children:["Tudo que você precisa para"," ",E.jsx("span",{className:"text-primary neon-text",children:"vender mais"})]}),E.jsx("p",{className:"text-muted-foreground text-lg max-w-2xl mx-auto",children:"Recursos poderosos que transformam seu WhatsApp em uma máquina de vendas."})]}),E.jsx("div",{className:"grid md:grid-cols-2 lg:grid-cols-3 gap-6",children:tN.map((e,t)=>E.jsxs(it.div,{initial:{opacity:0,y:30},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{delay:t*.1},className:"group p-6 rounded-xl bg-card border border-border hover:neon-border transition-all duration-300",children:[E.jsx("div",{className:"w-12 h-12 rounded-lg bg-primary/10 flex items-center justify-center mb-4 group-hover:bg-primary/20 transition-colors",children:E.jsx(e.icon,{className:"w-6 h-6 text-primary"})}),E.jsx("h3",{className:"text-lg font-semibold mb-2",children:e.title}),E.jsx("p",{className:"text-muted-foreground text-sm",children:e.desc})]},t))})]})]}),rN=[{value:"+10.000",label:"Contatos alcançados"},{value:"+450%",label:"Aumento de conversão"},{value:"24/7",label:"Vendas no automático"}],oN=()=>E.jsxs("section",{className:"py-24 bg-card relative overflow-hidden",children:[E.jsx("div",{className:"absolute inset-0 gradient-radial"}),E.jsxs("div",{className:"container mx-auto px-4 relative z-10",children:[E.jsxs(it.div,{initial:{opacity:0,y:30},whileInView:{opacity:1,y:0},viewport:{once:!0},className:"text-center mb-16",children:[E.jsxs("h2",{className:"text-3xl md:text-4xl font-bold mb-4",children:["Resultados que"," ",E.jsx("span",{className:"text-primary neon-text",children:"falam por si"})]}),E.jsx("p",{className:"text-muted-foreground text-lg max-w-2xl mx-auto",children:"Transforme seu WhatsApp em uma máquina de vendas previsível."})]}),E.jsx("div",{className:"grid md:grid-cols-3 gap-8",children:rN.map((e,t)=>E.jsxs(it.div,{initial:{opacity:0,scale:.8},whileInView:{opacity:1,scale:1},viewport:{once:!0},transition:{delay:t*.15},className:"text-center p-8 rounded-2xl bg-secondary/50 border border-border",children:[E.jsx("div",{className:"text-5xl md:text-6xl font-extrabold text-primary neon-text mb-3",children:e.value}),E.jsx("div",{className:"text-muted-foreground font-medium",children:e.label})]},t))})]})]}),iN=()=>E.jsx("section",{className:"py-20",children:E.jsx("div",{className:"container mx-auto px-4",children:E.jsxs(it.div,{initial:{opacity:0,y:30},whileInView:{opacity:1,y:0},viewport:{once:!0},className:"max-w-3xl mx-auto text-center p-10 rounded-2xl bg-card border border-border",children:[E.jsx("div",{className:"text-4xl mb-6",children:"⚡"}),E.jsx("h2",{className:"text-2xl md:text-3xl font-bold mb-4",children:"Não precisa entender de tecnologia"}),E.jsxs("p",{className:"text-lg text-muted-foreground leading-relaxed",children:["Em poucos minutos você já pode começar a disparar mensagens e atrair clientes. A interface é simples, intuitiva e feita para quem quer"," ",E.jsx("span",{className:"text-primary font-semibold",children:"resultado rápido"}),"."]})]})})}),sN=()=>E.jsxs("section",{id:"oferta",className:"py-24 relative",children:[E.jsx("div",{className:"absolute inset-0 gradient-radial"}),E.jsx("div",{className:"container mx-auto px-4 relative z-10",children:E.jsxs(it.div,{initial:{opacity:0,y:30},whileInView:{opacity:1,y:0},viewport:{once:!0},className:"max-w-xl mx-auto",children:[E.jsxs("div",{className:"text-center mb-8",children:[E.jsx("span",{className:"inline-block px-4 py-1.5 rounded-full bg-primary/10 text-primary text-sm font-semibold mb-4 animate-pulse-neon",children:"🔥 Oferta por tempo limitado"}),E.jsxs("h2",{className:"text-3xl md:text-4xl font-bold mb-2",children:["Acesso completo ao"," ",E.jsx("span",{className:"text-primary neon-text",children:"Wsender Plus"})]})]}),E.jsxs("div",{className:"rounded-2xl border-2 border-primary neon-border bg-card p-8 text-center",children:[E.jsx("div",{className:"text-muted-foreground line-through text-lg mb-1",children:"De R$ 97,00"}),E.jsxs("div",{className:"text-6xl md:text-7xl font-extrabold text-primary neon-text mb-1",children:["R$ 26",E.jsx("span",{className:"text-4xl",children:",90"})]}),E.jsx("div",{className:"text-muted-foreground mb-6",children:"Pagamento único • Sem mensalidades"}),E.jsx(it.a,{href:"#",whileHover:{scale:1.05},whileTap:{scale:.97},className:"block w-full py-4 rounded-lg bg-primary text-primary-foreground font-bold text-xl neon-glow hover:brightness-110 transition-all mb-6",children:"👉 COMPRAR AGORA"}),E.jsxs("div",{className:"flex flex-col gap-3 text-sm text-muted-foreground",children:[E.jsxs("div",{className:"flex items-center gap-2 justify-center",children:[E.jsx(tT,{className:"w-4 h-4 text-primary"}),"Garantia de 7 dias ou seu dinheiro de volta"]}),E.jsxs("div",{className:"flex items-center gap-2 justify-center",children:[E.jsx(ZP,{className:"w-4 h-4 text-primary"}),"Acesso imediato após a compra"]}),E.jsxs("div",{className:"flex items-center gap-2 justify-center",children:[E.jsx(nT,{className:"w-4 h-4 text-primary"}),"Lançamento exclusivo"]})]})]})]})})]}),aN=()=>E.jsx("section",{className:"py-20 bg-card",children:E.jsx("div",{className:"container mx-auto px-4",children:E.jsxs(it.div,{initial:{opacity:0,y:30},whileInView:{opacity:1,y:0},viewport:{once:!0},className:"max-w-2xl mx-auto flex flex-col md:flex-row items-center gap-8 p-8 rounded-2xl border border-border",children:[E.jsx("div",{className:"flex-shrink-0",children:E.jsx("div",{className:"w-20 h-20 rounded-full bg-primary/10 flex items-center justify-center",children:E.jsx(eT,{className:"w-10 h-10 text-primary"})})}),E.jsxs("div",{children:[E.jsx("h3",{className:"text-2xl font-bold mb-2",children:"Garantia Incondicional de 7 Dias"}),E.jsx("p",{className:"text-muted-foreground leading-relaxed",children:"Se por qualquer motivo você não ficar satisfeito, devolvemos 100% do seu dinheiro. Sem perguntas, sem burocracia. O risco é todo nosso."})]})]})})}),lN=()=>E.jsx("section",{className:"py-20",children:E.jsx("div",{className:"container mx-auto px-4",children:E.jsxs(it.div,{initial:{opacity:0,y:30},whileInView:{opacity:1,y:0},viewport:{once:!0},className:"max-w-3xl mx-auto text-center",children:[E.jsx("div",{className:"inline-block px-6 py-3 rounded-lg bg-destructive/10 border border-destructive/30 mb-6",children:E.jsx("span",{className:"text-destructive font-bold text-lg",children:"❗ ATENÇÃO"})}),E.jsx("h2",{className:"text-2xl md:text-3xl font-bold mb-4",children:"Essa condição pode sair do ar a qualquer momento"}),E.jsxs("p",{className:"text-muted-foreground text-lg mb-8",children:["O preço de lançamento de ",E.jsx("span",{className:"text-primary font-bold",children:"R$ 26,90"})," é por tempo limitado. Depois disso, o valor volta ao normal."]}),E.jsx(it.a,{href:"#oferta",whileHover:{scale:1.05},whileTap:{scale:.97},className:"inline-flex items-center gap-3 px-8 py-4 rounded-lg bg-primary text-primary-foreground font-bold text-lg neon-glow hover:brightness-110 transition-all",children:"👉 QUERO COMEÇAR AGORA"})]})})}),uN=()=>E.jsxs("main",{className:"min-h-screen",children:[E.jsx(eN,{}),E.jsx(nN,{}),E.jsx(oN,{}),E.jsx(iN,{}),E.jsx(sN,{}),E.jsx(aN,{}),E.jsx(lN,{}),E.jsx("footer",{className:"py-8 text-center text-sm text-muted-foreground border-t border-border",children:E.jsx("p",{children:"© 2026 Wsender Plus. Todos os direitos reservados."})})]}),cN=()=>{const e=_v();return w.useEffect(()=>{console.error("404 Error: User attempted to access non-existent route:",e.pathname)},[e.pathname]),E.jsx("div",{className:"flex min-h-screen items-center justify-center bg-muted",children:E.jsxs("div",{className:"text-center",children:[E.jsx("h1",{className:"mb-4 text-4xl font-bold",children:"404"}),E.jsx("p",{className:"mb-4 text-xl text-muted-foreground",children:"Oops! Page not found"}),E.jsx("a",{href:"/",className:"text-primary underline hover:text-primary/90",children:"Return to Home"})]})})},dN=new RE,fN=()=>E.jsx(NE,{client:dN,children:E.jsxs(kk,{children:[E.jsx($T,{}),E.jsx(QC,{}),E.jsx(gC,{children:E.jsxs(hC,{children:[E.jsx(gc,{path:"/",element:E.jsx(uN,{})}),E.jsx(gc,{path:"*",element:E.jsx(cN,{})})]})})]})});wv(document.getElementById("root")).render(E.jsx(fN,{}));