(function(wr){typeof define=="function"&&define.amd?define(wr):wr()})(function(){"use strict";function wr(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var gc={exports:{}},Mi={},yc={exports:{}},H={};/** * @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 Sr=Symbol.for("react.element"),fy=Symbol.for("react.portal"),dy=Symbol.for("react.fragment"),hy=Symbol.for("react.strict_mode"),py=Symbol.for("react.profiler"),my=Symbol.for("react.provider"),gy=Symbol.for("react.context"),yy=Symbol.for("react.forward_ref"),vy=Symbol.for("react.suspense"),xy=Symbol.for("react.memo"),wy=Symbol.for("react.lazy"),vc=Symbol.iterator;function Sy(e){return e===null||typeof e!="object"?null:(e=vc&&e[vc]||e["@@iterator"],typeof e=="function"?e:null)}var xc={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},wc=Object.assign,Sc={};function An(e,t,n){this.props=e,this.context=t,this.refs=Sc,this.updater=n||xc}An.prototype.isReactComponent={},An.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")},An.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Pc(){}Pc.prototype=An.prototype;function Ls(e,t,n){this.props=e,this.context=t,this.refs=Sc,this.updater=n||xc}var Ds=Ls.prototype=new Pc;Ds.constructor=Ls,wc(Ds,An.prototype),Ds.isPureReactComponent=!0;var Cc=Array.isArray,Tc=Object.prototype.hasOwnProperty,As={current:null},$c={key:!0,ref:!0,__self:!0,__source:!0};function kc(e,t,n){var r,i={},o=null,s=null;if(t!=null)for(r in t.ref!==void 0&&(s=t.ref),t.key!==void 0&&(o=""+t.key),t)Tc.call(t,r)&&!$c.hasOwnProperty(r)&&(i[r]=t[r]);var l=arguments.length-2;if(l===1)i.children=n;else if(1>>1,_=F[V];if(0>>1;Vi(Ve,R))pe<_&&0>i(Ln,Ve)?(F[V]=Ln,F[pe]=R,V=pe):(F[V]=Ve,F[he]=R,V=he);else if(pe<_&&0>i(Ln,R))F[V]=Ln,F[pe]=R,V=pe;else break e}}return j}function i(F,j){var R=F.sortIndex-j.sortIndex;return R!==0?R:F.id-j.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var s=Date,l=s.now();e.unstable_now=function(){return s.now()-l}}var a=[],u=[],c=1,f=null,d=3,h=!1,x=!1,w=!1,P=typeof setTimeout=="function"?setTimeout:null,y=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 m(F){for(var j=n(u);j!==null;){if(j.callback===null)r(u);else if(j.startTime<=F)r(u),j.sortIndex=j.expirationTime,t(a,j);else break;j=n(u)}}function S(F){if(w=!1,m(F),!x)if(n(a)!==null)x=!0,U(C);else{var j=n(u);j!==null&&N(S,j.startTime-F)}}function C(F,j){x=!1,w&&(w=!1,y(g),g=-1),h=!0;var R=d;try{for(m(j),f=n(a);f!==null&&(!(f.expirationTime>j)||F&&!E());){var V=f.callback;if(typeof V=="function"){f.callback=null,d=f.priorityLevel;var _=V(f.expirationTime<=j);j=e.unstable_now(),typeof _=="function"?f.callback=_:f===n(a)&&r(a),m(j)}else r(a);f=n(a)}if(f!==null)var re=!0;else{var he=n(u);he!==null&&N(S,he.startTime-j),re=!1}return re}finally{f=null,d=R,h=!1}}var b=!1,L=null,g=-1,M=5,T=-1;function E(){return!(e.unstable_now()-TF||125V?(F.sortIndex=R,t(u,F),n(a)===null&&F===n(u)&&(w?(y(g),g=-1):w=!0,N(S,R-V))):(F.sortIndex=_,t(a,F),x||h||(x=!0,U(C))),F},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(F){var j=d;return function(){var R=d;d=j;try{return F.apply(this,arguments)}finally{d=R}}}})(Ac),Dc.exports=Ac;var Ay=Dc.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 Ry=v,Ke=Ay;function D(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"),Vs=Object.prototype.hasOwnProperty,Fy=/^[: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]*$/,Fc={},Vc={};function Vy(e){return Vs.call(Vc,e)?!0:Vs.call(Fc,e)?!1:Fy.test(e)?Vc[e]=!0:(Fc[e]=!0,!1)}function Ny(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 Ky(e,t,n,r){if(t===null||typeof t>"u"||Ny(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 Te(e,t,n,r,i,o,s){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=s}var me={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){me[e]=new Te(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];me[t]=new Te(t,1,!1,e[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(e){me[e]=new Te(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){me[e]=new Te(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){me[e]=new Te(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(e){me[e]=new Te(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(function(e){me[e]=new Te(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(function(e){me[e]=new Te(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(function(e){me[e]=new Te(e,5,!1,e.toLowerCase(),null,!1,!1)});var Ns=/[\-:]([a-z])/g;function Ks(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(Ns,Ks);me[t]=new Te(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(Ns,Ks);me[t]=new Te(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(Ns,Ks);me[t]=new Te(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(e){me[e]=new Te(e,1,!1,e.toLowerCase(),null,!1,!1)}),me.xlinkHref=new Te("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(e){me[e]=new Te(e,1,!1,e.toLowerCase(),null,!0,!0)});function Is(e,t,n,r){var i=me.hasOwnProperty(t)?me[t]:null;(i!==null?i.type!==0:r||!(2l||i[s]!==o[l]){var a=` `+i[s].replace(" at new "," at ");return e.displayName&&a.includes("")&&(a=a.replace("",e.displayName)),a}while(1<=s&&0<=l);break}}}finally{Ws=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Tr(e):""}function Iy(e){switch(e.tag){case 5:return Tr(e.type);case 16:return Tr("Lazy");case 13:return Tr("Suspense");case 19:return Tr("SuspenseList");case 0:case 2:case 15:return e=Gs(e.type,!1),e;case 11:return e=Gs(e.type.render,!1),e;case 1:return e=Gs(e.type,!0),e;default:return""}}function Qs(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 Vn:return"Fragment";case Fn:return"Portal";case Os:return"Profiler";case js:return"StrictMode";case zs:return"Suspense";case Bs:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Kc:return(e.displayName||"Context")+".Consumer";case Nc:return(e._context.displayName||"Context")+".Provider";case _s:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Us:return t=e.displayName||null,t!==null?t:Qs(e.type)||"Memo";case Lt:t=e._payload,e=e._init;try{return Qs(e(t))}catch{}}return null}function jy(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 Qs(t);case 8:return t===js?"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 Dt(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Oc(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Oy(e){var t=Oc(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 i=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(s){r=""+s,o.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 Fi(e){e._valueTracker||(e._valueTracker=Oy(e))}function _c(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Oc(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Vi(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 Ys(e,t){var n=t.checked;return J({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function zc(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Dt(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 Bc(e,t){t=t.checked,t!=null&&Is(e,"checked",t,!1)}function Xs(e,t){Bc(e,t);var n=Dt(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")?Zs(e,t.type,n):t.hasOwnProperty("defaultValue")&&Zs(e,t.type,Dt(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Uc(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 Zs(e,t,n){(t!=="number"||Vi(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var $r=Array.isArray;function Nn(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i"+t.valueOf().toString()+"",t=Ni.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function kr(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Er={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},_y=["Webkit","ms","Moz","O"];Object.keys(Er).forEach(function(e){_y.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Er[t]=Er[e]})});function Xc(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Er.hasOwnProperty(e)&&Er[e]?(""+t).trim():t+"px"}function Zc(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=Xc(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var zy=J({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 el(e,t){if(t){if(zy[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(D(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(D(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(D(61))}if(t.style!=null&&typeof t.style!="object")throw Error(D(62))}}function tl(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 nl=null;function rl(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var il=null,Kn=null,In=null;function qc(e){if(e=Yr(e)){if(typeof il!="function")throw Error(D(280));var t=e.stateNode;t&&(t=oo(t),il(e.stateNode,e.type,t))}}function Jc(e){Kn?In?In.push(e):In=[e]:Kn=e}function ef(){if(Kn){var e=Kn,t=In;if(In=Kn=null,qc(e),t)for(e=0;e>>=0,e===0?32:31-(Jy(e)/ev|0)|0}var _i=64,zi=4194304;function Dr(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 Bi(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,i=e.suspendedLanes,o=e.pingedLanes,s=n&268435455;if(s!==0){var l=s&~i;l!==0?r=Dr(l):(o&=s,o!==0&&(r=Dr(o)))}else s=n&~i,s!==0?r=Dr(s):o!==0&&(r=Dr(o));if(r===0)return 0;if(t!==0&&t!==r&&!(t&i)&&(i=r&-r,o=t&-t,i>=o||i===16&&(o&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 Ar(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-qe(t),e[t]=n}function iv(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=Or),Mf=" ",Lf=!1;function Df(e,t){switch(e){case"keyup":return Av.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Af(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var _n=!1;function Fv(e,t){switch(e){case"compositionend":return Af(t);case"keypress":return t.which!==32?null:(Lf=!0,Mf);case"textInput":return e=t.data,e===Mf&&Lf?null:e;default:return null}}function Vv(e,t){if(_n)return e==="compositionend"||!Pl&&Df(e,t)?(e=Cf(),Qi=gl=Nt=null,_n=!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=jf(n)}}function _f(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?_f(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function zf(){for(var e=window,t=Vi();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Vi(e.document)}return t}function $l(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 Uv(e){var t=zf(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&_f(n.ownerDocument.documentElement,n)){if(r!==null&&$l(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 i=n.textContent.length,o=Math.min(r.start,i);r=r.end===void 0?o:Math.min(r.end,i),!e.extend&&o>r&&(i=r,r=o,o=i),i=Of(n,o);var s=Of(n,r);i&&s&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==s.node||e.focusOffset!==s.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),o>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,zn=null,kl=null,Ur=null,El=!1;function Bf(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;El||zn==null||zn!==Vi(r)||(r=zn,"selectionStart"in r&&$l(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}),Ur&&Br(Ur,r)||(Ur=r,r=no(kl,"onSelect"),0Gn||(e.current=jl[Gn],jl[Gn]=null,Gn--)}function Q(e,t){Gn++,jl[Gn]=e.current,e.current=t}var Ot={},ve=jt(Ot),be=jt(!1),ln=Ot;function Qn(e,t){var n=e.type.contextTypes;if(!n)return Ot;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i={},o;for(o in n)i[o]=t[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function Me(e){return e=e.childContextTypes,e!=null}function so(){Z(be),Z(ve)}function id(e,t,n){if(ve.current!==Ot)throw Error(D(168));Q(ve,t),Q(be,n)}function od(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in t))throw Error(D(108,jy(e)||"Unknown",i));return J({},n,r)}function lo(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Ot,ln=ve.current,Q(ve,e),Q(be,be.current),!0}function sd(e,t,n){var r=e.stateNode;if(!r)throw Error(D(169));n?(e=od(e,t,ln),r.__reactInternalMemoizedMergedChildContext=e,Z(be),Z(ve),Q(ve,e)):Z(be),Q(be,n)}var yt=null,ao=!1,Ol=!1;function ld(e){yt===null?yt=[e]:yt.push(e)}function n0(e){ao=!0,ld(e)}function _t(){if(!Ol&&yt!==null){Ol=!0;var e=0,t=G;try{var n=yt;for(G=1;e>=s,i-=s,vt=1<<32-qe(t)+i|n<g?(M=L,L=null):M=L.sibling;var T=d(y,L,m[g],S);if(T===null){L===null&&(L=M);break}e&&L&&T.alternate===null&&t(y,L),p=o(T,p,g),b===null?C=T:b.sibling=T,b=T,L=M}if(g===m.length)return n(y,L),q&&un(y,g),C;if(L===null){for(;gg?(M=L,L=null):M=L.sibling;var E=d(y,L,T.value,S);if(E===null){L===null&&(L=M);break}e&&L&&E.alternate===null&&t(y,L),p=o(E,p,g),b===null?C=E:b.sibling=E,b=E,L=M}if(T.done)return n(y,L),q&&un(y,g),C;if(L===null){for(;!T.done;g++,T=m.next())T=f(y,T.value,S),T!==null&&(p=o(T,p,g),b===null?C=T:b.sibling=T,b=T);return q&&un(y,g),C}for(L=r(y,L);!T.done;g++,T=m.next())T=h(L,y,g,T.value,S),T!==null&&(e&&T.alternate!==null&&L.delete(T.key===null?g:T.key),p=o(T,p,g),b===null?C=T:b.sibling=T,b=T);return e&&L.forEach(function(I){return t(y,I)}),q&&un(y,g),C}function P(y,p,m,S){if(typeof m=="object"&&m!==null&&m.type===Vn&&m.key===null&&(m=m.props.children),typeof m=="object"&&m!==null){switch(m.$$typeof){case Ri:e:{for(var C=m.key,b=p;b!==null;){if(b.key===C){if(C=m.type,C===Vn){if(b.tag===7){n(y,b.sibling),p=i(b,m.props.children),p.return=y,y=p;break e}}else if(b.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===Lt&&hd(C)===b.type){n(y,b.sibling),p=i(b,m.props),p.ref=Xr(y,b,m),p.return=y,y=p;break e}n(y,b);break}else t(y,b);b=b.sibling}m.type===Vn?(p=yn(m.props.children,y.mode,S,m.key),p.return=y,y=p):(S=Ko(m.type,m.key,m.props,null,y.mode,S),S.ref=Xr(y,p,m),S.return=y,y=S)}return s(y);case Fn:e:{for(b=m.key;p!==null;){if(p.key===b)if(p.tag===4&&p.stateNode.containerInfo===m.containerInfo&&p.stateNode.implementation===m.implementation){n(y,p.sibling),p=i(p,m.children||[]),p.return=y,y=p;break e}else{n(y,p);break}else t(y,p);p=p.sibling}p=Ka(m,y.mode,S),p.return=y,y=p}return s(y);case Lt:return b=m._init,P(y,p,b(m._payload),S)}if($r(m))return x(y,p,m,S);if(Cr(m))return w(y,p,m,S);ho(y,m)}return typeof m=="string"&&m!==""||typeof m=="number"?(m=""+m,p!==null&&p.tag===6?(n(y,p.sibling),p=i(p,m),p.return=y,y=p):(n(y,p),p=Na(m,y.mode,S),p.return=y,y=p),s(y)):n(y,p)}return P}var qn=pd(!0),md=pd(!1),po=jt(null),mo=null,Jn=null,Wl=null;function Gl(){Wl=Jn=mo=null}function Ql(e){var t=po.current;Z(po),e._currentValue=t}function Yl(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 er(e,t){mo=e,Wl=Jn=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Le=!0),e.firstContext=null)}function He(e){var t=e._currentValue;if(Wl!==e)if(e={context:e,memoizedValue:t,next:null},Jn===null){if(mo===null)throw Error(D(308));Jn=e,mo.dependencies={lanes:0,firstContext:e}}else Jn=Jn.next=e;return t}var cn=null;function Xl(e){cn===null?cn=[e]:cn.push(e)}function gd(e,t,n,r){var i=t.interleaved;return i===null?(n.next=n,Xl(t)):(n.next=i.next,i.next=n),t.interleaved=n,wt(e,r)}function wt(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 zt=!1;function Zl(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function yd(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 St(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Bt(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,W&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,wt(e,n)}return i=r.interleaved,i===null?(t.next=t,Xl(r)):(t.next=i.next,i.next=t),r.interleaved=t,wt(e,n)}function go(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,fl(e,n)}}function vd(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,o=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};o===null?i=o=s:o=o.next=s,n=n.next}while(n!==null);o===null?i=o=t:o=o.next=t}else i=o=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:o,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 yo(e,t,n,r){var i=e.updateQueue;zt=!1;var o=i.firstBaseUpdate,s=i.lastBaseUpdate,l=i.shared.pending;if(l!==null){i.shared.pending=null;var a=l,u=a.next;a.next=null,s===null?o=u:s.next=u,s=a;var c=e.alternate;c!==null&&(c=c.updateQueue,l=c.lastBaseUpdate,l!==s&&(l===null?c.firstBaseUpdate=u:l.next=u,c.lastBaseUpdate=a))}if(o!==null){var f=i.baseState;s=0,c=u=a=null,l=o;do{var d=l.lane,h=l.eventTime;if((r&d)===d){c!==null&&(c=c.next={eventTime:h,lane:0,tag:l.tag,payload:l.payload,callback:l.callback,next:null});e:{var x=e,w=l;switch(d=t,h=n,w.tag){case 1:if(x=w.payload,typeof x=="function"){f=x.call(h,f,d);break e}f=x;break e;case 3:x.flags=x.flags&-65537|128;case 0:if(x=w.payload,d=typeof x=="function"?x.call(h,f,d):x,d==null)break e;f=J({},f,d);break e;case 2:zt=!0}}l.callback!==null&&l.lane!==0&&(e.flags|=64,d=i.effects,d===null?i.effects=[l]:d.push(l))}else h={eventTime:h,lane:d,tag:l.tag,payload:l.payload,callback:l.callback,next:null},c===null?(u=c=h,a=f):c=c.next=h,s|=d;if(l=l.next,l===null){if(l=i.shared.pending,l===null)break;d=l,l=d.next,d.next=null,i.lastBaseUpdate=d,i.shared.pending=null}}while(!0);if(c===null&&(a=f),i.baseState=a,i.firstBaseUpdate=u,i.lastBaseUpdate=c,t=i.shared.interleaved,t!==null){i=t;do s|=i.lane,i=i.next;while(i!==t)}else o===null&&(i.shared.lanes=0);hn|=s,e.lanes=s,e.memoizedState=f}}function xd(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=na.transition;na.transition={};try{e(!1),t()}finally{G=n,na.transition=r}}function Id(){return We().memoizedState}function s0(e,t,n){var r=Gt(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},jd(e))Od(t,n);else if(n=gd(e,t,n,r),n!==null){var i=ke();it(n,e,r,i),_d(n,t,r)}}function l0(e,t,n){var r=Gt(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(jd(e))Od(t,i);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var s=t.lastRenderedState,l=o(s,n);if(i.hasEagerState=!0,i.eagerState=l,Je(l,s)){var a=t.interleaved;a===null?(i.next=i,Xl(t)):(i.next=a.next,a.next=i),t.interleaved=i;return}}catch{}finally{}n=gd(e,t,i,r),n!==null&&(i=ke(),it(n,e,r,i),_d(n,t,r))}}function jd(e){var t=e.alternate;return e===te||t!==null&&t===te}function Od(e,t){ei=wo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function _d(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,fl(e,n)}}var Co={readContext:He,useCallback:xe,useContext:xe,useEffect:xe,useImperativeHandle:xe,useInsertionEffect:xe,useLayoutEffect:xe,useMemo:xe,useReducer:xe,useRef:xe,useState:xe,useDebugValue:xe,useDeferredValue:xe,useTransition:xe,useMutableSource:xe,useSyncExternalStore:xe,useId:xe,unstable_isNewReconciler:!1},a0={readContext:He,useCallback:function(e,t){return ft().memoizedState=[e,t===void 0?null:t],e},useContext:He,useEffect:Ld,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,So(4194308,4,Rd.bind(null,t,e),n)},useLayoutEffect:function(e,t){return So(4194308,4,e,t)},useInsertionEffect:function(e,t){return So(4,2,e,t)},useMemo:function(e,t){var n=ft();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=ft();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=s0.bind(null,te,e),[r.memoizedState,e]},useRef:function(e){var t=ft();return e={current:e},t.memoizedState=e},useState:bd,useDebugValue:ua,useDeferredValue:function(e){return ft().memoizedState=e},useTransition:function(){var e=bd(!1),t=e[0];return e=o0.bind(null,e[1]),ft().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=te,i=ft();if(q){if(n===void 0)throw Error(D(407));n=n()}else{if(n=t(),de===null)throw Error(D(349));dn&30||Cd(r,t,n)}i.memoizedState=n;var o={value:n,getSnapshot:t};return i.queue=o,Ld($d.bind(null,r,o,e),[e]),r.flags|=2048,ri(9,Td.bind(null,r,o,n,t),void 0,null),n},useId:function(){var e=ft(),t=de.identifierPrefix;if(q){var n=xt,r=vt;n=(r&~(1<<32-qe(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=ti++,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[Qr]=r,lh(e,t,!1,!1),t.stateNode=e;e:{switch(s=tl(n,r),n){case"dialog":X("cancel",e),X("close",e),i=r;break;case"iframe":case"object":case"embed":X("load",e),i=r;break;case"video":case"audio":for(i=0;ior&&(t.flags|=128,r=!0,ii(o,!1),t.lanes=4194304)}else{if(!r)if(e=vo(s),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),ii(o,!0),o.tail===null&&o.tailMode==="hidden"&&!s.alternate&&!q)return we(t),null}else 2*oe()-o.renderingStartTime>or&&n!==1073741824&&(t.flags|=128,r=!0,ii(o,!1),t.lanes=4194304);o.isBackwards?(s.sibling=t.child,t.child=s):(n=o.last,n!==null?n.sibling=s:t.child=s,o.last=s)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=oe(),t.sibling=null,n=ee.current,Q(ee,r?n&1|2:n&1),t):(we(t),null);case 22:case 23:return Ra(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?_e&1073741824&&(we(t),t.subtreeFlags&6&&(t.flags|=8192)):we(t),null;case 24:return null;case 25:return null}throw Error(D(156,t.tag))}function g0(e,t){switch(zl(t),t.tag){case 1:return Me(t.type)&&so(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return tr(),Z(be),Z(ve),ta(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Jl(t),null;case 13:if(Z(ee),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(D(340));Zn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Z(ee),null;case 4:return tr(),null;case 10:return Ql(t.type._context),null;case 22:case 23:return Ra(),null;case 24:return null;default:return null}}var Eo=!1,Se=!1,y0=typeof WeakSet=="function"?WeakSet:Set,K=null;function rr(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){ie(e,t,r)}else n.current=null}function Sa(e,t,n){try{n()}catch(r){ie(e,t,r)}}var ch=!1;function v0(e,t){if(Rl=Wi,e=zf(),$l(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 i=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break e}var s=0,l=-1,a=-1,u=0,c=0,f=e,d=null;t:for(;;){for(var h;f!==n||i!==0&&f.nodeType!==3||(l=s+i),f!==o||r!==0&&f.nodeType!==3||(a=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(h=f.firstChild)!==null;)d=f,f=h;for(;;){if(f===e)break t;if(d===n&&++u===i&&(l=s),d===o&&++c===r&&(a=s),(h=f.nextSibling)!==null)break;f=d,d=f.parentNode}f=h}n=l===-1||a===-1?null:{start:l,end:a}}else n=null}n=n||{start:0,end:0}}else n=null;for(Fl={focusedElem:e,selectionRange:n},Wi=!1,K=t;K!==null;)if(t=K,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,K=e;else for(;K!==null;){t=K;try{var x=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(x!==null){var w=x.memoizedProps,P=x.memoizedState,y=t.stateNode,p=y.getSnapshotBeforeUpdate(t.elementType===t.type?w:tt(t.type,w),P);y.__reactInternalSnapshotBeforeUpdate=p}break;case 3:var m=t.stateNode.containerInfo;m.nodeType===1?m.textContent="":m.nodeType===9&&m.documentElement&&m.removeChild(m.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(D(163))}}catch(S){ie(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,K=e;break}K=t.return}return x=ch,ch=!1,x}function oi(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var o=i.destroy;i.destroy=void 0,o!==void 0&&Sa(t,n,o)}i=i.next}while(i!==r)}}function bo(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 Pa(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 fh(e){var t=e.alternate;t!==null&&(e.alternate=null,fh(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[ut],delete t[Qr],delete t[Il],delete t[e0],delete t[t0])),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 dh(e){return e.tag===5||e.tag===3||e.tag===4}function hh(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||dh(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 Ca(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=io));else if(r!==4&&(e=e.child,e!==null))for(Ca(e,t,n),e=e.sibling;e!==null;)Ca(e,t,n),e=e.sibling}function Ta(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(Ta(e,t,n),e=e.sibling;e!==null;)Ta(e,t,n),e=e.sibling}var ge=null,nt=!1;function Ut(e,t,n){for(n=n.child;n!==null;)ph(e,t,n),n=n.sibling}function ph(e,t,n){if(at&&typeof at.onCommitFiberUnmount=="function")try{at.onCommitFiberUnmount(Oi,n)}catch{}switch(n.tag){case 5:Se||rr(n,t);case 6:var r=ge,i=nt;ge=null,Ut(e,t,n),ge=r,nt=i,ge!==null&&(nt?(e=ge,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):ge.removeChild(n.stateNode));break;case 18:ge!==null&&(nt?(e=ge,n=n.stateNode,e.nodeType===8?Kl(e.parentNode,n):e.nodeType===1&&Kl(e,n),Kr(e)):Kl(ge,n.stateNode));break;case 4:r=ge,i=nt,ge=n.stateNode.containerInfo,nt=!0,Ut(e,t,n),ge=r,nt=i;break;case 0:case 11:case 14:case 15:if(!Se&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var o=i,s=o.destroy;o=o.tag,s!==void 0&&(o&2||o&4)&&Sa(n,t,s),i=i.next}while(i!==r)}Ut(e,t,n);break;case 1:if(!Se&&(rr(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(l){ie(n,t,l)}Ut(e,t,n);break;case 21:Ut(e,t,n);break;case 22:n.mode&1?(Se=(r=Se)||n.memoizedState!==null,Ut(e,t,n),Se=r):Ut(e,t,n);break;default:Ut(e,t,n)}}function mh(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new y0),t.forEach(function(r){var i=E0.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function rt(e,t){var n=t.deletions;if(n!==null)for(var r=0;ri&&(i=s),r&=~o}if(r=i,r=oe()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*w0(r/1960))-r,10e?16:e,Wt===null)var r=!1;else{if(e=Wt,Wt=null,Ro=0,W&6)throw Error(D(331));var i=W;for(W|=4,K=e.current;K!==null;){var o=K,s=o.child;if(K.flags&16){var l=o.deletions;if(l!==null){for(var a=0;aoe()-Ea?mn(e,0):ka|=n),Ae(e,t)}function bh(e,t){t===0&&(e.mode&1?(t=zi,zi<<=1,!(zi&130023424)&&(zi=4194304)):t=1);var n=ke();e=wt(e,t),e!==null&&(Ar(e,t,n),Ae(e,n))}function k0(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),bh(e,n)}function E0(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(D(314))}r!==null&&r.delete(t),bh(e,n)}var Mh;Mh=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||be.current)Le=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Le=!1,p0(e,t,n);Le=!!(e.flags&131072)}else Le=!1,q&&t.flags&1048576&&ad(t,co,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;ko(e,t),e=t.pendingProps;var i=Qn(t,ve.current);er(t,n),i=ia(null,t,r,e,i,n);var o=oa();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Me(r)?(o=!0,lo(t)):o=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,Zl(t),i.updater=To,t.stateNode=i,i._reactInternals=t,fa(t,r,e,n),t=ma(null,t,r,!0,o,n)):(t.tag=0,q&&o&&_l(t),$e(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(ko(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=M0(r),e=tt(r,e),i){case 0:t=pa(null,t,r,e,n);break e;case 1:t=th(null,t,r,e,n);break e;case 11:t=Xd(null,t,r,e,n);break e;case 14:t=Zd(null,t,r,tt(r.type,e),n);break e}throw Error(D(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:tt(r,i),pa(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:tt(r,i),th(e,t,r,i,n);case 3:e:{if(nh(t),e===null)throw Error(D(387));r=t.pendingProps,o=t.memoizedState,i=o.element,yd(e,t),yo(t,r,null,n);var s=t.memoizedState;if(r=s.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){i=nr(Error(D(423)),t),t=rh(e,t,r,n,i);break e}else if(r!==i){i=nr(Error(D(424)),t),t=rh(e,t,r,n,i);break e}else for(Oe=It(t.stateNode.containerInfo.firstChild),je=t,q=!0,et=null,n=md(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Zn(),r===i){t=Pt(e,t,n);break e}$e(e,t,r,n)}t=t.child}return t;case 5:return wd(t),e===null&&Ul(t),r=t.type,i=t.pendingProps,o=e!==null?e.memoizedProps:null,s=i.children,Vl(r,i)?s=null:o!==null&&Vl(r,o)&&(t.flags|=32),eh(e,t),$e(e,t,s,n),t.child;case 6:return e===null&&Ul(t),null;case 13:return ih(e,t,n);case 4:return ql(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=qn(t,null,r,n):$e(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:tt(r,i),Xd(e,t,r,i,n);case 7:return $e(e,t,t.pendingProps,n),t.child;case 8:return $e(e,t,t.pendingProps.children,n),t.child;case 12:return $e(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,o=t.memoizedProps,s=i.value,Q(po,r._currentValue),r._currentValue=s,o!==null)if(Je(o.value,s)){if(o.children===i.children&&!be.current){t=Pt(e,t,n);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var l=o.dependencies;if(l!==null){s=o.child;for(var a=l.firstContext;a!==null;){if(a.context===r){if(o.tag===1){a=St(-1,n&-n),a.tag=2;var u=o.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?a.next=a:(a.next=c.next,c.next=a),u.pending=a}}o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),Yl(o.return,n,t),l.lanes|=n;break}a=a.next}}else if(o.tag===10)s=o.type===t.type?null:o.child;else if(o.tag===18){if(s=o.return,s===null)throw Error(D(341));s.lanes|=n,l=s.alternate,l!==null&&(l.lanes|=n),Yl(s,n,t),s=o.sibling}else s=o.child;if(s!==null)s.return=o;else for(s=o;s!==null;){if(s===t){s=null;break}if(o=s.sibling,o!==null){o.return=s.return,s=o;break}s=s.return}o=s}$e(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,er(t,n),i=He(i),r=r(i),t.flags|=1,$e(e,t,r,n),t.child;case 14:return r=t.type,i=tt(r,t.pendingProps),i=tt(r.type,i),Zd(e,t,r,i,n);case 15:return qd(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:tt(r,i),ko(e,t),t.tag=1,Me(r)?(e=!0,lo(t)):e=!1,er(t,n),Bd(t,r,i),fa(t,r,i,n),ma(null,t,r,!0,e,n);case 19:return sh(e,t,n);case 22:return Jd(e,t,n)}throw Error(D(156,t.tag))};function Lh(e,t){return uf(e,t)}function b0(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 Qe(e,t,n,r){return new b0(e,t,n,r)}function Va(e){return e=e.prototype,!(!e||!e.isReactComponent)}function M0(e){if(typeof e=="function")return Va(e)?1:0;if(e!=null){if(e=e.$$typeof,e===_s)return 11;if(e===Us)return 14}return 2}function Yt(e,t){var n=e.alternate;return n===null?(n=Qe(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 Ko(e,t,n,r,i,o){var s=2;if(r=e,typeof e=="function")Va(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case Vn:return yn(n.children,i,o,t);case js:s=8,i|=8;break;case Os:return e=Qe(12,n,t,i|2),e.elementType=Os,e.lanes=o,e;case zs:return e=Qe(13,n,t,i),e.elementType=zs,e.lanes=o,e;case Bs:return e=Qe(19,n,t,i),e.elementType=Bs,e.lanes=o,e;case Ic:return Io(n,i,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Nc:s=10;break e;case Kc:s=9;break e;case _s:s=11;break e;case Us:s=14;break e;case Lt:s=16,r=null;break e}throw Error(D(130,e==null?e:typeof e,""))}return t=Qe(s,n,t,i),t.elementType=e,t.type=r,t.lanes=o,t}function yn(e,t,n,r){return e=Qe(7,e,r,t),e.lanes=n,e}function Io(e,t,n,r){return e=Qe(22,e,r,t),e.elementType=Ic,e.lanes=n,e.stateNode={isHidden:!1},e}function Na(e,t,n){return e=Qe(6,e,null,t),e.lanes=n,e}function Ka(e,t,n){return t=Qe(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function L0(e,t,n,r,i){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=cl(0),this.expirationTimes=cl(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=cl(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function Ia(e,t,n,r,i,o,s,l,a){return e=new L0(e,t,n,l,a),t===1?(t=1,o===!0&&(t|=8)):t=0,o=Qe(3,null,null,t),e.current=o,o.stateNode=e,o.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Zl(o),e}function D0(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Nh)}catch(e){console.error(e)}}Nh(),Lc.exports=Ne;var za=Lc.exports;const Kh=wr(za);function ci(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var N0=["color"],Ih=v.forwardRef(function(e,t){var n=e.color,r=n===void 0?"currentColor":n,i=ci(e,N0);return v.createElement("svg",Object.assign({width:"15",height:"15",viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},i,{ref:t}),v.createElement("path",{d:"M8.81809 4.18179C8.99383 4.35753 8.99383 4.64245 8.81809 4.81819L6.13629 7.49999L8.81809 10.1818C8.99383 10.3575 8.99383 10.6424 8.81809 10.8182C8.64236 10.9939 8.35743 10.9939 8.1817 10.8182L5.1817 7.81819C5.09731 7.73379 5.0499 7.61933 5.0499 7.49999C5.0499 7.38064 5.09731 7.26618 5.1817 7.18179L8.1817 4.18179C8.35743 4.00605 8.64236 4.00605 8.81809 4.18179Z",fill:r,fillRule:"evenodd",clipRule:"evenodd"}))}),K0=["color"],jh=v.forwardRef(function(e,t){var n=e.color,r=n===void 0?"currentColor":n,i=ci(e,K0);return v.createElement("svg",Object.assign({width:"15",height:"15",viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},i,{ref:t}),v.createElement("path",{d:"M6.18194 4.18185C6.35767 4.00611 6.6426 4.00611 6.81833 4.18185L9.81833 7.18185C9.90272 7.26624 9.95013 7.3807 9.95013 7.50005C9.95013 7.6194 9.90272 7.73386 9.81833 7.81825L6.81833 10.8182C6.6426 10.994 6.35767 10.994 6.18194 10.8182C6.0062 10.6425 6.0062 10.3576 6.18194 10.1819L8.86374 7.50005L6.18194 4.81825C6.0062 4.64251 6.0062 4.35759 6.18194 4.18185Z",fill:r,fillRule:"evenodd",clipRule:"evenodd"}))}),I0=["color"],j0=v.forwardRef(function(e,t){var n=e.color,r=n===void 0?"currentColor":n,i=ci(e,I0);return v.createElement("svg",Object.assign({width:"15",height:"15",viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},i,{ref:t}),v.createElement("path",{d:"M12.8536 2.85355C13.0488 2.65829 13.0488 2.34171 12.8536 2.14645C12.6583 1.95118 12.3417 1.95118 12.1464 2.14645L7.5 6.79289L2.85355 2.14645C2.65829 1.95118 2.34171 1.95118 2.14645 2.14645C1.95118 2.34171 1.95118 2.65829 2.14645 2.85355L6.79289 7.5L2.14645 12.1464C1.95118 12.3417 1.95118 12.6583 2.14645 12.8536C2.34171 13.0488 2.65829 13.0488 2.85355 12.8536L7.5 8.20711L12.1464 12.8536C12.3417 13.0488 12.6583 13.0488 12.8536 12.8536C13.0488 12.6583 13.0488 12.3417 12.8536 12.1464L8.20711 7.5L12.8536 2.85355Z",fill:r,fillRule:"evenodd",clipRule:"evenodd"}))}),O0=["color"],_0=v.forwardRef(function(e,t){var n=e.color,r=n===void 0?"currentColor":n,i=ci(e,O0);return v.createElement("svg",Object.assign({width:"15",height:"15",viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},i,{ref:t}),v.createElement("path",{d:"M6.04995 2.74998C6.04995 2.44623 5.80371 2.19998 5.49995 2.19998C5.19619 2.19998 4.94995 2.44623 4.94995 2.74998V12.25C4.94995 12.5537 5.19619 12.8 5.49995 12.8C5.80371 12.8 6.04995 12.5537 6.04995 12.25V2.74998ZM10.05 2.74998C10.05 2.44623 9.80371 2.19998 9.49995 2.19998C9.19619 2.19998 8.94995 2.44623 8.94995 2.74998V12.25C8.94995 12.5537 9.19619 12.8 9.49995 12.8C9.80371 12.8 10.05 12.5537 10.05 12.25V2.74998Z",fill:r,fillRule:"evenodd",clipRule:"evenodd"}))}),z0=["color"],B0=v.forwardRef(function(e,t){var n=e.color,r=n===void 0?"currentColor":n,i=ci(e,z0);return v.createElement("svg",Object.assign({width:"15",height:"15",viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},i,{ref:t}),v.createElement("path",{d:"M3.24182 2.32181C3.3919 2.23132 3.5784 2.22601 3.73338 2.30781L12.7334 7.05781C12.8974 7.14436 13 7.31457 13 7.5C13 7.68543 12.8974 7.85564 12.7334 7.94219L3.73338 12.6922C3.5784 12.774 3.3919 12.7687 3.24182 12.6782C3.09175 12.5877 3 12.4252 3 12.25V2.75C3 2.57476 3.09175 2.4123 3.24182 2.32181ZM4 3.57925V11.4207L11.4288 7.5L4 3.57925Z",fill:r,fillRule:"evenodd",clipRule:"evenodd"}))});const lr=typeof document<"u"?B.useLayoutEffect:()=>{};function vn(e){const t=v.useRef(null);return lr(()=>{t.current=e},[e]),v.useCallback((...n)=>{const r=t.current;return r==null?void 0:r(...n)},[])}const Ho={prefix:String(Math.round(Math.random()*1e10)),current:0},Oh=B.createContext(Ho),U0=B.createContext(!1);let H0=!!(typeof window<"u"&&window.document&&window.document.createElement),Ba=new WeakMap;function W0(e=!1){let t=v.useContext(Oh),n=v.useRef(null);if(n.current===null&&!e){var r,i;let o=(i=B.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED)===null||i===void 0||(r=i.ReactCurrentOwner)===null||r===void 0?void 0:r.current;if(o){let s=Ba.get(o);s==null?Ba.set(o,{id:t.current,state:o.memoizedState}):o.memoizedState!==s.state&&(t.current=s.id,Ba.delete(o))}n.current=++t.current}return n.current}function G0(e){let t=v.useContext(Oh);t===Ho&&!H0&&console.warn("When server rendering, you must wrap your application in an to ensure consistent ids are generated between the client and server.");let n=W0(!!e),r=`react-aria${t.prefix}`;return e||`${r}-${n}`}function Q0(e){let t=B.useId(),[n]=v.useState(fi()),r=n?"react-aria":`react-aria${Ho.prefix}`;return e||`${r}-${t}`}const Y0=typeof B.useId=="function"?Q0:G0;function X0(){return!1}function Z0(){return!0}function q0(e){return()=>{}}function fi(){return typeof B.useSyncExternalStore=="function"?B.useSyncExternalStore(q0,X0,Z0):v.useContext(U0)}let J0=!!(typeof window<"u"&&window.document&&window.document.createElement),Wo=new Map;function _h(e){let[t,n]=v.useState(e),r=v.useRef(null),i=Y0(t),o=v.useCallback(s=>{r.current=s},[]);return J0&&Wo.set(i,o),lr(()=>{let s=i;return()=>{Wo.delete(s)}},[i]),v.useEffect(()=>{let s=r.current;s&&(r.current=null,n(s))}),i}function e1(e,t){if(e===t)return e;let n=Wo.get(e);if(n)return n(t),t;let r=Wo.get(t);return r?(r(e),e):t}function zh(...e){return(...t)=>{for(let n of e)typeof n=="function"&&n(...t)}}const Re=e=>{var t;return(t=e==null?void 0:e.ownerDocument)!==null&&t!==void 0?t:document},ot=e=>e&&"window"in e&&e.window===e?e:Re(e).defaultView||window;function Bh(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t=65&&i.charCodeAt(2)<=90?t[i]=zh(o,s):(i==="className"||i==="UNSAFE_className")&&typeof o=="string"&&typeof s=="string"?t[i]=t1(o,s):i==="id"&&o&&s?t.id=e1(o,s):t[i]=s!==void 0?s:o}}return t}function n1(...e){return e.length===1?e[0]:t=>{for(let n of e)typeof n=="function"?n(t):n!=null&&(n.current=t)}}const r1=new Set(["id"]),i1=new Set(["aria-label","aria-labelledby","aria-describedby","aria-details"]),o1=new Set(["href","hrefLang","target","rel","download","ping","referrerPolicy"]),s1=/^(data-.*)$/;function Go(e,t={}){let{labelable:n,isLink:r,propNames:i}=t,o={};for(const s in e)Object.prototype.hasOwnProperty.call(e,s)&&(r1.has(s)||n&&i1.has(s)||r&&o1.has(s)||i!=null&&i.has(s)||s1.test(s))&&(o[s]=e[s]);return o}function Tt(e){if(l1())e.focus({preventScroll:!0});else{let t=a1(e);e.focus(),u1(t)}}let Qo=null;function l1(){if(Qo==null){Qo=!1;try{document.createElement("div").focus({get preventScroll(){return Qo=!0,!0}})}catch{}}return Qo}function a1(e){let t=e.parentNode,n=[],r=document.scrollingElement||document.documentElement;for(;t instanceof HTMLElement&&t!==r;)(t.offsetHeight"u"||window.navigator==null?!1:((t=window.navigator.userAgentData)===null||t===void 0?void 0:t.brands.some(n=>e.test(n.brand)))||e.test(window.navigator.userAgent)}function Ua(e){var t;return typeof window<"u"&&window.navigator!=null?e.test(((t=window.navigator.userAgentData)===null||t===void 0?void 0:t.platform)||window.navigator.platform):!1}function xn(){return Ua(/^Mac/i)}function c1(){return Ua(/^iPhone/i)}function Uh(){return Ua(/^iPad/i)||xn()&&navigator.maxTouchPoints>1}function Ha(){return c1()||Uh()}function f1(){return xn()||Ha()}function d1(){return Yo(/AppleWebKit/i)&&!h1()}function h1(){return Yo(/Chrome/i)}function Hh(){return Yo(/Android/i)}function p1(){return Yo(/Firefox/i)}const m1=v.createContext({isNative:!0,open:y1,useHref:e=>e});function Wa(){return v.useContext(m1)}function wn(e,t,n=!0){var r,i;let{metaKey:o,ctrlKey:s,altKey:l,shiftKey:a}=t;p1()&&(!((i=window.event)===null||i===void 0||(r=i.type)===null||r===void 0)&&r.startsWith("key"))&&e.target==="_blank"&&(xn()?o=!0:s=!0);let u=d1()&&xn()&&!Uh()?new KeyboardEvent("keydown",{keyIdentifier:"Enter",metaKey:o,ctrlKey:s,altKey:l,shiftKey:a}):new MouseEvent("click",{metaKey:o,ctrlKey:s,altKey:l,shiftKey:a,bubbles:!0,cancelable:!0});wn.isOpening=n,Tt(e),e.dispatchEvent(u),wn.isOpening=!1}wn.isOpening=!1;function g1(e,t){if(e instanceof HTMLAnchorElement)t(e);else if(e.hasAttribute("data-href")){let n=document.createElement("a");n.href=e.getAttribute("data-href"),e.hasAttribute("data-target")&&(n.target=e.getAttribute("data-target")),e.hasAttribute("data-rel")&&(n.rel=e.getAttribute("data-rel")),e.hasAttribute("data-download")&&(n.download=e.getAttribute("data-download")),e.hasAttribute("data-ping")&&(n.ping=e.getAttribute("data-ping")),e.hasAttribute("data-referrer-policy")&&(n.referrerPolicy=e.getAttribute("data-referrer-policy")),e.appendChild(n),t(n),e.removeChild(n)}}function y1(e,t){g1(e,n=>wn(n,t))}function v1(e){let t=Wa();return{href:e!=null&&e.href?t.useHref(e==null?void 0:e.href):void 0,target:e==null?void 0:e.target,rel:e==null?void 0:e.rel,download:e==null?void 0:e.download,ping:e==null?void 0:e.ping,referrerPolicy:e==null?void 0:e.referrerPolicy}}let ar=new Map,Ga=new Set;function Wh(){if(typeof window>"u")return;function e(r){return"propertyName"in r}let t=r=>{if(!e(r)||!r.target)return;let i=ar.get(r.target);i||(i=new Set,ar.set(r.target,i),r.target.addEventListener("transitioncancel",n,{once:!0})),i.add(r.propertyName)},n=r=>{if(!e(r)||!r.target)return;let i=ar.get(r.target);if(i&&(i.delete(r.propertyName),i.size===0&&(r.target.removeEventListener("transitioncancel",n),ar.delete(r.target)),ar.size===0)){for(let o of Ga)o();Ga.clear()}};document.body.addEventListener("transitionrun",t),document.body.addEventListener("transitionend",n)}typeof document<"u"&&(document.readyState!=="loading"?Wh():document.addEventListener("DOMContentLoaded",Wh));function Gh(e){requestAnimationFrame(()=>{ar.size===0?e():Ga.add(e)})}function Qh(){let e=v.useRef(new Map),t=v.useCallback((i,o,s,l)=>{let a=l!=null&&l.once?(...u)=>{e.current.delete(s),s(...u)}:s;e.current.set(s,{type:o,eventTarget:i,fn:a,options:l}),i.addEventListener(o,s,l)},[]),n=v.useCallback((i,o,s,l)=>{var a;let u=((a=e.current.get(s))===null||a===void 0?void 0:a.fn)||s;i.removeEventListener(o,u,l),e.current.delete(s)},[]),r=v.useCallback(()=>{e.current.forEach((i,o)=>{n(i.eventTarget,i.type,o,i.options)})},[n]);return v.useEffect(()=>r,[r]),{addGlobalListener:t,removeGlobalListener:n,removeAllGlobalListeners:r}}function Yh(e,t){let{id:n,"aria-label":r,"aria-labelledby":i}=e;return n=_h(n),i&&r?i=[...new Set([n,...i.trim().split(/\s+/)])].join(" "):i&&(i=i.trim().split(/\s+/).join(" ")),!r&&!i&&t&&(r=t),{id:n,"aria-label":r,"aria-labelledby":i}}function Xo(e){const t=v.useRef(null);return v.useMemo(()=>({get current(){return t.current},set current(n){t.current=n,typeof e=="function"?e(n):e&&(e.current=n)}}),[e])}function x1(e,t){lr(()=>{if(e&&e.ref&&t)return e.ref.current=t.current,()=>{e.ref&&(e.ref.current=null)}})}function w1(e,t){let n=window.getComputedStyle(e),r=/(auto|scroll)/.test(n.overflow+n.overflowX+n.overflowY);return r&&t&&(r=e.scrollHeight!==e.clientHeight||e.scrollWidth!==e.clientWidth),r}function S1(e,t){const n=[];for(;e&&e!==document.documentElement;)w1(e,t)&&n.push(e),e=e.parentElement;return n}let P1=0;const Qa=new Map;function C1(e){let[t,n]=v.useState();return lr(()=>{if(!e)return;let r=Qa.get(e);if(r)n(r.element.id);else{let i=`react-aria-description-${P1++}`;n(i);let o=document.createElement("div");o.id=i,o.style.display="none",o.textContent=e,document.body.appendChild(o),r={refCount:0,element:o},Qa.set(e,r)}return r.refCount++,()=>{r&&--r.refCount===0&&(r.element.remove(),Qa.delete(e))}},[e]),{"aria-describedby":e?t:void 0}}function T1(e,t,n,r){let i=vn(n),o=n==null;v.useEffect(()=>{if(o||!e.current)return;let s=e.current;return s.addEventListener(t,i,r),()=>{s.removeEventListener(t,i,r)}},[e,t,r,o,i])}function Xh(e,t){let n=Zh(e,t,"left"),r=Zh(e,t,"top"),i=t.offsetWidth,o=t.offsetHeight,s=e.scrollLeft,l=e.scrollTop,{borderTopWidth:a,borderLeftWidth:u}=getComputedStyle(e),c=e.scrollLeft+parseInt(u,10),f=e.scrollTop+parseInt(a,10),d=c+e.clientWidth,h=f+e.clientHeight;n<=s?s=n-parseInt(u,10):n+i>d&&(s+=n+i-d),r<=f?l=r-parseInt(a,10):r+o>h&&(l+=r+o-h),e.scrollLeft=s,e.scrollTop=l}function Zh(e,t,n){const r=n==="left"?"offsetLeft":"offsetTop";let i=0;for(;t.offsetParent&&(i+=t[r],t.offsetParent!==e);){if(t.offsetParent.contains(e)){i-=e[r];break}t=t.offsetParent}return i}function qh(e,t){if(document.contains(e)){let s=document.scrollingElement||document.documentElement;if(window.getComputedStyle(s).overflow==="hidden"){let a=S1(e);for(let u of a)Xh(u,e)}else{var n;let{left:a,top:u}=e.getBoundingClientRect();e==null||(n=e.scrollIntoView)===null||n===void 0||n.call(e,{block:"nearest"});let{left:c,top:f}=e.getBoundingClientRect();if(Math.abs(a-c)>1||Math.abs(u-f)>1){var r,i,o;t==null||(i=t.containingElement)===null||i===void 0||(r=i.scrollIntoView)===null||r===void 0||r.call(i,{block:"center",inline:"center"}),(o=e.scrollIntoView)===null||o===void 0||o.call(e,{block:"nearest"})}}}}function Ya(e){return e.mozInputSource===0&&e.isTrusted?!0:Hh()&&e.pointerType?e.type==="click"&&e.buttons===1:e.detail===0&&!e.pointerType}function $1(e){return!Hh()&&e.width===0&&e.height===0||e.width===1&&e.height===1&&e.pressure===0&&e.detail===0&&e.pointerType==="mouse"}function Jh(e,t,n){let[r,i]=v.useState(e||t),o=v.useRef(e!==void 0),s=e!==void 0;v.useEffect(()=>{let u=o.current;u!==s&&console.warn(`WARN: A component changed from ${u?"controlled":"uncontrolled"} to ${s?"controlled":"uncontrolled"}.`),o.current=s},[s]);let l=s?e:r,a=v.useCallback((u,...c)=>{let f=(d,...h)=>{n&&(Object.is(l,d)||n(d,...h)),s||(l=d)};typeof u=="function"?(console.warn("We can not support a function callback. See Github Issues for details https://github.com/adobe/react-spectrum/issues/2320"),i((h,...x)=>{let w=u(s?l:h,...x);return f(w,...c),s?h:w})):(s||i(u),f(u,...c))},[s,l,n]);return[l,a]}let ur="default",Xa="",Zo=new WeakMap;function ep(e){if(Ha()){if(ur==="default"){const t=Re(e);Xa=t.documentElement.style.webkitUserSelect,t.documentElement.style.webkitUserSelect="none"}ur="disabled"}else(e instanceof HTMLElement||e instanceof SVGElement)&&(Zo.set(e,e.style.userSelect),e.style.userSelect="none")}function qo(e){if(Ha()){if(ur!=="disabled")return;ur="restoring",setTimeout(()=>{Gh(()=>{if(ur==="restoring"){const t=Re(e);t.documentElement.style.webkitUserSelect==="none"&&(t.documentElement.style.webkitUserSelect=Xa||""),Xa="",ur="default"}})},300)}else if((e instanceof HTMLElement||e instanceof SVGElement)&&e&&Zo.has(e)){let t=Zo.get(e);e.style.userSelect==="none"&&(e.style.userSelect=t),e.getAttribute("style")===""&&e.removeAttribute("style"),Zo.delete(e)}}const tp=B.createContext({register:()=>{}});tp.displayName="PressResponderContext";function k1(e,t){return t.get?t.get.call(e):t.value}function np(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}function E1(e,t){var n=np(e,t,"get");return k1(e,n)}function b1(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function M1(e,t,n){b1(e,t),t.set(e,n)}function L1(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}function rp(e,t,n){var r=np(e,t,"set");return L1(e,r,n),n}function D1(e){let t=v.useContext(tp);if(t){let{register:n,...r}=t;e=st(r,e),n()}return x1(t,e.ref),e}var Jo=new WeakMap;class es{continuePropagation(){rp(this,Jo,!1)}get shouldStopPropagation(){return E1(this,Jo)}constructor(t,n,r){M1(this,Jo,{writable:!0,value:void 0}),rp(this,Jo,!0),this.type=t,this.pointerType=n,this.target=r.currentTarget,this.shiftKey=r.shiftKey,this.metaKey=r.metaKey,this.ctrlKey=r.ctrlKey,this.altKey=r.altKey}}const ip=Symbol("linkClicked");function op(e){let{onPress:t,onPressChange:n,onPressStart:r,onPressEnd:i,onPressUp:o,isDisabled:s,isPressed:l,preventFocusOnPress:a,shouldCancelOnPointerExit:u,allowTextSelectionOnPress:c,ref:f,...d}=D1(e),[h,x]=v.useState(!1),w=v.useRef({isPressed:!1,ignoreEmulatedMouseEvents:!1,ignoreClickAfterPress:!1,didFirePressStart:!1,isTriggeringEvent:!1,activePointerId:null,target:null,isOverTarget:!1,pointerType:null}),{addGlobalListener:P,removeAllGlobalListeners:y}=Qh(),p=vn((g,M)=>{let T=w.current;if(s||T.didFirePressStart)return!1;let E=!0;if(T.isTriggeringEvent=!0,r){let I=new es("pressstart",M,g);r(I),E=I.shouldStopPropagation}return n&&n(!0),T.isTriggeringEvent=!1,T.didFirePressStart=!0,x(!0),E}),m=vn((g,M,T=!0)=>{let E=w.current;if(!E.didFirePressStart)return!1;E.ignoreClickAfterPress=!0,E.didFirePressStart=!1,E.isTriggeringEvent=!0;let I=!0;if(i){let $=new es("pressend",M,g);i($),I=$.shouldStopPropagation}if(n&&n(!1),x(!1),t&&T&&!s){let $=new es("press",M,g);t($),I&&(I=$.shouldStopPropagation)}return E.isTriggeringEvent=!1,I}),S=vn((g,M)=>{let T=w.current;if(s)return!1;if(o){T.isTriggeringEvent=!0;let E=new es("pressup",M,g);return o(E),T.isTriggeringEvent=!1,E.shouldStopPropagation}return!0}),C=vn(g=>{let M=w.current;M.isPressed&&M.target&&(M.isOverTarget&&M.pointerType!=null&&m($t(M.target,g),M.pointerType,!1),M.isPressed=!1,M.isOverTarget=!1,M.activePointerId=null,M.pointerType=null,y(),c||qo(M.target))}),b=vn(g=>{u&&C(g)}),L=v.useMemo(()=>{let g=w.current,M={onKeyDown(E){if(qa(E.nativeEvent,E.currentTarget)&&E.currentTarget.contains(E.target)){var I;lp(E.target,E.key)&&E.preventDefault();let $=!0;if(!g.isPressed&&!E.repeat){g.target=E.currentTarget,g.isPressed=!0,$=p(E,"keyboard");let k=E.currentTarget,z=U=>{qa(U,k)&&!U.repeat&&k.contains(U.target)&&g.target&&S($t(g.target,U),"keyboard")};P(Re(E.currentTarget),"keyup",zh(z,T),!0)}$&&E.stopPropagation(),E.metaKey&&xn()&&((I=g.metaKeyEvents)===null||I===void 0||I.set(E.key,E.nativeEvent))}else E.key==="Meta"&&(g.metaKeyEvents=new Map)},onClick(E){if(!(E&&!E.currentTarget.contains(E.target))&&E&&E.button===0&&!g.isTriggeringEvent&&!wn.isOpening){let I=!0;if(s&&E.preventDefault(),!g.ignoreClickAfterPress&&!g.ignoreEmulatedMouseEvents&&!g.isPressed&&(g.pointerType==="virtual"||Ya(E.nativeEvent))){!s&&!a&&Tt(E.currentTarget);let $=p(E,"virtual"),k=S(E,"virtual"),z=m(E,"virtual");I=$&&k&&z}g.ignoreEmulatedMouseEvents=!1,g.ignoreClickAfterPress=!1,I&&E.stopPropagation()}}},T=E=>{var I;if(g.isPressed&&g.target&&qa(E,g.target)){var $;lp(E.target,E.key)&&E.preventDefault();let z=E.target;m($t(g.target,E),"keyboard",g.target.contains(z)),y(),E.key!=="Enter"&&Za(g.target)&&g.target.contains(z)&&!E[ip]&&(E[ip]=!0,wn(g.target,E,!1)),g.isPressed=!1,($=g.metaKeyEvents)===null||$===void 0||$.delete(E.key)}else if(E.key==="Meta"&&(!((I=g.metaKeyEvents)===null||I===void 0)&&I.size)){var k;let z=g.metaKeyEvents;g.metaKeyEvents=void 0;for(let U of z.values())(k=g.target)===null||k===void 0||k.dispatchEvent(new KeyboardEvent("keyup",U))}};if(typeof PointerEvent<"u"){M.onPointerDown=k=>{if(k.button!==0||!k.currentTarget.contains(k.target))return;if($1(k.nativeEvent)){g.pointerType="virtual";return}Ja(k.currentTarget)&&k.preventDefault(),g.pointerType=k.pointerType;let z=!0;g.isPressed||(g.isPressed=!0,g.isOverTarget=!0,g.activePointerId=k.pointerId,g.target=k.currentTarget,!s&&!a&&Tt(k.currentTarget),c||ep(g.target),z=p(k,g.pointerType),P(Re(k.currentTarget),"pointermove",E,!1),P(Re(k.currentTarget),"pointerup",I,!1),P(Re(k.currentTarget),"pointercancel",$,!1)),z&&k.stopPropagation()},M.onMouseDown=k=>{k.currentTarget.contains(k.target)&&k.button===0&&(Ja(k.currentTarget)&&k.preventDefault(),k.stopPropagation())},M.onPointerUp=k=>{!k.currentTarget.contains(k.target)||g.pointerType==="virtual"||k.button===0&&cr(k,k.currentTarget)&&S(k,g.pointerType||k.pointerType)};let E=k=>{k.pointerId===g.activePointerId&&(g.target&&cr(k,g.target)?!g.isOverTarget&&g.pointerType!=null&&(g.isOverTarget=!0,p($t(g.target,k),g.pointerType)):g.target&&g.isOverTarget&&g.pointerType!=null&&(g.isOverTarget=!1,m($t(g.target,k),g.pointerType,!1),b(k)))},I=k=>{k.pointerId===g.activePointerId&&g.isPressed&&k.button===0&&g.target&&(cr(k,g.target)&&g.pointerType!=null?m($t(g.target,k),g.pointerType):g.isOverTarget&&g.pointerType!=null&&m($t(g.target,k),g.pointerType,!1),g.isPressed=!1,g.isOverTarget=!1,g.activePointerId=null,g.pointerType=null,y(),c||qo(g.target))},$=k=>{C(k)};M.onDragStart=k=>{k.currentTarget.contains(k.target)&&C(k)}}else{M.onMouseDown=$=>{if($.button!==0||!$.currentTarget.contains($.target))return;if(Ja($.currentTarget)&&$.preventDefault(),g.ignoreEmulatedMouseEvents){$.stopPropagation();return}g.isPressed=!0,g.isOverTarget=!0,g.target=$.currentTarget,g.pointerType=Ya($.nativeEvent)?"virtual":"mouse",!s&&!a&&Tt($.currentTarget),p($,g.pointerType)&&$.stopPropagation(),P(Re($.currentTarget),"mouseup",E,!1)},M.onMouseEnter=$=>{if(!$.currentTarget.contains($.target))return;let k=!0;g.isPressed&&!g.ignoreEmulatedMouseEvents&&g.pointerType!=null&&(g.isOverTarget=!0,k=p($,g.pointerType)),k&&$.stopPropagation()},M.onMouseLeave=$=>{if(!$.currentTarget.contains($.target))return;let k=!0;g.isPressed&&!g.ignoreEmulatedMouseEvents&&g.pointerType!=null&&(g.isOverTarget=!1,k=m($,g.pointerType,!1),b($)),k&&$.stopPropagation()},M.onMouseUp=$=>{$.currentTarget.contains($.target)&&!g.ignoreEmulatedMouseEvents&&$.button===0&&S($,g.pointerType||"mouse")};let E=$=>{if($.button===0){if(g.isPressed=!1,y(),g.ignoreEmulatedMouseEvents){g.ignoreEmulatedMouseEvents=!1;return}g.target&&cr($,g.target)&&g.pointerType!=null?m($t(g.target,$),g.pointerType):g.target&&g.isOverTarget&&g.pointerType!=null&&m($t(g.target,$),g.pointerType,!1),g.isOverTarget=!1}};M.onTouchStart=$=>{if(!$.currentTarget.contains($.target))return;let k=A1($.nativeEvent);if(!k)return;g.activePointerId=k.identifier,g.ignoreEmulatedMouseEvents=!0,g.isOverTarget=!0,g.isPressed=!0,g.target=$.currentTarget,g.pointerType="touch",!s&&!a&&Tt($.currentTarget),c||ep(g.target),p($,g.pointerType)&&$.stopPropagation(),P(ot($.currentTarget),"scroll",I,!0)},M.onTouchMove=$=>{if(!$.currentTarget.contains($.target))return;if(!g.isPressed){$.stopPropagation();return}let k=sp($.nativeEvent,g.activePointerId),z=!0;k&&cr(k,$.currentTarget)?!g.isOverTarget&&g.pointerType!=null&&(g.isOverTarget=!0,z=p($,g.pointerType)):g.isOverTarget&&g.pointerType!=null&&(g.isOverTarget=!1,z=m($,g.pointerType,!1),b($)),z&&$.stopPropagation()},M.onTouchEnd=$=>{if(!$.currentTarget.contains($.target))return;if(!g.isPressed){$.stopPropagation();return}let k=sp($.nativeEvent,g.activePointerId),z=!0;k&&cr(k,$.currentTarget)&&g.pointerType!=null?(S($,g.pointerType),z=m($,g.pointerType)):g.isOverTarget&&g.pointerType!=null&&(z=m($,g.pointerType,!1)),z&&$.stopPropagation(),g.isPressed=!1,g.activePointerId=null,g.isOverTarget=!1,g.ignoreEmulatedMouseEvents=!0,g.target&&!c&&qo(g.target),y()},M.onTouchCancel=$=>{$.currentTarget.contains($.target)&&($.stopPropagation(),g.isPressed&&C($))};let I=$=>{g.isPressed&&$.target.contains(g.target)&&C({currentTarget:g.target,shiftKey:!1,ctrlKey:!1,metaKey:!1,altKey:!1})};M.onDragStart=$=>{$.currentTarget.contains($.target)&&C($)}}return M},[P,s,a,y,c,C,b,m,p,S]);return v.useEffect(()=>()=>{var g;c||qo((g=w.current.target)!==null&&g!==void 0?g:void 0)},[c]),{isPressed:l||h,pressProps:st(d,L)}}function Za(e){return e.tagName==="A"&&e.hasAttribute("href")}function qa(e,t){const{key:n,code:r}=e,i=t,o=i.getAttribute("role");return(n==="Enter"||n===" "||n==="Spacebar"||r==="Space")&&!(i instanceof ot(i).HTMLInputElement&&!ap(i,n)||i instanceof ot(i).HTMLTextAreaElement||i.isContentEditable)&&!((o==="link"||!o&&Za(i))&&n!=="Enter")}function A1(e){const{targetTouches:t}=e;return t.length>0?t[0]:null}function sp(e,t){const n=e.changedTouches;for(let r=0;rt.right||t.left>e.right||e.top>t.bottom||t.top>e.bottom)}function cr(e,t){let n=t.getBoundingClientRect(),r=R1(e);return F1(n,r)}function Ja(e){return!(e instanceof HTMLElement)||!e.hasAttribute("draggable")}function lp(e,t){return e instanceof HTMLInputElement?!ap(e,t):e instanceof HTMLButtonElement?e.type!=="submit"&&e.type!=="reset":!Za(e)}const V1=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function ap(e,t){return e.type==="checkbox"||e.type==="radio"?t===" ":V1.has(e.type)}class N1{isDefaultPrevented(){return this.nativeEvent.defaultPrevented}preventDefault(){this.defaultPrevented=!0,this.nativeEvent.preventDefault()}stopPropagation(){this.nativeEvent.stopPropagation(),this.isPropagationStopped=()=>!0}isPropagationStopped(){return!1}persist(){}constructor(t,n){this.nativeEvent=n,this.target=n.target,this.currentTarget=n.currentTarget,this.relatedTarget=n.relatedTarget,this.bubbles=n.bubbles,this.cancelable=n.cancelable,this.defaultPrevented=n.defaultPrevented,this.eventPhase=n.eventPhase,this.isTrusted=n.isTrusted,this.timeStamp=n.timeStamp,this.type=t}}function up(e){let t=v.useRef({isFocused:!1,observer:null});lr(()=>{const r=t.current;return()=>{r.observer&&(r.observer.disconnect(),r.observer=null)}},[]);let n=vn(r=>{e==null||e(r)});return v.useCallback(r=>{if(r.target instanceof HTMLButtonElement||r.target instanceof HTMLInputElement||r.target instanceof HTMLTextAreaElement||r.target instanceof HTMLSelectElement){t.current.isFocused=!0;let i=r.target,o=s=>{t.current.isFocused=!1,i.disabled&&n(new N1("blur",s)),t.current.observer&&(t.current.observer.disconnect(),t.current.observer=null)};i.addEventListener("focusout",o,{once:!0}),t.current.observer=new MutationObserver(()=>{if(t.current.isFocused&&i.disabled){var s;(s=t.current.observer)===null||s===void 0||s.disconnect();let l=i===document.activeElement?null:document.activeElement;i.dispatchEvent(new FocusEvent("blur",{relatedTarget:l})),i.dispatchEvent(new FocusEvent("focusout",{bubbles:!0,relatedTarget:l}))}}),t.current.observer.observe(i,{attributes:!0,attributeFilter:["disabled"]})}},[n])}function K1(e){let{isDisabled:t,onFocus:n,onBlur:r,onFocusChange:i}=e;const o=v.useCallback(a=>{if(a.target===a.currentTarget)return r&&r(a),i&&i(!1),!0},[r,i]),s=up(o),l=v.useCallback(a=>{const u=Re(a.target);a.target===a.currentTarget&&u.activeElement===a.target&&(n&&n(a),i&&i(!0),s(a))},[i,n,s]);return{focusProps:{onFocus:!t&&(n||i||r)?l:void 0,onBlur:!t&&(r||i)?o:void 0}}}let fr=null,eu=new Set,di=new Map,Sn=!1,tu=!1;const I1={Tab:!0,Escape:!0};function nu(e,t){for(let n of eu)n(e,t)}function j1(e){return!(e.metaKey||!xn()&&e.altKey||e.ctrlKey||e.key==="Control"||e.key==="Shift"||e.key==="Meta")}function ts(e){Sn=!0,j1(e)&&(fr="keyboard",nu("keyboard",e))}function Ye(e){fr="pointer",(e.type==="mousedown"||e.type==="pointerdown")&&(Sn=!0,nu("pointer",e))}function cp(e){Ya(e)&&(Sn=!0,fr="virtual")}function fp(e){e.target===window||e.target===document||(!Sn&&!tu&&(fr="virtual",nu("virtual",e)),Sn=!1,tu=!1)}function dp(){Sn=!1,tu=!0}function ru(e){if(typeof window>"u"||di.get(ot(e)))return;const t=ot(e),n=Re(e);let r=t.HTMLElement.prototype.focus;t.HTMLElement.prototype.focus=function(){Sn=!0,r.apply(this,arguments)},n.addEventListener("keydown",ts,!0),n.addEventListener("keyup",ts,!0),n.addEventListener("click",cp,!0),t.addEventListener("focus",fp,!0),t.addEventListener("blur",dp,!1),typeof PointerEvent<"u"?(n.addEventListener("pointerdown",Ye,!0),n.addEventListener("pointermove",Ye,!0),n.addEventListener("pointerup",Ye,!0)):(n.addEventListener("mousedown",Ye,!0),n.addEventListener("mousemove",Ye,!0),n.addEventListener("mouseup",Ye,!0)),t.addEventListener("beforeunload",()=>{hp(e)},{once:!0}),di.set(t,{focus:r})}const hp=(e,t)=>{const n=ot(e),r=Re(e);t&&r.removeEventListener("DOMContentLoaded",t),di.has(n)&&(n.HTMLElement.prototype.focus=di.get(n).focus,r.removeEventListener("keydown",ts,!0),r.removeEventListener("keyup",ts,!0),r.removeEventListener("click",cp,!0),n.removeEventListener("focus",fp,!0),n.removeEventListener("blur",dp,!1),typeof PointerEvent<"u"?(r.removeEventListener("pointerdown",Ye,!0),r.removeEventListener("pointermove",Ye,!0),r.removeEventListener("pointerup",Ye,!0)):(r.removeEventListener("mousedown",Ye,!0),r.removeEventListener("mousemove",Ye,!0),r.removeEventListener("mouseup",Ye,!0)),di.delete(n))};function O1(e){const t=Re(e);let n;return t.readyState!=="loading"?ru(e):(n=()=>{ru(e)},t.addEventListener("DOMContentLoaded",n)),()=>hp(e,n)}typeof document<"u"&&O1();function pp(){return fr!=="pointer"}function iu(){return fr}const _1=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function z1(e,t,n){var r;const i=typeof window<"u"?ot(n==null?void 0:n.target).HTMLInputElement:HTMLInputElement,o=typeof window<"u"?ot(n==null?void 0:n.target).HTMLTextAreaElement:HTMLTextAreaElement,s=typeof window<"u"?ot(n==null?void 0:n.target).HTMLElement:HTMLElement,l=typeof window<"u"?ot(n==null?void 0:n.target).KeyboardEvent:KeyboardEvent;return e=e||(n==null?void 0:n.target)instanceof i&&!_1.has(n==null||(r=n.target)===null||r===void 0?void 0:r.type)||(n==null?void 0:n.target)instanceof o||(n==null?void 0:n.target)instanceof s&&(n==null?void 0:n.target.isContentEditable),!(e&&t==="keyboard"&&n instanceof l&&!I1[n.key])}function B1(e,t,n){ru(),v.useEffect(()=>{let r=(i,o)=>{z1(!!(n!=null&&n.isTextInput),i,o)&&e(pp())};return eu.add(r),()=>{eu.delete(r)}},t)}function U1(e){let{isDisabled:t,onBlurWithin:n,onFocusWithin:r,onFocusWithinChange:i}=e,o=v.useRef({isFocusWithin:!1}),s=v.useCallback(u=>{o.current.isFocusWithin&&!u.currentTarget.contains(u.relatedTarget)&&(o.current.isFocusWithin=!1,n&&n(u),i&&i(!1))},[n,i,o]),l=up(s),a=v.useCallback(u=>{!o.current.isFocusWithin&&document.activeElement===u.target&&(r&&r(u),i&&i(!0),o.current.isFocusWithin=!0,l(u))},[r,i,l]);return t?{focusWithinProps:{onFocus:void 0,onBlur:void 0}}:{focusWithinProps:{onFocus:a,onBlur:s}}}let ns=!1,ou=0;function su(){ns=!0,setTimeout(()=>{ns=!1},50)}function mp(e){e.pointerType==="touch"&&su()}function H1(){if(!(typeof document>"u"))return typeof PointerEvent<"u"?document.addEventListener("pointerup",mp):document.addEventListener("touchend",su),ou++,()=>{ou--,!(ou>0)&&(typeof PointerEvent<"u"?document.removeEventListener("pointerup",mp):document.removeEventListener("touchend",su))}}function W1(e){let{onHoverStart:t,onHoverChange:n,onHoverEnd:r,isDisabled:i}=e,[o,s]=v.useState(!1),l=v.useRef({isHovered:!1,ignoreEmulatedMouseEvents:!1,pointerType:"",target:null}).current;v.useEffect(H1,[]);let{hoverProps:a,triggerHoverEnd:u}=v.useMemo(()=>{let c=(h,x)=>{if(l.pointerType=x,i||x==="touch"||l.isHovered||!h.currentTarget.contains(h.target))return;l.isHovered=!0;let w=h.currentTarget;l.target=w,t&&t({type:"hoverstart",target:w,pointerType:x}),n&&n(!0),s(!0)},f=(h,x)=>{if(l.pointerType="",l.target=null,x==="touch"||!l.isHovered)return;l.isHovered=!1;let w=h.currentTarget;r&&r({type:"hoverend",target:w,pointerType:x}),n&&n(!1),s(!1)},d={};return typeof PointerEvent<"u"?(d.onPointerEnter=h=>{ns&&h.pointerType==="mouse"||c(h,h.pointerType)},d.onPointerLeave=h=>{!i&&h.currentTarget.contains(h.target)&&f(h,h.pointerType)}):(d.onTouchStart=()=>{l.ignoreEmulatedMouseEvents=!0},d.onMouseEnter=h=>{!l.ignoreEmulatedMouseEvents&&!ns&&c(h,"mouse"),l.ignoreEmulatedMouseEvents=!1},d.onMouseLeave=h=>{!i&&h.currentTarget.contains(h.target)&&f(h,"mouse")}),{hoverProps:d,triggerHoverEnd:f}},[t,n,r,i,l]);return v.useEffect(()=>{i&&u({currentTarget:l.target},l.pointerType)},[i]),{hoverProps:a,isHovered:o}}const G1=500;function Q1(e){let{isDisabled:t,onLongPressStart:n,onLongPressEnd:r,onLongPress:i,threshold:o=G1,accessibilityDescription:s}=e;const l=v.useRef();let{addGlobalListener:a,removeGlobalListener:u}=Qh(),{pressProps:c}=op({isDisabled:t,onPressStart(d){if(d.continuePropagation(),(d.pointerType==="mouse"||d.pointerType==="touch")&&(n&&n({...d,type:"longpressstart"}),l.current=setTimeout(()=>{d.target.dispatchEvent(new PointerEvent("pointercancel",{bubbles:!0})),i&&i({...d,type:"longpress"}),l.current=void 0},o),d.pointerType==="touch")){let h=x=>{x.preventDefault()};a(d.target,"contextmenu",h,{once:!0}),a(window,"pointerup",()=>{setTimeout(()=>{u(d.target,"contextmenu",h)},30)},{once:!0})}},onPressEnd(d){l.current&&clearTimeout(l.current),r&&(d.pointerType==="mouse"||d.pointerType==="touch")&&r({...d,type:"longpressend"})}}),f=C1(i&&!t?s:void 0);return{longPressProps:st(c,f)}}function lu(e){const t=Re(e);if(iu()==="virtual"){let n=t.activeElement;Gh(()=>{t.activeElement===n&&e.isConnected&&Tt(e)})}else Tt(e)}function Y1(e){const t=ot(e);if(!(e instanceof t.HTMLElement)&&!(e instanceof t.SVGElement))return!1;let{display:n,visibility:r}=e.style,i=n!=="none"&&r!=="hidden"&&r!=="collapse";if(i){const{getComputedStyle:o}=e.ownerDocument.defaultView;let{display:s,visibility:l}=o(e);i=s!=="none"&&l!=="hidden"&&l!=="collapse"}return i}function X1(e,t){return!e.hasAttribute("hidden")&&!e.hasAttribute("data-react-aria-prevent-focus")&&(e.nodeName==="DETAILS"&&t&&t.nodeName!=="SUMMARY"?e.hasAttribute("open"):!0)}function gp(e,t){return e.nodeName!=="#comment"&&Y1(e)&&X1(e,t)&&(!e.parentElement||gp(e.parentElement,e))}const au=["input:not([disabled]):not([type=hidden])","select:not([disabled])","textarea:not([disabled])","button:not([disabled])","a[href]","area[href]","summary","iframe","object","embed","audio[controls]","video[controls]","[contenteditable]"],Z1=au.join(":not([hidden]),")+",[tabindex]:not([disabled]):not([hidden])";au.push('[tabindex]:not([tabindex="-1"]):not([disabled])');const q1=au.join(':not([hidden]):not([tabindex="-1"]),');function yp(e,t){return!e||!t?!1:t.some(n=>n.contains(e))}function vp(e,t,n){let r=t!=null&&t.tabbable?q1:Z1,i=Re(e).createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode(o){var s;return!(t==null||(s=t.from)===null||s===void 0)&&s.contains(o)?NodeFilter.FILTER_REJECT:o.matches(r)&&gp(o)&&(!n||yp(o,n))&&(!(t!=null&&t.accept)||t.accept(o))?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});return t!=null&&t.from&&(i.currentNode=t.from),i}class uu{get size(){return this.fastMap.size}getTreeNode(t){return this.fastMap.get(t)}addTreeNode(t,n,r){let i=this.fastMap.get(n??null);if(!i)return;let o=new xp({scopeRef:t});i.addChild(o),o.parent=i,this.fastMap.set(t,o),r&&(o.nodeToRestore=r)}addNode(t){this.fastMap.set(t.scopeRef,t)}removeTreeNode(t){if(t===null)return;let n=this.fastMap.get(t);if(!n)return;let r=n.parent;for(let o of this.traverse())o!==n&&n.nodeToRestore&&o.nodeToRestore&&n.scopeRef&&n.scopeRef.current&&yp(o.nodeToRestore,n.scopeRef.current)&&(o.nodeToRestore=n.nodeToRestore);let i=n.children;r&&(r.removeChild(n),i.size>0&&i.forEach(o=>r&&r.addChild(o))),this.fastMap.delete(n.scopeRef)}*traverse(t=this.root){if(t.scopeRef!=null&&(yield t),t.children.size>0)for(let n of t.children)yield*this.traverse(n)}clone(){var t;let n=new uu;var r;for(let i of this.traverse())n.addTreeNode(i.scopeRef,(r=(t=i.parent)===null||t===void 0?void 0:t.scopeRef)!==null&&r!==void 0?r:null,i.nodeToRestore);return n}constructor(){this.fastMap=new Map,this.root=new xp({scopeRef:null}),this.fastMap.set(null,this.root)}}class xp{addChild(t){this.children.add(t),t.parent=this}removeChild(t){this.children.delete(t),t.parent=void 0}constructor(t){this.children=new Set,this.contain=!1,this.scopeRef=t.scopeRef}}new uu;function cu(e={}){let{autoFocus:t=!1,isTextInput:n,within:r}=e,i=v.useRef({isFocused:!1,isFocusVisible:t||pp()}),[o,s]=v.useState(!1),[l,a]=v.useState(()=>i.current.isFocused&&i.current.isFocusVisible),u=v.useCallback(()=>a(i.current.isFocused&&i.current.isFocusVisible),[]),c=v.useCallback(h=>{i.current.isFocused=h,s(h),u()},[u]);B1(h=>{i.current.isFocusVisible=h,u()},[],{isTextInput:n});let{focusProps:f}=K1({isDisabled:r,onFocusChange:c}),{focusWithinProps:d}=U1({isDisabled:!r,onFocusWithinChange:c});return{isFocused:o,isFocusVisible:l,focusProps:r?d:f}}function J1(e,t){let n=t==null?void 0:t.isDisabled,[r,i]=v.useState(!1);return lr(()=>{if(e!=null&&e.current&&!n){let o=()=>{if(e.current){let l=vp(e.current,{tabbable:!0});i(!!l.nextNode())}};o();let s=new MutationObserver(o);return s.observe(e.current,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["tabIndex","disabled"]}),()=>{s.disconnect()}}}),n?!1:r}const ex=new Set(["Arab","Syrc","Samr","Mand","Thaa","Mend","Nkoo","Adlm","Rohg","Hebr"]),tx=new Set(["ae","ar","arc","bcc","bqi","ckb","dv","fa","glk","he","ku","mzn","nqo","pnb","ps","sd","ug","ur","yi"]);function nx(e){if(Intl.Locale){let n=new Intl.Locale(e).maximize(),r=typeof n.getTextInfo=="function"?n.getTextInfo():n.textInfo;if(r)return r.direction==="rtl";if(n.script)return ex.has(n.script)}let t=e.split("-")[0];return tx.has(t)}const rx=Symbol.for("react-aria.i18n.locale");function wp(){let e=typeof window<"u"&&window[rx]||typeof navigator<"u"&&(navigator.language||navigator.userLanguage)||"en-US";try{Intl.DateTimeFormat.supportedLocalesOf([e])}catch{e="en-US"}return{locale:e,direction:nx(e)?"rtl":"ltr"}}let fu=wp(),hi=new Set;function Sp(){fu=wp();for(let e of hi)e(fu)}function ix(){let e=fi(),[t,n]=v.useState(fu);return v.useEffect(()=>(hi.size===0&&window.addEventListener("languagechange",Sp),hi.add(n),()=>{hi.delete(n),hi.size===0&&window.removeEventListener("languagechange",Sp)}),[]),e?{locale:"en-US",direction:"ltr"}:t}const ox=B.createContext(null);function Pp(){let e=ix();return v.useContext(ox)||e}function du(e){return f1()?e.altKey:e.ctrlKey}function dr(e){return xn()?e.metaKey:e.ctrlKey}const sx=1e3;function lx(e){let{keyboardDelegate:t,selectionManager:n,onTypeSelect:r}=e,i=v.useRef({search:"",timeout:null}).current,o=s=>{let l=ax(s.key);if(!l||s.ctrlKey||s.metaKey||!s.currentTarget.contains(s.target))return;l===" "&&i.search.trim().length>0&&(s.preventDefault(),"continuePropagation"in s||s.stopPropagation()),i.search+=l;let a=t.getKeyForSearch(i.search,n.focusedKey);a==null&&(a=t.getKeyForSearch(i.search)),a!=null&&(n.setFocusedKey(a),r&&r(a)),clearTimeout(i.timeout),i.timeout=setTimeout(()=>{i.search=""},sx)};return{typeSelectProps:{onKeyDownCapture:t.getKeyForSearch?o:null}}}function ax(e){return e.length===1||!/^[A-Z]/i.test(e)?e:""}function ux(e){let{selectionManager:t,keyboardDelegate:n,ref:r,autoFocus:i=!1,shouldFocusWrap:o=!1,disallowEmptySelection:s=!1,disallowSelectAll:l=!1,selectOnFocus:a=t.selectionBehavior==="replace",disallowTypeAhead:u=!1,shouldUseVirtualFocus:c,allowsTabNavigation:f=!1,isVirtualized:d,scrollRef:h=r,linkBehavior:x="action"}=e,{direction:w}=Pp(),P=Wa(),y=T=>{if(T.altKey&&T.key==="Tab"&&T.preventDefault(),!r.current.contains(T.target))return;const E=(R,V)=>{if(R!=null){if(t.isLink(R)&&x==="selection"&&a&&!du(T)){za.flushSync(()=>{t.setFocusedKey(R,V)});let _=h.current.querySelector(`[data-key="${CSS.escape(R.toString())}"]`),re=t.getItemProps(R);P.open(_,T,re.href,re.routerOptions);return}if(t.setFocusedKey(R,V),t.isLink(R)&&x==="override")return;T.shiftKey&&t.selectionMode==="multiple"?t.extendSelection(R):a&&!du(T)&&t.replaceSelection(R)}};switch(T.key){case"ArrowDown":if(n.getKeyBelow){var I,$;T.preventDefault();let R=t.focusedKey!=null?n.getKeyBelow(t.focusedKey):(I=n.getFirstKey)===null||I===void 0?void 0:I.call(n);R==null&&o&&(R=($=n.getFirstKey)===null||$===void 0?void 0:$.call(n,t.focusedKey)),E(R)}break;case"ArrowUp":if(n.getKeyAbove){var k,z;T.preventDefault();let R=t.focusedKey!=null?n.getKeyAbove(t.focusedKey):(k=n.getLastKey)===null||k===void 0?void 0:k.call(n);R==null&&o&&(R=(z=n.getLastKey)===null||z===void 0?void 0:z.call(n,t.focusedKey)),E(R)}break;case"ArrowLeft":if(n.getKeyLeftOf){var U,N;T.preventDefault();let R=n.getKeyLeftOf(t.focusedKey);R==null&&o&&(R=w==="rtl"?(U=n.getFirstKey)===null||U===void 0?void 0:U.call(n,t.focusedKey):(N=n.getLastKey)===null||N===void 0?void 0:N.call(n,t.focusedKey)),E(R,w==="rtl"?"first":"last")}break;case"ArrowRight":if(n.getKeyRightOf){var F,j;T.preventDefault();let R=n.getKeyRightOf(t.focusedKey);R==null&&o&&(R=w==="rtl"?(F=n.getLastKey)===null||F===void 0?void 0:F.call(n,t.focusedKey):(j=n.getFirstKey)===null||j===void 0?void 0:j.call(n,t.focusedKey)),E(R,w==="rtl"?"last":"first")}break;case"Home":if(n.getFirstKey){T.preventDefault();let R=n.getFirstKey(t.focusedKey,dr(T));t.setFocusedKey(R),dr(T)&&T.shiftKey&&t.selectionMode==="multiple"?t.extendSelection(R):a&&t.replaceSelection(R)}break;case"End":if(n.getLastKey){T.preventDefault();let R=n.getLastKey(t.focusedKey,dr(T));t.setFocusedKey(R),dr(T)&&T.shiftKey&&t.selectionMode==="multiple"?t.extendSelection(R):a&&t.replaceSelection(R)}break;case"PageDown":if(n.getKeyPageBelow){T.preventDefault();let R=n.getKeyPageBelow(t.focusedKey);E(R)}break;case"PageUp":if(n.getKeyPageAbove){T.preventDefault();let R=n.getKeyPageAbove(t.focusedKey);E(R)}break;case"a":dr(T)&&t.selectionMode==="multiple"&&l!==!0&&(T.preventDefault(),t.selectAll());break;case"Escape":!s&&t.selectedKeys.size!==0&&(T.stopPropagation(),T.preventDefault(),t.clearSelection());break;case"Tab":if(!f){if(T.shiftKey)r.current.focus();else{let R=vp(r.current,{tabbable:!0}),V,_;do _=R.lastChild(),_&&(V=_);while(_);V&&!V.contains(document.activeElement)&&Tt(V)}break}}},p=v.useRef({top:0,left:0});T1(h,"scroll",d?null:()=>{p.current={top:h.current.scrollTop,left:h.current.scrollLeft}});let m=T=>{if(t.isFocused){T.currentTarget.contains(T.target)||t.setFocused(!1);return}if(T.currentTarget.contains(T.target)){if(t.setFocused(!0),t.focusedKey==null){let $=z=>{z!=null&&(t.setFocusedKey(z),a&&t.replaceSelection(z))},k=T.relatedTarget;var E,I;k&&T.currentTarget.compareDocumentPosition(k)&Node.DOCUMENT_POSITION_FOLLOWING?$((E=t.lastSelectedKey)!==null&&E!==void 0?E:n.getLastKey()):$((I=t.firstSelectedKey)!==null&&I!==void 0?I:n.getFirstKey())}else d||(h.current.scrollTop=p.current.top,h.current.scrollLeft=p.current.left);if(!d&&t.focusedKey!=null){let $=h.current.querySelector(`[data-key="${CSS.escape(t.focusedKey.toString())}"]`);$&&($.contains(document.activeElement)||Tt($),iu()==="keyboard"&&qh($,{containingElement:r.current}))}}},S=T=>{T.currentTarget.contains(T.relatedTarget)||t.setFocused(!1)};const C=v.useRef(i);v.useEffect(()=>{if(C.current){let T=null;i==="first"&&(T=n.getFirstKey()),i==="last"&&(T=n.getLastKey());let E=t.selectedKeys;if(E.size){for(let I of E)if(t.canSelectItem(I)){T=I;break}}t.setFocused(!0),t.setFocusedKey(T),T==null&&!c&&lu(r.current)}},[]);let b=v.useRef(t.focusedKey);v.useEffect(()=>{let T=iu();if(t.isFocused&&t.focusedKey!=null&&(h!=null&&h.current)){let E=h.current.querySelector(`[data-key="${CSS.escape(t.focusedKey.toString())}"]`);E&&(T==="keyboard"||C.current)&&(d||Xh(h.current,E),T!=="virtual"&&qh(E,{containingElement:r.current}))}t.isFocused&&t.focusedKey==null&&b.current!=null&&lu(r.current),b.current=t.focusedKey,C.current=!1},[d,h,t.focusedKey,t.isFocused,r]);let L={onKeyDown:y,onFocus:m,onBlur:S,onMouseDown(T){h.current===T.target&&T.preventDefault()}},{typeSelectProps:g}=lx({keyboardDelegate:n,selectionManager:t});u||(L=st(g,L));let M;return c||(M=t.focusedKey==null?0:-1),{collectionProps:{...L,tabIndex:M}}}function cx(e){let{selectionManager:t,key:n,ref:r,shouldSelectOnPressUp:i,shouldUseVirtualFocus:o,focus:s,isDisabled:l,onAction:a,allowsDifferentPressOrigin:u,linkBehavior:c="action"}=e,f=Wa(),d=N=>{if(N.pointerType==="keyboard"&&du(N))t.toggleSelection(n);else{if(t.selectionMode==="none")return;if(t.isLink(n)){if(c==="selection"){let F=t.getItemProps(n);f.open(r.current,N,F.href,F.routerOptions),t.setSelectedKeys(t.selectedKeys);return}else if(c==="override"||c==="none")return}t.selectionMode==="single"?t.isSelected(n)&&!t.disallowEmptySelection?t.toggleSelection(n):t.replaceSelection(n):N&&N.shiftKey?t.extendSelection(n):t.selectionBehavior==="toggle"||N&&(dr(N)||N.pointerType==="touch"||N.pointerType==="virtual")?t.toggleSelection(n):t.replaceSelection(n)}};v.useEffect(()=>{n===t.focusedKey&&t.isFocused&&!o&&(s?s():document.activeElement!==r.current&&lu(r.current))},[r,n,t.focusedKey,t.childFocusStrategy,t.isFocused,o]),l=l||t.isDisabled(n);let h={};!o&&!l?h={tabIndex:n===t.focusedKey?0:-1,onFocus(N){N.target===r.current&&t.setFocusedKey(n)}}:l&&(h.onMouseDown=N=>{N.preventDefault()});let x=t.isLink(n)&&c==="override",w=t.isLink(n)&&c!=="selection"&&c!=="none",P=!l&&t.canSelectItem(n)&&!x,y=(a||w)&&!l,p=y&&(t.selectionBehavior==="replace"?!P:!P||t.isEmpty),m=y&&P&&t.selectionBehavior==="replace",S=p||m,C=v.useRef(null),b=S&&P,L=v.useRef(!1),g=v.useRef(!1),M=N=>{if(a&&a(),w){let F=t.getItemProps(n);f.open(r.current,N,F.href,F.routerOptions)}},T={};i?(T.onPressStart=N=>{C.current=N.pointerType,L.current=b,N.pointerType==="keyboard"&&(!S||Tp())&&d(N)},u?(T.onPressUp=p?null:N=>{N.pointerType!=="keyboard"&&P&&d(N)},T.onPress=p?M:null):T.onPress=N=>{if(p||m&&N.pointerType!=="mouse"){if(N.pointerType==="keyboard"&&!Cp())return;M(N)}else N.pointerType!=="keyboard"&&P&&d(N)}):(T.onPressStart=N=>{C.current=N.pointerType,L.current=b,g.current=p,P&&(N.pointerType==="mouse"&&!p||N.pointerType==="keyboard"&&(!y||Tp()))&&d(N)},T.onPress=N=>{(N.pointerType==="touch"||N.pointerType==="pen"||N.pointerType==="virtual"||N.pointerType==="keyboard"&&S&&Cp()||N.pointerType==="mouse"&&g.current)&&(S?M(N):P&&d(N))}),h["data-key"]=n,T.preventFocusOnPress=o;let{pressProps:E,isPressed:I}=op(T),$=m?N=>{C.current==="mouse"&&(N.stopPropagation(),N.preventDefault(),M(N))}:void 0,{longPressProps:k}=Q1({isDisabled:!b,onLongPress(N){N.pointerType==="touch"&&(d(N),t.setSelectionBehavior("toggle"))}}),z=N=>{C.current==="touch"&&L.current&&N.preventDefault()},U=t.isLink(n)?N=>{wn.isOpening||N.preventDefault()}:void 0;return{itemProps:st(h,P||p?E:{},b?k:{},{onDoubleClick:$,onDragStartCapture:z,onClick:U}),isPressed:I,isSelected:t.isSelected(n),isFocused:t.isFocused&&t.focusedKey===n,isDisabled:l,allowsSelection:P,hasAction:S}}function Cp(){let e=window.event;return(e==null?void 0:e.key)==="Enter"}function Tp(){let e=window.event;return(e==null?void 0:e.key)===" "||(e==null?void 0:e.code)==="Space"}class fx{build(t,n){return this.context=n,$p(()=>this.iterateCollection(t))}*iterateCollection(t){let{children:n,items:r}=t;if(typeof n=="function"){if(!r)throw new Error("props.children was a function but props.items is missing");for(let i of t.items)yield*this.getFullNode({value:i},{renderer:n})}else{let i=[];B.Children.forEach(n,s=>{i.push(s)});let o=0;for(let s of i){let l=this.getFullNode({element:s,index:o},{});for(let a of l)o++,yield a}}}getKey(t,n,r,i){if(t.key!=null)return t.key;if(n.type==="cell"&&n.key!=null)return`${i}${n.key}`;let o=n.value;if(o!=null){var s;let l=(s=o.key)!==null&&s!==void 0?s:o.id;if(l==null)throw new Error("No key found for item");return l}return i?`${i}.${n.index}`:`$.${n.index}`}getChildState(t,n){return{renderer:n.renderer||t.renderer}}*getFullNode(t,n,r,i){let o=t.element;if(!o&&t.value&&n&&n.renderer){let a=this.cache.get(t.value);if(a&&(!a.shouldInvalidate||!a.shouldInvalidate(this.context))){a.index=t.index,a.parentKey=i?i.key:null,yield a;return}o=n.renderer(t.value)}if(B.isValidElement(o)){let a=o.type;if(typeof a!="function"&&typeof a.getCollectionNode!="function"){let d=typeof o.type=="function"?o.type.name:o.type;throw new Error(`Unknown element <${d}> in collection.`)}let u=a.getCollectionNode(o.props,this.context),c=t.index,f=u.next();for(;!f.done&&f.value;){let d=f.value;t.index=c;let h=d.key;h||(h=d.element?null:this.getKey(o,t,n,r));let w=[...this.getFullNode({...d,key:h,index:c,wrapper:dx(t.wrapper,d.wrapper)},this.getChildState(n,d),r?`${r}${o.key}`:o.key,i)];for(let P of w){if(P.value=d.value||t.value,P.value&&this.cache.set(P.value,P),t.type&&P.type!==t.type)throw new Error(`Unsupported type <${hu(P.type)}> in <${hu(i.type)}>. Only <${hu(t.type)}> is supported.`);c++,yield P}f=u.next(w)}return}if(t.key==null)return;let s=this,l={type:t.type,props:t.props,key:t.key,parentKey:i?i.key:null,value:t.value,level:i?i.level+1:0,index:t.index,rendered:t.rendered,textValue:t.textValue,"aria-label":t["aria-label"],wrapper:t.wrapper,shouldInvalidate:t.shouldInvalidate,hasChildNodes:t.hasChildNodes,childNodes:$p(function*(){if(!t.hasChildNodes)return;let a=0;for(let u of t.childNodes()){u.key!=null&&(u.key=`${l.key}${u.key}`),u.index=a;let c=s.getFullNode(u,s.getChildState(n,u),l.key,l);for(let f of c)a++,yield f}})};yield l}constructor(){this.cache=new WeakMap}}function $p(e){let t=[],n=null;return{*[Symbol.iterator](){for(let r of t)yield r;n||(n=e());for(let r of n)t.push(r),yield r}}}function dx(e,t){if(e&&t)return n=>e(t(n));if(e)return e;if(t)return t}function hu(e){return e[0].toUpperCase()+e.slice(1)}function hx(e,t,n){let r=v.useMemo(()=>new fx,[]),{children:i,items:o,collection:s}=e;return v.useMemo(()=>{if(s)return s;let a=r.build({children:i,items:o},n);return t(a)},[r,i,o,s,n,t])}function px(e,t){return typeof t.getChildren=="function"?t.getChildren(e.key):e.childNodes}function mx(e){return gx(e)}function gx(e,t){for(let n of e)return n}function pu(e,t,n){if(t.parentKey===n.parentKey)return t.index-n.index;let r=[...kp(e,t),t],i=[...kp(e,n),n],o=r.slice(0,i.length).findIndex((s,l)=>s!==i[l]);return o!==-1?(t=r[o],n=i[o],t.index-n.index):r.findIndex(s=>s===n)>=0?1:(i.findIndex(s=>s===t)>=0,-1)}function kp(e,t){let n=[];for(;(t==null?void 0:t.parentKey)!=null;)t=e.getItem(t.parentKey),n.unshift(t);return n}const Ep=new WeakMap;function rs(e,t,n){return typeof t=="string"&&(t=t.replace(/\s+/g,"")),`${Ep.get(e)}-${n}-${t}`}function yx(e,t,n){let{key:r,isDisabled:i,shouldSelectOnPressUp:o}=e,{selectionManager:s,selectedKey:l}=t,a=r===l,u=i||t.isDisabled||t.selectionManager.isDisabled(r),{itemProps:c,isPressed:f}=cx({selectionManager:s,key:r,ref:n,isDisabled:u,shouldSelectOnPressUp:o,linkBehavior:"selection"}),d=rs(t,r,"tab"),h=rs(t,r,"tabpanel"),{tabIndex:x}=c,w=t.collection.getItem(r),P=Go(w==null?void 0:w.props,{labelable:!0});delete P.id;let y=v1(w==null?void 0:w.props);return{tabProps:st(P,y,c,{id:d,"aria-selected":a,"aria-disabled":u||void 0,"aria-controls":a?h:void 0,tabIndex:u?void 0:x,role:"tab"}),isSelected:a,isDisabled:u,isPressed:f}}function vx(e,t,n){let r=J1(n)?void 0:0;var i;const o=rs(t,(i=e.id)!==null&&i!==void 0?i:t==null?void 0:t.selectedKey,"tabpanel"),s=Yh({...e,id:o,"aria-labelledby":rs(t,t==null?void 0:t.selectedKey,"tab")});return{tabPanelProps:st(s,{tabIndex:r,role:"tabpanel","aria-describedby":e["aria-describedby"],"aria-details":e["aria-details"]})}}class xx{getKeyLeftOf(t){return this.flipDirection?this.getNextKey(t):this.getPreviousKey(t)}getKeyRightOf(t){return this.flipDirection?this.getPreviousKey(t):this.getNextKey(t)}getKeyAbove(t){return this.getPreviousKey(t)}getKeyBelow(t){return this.getNextKey(t)}isDisabled(t){var n,r;return this.disabledKeys.has(t)||!!(!((r=this.collection.getItem(t))===null||r===void 0||(n=r.props)===null||n===void 0)&&n.isDisabled)}getFirstKey(){let t=this.collection.getFirstKey();return t!=null&&this.isDisabled(t)&&(t=this.getNextKey(t)),t}getLastKey(){let t=this.collection.getLastKey();return t!=null&&this.isDisabled(t)&&(t=this.getPreviousKey(t)),t}getNextKey(t){do t=this.collection.getKeyAfter(t),t==null&&(t=this.collection.getFirstKey());while(this.isDisabled(t));return t}getPreviousKey(t){do t=this.collection.getKeyBefore(t),t==null&&(t=this.collection.getLastKey());while(this.isDisabled(t));return t}constructor(t,n,r,i=new Set){this.collection=t,this.flipDirection=n==="rtl"&&r==="horizontal",this.disabledKeys=i}}function wx(e,t,n){let{orientation:r="horizontal",keyboardActivation:i="automatic"}=e,{collection:o,selectionManager:s,disabledKeys:l}=t,{direction:a}=Pp(),u=v.useMemo(()=>new xx(o,a,r,l),[o,l,r,a]),{collectionProps:c}=ux({ref:n,selectionManager:s,keyboardDelegate:u,selectOnFocus:i==="automatic",disallowEmptySelection:!0,scrollRef:n,linkBehavior:"selection"}),f=_h();Ep.set(t,f);let d=Yh({...e,id:f});return{tabListProps:{...st(c,d),role:"tablist","aria-orientation":r,tabIndex:void 0}}}var bp={exports:{}},Mp={};/** * @license React * use-sync-external-store-shim.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 hr=v;function Sx(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Px=typeof Object.is=="function"?Object.is:Sx,Cx=hr.useState,Tx=hr.useEffect,$x=hr.useLayoutEffect,kx=hr.useDebugValue;function Ex(e,t){var n=t(),r=Cx({inst:{value:n,getSnapshot:t}}),i=r[0].inst,o=r[1];return $x(function(){i.value=n,i.getSnapshot=t,mu(i)&&o({inst:i})},[e,n,t]),Tx(function(){return mu(i)&&o({inst:i}),e(function(){mu(i)&&o({inst:i})})},[e]),kx(n),n}function mu(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Px(e,n)}catch{return!0}}function bx(e,t){return t()}var Mx=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?bx:Ex;Mp.useSyncExternalStore=hr.useSyncExternalStore!==void 0?hr.useSyncExternalStore:Mx,bp.exports=Mp;var Lx=bp.exports;class gu{get childNodes(){throw new Error("childNodes is not supported")}clone(){let t=new gu(this.type,this.key);return t.value=this.value,t.level=this.level,t.hasChildNodes=this.hasChildNodes,t.rendered=this.rendered,t.textValue=this.textValue,t["aria-label"]=this["aria-label"],t.index=this.index,t.parentKey=this.parentKey,t.prevKey=this.prevKey,t.nextKey=this.nextKey,t.firstChildKey=this.firstChildKey,t.lastChildKey=this.lastChildKey,t.props=this.props,t}constructor(t,n){this.value=null,this.level=0,this.hasChildNodes=!1,this.rendered=null,this.textValue="",this["aria-label"]=void 0,this.index=0,this.parentKey=null,this.prevKey=null,this.nextKey=null,this.firstChildKey=null,this.lastChildKey=null,this.props={},this.type=t,this.key=n}}class Lp{*[Symbol.iterator](){let t=this.firstChild;for(;t;)yield t,t=t.nextSibling}get firstChild(){return this._firstChild}set firstChild(t){this._firstChild=t,this.ownerDocument.markDirty(this)}get lastChild(){return this._lastChild}set lastChild(t){this._lastChild=t,this.ownerDocument.markDirty(this)}get previousSibling(){return this._previousSibling}set previousSibling(t){this._previousSibling=t,this.ownerDocument.markDirty(this)}get nextSibling(){return this._nextSibling}set nextSibling(t){this._nextSibling=t,this.ownerDocument.markDirty(this)}get parentNode(){return this._parentNode}set parentNode(t){this._parentNode=t,this.ownerDocument.markDirty(this)}get isConnected(){var t;return((t=this.parentNode)===null||t===void 0?void 0:t.isConnected)||!1}appendChild(t){this.ownerDocument.startTransaction(),t.parentNode&&t.parentNode.removeChild(t),this.firstChild==null&&(this.firstChild=t),this.lastChild?(this.lastChild.nextSibling=t,t.index=this.lastChild.index+1,t.previousSibling=this.lastChild):(t.previousSibling=null,t.index=0),t.parentNode=this,t.nextSibling=null,this.lastChild=t,this.ownerDocument.markDirty(this),t.hasSetProps&&this.ownerDocument.addNode(t),this.ownerDocument.endTransaction(),this.ownerDocument.queueUpdate()}insertBefore(t,n){if(n==null)return this.appendChild(t);this.ownerDocument.startTransaction(),t.parentNode&&t.parentNode.removeChild(t),t.nextSibling=n,t.previousSibling=n.previousSibling,t.index=n.index,this.firstChild===n?this.firstChild=t:n.previousSibling&&(n.previousSibling.nextSibling=t),n.previousSibling=t,t.parentNode=n.parentNode;let r=n;for(;r;)r.index++,r=r.nextSibling;t.hasSetProps&&this.ownerDocument.addNode(t),this.ownerDocument.endTransaction(),this.ownerDocument.queueUpdate()}removeChild(t){if(t.parentNode!==this)return;this.ownerDocument.startTransaction();let n=t.nextSibling;for(;n;)n.index--,n=n.nextSibling;t.nextSibling&&(t.nextSibling.previousSibling=t.previousSibling),t.previousSibling&&(t.previousSibling.nextSibling=t.nextSibling),this.firstChild===t&&(this.firstChild=t.nextSibling),this.lastChild===t&&(this.lastChild=t.previousSibling),t.parentNode=null,t.nextSibling=null,t.previousSibling=null,t.index=0,this.ownerDocument.removeNode(t),this.ownerDocument.endTransaction(),this.ownerDocument.queueUpdate()}addEventListener(){}removeEventListener(){}constructor(t){this._firstChild=null,this._lastChild=null,this._previousSibling=null,this._nextSibling=null,this._parentNode=null,this.ownerDocument=t}}class pi extends Lp{get index(){return this._index}set index(t){this._index=t,this.ownerDocument.markDirty(this)}get level(){return this.parentNode instanceof pi?this.parentNode.level+(this.node.type==="item"?1:0):0}updateNode(){var t,n,r,i;let o=this.ownerDocument.getMutableNode(this);o.index=this.index,o.level=this.level,o.parentKey=this.parentNode instanceof pi?this.parentNode.node.key:null;var s;o.prevKey=(s=(t=this.previousSibling)===null||t===void 0?void 0:t.node.key)!==null&&s!==void 0?s:null;var l;o.nextKey=(l=(n=this.nextSibling)===null||n===void 0?void 0:n.node.key)!==null&&l!==void 0?l:null,o.hasChildNodes=!!this.firstChild;var a;o.firstChildKey=(a=(r=this.firstChild)===null||r===void 0?void 0:r.node.key)!==null&&a!==void 0?a:null;var u;o.lastChildKey=(u=(i=this.lastChild)===null||i===void 0?void 0:i.node.key)!==null&&u!==void 0?u:null}setProps(t,n,r){let i=this.ownerDocument.getMutableNode(this),{value:o,textValue:s,id:l,...a}=t;if(a.ref=n,i.props=a,i.rendered=r,i.value=o,i.textValue=s||(typeof r=="string"?r:"")||t["aria-label"]||"",l!=null&&l!==i.key){if(this.hasSetProps)throw new Error("Cannot change the id of an item");i.key=l}this.hasSetProps||(this.ownerDocument.addNode(this),this.ownerDocument.endTransaction(),this.hasSetProps=!0),this.ownerDocument.queueUpdate()}get style(){return{}}hasAttribute(){}setAttribute(){}setAttributeNS(){}removeAttribute(){}constructor(t,n){super(n),this.nodeType=8,this._index=0,this.hasSetProps=!1,this.node=new gu(t,`react-aria-${++n.nodeId}`),this.ownerDocument.startTransaction()}}class Dx{get size(){return this.keyMap.size}getKeys(){return this.keyMap.keys()}*[Symbol.iterator](){let t=this.firstKey!=null?this.keyMap.get(this.firstKey):void 0;for(;t;)yield t,t=t.nextKey!=null?this.keyMap.get(t.nextKey):void 0}getChildren(t){let n=this.keyMap;return{*[Symbol.iterator](){let r=n.get(t),i=(r==null?void 0:r.firstChildKey)!=null?n.get(r.firstChildKey):null;for(;i;)yield i,i=i.nextKey!=null?n.get(i.nextKey):void 0}}}getKeyBefore(t){let n=this.keyMap.get(t);if(!n)return null;if(n.prevKey!=null){for(n=this.keyMap.get(n.prevKey);n&&n.type!=="item"&&n.lastChildKey!=null;)n=this.keyMap.get(n.lastChildKey);var r;return(r=n==null?void 0:n.key)!==null&&r!==void 0?r:null}return n.parentKey}getKeyAfter(t){let n=this.keyMap.get(t);if(!n)return null;if(n.type!=="item"&&n.firstChildKey!=null)return n.firstChildKey;for(;n;){if(n.nextKey!=null)return n.nextKey;if(n.parentKey!=null)n=this.keyMap.get(n.parentKey);else return null}return null}getFirstKey(){return this.firstKey}getLastKey(){let t=this.lastKey!=null?this.keyMap.get(this.lastKey):null;for(;(t==null?void 0:t.lastChildKey)!=null;)t=this.keyMap.get(t.lastChildKey);var n;return(n=t==null?void 0:t.key)!==null&&n!==void 0?n:null}getItem(t){var n;return(n=this.keyMap.get(t))!==null&&n!==void 0?n:null}at(){throw new Error("Not implemented")}clone(){let t=this.constructor,n=new t;return n.keyMap=new Map(this.keyMap),n.firstKey=this.firstKey,n.lastKey=this.lastKey,n}addNode(t){if(this.frozen)throw new Error("Cannot add a node to a frozen collection");this.keyMap.set(t.key,t)}removeNode(t){if(this.frozen)throw new Error("Cannot remove a node to a frozen collection");this.keyMap.delete(t)}commit(t,n,r=!1){if(this.frozen)throw new Error("Cannot commit a frozen collection");this.firstKey=t,this.lastKey=n,this.frozen=!r}constructor(){this.keyMap=new Map,this.firstKey=null,this.lastKey=null,this.frozen=!1}}class Ax extends Lp{get isConnected(){return!0}createElement(t){return new pi(t,this)}getMutableNode(t){let n=t.node;return this.mutatedNodes.has(t)||(n=t.node.clone(),this.mutatedNodes.add(t),t.node=n),this.markDirty(t),n}getMutableCollection(){return!this.isSSR&&!this.collectionMutated&&(this.collection=this.collection.clone(),this.collectionMutated=!0),this.collection}markDirty(t){this.dirtyNodes.add(t)}startTransaction(){this.transactionCount++}endTransaction(){this.transactionCount--}addNode(t){let n=this.getMutableCollection();if(!n.getItem(t.node.key)){n.addNode(t.node);for(let r of t)this.addNode(r)}this.markDirty(t)}removeNode(t){for(let r of t)this.removeNode(r);this.getMutableCollection().removeNode(t.node.key),this.markDirty(t)}getCollection(){return this.transactionCount>0?this.collection:(this.updateCollection(),this.collection)}updateCollection(){for(let o of this.dirtyNodes)o instanceof pi&&o.isConnected&&o.updateNode();if(this.dirtyNodes.clear(),this.mutatedNodes.size||this.collectionMutated){var t,n;let o=this.getMutableCollection();for(let s of this.mutatedNodes)s.isConnected&&o.addNode(s.node);var r,i;o.commit((r=(t=this.firstChild)===null||t===void 0?void 0:t.node.key)!==null&&r!==void 0?r:null,(i=(n=this.lastChild)===null||n===void 0?void 0:n.node.key)!==null&&i!==void 0?i:null,this.isSSR),this.mutatedNodes.clear()}this.collectionMutated=!1}queueUpdate(){if(!(this.dirtyNodes.size===0||this.transactionCount>0))for(let t of this.subscriptions)t()}subscribe(t){return this.subscriptions.add(t),()=>this.subscriptions.delete(t)}resetAfterSSR(){this.isSSR&&(this.isSSR=!1,this.firstChild=null,this.lastChild=null,this.nodeId=0)}constructor(t){super(null),this.nodeType=11,this.ownerDocument=this,this.dirtyNodes=new Set,this.isSSR=!1,this.nodeId=0,this.nodesByProps=new WeakMap,this.mutatedNodes=new Set,this.subscriptions=new Set,this.transactionCount=0,this.collection=t,this.collectionMutated=!0}}function Rx(e){let{children:t,items:n,idScope:r,addIdAndValue:i,dependencies:o=[]}=e,s=v.useMemo(()=>new WeakMap,o);return v.useMemo(()=>{if(n&&typeof t=="function"){let u=[];for(let c of n){let f=s.get(c);if(!f){f=t(c);var l,a;let d=(a=(l=f.props.id)!==null&&l!==void 0?l:c.key)!==null&&a!==void 0?a:c.id;if(d==null)throw new Error("Could not determine key for item");r&&(d=r+":"+d),f=v.cloneElement(f,i?{key:d,id:d,value:c}:{key:d}),s.set(c,f)}u.push(f)}return u}else if(typeof t!="function")return t},[t,n,s,r,i])}function Fx(e){return Rx({...e,addIdAndValue:!0})}const Vx=v.createContext(!1);function Nx(e,t,n){let r=fi(),i=v.useRef(r);i.current=r;let o=v.useCallback(()=>i.current?n():t(),[t,n]);return Lx.useSyncExternalStore(e,o)}const Kx=typeof B.useSyncExternalStore=="function"?B.useSyncExternalStore:Nx;function Ix(e){let t=v.useMemo(()=>new Ax(e||new Dx),[e]),n=v.useCallback(s=>t.subscribe(s),[t]),r=v.useCallback(()=>{let s=t.getCollection();return t.isSSR&&t.resetAfterSSR(),s},[t]),i=v.useCallback(()=>(t.isSSR=!0,t.getCollection()),[t]);return{collection:Kx(n,r,i),document:t}}const yu=v.createContext(null),vu=v.createContext(null);function jx(e,t){let r=v.useContext(vu),i=Fx(e),o=v.useMemo(()=>B.createElement(Vx.Provider,{value:!0},i),[i]);return fi()?B.createElement(yu.Provider,{value:r},o):za.createPortal(o,r)}function Ox(e){return B.createElement(B.Fragment,null,jx(e))}function _x(e,t,n){return v.useCallback(r=>{r==null||r.setProps(e,t,n)},[e,t,n])}function zx(e,t,n,r,i){let o=_x(t,n,r),s=v.useContext(yu);if(s){let l=s.ownerDocument.nodesByProps.get(t);return l||(l=s.ownerDocument.createElement(e),l.setProps(t,n,r),s.appendChild(l),s.ownerDocument.updateCollection(),s.ownerDocument.nodesByProps.set(t,l)),i?B.createElement(yu.Provider,{value:l},i):null}return B.createElement(e,{ref:o},i)}const Dp=Symbol("default");function Bx({values:e,children:t}){for(let[n,r]of e)t=B.createElement(n.Provider,{value:r},t);return t}function is(e){let{className:t,style:n,children:r,defaultClassName:i,defaultChildren:o,defaultStyle:s,values:l}=e;return v.useMemo(()=>{let a,u,c;return typeof t=="function"?a=t({...l,defaultClassName:i}):a=t,typeof n=="function"?u=n({...l,defaultStyle:s||{}}):u=n,typeof r=="function"?c=r({...l,defaultChildren:o}):r==null?c=o:c=r,{className:a??i,style:u||s?{...s,...u}:void 0,children:c??o,"data-rac":""}},[t,n,r,i,o,s,l])}function Ap(e,t){let n=v.useContext(e);if(t===null)return null;if(n&&typeof n=="object"&&"slots"in n&&n.slots){let r=new Intl.ListFormat().format(Object.keys(n.slots).map(o=>`"${o}"`));if(!t&&!n.slots[Dp])throw new Error(`A slot prop is required. Valid slot names are ${r}.`);let i=t||Dp;if(!n.slots[i])throw new Error(`Invalid slot "${t}". Valid slot names are ${r}.`);return n.slots[i]}return n}function Ux(e,t,n){let r=Ap(n,e.slot)||{},{ref:i,...o}=r,s=Xo(v.useMemo(()=>n1(t,i),[t,i])),l=st(o,e);return"style"in o&&o.style&&"style"in e&&e.style&&(typeof o.style=="function"||typeof e.style=="function"?l.style=a=>{let u=typeof o.style=="function"?o.style(a):o.style,c={...a.defaultStyle,...u},f=typeof e.style=="function"?e.style({...a,defaultStyle:c}):e.style;return{...c,...f}}:l.style={...o.style,...e.style}),[l,s]}if(typeof HTMLTemplateElement<"u"){const e=Object.getOwnPropertyDescriptor(Node.prototype,"firstChild").get;Object.defineProperty(HTMLTemplateElement.prototype,"firstChild",{configurable:!0,enumerable:!0,get:function(){return this.dataset.reactAriaHidden?this.content.firstChild:e.call(this)}})}const xu=v.createContext(!1),Hx=typeof DocumentFragment<"u"?new DocumentFragment:null;function Wx(e){let t=v.useContext(xu),n=fi();if(t)return B.createElement(B.Fragment,null,e.children);let r=B.createElement(xu.Provider,{value:!0},e.children);return n?B.createElement("template",{"data-react-aria-hidden":!0},r):Kh.createPortal(r,Hx)}function Gx(e){let t=(n,r)=>v.useContext(xu)?null:e(n,r);return t.displayName=e.displayName||e.name,B.forwardRef(t)}class Rp{*[Symbol.iterator](){yield*this.iterable}get size(){return this.keyMap.size}getKeys(){return this.keyMap.keys()}getKeyBefore(t){let n=this.keyMap.get(t);return n?n.prevKey:null}getKeyAfter(t){let n=this.keyMap.get(t);return n?n.nextKey:null}getFirstKey(){return this.firstKey}getLastKey(){return this.lastKey}getItem(t){return this.keyMap.get(t)}at(t){const n=[...this.getKeys()];return this.getItem(n[t])}getChildren(t){let n=this.keyMap.get(t);return(n==null?void 0:n.childNodes)||[]}constructor(t){this.keyMap=new Map,this.iterable=t;let n=o=>{if(this.keyMap.set(o.key,o),o.childNodes&&o.type==="section")for(let s of o.childNodes)n(s)};for(let o of t)n(o);let r,i=0;for(let[o,s]of this.keyMap)r?(r.nextKey=o,s.prevKey=r.key):(this.firstKey=o,s.prevKey=void 0),s.type==="item"&&(s.index=i++),r=s,r.nextKey=void 0;this.lastKey=r==null?void 0:r.key}}class lt extends Set{constructor(t,n,r){super(t),t instanceof lt?(this.anchorKey=n||t.anchorKey,this.currentKey=r||t.currentKey):(this.anchorKey=n,this.currentKey=r)}}function Qx(e,t){if(e.size!==t.size)return!1;for(let n of e)if(!t.has(n))return!1;return!0}function Yx(e){let{selectionMode:t="none",disallowEmptySelection:n,allowDuplicateSelectionEvents:r,selectionBehavior:i="toggle",disabledBehavior:o="all"}=e,s=v.useRef(!1),[,l]=v.useState(!1),a=v.useRef(null),u=v.useRef(null),[,c]=v.useState(null),f=v.useMemo(()=>Fp(e.selectedKeys),[e.selectedKeys]),d=v.useMemo(()=>Fp(e.defaultSelectedKeys,new lt),[e.defaultSelectedKeys]),[h,x]=Jh(f,d,e.onSelectionChange),w=v.useMemo(()=>e.disabledKeys?new Set(e.disabledKeys):new Set,[e.disabledKeys]),[P,y]=v.useState(i);i==="replace"&&P==="toggle"&&typeof h=="object"&&h.size===0&&y("replace");let p=v.useRef(i);return v.useEffect(()=>{i!==p.current&&(y(i),p.current=i)},[i]),{selectionMode:t,disallowEmptySelection:n,selectionBehavior:P,setSelectionBehavior:y,get isFocused(){return s.current},setFocused(m){s.current=m,l(m)},get focusedKey(){return a.current},get childFocusStrategy(){return u.current},setFocusedKey(m,S="first"){a.current=m,u.current=S,c(m)},selectedKeys:h,setSelectedKeys(m){(r||!Qx(m,h))&&x(m)},disabledKeys:w,disabledBehavior:o}}function Fp(e,t){return e?e==="all"?"all":new lt(e):t}class Xx{get selectionMode(){return this.state.selectionMode}get disallowEmptySelection(){return this.state.disallowEmptySelection}get selectionBehavior(){return this.state.selectionBehavior}setSelectionBehavior(t){this.state.setSelectionBehavior(t)}get isFocused(){return this.state.isFocused}setFocused(t){this.state.setFocused(t)}get focusedKey(){return this.state.focusedKey}get childFocusStrategy(){return this.state.childFocusStrategy}setFocusedKey(t,n){(t==null||this.collection.getItem(t))&&this.state.setFocusedKey(t,n)}get selectedKeys(){return this.state.selectedKeys==="all"?new Set(this.getSelectAllKeys()):this.state.selectedKeys}get rawSelection(){return this.state.selectedKeys}isSelected(t){return this.state.selectionMode==="none"?!1:(t=this.getKey(t),this.state.selectedKeys==="all"?this.canSelectItem(t):this.state.selectedKeys.has(t))}get isEmpty(){return this.state.selectedKeys!=="all"&&this.state.selectedKeys.size===0}get isSelectAll(){if(this.isEmpty)return!1;if(this.state.selectedKeys==="all")return!0;if(this._isSelectAll!=null)return this._isSelectAll;let t=this.getSelectAllKeys(),n=this.state.selectedKeys;return this._isSelectAll=t.every(r=>n.has(r)),this._isSelectAll}get firstSelectedKey(){let t=null;for(let n of this.state.selectedKeys){let r=this.collection.getItem(n);(!t||r&&pu(this.collection,r,t)<0)&&(t=r)}return t==null?void 0:t.key}get lastSelectedKey(){let t=null;for(let n of this.state.selectedKeys){let r=this.collection.getItem(n);(!t||r&&pu(this.collection,r,t)>0)&&(t=r)}return t==null?void 0:t.key}get disabledKeys(){return this.state.disabledKeys}get disabledBehavior(){return this.state.disabledBehavior}extendSelection(t){if(this.selectionMode==="none")return;if(this.selectionMode==="single"){this.replaceSelection(t);return}t=this.getKey(t);let n;if(this.state.selectedKeys==="all")n=new lt([t],t,t);else{let r=this.state.selectedKeys,i=r.anchorKey||t;n=new lt(r,i,t);for(let o of this.getKeyRange(i,r.currentKey||t))n.delete(o);for(let o of this.getKeyRange(t,i))this.canSelectItem(o)&&n.add(o)}this.state.setSelectedKeys(n)}getKeyRange(t,n){let r=this.collection.getItem(t),i=this.collection.getItem(n);return r&&i?pu(this.collection,r,i)<=0?this.getKeyRangeInternal(t,n):this.getKeyRangeInternal(n,t):[]}getKeyRangeInternal(t,n){let r=[],i=t;for(;i;){let o=this.collection.getItem(i);if((o&&o.type==="item"||o.type==="cell"&&this.allowsCellSelection)&&r.push(i),i===n)return r;i=this.collection.getKeyAfter(i)}return[]}getKey(t){let n=this.collection.getItem(t);if(!n||n.type==="cell"&&this.allowsCellSelection)return t;for(;n.type!=="item"&&n.parentKey!=null;)n=this.collection.getItem(n.parentKey);return!n||n.type!=="item"?null:n.key}toggleSelection(t){if(this.selectionMode==="none")return;if(this.selectionMode==="single"&&!this.isSelected(t)){this.replaceSelection(t);return}if(t=this.getKey(t),t==null)return;let n=new lt(this.state.selectedKeys==="all"?this.getSelectAllKeys():this.state.selectedKeys);n.has(t)?n.delete(t):this.canSelectItem(t)&&(n.add(t),n.anchorKey=t,n.currentKey=t),!(this.disallowEmptySelection&&n.size===0)&&this.state.setSelectedKeys(n)}replaceSelection(t){if(this.selectionMode==="none"||(t=this.getKey(t),t==null))return;let n=this.canSelectItem(t)?new lt([t],t,t):new lt;this.state.setSelectedKeys(n)}setSelectedKeys(t){if(this.selectionMode==="none")return;let n=new lt;for(let r of t)if(r=this.getKey(r),r!=null&&(n.add(r),this.selectionMode==="single"))break;this.state.setSelectedKeys(n)}getSelectAllKeys(){let t=[],n=r=>{for(;r;){if(this.canSelectItem(r)){let i=this.collection.getItem(r);i.type==="item"&&t.push(r),i.hasChildNodes&&(this.allowsCellSelection||i.type!=="item")&&n(mx(px(i,this.collection)).key)}r=this.collection.getKeyAfter(r)}};return n(this.collection.getFirstKey()),t}selectAll(){!this.isSelectAll&&this.selectionMode==="multiple"&&this.state.setSelectedKeys("all")}clearSelection(){!this.disallowEmptySelection&&(this.state.selectedKeys==="all"||this.state.selectedKeys.size>0)&&this.state.setSelectedKeys(new lt)}toggleSelectAll(){this.isSelectAll?this.clearSelection():this.selectAll()}select(t,n){this.selectionMode!=="none"&&(this.selectionMode==="single"?this.isSelected(t)&&!this.disallowEmptySelection?this.toggleSelection(t):this.replaceSelection(t):this.selectionBehavior==="toggle"||n&&(n.pointerType==="touch"||n.pointerType==="virtual")?this.toggleSelection(t):this.replaceSelection(t))}isSelectionEqual(t){if(t===this.state.selectedKeys)return!0;let n=this.selectedKeys;if(t.size!==n.size)return!1;for(let r of t)if(!n.has(r))return!1;for(let r of n)if(!t.has(r))return!1;return!0}canSelectItem(t){var n;if(this.state.selectionMode==="none"||this.state.disabledKeys.has(t))return!1;let r=this.collection.getItem(t);return!(!r||!(r==null||(n=r.props)===null||n===void 0)&&n.isDisabled||r.type==="cell"&&!this.allowsCellSelection)}isDisabled(t){var n,r;return this.state.disabledBehavior==="all"&&(this.state.disabledKeys.has(t)||!!(!((r=this.collection.getItem(t))===null||r===void 0||(n=r.props)===null||n===void 0)&&n.isDisabled))}isLink(t){var n,r;return!!(!((r=this.collection.getItem(t))===null||r===void 0||(n=r.props)===null||n===void 0)&&n.href)}getItemProps(t){var n;return(n=this.collection.getItem(t))===null||n===void 0?void 0:n.props}constructor(t,n,r){this.collection=t,this.state=n;var i;this.allowsCellSelection=(i=r==null?void 0:r.allowsCellSelection)!==null&&i!==void 0?i:!1,this._isSelectAll=null}}function Zx(e){let{filter:t}=e,n=Yx(e),r=v.useMemo(()=>e.disabledKeys?new Set(e.disabledKeys):new Set,[e.disabledKeys]),i=v.useCallback(u=>t?new Rp(t(u)):new Rp(u),[t]),o=v.useMemo(()=>({suppressTextValueWarning:e.suppressTextValueWarning}),[e.suppressTextValueWarning]),s=hx(e,i,o),l=v.useMemo(()=>new Xx(s,n),[s,n]);const a=v.useRef(null);return v.useEffect(()=>{if(n.focusedKey!=null&&!s.getItem(n.focusedKey)){const u=a.current.getItem(n.focusedKey),c=[...a.current.getKeys()].map(w=>{const P=a.current.getItem(w);return P.type==="item"?P:null}).filter(w=>w!==null),f=[...s.getKeys()].map(w=>{const P=s.getItem(w);return P.type==="item"?P:null}).filter(w=>w!==null),d=c.length-f.length;let h=Math.min(d>1?Math.max(u.index-d+1,0):u.index,f.length-1),x;for(;h>=0;){if(!l.isDisabled(f[h].key)){x=f[h];break}hu.index&&(h=u.index),h--)}n.setFocusedKey(x?x.key:null)}a.current=s},[s,l,n,n.focusedKey]),{collection:s,disabledKeys:r,selectionManager:l}}function qx(e){var t;let[n,r]=Jh(e.selectedKey,(t=e.defaultSelectedKey)!==null&&t!==void 0?t:null,e.onSelectionChange),i=v.useMemo(()=>n!=null?[n]:[],[n]),{collection:o,disabledKeys:s,selectionManager:l}=Zx({...e,selectionMode:"single",disallowEmptySelection:!0,allowDuplicateSelectionEvents:!0,selectedKeys:i,onSelectionChange:u=>{var c;let f=(c=u.values().next().value)!==null&&c!==void 0?c:null;f===n&&e.onSelectionChange&&e.onSelectionChange(f),r(f)}}),a=n!=null?o.getItem(n):null;return{collection:o,disabledKeys:s,selectionManager:l,selectedKey:n,setSelectedKey:r,selectedItem:a}}function Jx(e){var t;let n=qx({...e,suppressTextValueWarning:!0,defaultSelectedKey:(t=e.defaultSelectedKey)!==null&&t!==void 0?t:Vp(e.collection,e.disabledKeys?new Set(e.disabledKeys):new Set)}),{selectionManager:r,collection:i,selectedKey:o}=n,s=v.useRef(o);return v.useEffect(()=>{let l=o;(r.isEmpty||!i.getItem(l))&&(l=Vp(i,n.disabledKeys),l!=null&&r.setSelectedKeys([l])),(l!=null&&r.focusedKey==null||!r.isFocused&&l!==s.current)&&r.setFocusedKey(l),s.current=l}),{...n,isDisabled:e.isDisabled||!1}}function Vp(e,t){let n=null;if(e){for(n=e.getFirstKey();t.has(n)&&n!==e.getLastKey();)n=e.getKeyAfter(n);t.has(n)&&n===e.getLastKey()&&(n=e.getFirstKey())}return n}const wu=v.createContext(null),Su=v.createContext(null);function ew(e,t){[e,t]=Ux(e,t,wu);let{collection:n,document:r}=Ix(),{children:i,orientation:o="horizontal"}=e;return i=v.useMemo(()=>typeof i=="function"?i({orientation:o,defaultChildren:null}):i,[i,o]),B.createElement(B.Fragment,null,B.createElement(Wx,null,B.createElement(vu.Provider,{value:r},i)),B.createElement(tw,{props:e,collection:n,tabsRef:t}))}function tw({props:e,tabsRef:t,collection:n}){let{orientation:r="horizontal"}=e,i=Jx({...e,collection:n,children:void 0}),{focusProps:o,isFocused:s,isFocusVisible:l}=cu({within:!0}),a=v.useMemo(()=>({orientation:r,isFocusWithin:s,isFocusVisible:l}),[r,s,l]),u=is({...e,defaultClassName:"react-aria-Tabs",values:a});return B.createElement("div",{...Go(e),...o,...u,ref:t,slot:e.slot||void 0,"data-focused":s||void 0,"data-orientation":r,"data-focus-visible":l||void 0,"data-disabled":i.isDisabled||void 0},B.createElement(Bx,{values:[[wu,e],[Su,i]]},u.children))}const nw=v.forwardRef(ew);function rw(e,t){return v.useContext(vu)?B.createElement(Ox,e):B.createElement(iw,{props:e,forwardedRef:t})}function iw({props:e,forwardedRef:t}){let n=v.useContext(Su),{orientation:r="horizontal",keyboardActivation:i="automatic"}=Ap(wu),o=Xo(t),{tabListProps:s}=wx({...e,orientation:r,keyboardActivation:i},n,o),l=is({...e,children:null,defaultClassName:"react-aria-TabList",values:{orientation:r,state:n}}),a=Go(e);return delete a.id,B.createElement("div",{...a,...s,ref:o,...l,"data-orientation":r||void 0},[...n.collection].map(u=>B.createElement(lw,{key:u.key,item:u,state:n})))}const ow=v.forwardRef(rw);function sw(e,t){return zx("item",e,t,e.children)}const Np=v.forwardRef(sw);function lw({item:e,state:t}){let n=Xo(e.props.ref),{tabProps:r,isSelected:i,isDisabled:o,isPressed:s}=yx({key:e.key,...e.props},t,n),{focusProps:l,isFocused:a,isFocusVisible:u}=cu(),{hoverProps:c,isHovered:f}=W1({isDisabled:o}),d=is({...e.props,children:e.rendered,defaultClassName:"react-aria-Tab",values:{isSelected:i,isDisabled:o,isFocused:a,isFocusVisible:u,isPressed:s,isHovered:f,state:t}}),h=e.props.href?"a":"div";return B.createElement(h,{...st(r,l,c,d),ref:n,"data-selected":i||void 0,"data-disabled":o||void 0,"data-focused":a||void 0,"data-focus-visible":u||void 0,"data-pressed":s||void 0,"data-hovered":f||void 0})}function aw(e,t){const n=v.useContext(Su);let r=Xo(t),{tabPanelProps:i}=vx(e,n,r),{focusProps:o,isFocused:s,isFocusVisible:l}=cu(),a=n.selectedKey===e.id,u=is({...e,defaultClassName:"react-aria-TabPanel",values:{isFocused:s,isFocusVisible:l,isInert:!a,state:n}});if(!a&&!e.shouldForceMount)return null;let c=Go(e);delete c.id;let f=a?st(c,i,o,u):u;return B.createElement("div",{...f,ref:r,"data-focused":s||void 0,"data-focus-visible":l||void 0,inert:a?void 0:"true","data-inert":a?void 0:"true"})}const uw=Gx(aw),cw=({title:e,slideData:t,count:n,setCount:r,handleNext:i,handlePrevious:o,theme:s})=>{const[l,a]=v.useState(0),[u,c]=v.useState(!1),[f,d]=v.useState(!0);return v.useEffect(()=>{if(!f){const h=setInterval(()=>{l<100?a(x=>x+1):l>100&&n100&&n===t.length?(c(!u),a(0),clearInterval(h)):a(x=>x+1)},100);return u&&clearInterval(h),()=>{clearInterval(h)}}},[i,n,t.length,r,l,u,f]),A.jsxs("nav",{className:"visible flex w-full flex-col justify-between max-lg:hidden lg:basis-3/12",children:[A.jsxs(ow,{"aria-label":e,className:`flex justify-stretch gap-0 sm:mx-0 lg:flex-col xl:gap-0 ${s==="dark"&&""}`,children:[s==="light"&&(t==null?void 0:t.map((h,x)=>A.jsxs(Np,{id:`tab-${h.id}-${h.position}`,className:`relative box-border flex w-full cursor-pointer flex-col gap-1 overflow-hidden py-[1.3rem] font-display text-sm font-semibold text-sfnavy transition-all hover:text-sfprimary hover:underline hover:underline-offset-2 sm:gap-3 lg:flex-row lg:items-center lg:align-middle lg:text-base ${h.position===n?"rounded-md bg-white text-sfprimary shadow-nav transition-transform hover:no-underline":""}`,children:[h.position===n?A.jsx("div",{className:`countdown-display absolute top-0 h-[4px] bg-sfprimary transition-all ${f&&"w-100"}`,style:f?{width:"100%"}:{width:l*1e3/1e3+"%"}&&n===t.length&&u?{width:"100%"}:{width:l*1e3/1e3+"%"}}):A.jsx("div",{className:"countdown-display absolute top-0 h-[2px] bg-transparent"}),A.jsx("span",{className:"visible px-3 text-left text-xs leading-tight max-sm:hidden xl:text-base xl:leading-normal",children:h.title})]},h.id))),s==="dark"&&(t==null?void 0:t.map((h,x)=>A.jsxs(Np,{id:`tab-${h.id}-${h.position}`,className:`relative box-border flex w-full cursor-pointer flex-col gap-1 overflow-hidden py-[1.3rem] font-display text-sm font-semibold text-white transition-all hover:rounded-md ${h.position===n?"gt-tablist-dark rounded-md bg-[#0000005d] text-white bg-blend-luminosity transition-transform hover:no-underline":" hover:bg-white/10 hover:underline hover:underline-offset-2 sm:gap-3 lg:flex-row lg:items-center lg:align-middle lg:text-base"}`,children:[h.position===n?A.jsx("div",{className:`countdown-display absolute top-0 h-[4px] bg-sfaccentdata transition-all ${f&&"w-100"}`,style:f?{width:"100%",background:"#04E1CB"}:{width:l*1e3/1e3+"%"}&&n===t.length&&u?{width:"100%"}:{width:l*1e3/1e3+"%"}}):A.jsx("div",{className:"countdown-display absolute top-0 h-[2px] bg-transparent"}),A.jsx("span",{className:"visible px-3 text-left text-xs leading-tight text-white max-sm:hidden xl:text-base xl:leading-normal",children:h.title})]},h.id)))]}),A.jsxs("div",{className:`visible flex flex-row items-center gap-3 border-t pt-4 text-center align-middle text-sm max-lg:hidden ${s==="dark"&&"border-t border-[#73A3C7]"}`,children:[A.jsx("button",{className:"flex h-10 w-10 flex-shrink items-center justify-center rounded-full bg-white text-sfnavy ring-2 ring-sfprimary transition-transform enabled:hover:bg-sfprimary enabled:hover:text-white disabled:cursor-not-allowed disabled:bg-[#c9c9c9] disabled:text-white disabled:opacity-60 disabled:ring-0 disabled:hover:bg-[#c9c9c9]",onClick:()=>{o(),u?c(!1):a(0)},disabled:!(n>1),"aria-label":"Previous Slide",tabIndex:-1,children:A.jsx(Ih,{width:22,height:22})}),A.jsx("button",{className:"flex h-10 w-10 flex-shrink items-center justify-center rounded-full bg-white text-sfnavy ring-2 ring-sfprimary transition-transform enabled:hover:bg-sfprimary enabled:hover:text-white disabled:cursor-not-allowed disabled:bg-[#c9c9c9] disabled:text-white disabled:opacity-60 disabled:ring-0 disabled:hover:bg-[#c9c9c9]",onClick:()=>{i(),u?c(!1):a(0)},disabled:!(n{c(h=>!h)},"aria-label":u?"Start autoplay":"Pause autoplay",tabIndex:-1,children:u?A.jsx(B0,{width:18,height:18}):A.jsx(_0,{width:18,height:18})})})]})]})},Kp=v.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),os=v.createContext({}),ss=v.createContext(null),ls=typeof document<"u",Pu=ls?v.useLayoutEffect:v.useEffect,Ip=v.createContext({strict:!1}),Cu=e=>e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),jp="data-"+Cu("framerAppearId");function fw(e,t,n,r){const{visualElement:i}=v.useContext(os),o=v.useContext(Ip),s=v.useContext(ss),l=v.useContext(Kp).reducedMotion,a=v.useRef();r=r||o.renderer,!a.current&&r&&(a.current=r(e,{visualState:t,parent:i,props:n,presenceContext:s,blockInitialAnimation:s?s.initial===!1:!1,reducedMotionConfig:l}));const u=a.current;v.useInsertionEffect(()=>{u&&u.update(n,s)});const c=v.useRef(!!(n[jp]&&!window.HandoffComplete));return Pu(()=>{u&&(u.render(),c.current&&u.animationState&&u.animationState.animateChanges())}),v.useEffect(()=>{u&&(u.updateFeatures(),!c.current&&u.animationState&&u.animationState.animateChanges(),c.current&&(c.current=!1,window.HandoffComplete=!0))}),u}function pr(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function dw(e,t,n){return v.useCallback(r=>{r&&e.mount&&e.mount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):pr(n)&&(n.current=r))},[t])}function mi(e){return typeof e=="string"||Array.isArray(e)}function as(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}const Tu=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],$u=["initial",...Tu];function us(e){return as(e.animate)||$u.some(t=>mi(e[t]))}function Op(e){return!!(us(e)||e.variants)}function hw(e,t){if(us(e)){const{initial:n,animate:r}=e;return{initial:n===!1||mi(n)?n:void 0,animate:mi(r)?r:void 0}}return e.inherit!==!1?t:{}}function pw(e){const{initial:t,animate:n}=hw(e,v.useContext(os));return v.useMemo(()=>({initial:t,animate:n}),[_p(t),_p(n)])}function _p(e){return Array.isArray(e)?e.join(" "):e}const zp={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},gi={};for(const e in zp)gi[e]={isEnabled:t=>zp[e].some(n=>!!t[n])};function mw(e){for(const t in e)gi[t]={...gi[t],...e[t]}}const ku=v.createContext({}),Bp=v.createContext({}),gw=Symbol.for("motionComponentSymbol");function yw({preloadedFeatures:e,createVisualElement:t,useRender:n,useVisualState:r,Component:i}){e&&mw(e);function o(l,a){let u;const c={...v.useContext(Kp),...l,layoutId:vw(l)},{isStatic:f}=c,d=pw(l),h=r(l,f);if(!f&&ls){d.visualElement=fw(i,h,c,t);const x=v.useContext(Bp),w=v.useContext(Ip).strict;d.visualElement&&(u=d.visualElement.loadFeatures(c,w,e,x))}return v.createElement(os.Provider,{value:d},u&&d.visualElement?v.createElement(u,{visualElement:d.visualElement,...c}):null,n(i,l,dw(h,d.visualElement,a),h,f,d.visualElement))}const s=v.forwardRef(o);return s[gw]=i,s}function vw({layoutId:e}){const t=v.useContext(ku).id;return t&&e!==void 0?t+"-"+e:e}function xw(e){function t(r,i={}){return yw(e(r,i))}if(typeof Proxy>"u")return t;const n=new Map;return new Proxy(t,{get:(r,i)=>(n.has(i)||n.set(i,t(i)),n.get(i))})}const ww=["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 Eu(e){return typeof e!="string"||e.includes("-")?!1:!!(ww.indexOf(e)>-1||/[A-Z]/.test(e))}const cs={};function Sw(e){Object.assign(cs,e)}const yi=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Pn=new Set(yi);function Up(e,{layout:t,layoutId:n}){return Pn.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!cs[e]||e==="opacity")}const Fe=e=>!!(e&&e.getVelocity),Pw={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Cw=yi.length;function Tw(e,{enableHardwareAcceleration:t=!0,allowTransformNone:n=!0},r,i){let o="";for(let s=0;st=>typeof t=="string"&&t.startsWith(e),Wp=Hp("--"),bu=Hp("var(--"),$w=/var\s*\(\s*--[\w-]+(\s*,\s*(?:(?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)+)?\s*\)/g,kw=(e,t)=>t&&typeof e=="number"?t.transform(e):e,Xt=(e,t,n)=>Math.min(Math.max(n,e),t),Cn={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},vi={...Cn,transform:e=>Xt(0,1,e)},fs={...Cn,default:1},xi=e=>Math.round(e*1e5)/1e5,ds=/(-)?([\d]*\.?[\d])+/g,Gp=/(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi,Ew=/^(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;function wi(e){return typeof e=="string"}const Si=e=>({test:t=>wi(t)&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Zt=Si("deg"),ht=Si("%"),O=Si("px"),bw=Si("vh"),Mw=Si("vw"),Qp={...ht,parse:e=>ht.parse(e)/100,transform:e=>ht.transform(e*100)},Yp={...Cn,transform:Math.round},Xp={borderWidth:O,borderTopWidth:O,borderRightWidth:O,borderBottomWidth:O,borderLeftWidth:O,borderRadius:O,radius:O,borderTopLeftRadius:O,borderTopRightRadius:O,borderBottomRightRadius:O,borderBottomLeftRadius:O,width:O,maxWidth:O,height:O,maxHeight:O,size:O,top:O,right:O,bottom:O,left:O,padding:O,paddingTop:O,paddingRight:O,paddingBottom:O,paddingLeft:O,margin:O,marginTop:O,marginRight:O,marginBottom:O,marginLeft:O,rotate:Zt,rotateX:Zt,rotateY:Zt,rotateZ:Zt,scale:fs,scaleX:fs,scaleY:fs,scaleZ:fs,skew:Zt,skewX:Zt,skewY:Zt,distance:O,translateX:O,translateY:O,translateZ:O,x:O,y:O,z:O,perspective:O,transformPerspective:O,opacity:vi,originX:Qp,originY:Qp,originZ:O,zIndex:Yp,fillOpacity:vi,strokeOpacity:vi,numOctaves:Yp};function Mu(e,t,n,r){const{style:i,vars:o,transform:s,transformOrigin:l}=e;let a=!1,u=!1,c=!0;for(const f in t){const d=t[f];if(Wp(f)){o[f]=d;continue}const h=Xp[f],x=kw(d,h);if(Pn.has(f)){if(a=!0,s[f]=x,!c)continue;d!==(h.default||0)&&(c=!1)}else f.startsWith("origin")?(u=!0,l[f]=x):i[f]=x}if(t.transform||(a||r?i.transform=Tw(e.transform,n,c,r):i.transform&&(i.transform="none")),u){const{originX:f="50%",originY:d="50%",originZ:h=0}=l;i.transformOrigin=`${f} ${d} ${h}`}}const Lu=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Zp(e,t,n){for(const r in t)!Fe(t[r])&&!Up(r,n)&&(e[r]=t[r])}function Lw({transformTemplate:e},t,n){return v.useMemo(()=>{const r=Lu();return Mu(r,t,{enableHardwareAcceleration:!n},e),Object.assign({},r.vars,r.style)},[t])}function Dw(e,t,n){const r=e.style||{},i={};return Zp(i,r,e),Object.assign(i,Lw(e,t,n)),e.transformValues?e.transformValues(i):i}function Aw(e,t,n){const r={},i=Dw(e,t,n);return e.drag&&e.dragListener!==!1&&(r.draggable=!1,i.userSelect=i.WebkitUserSelect=i.WebkitTouchCallout="none",i.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(r.tabIndex=0),r.style=i,r}const Rw=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","transformValues","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function hs(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||Rw.has(e)}let qp=e=>!hs(e);function Fw(e){e&&(qp=t=>t.startsWith("on")?!hs(t):e(t))}try{Fw(require("@emotion/is-prop-valid").default)}catch{}function Vw(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||(qp(i)||n===!0&&hs(i)||!t&&!hs(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}function Jp(e,t,n){return typeof e=="string"?e:O.transform(t+n*e)}function Nw(e,t,n){const r=Jp(t,e.x,e.width),i=Jp(n,e.y,e.height);return`${r} ${i}`}const Kw={offset:"stroke-dashoffset",array:"stroke-dasharray"},Iw={offset:"strokeDashoffset",array:"strokeDasharray"};function jw(e,t,n=1,r=0,i=!0){e.pathLength=1;const o=i?Kw:Iw;e[o.offset]=O.transform(-r);const s=O.transform(t),l=O.transform(n);e[o.array]=`${s} ${l}`}function Du(e,{attrX:t,attrY:n,attrScale:r,originX:i,originY:o,pathLength:s,pathSpacing:l=1,pathOffset:a=0,...u},c,f,d){if(Mu(e,u,c,d),f){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:h,style:x,dimensions:w}=e;h.transform&&(w&&(x.transform=h.transform),delete h.transform),w&&(i!==void 0||o!==void 0||x.transform)&&(x.transformOrigin=Nw(w,i!==void 0?i:.5,o!==void 0?o:.5)),t!==void 0&&(h.x=t),n!==void 0&&(h.y=n),r!==void 0&&(h.scale=r),s!==void 0&&jw(h,s,l,a,!1)}const em=()=>({...Lu(),attrs:{}}),Au=e=>typeof e=="string"&&e.toLowerCase()==="svg";function Ow(e,t,n,r){const i=v.useMemo(()=>{const o=em();return Du(o,t,{enableHardwareAcceleration:!1},Au(r),e.transformTemplate),{...o.attrs,style:{...o.style}}},[t]);if(e.style){const o={};Zp(o,e.style,e),i.style={...o,...i.style}}return i}function _w(e=!1){return(n,r,i,{latestValues:o},s)=>{const a=(Eu(n)?Ow:Aw)(r,o,s,n),c={...Vw(r,typeof n=="string",e),...a,ref:i},{children:f}=r,d=v.useMemo(()=>Fe(f)?f.get():f,[f]);return v.createElement(n,{...c,children:d})}}function tm(e,{style:t,vars:n},r,i){Object.assign(e.style,t,i&&i.getProjectionStyles(r));for(const o in n)e.style.setProperty(o,n[o])}const nm=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 rm(e,t,n,r){tm(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(nm.has(i)?i:Cu(i),t.attrs[i])}function Ru(e,t){const{style:n}=e,r={};for(const i in n)(Fe(n[i])||t.style&&Fe(t.style[i])||Up(i,e))&&(r[i]=n[i]);return r}function im(e,t){const n=Ru(e,t);for(const r in e)if(Fe(e[r])||Fe(t[r])){const i=yi.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;n[i]=e[r]}return n}function Fu(e,t,n,r={},i={}){return typeof t=="function"&&(t=t(n!==void 0?n:e.custom,r,i)),typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"&&(t=t(n!==void 0?n:e.custom,r,i)),t}function om(e){const t=v.useRef(null);return t.current===null&&(t.current=e()),t.current}const ps=e=>Array.isArray(e),zw=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),Bw=e=>ps(e)?e[e.length-1]||0:e;function ms(e){const t=Fe(e)?e.get():e;return zw(t)?t.toValue():t}function Uw({scrapeMotionValuesFromProps:e,createRenderState:t,onMount:n},r,i,o){const s={latestValues:Hw(r,i,o,e),renderState:t()};return n&&(s.mount=l=>n(r,l,s)),s}const sm=e=>(t,n)=>{const r=v.useContext(os),i=v.useContext(ss),o=()=>Uw(e,t,r,i);return n?o():om(o)};function Hw(e,t,n,r){const i={},o=r(e,{});for(const d in o)i[d]=ms(o[d]);let{initial:s,animate:l}=e;const a=us(e),u=Op(e);t&&u&&!a&&e.inherit!==!1&&(s===void 0&&(s=t.initial),l===void 0&&(l=t.animate));let c=n?n.initial===!1:!1;c=c||s===!1;const f=c?l:s;return f&&typeof f!="boolean"&&!as(f)&&(Array.isArray(f)?f:[f]).forEach(h=>{const x=Fu(e,h);if(!x)return;const{transitionEnd:w,transition:P,...y}=x;for(const p in y){let m=y[p];if(Array.isArray(m)){const S=c?m.length-1:0;m=m[S]}m!==null&&(i[p]=m)}for(const p in w)i[p]=w[p]}),i}const se=e=>e;class lm{constructor(){this.order=[],this.scheduled=new Set}add(t){if(!this.scheduled.has(t))return this.scheduled.add(t),this.order.push(t),!0}remove(t){const n=this.order.indexOf(t);n!==-1&&(this.order.splice(n,1),this.scheduled.delete(t))}clear(){this.order.length=0,this.scheduled.clear()}}function Ww(e){let t=new lm,n=new lm,r=0,i=!1,o=!1;const s=new WeakSet,l={schedule:(a,u=!1,c=!1)=>{const f=c&&i,d=f?t:n;return u&&s.add(a),d.add(a)&&f&&i&&(r=t.order.length),a},cancel:a=>{n.remove(a),s.delete(a)},process:a=>{if(i){o=!0;return}if(i=!0,[t,n]=[n,t],n.clear(),r=t.order.length,r)for(let u=0;u(f[d]=Ww(()=>n=!0),f),{}),s=f=>o[f].process(i),l=()=>{const f=performance.now();n=!1,i.delta=r?1e3/60:Math.max(Math.min(f-i.timestamp,Gw),1),i.timestamp=f,i.isProcessing=!0,gs.forEach(s),i.isProcessing=!1,n&&t&&(r=!1,e(l))},a=()=>{n=!0,r=!0,i.isProcessing||e(l)};return{schedule:gs.reduce((f,d)=>{const h=o[d];return f[d]=(x,w=!1,P=!1)=>(n||a(),h.schedule(x,w,P)),f},{}),cancel:f=>gs.forEach(d=>o[d].cancel(f)),state:i,steps:o}}const{schedule:Y,cancel:kt,state:Pe,steps:Vu}=Qw(typeof requestAnimationFrame<"u"?requestAnimationFrame:se,!0),Yw={useVisualState:sm({scrapeMotionValuesFromProps:im,createRenderState:em,onMount:(e,t,{renderState:n,latestValues:r})=>{Y.read(()=>{try{n.dimensions=typeof t.getBBox=="function"?t.getBBox():t.getBoundingClientRect()}catch{n.dimensions={x:0,y:0,width:0,height:0}}}),Y.render(()=>{Du(n,r,{enableHardwareAcceleration:!1},Au(t.tagName),e.transformTemplate),rm(t,n)})}})},Xw={useVisualState:sm({scrapeMotionValuesFromProps:Ru,createRenderState:Lu})};function Zw(e,{forwardMotionProps:t=!1},n,r){return{...Eu(e)?Yw:Xw,preloadedFeatures:n,useRender:_w(t),createVisualElement:r,Component:e}}function Et(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}const am=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;function ys(e,t="page"){return{point:{x:e[t+"X"],y:e[t+"Y"]}}}const qw=e=>t=>am(t)&&e(t,ys(t));function bt(e,t,n,r){return Et(e,t,qw(n),r)}const Jw=(e,t)=>n=>t(e(n)),qt=(...e)=>e.reduce(Jw);function um(e){let t=null;return()=>{const n=()=>{t=null};return t===null?(t=e,n):!1}}const cm=um("dragHorizontal"),fm=um("dragVertical");function dm(e){let t=!1;if(e==="y")t=fm();else if(e==="x")t=cm();else{const n=cm(),r=fm();n&&r?t=()=>{n(),r()}:(n&&n(),r&&r())}return t}function hm(){const e=dm(!0);return e?(e(),!1):!0}class Jt{constructor(t){this.isMounted=!1,this.node=t}update(){}}function pm(e,t){const n="pointer"+(t?"enter":"leave"),r="onHover"+(t?"Start":"End"),i=(o,s)=>{if(o.pointerType==="touch"||hm())return;const l=e.getProps();e.animationState&&l.whileHover&&e.animationState.setActive("whileHover",t),l[r]&&Y.update(()=>l[r](o,s))};return bt(e.current,n,i,{passive:!e.getProps()[r]})}class eS extends Jt{mount(){this.unmount=qt(pm(this.node,!0),pm(this.node,!1))}unmount(){}}class tS extends Jt{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=qt(Et(this.node.current,"focus",()=>this.onFocus()),Et(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}const mm=(e,t)=>t?e===t?!0:mm(e,t.parentElement):!1;function Nu(e,t){if(!t)return;const n=new PointerEvent("pointer"+e);t(n,ys(n))}class nS extends Jt{constructor(){super(...arguments),this.removeStartListeners=se,this.removeEndListeners=se,this.removeAccessibleListeners=se,this.startPointerPress=(t,n)=>{if(this.isPressing)return;this.removeEndListeners();const r=this.node.getProps(),o=bt(window,"pointerup",(l,a)=>{if(!this.checkPressEnd())return;const{onTap:u,onTapCancel:c,globalTapTarget:f}=this.node.getProps();Y.update(()=>{!f&&!mm(this.node.current,l.target)?c&&c(l,a):u&&u(l,a)})},{passive:!(r.onTap||r.onPointerUp)}),s=bt(window,"pointercancel",(l,a)=>this.cancelPress(l,a),{passive:!(r.onTapCancel||r.onPointerCancel)});this.removeEndListeners=qt(o,s),this.startPress(t,n)},this.startAccessiblePress=()=>{const t=o=>{if(o.key!=="Enter"||this.isPressing)return;const s=l=>{l.key!=="Enter"||!this.checkPressEnd()||Nu("up",(a,u)=>{const{onTap:c}=this.node.getProps();c&&Y.update(()=>c(a,u))})};this.removeEndListeners(),this.removeEndListeners=Et(this.node.current,"keyup",s),Nu("down",(l,a)=>{this.startPress(l,a)})},n=Et(this.node.current,"keydown",t),r=()=>{this.isPressing&&Nu("cancel",(o,s)=>this.cancelPress(o,s))},i=Et(this.node.current,"blur",r);this.removeAccessibleListeners=qt(n,i)}}startPress(t,n){this.isPressing=!0;const{onTapStart:r,whileTap:i}=this.node.getProps();i&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),r&&Y.update(()=>r(t,n))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!hm()}cancelPress(t,n){if(!this.checkPressEnd())return;const{onTapCancel:r}=this.node.getProps();r&&Y.update(()=>r(t,n))}mount(){const t=this.node.getProps(),n=bt(t.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),r=Et(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=qt(n,r)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}const Ku=new WeakMap,Iu=new WeakMap,rS=e=>{const t=Ku.get(e.target);t&&t(e)},iS=e=>{e.forEach(rS)};function oS({root:e,...t}){const n=e||document;Iu.has(n)||Iu.set(n,{});const r=Iu.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(iS,{root:e,...t})),r[i]}function sS(e,t,n){const r=oS(t);return Ku.set(e,n),r.observe(e),()=>{Ku.delete(e),r.unobserve(e)}}const lS={some:0,all:1};class aS extends Jt{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:o}=t,s={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:lS[i]},l=a=>{const{isIntersecting:u}=a;if(this.isInView===u||(this.isInView=u,o&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:c,onViewportLeave:f}=this.node.getProps(),d=u?c:f;d&&d(a)};return sS(this.node.current,s,l)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(uS(t,n))&&this.startObserver()}unmount(){}}function uS({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const cS={inView:{Feature:aS},tap:{Feature:nS},focus:{Feature:tS},hover:{Feature:eS}};function gm(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;rt[r]=n.get()),t}function dS(e){const t={};return e.values.forEach((n,r)=>t[r]=n.getVelocity()),t}function vs(e,t,n){const r=e.getProps();return Fu(r,t,n!==void 0?n:r.custom,fS(e),dS(e))}let xs=se;const Tn=e=>e*1e3,Mt=e=>e/1e3,hS={current:!1},ym=e=>Array.isArray(e)&&typeof e[0]=="number";function vm(e){return!!(!e||typeof e=="string"&&xm[e]||ym(e)||Array.isArray(e)&&e.every(vm))}const Pi=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,xm={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Pi([0,.65,.55,1]),circOut:Pi([.55,0,1,.45]),backIn:Pi([.31,.01,.66,-.59]),backOut:Pi([.33,1.53,.69,.99])};function wm(e){if(e)return ym(e)?Pi(e):Array.isArray(e)?e.map(wm):xm[e]}function pS(e,t,n,{delay:r=0,duration:i,repeat:o=0,repeatType:s="loop",ease:l,times:a}={}){const u={[t]:n};a&&(u.offset=a);const c=wm(l);return Array.isArray(c)&&(u.easing=c),e.animate(u,{delay:r,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:o+1,direction:s==="reverse"?"alternate":"normal"})}function mS(e,{repeat:t,repeatType:n="loop"}){const r=t&&n!=="loop"&&t%2===1?0:e.length-1;return e[r]}const Sm=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,gS=1e-7,yS=12;function vS(e,t,n,r,i){let o,s,l=0;do s=t+(n-t)/2,o=Sm(s,r,i)-e,o>0?n=s:t=s;while(Math.abs(o)>gS&&++lvS(o,0,1,e,n);return o=>o===0||o===1?o:Sm(i(o),t,r)}const xS=Ci(.42,0,1,1),wS=Ci(0,0,.58,1),Pm=Ci(.42,0,.58,1),SS=e=>Array.isArray(e)&&typeof e[0]!="number",Cm=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,Tm=e=>t=>1-e(1-t),ju=e=>1-Math.sin(Math.acos(e)),$m=Tm(ju),PS=Cm(ju),km=Ci(.33,1.53,.69,.99),Ou=Tm(km),CS=Cm(Ou),Em={linear:se,easeIn:xS,easeInOut:Pm,easeOut:wS,circIn:ju,circInOut:PS,circOut:$m,backIn:Ou,backInOut:CS,backOut:km,anticipate:e=>(e*=2)<1?.5*Ou(e):.5*(2-Math.pow(2,-10*(e-1)))},bm=e=>{if(Array.isArray(e)){xs(e.length===4);const[t,n,r,i]=e;return Ci(t,n,r,i)}else if(typeof e=="string")return xs(Em[e]!==void 0),Em[e];return e},_u=(e,t)=>n=>!!(wi(n)&&Ew.test(n)&&n.startsWith(e)||t&&Object.prototype.hasOwnProperty.call(n,t)),Mm=(e,t,n)=>r=>{if(!wi(r))return r;const[i,o,s,l]=r.match(ds);return{[e]:parseFloat(i),[t]:parseFloat(o),[n]:parseFloat(s),alpha:l!==void 0?parseFloat(l):1}},TS=e=>Xt(0,255,e),zu={...Cn,transform:e=>Math.round(TS(e))},$n={test:_u("rgb","red"),parse:Mm("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+zu.transform(e)+", "+zu.transform(t)+", "+zu.transform(n)+", "+xi(vi.transform(r))+")"};function $S(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const Bu={test:_u("#"),parse:$S,transform:$n.transform},mr={test:_u("hsl","hue"),parse:Mm("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+ht.transform(xi(t))+", "+ht.transform(xi(n))+", "+xi(vi.transform(r))+")"},Ee={test:e=>$n.test(e)||Bu.test(e)||mr.test(e),parse:e=>$n.test(e)?$n.parse(e):mr.test(e)?mr.parse(e):Bu.parse(e),transform:e=>wi(e)?e:e.hasOwnProperty("red")?$n.transform(e):mr.transform(e)},ne=(e,t,n)=>-n*e+n*t+e;function Uu(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 kS({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,o=0,s=0;if(!t)i=o=s=n;else{const l=n<.5?n*(1+t):n+t-n*t,a=2*n-l;i=Uu(a,l,e+1/3),o=Uu(a,l,e),s=Uu(a,l,e-1/3)}return{red:Math.round(i*255),green:Math.round(o*255),blue:Math.round(s*255),alpha:r}}const Hu=(e,t,n)=>{const r=e*e;return Math.sqrt(Math.max(0,n*(t*t-r)+r))},ES=[Bu,$n,mr],bS=e=>ES.find(t=>t.test(e));function Lm(e){const t=bS(e);let n=t.parse(e);return t===mr&&(n=kS(n)),n}const Dm=(e,t)=>{const n=Lm(e),r=Lm(t),i={...n};return o=>(i.red=Hu(n.red,r.red,o),i.green=Hu(n.green,r.green,o),i.blue=Hu(n.blue,r.blue,o),i.alpha=ne(n.alpha,r.alpha,o),$n.transform(i))};function MS(e){var t,n;return isNaN(e)&&wi(e)&&(((t=e.match(ds))===null||t===void 0?void 0:t.length)||0)+(((n=e.match(Gp))===null||n===void 0?void 0:n.length)||0)>0}const Am={regex:$w,countKey:"Vars",token:"${v}",parse:se},Rm={regex:Gp,countKey:"Colors",token:"${c}",parse:Ee.parse},Fm={regex:ds,countKey:"Numbers",token:"${n}",parse:Cn.parse};function Wu(e,{regex:t,countKey:n,token:r,parse:i}){const o=e.tokenised.match(t);o&&(e["num"+n]=o.length,e.tokenised=e.tokenised.replace(t,r),e.values.push(...o.map(i)))}function ws(e){const t=e.toString(),n={value:t,tokenised:t,values:[],numVars:0,numColors:0,numNumbers:0};return n.value.includes("var(--")&&Wu(n,Am),Wu(n,Rm),Wu(n,Fm),n}function Vm(e){return ws(e).values}function Nm(e){const{values:t,numColors:n,numVars:r,tokenised:i}=ws(e),o=t.length;return s=>{let l=i;for(let a=0;atypeof e=="number"?0:e;function DS(e){const t=Vm(e);return Nm(e)(t.map(LS))}const en={test:MS,parse:Vm,createTransformer:Nm,getAnimatableNone:DS},Km=(e,t)=>n=>`${n>0?t:e}`;function Im(e,t){return typeof e=="number"?n=>ne(e,t,n):Ee.test(e)?Dm(e,t):e.startsWith("var(")?Km(e,t):Om(e,t)}const jm=(e,t)=>{const n=[...e],r=n.length,i=e.map((o,s)=>Im(o,t[s]));return o=>{for(let s=0;s{const n={...e,...t},r={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=Im(e[i],t[i]));return i=>{for(const o in r)n[o]=r[o](i);return n}},Om=(e,t)=>{const n=en.createTransformer(t),r=ws(e),i=ws(t);return r.numVars===i.numVars&&r.numColors===i.numColors&&r.numNumbers>=i.numNumbers?qt(jm(r.values,i.values),n):Km(e,t)},Ti=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r},_m=(e,t)=>n=>ne(e,t,n);function RS(e){return typeof e=="number"?_m:typeof e=="string"?Ee.test(e)?Dm:Om:Array.isArray(e)?jm:typeof e=="object"?AS:_m}function FS(e,t,n){const r=[],i=n||RS(e[0]),o=e.length-1;for(let s=0;st[0];e[0]>e[o-1]&&(e=[...e].reverse(),t=[...t].reverse());const s=FS(t,r,i),l=s.length,a=u=>{let c=0;if(l>1)for(;ca(Xt(e[0],e[o-1],u)):a}function VS(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=Ti(0,t,r);e.push(ne(n,1,i))}}function NS(e){const t=[0];return VS(t,e.length-1),t}function KS(e,t){return e.map(n=>n*t)}function IS(e,t){return e.map(()=>t||Pm).splice(0,e.length-1)}function Ss({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=SS(r)?r.map(bm):bm(r),o={done:!1,value:t[0]},s=KS(n&&n.length===t.length?n:NS(t),e),l=zm(s,t,{ease:Array.isArray(i)?i:IS(t,i)});return{calculatedDuration:e,next:a=>(o.value=l(a),o.done=a>=e,o)}}function Bm(e,t){return t?e*(1e3/t):0}const jS=5;function Um(e,t,n){const r=Math.max(t-jS,0);return Bm(n-e(r),t-r)}const Gu=.001,OS=.01,_S=10,zS=.05,BS=1;function US({duration:e=800,bounce:t=.25,velocity:n=0,mass:r=1}){let i,o,s=1-t;s=Xt(zS,BS,s),e=Xt(OS,_S,Mt(e)),s<1?(i=u=>{const c=u*s,f=c*e,d=c-n,h=Qu(u,s),x=Math.exp(-f);return Gu-d/h*x},o=u=>{const f=u*s*e,d=f*n+n,h=Math.pow(s,2)*Math.pow(u,2)*e,x=Math.exp(-f),w=Qu(Math.pow(u,2),s);return(-i(u)+Gu>0?-1:1)*((d-h)*x)/w}):(i=u=>{const c=Math.exp(-u*e),f=(u-n)*e+1;return-Gu+c*f},o=u=>{const c=Math.exp(-u*e),f=(n-u)*(e*e);return c*f});const l=5/e,a=WS(i,o,l);if(e=Tn(e),isNaN(a))return{stiffness:100,damping:10,duration:e};{const u=Math.pow(a,2)*r;return{stiffness:u,damping:s*2*Math.sqrt(r*u),duration:e}}}const HS=12;function WS(e,t,n){let r=n;for(let i=1;ie[n]!==void 0)}function YS(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!Hm(e,QS)&&Hm(e,GS)){const n=US(e);t={...t,...n,mass:1},t.isResolvedFromDuration=!0}return t}function Wm({keyframes:e,restDelta:t,restSpeed:n,...r}){const i=e[0],o=e[e.length-1],s={done:!1,value:i},{stiffness:l,damping:a,mass:u,duration:c,velocity:f,isResolvedFromDuration:d}=YS({...r,velocity:-Mt(r.velocity||0)}),h=f||0,x=a/(2*Math.sqrt(l*u)),w=o-i,P=Mt(Math.sqrt(l/u)),y=Math.abs(w)<5;n||(n=y?.01:2),t||(t=y?.005:.5);let p;if(x<1){const m=Qu(P,x);p=S=>{const C=Math.exp(-x*P*S);return o-C*((h+x*P*w)/m*Math.sin(m*S)+w*Math.cos(m*S))}}else if(x===1)p=m=>o-Math.exp(-P*m)*(w+(h+P*w)*m);else{const m=P*Math.sqrt(x*x-1);p=S=>{const C=Math.exp(-x*P*S),b=Math.min(m*S,300);return o-C*((h+x*P*w)*Math.sinh(b)+m*w*Math.cosh(b))/m}}return{calculatedDuration:d&&c||null,next:m=>{const S=p(m);if(d)s.done=m>=c;else{let C=h;m!==0&&(x<1?C=Um(p,m,S):C=0);const b=Math.abs(C)<=n,L=Math.abs(o-S)<=t;s.done=b&&L}return s.value=s.done?o:S,s}}}function Gm({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:s,min:l,max:a,restDelta:u=.5,restSpeed:c}){const f=e[0],d={done:!1,value:f},h=g=>l!==void 0&&ga,x=g=>l===void 0?a:a===void 0||Math.abs(l-g)-w*Math.exp(-g/r),m=g=>y+p(g),S=g=>{const M=p(g),T=m(g);d.done=Math.abs(M)<=u,d.value=d.done?y:T};let C,b;const L=g=>{h(d.value)&&(C=g,b=Wm({keyframes:[d.value,x(d.value)],velocity:Um(m,g,d.value),damping:i,stiffness:o,restDelta:u,restSpeed:c}))};return L(0),{calculatedDuration:null,next:g=>{let M=!1;return!b&&C===void 0&&(M=!0,S(g),L(g)),C!==void 0&&g>C?b.next(g-C):(!M&&S(g),d)}}}const XS=e=>{const t=({timestamp:n})=>e(n);return{start:()=>Y.update(t,!0),stop:()=>kt(t),now:()=>Pe.isProcessing?Pe.timestamp:performance.now()}},Qm=2e4;function Ym(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t=Qm?1/0:t}const ZS={decay:Gm,inertia:Gm,tween:Ss,keyframes:Ss,spring:Wm};function Ps({autoplay:e=!0,delay:t=0,driver:n=XS,keyframes:r,type:i="keyframes",repeat:o=0,repeatDelay:s=0,repeatType:l="loop",onPlay:a,onStop:u,onComplete:c,onUpdate:f,...d}){let h=1,x=!1,w,P;const y=()=>{P=new Promise(V=>{w=V})};y();let p;const m=ZS[i]||Ss;let S;m!==Ss&&typeof r[0]!="number"&&(S=zm([0,100],r,{clamp:!1}),r=[0,100]);const C=m({...d,keyframes:r});let b;l==="mirror"&&(b=m({...d,keyframes:[...r].reverse(),velocity:-(d.velocity||0)}));let L="idle",g=null,M=null,T=null;C.calculatedDuration===null&&o&&(C.calculatedDuration=Ym(C));const{calculatedDuration:E}=C;let I=1/0,$=1/0;E!==null&&(I=E+s,$=I*(o+1)-s);let k=0;const z=V=>{if(M===null)return;h>0&&(M=Math.min(M,V)),h<0&&(M=Math.min(V-$/h,M)),g!==null?k=g:k=Math.round(V-M)*h;const _=k-t*(h>=0?1:-1),re=h>=0?_<0:_>$;k=Math.max(_,0),L==="finished"&&g===null&&(k=$);let he=k,Ve=C;if(o){const mc=Math.min(k,$)/I;let Ms=Math.floor(mc),Dn=mc%1;!Dn&&mc>=1&&(Dn=1),Dn===1&&Ms--,Ms=Math.min(Ms,o+1),!!(Ms%2)&&(l==="reverse"?(Dn=1-Dn,s&&(Dn-=s/I)):l==="mirror"&&(Ve=b)),he=Xt(0,1,Dn)*I}const pe=re?{done:!1,value:r[0]}:Ve.next(he);S&&(pe.value=S(pe.value));let{done:Ln}=pe;!re&&E!==null&&(Ln=h>=0?k>=$:k<=0);const kC=g===null&&(L==="finished"||L==="running"&&Ln);return f&&f(pe.value),kC&&F(),pe},U=()=>{p&&p.stop(),p=void 0},N=()=>{L="idle",U(),w(),y(),M=T=null},F=()=>{L="finished",c&&c(),U(),w()},j=()=>{if(x)return;p||(p=n(z));const V=p.now();a&&a(),g!==null?M=V-g:(!M||L==="finished")&&(M=V),L==="finished"&&y(),T=M,g=null,L="running",p.start()};e&&j();const R={then(V,_){return P.then(V,_)},get time(){return Mt(k)},set time(V){V=Tn(V),k=V,g!==null||!p||h===0?g=V:M=p.now()-V/h},get duration(){const V=C.calculatedDuration===null?Ym(C):C.calculatedDuration;return Mt(V)},get speed(){return h},set speed(V){V===h||!p||(h=V,R.time=Mt(k))},get state(){return L},play:j,pause:()=>{L="paused",g=k},stop:()=>{x=!0,L!=="idle"&&(L="idle",u&&u(),N())},cancel:()=>{T!==null&&z(T),N()},complete:()=>{L="finished"},sample:V=>(M=0,z(V))};return R}function qS(e){let t;return()=>(t===void 0&&(t=e()),t)}const JS=qS(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),eP=new Set(["opacity","clipPath","filter","transform","backgroundColor"]),Cs=10,tP=2e4,nP=(e,t)=>t.type==="spring"||e==="backgroundColor"||!vm(t.ease);function rP(e,t,{onUpdate:n,onComplete:r,...i}){if(!(JS()&&eP.has(t)&&!i.repeatDelay&&i.repeatType!=="mirror"&&i.damping!==0&&i.type!=="inertia"))return!1;let s=!1,l,a,u=!1;const c=()=>{a=new Promise(m=>{l=m})};c();let{keyframes:f,duration:d=300,ease:h,times:x}=i;if(nP(t,i)){const m=Ps({...i,repeat:0,delay:0});let S={done:!1,value:f[0]};const C=[];let b=0;for(;!S.done&&b{u=!1,w.cancel()},y=()=>{u=!0,Y.update(P),l(),c()};return w.onfinish=()=>{u||(e.set(mS(f,i)),r&&r(),y())},{then(m,S){return a.then(m,S)},attachTimeline(m){return w.timeline=m,w.onfinish=null,se},get time(){return Mt(w.currentTime||0)},set time(m){w.currentTime=Tn(m)},get speed(){return w.playbackRate},set speed(m){w.playbackRate=m},get duration(){return Mt(d)},play:()=>{s||(w.play(),kt(P))},pause:()=>w.pause(),stop:()=>{if(s=!0,w.playState==="idle")return;const{currentTime:m}=w;if(m){const S=Ps({...i,autoplay:!1});e.setWithVelocity(S.sample(m-Cs).value,S.sample(m).value,Cs)}y()},complete:()=>{u||w.finish()},cancel:y}}function iP({keyframes:e,delay:t,onUpdate:n,onComplete:r}){const i=()=>(n&&n(e[e.length-1]),r&&r(),{time:0,speed:1,duration:0,play:se,pause:se,stop:se,then:o=>(o(),Promise.resolve()),cancel:se,complete:se});return t?Ps({keyframes:[0,1],duration:0,delay:t,onComplete:i}):i()}const oP={type:"spring",stiffness:500,damping:25,restSpeed:10},sP=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),lP={type:"keyframes",duration:.8},aP={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},uP=(e,{keyframes:t})=>t.length>2?lP:Pn.has(e)?e.startsWith("scale")?sP(t[1]):oP:aP,Yu=(e,t)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(en.test(t)||t==="0")&&!t.startsWith("url(")),cP=new Set(["brightness","contrast","saturate","opacity"]);function fP(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(ds)||[];if(!r)return e;const i=n.replace(r,"");let o=cP.has(t)?1:0;return r!==n&&(o*=100),t+"("+o+i+")"}const dP=/([a-z-]*)\(.*?\)/g,Xu={...en,getAnimatableNone:e=>{const t=e.match(dP);return t?t.map(fP).join(" "):e}},hP={...Xp,color:Ee,backgroundColor:Ee,outlineColor:Ee,fill:Ee,stroke:Ee,borderColor:Ee,borderTopColor:Ee,borderRightColor:Ee,borderBottomColor:Ee,borderLeftColor:Ee,filter:Xu,WebkitFilter:Xu},Zu=e=>hP[e];function Xm(e,t){let n=Zu(e);return n!==Xu&&(n=en),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const Zm=e=>/^0[^.\s]+$/.test(e);function pP(e){if(typeof e=="number")return e===0;if(e!==null)return e==="none"||e==="0"||Zm(e)}function mP(e,t,n,r){const i=Yu(t,n);let o;Array.isArray(n)?o=[...n]:o=[null,n];const s=r.from!==void 0?r.from:e.get();let l;const a=[];for(let u=0;ui=>{const o=qu(r,e)||{},s=o.delay||r.delay||0;let{elapsed:l=0}=r;l=l-Tn(s);const a=mP(t,e,n,o),u=a[0],c=a[a.length-1],f=Yu(e,u),d=Yu(e,c);let h={keyframes:a,velocity:t.getVelocity(),ease:"easeOut",...o,delay:-l,onUpdate:x=>{t.set(x),o.onUpdate&&o.onUpdate(x)},onComplete:()=>{i(),o.onComplete&&o.onComplete()}};if(gP(o)||(h={...h,...uP(e,h)}),h.duration&&(h.duration=Tn(h.duration)),h.repeatDelay&&(h.repeatDelay=Tn(h.repeatDelay)),!f||!d||hS.current||o.type===!1||yP.skipAnimations)return iP(h);if(!r.isHandoff&&t.owner&&t.owner.current instanceof HTMLElement&&!t.owner.getProps().onUpdate){const x=rP(t,e,h);if(x)return x}return Ps(h)};function Ts(e){return!!(Fe(e)&&e.add)}const qm=e=>/^\-?\d*\.?\d+$/.test(e);function ec(e,t){e.indexOf(t)===-1&&e.push(t)}function tc(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class nc{constructor(){this.subscriptions=[]}add(t){return ec(this.subscriptions,t),()=>tc(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let o=0;o!isNaN(parseFloat(e));class xP{constructor(t,n={}){this.version="10.18.0",this.timeDelta=0,this.lastUpdated=0,this.canTrackVelocity=!1,this.events={},this.updateAndNotify=(r,i=!0)=>{this.prev=this.current,this.current=r;const{delta:o,timestamp:s}=Pe;this.lastUpdated!==s&&(this.timeDelta=o,this.lastUpdated=s,Y.postRender(this.scheduleVelocityCheck)),this.prev!==this.current&&this.events.change&&this.events.change.notify(this.current),this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()),i&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.scheduleVelocityCheck=()=>Y.postRender(this.velocityCheck),this.velocityCheck=({timestamp:r})=>{r!==this.lastUpdated&&(this.prev=this.current,this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()))},this.hasAnimated=!1,this.prev=this.current=t,this.canTrackVelocity=vP(this.current),this.owner=n.owner}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new nc);const r=this.events[t].add(n);return t==="change"?()=>{r(),Y.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=t,this.timeDelta=r}jump(t){this.updateAndNotify(t),this.prev=t,this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){return this.canTrackVelocity?Bm(parseFloat(this.current)-parseFloat(this.prev),this.timeDelta):0}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 gr(e,t){return new xP(e,t)}const Jm=e=>t=>t.test(e),eg=[Cn,O,ht,Zt,Mw,bw,{test:e=>e==="auto",parse:e=>e}],$i=e=>eg.find(Jm(e)),wP=[...eg,Ee,en],SP=e=>wP.find(Jm(e));function PP(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,gr(n))}function CP(e,t){const n=vs(e,t);let{transitionEnd:r={},transition:i={},...o}=n?e.makeTargetAnimatable(n,!1):{};o={...o,...r};for(const s in o){const l=Bw(o[s]);PP(e,s,l)}}function TP(e,t,n){var r,i;const o=Object.keys(t).filter(l=>!e.hasValue(l)),s=o.length;if(s)for(let l=0;la.remove(f))),u.push(P)}return s&&Promise.all(u).then(()=>{s&&CP(e,s)}),u}function rc(e,t,n={}){const r=vs(e,t,n.custom);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const o=r?()=>Promise.all(tg(e,r,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(a=0)=>{const{delayChildren:u=0,staggerChildren:c,staggerDirection:f}=i;return MP(e,t,u+a,c,f,n)}:()=>Promise.resolve(),{when:l}=i;if(l){const[a,u]=l==="beforeChildren"?[o,s]:[s,o];return a().then(()=>u())}else return Promise.all([o(),s(n.delay)])}function MP(e,t,n=0,r=0,i=1,o){const s=[],l=(e.variantChildren.size-1)*r,a=i===1?(u=0)=>u*r:(u=0)=>l-u*r;return Array.from(e.variantChildren).sort(LP).forEach((u,c)=>{u.notify("AnimationStart",t),s.push(rc(u,t,{...o,delay:n+a(c)}).then(()=>u.notify("AnimationComplete",t)))}),Promise.all(s)}function LP(e,t){return e.sortNodePosition(t)}function DP(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(o=>rc(e,o,n));r=Promise.all(i)}else if(typeof t=="string")r=rc(e,t,n);else{const i=typeof t=="function"?vs(e,t,n.custom):t;r=Promise.all(tg(e,i,n))}return r.then(()=>e.notify("AnimationComplete",t))}const AP=[...Tu].reverse(),RP=Tu.length;function FP(e){return t=>Promise.all(t.map(({animation:n,options:r})=>DP(e,n,r)))}function VP(e){let t=FP(e);const n=KP();let r=!0;const i=(a,u)=>{const c=vs(e,u);if(c){const{transition:f,transitionEnd:d,...h}=c;a={...a,...h,...d}}return a};function o(a){t=a(e)}function s(a,u){const c=e.getProps(),f=e.getVariantContext(!0)||{},d=[],h=new Set;let x={},w=1/0;for(let y=0;yw&&C,T=!1;const E=Array.isArray(S)?S:[S];let I=E.reduce(i,{});b===!1&&(I={});const{prevResolvedValues:$={}}=m,k={...$,...I},z=U=>{M=!0,h.has(U)&&(T=!0,h.delete(U)),m.needsAnimating[U]=!0};for(const U in k){const N=I[U],F=$[U];if(x.hasOwnProperty(U))continue;let j=!1;ps(N)&&ps(F)?j=!gm(N,F):j=N!==F,j?N!==void 0?z(U):h.add(U):N!==void 0&&h.has(U)?z(U):m.protectedKeys[U]=!0}m.prevProp=S,m.prevResolvedValues=I,m.isActive&&(x={...x,...I}),r&&e.blockInitialAnimation&&(M=!1),M&&(!L||T)&&d.push(...E.map(U=>({animation:U,options:{type:p,...a}})))}if(h.size){const y={};h.forEach(p=>{const m=e.getBaseTarget(p);m!==void 0&&(y[p]=m)}),d.push({animation:y})}let P=!!d.length;return r&&(c.initial===!1||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(P=!1),r=!1,P?t(d):Promise.resolve()}function l(a,u,c){var f;if(n[a].isActive===u)return Promise.resolve();(f=e.variantChildren)===null||f===void 0||f.forEach(h=>{var x;return(x=h.animationState)===null||x===void 0?void 0:x.setActive(a,u)}),n[a].isActive=u;const d=s(c,a);for(const h in n)n[h].protectedKeys={};return d}return{animateChanges:s,setActive:l,setAnimateFunction:o,getState:()=>n}}function NP(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!gm(t,e):!1}function kn(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function KP(){return{animate:kn(!0),whileInView:kn(),whileHover:kn(),whileTap:kn(),whileDrag:kn(),whileFocus:kn(),exit:kn()}}class IP extends Jt{constructor(t){super(t),t.animationState||(t.animationState=VP(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();this.unmount(),as(t)&&(this.unmount=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){}}let jP=0;class OP extends Jt{constructor(){super(...arguments),this.id=jP++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n,custom:r}=this.node.presenceContext,{isPresent:i}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===i)return;const o=this.node.animationState.setActive("exit",!t,{custom:r??this.node.getProps().custom});n&&!t&&o.then(()=>n(this.id))}mount(){const{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}}const _P={animation:{Feature:IP},exit:{Feature:OP}},ng=(e,t)=>Math.abs(e-t);function zP(e,t){const n=ng(e.x,t.x),r=ng(e.y,t.y);return Math.sqrt(n**2+r**2)}class rg{constructor(t,n,{transformPagePoint:r,contextWindow:i,dragSnapToOrigin:o=!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 f=oc(this.lastMoveEventInfo,this.history),d=this.startEvent!==null,h=zP(f.offset,{x:0,y:0})>=3;if(!d&&!h)return;const{point:x}=f,{timestamp:w}=Pe;this.history.push({...x,timestamp:w});const{onStart:P,onMove:y}=this.handlers;d||(P&&P(this.lastMoveEvent,f),this.startEvent=this.lastMoveEvent),y&&y(this.lastMoveEvent,f)},this.handlePointerMove=(f,d)=>{this.lastMoveEvent=f,this.lastMoveEventInfo=ic(d,this.transformPagePoint),Y.update(this.updatePoint,!0)},this.handlePointerUp=(f,d)=>{this.end();const{onEnd:h,onSessionEnd:x,resumeAnimation:w}=this.handlers;if(this.dragSnapToOrigin&&w&&w(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const P=oc(f.type==="pointercancel"?this.lastMoveEventInfo:ic(d,this.transformPagePoint),this.history);this.startEvent&&h&&h(f,P),x&&x(f,P)},!am(t))return;this.dragSnapToOrigin=o,this.handlers=n,this.transformPagePoint=r,this.contextWindow=i||window;const s=ys(t),l=ic(s,this.transformPagePoint),{point:a}=l,{timestamp:u}=Pe;this.history=[{...a,timestamp:u}];const{onSessionStart:c}=n;c&&c(t,oc(l,this.history)),this.removeListeners=qt(bt(this.contextWindow,"pointermove",this.handlePointerMove),bt(this.contextWindow,"pointerup",this.handlePointerUp),bt(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),kt(this.updatePoint)}}function ic(e,t){return t?{point:t(e.point)}:e}function ig(e,t){return{x:e.x-t.x,y:e.y-t.y}}function oc({point:e},t){return{point:e,delta:ig(e,og(t)),offset:ig(e,BP(t)),velocity:UP(t,.1)}}function BP(e){return e[0]}function og(e){return e[e.length-1]}function UP(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=og(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>Tn(t)));)n--;if(!r)return{x:0,y:0};const o=Mt(i.timestamp-r.timestamp);if(o===0)return{x:0,y:0};const s={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function ze(e){return e.max-e.min}function sc(e,t=0,n=.01){return Math.abs(e-t)<=n}function sg(e,t,n,r=.5){e.origin=r,e.originPoint=ne(t.min,t.max,e.origin),e.scale=ze(n)/ze(t),(sc(e.scale,1,1e-4)||isNaN(e.scale))&&(e.scale=1),e.translate=ne(n.min,n.max,e.origin)-e.originPoint,(sc(e.translate)||isNaN(e.translate))&&(e.translate=0)}function ki(e,t,n,r){sg(e.x,t.x,n.x,r?r.originX:void 0),sg(e.y,t.y,n.y,r?r.originY:void 0)}function lg(e,t,n){e.min=n.min+t.min,e.max=e.min+ze(t)}function HP(e,t,n){lg(e.x,t.x,n.x),lg(e.y,t.y,n.y)}function ag(e,t,n){e.min=t.min-n.min,e.max=e.min+ze(t)}function Ei(e,t,n){ag(e.x,t.x,n.x),ag(e.y,t.y,n.y)}function WP(e,{min:t,max:n},r){return t!==void 0&&en&&(e=r?ne(n,e,r.max):Math.min(e,n)),e}function ug(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 GP(e,{top:t,left:n,bottom:r,right:i}){return{x:ug(e.x,n,i),y:ug(e.y,t,r)}}function cg(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.minr?n=Ti(t.min,t.max-r,e.min):r>i&&(n=Ti(e.min,e.max-i,t.min)),Xt(0,1,n)}function XP(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 lc=.35;function ZP(e=lc){return e===!1?e=0:e===!0&&(e=lc),{x:fg(e,"left","right"),y:fg(e,"top","bottom")}}function fg(e,t,n){return{min:dg(e,t),max:dg(e,n)}}function dg(e,t){return typeof e=="number"?e:e[t]||0}const hg=()=>({translate:0,scale:1,origin:0,originPoint:0}),yr=()=>({x:hg(),y:hg()}),pg=()=>({min:0,max:0}),ae=()=>({x:pg(),y:pg()});function Xe(e){return[e("x"),e("y")]}function mg({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function qP({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function JP(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 ac(e){return e===void 0||e===1}function uc({scale:e,scaleX:t,scaleY:n}){return!ac(e)||!ac(t)||!ac(n)}function En(e){return uc(e)||gg(e)||e.z||e.rotate||e.rotateX||e.rotateY}function gg(e){return yg(e.x)||yg(e.y)}function yg(e){return e&&e!=="0%"}function $s(e,t,n){const r=e-n,i=t*r;return n+i}function vg(e,t,n,r,i){return i!==void 0&&(e=$s(e,i,r)),$s(e,n,r)+t}function cc(e,t=0,n=1,r,i){e.min=vg(e.min,t,n,r,i),e.max=vg(e.max,t,n,r,i)}function xg(e,{x:t,y:n}){cc(e.x,t.translate,t.scale,t.originPoint),cc(e.y,n.translate,n.scale,n.originPoint)}function e2(e,t,n,r=!1){const i=n.length;if(!i)return;t.x=t.y=1;let o,s;for(let l=0;l1.0000000000001||e<.999999999999?e:1}function tn(e,t){e.min=e.min+t,e.max=e.max+t}function Sg(e,t,[n,r,i]){const o=t[i]!==void 0?t[i]:.5,s=ne(e.min,e.max,o);cc(e,t[n],t[r],s,t.scale)}const t2=["x","scaleX","originX"],n2=["y","scaleY","originY"];function vr(e,t){Sg(e.x,t,t2),Sg(e.y,t,n2)}function Pg(e,t){return mg(JP(e.getBoundingClientRect(),t))}function r2(e,t,n){const r=Pg(e,n),{scroll:i}=t;return i&&(tn(r.x,i.offset.x),tn(r.y,i.offset.y)),r}const Cg=({current:e})=>e?e.ownerDocument.defaultView:null,i2=new WeakMap;class o2{constructor(t){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=ae(),this.visualElement=t}start(t,{snapToCursor:n=!1}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const i=c=>{const{dragSnapToOrigin:f}=this.getProps();f?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(ys(c,"page").point)},o=(c,f)=>{const{drag:d,dragPropagation:h,onDragStart:x}=this.getProps();if(d&&!h&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=dm(d),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Xe(P=>{let y=this.getAxisMotionValue(P).get()||0;if(ht.test(y)){const{projection:p}=this.visualElement;if(p&&p.layout){const m=p.layout.layoutBox[P];m&&(y=ze(m)*(parseFloat(y)/100))}}this.originPoint[P]=y}),x&&Y.update(()=>x(c,f),!1,!0);const{animationState:w}=this.visualElement;w&&w.setActive("whileDrag",!0)},s=(c,f)=>{const{dragPropagation:d,dragDirectionLock:h,onDirectionLock:x,onDrag:w}=this.getProps();if(!d&&!this.openGlobalLock)return;const{offset:P}=f;if(h&&this.currentDirection===null){this.currentDirection=s2(P),this.currentDirection!==null&&x&&x(this.currentDirection);return}this.updateAxis("x",f.point,P),this.updateAxis("y",f.point,P),this.visualElement.render(),w&&w(c,f)},l=(c,f)=>this.stop(c,f),a=()=>Xe(c=>{var f;return this.getAnimationState(c)==="paused"&&((f=this.getAxisMotionValue(c).animation)===null||f===void 0?void 0:f.play())}),{dragSnapToOrigin:u}=this.getProps();this.panSession=new rg(t,{onSessionStart:i,onStart:o,onMove:s,onSessionEnd:l,resumeAnimation:a},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,contextWindow:Cg(this.visualElement)})}stop(t,n){const r=this.isDragging;if(this.cancel(),!r)return;const{velocity:i}=n;this.startAnimation(i);const{onDragEnd:o}=this.getProps();o&&Y.update(()=>o(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.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!ks(t,i,this.currentDirection))return;const o=this.getAxisMotionValue(t);let s=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(s=WP(s,this.constraints[t],this.elastic[t])),o.set(s)}resolveConstraints(){var t;const{dragConstraints:n,dragElastic:r}=this.getProps(),i=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(t=this.visualElement.projection)===null||t===void 0?void 0:t.layout,o=this.constraints;n&&pr(n)?this.constraints||(this.constraints=this.resolveRefConstraints()):n&&i?this.constraints=GP(i.layoutBox,n):this.constraints=!1,this.elastic=ZP(r),o!==this.constraints&&i&&this.constraints&&!this.hasMutatedConstraints&&Xe(s=>{this.getAxisMotionValue(s)&&(this.constraints[s]=XP(i.layoutBox[s],this.constraints[s]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!pr(t))return!1;const r=t.current,{projection:i}=this.visualElement;if(!i||!i.layout)return!1;const o=r2(r,i.root,this.visualElement.getTransformPagePoint());let s=QP(i.layout.layoutBox,o);if(n){const l=n(qP(s));this.hasMutatedConstraints=!!l,l&&(s=mg(l))}return s}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:o,dragSnapToOrigin:s,onDragTransitionEnd:l}=this.getProps(),a=this.constraints||{},u=Xe(c=>{if(!ks(c,n,this.currentDirection))return;let f=a&&a[c]||{};s&&(f={min:0,max:0});const d=i?200:1e6,h=i?40:1e7,x={type:"inertia",velocity:r?t[c]:0,bounceStiffness:d,bounceDamping:h,timeConstant:750,restDelta:1,restSpeed:10,...o,...f};return this.startAxisValueAnimation(c,x)});return Promise.all(u).then(l)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return r.start(Ju(t,r,0,n))}stopAnimation(){Xe(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Xe(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(),i=r[n];return i||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Xe(n=>{const{drag:r}=this.getProps();if(!ks(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,o=this.getAxisMotionValue(n);if(i&&i.layout){const{min:s,max:l}=i.layout.layoutBox[n];o.set(t[n]-ne(s,l,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!pr(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Xe(s=>{const l=this.getAxisMotionValue(s);if(l){const a=l.get();i[s]=YP({min:a,max:a},this.constraints[s])}});const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Xe(s=>{if(!ks(s,t,null))return;const l=this.getAxisMotionValue(s),{min:a,max:u}=this.constraints[s];l.set(ne(a,u,i[s]))})}addListeners(){if(!this.visualElement.current)return;i2.set(this.visualElement,this);const t=this.visualElement.current,n=bt(t,"pointerdown",a=>{const{drag:u,dragListener:c=!0}=this.getProps();u&&c&&this.start(a)}),r=()=>{const{dragConstraints:a}=this.getProps();pr(a)&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,o=i.addEventListener("measure",r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),r();const s=Et(window,"resize",()=>this.scalePositionWithinConstraints()),l=i.addEventListener("didUpdate",({delta:a,hasLayoutChanged:u})=>{this.isDragging&&u&&(Xe(c=>{const f=this.getAxisMotionValue(c);f&&(this.originPoint[c]+=a[c].translate,f.set(f.get()+a[c].translate))}),this.visualElement.render())});return()=>{s(),n(),o(),l&&l()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:o=!1,dragElastic:s=lc,dragMomentum:l=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:o,dragElastic:s,dragMomentum:l}}}function ks(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function s2(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class l2 extends Jt{constructor(t){super(t),this.removeGroupControls=se,this.removeListeners=se,this.controls=new o2(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||se}unmount(){this.removeGroupControls(),this.removeListeners()}}const Tg=e=>(t,n)=>{e&&Y.update(()=>e(t,n))};class a2 extends Jt{constructor(){super(...arguments),this.removePointerDownListener=se}onPointerDown(t){this.session=new rg(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Cg(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:Tg(t),onStart:Tg(n),onMove:r,onEnd:(o,s)=>{delete this.session,i&&Y.update(()=>i(o,s))}}}mount(){this.removePointerDownListener=bt(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}function u2(){const e=v.useContext(ss);if(e===null)return[!0,null];const{isPresent:t,onExitComplete:n,register:r}=e,i=v.useId();return v.useEffect(()=>r(i),[]),!t&&n?[!1,()=>n&&n(i)]:[!0]}const Es={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function $g(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const bi={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(O.test(e))e=parseFloat(e);else return e;const n=$g(e,t.target.x),r=$g(e,t.target.y);return`${n}% ${r}%`}},c2={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=en.parse(e);if(i.length>5)return r;const o=en.createTransformer(e),s=typeof i[0]!="number"?1:0,l=n.x.scale*t.x,a=n.y.scale*t.y;i[0+s]/=l,i[1+s]/=a;const u=ne(l,a,.5);return typeof i[2+s]=="number"&&(i[2+s]/=u),typeof i[3+s]=="number"&&(i[3+s]/=u),o(i)}};class f2 extends B.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:o}=t;Sw(d2),o&&(n.group&&n.group.add(o),r&&r.register&&i&&r.register(o),o.root.didUpdate(),o.addEventListener("animationComplete",()=>{this.safeToRemove()}),o.setOptions({...o.options,onExitComplete:()=>this.safeToRemove()})),Es.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:o}=this.props,s=r.projection;return s&&(s.isPresent=o,i||t.layoutDependency!==n||n===void 0?s.willUpdate():this.safeToRemove(),t.isPresent!==o&&(o?s.promote():s.relegate()||Y.postRender(()=>{const l=s.getStack();(!l||!l.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),queueMicrotask(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function kg(e){const[t,n]=u2(),r=v.useContext(ku);return B.createElement(f2,{...e,layoutGroup:r,switchLayoutGroup:v.useContext(Bp),isPresent:t,safeToRemove:n})}const d2={borderRadius:{...bi,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:bi,borderTopRightRadius:bi,borderBottomLeftRadius:bi,borderBottomRightRadius:bi,boxShadow:c2},Eg=["TopLeft","TopRight","BottomLeft","BottomRight"],h2=Eg.length,bg=e=>typeof e=="string"?parseFloat(e):e,Mg=e=>typeof e=="number"||O.test(e);function p2(e,t,n,r,i,o){i?(e.opacity=ne(0,n.opacity!==void 0?n.opacity:1,m2(r)),e.opacityExit=ne(t.opacity!==void 0?t.opacity:1,0,g2(r))):o&&(e.opacity=ne(t.opacity!==void 0?t.opacity:1,n.opacity!==void 0?n.opacity:1,r));for(let s=0;srt?1:n(Ti(e,t,r))}function Ag(e,t){e.min=t.min,e.max=t.max}function Ze(e,t){Ag(e.x,t.x),Ag(e.y,t.y)}function Rg(e,t,n,r,i){return e-=t,e=$s(e,1/n,r),i!==void 0&&(e=$s(e,1/i,r)),e}function y2(e,t=0,n=1,r=.5,i,o=e,s=e){if(ht.test(t)&&(t=parseFloat(t),t=ne(s.min,s.max,t/100)-s.min),typeof t!="number")return;let l=ne(o.min,o.max,r);e===o&&(l-=t),e.min=Rg(e.min,t,n,l,i),e.max=Rg(e.max,t,n,l,i)}function Fg(e,t,[n,r,i],o,s){y2(e,t[n],t[r],t[i],t.scale,o,s)}const v2=["x","scaleX","originX"],x2=["y","scaleY","originY"];function Vg(e,t,n,r){Fg(e.x,t,v2,n?n.x:void 0,r?r.x:void 0),Fg(e.y,t,x2,n?n.y:void 0,r?r.y:void 0)}function Ng(e){return e.translate===0&&e.scale===1}function Kg(e){return Ng(e.x)&&Ng(e.y)}function w2(e,t){return e.x.min===t.x.min&&e.x.max===t.x.max&&e.y.min===t.y.min&&e.y.max===t.y.max}function Ig(e,t){return Math.round(e.x.min)===Math.round(t.x.min)&&Math.round(e.x.max)===Math.round(t.x.max)&&Math.round(e.y.min)===Math.round(t.y.min)&&Math.round(e.y.max)===Math.round(t.y.max)}function jg(e){return ze(e.x)/ze(e.y)}class S2{constructor(){this.members=[]}add(t){ec(this.members,t),t.scheduleRender()}remove(t){if(tc(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(i=>t===i);if(n===0)return!1;let r;for(let i=n;i>=0;i--){const o=this.members[i];if(o.isPresent!==!1){r=o;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:i}=t.options;i===!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 Og(e,t,n){let r="";const i=e.x.translate/t.x,o=e.y.translate/t.y;if((i||o)&&(r=`translate3d(${i}px, ${o}px, 0) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{rotate:a,rotateX:u,rotateY:c}=n;a&&(r+=`rotate(${a}deg) `),u&&(r+=`rotateX(${u}deg) `),c&&(r+=`rotateY(${c}deg) `)}const s=e.x.scale*t.x,l=e.y.scale*t.y;return(s!==1||l!==1)&&(r+=`scale(${s}, ${l})`),r||"none"}const P2=(e,t)=>e.depth-t.depth;class C2{constructor(){this.children=[],this.isDirty=!1}add(t){ec(this.children,t),this.isDirty=!0}remove(t){tc(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(P2),this.isDirty=!1,this.children.forEach(t)}}function T2(e,t){const n=performance.now(),r=({timestamp:i})=>{const o=i-n;o>=t&&(kt(r),e(o-t))};return Y.read(r,!0),()=>kt(r)}function $2(e){window.MotionDebug&&window.MotionDebug.record(e)}function k2(e){return e instanceof SVGElement&&e.tagName!=="svg"}function E2(e,t,n){const r=Fe(e)?e:gr(e);return r.start(Ju("",r,t,n)),r.animation}const _g=["","X","Y","Z"],b2={visibility:"hidden"},zg=1e3;let M2=0;const bn={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0};function Bg({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(s={},l=t==null?void 0:t()){this.id=M2++,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.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,bn.totalNodes=bn.resolvedTargetDeltas=bn.recalculatedProjection=0,this.nodes.forEach(A2),this.nodes.forEach(K2),this.nodes.forEach(I2),this.nodes.forEach(R2),$2(bn)},this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=l?l.root||l:this,this.path=l?[...l.path,l]:[],this.parent=l,this.depth=l?l.depth+1:0;for(let a=0;athis.root.updateBlockedByResize=!1;e(s,()=>{this.root.updateBlockedByResize=!0,f&&f(),f=T2(d,250),Es.hasAnimatedSinceResize&&(Es.hasAnimatedSinceResize=!1,this.nodes.forEach(Hg))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&c&&(a||u)&&this.addEventListener("didUpdate",({delta:f,hasLayoutChanged:d,hasRelativeTargetChanged:h,layout:x})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const w=this.options.transition||c.getDefaultTransition()||B2,{onLayoutAnimationStart:P,onLayoutAnimationComplete:y}=c.getProps(),p=!this.targetLayout||!Ig(this.targetLayout,x)||h,m=!d&&h;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||m||d&&(p||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(f,m);const S={...qu(w,"layout"),onPlay:P,onComplete:y};(c.shouldReduceMotion||this.options.layoutRoot)&&(S.delay=0,S.type=!1),this.startAnimation(S)}else d||Hg(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=x})}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,kt(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(j2),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(!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let c=0;cthis.update()))}clearAllSnapshots(){this.nodes.forEach(F2),this.sharedNodes.forEach(O2)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,Y.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){Y.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let a=0;a{const C=S/1e3;Wg(f.x,s.x,C),Wg(f.y,s.y,C),this.setTargetDelta(f),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Ei(d,this.layout.layoutBox,this.relativeParent.layout.layoutBox),_2(this.relativeTarget,this.relativeTargetOrigin,d,C),m&&w2(this.relativeTarget,m)&&(this.isProjectionDirty=!1),m||(m=ae()),Ze(m,this.relativeTarget)),w&&(this.animationValues=c,p2(c,u,this.latestValues,C,p,y)),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&&(kt(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Y.update(()=>{Es.hasAnimatedSinceResize=!0,this.currentAnimation=E2(0,zg,{...s,onUpdate:l=>{this.mixTargetDelta(l),s.onUpdate&&s.onUpdate(l)},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(zg),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:l,target:a,layout:u,latestValues:c}=s;if(!(!l||!a||!u)){if(this!==s&&this.layout&&u&&Zg(this.options.animationType,this.layout.layoutBox,u.layoutBox)){a=this.target||ae();const f=ze(this.layout.layoutBox.x);a.x.min=s.target.x.min,a.x.max=a.x.min+f;const d=ze(this.layout.layoutBox.y);a.y.min=s.target.y.min,a.y.max=a.y.min+d}Ze(l,a),vr(l,c),ki(this.projectionDeltaWithTransform,this.layoutCorrected,l,c)}}registerSharedNode(s,l){this.sharedNodes.has(s)||this.sharedNodes.set(s,new S2),this.sharedNodes.get(s).add(l);const u=l.options.initialPromotionConfig;l.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(l):void 0})}isLead(){const s=this.getStack();return s?s.lead===this:!0}getLead(){var s;const{layoutId:l}=this.options;return l?((s=this.getStack())===null||s===void 0?void 0:s.lead)||this:this}getPrevLead(){var s;const{layoutId:l}=this.options;return l?(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:l,preserveFollowOpacity:a}={}){const u=this.getStack();u&&u.promote(this,a),s&&(this.projectionDelta=void 0,this.needsReset=!0),l&&this.setOptions({transition:l})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetRotation(){const{visualElement:s}=this.options;if(!s)return;let l=!1;const{latestValues:a}=s;if((a.rotate||a.rotateX||a.rotateY||a.rotateZ)&&(l=!0),!l)return;const u={};for(let c=0;c<_g.length;c++){const f="rotate"+_g[c];a[f]&&(u[f]=a[f],s.setStaticValue(f,0))}s.render();for(const c in u)s.setStaticValue(c,u[c]);s.scheduleRender()}getProjectionStyles(s){var l,a;if(!this.instance||this.isSVG)return;if(!this.isVisible)return b2;const u={visibility:""},c=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,u.opacity="",u.pointerEvents=ms(s==null?void 0:s.pointerEvents)||"",u.transform=c?c(this.latestValues,""):"none",u;const f=this.getLead();if(!this.projectionDelta||!this.layout||!f.target){const w={};return this.options.layoutId&&(w.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,w.pointerEvents=ms(s==null?void 0:s.pointerEvents)||""),this.hasProjected&&!En(this.latestValues)&&(w.transform=c?c({},""):"none",this.hasProjected=!1),w}const d=f.animationValues||f.latestValues;this.applyTransformsToTarget(),u.transform=Og(this.projectionDeltaWithTransform,this.treeScale,d),c&&(u.transform=c(d,u.transform));const{x:h,y:x}=this.projectionDelta;u.transformOrigin=`${h.origin*100}% ${x.origin*100}% 0`,f.animationValues?u.opacity=f===this?(a=(l=d.opacity)!==null&&l!==void 0?l:this.latestValues.opacity)!==null&&a!==void 0?a:1:this.preserveOpacity?this.latestValues.opacity:d.opacityExit:u.opacity=f===this?d.opacity!==void 0?d.opacity:"":d.opacityExit!==void 0?d.opacityExit:0;for(const w in cs){if(d[w]===void 0)continue;const{correct:P,applyTo:y}=cs[w],p=u.transform==="none"?d[w]:P(d[w],f);if(y){const m=y.length;for(let S=0;S{var l;return(l=s.currentAnimation)===null||l===void 0?void 0:l.stop()}),this.root.nodes.forEach(Ug),this.root.sharedNodes.clear()}}}function L2(e){e.updateLayout()}function D2(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:i}=e.layout,{animationType:o}=e.options,s=n.source!==e.layout.source;o==="size"?Xe(f=>{const d=s?n.measuredBox[f]:n.layoutBox[f],h=ze(d);d.min=r[f].min,d.max=d.min+h}):Zg(o,n.layoutBox,r)&&Xe(f=>{const d=s?n.measuredBox[f]:n.layoutBox[f],h=ze(r[f]);d.max=d.min+h,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[f].max=e.relativeTarget[f].min+h)});const l=yr();ki(l,r,n.layoutBox);const a=yr();s?ki(a,e.applyTransform(i,!0),n.measuredBox):ki(a,r,n.layoutBox);const u=!Kg(l);let c=!1;if(!e.resumeFrom){const f=e.getClosestProjectingParent();if(f&&!f.resumeFrom){const{snapshot:d,layout:h}=f;if(d&&h){const x=ae();Ei(x,n.layoutBox,d.layoutBox);const w=ae();Ei(w,r,h.layoutBox),Ig(x,w)||(c=!0),f.options.layoutRoot&&(e.relativeTarget=w,e.relativeTargetOrigin=x,e.relativeParent=f)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:n,delta:a,layoutDelta:l,hasLayoutChanged:u,hasRelativeTargetChanged:c})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function A2(e){bn.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 R2(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function F2(e){e.clearSnapshot()}function Ug(e){e.clearMeasurements()}function V2(e){e.isLayoutDirty=!1}function N2(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Hg(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function K2(e){e.resolveTargetDelta()}function I2(e){e.calcProjection()}function j2(e){e.resetRotation()}function O2(e){e.removeLeadSnapshot()}function Wg(e,t,n){e.translate=ne(t.translate,0,n),e.scale=ne(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Gg(e,t,n,r){e.min=ne(t.min,n.min,r),e.max=ne(t.max,n.max,r)}function _2(e,t,n,r){Gg(e.x,t.x,n.x,r),Gg(e.y,t.y,n.y,r)}function z2(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const B2={duration:.45,ease:[.4,0,.1,1]},Qg=e=>typeof navigator<"u"&&navigator.userAgent.toLowerCase().includes(e),Yg=Qg("applewebkit/")&&!Qg("chrome/")?Math.round:se;function Xg(e){e.min=Yg(e.min),e.max=Yg(e.max)}function U2(e){Xg(e.x),Xg(e.y)}function Zg(e,t,n){return e==="position"||e==="preserve-aspect"&&!sc(jg(t),jg(n),.2)}const H2=Bg({attachResizeListener:(e,t)=>Et(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),fc={current:void 0},qg=Bg({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!fc.current){const e=new H2({});e.mount(window),e.setOptions({layoutScroll:!0}),fc.current=e}return fc.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),W2={pan:{Feature:a2},drag:{Feature:l2,ProjectionNode:qg,MeasureLayout:kg}},G2=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/;function Q2(e){const t=G2.exec(e);if(!t)return[,];const[,n,r]=t;return[n,r]}function dc(e,t,n=1){const[r,i]=Q2(e);if(!r)return;const o=window.getComputedStyle(t).getPropertyValue(r);if(o){const s=o.trim();return qm(s)?parseFloat(s):s}else return bu(i)?dc(i,t,n+1):i}function Y2(e,{...t},n){const r=e.current;if(!(r instanceof Element))return{target:t,transitionEnd:n};n&&(n={...n}),e.values.forEach(i=>{const o=i.get();if(!bu(o))return;const s=dc(o,r);s&&i.set(s)});for(const i in t){const o=t[i];if(!bu(o))continue;const s=dc(o,r);s&&(t[i]=s,n||(n={}),n[i]===void 0&&(n[i]=o))}return{target:t,transitionEnd:n}}const X2=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),Jg=e=>X2.has(e),Z2=e=>Object.keys(e).some(Jg),ey=e=>e===Cn||e===O,ty=(e,t)=>parseFloat(e.split(", ")[t]),ny=(e,t)=>(n,{transform:r})=>{if(r==="none"||!r)return 0;const i=r.match(/^matrix3d\((.+)\)$/);if(i)return ty(i[1],t);{const o=r.match(/^matrix\((.+)\)$/);return o?ty(o[1],e):0}},q2=new Set(["x","y","z"]),J2=yi.filter(e=>!q2.has(e));function eC(e){const t=[];return J2.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t.length&&e.render(),t}const xr={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:ny(4,13),y:ny(5,14)};xr.translateX=xr.x,xr.translateY=xr.y;const tC=(e,t,n)=>{const r=t.measureViewportBox(),i=t.current,o=getComputedStyle(i),{display:s}=o,l={};s==="none"&&t.setStaticValue("display",e.display||"block"),n.forEach(u=>{l[u]=xr[u](r,o)}),t.render();const a=t.measureViewportBox();return n.forEach(u=>{const c=t.getValue(u);c&&c.jump(l[u]),e[u]=xr[u](a,o)}),e},nC=(e,t,n={},r={})=>{t={...t},r={...r};const i=Object.keys(t).filter(Jg);let o=[],s=!1;const l=[];if(i.forEach(a=>{const u=e.getValue(a);if(!e.hasValue(a))return;let c=n[a],f=$i(c);const d=t[a];let h;if(ps(d)){const x=d.length,w=d[0]===null?1:0;c=d[w],f=$i(c);for(let P=w;P=0?window.pageYOffset:null,u=tC(t,e,l);return o.length&&o.forEach(([c,f])=>{e.getValue(c).set(f)}),e.render(),ls&&a!==null&&window.scrollTo({top:a}),{target:u,transitionEnd:r}}else return{target:t,transitionEnd:r}};function rC(e,t,n,r){return Z2(t)?nC(e,t,n,r):{target:t,transitionEnd:r}}const iC=(e,t,n,r)=>{const i=Y2(e,t,r);return t=i.target,r=i.transitionEnd,rC(e,t,n,r)},hc={current:null},ry={current:!1};function oC(){if(ry.current=!0,!!ls)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>hc.current=e.matches;e.addListener(t),t()}else hc.current=!1}function sC(e,t,n){const{willChange:r}=t;for(const i in t){const o=t[i],s=n[i];if(Fe(o))e.addValue(i,o),Ts(r)&&r.add(i);else if(Fe(s))e.addValue(i,gr(o,{owner:e})),Ts(r)&&r.remove(i);else if(s!==o)if(e.hasValue(i)){const l=e.getValue(i);!l.hasAnimated&&l.set(o)}else{const l=e.getStaticValue(i);e.addValue(i,gr(l!==void 0?l:o,{owner:e}))}}for(const i in n)t[i]===void 0&&e.removeValue(i);return t}const iy=new WeakMap,oy=Object.keys(gi),lC=oy.length,sy=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],aC=$u.length;class uC{constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,visualState:o},s={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,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.scheduleRender=()=>Y.render(this.render,!1,!0);const{latestValues:l,renderState:a}=o;this.latestValues=l,this.baseTarget={...l},this.initialValues=n.initial?{...l}:{},this.renderState=a,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.options=s,this.isControllingVariants=us(n),this.isVariantNode=Op(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:u,...c}=this.scrapeMotionValuesFromProps(n,{});for(const f in c){const d=c[f];l[f]!==void 0&&Fe(d)&&(d.set(l[f],!1),Ts(u)&&u.add(f))}}scrapeMotionValuesFromProps(t,n){return{}}mount(t){this.current=t,iy.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,r)=>this.bindToMotionValue(r,n)),ry.current||oC(),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(){iy.delete(this.current),this.projection&&this.projection.unmount(),kt(this.notifyUpdate),kt(this.render),this.valueSubscriptions.forEach(t=>t()),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)this.features[t].unmount();this.current=null}bindToMotionValue(t,n){const r=Pn.has(t),i=n.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&Y.update(this.notifyUpdate,!1,!0),r&&this.projection&&(this.projection.isTransformDirty=!0)}),o=n.on("renderRequest",this.scheduleRender);this.valueSubscriptions.set(t,()=>{i(),o()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}loadFeatures({children:t,...n},r,i,o){let s,l;for(let a=0;athis.scheduleRender(),animationType:typeof u=="string"?u:"both",initialPromotionConfig:o,layoutScroll:d,layoutRoot:h})}return l}updateFeatures(){for(const t in this.features){const n=this.features[t];n.isMounted?n.update():(n.mount(),n.isMounted=!0)}}triggerBuild(){this.build(this.renderState,this.latestValues,this.options,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):ae()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}makeTargetAnimatable(t,n=!0){return this.makeTargetAnimatableFromInstance(t,this.props,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){n!==this.values.get(t)&&(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=gr(n,{owner:this}),this.addValue(t,r)),r}readValue(t){var n;return this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(n=this.getBaseTargetFromProps(this.props,t))!==null&&n!==void 0?n:this.readValueFromInstance(this.current,t,this.options)}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var n;const{initial:r}=this.props,i=typeof r=="string"||typeof r=="object"?(n=Fu(this.props,r))===null||n===void 0?void 0:n[t]:void 0;if(r&&i!==void 0)return i;const o=this.getBaseTargetFromProps(this.props,t);return o!==void 0&&!Fe(o)?o:this.initialValues[t]!==void 0&&i===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new nc),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}}class ly extends uC{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]}makeTargetAnimatableFromInstance({transition:t,transitionEnd:n,...r},{transformValues:i},o){let s=kP(r,t||{},this);if(i&&(n&&(n=i(n)),r&&(r=i(r)),s&&(s=i(s))),o){TP(this,r,s);const l=iC(this,r,s,n);n=l.transitionEnd,r=l.target}return{transition:t,transitionEnd:n,...r}}}function cC(e){return window.getComputedStyle(e)}class fC extends ly{constructor(){super(...arguments),this.type="html"}readValueFromInstance(t,n){if(Pn.has(n)){const r=Zu(n);return r&&r.default||0}else{const r=cC(t),i=(Wp(n)?r.getPropertyValue(n):r[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return Pg(t,n)}build(t,n,r,i){Mu(t,n,r,i.transformTemplate)}scrapeMotionValuesFromProps(t,n){return Ru(t,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Fe(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}renderInstance(t,n,r,i){tm(t,n,r,i)}}class dC extends ly{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Pn.has(n)){const r=Zu(n);return r&&r.default||0}return n=nm.has(n)?n:Cu(n),t.getAttribute(n)}measureInstanceViewportBox(){return ae()}scrapeMotionValuesFromProps(t,n){return im(t,n)}build(t,n,r,i){Du(t,n,r,this.isSVGTag,i.transformTemplate)}renderInstance(t,n,r,i){rm(t,n,r,i)}mount(t){this.isSVGTag=Au(t.tagName),super.mount(t)}}const hC=(e,t)=>Eu(e)?new dC(t,{enableHardwareAcceleration:!1}):new fC(t,{enableHardwareAcceleration:!0}),pC={..._P,...cS,...W2,...{layout:{ProjectionNode:qg,MeasureLayout:kg}}},nn=xw((e,t)=>Zw(e,t,pC,hC));function ay(){const e=v.useRef(!1);return Pu(()=>(e.current=!0,()=>{e.current=!1}),[]),e}function mC(){const e=ay(),[t,n]=v.useState(0),r=v.useCallback(()=>{e.current&&n(t+1)},[t]);return[v.useCallback(()=>Y.postRender(r),[r]),t]}class gC extends v.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const r=this.props.sizeRef.current;r.height=n.offsetHeight||0,r.width=n.offsetWidth||0,r.top=n.offsetTop,r.left=n.offsetLeft}return null}componentDidUpdate(){}render(){return this.props.children}}function yC({children:e,isPresent:t}){const n=v.useId(),r=v.useRef(null),i=v.useRef({width:0,height:0,top:0,left:0});return v.useInsertionEffect(()=>{const{width:o,height:s,top:l,left:a}=i.current;if(t||!r.current||!o||!s)return;r.current.dataset.motionPopId=n;const u=document.createElement("style");return document.head.appendChild(u),u.sheet&&u.sheet.insertRule(` [data-motion-pop-id="${n}"] { position: absolute !important; width: ${o}px !important; height: ${s}px !important; top: ${l}px !important; left: ${a}px !important; } `),()=>{document.head.removeChild(u)}},[t]),v.createElement(gC,{isPresent:t,childRef:r,sizeRef:i},v.cloneElement(e,{ref:r}))}const pc=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:o,mode:s})=>{const l=om(vC),a=v.useId(),u=v.useMemo(()=>({id:a,initial:t,isPresent:n,custom:i,onExitComplete:c=>{l.set(c,!0);for(const f of l.values())if(!f)return;r&&r()},register:c=>(l.set(c,!1),()=>l.delete(c))}),o?void 0:[n]);return v.useMemo(()=>{l.forEach((c,f)=>l.set(f,!1))},[n]),v.useEffect(()=>{!n&&!l.size&&r&&r()},[n]),s==="popLayout"&&(e=v.createElement(yC,{isPresent:n},e)),v.createElement(ss.Provider,{value:u},e)};function vC(){return new Map}function xC(e){return v.useEffect(()=>()=>e(),[])}const Mn=e=>e.key||"";function wC(e,t){e.forEach(n=>{const r=Mn(n);t.set(r,n)})}function SC(e){const t=[];return v.Children.forEach(e,n=>{v.isValidElement(n)&&t.push(n)}),t}const bs=({children:e,custom:t,initial:n=!0,onExitComplete:r,exitBeforeEnter:i,presenceAffectsLayout:o=!0,mode:s="sync"})=>{const l=v.useContext(ku).forceRender||mC()[0],a=ay(),u=SC(e);let c=u;const f=v.useRef(new Map).current,d=v.useRef(c),h=v.useRef(new Map).current,x=v.useRef(!0);if(Pu(()=>{x.current=!1,wC(u,h),d.current=c}),xC(()=>{x.current=!0,h.clear(),f.clear()}),x.current)return v.createElement(v.Fragment,null,c.map(p=>v.createElement(pc,{key:Mn(p),isPresent:!0,initial:n?void 0:!1,presenceAffectsLayout:o,mode:s},p)));c=[...c];const w=d.current.map(Mn),P=u.map(Mn),y=w.length;for(let p=0;p{if(P.indexOf(m)!==-1)return;const S=h.get(m);if(!S)return;const C=w.indexOf(m);let b=p;if(!b){const L=()=>{f.delete(m);const g=Array.from(h.keys()).filter(M=>!P.includes(M));if(g.forEach(M=>h.delete(M)),d.current=u.filter(M=>{const T=Mn(M);return T===m||g.includes(T)}),!f.size){if(a.current===!1)return;l(),r&&r()}};b=v.createElement(pc,{key:Mn(S),isPresent:!1,onExitComplete:L,custom:t,presenceAffectsLayout:o,mode:s},S),f.set(m,b)}c.splice(C,0,b)}),c=c.map(p=>{const m=p.key;return f.has(m)?p:v.createElement(pc,{key:Mn(p),isPresent:!0,presenceAffectsLayout:o,mode:s},p)}),v.createElement(v.Fragment,null,f.size?c:c.map(p=>v.cloneElement(p)))},uy=v.forwardRef(({slideData:e,count:t,onDragEnd:n,setIsAnimating:r,popoverDelay:i,handleNext:o,handlePrevious:s},l)=>{const a={duration:i,ease:[.45,.04,.1,.97]};return A.jsxs("div",{className:"slide-image relative h-auto w-full max-w-[936px] overflow-hidden rounded-[1.65rem] bg-slate-100",children:[A.jsxs(nn.div,{drag:"x",dragConstraints:{left:0,right:0},dragElastic:.1,onDragEnd:n,ref:l,onDragTransitionEnd:()=>r(!1),onAnimationEnd:()=>r(!1),className:"absolute bottom-0 top-0 z-[10] flex w-full flex-row items-center justify-between gap-2 px-4 text-center align-middle text-sm max-md:visible lg:hidden",children:[A.jsx("button",{className:"flex h-10 w-10 flex-shrink items-center justify-center rounded-full bg-white text-sfnavy ring-2 ring-sfprimary transition-transform enabled:hover:bg-sfprimary enabled:hover:text-white disabled:cursor-not-allowed disabled:bg-[#c9c9c9] disabled:text-white disabled:ring-0 disabled:hover:bg-[#c9c9c9]",onClick:()=>s(),disabled:!(t>1),"aria-controls":"Previous Slide",children:A.jsx(Ih,{width:22,height:22})}),A.jsx("button",{className:"flex h-10 w-10 flex-shrink items-center justify-center rounded-full bg-white text-sfnavy ring-2 ring-sfprimary transition-transform enabled:hover:bg-sfprimary enabled:hover:text-white disabled:cursor-not-allowed disabled:bg-[#c9c9c9] disabled:text-white disabled:ring-0 disabled:hover:bg-[#c9c9c9]",onClick:()=>o(),disabled:!(t{u==="center"&&r(!1)},children:e==null?void 0:e.map((u,c)=>A.jsx(uw,{shouldForceMount:!0,className:"relative w-auto min-w-fit",id:`tab-${u.id}-${u.position}`,"tab-index":-1,children:A.jsx(nn.img,{animate:{opacity:c===t-1?1:.5,scale:c===t-1?1:.8},src:u.image,ref:l,alt:u.desc,onAnimationEnd:()=>r(!1),loading:"eager"},c)},c))},"slider")})]})});uy.displayName="SlideImageAria";const cy=v.forwardRef(({slideData:e,count:t,direction:n,popoverWidth:r,dotWidth:i,convertPercentage:o,setIsAnimating:s,handleNext:l,handlePrevious:a,popoverDelay:u},c)=>{const[f,d]=v.useState(!1),h={enter:P=>({opacity:0,x:P*-60,scale:.9}),center:{opacity:1,x:0,scale:1,transition:{delay:u}},exit:P=>({opacity:0,x:P*60,scale:.9})},x={duration:.3,ease:[.45,.14,.1,.97]},w={duration:.2,ease:[.45,.14,.1,.97]};return A.jsx(bs,{custom:n,initial:!1,children:e==null?void 0:e.map((P,y)=>t===P.position&&A.jsx("div",{children:A.jsxs(nn.div,{variants:h,initial:"enter",animate:"center",exit:"exit",custom:n,transition:x,onAnimationComplete:p=>{if(p==="center")s(!1);else return null},ref:c,whileHover:{scale:1},className:"slide-popover focus visible absolute z-20 rounded-full border-2 border-transparent bg-blue-500 max-lg:hidden",style:{width:i,height:i,transformOrigin:"center",left:`${P.x}%`,top:`${P.y}%`},children:[A.jsxs(nn.button,{whileHover:{scale:1.4},onClick:()=>d(!f),className:"flex h-full w-full items-center justify-center rounded-full bg-blue-600 text-sm font-semibold text-white shadow-xl ring-2 ring-white/70 focus-within:outline-none focus-within:ring-0 focus-visible:bg-sfnavy focus-visible:ring-2 focus-visible:ring-white",tabIndex:t===P.position?0:-1,"aria-hidden":t!==P.position,"aria-label":f?`Close text description for ${P.title} tab`:`Open text description form ${P.title} tab`,children:[!f&&A.jsxs(A.Fragment,{children:[A.jsx("span",{className:"z-20",children:t}),A.jsx("span",{className:"absolute z-10 flex h-full w-full animate-ping rounded-full bg-blue-600 focus:ring-0","aria-hidden":!0})]}),f&&A.jsx(nn.span,{initial:{rotate:-20},animate:{rotate:0},className:"z-20 rounded-full focus:ring-0","aria-hidden":!0,children:A.jsx(j0,{})})]}),A.jsx(bs,{mode:"wait",children:f&&A.jsxs(nn.div,{initial:{opacity:0,scale:.7},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.7},transition:w,className:`absolute flex h-[auto] flex-col gap-3 rounded-xl bg-white/90 p-6 shadow-2xl ring-1 ring-slate-400/10 backdrop-blur-lg ${P.pointer==="tl"?"left-[25px] top-[25px]":P.pointer==="tr"?"right-[25px] top-[25px]":P.pointer==="bl"?"bottom-[25px] left-[25px]":P.pointer==="br"?"bottom-[25px] right-[25px]":P.pointer==="na"?"hidden":"left-[25px] top-[25px]"}`,style:{width:r},children:[A.jsx("h3",{className:"text-[1.2rem] text-sfnavy",children:P.title}),A.jsx("p",{className:"text-gray-800",children:P.desc}),P.hasCta==="on"&&A.jsx("div",{className:"mt-4",children:A.jsx("a",{className:"btn-primary-tour",href:P.ctaUrl??"#","aria-describedby":P.ctaTitle??"Finish tour",children:P.ctaTitle})}),A.jsxs("div",{className:"flex flex-row items-center gap-4 text-center align-middle text-sm",children:[t>1&&t&&P.hasCta!=="on"&&A.jsx("button",{className:"mt-2 flex-1 items-center rounded-full text-left align-middle font-semibold text-sfnavy underline hover:text-sfprimary",onClick:()=>a(),children:"Previous"}),tl(),children:"Next"})]})]})})]},y)},y))})});cy.displayName="SlidePopover";const PC=({slideData:e,count:t,setCount:n,theme:r})=>A.jsxs("div",{className:"visible mx-4 flex flex-col lg:hidden",children:[A.jsx("nav",{className:"my-4 h-auto w-full justify-between",children:A.jsx("ul",{className:"flex h-12 justify-center gap-3 sm:mx-0 lg:flex-col xl:gap-0",children:e==null?void 0:e.map((i,o)=>A.jsx("li",{className:"flex h-12 w-12 rounded-full bg-[#EAF5FE] ring-2 ring-sfprimary",role:"none",children:A.jsx("button",{className:`relative flex h-12 w-12 cursor-pointer flex-col items-center justify-center gap-1 overflow-hidden rounded-full font-display text-sm font-semibold text-sfnavy transition-colors hover:bg-sfprimary hover:text-white sm:gap-3 lg:flex-row lg:items-center lg:align-middle lg:text-base ${i.position===t&&"rounded-full bg-sfnavy text-white transition-transform"}`,onClick:()=>n(i.position),role:"tab","aria-controls":`tab-${i.id}-${i.position}`,"aria-label":i.title,"aria-selected":i.position===t,children:i.position},i.id)},o))})}),A.jsx(bs,{initial:!1,mode:"popLayout",children:e==null?void 0:e.map((i,o)=>t===i.position&&A.jsxs(nn.div,{initial:{opacity:0,y:-10},animate:{opacity:1,y:0},exit:{opacity:0,y:10},className:"mb-10 flex w-full columns-1 flex-col gap-4",children:[A.jsx("h3",{className:`mt-4 ${r==="light"?"text-sfnavy":"text-white"}`,children:i.title}),A.jsx("p",{className:`${r==="light"?"text-sfnavy":"text-white"}`,children:i.desc}),i.hasCta==="on"&&A.jsx("div",{className:"my-4",children:A.jsx("a",{className:"btn-primary-tour",href:i.ctaUrl??"#","aria-describedby":i.ctaTitle??"Finish tour",children:i.ctaTitle})})]},i.id))})]});function CC(){return A.jsxs("div",{className:"guided-tour-container mx-auto xl:px-8",children:[A.jsxs("div",{className:"flex flex-col items-center justify-center",children:[A.jsx("div",{className:"mx-4 mb-4 h-12 w-2/3 animate-pulse rounded-md bg-slate-200 text-center text-3xl text-sfnavy sm:mx-0 xl:text-4xl"}),A.jsx("div",{className:"mx-4 mb-10 h-8 w-2/3 animate-pulse rounded-md bg-slate-200 text-center text-3xl text-sfnavy sm:mx-0 xl:text-4xl"})]}),A.jsxs("section",{className:"flex columns-1 flex-col gap-4 lg:columns-2 lg:flex-row lg:gap-8",children:[A.jsx("nav",{className:"visible flex w-full flex-col justify-between max-lg:hidden lg:basis-3/12",children:A.jsxs("ul",{className:" flex justify-stretch gap-1 sm:mx-0 lg:flex-col xl:gap-3",children:[A.jsx("li",{className:"first-line:text-sfnavy-800 relative box-border flex h-16 w-full animate-pulse flex-col gap-1 overflow-hidden rounded-md bg-slate-200 py-[1.3rem] font-display text-sm font-semibold text-sfnavy transition-all hover:text-sfprimary sm:gap-3 lg:flex-row lg:items-center lg:align-middle lg:text-base"}),A.jsx("li",{className:"first-line:text-sfnavy-800 relative box-border flex h-16 w-full animate-pulse flex-col gap-1 overflow-hidden rounded-md bg-slate-200 py-[1.3rem] font-display text-sm font-semibold text-sfnavy transition-all hover:text-sfprimary sm:gap-3 lg:flex-row lg:items-center lg:align-middle lg:text-base"}),A.jsx("li",{className:"first-line:text-sfnavy-800 relative box-border flex h-16 w-full animate-pulse flex-col gap-1 overflow-hidden rounded-md bg-slate-200 py-[1.3rem] font-display text-sm font-semibold text-sfnavy transition-all hover:text-sfprimary sm:gap-3 lg:flex-row lg:items-center lg:align-middle lg:text-base"})]})}),A.jsx("div",{className:"relative h-full lg:basis-9/12",children:A.jsx("div",{className:"relative aspect-video h-full w-full max-w-[936px] animate-pulse overflow-hidden rounded-md bg-slate-200 transition-all"})})]})]})}const TC=({title:e,tourId:t,theme:n,copy:r})=>{var R;const[i,o]=v.useState(1),[s,l]=v.useState(!1),a=384,u=32,c=.5,f=v.useRef(null),[d,h]=v.useState((R=f.current)==null?void 0:R.clientHeight),[x,w]=v.useState(0),[P,y]=v.useState(0),[p,m]=v.useState(0),[S,C]=v.useState(0),b=k(i),L=b!==null&&i>b?1:-1,g=v.useRef(null),[M,T]=v.useState(null),[E,I]=v.useState("");v.useEffect(()=>{$()},[]);const $=async()=>{try{const V=`//wps-guided-tours-cd2869867e18.herokuapp.com/api/tours/${t}`,_=await fetch(V);if(console.log(_),!_.ok)throw new Error(`HTTP error! status: ${_.status}`);const re=await _.json();console.log("Data:",re),I(re.orientation),T(re.slides)}catch(V){console.error("Error fetching slide data:",V)}};v.useEffect(()=>{var _,re;m((_=g.current)==null?void 0:_.clientWidth),C((re=g.current)==null?void 0:re.clientHeight);const V=()=>{var he,Ve,pe;h((he=f.current)==null?void 0:he.clientHeight),w((Ve=g.current)==null?void 0:Ve.clientWidth),y((pe=g.current)==null?void 0:pe.clientHeight),console.log(P)};return V(),window.addEventListener("resize",V),()=>{var he,Ve;m((he=g.current)==null?void 0:he.clientWidth),C((Ve=g.current)==null?void 0:Ve.clientHeight),window.removeEventListener("resize",V)}},[d,i,p,S,P]);function k(V){let[_,re]=v.useState([null,V]);return _[1]!==V&&re([_[1],V]),_[0]}function z(){s||(l(!0),o(i+1))}function U(){s||(l(!0),o(i-1))}function N(V){let re=V.toString().slice(-1);o(+re)}function F(V,_){let re=p-a/2,he=S-d/2,Ve=V/100*re,pe=_/100*he;return[Ve,pe]}function j(V,_){_.offset.xx/3&&i!==1?(l(!0),o(i-1)):console.log(V)}return M?A.jsxs("div",{className:"guided-tour-container mx-auto xl:px-8",children:[e!==""&&A.jsx("h2",{className:`mx-4 text-center text-3xl ${n==="light"?"text-sfnavy":"text-white"} ${r!==""?"mb-6":"mb-12"} sm:mx-0 xl:text-[32px]`,children:e}),r!==""&&A.jsx("div",{className:"blade__description mx-auto mb-14 flex w-3/4 items-center justify-center",children:A.jsx("p",{className:`text-center text-[18px] ${n==="light"?"text-sfdarygrey":"text-white"}`,children:r})}),A.jsx("section",{children:A.jsxs(nw,{orientation:"vertical",keyboardActivation:"manual",onSelectionChange:V=>{N(V)},className:`flex columns-1 flex-col gap-4 lg:columns-2 lg:gap-8 ${E==="right"?"lg:flex-row":E==="left"?"lg:flex-row-reverse":"lg:flex-row"}`,children:[A.jsx(cw,{title:e,slideData:M,setCount:o,count:i,handleNext:z,handlePrevious:U,theme:n}),A.jsxs("div",{className:"relative h-auto w-full lg:basis-9/12",children:[A.jsx(cy,{slideData:M,count:i,direction:L,popoverWidth:a,dotWidth:u,convertPercentage:F,ref:f,setIsAnimating:l,handleNext:z,handlePrevious:U,popoverDelay:c}),A.jsx(uy,{slideData:M,ref:g,count:i,onDragEnd:j,setIsAnimating:l,popoverDelay:c,handleNext:z,handlePrevious:U})]}),A.jsx(PC,{slideData:M,count:i,setCount:o,handleNext:z,handlePrevious:U,theme:n})]})})]}):A.jsx(CC,{})};function $C(){document.querySelectorAll('[data-mwo-widget="guided-tour"]').forEach(t=>{const n=t.getAttribute("data-title")||"",r=t.getAttribute("data-theme")||"",i=t.getAttribute("data-copy")||"",o=t.getAttribute("data-tour-id")||"";Kh.render(A.jsx(B.StrictMode,{children:A.jsx(TC,{title:n,theme:r,copy:i,tourId:o})}),t)})}document.addEventListener("DOMContentLoaded",$C)});