(function(K){typeof define=="function"&&define.amd?define(K):K()})(function(){"use strict";var AC=Object.defineProperty,SC=Object.defineProperties;var xC=Object.getOwnPropertyDescriptors;var Ws=Object.getOwnPropertySymbols;var gh=Object.prototype.hasOwnProperty,bh=Object.prototype.propertyIsEnumerable;var iu=Math.pow,yh=(K,ae,te)=>ae in K?AC(K,ae,{enumerable:!0,configurable:!0,writable:!0,value:te}):K[ae]=te,I=(K,ae)=>{for(var te in ae||(ae={}))gh.call(ae,te)&&yh(K,te,ae[te]);if(Ws)for(var te of Ws(ae))bh.call(ae,te)&&yh(K,te,ae[te]);return K},q=(K,ae)=>SC(K,xC(ae));var je=(K,ae)=>{var te={};for(var Me in K)gh.call(K,Me)&&ae.indexOf(Me)<0&&(te[Me]=K[Me]);if(K!=null&&Ws)for(var Me of Ws(K))ae.indexOf(Me)<0&&bh.call(K,Me)&&(te[Me]=K[Me]);return te};function K(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ae={exports:{}},te={},Me={exports:{}},U={};/** * @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 rn=Symbol.for("react.element"),vh=Symbol.for("react.portal"),Th=Symbol.for("react.fragment"),Ch=Symbol.for("react.strict_mode"),Ah=Symbol.for("react.profiler"),Sh=Symbol.for("react.provider"),xh=Symbol.for("react.context"),Ih=Symbol.for("react.forward_ref"),Lh=Symbol.for("react.suspense"),Dh=Symbol.for("react.memo"),Eh=Symbol.for("react.lazy"),ou=Symbol.iterator;function wh(e){return e===null||typeof e!="object"?null:(e=ou&&e[ou]||e["@@iterator"],typeof e=="function"?e:null)}var uu={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},cu=Object.assign,du={};function vr(e,t,r){this.props=e,this.context=t,this.refs=du,this.updater=r||uu}vr.prototype.isReactComponent={},vr.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")},vr.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function mu(){}mu.prototype=vr.prototype;function Gs(e,t,r){this.props=e,this.context=t,this.refs=du,this.updater=r||uu}var Hs=Gs.prototype=new mu;Hs.constructor=Gs,cu(Hs,vr.prototype),Hs.isPureReactComponent=!0;var pu=Array.isArray,fu=Object.prototype.hasOwnProperty,Ks={current:null},hu={key:!0,ref:!0,__self:!0,__source:!0};function yu(e,t,r){var n,a={},s=null,l=null;if(t!=null)for(n in t.ref!==void 0&&(l=t.ref),t.key!==void 0&&(s=""+t.key),t)fu.call(t,n)&&!hu.hasOwnProperty(n)&&(a[n]=t[n]);var i=arguments.length-2;if(i===1)a.children=r;else if(1>>1,oe=D[J];if(0>>1;Ja(lu,P))bra($s,lu)?(D[J]=$s,D[br]=P,J=br):(D[J]=lu,D[gr]=P,J=gr);else if(bra($s,P))D[J]=$s,D[br]=P,J=br;else break e}}return N}function a(D,N){var P=D.sortIndex-N.sortIndex;return P!==0?P:D.id-N.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;e.unstable_now=function(){return s.now()}}else{var l=Date,i=l.now();e.unstable_now=function(){return l.now()-i}}var o=[],u=[],c=1,d=null,m=3,y=!1,g=!1,b=!1,C=typeof setTimeout=="function"?setTimeout:null,f=typeof clearTimeout=="function"?clearTimeout:null,p=typeof setImmediate!="undefined"?setImmediate:null;typeof navigator!="undefined"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function h(D){for(var N=r(u);N!==null;){if(N.callback===null)n(u);else if(N.startTime<=D)n(u),N.sortIndex=N.expirationTime,t(o,N);else break;N=r(u)}}function v(D){if(b=!1,h(D),!g)if(r(o)!==null)g=!0,qe(T);else{var N=r(u);N!==null&&yr(v,N.startTime-D)}}function T(D,N){g=!1,b&&(b=!1,f(S),S=-1),y=!0;var P=m;try{for(h(N),d=r(o);d!==null&&(!(d.expirationTime>N)||D&&!ie());){var J=d.callback;if(typeof J=="function"){d.callback=null,m=d.priorityLevel;var oe=J(d.expirationTime<=N);N=e.unstable_now(),typeof oe=="function"?d.callback=oe:d===r(o)&&n(o),h(N)}else n(o);d=r(o)}if(d!==null)var Zs=!0;else{var gr=r(u);gr!==null&&yr(v,gr.startTime-N),Zs=!1}return Zs}finally{d=null,m=P,y=!1}}var x=!1,L=null,S=-1,O=5,B=-1;function ie(){return!(e.unstable_now()-BD||125J?(D.sortIndex=P,t(u,D),r(o)===null&&D===r(u)&&(b?(f(S),S=-1):b=!0,yr(v,P-J))):(D.sortIndex=oe,t(o,D),g||y||(g=!0,qe(T))),D},e.unstable_shouldYield=ie,e.unstable_wrapCallback=function(D){var N=m;return function(){var P=m;m=N;try{return D.apply(this,arguments)}finally{m=P}}}})(Au),Cu.exports=Au;var Fh=Cu.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 _h=w,Ne=Fh;function A(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;rt}return!1}function Ae(e,t,r,n,a,s,l){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=n,this.attributeNamespace=a,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=l}var ue={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){ue[e]=new Ae(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];ue[t]=new Ae(t,1,!1,e[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(e){ue[e]=new Ae(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){ue[e]=new Ae(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){ue[e]=new Ae(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(e){ue[e]=new Ae(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(function(e){ue[e]=new Ae(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(function(e){ue[e]=new Ae(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(function(e){ue[e]=new Ae(e,5,!1,e.toLowerCase(),null,!1,!1)});var el=/[\-:]([a-z])/g;function tl(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(el,tl);ue[t]=new Ae(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(el,tl);ue[t]=new Ae(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(el,tl);ue[t]=new Ae(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(e){ue[e]=new Ae(e,1,!1,e.toLowerCase(),null,!1,!1)}),ue.xlinkHref=new Ae("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(e){ue[e]=new Ae(e,1,!1,e.toLowerCase(),null,!0,!0)});function rl(e,t,r,n){var a=ue.hasOwnProperty(t)?ue[t]:null;(a!==null?a.type!==0:n||!(2i||a[l]!==s[i]){var o=` `+a[l].replace(" at new "," at ");return e.displayName&&o.includes("")&&(o=o.replace("",e.displayName)),o}while(1<=l&&0<=i);break}}}finally{cl=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?sn(e):""}function Gh(e){switch(e.tag){case 5:return sn(e.type);case 16:return sn("Lazy");case 13:return sn("Suspense");case 19:return sn("SuspenseList");case 0:case 2:case 15:return e=dl(e.type,!1),e;case 11:return e=dl(e.type.render,!1),e;case 1:return e=dl(e.type,!0),e;default:return""}}function ml(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 Ar:return"Fragment";case Cr:return"Portal";case al:return"Profiler";case nl:return"StrictMode";case ll:return"Suspense";case il:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Du:return(e.displayName||"Context")+".Consumer";case Lu:return(e._context.displayName||"Context")+".Provider";case sl:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ol:return t=e.displayName||null,t!==null?t:ml(e.type)||"Memo";case At:t=e._payload,e=e._init;try{return ml(e(t))}catch(r){}}return null}function Hh(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 ml(t);case 8:return t===nl?"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 St(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function ju(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Kh(e){var t=ju(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),n=""+e[t];if(!e.hasOwnProperty(t)&&typeof r!="undefined"&&typeof r.get=="function"&&typeof r.set=="function"){var a=r.get,s=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return a.call(this)},set:function(l){n=""+l,s.call(this,l)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(l){n=""+l},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function fa(e){e._valueTracker||(e._valueTracker=Kh(e))}function Bu(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),n="";return e&&(n=ju(e)?e.checked?"true":"false":e.value),e=n,e!==r?(t.setValue(e),!0):!1}function ha(e){if(e=e||(typeof document!="undefined"?document:void 0),typeof e=="undefined")return null;try{return e.activeElement||e.body}catch(t){return e.body}}function pl(e,t){var r=t.checked;return $({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r!=null?r:e._wrapperState.initialChecked})}function Nu(e,t){var r=t.defaultValue==null?"":t.defaultValue,n=t.checked!=null?t.checked:t.defaultChecked;r=St(t.value!=null?t.value:r),e._wrapperState={initialChecked:n,initialValue:r,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Pu(e,t){t=t.checked,t!=null&&rl(e,"checked",t,!1)}function fl(e,t){Pu(e,t);var r=St(t.value),n=t.type;if(r!=null)n==="number"?(r===0&&e.value===""||e.value!=r)&&(e.value=""+r):e.value!==""+r&&(e.value=""+r);else if(n==="submit"||n==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?hl(e,t.type,r):t.hasOwnProperty("defaultValue")&&hl(e,t.type,St(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Uu(e,t,r){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var n=t.type;if(!(n!=="submit"&&n!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,r||t===e.value||(e.value=t),e.defaultValue=t}r=e.name,r!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,r!==""&&(e.name=r)}function hl(e,t,r){(t!=="number"||ha(e.ownerDocument)!==e)&&(r==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}var ln=Array.isArray;function Sr(e,t,r,n){if(e=e.options,t){t={};for(var a=0;a"+t.valueOf().toString()+"",t=ya.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function on(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var un={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},Qh=["Webkit","ms","Moz","O"];Object.keys(un).forEach(function(e){Qh.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),un[t]=un[e]})});function zu(e,t,r){return t==null||typeof t=="boolean"||t===""?"":r||typeof t!="number"||t===0||un.hasOwnProperty(e)&&un[e]?(""+t).trim():t+"px"}function Fu(e,t){e=e.style;for(var r in t)if(t.hasOwnProperty(r)){var n=r.indexOf("--")===0,a=zu(r,t[r],n);r==="float"&&(r="cssFloat"),n?e.setProperty(r,a):e[r]=a}}var Yh=$({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 bl(e,t){if(t){if(Yh[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(A(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(A(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(A(61))}if(t.style!=null&&typeof t.style!="object")throw Error(A(62))}}function vl(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 Tl=null;function Cl(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Al=null,xr=null,Ir=null;function _u(e){if(e=Bn(e)){if(typeof Al!="function")throw Error(A(280));var t=e.stateNode;t&&(t=Ma(t),Al(e.stateNode,e.type,t))}}function Vu(e){xr?Ir?Ir.push(e):Ir=[e]:xr=e}function Zu(){if(xr){var e=xr,t=Ir;if(Ir=xr=null,_u(e),t)for(e=0;e>>=0,e===0?32:31-(oy(e)/uy|0)|0}var Ca=64,Aa=4194304;function pn(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 Sa(e,t){var r=e.pendingLanes;if(r===0)return 0;var n=0,a=e.suspendedLanes,s=e.pingedLanes,l=r&268435455;if(l!==0){var i=l&~a;i!==0?n=pn(i):(s&=l,s!==0&&(n=pn(s)))}else l=r&~a,l!==0?n=pn(l):s!==0&&(n=pn(s));if(n===0)return 0;if(t!==0&&t!==n&&!(t&a)&&(a=n&-n,s=t&-t,a>=s||a===16&&(s&4194240)!==0))return t;if(n&4&&(n|=r&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=n;0r;r++)t.push(e);return t}function fn(e,t,r){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-He(t),e[t]=r}function py(e,t){var r=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 n=e.eventTimes;for(e=e.expirationTimes;0=An),bc=" ",vc=!1;function Tc(e,t){switch(e){case"keyup":return Fy.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Cc(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Er=!1;function Vy(e,t){switch(e){case"compositionend":return Cc(t);case"keypress":return t.which!==32?null:(vc=!0,bc);case"textInput":return e=t.data,e===bc&&vc?null:e;default:return null}}function Zy(e,t){if(Er)return e==="compositionend"||!zl&&Tc(e,t)?(e=mc(),Ea=Ul=Et=null,Er=!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:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=Ec(r)}}function jc(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?jc(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Bc(){for(var e=window,t=ha();t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch(n){r=!1}if(r)e=t.contentWindow;else break;t=ha(e.document)}return t}function Vl(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 Jy(e){var t=Bc(),r=e.focusedElem,n=e.selectionRange;if(t!==r&&r&&r.ownerDocument&&jc(r.ownerDocument.documentElement,r)){if(n!==null&&Vl(r)){if(t=n.start,e=n.end,e===void 0&&(e=t),"selectionStart"in r)r.selectionStart=t,r.selectionEnd=Math.min(e,r.value.length);else if(e=(t=r.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var a=r.textContent.length,s=Math.min(n.start,a);n=n.end===void 0?s:Math.min(n.end,a),!e.extend&&s>n&&(a=n,n=s,s=a),a=wc(r,s);var l=wc(r,n);a&&l&&(e.rangeCount!==1||e.anchorNode!==a.node||e.anchorOffset!==a.offset||e.focusNode!==l.node||e.focusOffset!==l.offset)&&(t=t.createRange(),t.setStart(a.node,a.offset),e.removeAllRanges(),s>n?(e.addRange(t),e.extend(l.node,l.offset)):(t.setEnd(l.node,l.offset),e.addRange(t)))}}for(t=[],e=r;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r=document.documentMode,wr=null,Zl=null,Ln=null,$l=!1;function Nc(e,t,r){var n=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;$l||wr==null||wr!==ha(n)||(n=wr,"selectionStart"in n&&Vl(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),Ln&&In(Ln,n)||(Ln=n,n=ka(Zl,"onSelect"),0Ur||(e.current=ni[Ur],ni[Ur]=null,Ur--)}function F(e,t){Ur++,ni[Ur]=e.current,e.current=t}var Nt={},fe=Bt(Nt),Ie=Bt(!1),Jt=Nt;function Or(e,t){var r=e.type.contextTypes;if(!r)return Nt;var n=e.stateNode;if(n&&n.__reactInternalMemoizedUnmaskedChildContext===t)return n.__reactInternalMemoizedMaskedChildContext;var a={},s;for(s in r)a[s]=t[s];return n&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=a),a}function Le(e){return e=e.childContextTypes,e!=null}function za(){V(Ie),V(fe)}function Gc(e,t,r){if(fe.current!==Nt)throw Error(A(168));F(fe,t),F(Ie,r)}function Hc(e,t,r){var n=e.stateNode;if(t=t.childContextTypes,typeof n.getChildContext!="function")return r;n=n.getChildContext();for(var a in n)if(!(a in t))throw Error(A(108,Hh(e)||"Unknown",a));return $({},r,n)}function Fa(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Nt,Jt=fe.current,F(fe,e),F(Ie,Ie.current),!0}function Kc(e,t,r){var n=e.stateNode;if(!n)throw Error(A(169));r?(e=Hc(e,t,Jt),n.__reactInternalMemoizedMergedChildContext=e,V(Ie),V(fe),F(fe,e)):V(Ie),F(Ie,r)}var ct=null,_a=!1,ai=!1;function Qc(e){ct===null?ct=[e]:ct.push(e)}function dg(e){_a=!0,Qc(e)}function Pt(){if(!ai&&ct!==null){ai=!0;var e=0,t=M;try{var r=ct;for(M=1;e>=l,a-=l,dt=1<<32-He(t)+a|r<S?(O=L,L=null):O=L.sibling;var B=m(f,L,h[S],v);if(B===null){L===null&&(L=O);break}e&&L&&B.alternate===null&&t(f,L),p=s(B,p,S),x===null?T=B:x.sibling=B,x=B,L=O}if(S===h.length)return r(f,L),Z&&tr(f,S),T;if(L===null){for(;SS?(O=L,L=null):O=L.sibling;var ie=m(f,L,B.value,v);if(ie===null){L===null&&(L=O);break}e&&L&&ie.alternate===null&&t(f,L),p=s(ie,p,S),x===null?T=ie:x.sibling=ie,x=ie,L=O}if(B.done)return r(f,L),Z&&tr(f,S),T;if(L===null){for(;!B.done;S++,B=h.next())B=d(f,B.value,v),B!==null&&(p=s(B,p,S),x===null?T=B:x.sibling=B,x=B);return Z&&tr(f,S),T}for(L=n(f,L);!B.done;S++,B=h.next())B=y(L,f,S,B.value,v),B!==null&&(e&&B.alternate!==null&&L.delete(B.key===null?S:B.key),p=s(B,p,S),x===null?T=B:x.sibling=B,x=B);return e&&L.forEach(function(Kt){return t(f,Kt)}),Z&&tr(f,S),T}function C(f,p,h,v){if(typeof h=="object"&&h!==null&&h.type===Ar&&h.key===null&&(h=h.props.children),typeof h=="object"&&h!==null){switch(h.$$typeof){case pa:e:{for(var T=h.key,x=p;x!==null;){if(x.key===T){if(T=h.type,T===Ar){if(x.tag===7){r(f,x.sibling),p=a(x,h.props.children),p.return=f,f=p;break e}}else if(x.elementType===T||typeof T=="object"&&T!==null&&T.$$typeof===At&&rd(T)===x.type){r(f,x.sibling),p=a(x,h.props),p.ref=Nn(f,x,h),p.return=f,f=p;break e}r(f,x);break}else t(f,x);x=x.sibling}h.type===Ar?(p=ur(h.props.children,f.mode,v,h.key),p.return=f,f=p):(v=ys(h.type,h.key,h.props,null,f.mode,v),v.ref=Nn(f,p,h),v.return=f,f=v)}return l(f);case Cr:e:{for(x=h.key;p!==null;){if(p.key===x)if(p.tag===4&&p.stateNode.containerInfo===h.containerInfo&&p.stateNode.implementation===h.implementation){r(f,p.sibling),p=a(p,h.children||[]),p.return=f,f=p;break e}else{r(f,p);break}else t(f,p);p=p.sibling}p=to(h,f.mode,v),p.return=f,f=p}return l(f);case At:return x=h._init,C(f,p,x(h._payload),v)}if(ln(h))return g(f,p,h,v);if(an(h))return b(f,p,h,v);Wa(f,h)}return typeof h=="string"&&h!==""||typeof h=="number"?(h=""+h,p!==null&&p.tag===6?(r(f,p.sibling),p=a(p,h),p.return=f,f=p):(r(f,p),p=eo(h,f.mode,v),p.return=f,f=p),l(f)):r(f,p)}return C}var Mr=nd(!0),ad=nd(!1),Ga=Bt(null),Ha=null,zr=null,ci=null;function di(){ci=zr=Ha=null}function mi(e){var t=Ga.current;V(Ga),e._currentValue=t}function pi(e,t,r){for(;e!==null;){var n=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,n!==null&&(n.childLanes|=t)):n!==null&&(n.childLanes&t)!==t&&(n.childLanes|=t),e===r)break;e=e.return}}function Fr(e,t){Ha=e,ci=zr=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(De=!0),e.firstContext=null)}function _e(e){var t=e._currentValue;if(ci!==e)if(e={context:e,memoizedValue:t,next:null},zr===null){if(Ha===null)throw Error(A(308));zr=e,Ha.dependencies={lanes:0,firstContext:e}}else zr=zr.next=e;return t}var rr=null;function fi(e){rr===null?rr=[e]:rr.push(e)}function sd(e,t,r,n){var a=t.interleaved;return a===null?(r.next=r,fi(t)):(r.next=a.next,a.next=r),t.interleaved=r,pt(e,n)}function pt(e,t){e.lanes|=t;var r=e.alternate;for(r!==null&&(r.lanes|=t),r=e,e=e.return;e!==null;)e.childLanes|=t,r=e.alternate,r!==null&&(r.childLanes|=t),r=e,e=e.return;return r.tag===3?r.stateNode:null}var Ut=!1;function hi(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function ld(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 ft(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Ot(e,t,r){var n=e.updateQueue;if(n===null)return null;if(n=n.shared,R&2){var a=n.pending;return a===null?t.next=t:(t.next=a.next,a.next=t),n.pending=t,pt(e,r)}return a=n.interleaved,a===null?(t.next=t,fi(n)):(t.next=a.next,a.next=t),n.interleaved=t,pt(e,r)}function Ka(e,t,r){if(t=t.updateQueue,t!==null&&(t=t.shared,(r&4194240)!==0)){var n=t.lanes;n&=e.pendingLanes,r|=n,t.lanes=r,wl(e,r)}}function id(e,t){var r=e.updateQueue,n=e.alternate;if(n!==null&&(n=n.updateQueue,r===n)){var a=null,s=null;if(r=r.firstBaseUpdate,r!==null){do{var l={eventTime:r.eventTime,lane:r.lane,tag:r.tag,payload:r.payload,callback:r.callback,next:null};s===null?a=s=l:s=s.next=l,r=r.next}while(r!==null);s===null?a=s=t:s=s.next=t}else a=s=t;r={baseState:n.baseState,firstBaseUpdate:a,lastBaseUpdate:s,shared:n.shared,effects:n.effects},e.updateQueue=r;return}e=r.lastBaseUpdate,e===null?r.firstBaseUpdate=t:e.next=t,r.lastBaseUpdate=t}function Qa(e,t,r,n){var a=e.updateQueue;Ut=!1;var s=a.firstBaseUpdate,l=a.lastBaseUpdate,i=a.shared.pending;if(i!==null){a.shared.pending=null;var o=i,u=o.next;o.next=null,l===null?s=u:l.next=u,l=o;var c=e.alternate;c!==null&&(c=c.updateQueue,i=c.lastBaseUpdate,i!==l&&(i===null?c.firstBaseUpdate=u:i.next=u,c.lastBaseUpdate=o))}if(s!==null){var d=a.baseState;l=0,c=u=o=null,i=s;do{var m=i.lane,y=i.eventTime;if((n&m)===m){c!==null&&(c=c.next={eventTime:y,lane:0,tag:i.tag,payload:i.payload,callback:i.callback,next:null});e:{var g=e,b=i;switch(m=t,y=r,b.tag){case 1:if(g=b.payload,typeof g=="function"){d=g.call(y,d,m);break e}d=g;break e;case 3:g.flags=g.flags&-65537|128;case 0:if(g=b.payload,m=typeof g=="function"?g.call(y,d,m):g,m==null)break e;d=$({},d,m);break e;case 2:Ut=!0}}i.callback!==null&&i.lane!==0&&(e.flags|=64,m=a.effects,m===null?a.effects=[i]:m.push(i))}else y={eventTime:y,lane:m,tag:i.tag,payload:i.payload,callback:i.callback,next:null},c===null?(u=c=y,o=d):c=c.next=y,l|=m;if(i=i.next,i===null){if(i=a.shared.pending,i===null)break;m=i,i=m.next,m.next=null,a.lastBaseUpdate=m,a.shared.pending=null}}while(!0);if(c===null&&(o=d),a.baseState=o,a.firstBaseUpdate=u,a.lastBaseUpdate=c,t=a.shared.interleaved,t!==null){a=t;do l|=a.lane,a=a.next;while(a!==t)}else s===null&&(a.shared.lanes=0);sr|=l,e.lanes=l,e.memoizedState=d}}function od(e,t,r){if(e=t.effects,t.effects=null,e!==null)for(t=0;tr?r:4,e(!0);var n=Ti.transition;Ti.transition={};try{e(!1),t()}finally{M=r,Ti.transition=n}}function Dd(){return Ve().memoizedState}function hg(e,t,r){var n=Mt(e);if(r={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null},Ed(e))wd(t,r);else if(r=sd(e,t,r,n),r!==null){var a=xe();et(r,e,n,a),jd(r,t,n)}}function yg(e,t,r){var n=Mt(e),a={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null};if(Ed(e))wd(t,a);else{var s=e.alternate;if(e.lanes===0&&(s===null||s.lanes===0)&&(s=t.lastRenderedReducer,s!==null))try{var l=t.lastRenderedState,i=s(l,r);if(a.hasEagerState=!0,a.eagerState=i,Ke(i,l)){var o=t.interleaved;o===null?(a.next=a,fi(t)):(a.next=o.next,o.next=a),t.interleaved=a;return}}catch(u){}finally{}r=sd(e,t,a,n),r!==null&&(a=xe(),et(r,e,n,a),jd(r,t,n))}}function Ed(e){var t=e.alternate;return e===G||t!==null&&t===G}function wd(e,t){kn=Ja=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function jd(e,t,r){if(r&4194240){var n=t.lanes;n&=e.pendingLanes,r|=n,t.lanes=r,wl(e,r)}}var rs={readContext:_e,useCallback:he,useContext:he,useEffect:he,useImperativeHandle:he,useInsertionEffect:he,useLayoutEffect:he,useMemo:he,useReducer:he,useRef:he,useState:he,useDebugValue:he,useDeferredValue:he,useTransition:he,useMutableSource:he,useSyncExternalStore:he,useId:he,unstable_isNewReconciler:!1},gg={readContext:_e,useCallback:function(e,t){return at().memoizedState=[e,t===void 0?null:t],e},useContext:_e,useEffect:vd,useImperativeHandle:function(e,t,r){return r=r!=null?r.concat([e]):null,es(4194308,4,Ad.bind(null,t,e),r)},useLayoutEffect:function(e,t){return es(4194308,4,e,t)},useInsertionEffect:function(e,t){return es(4,2,e,t)},useMemo:function(e,t){var r=at();return t=t===void 0?null:t,e=e(),r.memoizedState=[e,t],e},useReducer:function(e,t,r){var n=at();return t=r!==void 0?r(t):t,n.memoizedState=n.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},n.queue=e,e=e.dispatch=hg.bind(null,G,e),[n.memoizedState,e]},useRef:function(e){var t=at();return e={current:e},t.memoizedState=e},useState:gd,useDebugValue:Di,useDeferredValue:function(e){return at().memoizedState=e},useTransition:function(){var e=gd(!1),t=e[0];return e=fg.bind(null,e[1]),at().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var n=G,a=at();if(Z){if(r===void 0)throw Error(A(407));r=r()}else{if(r=t(),le===null)throw Error(A(349));ar&30||md(n,t,r)}a.memoizedState=r;var s={value:r,getSnapshot:t};return a.queue=s,vd(fd.bind(null,n,s,e),[e]),n.flags|=2048,Mn(9,pd.bind(null,n,s,r,t),void 0,null),r},useId:function(){var e=at(),t=le.identifierPrefix;if(Z){var r=mt,n=dt;r=(n&~(1<<32-He(n)-1)).toString(32)+r,t=":"+t+"R"+r,r=Rn++,0<\/script>",e=e.removeChild(e.firstChild)):typeof n.is=="string"?e=l.createElement(r,{is:n.is}):(e=l.createElement(r),r==="select"&&(l=e,n.multiple?l.multiple=!0:n.size&&(l.size=n.size))):e=l.createElementNS(e,r),e[rt]=t,e[jn]=n,Qd(e,t,!1,!1),t.stateNode=e;e:{switch(l=vl(r,n),r){case"dialog":_("cancel",e),_("close",e),a=n;break;case"iframe":case"object":case"embed":_("load",e),a=n;break;case"video":case"audio":for(a=0;aWr&&(t.flags|=128,n=!0,zn(s,!1),t.lanes=4194304)}else{if(!n)if(e=Ya(l),e!==null){if(t.flags|=128,n=!0,r=e.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),zn(s,!0),s.tail===null&&s.tailMode==="hidden"&&!l.alternate&&!Z)return ye(t),null}else 2*Y()-s.renderingStartTime>Wr&&r!==1073741824&&(t.flags|=128,n=!0,zn(s,!1),t.lanes=4194304);s.isBackwards?(l.sibling=t.child,t.child=l):(r=s.last,r!==null?r.sibling=l:t.child=l,s.last=l)}return s.tail!==null?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=Y(),t.sibling=null,r=W.current,F(W,n?r&1|2:r&1),t):(ye(t),null);case 22:case 23:return Yi(),n=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==n&&(t.flags|=8192),n&&t.mode&1?ke&1073741824&&(ye(t),t.subtreeFlags&6&&(t.flags|=8192)):ye(t),null;case 24:return null;case 25:return null}throw Error(A(156,t.tag))}function Ig(e,t){switch(li(t),t.tag){case 1:return Le(t.type)&&za(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return _r(),V(Ie),V(fe),vi(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return gi(t),null;case 13:if(V(W),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(A(340));qr()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return V(W),null;case 4:return _r(),null;case 10:return mi(t.type._context),null;case 22:case 23:return Yi(),null;case 24:return null;default:return null}}var ls=!1,ge=!1,Lg=typeof WeakSet=="function"?WeakSet:Set,E=null;function Zr(e,t){var r=e.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(n){Q(e,t,n)}else r.current=null}function Mi(e,t,r){try{r()}catch(n){Q(e,t,n)}}var Jd=!1;function Dg(e,t){if(Yl=La,e=Bc(),Vl(e)){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{r=(r=e.ownerDocument)&&r.defaultView||window;var n=r.getSelection&&r.getSelection();if(n&&n.rangeCount!==0){r=n.anchorNode;var a=n.anchorOffset,s=n.focusNode;n=n.focusOffset;try{r.nodeType,s.nodeType}catch(v){r=null;break e}var l=0,i=-1,o=-1,u=0,c=0,d=e,m=null;t:for(;;){for(var y;d!==r||a!==0&&d.nodeType!==3||(i=l+a),d!==s||n!==0&&d.nodeType!==3||(o=l+n),d.nodeType===3&&(l+=d.nodeValue.length),(y=d.firstChild)!==null;)m=d,d=y;for(;;){if(d===e)break t;if(m===r&&++u===a&&(i=l),m===s&&++c===n&&(o=l),(y=d.nextSibling)!==null)break;d=m,m=d.parentNode}d=y}r=i===-1||o===-1?null:{start:i,end:o}}else r=null}r=r||{start:0,end:0}}else r=null;for(Xl={focusedElem:e,selectionRange:r},La=!1,E=t;E!==null;)if(t=E,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,E=e;else for(;E!==null;){t=E;try{var g=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(g!==null){var b=g.memoizedProps,C=g.memoizedState,f=t.stateNode,p=f.getSnapshotBeforeUpdate(t.elementType===t.type?b:Ye(t.type,b),C);f.__reactInternalSnapshotBeforeUpdate=p}break;case 3:var h=t.stateNode.containerInfo;h.nodeType===1?h.textContent="":h.nodeType===9&&h.documentElement&&h.removeChild(h.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(A(163))}}catch(v){Q(t,t.return,v)}if(e=t.sibling,e!==null){e.return=t.return,E=e;break}E=t.return}return g=Jd,Jd=!1,g}function Fn(e,t,r){var n=t.updateQueue;if(n=n!==null?n.lastEffect:null,n!==null){var a=n=n.next;do{if((a.tag&e)===e){var s=a.destroy;a.destroy=void 0,s!==void 0&&Mi(t,r,s)}a=a.next}while(a!==n)}}function is(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var r=t=t.next;do{if((r.tag&e)===e){var n=r.create;r.destroy=n()}r=r.next}while(r!==t)}}function zi(e){var t=e.ref;if(t!==null){var r=e.stateNode;switch(e.tag){case 5:e=r;break;default:e=r}typeof t=="function"?t(e):t.current=e}}function em(e){var t=e.alternate;t!==null&&(e.alternate=null,em(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[rt],delete t[jn],delete t[ri],delete t[ug],delete t[cg])),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 tm(e){return e.tag===5||e.tag===3||e.tag===4}function rm(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||tm(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 Fi(e,t,r){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?r.nodeType===8?r.parentNode.insertBefore(e,t):r.insertBefore(e,t):(r.nodeType===8?(t=r.parentNode,t.insertBefore(e,r)):(t=r,t.appendChild(e)),r=r._reactRootContainer,r!=null||t.onclick!==null||(t.onclick=qa));else if(n!==4&&(e=e.child,e!==null))for(Fi(e,t,r),e=e.sibling;e!==null;)Fi(e,t,r),e=e.sibling}function _i(e,t,r){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?r.insertBefore(e,t):r.appendChild(e);else if(n!==4&&(e=e.child,e!==null))for(_i(e,t,r),e=e.sibling;e!==null;)_i(e,t,r),e=e.sibling}var ce=null,Xe=!1;function kt(e,t,r){for(r=r.child;r!==null;)nm(e,t,r),r=r.sibling}function nm(e,t,r){if(tt&&typeof tt.onCommitFiberUnmount=="function")try{tt.onCommitFiberUnmount(Ta,r)}catch(i){}switch(r.tag){case 5:ge||Zr(r,t);case 6:var n=ce,a=Xe;ce=null,kt(e,t,r),ce=n,Xe=a,ce!==null&&(Xe?(e=ce,r=r.stateNode,e.nodeType===8?e.parentNode.removeChild(r):e.removeChild(r)):ce.removeChild(r.stateNode));break;case 18:ce!==null&&(Xe?(e=ce,r=r.stateNode,e.nodeType===8?ti(e.parentNode,r):e.nodeType===1&&ti(e,r),vn(e)):ti(ce,r.stateNode));break;case 4:n=ce,a=Xe,ce=r.stateNode.containerInfo,Xe=!0,kt(e,t,r),ce=n,Xe=a;break;case 0:case 11:case 14:case 15:if(!ge&&(n=r.updateQueue,n!==null&&(n=n.lastEffect,n!==null))){a=n=n.next;do{var s=a,l=s.destroy;s=s.tag,l!==void 0&&(s&2||s&4)&&Mi(r,t,l),a=a.next}while(a!==n)}kt(e,t,r);break;case 1:if(!ge&&(Zr(r,t),n=r.stateNode,typeof n.componentWillUnmount=="function"))try{n.props=r.memoizedProps,n.state=r.memoizedState,n.componentWillUnmount()}catch(i){Q(r,t,i)}kt(e,t,r);break;case 21:kt(e,t,r);break;case 22:r.mode&1?(ge=(n=ge)||r.memoizedState!==null,kt(e,t,r),ge=n):kt(e,t,r);break;default:kt(e,t,r)}}function am(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var r=e.stateNode;r===null&&(r=e.stateNode=new Lg),t.forEach(function(n){var a=kg.bind(null,e,n);r.has(n)||(r.add(n),n.then(a,a))})}}function Je(e,t){var r=t.deletions;if(r!==null)for(var n=0;na&&(a=l),n&=~s}if(n=a,n=Y()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*wg(n/1960))-n,10e?16:e,qt===null)var n=!1;else{if(e=qt,qt=null,ms=0,R&6)throw Error(A(331));var a=R;for(R|=4,E=e.current;E!==null;){var s=E,l=s.child;if(E.flags&16){var i=s.deletions;if(i!==null){for(var o=0;oY()-$i?ir(e,0):Zi|=r),we(e,t)}function gm(e,t){t===0&&(e.mode&1?(t=Aa,Aa<<=1,!(Aa&130023424)&&(Aa=4194304)):t=1);var r=xe();e=pt(e,t),e!==null&&(fn(e,t,r),we(e,r))}function Og(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),gm(e,r)}function kg(e,t){var r=0;switch(e.tag){case 13:var n=e.stateNode,a=e.memoizedState;a!==null&&(r=a.retryLane);break;case 19:n=e.stateNode;break;default:throw Error(A(314))}n!==null&&n.delete(t),gm(e,r)}var bm;bm=function(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps||Ie.current)De=!0;else{if(!(e.lanes&r)&&!(t.flags&128))return De=!1,Sg(e,t,r);De=!!(e.flags&131072)}else De=!1,Z&&t.flags&1048576&&Yc(t,Za,t.index);switch(t.lanes=0,t.tag){case 2:var n=t.type;ss(e,t),e=t.pendingProps;var a=Or(t,fe.current);Fr(t,r),a=Ai(null,t,n,e,a,r);var s=Si();return t.flags|=1,typeof a=="object"&&a!==null&&typeof a.render=="function"&&a.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Le(n)?(s=!0,Fa(t)):s=!1,t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,hi(t),a.updater=ns,t.stateNode=a,a._reactInternals=t,wi(t,n,e,r),t=Pi(null,t,n,!0,s,r)):(t.tag=0,Z&&s&&si(t),Se(null,t,a,r),t=t.child),t;case 16:n=t.elementType;e:{switch(ss(e,t),e=t.pendingProps,a=n._init,n=a(n._payload),t.type=n,a=t.tag=qg(n),e=Ye(n,e),a){case 0:t=Ni(null,t,n,e,r);break e;case 1:t=Zd(null,t,n,e,r);break e;case 11:t=Md(null,t,n,e,r);break e;case 14:t=zd(null,t,n,Ye(n.type,e),r);break e}throw Error(A(306,n,""))}return t;case 0:return n=t.type,a=t.pendingProps,a=t.elementType===n?a:Ye(n,a),Ni(e,t,n,a,r);case 1:return n=t.type,a=t.pendingProps,a=t.elementType===n?a:Ye(n,a),Zd(e,t,n,a,r);case 3:e:{if($d(t),e===null)throw Error(A(387));n=t.pendingProps,s=t.memoizedState,a=s.element,ld(e,t),Qa(t,n,null,r);var l=t.memoizedState;if(n=l.element,s.isDehydrated)if(s={element:n,isDehydrated:!1,cache:l.cache,pendingSuspenseBoundaries:l.pendingSuspenseBoundaries,transitions:l.transitions},t.updateQueue.baseState=s,t.memoizedState=s,t.flags&256){a=Vr(Error(A(423)),t),t=Wd(e,t,n,r,a);break e}else if(n!==a){a=Vr(Error(A(424)),t),t=Wd(e,t,n,r,a);break e}else for(Oe=jt(t.stateNode.containerInfo.firstChild),Ue=t,Z=!0,Qe=null,r=ad(t,null,n,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(qr(),n===a){t=ht(e,t,r);break e}Se(e,t,n,r)}t=t.child}return t;case 5:return ud(t),e===null&&oi(t),n=t.type,a=t.pendingProps,s=e!==null?e.memoizedProps:null,l=a.children,Jl(n,a)?l=null:s!==null&&Jl(n,s)&&(t.flags|=32),Vd(e,t),Se(e,t,l,r),t.child;case 6:return e===null&&oi(t),null;case 13:return Gd(e,t,r);case 4:return yi(t,t.stateNode.containerInfo),n=t.pendingProps,e===null?t.child=Mr(t,null,n,r):Se(e,t,n,r),t.child;case 11:return n=t.type,a=t.pendingProps,a=t.elementType===n?a:Ye(n,a),Md(e,t,n,a,r);case 7:return Se(e,t,t.pendingProps,r),t.child;case 8:return Se(e,t,t.pendingProps.children,r),t.child;case 12:return Se(e,t,t.pendingProps.children,r),t.child;case 10:e:{if(n=t.type._context,a=t.pendingProps,s=t.memoizedProps,l=a.value,F(Ga,n._currentValue),n._currentValue=l,s!==null)if(Ke(s.value,l)){if(s.children===a.children&&!Ie.current){t=ht(e,t,r);break e}}else for(s=t.child,s!==null&&(s.return=t);s!==null;){var i=s.dependencies;if(i!==null){l=s.child;for(var o=i.firstContext;o!==null;){if(o.context===n){if(s.tag===1){o=ft(-1,r&-r),o.tag=2;var u=s.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?o.next=o:(o.next=c.next,c.next=o),u.pending=o}}s.lanes|=r,o=s.alternate,o!==null&&(o.lanes|=r),pi(s.return,r,t),i.lanes|=r;break}o=o.next}}else if(s.tag===10)l=s.type===t.type?null:s.child;else if(s.tag===18){if(l=s.return,l===null)throw Error(A(341));l.lanes|=r,i=l.alternate,i!==null&&(i.lanes|=r),pi(l,r,t),l=s.sibling}else l=s.child;if(l!==null)l.return=s;else for(l=s;l!==null;){if(l===t){l=null;break}if(s=l.sibling,s!==null){s.return=l.return,l=s;break}l=l.return}s=l}Se(e,t,a.children,r),t=t.child}return t;case 9:return a=t.type,n=t.pendingProps.children,Fr(t,r),a=_e(a),n=n(a),t.flags|=1,Se(e,t,n,r),t.child;case 14:return n=t.type,a=Ye(n,t.pendingProps),a=Ye(n.type,a),zd(e,t,n,a,r);case 15:return Fd(e,t,t.type,t.pendingProps,r);case 17:return n=t.type,a=t.pendingProps,a=t.elementType===n?a:Ye(n,a),ss(e,t),t.tag=1,Le(n)?(e=!0,Fa(t)):e=!1,Fr(t,r),Nd(t,n,a),wi(t,n,a,r),Pi(null,t,n,!0,e,r);case 19:return Kd(e,t,r);case 22:return _d(e,t,r)}throw Error(A(156,t.tag))};function vm(e,t){return Xu(e,t)}function Rg(e,t,r,n){this.tag=e,this.key=r,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=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function $e(e,t,r,n){return new Rg(e,t,r,n)}function Ji(e){return e=e.prototype,!(!e||!e.isReactComponent)}function qg(e){if(typeof e=="function")return Ji(e)?1:0;if(e!=null){if(e=e.$$typeof,e===sl)return 11;if(e===ol)return 14}return 2}function Ft(e,t){var r=e.alternate;return r===null?(r=$e(e.tag,t,e.key,e.mode),r.elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=t,r.type=e.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=e.flags&14680064,r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,t=e.dependencies,r.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r}function ys(e,t,r,n,a,s){var l=2;if(n=e,typeof e=="function")Ji(e)&&(l=1);else if(typeof e=="string")l=5;else e:switch(e){case Ar:return ur(r.children,a,s,t);case nl:l=8,a|=8;break;case al:return e=$e(12,r,t,a|2),e.elementType=al,e.lanes=s,e;case ll:return e=$e(13,r,t,a),e.elementType=ll,e.lanes=s,e;case il:return e=$e(19,r,t,a),e.elementType=il,e.lanes=s,e;case Eu:return gs(r,a,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Lu:l=10;break e;case Du:l=9;break e;case sl:l=11;break e;case ol:l=14;break e;case At:l=16,n=null;break e}throw Error(A(130,e==null?e:typeof e,""))}return t=$e(l,r,t,a),t.elementType=e,t.type=n,t.lanes=s,t}function ur(e,t,r,n){return e=$e(7,e,n,t),e.lanes=r,e}function gs(e,t,r,n){return e=$e(22,e,n,t),e.elementType=Eu,e.lanes=r,e.stateNode={isHidden:!1},e}function eo(e,t,r){return e=$e(6,e,null,t),e.lanes=r,e}function to(e,t,r){return t=$e(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Mg(e,t,r,n,a){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=El(0),this.expirationTimes=El(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=El(0),this.identifierPrefix=n,this.onRecoverableError=a,this.mutableSourceEagerHydrationData=null}function ro(e,t,r,n,a,s,l,i,o){return e=new Mg(e,t,r,i,o),t===1?(t=1,s===!0&&(t|=8)):t=0,s=$e(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:n,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},hi(s),e}function zg(e,t,r){var n=3e,isStatic:!1,reducedMotion:"never"}),xs=w.createContext({}),lo=w.createContext(null),io=typeof window!="undefined",Kg=io?w.useLayoutEffect:w.useEffect,Em=w.createContext({strict:!1}),Is=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),wm="data-"+Is("framerAppearId"),Qg={skipAnimations:!1,useManualTiming:!1};function Yg(e){let t=new Set,r=new Set,n=!1,a=!1;const s=new WeakSet;let l={delta:0,timestamp:0,isProcessing:!1};function i(u){s.has(u)&&(o.schedule(u),e()),u(l)}const o={schedule:(u,c=!1,d=!1)=>{const y=d&&n?t:r;return c&&s.add(u),y.has(u)||y.add(u),u},cancel:u=>{r.delete(u),s.delete(u)},process:u=>{if(l=u,n){a=!0;return}n=!0,[t,r]=[r,t],r.clear(),t.forEach(i),n=!1,a&&(a=!1,o.process(u))}};return o}const Ls=["read","resolveKeyframes","update","preRender","render","postRender"],Xg=40;function jm(e,t){let r=!1,n=!0;const a={delta:0,timestamp:0,isProcessing:!1},s=()=>r=!0,l=Ls.reduce((f,p)=>(f[p]=Yg(s),f),{}),{read:i,resolveKeyframes:o,update:u,preRender:c,render:d,postRender:m}=l,y=()=>{const f=performance.now();r=!1,a.delta=n?1e3/60:Math.max(Math.min(f-a.timestamp,Xg),1),a.timestamp=f,a.isProcessing=!0,i.process(a),o.process(a),u.process(a),c.process(a),d.process(a),m.process(a),a.isProcessing=!1,r&&t&&(n=!1,e(y))},g=()=>{r=!0,n=!0,a.isProcessing||e(y)};return{schedule:Ls.reduce((f,p)=>{const h=l[p];return f[p]=(v,T=!1,x=!1)=>(r||g(),h.schedule(v,T,x)),f},{}),cancel:f=>{for(let p=0;p{c&&c.update(r,i)});const m=w.useRef(!!(r[wm]&&!window.HandoffComplete));return Kg(()=>{c&&(c.updateFeatures(),oo.render(c.render),m.current&&c.animationState&&c.animationState.animateChanges())}),w.useEffect(()=>{c&&(!m.current&&c.animationState&&c.animationState.animateChanges(),m.current&&(m.current=!1,Nm||(Nm=!0,queueMicrotask(eb))))}),c}function eb(){window.HandoffComplete=!0}function tb(e,t,r,n){const{layoutId:a,layout:s,drag:l,dragConstraints:i,layoutScroll:o,layoutRoot:u}=t;e.projection=new r(e.latestValues,t["data-framer-portal-id"]?void 0:Pm(e.parent)),e.projection.setOptions({layoutId:a,layout:s,alwaysMeasureLayout:!!l||i&&Hr(i),visualElement:e,animationType:typeof s=="string"?s:"both",initialPromotionConfig:n,layoutScroll:o,layoutRoot:u})}function Pm(e){if(e)return e.options.allowProjection!==!1?e.projection:Pm(e.parent)}function rb(e,t,r){return w.useCallback(n=>{n&&e.mount&&e.mount(n),t&&(n?t.mount(n):t.unmount()),r&&(typeof r=="function"?r(n):Hr(r)&&(r.current=n))},[t])}function Wn(e){return typeof e=="string"||Array.isArray(e)}function Gn(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}const uo=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],co=["initial",...uo];function Ds(e){return Gn(e.animate)||co.some(t=>Wn(e[t]))}function Um(e){return!!(Ds(e)||e.variants)}function nb(e,t){if(Ds(e)){const{initial:r,animate:n}=e;return{initial:r===!1||Wn(r)?r:void 0,animate:Wn(n)?n:void 0}}return e.inherit!==!1?t:{}}function ab(e){const{initial:t,animate:r}=nb(e,w.useContext(xs));return w.useMemo(()=>({initial:t,animate:r}),[Om(t),Om(r)])}function Om(e){return Array.isArray(e)?e.join(" "):e}const km={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"]},Kr={};for(const e in km)Kr[e]={isEnabled:t=>km[e].some(r=>!!t[r])};function sb(e){for(const t in e)Kr[t]=I(I({},Kr[t]),e[t])}const Rm=w.createContext({}),lb=Symbol.for("motionComponentSymbol"),be=e=>e;let mo=be;function ib({preloadedFeatures:e,createVisualElement:t,useRender:r,useVisualState:n,Component:a}){e&&sb(e);function s(i,o){let u;const c=q(I(I({},w.useContext(Dm)),i),{layoutId:ob(i)}),{isStatic:d}=c,m=ab(i),y=n(i,d);if(!d&&io){ub();const g=cb(c);u=g.MeasureLayout,m.visualElement=Jg(a,y,c,t,g.ProjectionNode)}return k.jsxs(xs.Provider,{value:m,children:[u&&m.visualElement?k.jsx(u,I({visualElement:m.visualElement},c)):null,r(a,i,rb(y,m.visualElement,o),y,d,m.visualElement)]})}const l=w.forwardRef(s);return l[lb]=a,l}function ob({layoutId:e}){const t=w.useContext(Rm).id;return t&&e!==void 0?t+"-"+e:e}function ub(e,t){w.useContext(Em).strict}function cb(e){const{drag:t,layout:r}=Kr;if(!t&&!r)return{};const n=I(I({},t),r);return{MeasureLayout:t!=null&&t.isEnabled(e)||r!=null&&r.isEnabled(e)?n.MeasureLayout:void 0,ProjectionNode:n.ProjectionNode}}function db(e){function t(n,a={}){return ib(e(n,a))}if(typeof Proxy=="undefined")return t;const r=new Map;return new Proxy(t,{get:(n,a)=>(r.has(a)||r.set(a,t(a)),r.get(a))})}const mb=["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 po(e){return typeof e!="string"||e.includes("-")?!1:!!(mb.indexOf(e)>-1||/[A-Z]/u.test(e))}const Es={};function pb(e){Object.assign(Es,e)}const Hn=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],_t=new Set(Hn);function qm(e,{layout:t,layoutId:r}){return _t.has(e)||e.startsWith("origin")||(t||r!==void 0)&&(!!Es[e]||e==="opacity")}const ve=e=>!!(e&&e.getVelocity),fb={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},hb=Hn.length;function yb(e,t,r){let n="";for(let a=0;at=>typeof t=="string"&&t.startsWith(e),zm=Mm("--"),gb=Mm("var(--"),fo=e=>gb(e)?bb.test(e.split("/*")[0].trim()):!1,bb=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,vb=(e,t)=>t&&typeof e=="number"?t.transform(e):e,Vt=(e,t,r)=>r>t?t:rtypeof e=="number",parse:parseFloat,transform:e=>e},Kn=q(I({},Qr),{transform:e=>Vt(0,1,e)}),ws=q(I({},Qr),{default:1}),Qn=e=>Math.round(e*1e5)/1e5,ho=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu,Tb=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu,Cb=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu;function Yn(e){return typeof e=="string"}function Ab(e){return e==null}const Xn=e=>({test:t=>Yn(t)&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Zt=Xn("deg"),lt=Xn("%"),j=Xn("px"),Sb=Xn("vh"),xb=Xn("vw"),Fm=q(I({},lt),{parse:e=>lt.parse(e)/100,transform:e=>lt.transform(e*100)}),_m=q(I({},Qr),{transform:Math.round}),Vm={borderWidth:j,borderTopWidth:j,borderRightWidth:j,borderBottomWidth:j,borderLeftWidth:j,borderRadius:j,radius:j,borderTopLeftRadius:j,borderTopRightRadius:j,borderBottomRightRadius:j,borderBottomLeftRadius:j,width:j,maxWidth:j,height:j,maxHeight:j,size:j,top:j,right:j,bottom:j,left:j,padding:j,paddingTop:j,paddingRight:j,paddingBottom:j,paddingLeft:j,margin:j,marginTop:j,marginRight:j,marginBottom:j,marginLeft:j,rotate:Zt,rotateX:Zt,rotateY:Zt,rotateZ:Zt,scale:ws,scaleX:ws,scaleY:ws,scaleZ:ws,skew:Zt,skewX:Zt,skewY:Zt,distance:j,translateX:j,translateY:j,translateZ:j,x:j,y:j,z:j,perspective:j,transformPerspective:j,opacity:Kn,originX:Fm,originY:Fm,originZ:j,zIndex:_m,backgroundPositionX:j,backgroundPositionY:j,fillOpacity:Kn,strokeOpacity:Kn,numOctaves:_m};function yo(e,t,r){const{style:n,vars:a,transform:s,transformOrigin:l}=e;let i=!1,o=!1,u=!0;for(const c in t){const d=t[c];if(zm(c)){a[c]=d;continue}const m=Vm[c],y=vb(d,m);if(_t.has(c)){if(i=!0,s[c]=y,!u)continue;d!==(m.default||0)&&(u=!1)}else c.startsWith("origin")?(o=!0,l[c]=y):n[c]=y}if(t.transform||(i||r?n.transform=yb(e.transform,u,r):n.transform&&(n.transform="none")),o){const{originX:c="50%",originY:d="50%",originZ:m=0}=l;n.transformOrigin=`${c} ${d} ${m}`}}const go=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Zm(e,t,r){for(const n in t)!ve(t[n])&&!qm(n,r)&&(e[n]=t[n])}function Ib({transformTemplate:e},t){return w.useMemo(()=>{const r=go();return yo(r,t,e),Object.assign({},r.vars,r.style)},[t])}function Lb(e,t){const r=e.style||{},n={};return Zm(n,r,e),Object.assign(n,Ib(e,t)),n}function Db(e,t){const r={},n=Lb(e,t);return e.drag&&e.dragListener!==!1&&(r.draggable=!1,n.userSelect=n.WebkitUserSelect=n.WebkitTouchCallout="none",n.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=n,r}const Eb=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function js(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||Eb.has(e)}let $m=e=>!js(e);function wb(e){e&&($m=t=>t.startsWith("on")?!js(t):e(t))}try{wb(require("@emotion/is-prop-valid").default)}catch(e){}function jb(e,t,r){const n={};for(const a in e)a==="values"&&typeof e.values=="object"||($m(a)||r===!0&&js(a)||!t&&!js(a)||e.draggable&&a.startsWith("onDrag"))&&(n[a]=e[a]);return n}function Wm(e,t,r){return typeof e=="string"?e:j.transform(t+r*e)}function Bb(e,t,r){const n=Wm(t,e.x,e.width),a=Wm(r,e.y,e.height);return`${n} ${a}`}const Nb={offset:"stroke-dashoffset",array:"stroke-dasharray"},Pb={offset:"strokeDashoffset",array:"strokeDasharray"};function Ub(e,t,r=1,n=0,a=!0){e.pathLength=1;const s=a?Nb:Pb;e[s.offset]=j.transform(-n);const l=j.transform(t),i=j.transform(r);e[s.array]=`${l} ${i}`}function bo(e,m,c,d){var y=m,{attrX:t,attrY:r,attrScale:n,originX:a,originY:s,pathLength:l,pathSpacing:i=1,pathOffset:o=0}=y,u=je(y,["attrX","attrY","attrScale","originX","originY","pathLength","pathSpacing","pathOffset"]);if(yo(e,u,d),c){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:g,style:b,dimensions:C}=e;g.transform&&(C&&(b.transform=g.transform),delete g.transform),C&&(a!==void 0||s!==void 0||b.transform)&&(b.transformOrigin=Bb(C,a!==void 0?a:.5,s!==void 0?s:.5)),t!==void 0&&(g.x=t),r!==void 0&&(g.y=r),n!==void 0&&(g.scale=n),l!==void 0&&Ub(g,l,i,o,!1)}const Gm=()=>q(I({},go()),{attrs:{}}),vo=e=>typeof e=="string"&&e.toLowerCase()==="svg";function Ob(e,t,r,n){const a=w.useMemo(()=>{const s=Gm();return bo(s,t,vo(n),e.transformTemplate),q(I({},s.attrs),{style:I({},s.style)})},[t]);if(e.style){const s={};Zm(s,e.style,e),a.style=I(I({},s),a.style)}return a}function kb(e=!1){return(r,n,a,{latestValues:s},l)=>{const o=(po(r)?Ob:Db)(n,s,l,r),u=jb(n,typeof r=="string",e),c=r!==w.Fragment?q(I(I({},u),o),{ref:a}):{},{children:d}=n,m=w.useMemo(()=>ve(d)?d.get():d,[d]);return w.createElement(r,q(I({},c),{children:m}))}}function Hm(e,{style:t,vars:r},n,a){Object.assign(e.style,t,a&&a.getProjectionStyles(n));for(const s in r)e.style.setProperty(s,r[s])}const Km=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 Qm(e,t,r,n){Hm(e,t,void 0,n);for(const a in t.attrs)e.setAttribute(Km.has(a)?a:Is(a),t.attrs[a])}function To(e,t,r){var n;const{style:a}=e,s={};for(const l in a)(ve(a[l])||t.style&&ve(t.style[l])||qm(l,e)||((n=r==null?void 0:r.getValue(l))===null||n===void 0?void 0:n.liveStyle)!==void 0)&&(s[l]=a[l]);return r&&a&&typeof a.willChange=="string"&&(r.applyWillChange=!1),s}function Ym(e,t,r){const n=To(e,t,r);for(const a in e)if(ve(e[a])||ve(t[a])){const s=Hn.indexOf(a)!==-1?"attr"+a.charAt(0).toUpperCase()+a.substring(1):a;n[s]=e[a]}return n}function Xm(e){const t=[{},{}];return e==null||e.values.forEach((r,n)=>{t[0][n]=r.get(),t[1][n]=r.getVelocity()}),t}function Co(e,t,r,n){if(typeof t=="function"){const[a,s]=Xm(n);t=t(r!==void 0?r:e.custom,a,s)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[a,s]=Xm(n);t=t(r!==void 0?r:e.custom,a,s)}return t}function Rb(e){const t=w.useRef(null);return t.current===null&&(t.current=e()),t.current}const Ao=e=>Array.isArray(e),qb=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),Mb=e=>Ao(e)?e[e.length-1]||0:e;function Bs(e){const t=ve(e)?e.get():e;return qb(t)?t.toValue():t}const Jm=new Set(["opacity","clipPath","filter","transform"]);function ep(e){if(_t.has(e))return"transform";if(Jm.has(e))return Is(e)}function Ns(e,t){e.indexOf(t)===-1&&e.push(t)}function Ps(e,t){const r=e.indexOf(t);r>-1&&e.splice(r,1)}function zb({applyWillChange:e=!1,scrapeMotionValuesFromProps:t,createRenderState:r,onMount:n},a,s,l,i){const o={latestValues:_b(a,s,l,i?!1:e,t),renderState:r()};return n&&(o.mount=u=>n(a,u,o)),o}const tp=e=>(t,r)=>{const n=w.useContext(xs),a=w.useContext(lo),s=()=>zb(e,t,n,a,r);return r?s():Rb(s)};function Fb(e,t){const r=ep(t);r&&Ns(e,r)}function rp(e,t,r){const n=Array.isArray(t)?t:[t];for(let s=0;s{for(const p in C){let h=C[p];if(Array.isArray(h)){const v=g?h.length-1:0;h=h[v]}h!==null&&(l[p]=h)}for(const p in f)l[p]=f[p]}),o&&(d&&c!==!1&&!Gn(d)&&rp(e,d,C=>{for(const f in C)Fb(i,f)}),i.length&&(l.willChange=i.join(","))),l}const{schedule:z,cancel:gt,state:me,steps:So}=jm(typeof requestAnimationFrame!="undefined"?requestAnimationFrame:be,!0),Vb={useVisualState:tp({scrapeMotionValuesFromProps:Ym,createRenderState:Gm,onMount:(e,t,{renderState:r,latestValues:n})=>{z.read(()=>{try{r.dimensions=typeof t.getBBox=="function"?t.getBBox():t.getBoundingClientRect()}catch(a){r.dimensions={x:0,y:0,width:0,height:0}}}),z.render(()=>{bo(r,n,vo(t.tagName),e.transformTemplate),Qm(t,r)})}})},Zb={useVisualState:tp({applyWillChange:!0,scrapeMotionValuesFromProps:To,createRenderState:go})};function $b(e,{forwardMotionProps:t=!1},r,n){const a=po(e)?Vb:Zb;return q(I({},a),{preloadedFeatures:r,useRender:kb(t),createVisualElement:n,Component:e})}function bt(e,t,r,n={passive:!0}){return e.addEventListener(t,r,n),()=>e.removeEventListener(t,r)}const np=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;function Us(e,t="page"){return{point:{x:e[`${t}X`],y:e[`${t}Y`]}}}const Wb=e=>t=>np(t)&&e(t,Us(t));function vt(e,t,r,n){return bt(e,t,Wb(r),n)}const Gb=(e,t)=>r=>t(e(r)),Tt=(...e)=>e.reduce(Gb);function ap(e){let t=null;return()=>{const r=()=>{t=null};return t===null?(t=e,r):!1}}const sp=ap("dragHorizontal"),lp=ap("dragVertical");function ip(e){let t=!1;if(e==="y")t=lp();else if(e==="x")t=sp();else{const r=sp(),n=lp();r&&n?t=()=>{r(),n()}:(r&&r(),n&&n())}return t}function op(){const e=ip(!0);return e?(e(),!1):!0}class $t{constructor(t){this.isMounted=!1,this.node=t}update(){}}function up(e,t){const r=t?"pointerenter":"pointerleave",n=t?"onHoverStart":"onHoverEnd",a=(s,l)=>{if(s.pointerType==="touch"||op())return;const i=e.getProps();e.animationState&&i.whileHover&&e.animationState.setActive("whileHover",t);const o=i[n];o&&z.postRender(()=>o(s,l))};return vt(e.current,r,a,{passive:!e.getProps()[n]})}class Hb extends $t{mount(){this.unmount=Tt(up(this.node,!0),up(this.node,!1))}unmount(){}}class Kb extends $t{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch(r){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=Tt(bt(this.node.current,"focus",()=>this.onFocus()),bt(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}const cp=(e,t)=>t?e===t?!0:cp(e,t.parentElement):!1;function xo(e,t){if(!t)return;const r=new PointerEvent("pointer"+e);t(r,Us(r))}class Qb extends $t{constructor(){super(...arguments),this.removeStartListeners=be,this.removeEndListeners=be,this.removeAccessibleListeners=be,this.startPointerPress=(t,r)=>{if(this.isPressing)return;this.removeEndListeners();const n=this.node.getProps(),s=vt(window,"pointerup",(i,o)=>{if(!this.checkPressEnd())return;const{onTap:u,onTapCancel:c,globalTapTarget:d}=this.node.getProps(),m=!d&&!cp(this.node.current,i.target)?c:u;m&&z.update(()=>m(i,o))},{passive:!(n.onTap||n.onPointerUp)}),l=vt(window,"pointercancel",(i,o)=>this.cancelPress(i,o),{passive:!(n.onTapCancel||n.onPointerCancel)});this.removeEndListeners=Tt(s,l),this.startPress(t,r)},this.startAccessiblePress=()=>{const t=s=>{if(s.key!=="Enter"||this.isPressing)return;const l=i=>{i.key!=="Enter"||!this.checkPressEnd()||xo("up",(o,u)=>{const{onTap:c}=this.node.getProps();c&&z.postRender(()=>c(o,u))})};this.removeEndListeners(),this.removeEndListeners=bt(this.node.current,"keyup",l),xo("down",(i,o)=>{this.startPress(i,o)})},r=bt(this.node.current,"keydown",t),n=()=>{this.isPressing&&xo("cancel",(s,l)=>this.cancelPress(s,l))},a=bt(this.node.current,"blur",n);this.removeAccessibleListeners=Tt(r,a)}}startPress(t,r){this.isPressing=!0;const{onTapStart:n,whileTap:a}=this.node.getProps();a&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),n&&z.postRender(()=>n(t,r))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!op()}cancelPress(t,r){if(!this.checkPressEnd())return;const{onTapCancel:n}=this.node.getProps();n&&z.postRender(()=>n(t,r))}mount(){const t=this.node.getProps(),r=vt(t.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),n=bt(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=Tt(r,n)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}const Io=new WeakMap,Lo=new WeakMap,Yb=e=>{const t=Io.get(e.target);t&&t(e)},Xb=e=>{e.forEach(Yb)};function Jb(r){var n=r,{root:e}=n,t=je(n,["root"]);const a=e||document;Lo.has(a)||Lo.set(a,{});const s=Lo.get(a),l=JSON.stringify(t);return s[l]||(s[l]=new IntersectionObserver(Xb,I({root:e},t))),s[l]}function ev(e,t,r){const n=Jb(t);return Io.set(e,r),n.observe(e),()=>{Io.delete(e),n.unobserve(e)}}const tv={some:0,all:1};class rv extends $t{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:r,margin:n,amount:a="some",once:s}=t,l={root:r?r.current:void 0,rootMargin:n,threshold:typeof a=="number"?a:tv[a]},i=o=>{const{isIntersecting:u}=o;if(this.isInView===u||(this.isInView=u,s&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:c,onViewportLeave:d}=this.node.getProps(),m=u?c:d;m&&m(o)};return ev(this.node.current,l,i)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver=="undefined")return;const{props:t,prevProps:r}=this.node;["amount","margin","root"].some(nv(t,r))&&this.startObserver()}unmount(){}}function nv({viewport:e={}},{viewport:t={}}={}){return r=>e[r]!==t[r]}const av={inView:{Feature:rv},tap:{Feature:Qb},focus:{Feature:Kb},hover:{Feature:Hb}};function dp(e,t){if(!Array.isArray(t))return!1;const r=t.length;if(r!==e.length)return!1;for(let n=0;ne*1e3,Ct=e=>e/1e3,sv={type:"spring",stiffness:500,damping:25,restSpeed:10},lv=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),iv={type:"keyframes",duration:.8},ov={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},uv=(e,{keyframes:t})=>t.length>2?iv:_t.has(e)?e.startsWith("scale")?lv(t[1]):sv:ov;function cv(d){var m=d,{when:e,delay:t,delayChildren:r,staggerChildren:n,staggerDirection:a,repeat:s,repeatType:l,repeatDelay:i,from:o,elapsed:u}=m,c=je(m,["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);return!!Object.keys(c).length}function Do(e,t){return e[t]||e.default||e}const dv=e=>e!==null;function ks(e,{repeat:t,repeatType:r="loop"},n){const a=e.filter(dv),s=t&&r!=="loop"&&t%2===1?0:a.length-1;return!s||n===void 0?a[s]:n}let Rs;function mv(){Rs=void 0}const Gt={now:()=>(Rs===void 0&&Gt.set(me.isProcessing||Qg.useManualTiming?me.timestamp:performance.now()),Rs),set:e=>{Rs=e,queueMicrotask(mv)}},mp=e=>/^0[^.\s]+$/u.test(e);function pv(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||mp(e):!0}const pp=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),fv=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function hv(e){const t=fv.exec(e);if(!t)return[,];const[,r,n,a]=t;return[`--${r!=null?r:n}`,a]}function fp(e,t,r=1){const[n,a]=hv(e);if(!n)return;const s=window.getComputedStyle(t).getPropertyValue(n);if(s){const l=s.trim();return pp(l)?parseFloat(l):l}return fo(a)?fp(a,t,r+1):a}const yv=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),hp=e=>e===Qr||e===j,yp=(e,t)=>parseFloat(e.split(", ")[t]),gp=(e,t)=>(r,{transform:n})=>{if(n==="none"||!n)return 0;const a=n.match(/^matrix3d\((.+)\)$/u);if(a)return yp(a[1],t);{const s=n.match(/^matrix\((.+)\)$/u);return s?yp(s[1],e):0}},gv=new Set(["x","y","z"]),bv=Hn.filter(e=>!gv.has(e));function vv(e){const t=[];return bv.forEach(r=>{const n=e.getValue(r);n!==void 0&&(t.push([r,n.get()]),n.set(r.startsWith("scale")?1:0))}),t}const Yr={width:({x:e},{paddingLeft:t="0",paddingRight:r="0"})=>e.max-e.min-parseFloat(t)-parseFloat(r),height:({y:e},{paddingTop:t="0",paddingBottom:r="0"})=>e.max-e.min-parseFloat(t)-parseFloat(r),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:gp(4,13),y:gp(5,14)};Yr.translateX=Yr.x,Yr.translateY=Yr.y;const bp=e=>t=>t.test(e),vp=[Qr,j,lt,Zt,xb,Sb,{test:e=>e==="auto",parse:e=>e}],Tp=e=>vp.find(bp(e)),cr=new Set;let Eo=!1,wo=!1;function Cp(){if(wo){const e=Array.from(cr).filter(n=>n.needsMeasurement),t=new Set(e.map(n=>n.element)),r=new Map;t.forEach(n=>{const a=vv(n);a.length&&(r.set(n,a),n.render())}),e.forEach(n=>n.measureInitialState()),t.forEach(n=>{n.render();const a=r.get(n);a&&a.forEach(([s,l])=>{var i;(i=n.getValue(s))===null||i===void 0||i.set(l)})}),e.forEach(n=>n.measureEndState()),e.forEach(n=>{n.suspendedScrollY!==void 0&&window.scrollTo(0,n.suspendedScrollY)})}wo=!1,Eo=!1,cr.forEach(e=>e.complete()),cr.clear()}function Ap(){cr.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(wo=!0)})}function Tv(){Ap(),Cp()}class jo{constructor(t,r,n,a,s,l=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...t],this.onComplete=r,this.name=n,this.motionValue=a,this.element=s,this.isAsync=l}scheduleResolve(){this.isScheduled=!0,this.isAsync?(cr.add(this),Eo||(Eo=!0,z.read(Ap),z.resolveKeyframes(Cp))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:r,element:n,motionValue:a}=this;for(let s=0;sr=>!!(Yn(r)&&Cb.test(r)&&r.startsWith(e)||t&&!Ab(r)&&Object.prototype.hasOwnProperty.call(r,t)),Sp=(e,t,r)=>n=>{if(!Yn(n))return n;const[a,s,l,i]=n.match(ho);return{[e]:parseFloat(a),[t]:parseFloat(s),[r]:parseFloat(l),alpha:i!==void 0?parseFloat(i):1}},Cv=e=>Vt(0,255,e),No=q(I({},Qr),{transform:e=>Math.round(Cv(e))}),dr={test:Bo("rgb","red"),parse:Sp("red","green","blue"),transform:({red:e,green:t,blue:r,alpha:n=1})=>"rgba("+No.transform(e)+", "+No.transform(t)+", "+No.transform(r)+", "+Qn(Kn.transform(n))+")"};function Av(e){let t="",r="",n="",a="";return e.length>5?(t=e.substring(1,3),r=e.substring(3,5),n=e.substring(5,7),a=e.substring(7,9)):(t=e.substring(1,2),r=e.substring(2,3),n=e.substring(3,4),a=e.substring(4,5),t+=t,r+=r,n+=n,a+=a),{red:parseInt(t,16),green:parseInt(r,16),blue:parseInt(n,16),alpha:a?parseInt(a,16)/255:1}}const Po={test:Bo("#"),parse:Av,transform:dr.transform},Xr={test:Bo("hsl","hue"),parse:Sp("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:r,alpha:n=1})=>"hsla("+Math.round(e)+", "+lt.transform(Qn(t))+", "+lt.transform(Qn(r))+", "+Qn(Kn.transform(n))+")"},Te={test:e=>dr.test(e)||Po.test(e)||Xr.test(e),parse:e=>dr.test(e)?dr.parse(e):Xr.test(e)?Xr.parse(e):Po.parse(e),transform:e=>Yn(e)?e:e.hasOwnProperty("red")?dr.transform(e):Xr.transform(e)};function Sv(e){var t,r;return isNaN(e)&&Yn(e)&&(((t=e.match(ho))===null||t===void 0?void 0:t.length)||0)+(((r=e.match(Tb))===null||r===void 0?void 0:r.length)||0)>0}const xp="number",Ip="color",xv="var",Iv="var(",Lp="${}",Lv=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Jn(e){const t=e.toString(),r=[],n={color:[],number:[],var:[]},a=[];let s=0;const i=t.replace(Lv,o=>(Te.test(o)?(n.color.push(s),a.push(Ip),r.push(Te.parse(o))):o.startsWith(Iv)?(n.var.push(s),a.push(xv),r.push(o)):(n.number.push(s),a.push(xp),r.push(parseFloat(o))),++s,Lp)).split(Lp);return{values:r,split:i,indexes:n,types:a}}function Dp(e){return Jn(e).values}function Ep(e){const{split:t,types:r}=Jn(e),n=t.length;return a=>{let s="";for(let l=0;ltypeof e=="number"?0:e;function Ev(e){const t=Dp(e);return Ep(e)(t.map(Dv))}const Ht={test:Sv,parse:Dp,createTransformer:Ep,getAnimatableNone:Ev},wv=new Set(["brightness","contrast","saturate","opacity"]);function jv(e){const[t,r]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[n]=r.match(ho)||[];if(!n)return e;const a=r.replace(n,"");let s=wv.has(t)?1:0;return n!==r&&(s*=100),t+"("+s+a+")"}const Bv=/\b([a-z-]*)\(.*?\)/gu,Uo=q(I({},Ht),{getAnimatableNone:e=>{const t=e.match(Bv);return t?t.map(jv).join(" "):e}}),Nv=q(I({},Vm),{color:Te,backgroundColor:Te,outlineColor:Te,fill:Te,stroke:Te,borderColor:Te,borderTopColor:Te,borderRightColor:Te,borderBottomColor:Te,borderLeftColor:Te,filter:Uo,WebkitFilter:Uo}),Oo=e=>Nv[e];function wp(e,t){let r=Oo(e);return r!==Uo&&(r=Ht),r.getAnimatableNone?r.getAnimatableNone(t):void 0}const Pv=new Set(["auto","none","0"]);function Uv(e,t,r){let n=0,a;for(;n{r.getValue(o).set(u)}),this.resolveNoneKeyframes()}}function Bp(e){let t;return()=>(t===void 0&&(t=e()),t)}const Np=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(Ht.test(e)||e==="0")&&!e.startsWith("url("));function Ov(e){const t=e[0];if(e.length===1)return!0;for(let r=0;r{this.resolveFinishedPromise=t})}}function Up(e,t){return t?e*(1e3/t):0}const Rv=5;function Op(e,t,r){const n=Math.max(t-Rv,0);return Up(r-e(n),t-n)}const ko=.001,qv=.01,Mv=10,zv=.05,Fv=1;function _v({duration:e=800,bounce:t=.25,velocity:r=0,mass:n=1}){let a,s,l=1-t;l=Vt(zv,Fv,l),e=Vt(qv,Mv,Ct(e)),l<1?(a=u=>{const c=u*l,d=c*e,m=c-r,y=Ro(u,l),g=Math.exp(-d);return ko-m/y*g},s=u=>{const d=u*l*e,m=d*r+r,y=Math.pow(l,2)*Math.pow(u,2)*e,g=Math.exp(-d),b=Ro(Math.pow(u,2),l);return(-a(u)+ko>0?-1:1)*((m-y)*g)/b}):(a=u=>{const c=Math.exp(-u*e),d=(u-r)*e+1;return-ko+c*d},s=u=>{const c=Math.exp(-u*e),d=(r-u)*(e*e);return c*d});const i=5/e,o=Zv(a,s,i);if(e=Wt(e),isNaN(o))return{stiffness:100,damping:10,duration:e};{const u=Math.pow(o,2)*n;return{stiffness:u,damping:l*2*Math.sqrt(n*u),duration:e}}}const Vv=12;function Zv(e,t,r){let n=r;for(let a=1;ae[r]!==void 0)}function Gv(e){let t=I({velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1},e);if(!kp(e,Wv)&&kp(e,$v)){const r=_v(e);t=q(I(I({},t),r),{mass:1}),t.isResolvedFromDuration=!0}return t}function Rp(a){var s=a,{keyframes:e,restDelta:t,restSpeed:r}=s,n=je(s,["keyframes","restDelta","restSpeed"]);const l=e[0],i=e[e.length-1],o={done:!1,value:l},{stiffness:u,damping:c,mass:d,duration:m,velocity:y,isResolvedFromDuration:g}=Gv(q(I({},n),{velocity:-Ct(n.velocity||0)})),b=y||0,C=c/(2*Math.sqrt(u*d)),f=i-l,p=Ct(Math.sqrt(u/d)),h=Math.abs(f)<5;r||(r=h?.01:2),t||(t=h?.005:.5);let v;if(C<1){const T=Ro(p,C);v=x=>{const L=Math.exp(-C*p*x);return i-L*((b+C*p*f)/T*Math.sin(T*x)+f*Math.cos(T*x))}}else if(C===1)v=T=>i-Math.exp(-p*T)*(f+(b+p*f)*T);else{const T=p*Math.sqrt(C*C-1);v=x=>{const L=Math.exp(-C*p*x),S=Math.min(T*x,300);return i-L*((b+C*p*f)*Math.sinh(S)+T*f*Math.cosh(S))/T}}return{calculatedDuration:g&&m||null,next:T=>{const x=v(T);if(g)o.done=T>=m;else{let L=b;T!==0&&(C<1?L=Op(v,T,x):L=0);const S=Math.abs(L)<=r,O=Math.abs(i-x)<=t;o.done=S&&O}return o.value=o.done?i:x,o}}}function qp({keyframes:e,velocity:t=0,power:r=.8,timeConstant:n=325,bounceDamping:a=10,bounceStiffness:s=500,modifyTarget:l,min:i,max:o,restDelta:u=.5,restSpeed:c}){const d=e[0],m={done:!1,value:d},y=S=>i!==void 0&&So,g=S=>i===void 0?o:o===void 0||Math.abs(i-S)-b*Math.exp(-S/n),h=S=>f+p(S),v=S=>{const O=p(S),B=h(S);m.done=Math.abs(O)<=u,m.value=m.done?f:B};let T,x;const L=S=>{y(m.value)&&(T=S,x=Rp({keyframes:[m.value,g(m.value)],velocity:Op(h,S,m.value),damping:a,stiffness:s,restDelta:u,restSpeed:c}))};return L(0),{calculatedDuration:null,next:S=>{let O=!1;return!x&&T===void 0&&(O=!0,v(S),L(S)),T!==void 0&&S>=T?x.next(S-T):(!O&&v(S),m)}}}const Mp=(e,t,r)=>(((1-3*r+3*t)*e+(3*r-6*t))*e+3*t)*e,Hv=1e-7,Kv=12;function Qv(e,t,r,n,a){let s,l,i=0;do l=t+(r-t)/2,s=Mp(l,n,a)-e,s>0?r=l:t=l;while(Math.abs(s)>Hv&&++iQv(s,0,1,e,r);return s=>s===0||s===1?s:Mp(a(s),t,n)}const Yv=ea(.42,0,1,1),Xv=ea(0,0,.58,1),zp=ea(.42,0,.58,1),Jv=e=>Array.isArray(e)&&typeof e[0]!="number",Fp=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,_p=e=>t=>1-e(1-t),qo=e=>1-Math.sin(Math.acos(e)),Vp=_p(qo),eT=Fp(qo),Zp=ea(.33,1.53,.69,.99),Mo=_p(Zp),tT=Fp(Mo),$p={linear:be,easeIn:Yv,easeInOut:zp,easeOut:Xv,circIn:qo,circInOut:eT,circOut:Vp,backIn:Mo,backInOut:tT,backOut:Zp,anticipate:e=>(e*=2)<1?.5*Mo(e):.5*(2-Math.pow(2,-10*(e-1)))},Wp=e=>{if(Array.isArray(e)){mo(e.length===4);const[t,r,n,a]=e;return ea(t,r,n,a)}else if(typeof e=="string")return mo($p[e]!==void 0),$p[e];return e},ta=(e,t,r)=>{const n=t-e;return n===0?1:(r-e)/n},H=(e,t,r)=>e+(t-e)*r;function zo(e,t,r){return r<0&&(r+=1),r>1&&(r-=1),r<1/6?e+(t-e)*6*r:r<1/2?t:r<2/3?e+(t-e)*(2/3-r)*6:e}function rT({hue:e,saturation:t,lightness:r,alpha:n}){e/=360,t/=100,r/=100;let a=0,s=0,l=0;if(!t)a=s=l=r;else{const i=r<.5?r*(1+t):r+t-r*t,o=2*r-i;a=zo(o,i,e+1/3),s=zo(o,i,e),l=zo(o,i,e-1/3)}return{red:Math.round(a*255),green:Math.round(s*255),blue:Math.round(l*255),alpha:n}}function qs(e,t){return r=>r>0?t:e}const Fo=(e,t,r)=>{const n=e*e,a=r*(t*t-n)+n;return a<0?0:Math.sqrt(a)},nT=[Po,dr,Xr],aT=e=>nT.find(t=>t.test(e));function Gp(e){const t=aT(e);if(!t)return!1;let r=t.parse(e);return t===Xr&&(r=rT(r)),r}const Hp=(e,t)=>{const r=Gp(e),n=Gp(t);if(!r||!n)return qs(e,t);const a=I({},r);return s=>(a.red=Fo(r.red,n.red,s),a.green=Fo(r.green,n.green,s),a.blue=Fo(r.blue,n.blue,s),a.alpha=H(r.alpha,n.alpha,s),dr.transform(a))},_o=new Set(["none","hidden"]);function sT(e,t){return _o.has(e)?r=>r<=0?e:t:r=>r>=1?t:e}function lT(e,t){return r=>H(e,t,r)}function Vo(e){return typeof e=="number"?lT:typeof e=="string"?fo(e)?qs:Te.test(e)?Hp:uT:Array.isArray(e)?Kp:typeof e=="object"?Te.test(e)?Hp:iT:qs}function Kp(e,t){const r=[...e],n=r.length,a=e.map((s,l)=>Vo(s)(s,t[l]));return s=>{for(let l=0;l{for(const s in n)r[s]=n[s](a);return r}}function oT(e,t){var r;const n=[],a={color:0,var:0,number:0};for(let s=0;s{const r=Ht.createTransformer(t),n=Jn(e),a=Jn(t);return n.indexes.var.length===a.indexes.var.length&&n.indexes.color.length===a.indexes.color.length&&n.indexes.number.length>=a.indexes.number.length?_o.has(e)&&!a.values.length||_o.has(t)&&!n.values.length?sT(e,t):Tt(Kp(oT(n,a),a.values),r):qs(e,t)};function Qp(e,t,r){return typeof e=="number"&&typeof t=="number"&&typeof r=="number"?H(e,t,r):Vo(e)(e,t)}function cT(e,t,r){const n=[],a=r||Qp,s=e.length-1;for(let l=0;lt[0];if(s===2&&e[0]===e[1])return()=>t[1];e[0]>e[s-1]&&(e=[...e].reverse(),t=[...t].reverse());const l=cT(t,n,a),i=l.length,o=u=>{let c=0;if(i>1)for(;co(Vt(e[0],e[s-1],u)):o}function mT(e,t){const r=e[e.length-1];for(let n=1;n<=t;n++){const a=ta(0,t,n);e.push(H(r,1,a))}}function pT(e){const t=[0];return mT(t,e.length-1),t}function fT(e,t){return e.map(r=>r*t)}function hT(e,t){return e.map(()=>t||zp).splice(0,e.length-1)}function Ms({duration:e=300,keyframes:t,times:r,ease:n="easeInOut"}){const a=Jv(n)?n.map(Wp):Wp(n),s={done:!1,value:t[0]},l=fT(r&&r.length===t.length?r:pT(t),e),i=dT(l,t,{ease:Array.isArray(a)?a:hT(t,a)});return{calculatedDuration:e,next:o=>(s.value=i(o),s.done=o>=e,s)}}const Yp=2e4;function yT(e){let t=0;const r=50;let n=e.next(t);for(;!n.done&&t=Yp?1/0:t}const gT=e=>{const t=({timestamp:r})=>e(r);return{start:()=>z.update(t,!0),stop:()=>gt(t),now:()=>me.isProcessing?me.timestamp:Gt.now()}},bT={decay:qp,inertia:qp,tween:Ms,keyframes:Ms,spring:Rp},vT=e=>e/100;class Zo extends Pp{constructor(n){var a=n,{KeyframeResolver:t=jo}=a,r=je(a,["KeyframeResolver"]);super(r),this.holdTime=null,this.startTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.teardown();const{onStop:u}=this.options;u&&u()};const{name:s,motionValue:l,keyframes:i}=this.options,o=(u,c)=>this.onKeyframesResolved(u,c);s&&l&&l.owner?this.resolver=l.owner.resolveKeyframes(i,o,s,l):this.resolver=new t(i,o,s,l),this.resolver.scheduleResolve()}initPlayback(t){const{type:r="keyframes",repeat:n=0,repeatDelay:a=0,repeatType:s,velocity:l=0}=this.options,i=bT[r]||Ms;let o,u;i!==Ms&&typeof t[0]!="number"&&(o=Tt(vT,Qp(t[0],t[1])),t=[0,100]);const c=i(q(I({},this.options),{keyframes:t}));s==="mirror"&&(u=i(q(I({},this.options),{keyframes:[...t].reverse(),velocity:-l}))),c.calculatedDuration===null&&(c.calculatedDuration=yT(c));const{calculatedDuration:d}=c,m=d+a,y=m*(n+1)-a;return{generator:c,mirroredGenerator:u,mapPercentToKeyframes:o,calculatedDuration:d,resolvedDuration:m,totalDuration:y}}onPostResolved(){const{autoplay:t=!0}=this.options;this.play(),this.pendingPlayState==="paused"||!t?this.pause():this.state=this.pendingPlayState}tick(t,r=!1){const{resolved:n}=this;if(!n){const{keyframes:S}=this.options;return{done:!0,value:S[S.length-1]}}const{finalKeyframe:a,generator:s,mirroredGenerator:l,mapPercentToKeyframes:i,keyframes:o,calculatedDuration:u,totalDuration:c,resolvedDuration:d}=n;if(this.startTime===null)return s.next(0);const{delay:m,repeat:y,repeatType:g,repeatDelay:b,onUpdate:C}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-c/this.speed,this.startTime)),r?this.currentTime=t:this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=Math.round(t-this.startTime)*this.speed;const f=this.currentTime-m*(this.speed>=0?1:-1),p=this.speed>=0?f<0:f>c;this.currentTime=Math.max(f,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=c);let h=this.currentTime,v=s;if(y){const S=Math.min(this.currentTime,c)/d;let O=Math.floor(S),B=S%1;!B&&S>=1&&(B=1),B===1&&O--,O=Math.min(O,y+1),!!(O%2)&&(g==="reverse"?(B=1-B,b&&(B-=b/d)):g==="mirror"&&(v=l)),h=Vt(0,1,B)*d}const T=p?{done:!1,value:o[0]}:v.next(h);i&&(T.value=i(T.value));let{done:x}=T;!p&&u!==null&&(x=this.speed>=0?this.currentTime>=c:this.currentTime<=0);const L=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&x);return L&&a!==void 0&&(T.value=ks(o,this.options,a)),C&&C(T.value),L&&this.finish(),T}get duration(){const{resolved:t}=this;return t?Ct(t.calculatedDuration):0}get time(){return Ct(this.currentTime)}set time(t){t=Wt(t),this.currentTime=t,this.holdTime!==null||this.speed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.speed)}get speed(){return this.playbackSpeed}set speed(t){const r=this.playbackSpeed!==t;this.playbackSpeed=t,r&&(this.time=Ct(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;const{driver:t=gT,onPlay:r}=this.options;this.driver||(this.driver=t(a=>this.tick(a))),r&&r();const n=this.driver.now();this.holdTime!==null?this.startTime=n-this.holdTime:(!this.startTime||this.state==="finished")&&(this.startTime=n),this.state==="finished"&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var t;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=(t=this.currentTime)!==null&&t!==void 0?t:0}complete(){this.state!=="running"&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:t}=this.options;t&&t()}cancel(){this.cancelTime!==null&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}}const Xp=e=>Array.isArray(e)&&typeof e[0]=="number";function Jp(e){return!!(!e||typeof e=="string"&&e in $o||Xp(e)||Array.isArray(e)&&e.every(Jp))}const ra=([e,t,r,n])=>`cubic-bezier(${e}, ${t}, ${r}, ${n})`,$o={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:ra([0,.65,.55,1]),circOut:ra([.55,0,1,.45]),backIn:ra([.31,.01,.66,-.59]),backOut:ra([.33,1.53,.69,.99])};function TT(e){return ef(e)||$o.easeOut}function ef(e){if(e)return Xp(e)?ra(e):Array.isArray(e)?e.map(TT):$o[e]}function CT(e,t,r,{delay:n=0,duration:a=300,repeat:s=0,repeatType:l="loop",ease:i,times:o}={}){const u={[t]:r};o&&(u.offset=o);const c=ef(i);return Array.isArray(c)&&(u.easing=c),e.animate(u,{delay:n,duration:a,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:s+1,direction:l==="reverse"?"alternate":"normal"})}const AT=Bp(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),zs=10,ST=2e4;function xT(e){return e.type==="spring"||!Jp(e.ease)}function IT(e,t){const r=new Zo(q(I({},t),{keyframes:e,repeat:0,delay:0,isGenerator:!0}));let n={done:!1,value:e[0]};const a=[];let s=0;for(;!n.done&&sthis.onKeyframesResolved(s,l),r,n),this.resolver.scheduleResolve()}initPlayback(t,r){var n;let{duration:a=300,times:s,ease:l,type:i,motionValue:o,name:u}=this.options;if(!(!((n=o.owner)===null||n===void 0)&&n.current))return!1;if(xT(this.options)){const d=this.options,{onComplete:m,onUpdate:y,motionValue:g}=d,b=je(d,["onComplete","onUpdate","motionValue"]),C=IT(t,b);t=C.keyframes,t.length===1&&(t[1]=t[0]),a=C.duration,s=C.times,l=C.ease,i="keyframes"}const c=CT(o.owner.current,u,t,q(I({},this.options),{duration:a,times:s,ease:l}));return c.startTime=Gt.now(),this.pendingTimeline?(c.timeline=this.pendingTimeline,this.pendingTimeline=void 0):c.onfinish=()=>{const{onComplete:m}=this.options;o.set(ks(t,this.options,r)),m&&m(),this.cancel(),this.resolveFinishedPromise()},{animation:c,duration:a,times:s,type:i,ease:l,keyframes:t}}get duration(){const{resolved:t}=this;if(!t)return 0;const{duration:r}=t;return Ct(r)}get time(){const{resolved:t}=this;if(!t)return 0;const{animation:r}=t;return Ct(r.currentTime||0)}set time(t){const{resolved:r}=this;if(!r)return;const{animation:n}=r;n.currentTime=Wt(t)}get speed(){const{resolved:t}=this;if(!t)return 1;const{animation:r}=t;return r.playbackRate}set speed(t){const{resolved:r}=this;if(!r)return;const{animation:n}=r;n.playbackRate=t}get state(){const{resolved:t}=this;if(!t)return"idle";const{animation:r}=t;return r.playState}attachTimeline(t){if(!this._resolved)this.pendingTimeline=t;else{const{resolved:r}=this;if(!r)return be;const{animation:n}=r;n.timeline=t,n.onfinish=null}return be}play(){if(this.isStopped)return;const{resolved:t}=this;if(!t)return;const{animation:r}=t;r.playState==="finished"&&this.updateFinishedPromise(),r.play()}pause(){const{resolved:t}=this;if(!t)return;const{animation:r}=t;r.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.resolveFinishedPromise(),this.updateFinishedPromise();const{resolved:t}=this;if(!t)return;const{animation:r,keyframes:n,duration:a,type:s,ease:l,times:i}=t;if(r.playState==="idle"||r.playState==="finished")return;if(this.time){const u=this.options,{motionValue:c,onUpdate:d,onComplete:m}=u,y=je(u,["motionValue","onUpdate","onComplete"]),g=new Zo(q(I({},y),{keyframes:n,duration:a,type:s,ease:l,times:i,isGenerator:!0})),b=Wt(this.time);c.setWithVelocity(g.sample(b-zs).value,g.sample(b).value,zs)}const{onStop:o}=this.options;o&&o(),this.cancel()}complete(){const{resolved:t}=this;t&&t.animation.finish()}cancel(){const{resolved:t}=this;t&&t.animation.cancel()}static supports(t){const{motionValue:r,name:n,repeatDelay:a,repeatType:s,damping:l,type:i}=t;return AT()&&n&&Jm.has(n)&&r&&r.owner&&r.owner.current instanceof HTMLElement&&!r.owner.getProps().onUpdate&&!a&&s!=="mirror"&&l!==0&&i!=="inertia"}}function LT(e,t){let r;const n=()=>{const{currentTime:a}=t,l=(a===null?0:a.value)/100;r!==l&&e(l),r=l};return z.update(n,!0),()=>gt(n)}const DT=Bp(()=>window.ScrollTimeline!==void 0);class ET{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}then(t,r){return Promise.all(this.animations).then(t).catch(r)}getAll(t){return this.animations[0][t]}setAll(t,r){for(let n=0;n{if(DT()&&n.attachTimeline)n.attachTimeline(t);else return n.pause(),LT(a=>{n.time=n.duration*a},t)});return()=>{r.forEach((n,a)=>{n&&n(),this.animations[a].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get duration(){let t=0;for(let r=0;rr[t]())}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}const Wo=(e,t,r,n={},a,s,l)=>i=>{const o=Do(n,e)||{},u=o.delay||n.delay||0;let{elapsed:c=0}=n;c=c-Wt(u);let d=q(I({keyframes:Array.isArray(r)?r:[null,r],ease:"easeOut",velocity:t.getVelocity()},o),{delay:-c,onUpdate:y=>{t.set(y),o.onUpdate&&o.onUpdate(y)},onComplete:()=>{i(),o.onComplete&&o.onComplete(),l&&l()},onStop:l,name:e,motionValue:t,element:s?void 0:a});cv(o)||(d=I(I({},d),uv(e,d))),d.duration&&(d.duration=Wt(d.duration)),d.repeatDelay&&(d.repeatDelay=Wt(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let m=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(d.duration=0,d.delay===0&&(m=!0)),m&&!s&&t.get()!==void 0){const y=ks(d.keyframes,o);if(y!==void 0)return z.update(()=>{d.onUpdate(y),d.onComplete()}),new ET([])}return!s&&tf.supports(d)?new tf(d):new Zo(d)};class Go{constructor(){this.subscriptions=[]}add(t){return Ns(this.subscriptions,t),()=>Ps(this.subscriptions,t)}notify(t,r,n){const a=this.subscriptions.length;if(a)if(a===1)this.subscriptions[0](t,r,n);else for(let s=0;s!isNaN(parseFloat(e));class nf{constructor(t,r={}){this.version="11.3.19",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(n,a=!0)=>{const s=Gt.now();this.updatedAt!==s&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(n),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),a&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=r.owner}setCurrent(t){this.current=t,this.updatedAt=Gt.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=wT(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,r){this.events[t]||(this.events[t]=new Go);const n=this.events[t].add(r);return t==="change"?()=>{n(),z.read(()=>{this.events.change.getSize()||this.stop()})}:n}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,r){this.passiveEffect=t,this.stopPassiveEffect=r}set(t,r=!0){!r||!this.passiveEffect?this.updateAndNotify(t,r):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,r,n){this.set(r),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-n}jump(t,r=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,r&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=Gt.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>rf)return 0;const r=Math.min(this.updatedAt-this.prevUpdatedAt,rf);return Up(parseFloat(this.current)-parseFloat(this.prevFrameValue),r)}start(t){return this.stop(),new Promise(r=>{this.hasAnimated=!0,this.animation=t(r),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 na(e,t){return new nf(e,t)}function jT(e,t,r){e.hasValue(t)?e.getValue(t).set(r):e.addValue(t,na(r))}function BT(e,t){let l=Os(e,t)||{},{transitionEnd:n={},transition:a={}}=l,s=je(l,["transitionEnd","transition"]);s=I(I({},s),n);for(const i in s){const o=Mb(s[i]);jT(e,i,o)}}function af(e){return e.getProps()[wm]}class NT extends nf{constructor(){super(...arguments),this.output=[],this.counts=new Map}add(t){const r=ep(t);if(!r)return;const n=this.counts.get(r)||0;this.counts.set(r,n+1),n===0&&(this.output.push(r),this.update());let a=!1;return()=>{if(a)return;a=!0;const s=this.counts.get(r)-1;this.counts.set(r,s),s===0&&(Ps(this.output,r),this.update())}}update(){this.set(this.output.length?this.output.join(", "):"auto")}}function PT(e){return!!(ve(e)&&e.add)}function Ho(e,t){var r;if(!e.applyWillChange)return;let n=e.getValue("willChange");if(!n&&!(!((r=e.props.style)===null||r===void 0)&&r.willChange)&&(n=new NT("auto"),e.addValue("willChange",n)),PT(n))return n.add(t)}function UT({protectedKeys:e,needsAnimating:t},r){const n=e.hasOwnProperty(r)&&t[r]!==!0;return t[r]=!1,n}function sf(e,t,{delay:r=0,transitionOverride:n,type:a}={}){var s;let d=t,{transition:l=e.getDefaultTransition(),transitionEnd:i}=d,o=je(d,["transition","transitionEnd"]);n&&(l=n);const u=[],c=a&&e.animationState&&e.animationState.getState()[a];for(const m in o){const y=e.getValue(m,(s=e.latestValues[m])!==null&&s!==void 0?s:null),g=o[m];if(g===void 0||c&&UT(c,m))continue;const b=I({delay:r,elapsed:0},Do(l||{},m));let C=!1;if(window.HandoffAppearAnimations){const p=af(e);if(p){const h=window.HandoffAppearAnimations(p,m,y,z);h!==null&&(b.elapsed=h,C=!0)}}y.start(Wo(m,y,g,e.shouldReduceMotion&&_t.has(m)?{type:!1}:b,e,C,Ho(e,m)));const f=y.animation;f&&u.push(f)}return i&&Promise.all(u).then(()=>{z.update(()=>{i&&BT(e,i)})}),u}function Ko(e,t,r={}){var n;const a=Os(e,t,r.type==="exit"?(n=e.presenceContext)===null||n===void 0?void 0:n.custom:void 0);let{transition:s=e.getDefaultTransition()||{}}=a||{};r.transitionOverride&&(s=r.transitionOverride);const l=a?()=>Promise.all(sf(e,a,r)):()=>Promise.resolve(),i=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:c=0,staggerChildren:d,staggerDirection:m}=s;return OT(e,t,c+u,d,m,r)}:()=>Promise.resolve(),{when:o}=s;if(o){const[u,c]=o==="beforeChildren"?[l,i]:[i,l];return u().then(()=>c())}else return Promise.all([l(),i(r.delay)])}function OT(e,t,r=0,n=0,a=1,s){const l=[],i=(e.variantChildren.size-1)*n,o=a===1?(u=0)=>u*n:(u=0)=>i-u*n;return Array.from(e.variantChildren).sort(kT).forEach((u,c)=>{u.notify("AnimationStart",t),l.push(Ko(u,t,q(I({},s),{delay:r+o(c)})).then(()=>u.notify("AnimationComplete",t)))}),Promise.all(l)}function kT(e,t){return e.sortNodePosition(t)}function RT(e,t,r={}){e.notify("AnimationStart",t);let n;if(Array.isArray(t)){const a=t.map(s=>Ko(e,s,r));n=Promise.all(a)}else if(typeof t=="string")n=Ko(e,t,r);else{const a=typeof t=="function"?Os(e,t,r.custom):t;n=Promise.all(sf(e,a,r))}return n.then(()=>{e.notify("AnimationComplete",t)})}const qT=[...uo].reverse(),MT=uo.length;function zT(e){return t=>Promise.all(t.map(({animation:r,options:n})=>RT(e,r,n)))}function FT(e){let t=zT(e),r=lf(),n=!0;const a=o=>(u,c)=>{var d;const m=Os(e,c,o==="exit"?(d=e.presenceContext)===null||d===void 0?void 0:d.custom:void 0);if(m){const y=m,{transition:g,transitionEnd:b}=y,C=je(y,["transition","transitionEnd"]);u=I(I(I({},u),C),b)}return u};function s(o){t=o(e)}function l(o){const u=e.getProps(),c=e.getVariantContext(!0)||{},d=[],m=new Set;let y={},g=1/0;for(let C=0;Cg&&v,O=!1;const B=Array.isArray(h)?h:[h];let ie=B.reduce(a(f),{});T===!1&&(ie={});const{prevResolvedValues:Kt={}}=p,hr=I(I({},Kt),ie),ua=pe=>{S=!0,m.has(pe)&&(O=!0,m.delete(pe)),p.needsAnimating[pe]=!0;const qe=e.getValue(pe);qe&&(qe.liveStyle=!1)};for(const pe in hr){const qe=ie[pe],yr=Kt[pe];if(y.hasOwnProperty(pe))continue;let D=!1;Ao(qe)&&Ao(yr)?D=!dp(qe,yr):D=qe!==yr,D?qe!=null?ua(pe):m.add(pe):qe!==void 0&&m.has(pe)?ua(pe):p.protectedKeys[pe]=!0}p.prevProp=h,p.prevResolvedValues=ie,p.isActive&&(y=I(I({},y),ie)),n&&e.blockInitialAnimation&&(S=!1),S&&(!x||O)&&d.push(...B.map(pe=>({animation:pe,options:{type:f}})))}if(m.size){const C={};m.forEach(f=>{const p=e.getBaseTarget(f),h=e.getValue(f);h&&(h.liveStyle=!0),C[f]=p!=null?p:null}),d.push({animation:C})}let b=!!d.length;return n&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(b=!1),n=!1,b?t(d):Promise.resolve()}function i(o,u){var c;if(r[o].isActive===u)return Promise.resolve();(c=e.variantChildren)===null||c===void 0||c.forEach(m=>{var y;return(y=m.animationState)===null||y===void 0?void 0:y.setActive(o,u)}),r[o].isActive=u;const d=l(o);for(const m in r)r[m].protectedKeys={};return d}return{animateChanges:l,setActive:i,setAnimateFunction:s,getState:()=>r,reset:()=>{r=lf(),n=!0}}}function _T(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!dp(t,e):!1}function mr(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function lf(){return{animate:mr(!0),whileInView:mr(),whileHover:mr(),whileTap:mr(),whileDrag:mr(),whileFocus:mr(),exit:mr()}}class VT extends $t{constructor(t){super(t),t.animationState||(t.animationState=FT(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Gn(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:r}=this.node.prevProps||{};t!==r&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)===null||t===void 0||t.call(this)}}let ZT=0;class $T extends $t{constructor(){super(...arguments),this.id=ZT++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:r}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===n)return;const a=this.node.animationState.setActive("exit",!t);r&&!t&&a.then(()=>r(this.id))}mount(){const{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}}const WT={animation:{Feature:VT},exit:{Feature:$T}},of=(e,t)=>Math.abs(e-t);function GT(e,t){const r=of(e.x,t.x),n=of(e.y,t.y);return Math.sqrt(iu(r,2)+iu(n,2))}class uf{constructor(t,r,{transformPagePoint:n,contextWindow:a,dragSnapToOrigin:s=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const d=Yo(this.lastMoveEventInfo,this.history),m=this.startEvent!==null,y=GT(d.offset,{x:0,y:0})>=3;if(!m&&!y)return;const{point:g}=d,{timestamp:b}=me;this.history.push(q(I({},g),{timestamp:b}));const{onStart:C,onMove:f}=this.handlers;m||(C&&C(this.lastMoveEvent,d),this.startEvent=this.lastMoveEvent),f&&f(this.lastMoveEvent,d)},this.handlePointerMove=(d,m)=>{this.lastMoveEvent=d,this.lastMoveEventInfo=Qo(m,this.transformPagePoint),z.update(this.updatePoint,!0)},this.handlePointerUp=(d,m)=>{this.end();const{onEnd:y,onSessionEnd:g,resumeAnimation:b}=this.handlers;if(this.dragSnapToOrigin&&b&&b(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const C=Yo(d.type==="pointercancel"?this.lastMoveEventInfo:Qo(m,this.transformPagePoint),this.history);this.startEvent&&y&&y(d,C),g&&g(d,C)},!np(t))return;this.dragSnapToOrigin=s,this.handlers=r,this.transformPagePoint=n,this.contextWindow=a||window;const l=Us(t),i=Qo(l,this.transformPagePoint),{point:o}=i,{timestamp:u}=me;this.history=[q(I({},o),{timestamp:u})];const{onSessionStart:c}=r;c&&c(t,Yo(i,this.history)),this.removeListeners=Tt(vt(this.contextWindow,"pointermove",this.handlePointerMove),vt(this.contextWindow,"pointerup",this.handlePointerUp),vt(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),gt(this.updatePoint)}}function Qo(e,t){return t?{point:t(e.point)}:e}function cf(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Yo({point:e},t){return{point:e,delta:cf(e,df(t)),offset:cf(e,HT(t)),velocity:KT(t,.1)}}function HT(e){return e[0]}function df(e){return e[e.length-1]}function KT(e,t){if(e.length<2)return{x:0,y:0};let r=e.length-1,n=null;const a=df(e);for(;r>=0&&(n=e[r],!(a.timestamp-n.timestamp>Wt(t)));)r--;if(!n)return{x:0,y:0};const s=Ct(a.timestamp-n.timestamp);if(s===0)return{x:0,y:0};const l={x:(a.x-n.x)/s,y:(a.y-n.y)/s};return l.x===1/0&&(l.x=0),l.y===1/0&&(l.y=0),l}const mf=1e-4,QT=1-mf,YT=1+mf,pf=.01,XT=0-pf,JT=0+pf;function Re(e){return e.max-e.min}function e0(e,t,r){return Math.abs(e-t)<=r}function ff(e,t,r,n=.5){e.origin=n,e.originPoint=H(t.min,t.max,e.origin),e.scale=Re(r)/Re(t),e.translate=H(r.min,r.max,e.origin)-e.originPoint,(e.scale>=QT&&e.scale<=YT||isNaN(e.scale))&&(e.scale=1),(e.translate>=XT&&e.translate<=JT||isNaN(e.translate))&&(e.translate=0)}function aa(e,t,r,n){ff(e.x,t.x,r.x,n?n.originX:void 0),ff(e.y,t.y,r.y,n?n.originY:void 0)}function hf(e,t,r){e.min=r.min+t.min,e.max=e.min+Re(t)}function t0(e,t,r){hf(e.x,t.x,r.x),hf(e.y,t.y,r.y)}function yf(e,t,r){e.min=t.min-r.min,e.max=e.min+Re(t)}function sa(e,t,r){yf(e.x,t.x,r.x),yf(e.y,t.y,r.y)}function r0(e,{min:t,max:r},n){return t!==void 0&&er&&(e=n?H(r,e,n.max):Math.min(e,r)),e}function gf(e,t,r){return{min:t!==void 0?e.min+t:void 0,max:r!==void 0?e.max+r-(e.max-e.min):void 0}}function n0(e,{top:t,left:r,bottom:n,right:a}){return{x:gf(e.x,r,a),y:gf(e.y,t,n)}}function bf(e,t){let r=t.min-e.min,n=t.max-e.max;return t.max-t.minn?r=ta(t.min,t.max-n,e.min):n>a&&(r=ta(e.min,e.max-a,t.min)),Vt(0,1,r)}function l0(e,t){const r={};return t.min!==void 0&&(r.min=t.min-e.min),t.max!==void 0&&(r.max=t.max-e.min),r}const Xo=.35;function i0(e=Xo){return e===!1?e=0:e===!0&&(e=Xo),{x:vf(e,"left","right"),y:vf(e,"top","bottom")}}function vf(e,t,r){return{min:Tf(e,t),max:Tf(e,r)}}function Tf(e,t){return typeof e=="number"?e:e[t]||0}const Cf=()=>({translate:0,scale:1,origin:0,originPoint:0}),Jr=()=>({x:Cf(),y:Cf()}),Af=()=>({min:0,max:0}),X=()=>({x:Af(),y:Af()});function We(e){return[e("x"),e("y")]}function Sf({top:e,left:t,right:r,bottom:n}){return{x:{min:t,max:r},y:{min:e,max:n}}}function o0({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function u0(e,t){if(!t)return e;const r=t({x:e.left,y:e.top}),n=t({x:e.right,y:e.bottom});return{top:r.y,left:r.x,bottom:n.y,right:n.x}}function Jo(e){return e===void 0||e===1}function eu({scale:e,scaleX:t,scaleY:r}){return!Jo(e)||!Jo(t)||!Jo(r)}function pr(e){return eu(e)||xf(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function xf(e){return If(e.x)||If(e.y)}function If(e){return e&&e!=="0%"}function Fs(e,t,r){const n=e-r,a=t*n;return r+a}function Lf(e,t,r,n,a){return a!==void 0&&(e=Fs(e,a,n)),Fs(e,r,n)+t}function tu(e,t=0,r=1,n,a){e.min=Lf(e.min,t,r,n,a),e.max=Lf(e.max,t,r,n,a)}function Df(e,{x:t,y:r}){tu(e.x,t.translate,t.scale,t.originPoint),tu(e.y,r.translate,r.scale,r.originPoint)}const Ef=.999999999999,wf=1.0000000000001;function c0(e,t,r,n=!1){const a=r.length;if(!a)return;t.x=t.y=1;let s,l;for(let i=0;iEf&&(t.x=1),t.yEf&&(t.y=1)}function en(e,t){e.min=e.min+t,e.max=e.max+t}function jf(e,t,r,n,a=.5){const s=H(e.min,e.max,a);tu(e,t,r,s,n)}function tn(e,t){jf(e.x,t.x,t.scaleX,t.scale,t.originX),jf(e.y,t.y,t.scaleY,t.scale,t.originY)}function Bf(e,t){return Sf(u0(e.getBoundingClientRect(),t))}function d0(e,t,r){const n=Bf(e,r),{scroll:a}=t;return a&&(en(n.x,a.offset.x),en(n.y,a.offset.y)),n}const Nf=({current:e})=>e?e.ownerDocument.defaultView:null,m0=new WeakMap;class p0{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=X(),this.visualElement=t}start(t,{snapToCursor:r=!1}={}){const{presenceContext:n}=this.visualElement;if(n&&n.isPresent===!1)return;const a=c=>{const{dragSnapToOrigin:d}=this.getProps();d?this.pauseAnimation():this.stopAnimation(),r&&this.snapToCursor(Us(c,"page").point)},s=(c,d)=>{var m;const{drag:y,dragPropagation:g,onDragStart:b}=this.getProps();if(y&&!g&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=ip(y),!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),We(f=>{let p=this.getAxisMotionValue(f).get()||0;if(lt.test(p)){const{projection:h}=this.visualElement;if(h&&h.layout){const v=h.layout.layoutBox[f];v&&(p=Re(v)*(parseFloat(p)/100))}}this.originPoint[f]=p}),b&&z.postRender(()=>b(c,d)),(m=this.removeWillChange)===null||m===void 0||m.call(this),this.removeWillChange=Ho(this.visualElement,"transform");const{animationState:C}=this.visualElement;C&&C.setActive("whileDrag",!0)},l=(c,d)=>{const{dragPropagation:m,dragDirectionLock:y,onDirectionLock:g,onDrag:b}=this.getProps();if(!m&&!this.openGlobalLock)return;const{offset:C}=d;if(y&&this.currentDirection===null){this.currentDirection=f0(C),this.currentDirection!==null&&g&&g(this.currentDirection);return}this.updateAxis("x",d.point,C),this.updateAxis("y",d.point,C),this.visualElement.render(),b&&b(c,d)},i=(c,d)=>this.stop(c,d),o=()=>We(c=>{var d;return this.getAnimationState(c)==="paused"&&((d=this.getAxisMotionValue(c).animation)===null||d===void 0?void 0:d.play())}),{dragSnapToOrigin:u}=this.getProps();this.panSession=new uf(t,{onSessionStart:a,onStart:s,onMove:l,onSessionEnd:i,resumeAnimation:o},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,contextWindow:Nf(this.visualElement)})}stop(t,r){var n;(n=this.removeWillChange)===null||n===void 0||n.call(this);const a=this.isDragging;if(this.cancel(),!a)return;const{velocity:s}=r;this.startAnimation(s);const{onDragEnd:l}=this.getProps();l&&z.postRender(()=>l(t,r))}cancel(){this.isDragging=!1;const{projection:t,animationState:r}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:n}=this.getProps();!n&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),r&&r.setActive("whileDrag",!1)}updateAxis(t,r,n){const{drag:a}=this.getProps();if(!n||!_s(t,a,this.currentDirection))return;const s=this.getAxisMotionValue(t);let l=this.originPoint[t]+n[t];this.constraints&&this.constraints[t]&&(l=r0(l,this.constraints[t],this.elastic[t])),s.set(l)}resolveConstraints(){var t;const{dragConstraints:r,dragElastic:n}=this.getProps(),a=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(t=this.visualElement.projection)===null||t===void 0?void 0:t.layout,s=this.constraints;r&&Hr(r)?this.constraints||(this.constraints=this.resolveRefConstraints()):r&&a?this.constraints=n0(a.layoutBox,r):this.constraints=!1,this.elastic=i0(n),s!==this.constraints&&a&&this.constraints&&!this.hasMutatedConstraints&&We(l=>{this.constraints!==!1&&this.getAxisMotionValue(l)&&(this.constraints[l]=l0(a.layoutBox[l],this.constraints[l]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:r}=this.getProps();if(!t||!Hr(t))return!1;const n=t.current,{projection:a}=this.visualElement;if(!a||!a.layout)return!1;const s=d0(n,a.root,this.visualElement.getTransformPagePoint());let l=a0(a.layout.layoutBox,s);if(r){const i=r(o0(l));this.hasMutatedConstraints=!!i,i&&(l=Sf(i))}return l}startAnimation(t){const{drag:r,dragMomentum:n,dragElastic:a,dragTransition:s,dragSnapToOrigin:l,onDragTransitionEnd:i}=this.getProps(),o=this.constraints||{},u=We(c=>{if(!_s(c,r,this.currentDirection))return;let d=o&&o[c]||{};l&&(d={min:0,max:0});const m=a?200:1e6,y=a?40:1e7,g=I(I({type:"inertia",velocity:n?t[c]:0,bounceStiffness:m,bounceDamping:y,timeConstant:750,restDelta:1,restSpeed:10},s),d);return this.startAxisValueAnimation(c,g)});return Promise.all(u).then(i)}startAxisValueAnimation(t,r){const n=this.getAxisMotionValue(t);return n.start(Wo(t,n,0,r,this.visualElement,!1,Ho(this.visualElement,t)))}stopAnimation(){We(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){We(t=>{var r;return(r=this.getAxisMotionValue(t).animation)===null||r===void 0?void 0:r.pause()})}getAnimationState(t){var r;return(r=this.getAxisMotionValue(t).animation)===null||r===void 0?void 0:r.state}getAxisMotionValue(t){const r=`_drag${t.toUpperCase()}`,n=this.visualElement.getProps(),a=n[r];return a||this.visualElement.getValue(t,(n.initial?n.initial[t]:void 0)||0)}snapToCursor(t){We(r=>{const{drag:n}=this.getProps();if(!_s(r,n,this.currentDirection))return;const{projection:a}=this.visualElement,s=this.getAxisMotionValue(r);if(a&&a.layout){const{min:l,max:i}=a.layout.layoutBox[r];s.set(t[r]-H(l,i,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:r}=this.getProps(),{projection:n}=this.visualElement;if(!Hr(r)||!n||!this.constraints)return;this.stopAnimation();const a={x:0,y:0};We(l=>{const i=this.getAxisMotionValue(l);if(i&&this.constraints!==!1){const o=i.get();a[l]=s0({min:o,max:o},this.constraints[l])}});const{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),We(l=>{if(!_s(l,t,null))return;const i=this.getAxisMotionValue(l),{min:o,max:u}=this.constraints[l];i.set(H(o,u,a[l]))})}addListeners(){if(!this.visualElement.current)return;m0.set(this.visualElement,this);const t=this.visualElement.current,r=vt(t,"pointerdown",o=>{const{drag:u,dragListener:c=!0}=this.getProps();u&&c&&this.start(o)}),n=()=>{const{dragConstraints:o}=this.getProps();Hr(o)&&o.current&&(this.constraints=this.resolveRefConstraints())},{projection:a}=this.visualElement,s=a.addEventListener("measure",n);a&&!a.layout&&(a.root&&a.root.updateScroll(),a.updateLayout()),z.read(n);const l=bt(window,"resize",()=>this.scalePositionWithinConstraints()),i=a.addEventListener("didUpdate",({delta:o,hasLayoutChanged:u})=>{this.isDragging&&u&&(We(c=>{const d=this.getAxisMotionValue(c);d&&(this.originPoint[c]+=o[c].translate,d.set(d.get()+o[c].translate))}),this.visualElement.render())});return()=>{l(),r(),s(),i&&i()}}getProps(){const t=this.visualElement.getProps(),{drag:r=!1,dragDirectionLock:n=!1,dragPropagation:a=!1,dragConstraints:s=!1,dragElastic:l=Xo,dragMomentum:i=!0}=t;return q(I({},t),{drag:r,dragDirectionLock:n,dragPropagation:a,dragConstraints:s,dragElastic:l,dragMomentum:i})}}function _s(e,t,r){return(t===!0||t===e)&&(r===null||r===e)}function f0(e,t=10){let r=null;return Math.abs(e.y)>t?r="y":Math.abs(e.x)>t&&(r="x"),r}class h0 extends $t{constructor(t){super(t),this.removeGroupControls=be,this.removeListeners=be,this.controls=new p0(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||be}unmount(){this.removeGroupControls(),this.removeListeners()}}const Pf=e=>(t,r)=>{e&&z.postRender(()=>e(t,r))};class y0 extends $t{constructor(){super(...arguments),this.removePointerDownListener=be}onPointerDown(t){this.session=new uf(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Nf(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:r,onPan:n,onPanEnd:a}=this.node.getProps();return{onSessionStart:Pf(t),onStart:Pf(r),onMove:n,onEnd:(s,l)=>{delete this.session,a&&z.postRender(()=>a(s,l))}}}mount(){this.removePointerDownListener=vt(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 g0(){const e=w.useContext(lo);if(e===null)return[!0,null];const{isPresent:t,onExitComplete:r,register:n}=e,a=w.useId();w.useEffect(()=>n(a),[]);const s=w.useCallback(()=>r&&r(a),[a,r]);return!t&&r?[!1,s]:[!0]}const Vs={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function Uf(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const la={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(j.test(e))e=parseFloat(e);else return e;const r=Uf(e,t.target.x),n=Uf(e,t.target.y);return`${r}% ${n}%`}},b0={correct:(e,{treeScale:t,projectionDelta:r})=>{const n=e,a=Ht.parse(e);if(a.length>5)return n;const s=Ht.createTransformer(e),l=typeof a[0]!="number"?1:0,i=r.x.scale*t.x,o=r.y.scale*t.y;a[0+l]/=i,a[1+l]/=o;const u=H(i,o,.5);return typeof a[2+l]=="number"&&(a[2+l]/=u),typeof a[3+l]=="number"&&(a[3+l]/=u),s(a)}};class v0 extends w.Component{componentDidMount(){const{visualElement:t,layoutGroup:r,switchLayoutGroup:n,layoutId:a}=this.props,{projection:s}=t;pb(T0),s&&(r.group&&r.group.add(s),n&&n.register&&a&&n.register(s),s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions(q(I({},s.options),{onExitComplete:()=>this.safeToRemove()}))),Vs.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:r,visualElement:n,drag:a,isPresent:s}=this.props,l=n.projection;return l&&(l.isPresent=s,a||t.layoutDependency!==r||r===void 0?l.willUpdate():this.safeToRemove(),t.isPresent!==s&&(s?l.promote():l.relegate()||z.postRender(()=>{const i=l.getStack();(!i||!i.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),oo.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:r,switchLayoutGroup:n}=this.props,{projection:a}=t;a&&(a.scheduleCheckAfterUnmount(),r&&r.group&&r.group.remove(a),n&&n.deregister&&n.deregister(a))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function Of(e){const[t,r]=g0(),n=w.useContext(Rm);return k.jsx(v0,q(I({},e),{layoutGroup:n,switchLayoutGroup:w.useContext(Bm),isPresent:t,safeToRemove:r}))}const T0={borderRadius:q(I({},la),{applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]}),borderTopLeftRadius:la,borderTopRightRadius:la,borderBottomLeftRadius:la,borderBottomRightRadius:la,boxShadow:b0},kf=["TopLeft","TopRight","BottomLeft","BottomRight"],C0=kf.length,Rf=e=>typeof e=="string"?parseFloat(e):e,qf=e=>typeof e=="number"||j.test(e);function A0(e,t,r,n,a,s){a?(e.opacity=H(0,r.opacity!==void 0?r.opacity:1,S0(n)),e.opacityExit=H(t.opacity!==void 0?t.opacity:1,0,x0(n))):s&&(e.opacity=H(t.opacity!==void 0?t.opacity:1,r.opacity!==void 0?r.opacity:1,n));for(let l=0;lnt?1:r(ta(e,t,n))}function Ff(e,t){e.min=t.min,e.max=t.max}function Ge(e,t){Ff(e.x,t.x),Ff(e.y,t.y)}function _f(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function Vf(e,t,r,n,a){return e-=t,e=Fs(e,1/r,n),a!==void 0&&(e=Fs(e,1/a,n)),e}function I0(e,t=0,r=1,n=.5,a,s=e,l=e){if(lt.test(t)&&(t=parseFloat(t),t=H(l.min,l.max,t/100)-l.min),typeof t!="number")return;let i=H(s.min,s.max,n);e===s&&(i-=t),e.min=Vf(e.min,t,r,i,a),e.max=Vf(e.max,t,r,i,a)}function Zf(e,t,[r,n,a],s,l){I0(e,t[r],t[n],t[a],t.scale,s,l)}const L0=["x","scaleX","originX"],D0=["y","scaleY","originY"];function $f(e,t,r,n){Zf(e.x,t,L0,r?r.x:void 0,n?n.x:void 0),Zf(e.y,t,D0,r?r.y:void 0,n?n.y:void 0)}function Wf(e){return e.translate===0&&e.scale===1}function Gf(e){return Wf(e.x)&&Wf(e.y)}function Hf(e,t){return e.min===t.min&&e.max===t.max}function E0(e,t){return Hf(e.x,t.x)&&Hf(e.y,t.y)}function Kf(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Qf(e,t){return Kf(e.x,t.x)&&Kf(e.y,t.y)}function Yf(e){return Re(e.x)/Re(e.y)}function Xf(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class w0{constructor(){this.members=[]}add(t){Ns(this.members,t),t.scheduleRender()}remove(t){if(Ps(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const r=this.members[this.members.length-1];r&&this.promote(r)}}relegate(t){const r=this.members.findIndex(a=>t===a);if(r===0)return!1;let n;for(let a=r;a>=0;a--){const s=this.members[a];if(s.isPresent!==!1){n=s;break}}return n?(this.promote(n),!0):!1}promote(t,r){const n=this.lead;if(t!==n&&(this.prevLead=n,this.lead=t,t.show(),n)){n.instance&&n.scheduleRender(),t.scheduleRender(),t.resumeFrom=n,r&&(t.resumeFrom.preserveOpacity=!0),n.snapshot&&(t.snapshot=n.snapshot,t.snapshot.latestValues=n.animationValues||n.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:a}=t.options;a===!1&&n.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:r,resumingFrom:n}=t;r.onExitComplete&&r.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function j0(e,t,r){let n="";const a=e.x.translate/t.x,s=e.y.translate/t.y,l=(r==null?void 0:r.z)||0;if((a||s||l)&&(n=`translate3d(${a}px, ${s}px, ${l}px) `),(t.x!==1||t.y!==1)&&(n+=`scale(${1/t.x}, ${1/t.y}) `),r){const{transformPerspective:u,rotate:c,rotateX:d,rotateY:m,skewX:y,skewY:g}=r;u&&(n=`perspective(${u}px) ${n}`),c&&(n+=`rotate(${c}deg) `),d&&(n+=`rotateX(${d}deg) `),m&&(n+=`rotateY(${m}deg) `),y&&(n+=`skewX(${y}deg) `),g&&(n+=`skewY(${g}deg) `)}const i=e.x.scale*t.x,o=e.y.scale*t.y;return(i!==1||o!==1)&&(n+=`scale(${i}, ${o})`),n||"none"}const B0=(e,t)=>e.depth-t.depth;class N0{constructor(){this.children=[],this.isDirty=!1}add(t){Ns(this.children,t),this.isDirty=!0}remove(t){Ps(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(B0),this.isDirty=!1,this.children.forEach(t)}}function P0(e,t){const r=Gt.now(),n=({timestamp:a})=>{const s=a-r;s>=t&&(gt(n),e(s-t))};return z.read(n,!0),()=>gt(n)}function U0(e){return e instanceof SVGElement&&e.tagName!=="svg"}function O0(e,t,r){const n=ve(e)?e:na(e);return n.start(Wo("",n,t,r)),n.animation}const fr={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},ia=typeof window!="undefined"&&window.MotionDebug!==void 0,ru=["","X","Y","Z"],k0={visibility:"hidden"},Jf=1e3;let R0=0;function nu(e,t,r,n){const{latestValues:a}=t;a[e]&&(r[e]=a[e],t.setStaticValue(e,0),n&&(n[e]=0))}function eh(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return!1;const{visualElement:t}=e.options;return t?af(t)?!0:e.parent&&!e.parent.hasCheckedOptimisedAppear?eh(e.parent):!1:!1}function th({attachResizeListener:e,defaultParent:t,measureScroll:r,checkIsScrollRoot:n,resetTransform:a}){return class{constructor(l={},i=t==null?void 0:t()){this.id=R0++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,ia&&(fr.totalNodes=fr.resolvedTargetDeltas=fr.recalculatedProjection=0),this.nodes.forEach(z0),this.nodes.forEach($0),this.nodes.forEach(W0),this.nodes.forEach(F0),ia&&window.MotionDebug.record(fr)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=l,this.root=i?i.root||i:this,this.path=i?[...i.path,i]:[],this.parent=i,this.depth=i?i.depth+1:0;for(let o=0;othis.root.updateBlockedByResize=!1;e(l,()=>{this.root.updateBlockedByResize=!0,d&&d(),d=P0(m,250),Vs.hasAnimatedSinceResize&&(Vs.hasAnimatedSinceResize=!1,this.nodes.forEach(nh))})}o&&this.root.registerSharedNode(o,this),this.options.animate!==!1&&c&&(o||u)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:m,hasRelativeTargetChanged:y,layout:g})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const b=this.options.transition||c.getDefaultTransition()||Y0,{onLayoutAnimationStart:C,onLayoutAnimationComplete:f}=c.getProps(),p=!this.targetLayout||!Qf(this.targetLayout,g)||y,h=!m&&y;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||h||m&&(p||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(d,h);const v=q(I({},Do(b,"layout")),{onPlay:C,onComplete:f});(c.shouldReduceMotion||this.options.layoutRoot)&&(v.delay=0,v.type=!1),this.startAnimation(v)}else m||nh(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=g})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const l=this.getStack();l&&l.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,gt(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(G0),this.animationId++)}getTransformTemplate(){const{visualElement:l}=this.options;return l&&l.getProps().transformTemplate}willUpdate(l=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.HandoffCancelAllAnimations&&eh(this)&&window.HandoffCancelAllAnimations(),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let c=0;c{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let o=0;o{const T=v/1e3;ah(d.x,l.x,T),ah(d.y,l.y,T),this.setTargetDelta(d),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(sa(m,this.layout.layoutBox,this.relativeParent.layout.layoutBox),K0(this.relativeTarget,this.relativeTargetOrigin,m,T),h&&E0(this.relativeTarget,h)&&(this.isProjectionDirty=!1),h||(h=X()),Ge(h,this.relativeTarget)),b&&(this.animationValues=c,A0(c,u,this.latestValues,T,p,f)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=T},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(l){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(gt(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=z.update(()=>{Vs.hasAnimatedSinceResize=!0,this.currentAnimation=O0(0,Jf,q(I({},l),{onUpdate:i=>{this.mixTargetDelta(i),l.onUpdate&&l.onUpdate(i)},onComplete:()=>{l.onComplete&&l.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 l=this.getStack();l&&l.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Jf),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const l=this.getLead();let{targetWithTransforms:i,target:o,layout:u,latestValues:c}=l;if(!(!i||!o||!u)){if(this!==l&&this.layout&&u&&uh(this.options.animationType,this.layout.layoutBox,u.layoutBox)){o=this.target||X();const d=Re(this.layout.layoutBox.x);o.x.min=l.target.x.min,o.x.max=o.x.min+d;const m=Re(this.layout.layoutBox.y);o.y.min=l.target.y.min,o.y.max=o.y.min+m}Ge(i,o),tn(i,c),aa(this.projectionDeltaWithTransform,this.layoutCorrected,i,c)}}registerSharedNode(l,i){this.sharedNodes.has(l)||this.sharedNodes.set(l,new w0),this.sharedNodes.get(l).add(i);const u=i.options.initialPromotionConfig;i.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(i):void 0})}isLead(){const l=this.getStack();return l?l.lead===this:!0}getLead(){var l;const{layoutId:i}=this.options;return i?((l=this.getStack())===null||l===void 0?void 0:l.lead)||this:this}getPrevLead(){var l;const{layoutId:i}=this.options;return i?(l=this.getStack())===null||l===void 0?void 0:l.prevLead:void 0}getStack(){const{layoutId:l}=this.options;if(l)return this.root.sharedNodes.get(l)}promote({needsReset:l,transition:i,preserveFollowOpacity:o}={}){const u=this.getStack();u&&u.promote(this,o),l&&(this.projectionDelta=void 0,this.needsReset=!0),i&&this.setOptions({transition:i})}relegate(){const l=this.getStack();return l?l.relegate(this):!1}resetSkewAndRotation(){const{visualElement:l}=this.options;if(!l)return;let i=!1;const{latestValues:o}=l;if((o.z||o.rotate||o.rotateX||o.rotateY||o.rotateZ||o.skewX||o.skewY)&&(i=!0),!i)return;const u={};o.z&&nu("z",l,u,this.animationValues);for(let c=0;c{var i;return(i=l.currentAnimation)===null||i===void 0?void 0:i.stop()}),this.root.nodes.forEach(rh),this.root.sharedNodes.clear()}}}function q0(e){e.updateLayout()}function M0(e){var t;const r=((t=e.resumeFrom)===null||t===void 0?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&r&&e.hasListeners("didUpdate")){const{layoutBox:n,measuredBox:a}=e.layout,{animationType:s}=e.options,l=r.source!==e.layout.source;s==="size"?We(d=>{const m=l?r.measuredBox[d]:r.layoutBox[d],y=Re(m);m.min=n[d].min,m.max=m.min+y}):uh(s,r.layoutBox,n)&&We(d=>{const m=l?r.measuredBox[d]:r.layoutBox[d],y=Re(n[d]);m.max=m.min+y,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+y)});const i=Jr();aa(i,n,r.layoutBox);const o=Jr();l?aa(o,e.applyTransform(a,!0),r.measuredBox):aa(o,n,r.layoutBox);const u=!Gf(i);let c=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:m,layout:y}=d;if(m&&y){const g=X();sa(g,r.layoutBox,m.layoutBox);const b=X();sa(b,n,y.layoutBox),Qf(g,b)||(c=!0),d.options.layoutRoot&&(e.relativeTarget=b,e.relativeTargetOrigin=g,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:n,snapshot:r,delta:o,layoutDelta:i,hasLayoutChanged:u,hasRelativeTargetChanged:c})}else if(e.isLead()){const{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function z0(e){ia&&fr.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 F0(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function _0(e){e.clearSnapshot()}function rh(e){e.clearMeasurements()}function V0(e){e.isLayoutDirty=!1}function Z0(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function nh(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function $0(e){e.resolveTargetDelta()}function W0(e){e.calcProjection()}function G0(e){e.resetSkewAndRotation()}function H0(e){e.removeLeadSnapshot()}function ah(e,t,r){e.translate=H(t.translate,0,r),e.scale=H(t.scale,1,r),e.origin=t.origin,e.originPoint=t.originPoint}function sh(e,t,r,n){e.min=H(t.min,r.min,n),e.max=H(t.max,r.max,n)}function K0(e,t,r,n){sh(e.x,t.x,r.x,n),sh(e.y,t.y,r.y,n)}function Q0(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const Y0={duration:.45,ease:[.4,0,.1,1]},lh=e=>typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),ih=lh("applewebkit/")&&!lh("chrome/")?Math.round:be;function oh(e){e.min=ih(e.min),e.max=ih(e.max)}function X0(e){oh(e.x),oh(e.y)}function uh(e,t,r){return e==="position"||e==="preserve-aspect"&&!e0(Yf(t),Yf(r),.2)}function J0(e){var t;return e!==e.root&&((t=e.scroll)===null||t===void 0?void 0:t.wasRoot)}const eC=th({attachResizeListener:(e,t)=>bt(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),au={current:void 0},ch=th({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!au.current){const e=new eC({});e.mount(window),e.setOptions({layoutScroll:!0}),au.current=e}return au.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),tC={pan:{Feature:y0},drag:{Feature:h0,ProjectionNode:ch,MeasureLayout:Of}},su={current:null},dh={current:!1};function rC(){if(dh.current=!0,!!io)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>su.current=e.matches;e.addListener(t),t()}else su.current=!1}function nC(e,t,r){for(const n in t){const a=t[n],s=r[n];if(ve(a))e.addValue(n,a);else if(ve(s))e.addValue(n,na(a,{owner:e}));else if(s!==a)if(e.hasValue(n)){const l=e.getValue(n);l.liveStyle===!0?l.jump(a):l.hasAnimated||l.set(a)}else{const l=e.getStaticValue(n);e.addValue(n,na(l!==void 0?l:a,{owner:e}))}}for(const n in r)t[n]===void 0&&e.removeValue(n);return t}const mh=new WeakMap,aC=[...vp,Te,Ht],sC=e=>aC.find(bp(e)),ph=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],lC=co.length;class iC{scrapeMotionValuesFromProps(t,r,n){return{}}constructor({parent:t,props:r,presenceContext:n,reducedMotionConfig:a,blockInitialAnimation:s,visualState:l},i={}){this.applyWillChange=!1,this.resolveKeyframes=(y,g,b,C)=>new this.KeyframeResolver(y,g,b,C,this),this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=jo,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.isRenderScheduled=!1,this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.isRenderScheduled=!1,this.scheduleRender=()=>{this.isRenderScheduled||(this.isRenderScheduled=!0,z.render(this.render,!1,!0))};const{latestValues:o,renderState:u}=l;this.latestValues=o,this.baseTarget=I({},o),this.initialValues=r.initial?I({},o):{},this.renderState=u,this.parent=t,this.props=r,this.presenceContext=n,this.depth=t?t.depth+1:0,this.reducedMotionConfig=a,this.options=i,this.blockInitialAnimation=!!s,this.isControllingVariants=Ds(r),this.isVariantNode=Um(r),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const m=this.scrapeMotionValuesFromProps(r,{},this),{willChange:c}=m,d=je(m,["willChange"]);for(const y in d){const g=d[y];o[y]!==void 0&&ve(g)&&g.set(o[y],!1)}}mount(t){this.current=t,mh.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((r,n)=>this.bindToMotionValue(n,r)),dh.current||rC(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:su.current,this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){mh.delete(this.current),this.projection&&this.projection.unmount(),gt(this.notifyUpdate),gt(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){const r=this.features[t];r&&(r.unmount(),r.isMounted=!1)}this.current=null}bindToMotionValue(t,r){const n=_t.has(t),a=r.on("change",l=>{this.latestValues[t]=l,this.props.onUpdate&&z.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)}),s=r.on("renderRequest",this.scheduleRender);this.valueSubscriptions.set(t,()=>{a(),s(),r.owner&&r.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Kr){const r=Kr[t];if(!r)continue;const{isEnabled:n,Feature:a}=r;if(!this.features[t]&&a&&n(this.props)&&(this.features[t]=new a(this)),this.features[t]){const s=this.features[t];s.isMounted?s.update():(s.mount(),s.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):X()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,r){this.latestValues[t]=r}update(t,r){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=r;for(let n=0;nr.variantChildren.delete(t)}addValue(t,r){const n=this.values.get(t);r!==n&&(n&&this.removeValue(t),this.bindToMotionValue(t,r),this.values.set(t,r),this.latestValues[t]=r.get())}removeValue(t){this.values.delete(t);const r=this.valueSubscriptions.get(t);r&&(r(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,r){if(this.props.values&&this.props.values[t])return this.props.values[t];let n=this.values.get(t);return n===void 0&&r!==void 0&&(n=na(r===null?void 0:r,{owner:this}),this.addValue(t,n)),n}readValue(t,r){var n;let a=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);return a!=null&&(typeof a=="string"&&(pp(a)||mp(a))?a=parseFloat(a):!sC(a)&&Ht.test(r)&&(a=wp(t,r)),this.setBaseTarget(t,ve(a)?a.get():a)),ve(a)?a.get():a}setBaseTarget(t,r){this.baseTarget[t]=r}getBaseTarget(t){var r;const{initial:n}=this.props;let a;if(typeof n=="string"||typeof n=="object"){const l=Co(this.props,n,(r=this.presenceContext)===null||r===void 0?void 0:r.custom);l&&(a=l[t])}if(n&&a!==void 0)return a;const s=this.getBaseTargetFromProps(this.props,t);return s!==void 0&&!ve(s)?s:this.initialValues[t]!==void 0&&a===void 0?void 0:this.baseTarget[t]}on(t,r){return this.events[t]||(this.events[t]=new Go),this.events[t].add(r)}notify(t,...r){this.events[t]&&this.events[t].notify(...r)}}class fh extends iC{constructor(){super(...arguments),this.KeyframeResolver=jp}sortInstanceNodePosition(t,r){return t.compareDocumentPosition(r)&2?1:-1}getBaseTargetFromProps(t,r){return t.style?t.style[r]:void 0}removeValueFromRenderState(t,{vars:r,style:n}){delete r[t],delete n[t]}}function oC(e){return window.getComputedStyle(e)}class uC extends fh{constructor(){super(...arguments),this.type="html",this.applyWillChange=!0,this.renderInstance=Hm}readValueFromInstance(t,r){if(_t.has(r)){const n=Oo(r);return n&&n.default||0}else{const n=oC(t),a=(zm(r)?n.getPropertyValue(r):n[r])||0;return typeof a=="string"?a.trim():a}}measureInstanceViewportBox(t,{transformPagePoint:r}){return Bf(t,r)}build(t,r,n){yo(t,r,n.transformTemplate)}scrapeMotionValuesFromProps(t,r,n){return To(t,r,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;ve(t)&&(this.childSubscription=t.on("change",r=>{this.current&&(this.current.textContent=`${r}`)}))}}class cC extends fh{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=X}getBaseTargetFromProps(t,r){return t[r]}readValueFromInstance(t,r){if(_t.has(r)){const n=Oo(r);return n&&n.default||0}return r=Km.has(r)?r:Is(r),t.getAttribute(r)}scrapeMotionValuesFromProps(t,r,n){return Ym(t,r,n)}build(t,r,n){bo(t,r,this.isSVGTag,n.transformTemplate)}renderInstance(t,r,n,a){Qm(t,r,n,a)}mount(t){this.isSVGTag=vo(t.tagName),super.mount(t)}}const dC=(e,t)=>po(e)?new cC(t):new uC(t,{allowProjection:e!==w.Fragment}),mC={layout:{ProjectionNode:ch,MeasureLayout:Of}},pC=I(I(I(I({},WT),av),tC),mC),fC=db((e,t)=>$b(e,t,pC,dC)),hh={name:"dc-connectors",private:!0,version:"0.1.2",type:"module",scripts:{dev:"vite",build:"vite build","build:connectors":"node ./scripts/build-connectors.js","build:mulesoft":"node ./scripts/build-mulesoft.js",lint:"eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",preview:"vite preview",commit:"git-cz"},dependencies:{"framer-motion":"^11.2.11",react:"^18.2.0","react-aria-components":"^1.2.1","react-dom":"^18.2.0","tailwindcss-animate":"^1.0.7","tailwindcss-react-aria-components":"^1.1.3"},devDependencies:{"@types/react":"^18.2.66","@types/react-dom":"^18.2.22","@typescript-eslint/eslint-plugin":"^7.2.0","@typescript-eslint/parser":"^7.2.0","@vitejs/plugin-react":"^4.2.1",autoprefixer:"^10.4.19",eslint:"^8.57.0","eslint-plugin-react-hooks":"^4.6.0","eslint-plugin-react-refresh":"^0.4.6",postcss:"^8.4.38","postcss-prefix-selector":"^1.16.1",tailwindcss:"^3.4.3",typescript:"^5.2.2",vite:"^5.2.0"},config:{commitizen:{path:"./node_modules/cz-conventional-changelog"}}},hC={hidden:{opacity:0,y:20},visible:{opacity:1,y:0,transition:{duration:.6,ease:[.45,.14,.1,.97]}}},yC=hh.version,gC=`https://a.sfdcstatic.com/digital/@sfdc-www/open-blade-libs/${hh.name}/v${yC}`,oa=new URLSearchParams(window.location.search).has("retroMode"),bC=({index:e,item:t,isVisible:r,shouldAnimate:n})=>{const a=s=>k.jsxs(fC.div,{className:`card shadow-lg p-4 rounded-lg flex items-center ${oa?"bg-black border-2 text-green-400 font-mono border-yellow-400":""}`,initial:"hidden",variants:hC,"data-index":e,animate:n?"visible":"hidden",children:[k.jsx("div",{className:`flex-none py-3 pr-4 ${oa?"border-yellow-400":"border-gray-200"} border-r-2`,children:k.jsx("img",{role:"presentation",src:gC+t.iconUrl,alt:t.label,className:"w-10 h-10 align-middle"})}),k.jsxs("div",{className:"pl-4 flex-grow overflow-hidden items-center",children:[k.jsxs("div",{className:"flex-grow",children:[t.releaseLevel==="IN_DEV"&&k.jsx("div",{className:"px-2 py-1 bg-gray-800 rounded-xl border border-gray-800 justify-center items-center inline-flex mb-2",children:k.jsx("div",{className:"text-white text-[10px] font-bold leading-none tracking-tight",children:"Coming Soon"})}),t.releaseLevel==="BETA"&&k.jsx("div",{className:`px-2 py-1 rounded-xl border justify-center items-center inline-flex mb-2 ${oa?"bg-fuchsia-500 text-white":"text-fuchsia-700 border-violet-50 bg-violet-50"}`,children:k.jsx("div",{className:"text-[10px] font-bold leading-none tracking-tight",children:"Beta"})})]}),k.jsx("h3",{className:`mb-2 font-bold overflow-hidden truncate ${oa?"text-green-400":"text-sfnavy"}`,children:t.label}),k.jsxs("p",{className:`text-xs ${oa?"text-green-400":"text-gray-800"}`,children:[s&&(s.length>120?`${s.substring(0,120)}...`:s),t.releaseLevel==="MuleSoft"&&"Ingest data via MuleSoft’s Anypoint Exchange"]})]})]},e);return k.jsxs(k.Fragment,{children:[a(t.ingressDescription),t.egressDescription&&a(t.egressDescription)]})},vC=Gg.map(e=>q(I({},e),{name:e.label||"",features:e.label||[],featuresConfig:{IncrementalUpdate:{deleteSupport:"No"}},connectionAttributes:{},extractAttributes:{}})),TC=[...Wg.filter(e=>e.releaseLevel!=="IN_DEV"&&e.releaseLevel!=="PILOT"&&e.name!=="OCI"&&e.name!=="TenantBillingUsageConnector"),...vC,Hg].sort((e,t)=>e.label.localeCompare(t.label));function CC(){const[e,t]=w.useState(""),[r,n]=w.useState(new Set),[a,s]=w.useState(new Set),[l,i]=w.useState(0),o=y=>{t(y.target.value),n(new Set)},u=TC.filter(y=>e?e==="GA"?y.releaseLevel==="GA"||y.releaseLevel==="MuleSoft":y.releaseLevel===e:!0);w.useEffect(()=>{i(u.length)},[u]);const c=w.useRef(new IntersectionObserver(y=>{const g=y.filter(b=>b.isIntersecting);if(g.length){const b=new Set(r),C=new Set(a);g.forEach(f=>{const p=Number(f.target.getAttribute("data-index"));b.add(p),C.add(p)}),n(b),s(C)}},{threshold:.5}));w.useEffect(()=>{const y=c.current;return document.querySelectorAll(".card").forEach(b=>{y.observe(b)}),()=>{y.disconnect()}},[u]);const m=new URLSearchParams(window.location.search).has("retroMode");return k.jsxs(k.Fragment,{children:[m&&k.jsx("style",{children:` .relative.marquee--blade.marquee--center { background: #000; } .marquee--blade .blade__description p, .marquee--blade .container .grid.grid_main .content__wrapper .marquee__blade-heading .headline { color: rgb(74 222 128); font-family: monospace; } a.cta_button[data-variant=primary] { background-color: yellow; color: black; border: 3px solid rgb(74 222 128); outline:none; } `}),k.jsx("div",{className:`${m?"bg-black text-green-400 py-10":""}`,children:k.jsx("div",{className:"container mx-auto lg:mt-0 md:mt-5 pt-0 min-h-screen ",children:k.jsxs("div",{className:"flex flex-col items-center min-h-screen text-gray-900 font-sans",children:[k.jsxs("div",{className:"flex space-x-4 mb-6",children:[k.jsx("label",{htmlFor:"filter",className:`mr-2 font-bold text-[18px]${m?"text-green-400":""}`,children:"Filter:"}),k.jsxs("select",{id:"filter",value:e,onChange:o,className:`border p-1 rounded ${m?"bg-black text-green-400 border-green-400":""}`,children:[k.jsx("option",{value:"",children:"All"}),k.jsx("option",{value:"BETA",children:"Beta"}),k.jsx("option",{value:"GA",children:"General Availability"})]})]}),m&&k.jsxs("div",{id:"connectorCounter",className:"mb-4 font-mono text-4xl text-green-600 bg-black p-4 rounded",children:[l," Data Sources"]}),!m&&k.jsxs("div",{id:"connectorCounter",className:" mb-4",children:[l," Data Sources"]}),k.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-3 gap-6 p-4",children:u.map((y,g)=>k.jsx(bC,{index:g,item:y,isVisible:r.has(g)||a.has(g),shouldAnimate:r.has(g),"data-index":g,retroMode:m},g))})]})})})]})}Xs.createRoot(document.getElementById("wps-dc-integrator")).render(k.jsx(Uh.StrictMode,{children:k.jsx(CC,{})}))});