(function(K){typeof define=="function"&&define.amd?define(K):K()})(function(){"use strict";var kT=Object.defineProperty,RT=Object.defineProperties;var qT=Object.getOwnPropertyDescriptors;var $s=Object.getOwnPropertySymbols;var Dy=Object.prototype.hasOwnProperty,wy=Object.prototype.propertyIsEnumerable;var fu=Math.pow,Ey=(K,le,re)=>le in K?kT(K,le,{enumerable:!0,configurable:!0,writable:!0,value:re}):K[le]=re,I=(K,le)=>{for(var re in le||(le={}))Dy.call(le,re)&&Ey(K,re,le[re]);if($s)for(var re of $s(le))wy.call(le,re)&&Ey(K,re,le[re]);return K},k=(K,le)=>RT(K,qT(le));var We=(K,le)=>{var re={};for(var qe in K)Dy.call(K,qe)&&le.indexOf(qe)<0&&(re[qe]=K[qe]);if(K!=null&&$s)for(var qe of $s(K))le.indexOf(qe)<0&&wy.call(K,qe)&&(re[qe]=K[qe]);return re};function K(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var le={exports:{}},re={},qe={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 tn=Symbol.for("react.element"),jy=Symbol.for("react.portal"),Ny=Symbol.for("react.fragment"),By=Symbol.for("react.strict_mode"),Py=Symbol.for("react.profiler"),Uy=Symbol.for("react.provider"),Oy=Symbol.for("react.context"),ky=Symbol.for("react.forward_ref"),Ry=Symbol.for("react.suspense"),qy=Symbol.for("react.memo"),My=Symbol.for("react.lazy"),yu=Symbol.iterator;function zy(e){return e===null||typeof e!="object"?null:(e=yu&&e[yu]||e["@@iterator"],typeof e=="function"?e:null)}var hu={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},bu=Object.assign,gu={};function hr(e,t,r){this.props=e,this.context=t,this.refs=gu,this.updater=r||hu}hr.prototype.isReactComponent={},hr.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")},hr.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function vu(){}vu.prototype=hr.prototype;function Gs(e,t,r){this.props=e,this.context=t,this.refs=gu,this.updater=r||hu}var Ws=Gs.prototype=new vu;Ws.constructor=Gs,bu(Ws,hr.prototype),Ws.isPureReactComponent=!0;var Au=Array.isArray,Cu=Object.prototype.hasOwnProperty,Hs={current:null},Tu={key:!0,ref:!0,__self:!0,__source:!0};function Su(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)Cu.call(t,n)&&!Tu.hasOwnProperty(n)&&(a[n]=t[n]);var i=arguments.length-2;if(i===1)a.children=r;else if(1>>1,de=E[ee];if(0>>1;eea(pu,P))yra(Zs,pu)?(E[ee]=Zs,E[yr]=P,ee=yr):(E[ee]=pu,E[fr]=P,ee=fr);else if(yra(Zs,P))E[ee]=Zs,E[yr]=P,ee=yr;else break e}}return B}function a(E,B){var P=E.sortIndex-B.sortIndex;return P!==0?P:E.id-B.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=[],d=1,c=null,m=3,h=!1,b=!1,g=!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 y(E){for(var B=r(u);B!==null;){if(B.callback===null)n(u);else if(B.startTime<=E)n(u),B.sortIndex=B.expirationTime,t(o,B);else break;B=r(u)}}function v(E){if(g=!1,y(E),!b)if(r(o)!==null)b=!0,_s(A);else{var B=r(u);B!==null&&se(v,B.startTime-E)}}function A(E,B){b=!1,g&&(g=!1,f(S),S=-1),h=!0;var P=m;try{for(y(B),c=r(o);c!==null&&(!(c.expirationTime>B)||E&&!ue());){var ee=c.callback;if(typeof ee=="function"){c.callback=null,m=c.priorityLevel;var de=ee(c.expirationTime<=B);B=e.unstable_now(),typeof de=="function"?c.callback=de:c===r(o)&&n(o),y(B)}else n(o);c=r(o)}if(c!==null)var Vs=!0;else{var fr=r(u);fr!==null&&se(v,fr.startTime-B),Vs=!1}return Vs}finally{c=null,m=P,h=!1}}var x=!1,L=null,S=-1,O=5,N=-1;function ue(){return!(e.unstable_now()-NE||125ee?(E.sortIndex=P,t(u,E),r(o)===null&&E===r(u)&&(g?(f(S),S=-1):g=!0,se(v,P-ee))):(E.sortIndex=de,t(o,E),b||h||(b=!0,_s(A))),E},e.unstable_shouldYield=ue,e.unstable_wrapCallback=function(E){var B=m;return function(){var P=m;m=B;try{return E.apply(this,arguments)}finally{m=P}}}})(wu),Du.exports=wu;var Xy=Du.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 Jy=w,Ne=Xy;function T(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;rt}return!1}function Te(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 ce={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){ce[e]=new Te(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];ce[t]=new Te(t,1,!1,e[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(e){ce[e]=new Te(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){ce[e]=new Te(e,2,!1,e,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){ce[e]=new Te(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(e){ce[e]=new Te(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(function(e){ce[e]=new Te(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(function(e){ce[e]=new Te(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(function(e){ce[e]=new Te(e,5,!1,e.toLowerCase(),null,!1,!1)});var Js=/[\-:]([a-z])/g;function el(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(Js,el);ce[t]=new Te(t,1,!1,e,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Js,el);ce[t]=new Te(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Js,el);ce[t]=new Te(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(e){ce[e]=new Te(e,1,!1,e.toLowerCase(),null,!1,!1)}),ce.xlinkHref=new Te("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(e){ce[e]=new Te(e,1,!1,e.toLowerCase(),null,!0,!0)});function tl(e,t,r,n){var a=ce.hasOwnProperty(t)?ce[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{ul=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?an(e):""}function ah(e){switch(e.tag){case 5:return an(e.type);case 16:return an("Lazy");case 13:return an("Suspense");case 19:return an("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 cl(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 vr:return"Fragment";case gr:return"Portal";case nl:return"Profiler";case rl:return"StrictMode";case sl:return"Suspense";case ll:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Uu:return(e.displayName||"Context")+".Consumer";case Pu:return(e._context.displayName||"Context")+".Provider";case al:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case il:return t=e.displayName||null,t!==null?t:cl(e.type)||"Memo";case Tt:t=e._payload,e=e._init;try{return cl(e(t))}catch(r){}}return null}function sh(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 cl(t);case 8:return t===rl?"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 Ru(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function lh(e){var t=Ru(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=lh(e))}function qu(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),n="";return e&&(n=Ru(e)?e.checked?"true":"false":e.value),e=n,e!==r?(t.setValue(e),!0):!1}function ya(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 ml(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 Mu(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 zu(e,t){t=t.checked,t!=null&&tl(e,"checked",t,!1)}function pl(e,t){zu(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")?fl(e,t.type,r):t.hasOwnProperty("defaultValue")&&fl(e,t.type,St(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Fu(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 fl(e,t,r){(t!=="number"||ya(e.ownerDocument)!==e)&&(r==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}var sn=Array.isArray;function Ar(e,t,r,n){if(e=e.options,t){t={};for(var a=0;a"+t.valueOf().toString()+"",t=ha.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function ln(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var on={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},ih=["Webkit","ms","Moz","O"];Object.keys(on).forEach(function(e){ih.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),on[t]=on[e]})});function Wu(e,t,r){return t==null||typeof t=="boolean"||t===""?"":r||typeof t!="number"||t===0||on.hasOwnProperty(e)&&on[e]?(""+t).trim():t+"px"}function Hu(e,t){e=e.style;for(var r in t)if(t.hasOwnProperty(r)){var n=r.indexOf("--")===0,a=Wu(r,t[r],n);r==="float"&&(r="cssFloat"),n?e.setProperty(r,a):e[r]=a}}var oh=$({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(oh[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(T(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(T(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(T(61))}if(t.style!=null&&typeof t.style!="object")throw Error(T(62))}}function gl(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 vl=null;function Al(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Cl=null,Cr=null,Tr=null;function Ku(e){if(e=jn(e)){if(typeof Cl!="function")throw Error(T(280));var t=e.stateNode;t&&(t=Ma(t),Cl(e.stateNode,e.type,t))}}function Qu(e){Cr?Tr?Tr.push(e):Tr=[e]:Cr=e}function Yu(){if(Cr){var e=Cr,t=Tr;if(Tr=Cr=null,Ku(e),t)for(e=0;e>>=0,e===0?32:31-(vh(e)/Ah|0)|0}var Ca=64,Ta=4194304;function mn(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=mn(i):(s&=l,s!==0&&(n=mn(s)))}else l=r&~a,l!==0?n=mn(l):s!==0&&(n=mn(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 pn(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 xh(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=Cn),Id=" ",Ld=!1;function Ed(e,t){switch(e){case"keyup":return Xh.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Dd(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Ir=!1;function eb(e,t){switch(e){case"compositionend":return Dd(t);case"keypress":return t.which!==32?null:(Ld=!0,Id);case"textInput":return e=t.data,e===Id&&Ld?null:e;default:return null}}function tb(e,t){if(Ir)return e==="compositionend"||!Ml&&Ed(e,t)?(e=vd(),Da=Pl=Dt=null,Ir=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)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=Od(r)}}function Rd(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Rd(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function qd(){for(var e=window,t=ya();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=ya(e.document)}return t}function _l(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function db(e){var t=qd(),r=e.focusedElem,n=e.selectionRange;if(t!==r&&r&&r.ownerDocument&&Rd(r.ownerDocument.documentElement,r)){if(n!==null&&_l(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=kd(r,s);var l=kd(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,Lr=null,Vl=null,In=null,Zl=!1;function Md(e,t,r){var n=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;Zl||Lr==null||Lr!==ya(n)||(n=Lr,"selectionStart"in n&&_l(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}),In&&xn(In,n)||(In=n,n=ka(Vl,"onSelect"),0Nr||(e.current=ri[Nr],ri[Nr]=null,Nr--)}function z(e,t){Nr++,ri[Nr]=e.current,e.current=t}var Bt={},ye=Nt(Bt),Ie=Nt(!1),Qt=Bt;function Br(e,t){var r=e.type.contextTypes;if(!r)return Bt;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(){_(Ie),_(ye)}function ec(e,t,r){if(ye.current!==Bt)throw Error(T(168));z(ye,t),z(Ie,r)}function tc(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(T(108,sh(e)||"Unknown",a));return $({},r,n)}function Fa(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Bt,Qt=ye.current,z(ye,e),z(Ie,Ie.current),!0}function rc(e,t,r){var n=e.stateNode;if(!n)throw Error(T(169));r?(e=tc(e,t,Qt),n.__reactInternalMemoizedMergedChildContext=e,_(Ie),_(ye),z(ye,e)):_(Ie),z(Ie,r)}var mt=null,_a=!1,ni=!1;function nc(e){mt===null?mt=[e]:mt.push(e)}function Tb(e){_a=!0,nc(e)}function Pt(){if(!ni&&mt!==null){ni=!0;var e=0,t=M;try{var r=mt;for(M=1;e>=l,a-=l,pt=1<<32-He(t)+a|r<S?(O=L,L=null):O=L.sibling;var N=m(f,L,y[S],v);if(N===null){L===null&&(L=O);break}e&&L&&N.alternate===null&&t(f,L),p=s(N,p,S),x===null?A=N:x.sibling=N,x=N,L=O}if(S===y.length)return r(f,L),Z&&Xt(f,S),A;if(L===null){for(;SS?(O=L,L=null):O=L.sibling;var ue=m(f,L,N.value,v);if(ue===null){L===null&&(L=O);break}e&&L&&ue.alternate===null&&t(f,L),p=s(ue,p,S),x===null?A=ue:x.sibling=ue,x=ue,L=O}if(N.done)return r(f,L),Z&&Xt(f,S),A;if(L===null){for(;!N.done;S++,N=y.next())N=c(f,N.value,v),N!==null&&(p=s(N,p,S),x===null?A=N:x.sibling=N,x=N);return Z&&Xt(f,S),A}for(L=n(f,L);!N.done;S++,N=y.next())N=h(L,f,S,N.value,v),N!==null&&(e&&N.alternate!==null&&L.delete(N.key===null?S:N.key),p=s(N,p,S),x===null?A=N:x.sibling=N,x=N);return e&&L.forEach(function(Gt){return t(f,Gt)}),Z&&Xt(f,S),A}function C(f,p,y,v){if(typeof y=="object"&&y!==null&&y.type===vr&&y.key===null&&(y=y.props.children),typeof y=="object"&&y!==null){switch(y.$$typeof){case pa:e:{for(var A=y.key,x=p;x!==null;){if(x.key===A){if(A=y.type,A===vr){if(x.tag===7){r(f,x.sibling),p=a(x,y.props.children),p.return=f,f=p;break e}}else if(x.elementType===A||typeof A=="object"&&A!==null&&A.$$typeof===Tt&&uc(A)===x.type){r(f,x.sibling),p=a(x,y.props),p.ref=Nn(f,x,y),p.return=f,f=p;break e}r(f,x);break}else t(f,x);x=x.sibling}y.type===vr?(p=lr(y.props.children,f.mode,v,y.key),p.return=f,f=p):(v=hs(y.type,y.key,y.props,null,f.mode,v),v.ref=Nn(f,p,y),v.return=f,f=v)}return l(f);case gr:e:{for(x=y.key;p!==null;){if(p.key===x)if(p.tag===4&&p.stateNode.containerInfo===y.containerInfo&&p.stateNode.implementation===y.implementation){r(f,p.sibling),p=a(p,y.children||[]),p.return=f,f=p;break e}else{r(f,p);break}else t(f,p);p=p.sibling}p=eo(y,f.mode,v),p.return=f,f=p}return l(f);case Tt:return x=y._init,C(f,p,x(y._payload),v)}if(sn(y))return b(f,p,y,v);if(nn(y))return g(f,p,y,v);Ga(f,y)}return typeof y=="string"&&y!==""||typeof y=="number"?(y=""+y,p!==null&&p.tag===6?(r(f,p.sibling),p=a(p,y),p.return=f,f=p):(r(f,p),p=Ji(y,f.mode,v),p.return=f,f=p),l(f)):r(f,p)}return C}var kr=dc(!0),cc=dc(!1),Wa=Nt(null),Ha=null,Rr=null,ui=null;function di(){ui=Rr=Ha=null}function ci(e){var t=Wa.current;_(Wa),e._currentValue=t}function mi(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 qr(e,t){Ha=e,ui=Rr=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Ee=!0),e.firstContext=null)}function Fe(e){var t=e._currentValue;if(ui!==e)if(e={context:e,memoizedValue:t,next:null},Rr===null){if(Ha===null)throw Error(T(308));Rr=e,Ha.dependencies={lanes:0,firstContext:e}}else Rr=Rr.next=e;return t}var Jt=null;function pi(e){Jt===null?Jt=[e]:Jt.push(e)}function mc(e,t,r,n){var a=t.interleaved;return a===null?(r.next=r,pi(t)):(r.next=a.next,a.next=r),t.interleaved=r,yt(e,n)}function yt(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 fi(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function pc(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 ht(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,q&2){var a=n.pending;return a===null?t.next=t:(t.next=a.next,a.next=t),n.pending=t,yt(e,r)}return a=n.interleaved,a===null?(t.next=t,pi(n)):(t.next=a.next,a.next=t),n.interleaved=t,yt(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,Dl(e,r)}}function fc(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 d=e.alternate;d!==null&&(d=d.updateQueue,i=d.lastBaseUpdate,i!==l&&(i===null?d.firstBaseUpdate=u:i.next=u,d.lastBaseUpdate=o))}if(s!==null){var c=a.baseState;l=0,d=u=o=null,i=s;do{var m=i.lane,h=i.eventTime;if((n&m)===m){d!==null&&(d=d.next={eventTime:h,lane:0,tag:i.tag,payload:i.payload,callback:i.callback,next:null});e:{var b=e,g=i;switch(m=t,h=r,g.tag){case 1:if(b=g.payload,typeof b=="function"){c=b.call(h,c,m);break e}c=b;break e;case 3:b.flags=b.flags&-65537|128;case 0:if(b=g.payload,m=typeof b=="function"?b.call(h,c,m):b,m==null)break e;c=$({},c,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 h={eventTime:h,lane:m,tag:i.tag,payload:i.payload,callback:i.callback,next:null},d===null?(u=d=h,o=c):d=d.next=h,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(d===null&&(o=c),a.baseState=o,a.firstBaseUpdate=u,a.lastBaseUpdate=d,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);rr|=l,e.lanes=l,e.memoizedState=c}}function yc(e,t,r){if(e=t.effects,t.effects=null,e!==null)for(t=0;tr?r:4,e(!0);var n=vi.transition;vi.transition={};try{e(!1),t()}finally{M=r,vi.transition=n}}function Uc(){return _e().memoizedState}function Lb(e,t,r){var n=Mt(e);if(r={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null},Oc(e))kc(t,r);else if(r=mc(e,t,r,n),r!==null){var a=xe();et(r,e,n,a),Rc(r,t,n)}}function Eb(e,t,r){var n=Mt(e),a={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null};if(Oc(e))kc(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,pi(t)):(a.next=o.next,o.next=a),t.interleaved=a;return}}catch(u){}finally{}r=mc(e,t,a,n),r!==null&&(a=xe(),et(r,e,n,a),Rc(r,t,n))}}function Oc(e){var t=e.alternate;return e===W||t!==null&&t===W}function kc(e,t){On=Ja=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function Rc(e,t,r){if(r&4194240){var n=t.lanes;n&=e.pendingLanes,r|=n,t.lanes=r,Dl(e,r)}}var rs={readContext:Fe,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},Db={readContext:Fe,useCallback:function(e,t){return st().memoizedState=[e,t===void 0?null:t],e},useContext:Fe,useEffect:Lc,useImperativeHandle:function(e,t,r){return r=r!=null?r.concat([e]):null,es(4194308,4,wc.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=st();return t=t===void 0?null:t,e=e(),r.memoizedState=[e,t],e},useReducer:function(e,t,r){var n=st();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=Lb.bind(null,W,e),[n.memoizedState,e]},useRef:function(e){var t=st();return e={current:e},t.memoizedState=e},useState:xc,useDebugValue:Li,useDeferredValue:function(e){return st().memoizedState=e},useTransition:function(){var e=xc(!1),t=e[0];return e=Ib.bind(null,e[1]),st().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var n=W,a=st();if(Z){if(r===void 0)throw Error(T(407));r=r()}else{if(r=t(),oe===null)throw Error(T(349));tr&30||vc(n,t,r)}a.memoizedState=r;var s={value:r,getSnapshot:t};return a.queue=s,Lc(Cc.bind(null,n,s,e),[e]),n.flags|=2048,qn(9,Ac.bind(null,n,s,r,t),void 0,null),r},useId:function(){var e=st(),t=oe.identifierPrefix;if(Z){var r=ft,n=pt;r=(n&~(1<<32-He(n)-1)).toString(32)+r,t=":"+t+"R"+r,r=kn++,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[nt]=t,e[wn]=n,nm(e,t,!1,!1),t.stateNode=e;e:{switch(l=gl(r,n),r){case"dialog":F("cancel",e),F("close",e),a=n;break;case"iframe":case"object":case"embed":F("load",e),a=n;break;case"video":case"audio":for(a=0;aVr&&(t.flags|=128,n=!0,Mn(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),Mn(s,!0),s.tail===null&&s.tailMode==="hidden"&&!l.alternate&&!Z)return be(t),null}else 2*X()-s.renderingStartTime>Vr&&r!==1073741824&&(t.flags|=128,n=!0,Mn(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=X(),t.sibling=null,r=G.current,z(G,n?r&1|2:r&1),t):(be(t),null);case 22:case 23:return Qi(),n=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==n&&(t.flags|=8192),n&&t.mode&1?Oe&1073741824&&(be(t),t.subtreeFlags&6&&(t.flags|=8192)):be(t),null;case 24:return null;case 25:return null}throw Error(T(156,t.tag))}function kb(e,t){switch(si(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 Mr(),_(Ie),_(ye),gi(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return hi(t),null;case 13:if(_(G),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(T(340));Or()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return _(G),null;case 4:return Mr(),null;case 10:return ci(t.type._context),null;case 22:case 23:return Qi(),null;case 24:return null;default:return null}}var ls=!1,ge=!1,Rb=typeof WeakSet=="function"?WeakSet:Set,D=null;function Fr(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 qi(e,t,r){try{r()}catch(n){Q(e,t,n)}}var lm=!1;function qb(e,t){if(Ql=La,e=qd(),_l(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,d=0,c=e,m=null;t:for(;;){for(var h;c!==r||a!==0&&c.nodeType!==3||(i=l+a),c!==s||n!==0&&c.nodeType!==3||(o=l+n),c.nodeType===3&&(l+=c.nodeValue.length),(h=c.firstChild)!==null;)m=c,c=h;for(;;){if(c===e)break t;if(m===r&&++u===a&&(i=l),m===s&&++d===n&&(o=l),(h=c.nextSibling)!==null)break;c=m,m=c.parentNode}c=h}r=i===-1||o===-1?null:{start:i,end:o}}else r=null}r=r||{start:0,end:0}}else r=null;for(Yl={focusedElem:e,selectionRange:r},La=!1,D=t;D!==null;)if(t=D,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,D=e;else for(;D!==null;){t=D;try{var b=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(b!==null){var g=b.memoizedProps,C=b.memoizedState,f=t.stateNode,p=f.getSnapshotBeforeUpdate(t.elementType===t.type?g:Ye(t.type,g),C);f.__reactInternalSnapshotBeforeUpdate=p}break;case 3:var y=t.stateNode.containerInfo;y.nodeType===1?y.textContent="":y.nodeType===9&&y.documentElement&&y.removeChild(y.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(T(163))}}catch(v){Q(t,t.return,v)}if(e=t.sibling,e!==null){e.return=t.return,D=e;break}D=t.return}return b=lm,lm=!1,b}function zn(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&&qi(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 Mi(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 im(e){var t=e.alternate;t!==null&&(e.alternate=null,im(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[nt],delete t[wn],delete t[ti],delete t[Ab],delete t[Cb])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function om(e){return e.tag===5||e.tag===3||e.tag===4}function um(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||om(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function zi(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(zi(e,t,r),e=e.sibling;e!==null;)zi(e,t,r),e=e.sibling}function Fi(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(Fi(e,t,r),e=e.sibling;e!==null;)Fi(e,t,r),e=e.sibling}var me=null,Xe=!1;function kt(e,t,r){for(r=r.child;r!==null;)dm(e,t,r),r=r.sibling}function dm(e,t,r){if(rt&&typeof rt.onCommitFiberUnmount=="function")try{rt.onCommitFiberUnmount(Aa,r)}catch(i){}switch(r.tag){case 5:ge||Fr(r,t);case 6:var n=me,a=Xe;me=null,kt(e,t,r),me=n,Xe=a,me!==null&&(Xe?(e=me,r=r.stateNode,e.nodeType===8?e.parentNode.removeChild(r):e.removeChild(r)):me.removeChild(r.stateNode));break;case 18:me!==null&&(Xe?(e=me,r=r.stateNode,e.nodeType===8?ei(e.parentNode,r):e.nodeType===1&&ei(e,r),gn(e)):ei(me,r.stateNode));break;case 4:n=me,a=Xe,me=r.stateNode.containerInfo,Xe=!0,kt(e,t,r),me=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)&&qi(r,t,l),a=a.next}while(a!==n)}kt(e,t,r);break;case 1:if(!ge&&(Fr(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 cm(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var r=e.stateNode;r===null&&(r=e.stateNode=new Rb),t.forEach(function(n){var a=Wb.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=X()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*zb(n/1960))-n,10e?16:e,qt===null)var n=!1;else{if(e=qt,qt=null,ms=0,q&6)throw Error(T(331));var a=q;for(q|=4,D=e.current;D!==null;){var s=D,l=s.child;if(D.flags&16){var i=s.deletions;if(i!==null){for(var o=0;oX()-Zi?ar(e,0):Vi|=r),we(e,t)}function xm(e,t){t===0&&(e.mode&1?(t=Ta,Ta<<=1,!(Ta&130023424)&&(Ta=4194304)):t=1);var r=xe();e=yt(e,t),e!==null&&(pn(e,t,r),we(e,r))}function Gb(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),xm(e,r)}function Wb(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(T(314))}n!==null&&n.delete(t),xm(e,r)}var Im;Im=function(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps||Ie.current)Ee=!0;else{if(!(e.lanes&r)&&!(t.flags&128))return Ee=!1,Ub(e,t,r);Ee=!!(e.flags&131072)}else Ee=!1,Z&&t.flags&1048576&&ac(t,Za,t.index);switch(t.lanes=0,t.tag){case 2:var n=t.type;ss(e,t),e=t.pendingProps;var a=Br(t,ye.current);qr(t,r),a=Ci(null,t,n,e,a,r);var s=Ti();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,fi(t),a.updater=ns,t.stateNode=a,a._reactInternals=t,Di(t,n,e,r),t=Bi(null,t,n,!0,s,r)):(t.tag=0,Z&&s&&ai(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=Kb(n),e=Ye(n,e),a){case 0:t=Ni(null,t,n,e,r);break e;case 1:t=Yc(null,t,n,e,r);break e;case 11:t=Gc(null,t,n,e,r);break e;case 14:t=Wc(null,t,n,Ye(n.type,e),r);break e}throw Error(T(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),Yc(e,t,n,a,r);case 3:e:{if(Xc(t),e===null)throw Error(T(387));n=t.pendingProps,s=t.memoizedState,a=s.element,pc(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=zr(Error(T(423)),t),t=Jc(e,t,n,r,a);break e}else if(n!==a){a=zr(Error(T(424)),t),t=Jc(e,t,n,r,a);break e}else for(Ue=jt(t.stateNode.containerInfo.firstChild),Pe=t,Z=!0,Qe=null,r=cc(t,null,n,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(Or(),n===a){t=bt(e,t,r);break e}Se(e,t,n,r)}t=t.child}return t;case 5:return hc(t),e===null&&ii(t),n=t.type,a=t.pendingProps,s=e!==null?e.memoizedProps:null,l=a.children,Xl(n,a)?l=null:s!==null&&Xl(n,s)&&(t.flags|=32),Qc(e,t),Se(e,t,l,r),t.child;case 6:return e===null&&ii(t),null;case 13:return em(e,t,r);case 4:return yi(t,t.stateNode.containerInfo),n=t.pendingProps,e===null?t.child=kr(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),Gc(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,z(Wa,n._currentValue),n._currentValue=l,s!==null)if(Ke(s.value,l)){if(s.children===a.children&&!Ie.current){t=bt(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=ht(-1,r&-r),o.tag=2;var u=s.updateQueue;if(u!==null){u=u.shared;var d=u.pending;d===null?o.next=o:(o.next=d.next,d.next=o),u.pending=o}}s.lanes|=r,o=s.alternate,o!==null&&(o.lanes|=r),mi(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(T(341));l.lanes|=r,i=l.alternate,i!==null&&(i.lanes|=r),mi(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,qr(t,r),a=Fe(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),Wc(e,t,n,a,r);case 15:return Hc(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,qr(t,r),Mc(t,n,a),Di(t,n,a,r),Bi(null,t,n,!0,e,r);case 19:return rm(e,t,r);case 22:return Kc(e,t,r)}throw Error(T(156,t.tag))};function Lm(e,t){return sd(e,t)}function Hb(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 Ze(e,t,r,n){return new Hb(e,t,r,n)}function Xi(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Kb(e){if(typeof e=="function")return Xi(e)?1:0;if(e!=null){if(e=e.$$typeof,e===al)return 11;if(e===il)return 14}return 2}function Ft(e,t){var r=e.alternate;return r===null?(r=Ze(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 hs(e,t,r,n,a,s){var l=2;if(n=e,typeof e=="function")Xi(e)&&(l=1);else if(typeof e=="string")l=5;else e:switch(e){case vr:return lr(r.children,a,s,t);case rl:l=8,a|=8;break;case nl:return e=Ze(12,r,t,a|2),e.elementType=nl,e.lanes=s,e;case sl:return e=Ze(13,r,t,a),e.elementType=sl,e.lanes=s,e;case ll:return e=Ze(19,r,t,a),e.elementType=ll,e.lanes=s,e;case Ou:return bs(r,a,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Pu:l=10;break e;case Uu:l=9;break e;case al:l=11;break e;case il:l=14;break e;case Tt:l=16,n=null;break e}throw Error(T(130,e==null?e:typeof e,""))}return t=Ze(l,r,t,a),t.elementType=e,t.type=n,t.lanes=s,t}function lr(e,t,r,n){return e=Ze(7,e,n,t),e.lanes=r,e}function bs(e,t,r,n){return e=Ze(22,e,n,t),e.elementType=Ou,e.lanes=r,e.stateNode={isHidden:!1},e}function Ji(e,t,r){return e=Ze(6,e,null,t),e.lanes=r,e}function eo(e,t,r){return t=Ze(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Qb(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 to(e,t,r,n,a,s,l,i,o){return e=new Qb(e,t,r,i,o),t===1?(t=1,s===!0&&(t|=8)):t=0,s=Ze(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:n,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},fi(s),e}function Yb(e,t,r){var n=3e,isStatic:!1,reducedMotion:"never"});function lg(e=!0){const t=w.useContext(so);if(t===null)return[!0,null];const{isPresent:r,onExitComplete:n,register:a}=t,s=w.useId();w.useEffect(()=>{e&&a(s)},[e]);const l=w.useCallback(()=>e&&n&&n(s),[s,n,e]);return!r&&n?[!1,l]:[!0]}const lo=typeof window!="undefined",ig=lo?w.useLayoutEffect:w.useEffect,ke=e=>e;let io=ke;function oo(e){let t;return()=>(t===void 0&&(t=e()),t)}const $r=(e,t,r)=>{const n=t-e;return n===0?1:(r-e)/n},vt=e=>e*1e3,At=e=>e/1e3,og={skipAnimations:!1,useManualTiming:!1};function ug(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,d=!1,c=!1)=>{const h=c&&n?t:r;return d&&s.add(u),h.has(u)||h.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],t.forEach(i),t.clear(),n=!1,a&&(a=!1,o.process(u))}};return o}const xs=["read","resolveKeyframes","update","preRender","render","postRender"],dg=40;function km(e,t){let r=!1,n=!0;const a={delta:0,timestamp:0,isProcessing:!1},s=()=>r=!0,l=xs.reduce((f,p)=>(f[p]=ug(s),f),{}),{read:i,resolveKeyframes:o,update:u,preRender:d,render:c,postRender:m}=l,h=()=>{const f=performance.now();r=!1,a.delta=n?1e3/60:Math.max(Math.min(f-a.timestamp,dg),1),a.timestamp=f,a.isProcessing=!0,i.process(a),o.process(a),u.process(a),d.process(a),c.process(a),m.process(a),a.isProcessing=!1,r&&t&&(n=!1,e(h))},b=()=>{r=!0,n=!0,a.isProcessing||e(h)};return{schedule:xs.reduce((f,p)=>{const y=l[p];return f[p]=(v,A=!1,x=!1)=>(r||b(),y.schedule(v,A,x)),f},{}),cancel:f=>{for(let p=0;pqm[e].some(r=>!!t[r])};function cg(e){for(const t in e)Gr[t]=I(I({},Gr[t]),e[t])}const mg=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 Is(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||mg.has(e)}let Mm=e=>!Is(e);function pg(e){e&&(Mm=t=>t.startsWith("on")?!Is(t):e(t))}try{pg(require("@emotion/is-prop-valid").default)}catch(e){}function fg(e,t,r){const n={};for(const a in e)a==="values"&&typeof e.values=="object"||(Mm(a)||r===!0&&Is(a)||!t&&!Is(a)||e.draggable&&a.startsWith("onDrag"))&&(n[a]=e[a]);return n}function yg(e){if(typeof Proxy=="undefined")return e;const t=new Map,r=(...n)=>e(...n);return new Proxy(r,{get:(n,a)=>a==="create"?e:(t.has(a)||t.set(a,e(a)),t.get(a))})}const Ls=w.createContext({});function $n(e){return typeof e=="string"||Array.isArray(e)}function Es(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}const co=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],mo=["initial",...co];function Ds(e){return Es(e.animate)||mo.some(t=>$n(e[t]))}function zm(e){return!!(Ds(e)||e.variants)}function hg(e,t){if(Ds(e)){const{initial:r,animate:n}=e;return{initial:r===!1||$n(r)?r:void 0,animate:$n(n)?n:void 0}}return e.inherit!==!1?t:{}}function bg(e){const{initial:t,animate:r}=hg(e,w.useContext(Ls));return w.useMemo(()=>({initial:t,animate:r}),[Fm(t),Fm(r)])}function Fm(e){return Array.isArray(e)?e.join(" "):e}const gg=Symbol.for("motionComponentSymbol");function Wr(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function vg(e,t,r){return w.useCallback(n=>{n&&e.onMount&&e.onMount(n),t&&(n?t.mount(n):t.unmount()),r&&(typeof r=="function"?r(n):Wr(r)&&(r.current=n))},[t])}const po=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),_m="data-"+po("framerAppearId"),{schedule:fo,cancel:KT}=km(queueMicrotask,!1),Vm=w.createContext({});function Ag(e,t,r,n,a){var s,l;const{visualElement:i}=w.useContext(Ls),o=w.useContext(Rm),u=w.useContext(so),d=w.useContext(Om).reducedMotion,c=w.useRef(null);n=n||o.renderer,!c.current&&n&&(c.current=n(e,{visualState:t,parent:i,props:r,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:d}));const m=c.current,h=w.useContext(Vm);m&&!m.projection&&a&&(m.type==="html"||m.type==="svg")&&Cg(c.current,r,a,h);const b=w.useRef(!1);w.useInsertionEffect(()=>{m&&b.current&&m.update(r,u)});const g=r[_m],C=w.useRef(!!g&&!(!((s=window.MotionHandoffIsComplete)===null||s===void 0)&&s.call(window,g))&&((l=window.MotionHasOptimisedAnimation)===null||l===void 0?void 0:l.call(window,g)));return ig(()=>{m&&(b.current=!0,window.MotionIsMounted=!0,m.updateFeatures(),fo.render(m.render),C.current&&m.animationState&&m.animationState.animateChanges())}),w.useEffect(()=>{m&&(!C.current&&m.animationState&&m.animationState.animateChanges(),C.current&&(queueMicrotask(()=>{var f;(f=window.MotionHandoffMarkAsComplete)===null||f===void 0||f.call(window,g)}),C.current=!1))}),m}function Cg(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:Zm(e.parent)),e.projection.setOptions({layoutId:a,layout:s,alwaysMeasureLayout:!!l||i&&Wr(i),visualElement:e,animationType:typeof s=="string"?s:"both",initialPromotionConfig:n,layoutScroll:o,layoutRoot:u})}function Zm(e){if(e)return e.options.allowProjection!==!1?e.projection:Zm(e.parent)}function Tg({preloadedFeatures:e,createVisualElement:t,useRender:r,useVisualState:n,Component:a}){var s,l;e&&cg(e);function i(u,d){let c;const m=k(I(I({},w.useContext(Om)),u),{layoutId:Sg(u)}),{isStatic:h}=m,b=bg(u),g=n(u,h);if(!h&&lo){xg();const C=Ig(m);c=C.MeasureLayout,b.visualElement=Ag(a,g,m,t,C.ProjectionNode)}return R.jsxs(Ls.Provider,{value:b,children:[c&&b.visualElement?R.jsx(c,I({visualElement:b.visualElement},m)):null,r(a,u,vg(g,b.visualElement,d),g,h,b.visualElement)]})}i.displayName=`motion.${typeof a=="string"?a:`create(${(l=(s=a.displayName)!==null&&s!==void 0?s:a.name)!==null&&l!==void 0?l:""})`}`;const o=w.forwardRef(i);return o[gg]=a,o}function Sg({layoutId:e}){const t=w.useContext(Um).id;return t&&e!==void 0?t+"-"+e:e}function xg(e,t){w.useContext(Rm).strict}function Ig(e){const{drag:t,layout:r}=Gr;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}}const Lg=["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 yo(e){return typeof e!="string"||e.includes("-")?!1:!!(Lg.indexOf(e)>-1||/[A-Z]/u.test(e))}function $m(e){const t=[{},{}];return e==null||e.values.forEach((r,n)=>{t[0][n]=r.get(),t[1][n]=r.getVelocity()}),t}function ho(e,t,r,n){if(typeof t=="function"){const[a,s]=$m(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]=$m(n);t=t(r!==void 0?r:e.custom,a,s)}return t}const bo=e=>Array.isArray(e),Eg=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),Dg=e=>bo(e)?e[e.length-1]||0:e,ve=e=>!!(e&&e.getVelocity);function ws(e){const t=ve(e)?e.get():e;return Eg(t)?t.toValue():t}function wg({scrapeMotionValuesFromProps:e,createRenderState:t,onUpdate:r},n,a,s){const l={latestValues:jg(n,a,s,e),renderState:t()};return r&&(l.onMount=i=>r(I({props:n,current:i},l)),l.onUpdate=i=>r(i)),l}const Gm=e=>(t,r)=>{const n=w.useContext(Ls),a=w.useContext(so),s=()=>wg(e,t,n,a);return r?s():sg(s)};function jg(e,t,r,n){const a={},s=n(e,{});for(const h in s)a[h]=ws(s[h]);let{initial:l,animate:i}=e;const o=Ds(e),u=zm(e);t&&u&&!o&&e.inherit!==!1&&(l===void 0&&(l=t.initial),i===void 0&&(i=t.animate));let d=r?r.initial===!1:!1;d=d||l===!1;const c=d?i:l;if(c&&typeof c!="boolean"&&!Es(c)){const h=Array.isArray(c)?c:[c];for(let b=0;bt=>typeof t=="string"&&t.startsWith(e),Hm=Wm("--"),Ng=Wm("var(--"),go=e=>Ng(e)?Bg.test(e.split("/*")[0].trim()):!1,Bg=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,Km=(e,t)=>t&&typeof e=="number"?t.transform(e):e,Ct=(e,t,r)=>r>t?t:rtypeof e=="number",parse:parseFloat,transform:e=>e},Gn=k(I({},Kr),{transform:e=>Ct(0,1,e)}),js=k(I({},Kr),{default:1}),Wn=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Vt=Wn("deg"),it=Wn("%"),j=Wn("px"),Pg=Wn("vh"),Ug=Wn("vw"),Qm=k(I({},it),{parse:e=>it.parse(e)/100,transform:e=>it.transform(e*100)}),Og={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,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,backgroundPositionX:j,backgroundPositionY:j},kg={rotate:Vt,rotateX:Vt,rotateY:Vt,rotateZ:Vt,scale:js,scaleX:js,scaleY:js,scaleZ:js,skew:Vt,skewX:Vt,skewY:Vt,distance:j,translateX:j,translateY:j,translateZ:j,x:j,y:j,z:j,perspective:j,transformPerspective:j,opacity:Gn,originX:Qm,originY:Qm,originZ:j},Ym=k(I({},Kr),{transform:Math.round}),vo=k(I(I({},Og),kg),{zIndex:Ym,size:j,fillOpacity:Gn,strokeOpacity:Gn,numOctaves:Ym}),Rg={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},qg=Hr.length;function Mg(e,t,r){let n="",a=!0;for(let s=0;s({style:{},transform:{},transformOrigin:{},vars:{}}),Jm=()=>k(I({},To()),{attrs:{}}),So=e=>typeof e=="string"&&e.toLowerCase()==="svg";function ep(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 tp=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 rp(e,t,r,n){ep(e,t,void 0,n);for(const a in t.attrs)e.setAttribute(tp.has(a)?a:po(a),t.attrs[a])}const Ns={};function Zg(e){Object.assign(Ns,e)}function np(e,{layout:t,layoutId:r}){return ir.has(e)||e.startsWith("origin")||(t||r!==void 0)&&(!!Ns[e]||e==="opacity")}function xo(e,t,r){var n;const{style:a}=e,s={};for(const l in a)(ve(a[l])||t.style&&ve(t.style[l])||np(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 s}function ap(e,t,r){const n=xo(e,t,r);for(const a in e)if(ve(e[a])||ve(t[a])){const s=Hr.indexOf(a)!==-1?"attr"+a.charAt(0).toUpperCase()+a.substring(1):a;n[s]=e[a]}return n}function $g(e,t){try{t.dimensions=typeof e.getBBox=="function"?e.getBBox():e.getBoundingClientRect()}catch(r){t.dimensions={x:0,y:0,width:0,height:0}}}const sp=["x","y","width","height","cx","cy","r"],Gg={useVisualState:Gm({scrapeMotionValuesFromProps:ap,createRenderState:Jm,onUpdate:({props:e,prevProps:t,current:r,renderState:n,latestValues:a})=>{if(!r)return;let s=!!e.drag;if(!s){for(const i in a)if(ir.has(i)){s=!0;break}}if(!s)return;let l=!t;if(t)for(let i=0;i{$g(r,n),V.render(()=>{Co(n,a,So(r.tagName),e.transformTemplate),rp(r,n)})})}})},Wg={useVisualState:Gm({scrapeMotionValuesFromProps:xo,createRenderState:To})};function lp(e,t,r){for(const n in t)!ve(t[n])&&!np(n,r)&&(e[n]=t[n])}function Hg({transformTemplate:e},t){return w.useMemo(()=>{const r=To();return Ao(r,t,e),Object.assign({},r.vars,r.style)},[t])}function Kg(e,t){const r=e.style||{},n={};return lp(n,r,e),Object.assign(n,Hg(e,t)),n}function Qg(e,t){const r={},n=Kg(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}function Yg(e,t,r,n){const a=w.useMemo(()=>{const s=Jm();return Co(s,t,So(n),e.transformTemplate),k(I({},s.attrs),{style:I({},s.style)})},[t]);if(e.style){const s={};lp(s,e.style,e),a.style=I(I({},s),a.style)}return a}function Xg(e=!1){return(r,n,a,{latestValues:s},l)=>{const o=(yo(r)?Yg:Qg)(n,s,l,r),u=fg(n,typeof r=="string",e),d=r!==w.Fragment?k(I(I({},u),o),{ref:a}):{},{children:c}=n,m=w.useMemo(()=>ve(c)?c.get():c,[c]);return w.createElement(r,k(I({},d),{children:m}))}}function Jg(e,t){return function(n,{forwardMotionProps:a}={forwardMotionProps:!1}){const s=yo(n)?Gg:Wg,l=k(I({},s),{preloadedFeatures:e,useRender:Xg(a),createVisualElement:t,Component:n});return Tg(l)}}function ip(e,t){if(!Array.isArray(t))return!1;const r=t.length;if(r!==e.length)return!1;for(let n=0;nwindow.ScrollTimeline!==void 0);class tv{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}get finished(){return Promise.all(this.animations.map(t=>"finished"in t?t.finished:t))}getAll(t){return this.animations[0][t]}setAll(t,r){for(let n=0;n{if(ev()&&a.attachTimeline)return a.attachTimeline(t);if(typeof r=="function")return r(a)});return()=>{n.forEach((a,s)=>{a&&a(),this.animations[s].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get startTime(){return this.getAll("startTime")}get duration(){let t=0;for(let r=0;rr[t]())}flatten(){this.runAll("flatten")}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}class rv extends tv{then(t,r){return Promise.all(this.animations).then(t).catch(r)}}function Io(e,t){return e?e[t]||e.default||e:void 0}const Lo=2e4;function op(e){let t=0;const r=50;let n=e.next(t);for(;!n.done&&t=Lo?1/0:t}function Eo(e){return typeof e=="function"}function up(e,t){e.timeline=t,e.onfinish=null}const Do=e=>Array.isArray(e)&&typeof e[0]=="number",nv={linearEasing:void 0};function av(e,t){const r=oo(e);return()=>{var n;return(n=nv[t])!==null&&n!==void 0?n:r()}}const Ps=av(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch(e){return!1}return!0},"linearEasing"),dp=(e,t,r=10)=>{let n="";const a=Math.max(Math.round(t/r),2);for(let s=0;s`cubic-bezier(${e}, ${t}, ${r}, ${n})`,wo={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Hn([0,.65,.55,1]),circOut:Hn([.55,0,1,.45]),backIn:Hn([.31,.01,.66,-.59]),backOut:Hn([.33,1.53,.69,.99])};function mp(e,t){if(e)return typeof e=="function"&&Ps()?dp(e,t):Do(e)?Hn(e):Array.isArray(e)?e.map(r=>mp(r,t)||wo.easeOut):wo[e]}const tt={x:!1,y:!1};function pp(){return tt.x||tt.y}function sv(e,t,r){var n;if(e instanceof Element)return[e];if(typeof e=="string"){let a=document;const s=(n=void 0)!==null&&n!==void 0?n:a.querySelectorAll(e);return s?Array.from(s):[]}return Array.from(e)}function fp(e,t){const r=sv(e),n=new AbortController,a=k(I({passive:!0},t),{signal:n.signal});return[r,a,()=>n.abort()]}function yp(e){return t=>{t.pointerType==="touch"||pp()||e(t)}}function lv(e,t,r={}){const[n,a,s]=fp(e,r),l=yp(i=>{const{target:o}=i,u=t(i);if(typeof u!="function"||!o)return;const d=yp(c=>{u(c),o.removeEventListener("pointerleave",d)});o.addEventListener("pointerleave",d,a)});return n.forEach(i=>{i.addEventListener("pointerenter",l,a)}),s}const hp=(e,t)=>t?e===t?!0:hp(e,t.parentElement):!1,jo=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,iv=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function ov(e){return iv.has(e.tagName)||e.tabIndex!==-1}const Kn=new WeakSet;function bp(e){return t=>{t.key==="Enter"&&e(t)}}function No(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const uv=(e,t)=>{const r=e.currentTarget;if(!r)return;const n=bp(()=>{if(Kn.has(r))return;No(r,"down");const a=bp(()=>{No(r,"up")}),s=()=>No(r,"cancel");r.addEventListener("keyup",a,t),r.addEventListener("blur",s,t)});r.addEventListener("keydown",n,t),r.addEventListener("blur",()=>r.removeEventListener("keydown",n),t)};function gp(e){return jo(e)&&!pp()}function dv(e,t,r={}){const[n,a,s]=fp(e,r),l=i=>{const o=i.currentTarget;if(!gp(i)||Kn.has(o))return;Kn.add(o);const u=t(i),d=(h,b)=>{window.removeEventListener("pointerup",c),window.removeEventListener("pointercancel",m),!(!gp(h)||!Kn.has(o))&&(Kn.delete(o),typeof u=="function"&&u(h,{success:b}))},c=h=>{d(h,r.useGlobalTarget||hp(o,h.target))},m=h=>{d(h,!1)};window.addEventListener("pointerup",c,a),window.addEventListener("pointercancel",m,a)};return n.forEach(i=>{!ov(i)&&i.getAttribute("tabindex")===null&&(i.tabIndex=0),(r.useGlobalTarget?window:i).addEventListener("pointerdown",l,a),i.addEventListener("focus",u=>uv(u,a),a)}),s}function cv(e){return e==="x"||e==="y"?tt[e]?null:(tt[e]=!0,()=>{tt[e]=!1}):tt.x||tt.y?null:(tt.x=tt.y=!0,()=>{tt.x=tt.y=!1})}const vp=new Set(["width","height","top","left","right","bottom",...Hr]);let Us;function mv(){Us=void 0}const ot={now:()=>(Us===void 0&&ot.set(fe.isProcessing||og.useManualTiming?fe.timestamp:performance.now()),Us),set:e=>{Us=e,queueMicrotask(mv)}};function Bo(e,t){e.indexOf(t)===-1&&e.push(t)}function Po(e,t){const r=e.indexOf(t);r>-1&&e.splice(r,1)}class Uo{constructor(){this.subscriptions=[]}add(t){return Bo(this.subscriptions,t),()=>Po(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 fv{constructor(t,r={}){this.version="11.18.2",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(n,a=!0)=>{const s=ot.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=ot.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=pv(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 Uo);const n=this.events[t].add(r);return t==="change"?()=>{n(),V.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=ot.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Cp)return 0;const r=Math.min(this.updatedAt-this.prevUpdatedAt,Cp);return Ap(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 Qn(e,t){return new fv(e,t)}function yv(e,t,r){e.hasValue(t)?e.getValue(t).set(r):e.addValue(t,Qn(r))}function hv(e,t){let l=Bs(e,t)||{},{transitionEnd:n={},transition:a={}}=l,s=We(l,["transitionEnd","transition"]);s=I(I({},s),n);for(const i in s){const o=Dg(s[i]);yv(e,i,o)}}function bv(e){return!!(ve(e)&&e.add)}function Oo(e,t){const r=e.getValue("willChange");if(bv(r))return r.add(t)}function Tp(e){return e.props[_m]}const Sp=(e,t,r)=>(((1-3*r+3*t)*e+(3*r-6*t))*e+3*t)*e,gv=1e-7,vv=12;function Av(e,t,r,n,a){let s,l,i=0;do l=t+(r-t)/2,s=Sp(l,n,a)-e,s>0?r=l:t=l;while(Math.abs(s)>gv&&++iAv(s,0,1,e,r);return s=>s===0||s===1?s:Sp(a(s),t,n)}const xp=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,Ip=e=>t=>1-e(1-t),Lp=Yn(.33,1.53,.69,.99),ko=Ip(Lp),Ep=xp(ko),Dp=e=>(e*=2)<1?.5*ko(e):.5*(2-Math.pow(2,-10*(e-1))),Ro=e=>1-Math.sin(Math.acos(e)),wp=Ip(Ro),jp=xp(Ro),Np=e=>/^0[^.\s]+$/u.test(e);function Cv(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||Np(e):!0}const Xn=e=>Math.round(e*1e5)/1e5,qo=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Tv(e){return e==null}const Sv=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Mo=(e,t)=>r=>!!(typeof r=="string"&&Sv.test(r)&&r.startsWith(e)||t&&!Tv(r)&&Object.prototype.hasOwnProperty.call(r,t)),Bp=(e,t,r)=>n=>{if(typeof n!="string")return n;const[a,s,l,i]=n.match(qo);return{[e]:parseFloat(a),[t]:parseFloat(s),[r]:parseFloat(l),alpha:i!==void 0?parseFloat(i):1}},xv=e=>Ct(0,255,e),zo=k(I({},Kr),{transform:e=>Math.round(xv(e))}),or={test:Mo("rgb","red"),parse:Bp("red","green","blue"),transform:({red:e,green:t,blue:r,alpha:n=1})=>"rgba("+zo.transform(e)+", "+zo.transform(t)+", "+zo.transform(r)+", "+Xn(Gn.transform(n))+")"};function Iv(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 Fo={test:Mo("#"),parse:Iv,transform:or.transform},Qr={test:Mo("hsl","hue"),parse:Bp("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:r,alpha:n=1})=>"hsla("+Math.round(e)+", "+it.transform(Xn(t))+", "+it.transform(Xn(r))+", "+Xn(Gn.transform(n))+")"},Ae={test:e=>or.test(e)||Fo.test(e)||Qr.test(e),parse:e=>or.test(e)?or.parse(e):Qr.test(e)?Qr.parse(e):Fo.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?or.transform(e):Qr.transform(e)},Lv=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function Ev(e){var t,r;return isNaN(e)&&typeof e=="string"&&(((t=e.match(qo))===null||t===void 0?void 0:t.length)||0)+(((r=e.match(Lv))===null||r===void 0?void 0:r.length)||0)>0}const Pp="number",Up="color",Dv="var",wv="var(",Op="${}",jv=/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(jv,o=>(Ae.test(o)?(n.color.push(s),a.push(Up),r.push(Ae.parse(o))):o.startsWith(wv)?(n.var.push(s),a.push(Dv),r.push(o)):(n.number.push(s),a.push(Pp),r.push(parseFloat(o))),++s,Op)).split(Op);return{values:r,split:i,indexes:n,types:a}}function kp(e){return Jn(e).values}function Rp(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 Bv(e){const t=kp(e);return Rp(e)(t.map(Nv))}const Zt={test:Ev,parse:kp,createTransformer:Rp,getAnimatableNone:Bv},Pv=new Set(["brightness","contrast","saturate","opacity"]);function Uv(e){const[t,r]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[n]=r.match(qo)||[];if(!n)return e;const a=r.replace(n,"");let s=Pv.has(t)?1:0;return n!==r&&(s*=100),t+"("+s+a+")"}const Ov=/\b([a-z-]*)\(.*?\)/gu,_o=k(I({},Zt),{getAnimatableNone:e=>{const t=e.match(Ov);return t?t.map(Uv).join(" "):e}}),kv=k(I({},vo),{color:Ae,backgroundColor:Ae,outlineColor:Ae,fill:Ae,stroke:Ae,borderColor:Ae,borderTopColor:Ae,borderRightColor:Ae,borderBottomColor:Ae,borderLeftColor:Ae,filter:_o,WebkitFilter:_o}),Vo=e=>kv[e];function qp(e,t){let r=Vo(e);return r!==_o&&(r=Zt),r.getAnimatableNone?r.getAnimatableNone(t):void 0}const Rv=new Set(["auto","none","0"]);function qv(e,t,r){let n=0,a;for(;ne===Kr||e===j,zp=(e,t)=>parseFloat(e.split(", ")[t]),Fp=(e,t)=>(r,{transform:n})=>{if(n==="none"||!n)return 0;const a=n.match(/^matrix3d\((.+)\)$/u);if(a)return zp(a[1],t);{const s=n.match(/^matrix\((.+)\)$/u);return s?zp(s[1],e):0}},Mv=new Set(["x","y","z"]),zv=Hr.filter(e=>!Mv.has(e));function Fv(e){const t=[];return zv.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:Fp(4,13),y:Fp(5,14)};Yr.translateX=Yr.x,Yr.translateY=Yr.y;const ur=new Set;let Zo=!1,$o=!1;function _p(){if($o){const e=Array.from(ur).filter(n=>n.needsMeasurement),t=new Set(e.map(n=>n.element)),r=new Map;t.forEach(n=>{const a=Fv(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)})}$o=!1,Zo=!1,ur.forEach(e=>e.complete()),ur.clear()}function Vp(){ur.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&($o=!0)})}function _v(){Vp(),_p()}class Go{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?(ur.add(this),Zo||(Zo=!0,V.read(Vp),V.resolveKeyframes(_p))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:r,element:n,motionValue:a}=this;for(let s=0;s/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),Vv=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Zv(e){const t=Vv.exec(e);if(!t)return[,];const[,r,n,a]=t;return[`--${r!=null?r:n}`,a]}function $p(e,t,r=1){const[n,a]=Zv(e);if(!n)return;const s=window.getComputedStyle(t).getPropertyValue(n);if(s){const l=s.trim();return Zp(l)?parseFloat(l):l}return go(a)?$p(a,t,r+1):a}const Gp=e=>t=>t.test(e),Wp=[Kr,j,it,Vt,Ug,Pg,{test:e=>e==="auto",parse:e=>e}],Hp=e=>Wp.find(Gp(e));class Kp extends Go{constructor(t,r,n,a,s){super(t,r,n,a,s,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:r,name:n}=this;if(!r||!r.current)return;super.readKeyframes();for(let o=0;o{r.getValue(o).set(u)}),this.resolveNoneKeyframes()}}const Qp=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(Zt.test(e)||e==="0")&&!e.startsWith("url("));function $v(e){const t=e[0];if(e.length===1)return!0;for(let r=0;re!==null;function Os(e,{repeat:t,repeatType:r="loop"},n){const a=e.filter(Wv),s=t&&r!=="loop"&&t%2===1?0:a.length-1;return!s||n===void 0?a[s]:n}const Hv=40;class Yp{constructor(o){var u=o,{autoplay:t=!0,delay:r=0,type:n="keyframes",repeat:a=0,repeatDelay:s=0,repeatType:l="loop"}=u,i=We(u,["autoplay","delay","type","repeat","repeatDelay","repeatType"]);this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=ot.now(),this.options=I({autoplay:t,delay:r,type:n,repeat:a,repeatDelay:s,repeatType:l},i),this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt?this.resolvedAt-this.createdAt>Hv?this.resolvedAt:this.createdAt:this.createdAt}get resolved(){return!this._resolved&&!this.hasAttemptedResolve&&_v(),this._resolved}onKeyframesResolved(t,r){this.resolvedAt=ot.now(),this.hasAttemptedResolve=!0;const{name:n,type:a,velocity:s,delay:l,onComplete:i,onUpdate:o,isGenerator:u}=this.options;if(!u&&!Gv(t,n,a,s))if(l)this.options.duration=0;else{o&&o(Os(t,this.options,r)),i&&i(),this.resolveFinishedPromise();return}const d=this.initPlayback(t,r);d!==!1&&(this._resolved=I({keyframes:t,finalKeyframe:r},d),this.onPostResolved())}onPostResolved(){}then(t,r){return this.currentFinishedPromise.then(t,r)}flatten(){this.options.type="keyframes",this.options.ease="linear"}updateFinishedPromise(){this.currentFinishedPromise=new Promise(t=>{this.resolveFinishedPromise=t})}}const H=(e,t,r)=>e+(t-e)*r;function Wo(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 Kv({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=Wo(o,i,e+1/3),s=Wo(o,i,e),l=Wo(o,i,e-1/3)}return{red:Math.round(a*255),green:Math.round(s*255),blue:Math.round(l*255),alpha:n}}function ks(e,t){return r=>r>0?t:e}const Ho=(e,t,r)=>{const n=e*e,a=r*(t*t-n)+n;return a<0?0:Math.sqrt(a)},Qv=[Fo,or,Qr],Yv=e=>Qv.find(t=>t.test(e));function Xp(e){const t=Yv(e);if(!t)return!1;let r=t.parse(e);return t===Qr&&(r=Kv(r)),r}const Jp=(e,t)=>{const r=Xp(e),n=Xp(t);if(!r||!n)return ks(e,t);const a=I({},r);return s=>(a.red=Ho(r.red,n.red,s),a.green=Ho(r.green,n.green,s),a.blue=Ho(r.blue,n.blue,s),a.alpha=H(r.alpha,n.alpha,s),or.transform(a))},Xv=(e,t)=>r=>t(e(r)),ea=(...e)=>e.reduce(Xv),Ko=new Set(["none","hidden"]);function Jv(e,t){return Ko.has(e)?r=>r<=0?e:t:r=>r>=1?t:e}function eA(e,t){return r=>H(e,t,r)}function Qo(e){return typeof e=="number"?eA:typeof e=="string"?go(e)?ks:Ae.test(e)?Jp:nA:Array.isArray(e)?ef:typeof e=="object"?Ae.test(e)?Jp:tA:ks}function ef(e,t){const r=[...e],n=r.length,a=e.map((s,l)=>Qo(s)(s,t[l]));return s=>{for(let l=0;l{for(const s in n)r[s]=n[s](a);return r}}function rA(e,t){var r;const n=[],a={color:0,var:0,number:0};for(let s=0;s{const r=Zt.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?Ko.has(e)&&!a.values.length||Ko.has(t)&&!n.values.length?Jv(e,t):ea(ef(rA(n,a),a.values),r):ks(e,t)};function tf(e,t,r){return typeof e=="number"&&typeof t=="number"&&typeof r=="number"?H(e,t,r):Qo(e)(e,t)}const aA=5;function rf(e,t,r){const n=Math.max(t-aA,0);return Ap(r-e(n),t-n)}const Y={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},nf=.001;function sA({duration:e=Y.duration,bounce:t=Y.bounce,velocity:r=Y.velocity,mass:n=Y.mass}){let a,s,l=1-t;l=Ct(Y.minDamping,Y.maxDamping,l),e=Ct(Y.minDuration,Y.maxDuration,At(e)),l<1?(a=u=>{const d=u*l,c=d*e,m=d-r,h=Yo(u,l),b=Math.exp(-c);return nf-m/h*b},s=u=>{const c=u*l*e,m=c*r+r,h=Math.pow(l,2)*Math.pow(u,2)*e,b=Math.exp(-c),g=Yo(Math.pow(u,2),l);return(-a(u)+nf>0?-1:1)*((m-h)*b)/g}):(a=u=>{const d=Math.exp(-u*e),c=(u-r)*e+1;return-.001+d*c},s=u=>{const d=Math.exp(-u*e),c=(r-u)*(e*e);return d*c});const i=5/e,o=iA(a,s,i);if(e=vt(e),isNaN(o))return{stiffness:Y.stiffness,damping:Y.damping,duration:e};{const u=Math.pow(o,2)*n;return{stiffness:u,damping:l*2*Math.sqrt(n*u),duration:e}}}const lA=12;function iA(e,t,r){let n=r;for(let a=1;ae[r]!==void 0)}function dA(e){let t=I({velocity:Y.velocity,stiffness:Y.stiffness,damping:Y.damping,mass:Y.mass,isResolvedFromDuration:!1},e);if(!af(e,uA)&&af(e,oA))if(e.visualDuration){const r=e.visualDuration,n=2*Math.PI/(r*1.2),a=n*n,s=2*Ct(.05,1,1-(e.bounce||0))*Math.sqrt(a);t=k(I({},t),{mass:Y.mass,stiffness:a,damping:s})}else{const r=sA(e);t=k(I(I({},t),r),{mass:Y.mass}),t.isResolvedFromDuration=!0}return t}function sf(e=Y.visualDuration,t=Y.bounce){const r=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:n,restDelta:a}=r;const s=r.keyframes[0],l=r.keyframes[r.keyframes.length-1],i={done:!1,value:s},{stiffness:o,damping:u,mass:d,duration:c,velocity:m,isResolvedFromDuration:h}=dA(k(I({},r),{velocity:-At(r.velocity||0)})),b=m||0,g=u/(2*Math.sqrt(o*d)),C=l-s,f=At(Math.sqrt(o/d)),p=Math.abs(C)<5;n||(n=p?Y.restSpeed.granular:Y.restSpeed.default),a||(a=p?Y.restDelta.granular:Y.restDelta.default);let y;if(g<1){const A=Yo(f,g);y=x=>{const L=Math.exp(-g*f*x);return l-L*((b+g*f*C)/A*Math.sin(A*x)+C*Math.cos(A*x))}}else if(g===1)y=A=>l-Math.exp(-f*A)*(C+(b+f*C)*A);else{const A=f*Math.sqrt(g*g-1);y=x=>{const L=Math.exp(-g*f*x),S=Math.min(A*x,300);return l-L*((b+g*f*C)*Math.sinh(S)+A*C*Math.cosh(S))/A}}const v={calculatedDuration:h&&c||null,next:A=>{const x=y(A);if(h)i.done=A>=c;else{let L=0;g<1&&(L=A===0?vt(b):rf(y,A,x));const S=Math.abs(L)<=n,O=Math.abs(l-x)<=a;i.done=S&&O}return i.value=i.done?l:x,i},toString:()=>{const A=Math.min(op(v),Lo),x=dp(L=>v.next(A*L).value,A,30);return A+"ms "+x}};return v}function lf({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:d}){const c=e[0],m={done:!1,value:c},h=S=>i!==void 0&&So,b=S=>i===void 0?o:o===void 0||Math.abs(i-S)-g*Math.exp(-S/n),y=S=>f+p(S),v=S=>{const O=p(S),N=y(S);m.done=Math.abs(O)<=u,m.value=m.done?f:N};let A,x;const L=S=>{h(m.value)&&(A=S,x=sf({keyframes:[m.value,b(m.value)],velocity:rf(y,S,m.value),damping:a,stiffness:s,restDelta:u,restSpeed:d}))};return L(0),{calculatedDuration:null,next:S=>{let O=!1;return!x&&A===void 0&&(O=!0,v(S),L(S)),A!==void 0&&S>=A?x.next(S-A):(!O&&v(S),m)}}}const cA=Yn(.42,0,1,1),mA=Yn(0,0,.58,1),of=Yn(.42,0,.58,1),pA=e=>Array.isArray(e)&&typeof e[0]!="number",uf={linear:ke,easeIn:cA,easeInOut:of,easeOut:mA,circIn:Ro,circInOut:jp,circOut:wp,backIn:ko,backInOut:Ep,backOut:Lp,anticipate:Dp},df=e=>{if(Do(e)){io(e.length===4);const[t,r,n,a]=e;return Yn(t,r,n,a)}else if(typeof e=="string")return io(uf[e]!==void 0),uf[e];return e};function fA(e,t,r){const n=[],a=r||tf,s=e.length-1;for(let l=0;lt[0];if(s===2&&t[0]===t[1])return()=>t[1];const l=e[0]===e[1];e[0]>e[s-1]&&(e=[...e].reverse(),t=[...t].reverse());const i=fA(t,n,a),o=i.length,u=d=>{if(l&&d1)for(;cu(Ct(e[0],e[s-1],d)):u}function hA(e,t){const r=e[e.length-1];for(let n=1;n<=t;n++){const a=$r(0,t,n);e.push(H(r,1,a))}}function bA(e){const t=[0];return hA(t,e.length-1),t}function gA(e,t){return e.map(r=>r*t)}function vA(e,t){return e.map(()=>t||of).splice(0,e.length-1)}function Rs({duration:e=300,keyframes:t,times:r,ease:n="easeInOut"}){const a=pA(n)?n.map(df):df(n),s={done:!1,value:t[0]},l=gA(r&&r.length===t.length?r:bA(t),e),i=yA(l,t,{ease:Array.isArray(a)?a:vA(t,a)});return{calculatedDuration:e,next:o=>(s.value=i(o),s.done=o>=e,s)}}const AA=e=>{const t=({timestamp:r})=>e(r);return{start:()=>V.update(t,!0),stop:()=>_t(t),now:()=>fe.isProcessing?fe.timestamp:ot.now()}},CA={decay:lf,inertia:lf,tween:Rs,keyframes:Rs,spring:sf},TA=e=>e/100;class Xo extends Yp{constructor(t){super(t),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.teardown();const{onStop:o}=this.options;o&&o()};const{name:r,motionValue:n,element:a,keyframes:s}=this.options,l=(a==null?void 0:a.KeyframeResolver)||Go,i=(o,u)=>this.onKeyframesResolved(o,u);this.resolver=new l(s,i,r,n,a),this.resolver.scheduleResolve()}flatten(){super.flatten(),this._resolved&&Object.assign(this._resolved,this.initPlayback(this._resolved.keyframes))}initPlayback(t){const{type:r="keyframes",repeat:n=0,repeatDelay:a=0,repeatType:s,velocity:l=0}=this.options,i=Eo(r)?r:CA[r]||Rs;let o,u;i!==Rs&&typeof t[0]!="number"&&(o=ea(TA,tf(t[0],t[1])),t=[0,100]);const d=i(k(I({},this.options),{keyframes:t}));s==="mirror"&&(u=i(k(I({},this.options),{keyframes:[...t].reverse(),velocity:-l}))),d.calculatedDuration===null&&(d.calculatedDuration=op(d));const{calculatedDuration:c}=d,m=c+a,h=m*(n+1)-a;return{generator:d,mirroredGenerator:u,mapPercentToKeyframes:o,calculatedDuration:c,resolvedDuration:m,totalDuration:h}}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:d,resolvedDuration:c}=n;if(this.startTime===null)return s.next(0);const{delay:m,repeat:h,repeatType:b,repeatDelay:g,onUpdate:C}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-d/this.speed,this.startTime)),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>d;this.currentTime=Math.max(f,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=d);let y=this.currentTime,v=s;if(h){const S=Math.min(this.currentTime,d)/c;let O=Math.floor(S),N=S%1;!N&&S>=1&&(N=1),N===1&&O--,O=Math.min(O,h+1),!!(O%2)&&(b==="reverse"?(N=1-N,g&&(N-=g/c)):b==="mirror"&&(v=l)),y=Ct(0,1,N)*c}const A=p?{done:!1,value:o[0]}:v.next(y);i&&(A.value=i(A.value));let{done:x}=A;!p&&u!==null&&(x=this.speed>=0?this.currentTime>=d:this.currentTime<=0);const L=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&x);return L&&a!==void 0&&(A.value=Os(o,this.options,a)),C&&C(A.value),L&&this.finish(),A}get duration(){const{resolved:t}=this;return t?At(t.calculatedDuration):0}get time(){return At(this.currentTime)}set time(t){t=vt(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=At(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;const{driver:t=AA,onPlay:r,startTime:n}=this.options;this.driver||(this.driver=t(s=>this.tick(s))),r&&r();const a=this.driver.now();this.holdTime!==null?this.startTime=a-this.holdTime:this.startTime?this.state==="finished"&&(this.startTime=a):this.startTime=n!=null?n:this.calcStartTime(),this.state==="finished"&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var t;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=(t=this.currentTime)!==null&&t!==void 0?t:0}complete(){this.state!=="running"&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:t}=this.options;t&&t()}cancel(){this.cancelTime!==null&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}}const SA=new Set(["opacity","clipPath","filter","transform"]);function xA(e,t,r,{delay:n=0,duration:a=300,repeat:s=0,repeatType:l="loop",ease:i="easeInOut",times:o}={}){const u={[t]:r};o&&(u.offset=o);const d=mp(i,a);return Array.isArray(d)&&(u.easing=d),e.animate(u,{delay:n,duration:a,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:s+1,direction:l==="reverse"?"alternate":"normal"})}const IA=oo(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),qs=10,LA=2e4;function EA(e){return Eo(e.type)||e.type==="spring"||!cp(e.ease)}function DA(e,t){const r=new Xo(k(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(l,i),r,n,a),this.resolver.scheduleResolve()}initPlayback(t,r){let{duration:n=300,times:a,ease:s,type:l,motionValue:i,name:o,startTime:u}=this.options;if(!i.owner||!i.owner.current)return!1;if(typeof s=="string"&&Ps()&&wA(s)&&(s=cf[s]),EA(this.options)){const c=this.options,{onComplete:m,onUpdate:h,motionValue:b,element:g}=c,C=We(c,["onComplete","onUpdate","motionValue","element"]),f=DA(t,C);t=f.keyframes,t.length===1&&(t[1]=t[0]),n=f.duration,a=f.times,s=f.ease,l="keyframes"}const d=xA(i.owner.current,o,t,k(I({},this.options),{duration:n,times:a,ease:s}));return d.startTime=u!=null?u:this.calcStartTime(),this.pendingTimeline?(up(d,this.pendingTimeline),this.pendingTimeline=void 0):d.onfinish=()=>{const{onComplete:m}=this.options;i.set(Os(t,this.options,r)),m&&m(),this.cancel(),this.resolveFinishedPromise()},{animation:d,duration:n,times:a,type:l,ease:s,keyframes:t}}get duration(){const{resolved:t}=this;if(!t)return 0;const{duration:r}=t;return At(r)}get time(){const{resolved:t}=this;if(!t)return 0;const{animation:r}=t;return At(r.currentTime||0)}set time(t){const{resolved:r}=this;if(!r)return;const{animation:n}=r;n.currentTime=vt(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}get startTime(){const{resolved:t}=this;if(!t)return null;const{animation:r}=t;return r.startTime}attachTimeline(t){if(!this._resolved)this.pendingTimeline=t;else{const{resolved:r}=this;if(!r)return ke;const{animation:n}=r;up(n,t)}return ke}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:d,onUpdate:c,onComplete:m,element:h}=u,b=We(u,["motionValue","onUpdate","onComplete","element"]),g=new Xo(k(I({},b),{keyframes:n,duration:a,type:s,ease:l,times:i,isGenerator:!0})),C=vt(this.time);d.setWithVelocity(g.sample(C-qs).value,g.sample(C).value,qs)}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;if(!r||!r.owner||!(r.owner.current instanceof HTMLElement))return!1;const{onUpdate:o,transformTemplate:u}=r.owner.getProps();return IA()&&n&&SA.has(n)&&!o&&!u&&!a&&s!=="mirror"&&l!==0&&i!=="inertia"}}const jA={type:"spring",stiffness:500,damping:25,restSpeed:10},NA=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),BA={type:"keyframes",duration:.8},PA={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},UA=(e,{keyframes:t})=>t.length>2?BA:ir.has(e)?e.startsWith("scale")?NA(t[1]):jA:PA;function OA(c){var m=c,{when:e,delay:t,delayChildren:r,staggerChildren:n,staggerDirection:a,repeat:s,repeatType:l,repeatDelay:i,from:o,elapsed:u}=m,d=We(m,["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);return!!Object.keys(d).length}const Jo=(e,t,r,n={},a,s)=>l=>{const i=Io(n,e)||{},o=i.delay||n.delay||0;let{elapsed:u=0}=n;u=u-vt(o);let d=k(I({keyframes:Array.isArray(r)?r:[null,r],ease:"easeOut",velocity:t.getVelocity()},i),{delay:-u,onUpdate:m=>{t.set(m),i.onUpdate&&i.onUpdate(m)},onComplete:()=>{l(),i.onComplete&&i.onComplete()},name:e,motionValue:t,element:s?void 0:a});OA(i)||(d=I(I({},d),UA(e,d))),d.duration&&(d.duration=vt(d.duration)),d.repeatDelay&&(d.repeatDelay=vt(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let c=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(d.duration=0,d.delay===0&&(c=!0)),c&&!s&&t.get()!==void 0){const m=Os(d.keyframes,i);if(m!==void 0)return V.update(()=>{d.onUpdate(m),d.onComplete()}),new rv([])}return!s&&mf.supports(d)?new mf(d):new Xo(d)};function kA({protectedKeys:e,needsAnimating:t},r){const n=e.hasOwnProperty(r)&&t[r]!==!0;return t[r]=!1,n}function pf(e,t,{delay:r=0,transitionOverride:n,type:a}={}){var s;let c=t,{transition:l=e.getDefaultTransition(),transitionEnd:i}=c,o=We(c,["transition","transitionEnd"]);n&&(l=n);const u=[],d=a&&e.animationState&&e.animationState.getState()[a];for(const m in o){const h=e.getValue(m,(s=e.latestValues[m])!==null&&s!==void 0?s:null),b=o[m];if(b===void 0||d&&kA(d,m))continue;const g=I({delay:r},Io(l||{},m));let C=!1;if(window.MotionHandoffAnimation){const p=Tp(e);if(p){const y=window.MotionHandoffAnimation(p,m,V);y!==null&&(g.startTime=y,C=!0)}}Oo(e,m),h.start(Jo(m,h,b,e.shouldReduceMotion&&vp.has(m)?{type:!1}:g,e,C));const f=h.animation;f&&u.push(f)}return i&&Promise.all(u).then(()=>{V.update(()=>{i&&hv(e,i)})}),u}function eu(e,t,r={}){var n;const a=Bs(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(pf(e,a,r)):()=>Promise.resolve(),i=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:d=0,staggerChildren:c,staggerDirection:m}=s;return RA(e,t,d+u,c,m,r)}:()=>Promise.resolve(),{when:o}=s;if(o){const[u,d]=o==="beforeChildren"?[l,i]:[i,l];return u().then(()=>d())}else return Promise.all([l(),i(r.delay)])}function RA(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(qA).forEach((u,d)=>{u.notify("AnimationStart",t),l.push(eu(u,t,k(I({},s),{delay:r+o(d)})).then(()=>u.notify("AnimationComplete",t)))}),Promise.all(l)}function qA(e,t){return e.sortNodePosition(t)}function MA(e,t,r={}){e.notify("AnimationStart",t);let n;if(Array.isArray(t)){const a=t.map(s=>eu(e,s,r));n=Promise.all(a)}else if(typeof t=="string")n=eu(e,t,r);else{const a=typeof t=="function"?Bs(e,t,r.custom):t;n=Promise.all(pf(e,a,r))}return n.then(()=>{e.notify("AnimationComplete",t)})}const zA=mo.length;function ff(e){if(!e)return;if(!e.isControllingVariants){const r=e.parent?ff(e.parent)||{}:{};return e.props.initial!==void 0&&(r.initial=e.props.initial),r}const t={};for(let r=0;rPromise.all(t.map(({animation:r,options:n})=>MA(e,r,n)))}function ZA(e){let t=VA(e),r=yf(),n=!0;const a=o=>(u,d)=>{var c;const m=Bs(e,d,o==="exit"?(c=e.presenceContext)===null||c===void 0?void 0:c.custom:void 0);if(m){const h=m,{transition:b,transitionEnd:g}=h,C=We(h,["transition","transitionEnd"]);u=I(I(I({},u),C),g)}return u};function s(o){t=o(e)}function l(o){const{props:u}=e,d=ff(e.parent)||{},c=[],m=new Set;let h={},b=1/0;for(let C=0;C<_A;C++){const f=FA[C],p=r[f],y=u[f]!==void 0?u[f]:d[f],v=$n(y),A=f===o?p.isActive:null;A===!1&&(b=C);let x=y===d[f]&&y!==u[f]&&v;if(x&&n&&e.manuallyAnimateOnMount&&(x=!1),p.protectedKeys=I({},h),!p.isActive&&A===null||!y&&!p.prevProp||Es(y)||typeof y=="boolean")continue;const L=$A(p.prevProp,y);let S=L||f===o&&p.isActive&&!x&&v||C>b&&v,O=!1;const N=Array.isArray(y)?y:[y];let ue=N.reduce(a(f),{});A===!1&&(ue={});const{prevResolvedValues:Gt={}}=p,pr=I(I({},Gt),ue),ua=se=>{S=!0,m.has(se)&&(O=!0,m.delete(se)),p.needsAnimating[se]=!0;const E=e.getValue(se);E&&(E.liveStyle=!1)};for(const se in pr){const E=ue[se],B=Gt[se];if(h.hasOwnProperty(se))continue;let P=!1;bo(E)&&bo(B)?P=!ip(E,B):P=E!==B,P?E!=null?ua(se):m.add(se):E!==void 0&&m.has(se)?ua(se):p.protectedKeys[se]=!0}p.prevProp=y,p.prevResolvedValues=ue,p.isActive&&(h=I(I({},h),ue)),n&&e.blockInitialAnimation&&(S=!1),S&&(!(x&&L)||O)&&c.push(...N.map(se=>({animation:se,options:{type:f}})))}if(m.size){const C={};m.forEach(f=>{const p=e.getBaseTarget(f),y=e.getValue(f);y&&(y.liveStyle=!0),C[f]=p!=null?p:null}),c.push({animation:C})}let g=!!c.length;return n&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(g=!1),n=!1,g?t(c):Promise.resolve()}function i(o,u){var d;if(r[o].isActive===u)return Promise.resolve();(d=e.variantChildren)===null||d===void 0||d.forEach(m=>{var h;return(h=m.animationState)===null||h===void 0?void 0:h.setActive(o,u)}),r[o].isActive=u;const c=l(o);for(const m in r)r[m].protectedKeys={};return c}return{animateChanges:l,setActive:i,setAnimateFunction:s,getState:()=>r,reset:()=>{r=yf(),n=!0}}}function $A(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!ip(t,e):!1}function dr(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function yf(){return{animate:dr(!0),whileInView:dr(),whileHover:dr(),whileTap:dr(),whileDrag:dr(),whileFocus:dr(),exit:dr()}}class $t{constructor(t){this.isMounted=!1,this.node=t}update(){}}class GA extends $t{constructor(t){super(t),t.animationState||(t.animationState=ZA(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Es(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 WA=0;class HA extends $t{constructor(){super(...arguments),this.id=WA++}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 KA={animation:{Feature:GA},exit:{Feature:HA}};function ta(e,t,r,n={passive:!0}){return e.addEventListener(t,r,n),()=>e.removeEventListener(t,r)}function ra(e){return{point:{x:e.pageX,y:e.pageY}}}const QA=e=>t=>jo(t)&&e(t,ra(t));function na(e,t,r,n){return ta(e,t,QA(r),n)}const hf=(e,t)=>Math.abs(e-t);function YA(e,t){const r=hf(e.x,t.x),n=hf(e.y,t.y);return Math.sqrt(fu(r,2)+fu(n,2))}class bf{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 c=ru(this.lastMoveEventInfo,this.history),m=this.startEvent!==null,h=YA(c.offset,{x:0,y:0})>=3;if(!m&&!h)return;const{point:b}=c,{timestamp:g}=fe;this.history.push(k(I({},b),{timestamp:g}));const{onStart:C,onMove:f}=this.handlers;m||(C&&C(this.lastMoveEvent,c),this.startEvent=this.lastMoveEvent),f&&f(this.lastMoveEvent,c)},this.handlePointerMove=(c,m)=>{this.lastMoveEvent=c,this.lastMoveEventInfo=tu(m,this.transformPagePoint),V.update(this.updatePoint,!0)},this.handlePointerUp=(c,m)=>{this.end();const{onEnd:h,onSessionEnd:b,resumeAnimation:g}=this.handlers;if(this.dragSnapToOrigin&&g&&g(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const C=ru(c.type==="pointercancel"?this.lastMoveEventInfo:tu(m,this.transformPagePoint),this.history);this.startEvent&&h&&h(c,C),b&&b(c,C)},!jo(t))return;this.dragSnapToOrigin=s,this.handlers=r,this.transformPagePoint=n,this.contextWindow=a||window;const l=ra(t),i=tu(l,this.transformPagePoint),{point:o}=i,{timestamp:u}=fe;this.history=[k(I({},o),{timestamp:u})];const{onSessionStart:d}=r;d&&d(t,ru(i,this.history)),this.removeListeners=ea(na(this.contextWindow,"pointermove",this.handlePointerMove),na(this.contextWindow,"pointerup",this.handlePointerUp),na(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),_t(this.updatePoint)}}function tu(e,t){return t?{point:t(e.point)}:e}function gf(e,t){return{x:e.x-t.x,y:e.y-t.y}}function ru({point:e},t){return{point:e,delta:gf(e,vf(t)),offset:gf(e,XA(t)),velocity:JA(t,.1)}}function XA(e){return e[0]}function vf(e){return e[e.length-1]}function JA(e,t){if(e.length<2)return{x:0,y:0};let r=e.length-1,n=null;const a=vf(e);for(;r>=0&&(n=e[r],!(a.timestamp-n.timestamp>vt(t)));)r--;if(!n)return{x:0,y:0};const s=At(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 Af=1e-4,eC=1-Af,tC=1+Af,Cf=.01,rC=0-Cf,nC=0+Cf;function Re(e){return e.max-e.min}function aC(e,t,r){return Math.abs(e-t)<=r}function Tf(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>=eC&&e.scale<=tC||isNaN(e.scale))&&(e.scale=1),(e.translate>=rC&&e.translate<=nC||isNaN(e.translate))&&(e.translate=0)}function aa(e,t,r,n){Tf(e.x,t.x,r.x,n?n.originX:void 0),Tf(e.y,t.y,r.y,n?n.originY:void 0)}function Sf(e,t,r){e.min=r.min+t.min,e.max=e.min+Re(t)}function sC(e,t,r){Sf(e.x,t.x,r.x),Sf(e.y,t.y,r.y)}function xf(e,t,r){e.min=t.min-r.min,e.max=e.min+Re(t)}function sa(e,t,r){xf(e.x,t.x,r.x),xf(e.y,t.y,r.y)}function lC(e,{min:t,max:r},n){return t!==void 0&&er&&(e=n?H(r,e,n.max):Math.min(e,r)),e}function If(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 iC(e,{top:t,left:r,bottom:n,right:a}){return{x:If(e.x,r,a),y:If(e.y,t,n)}}function Lf(e,t){let r=t.min-e.min,n=t.max-e.max;return t.max-t.minn?r=$r(t.min,t.max-n,e.min):n>a&&(r=$r(e.min,e.max-a,t.min)),Ct(0,1,r)}function dC(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 nu=.35;function cC(e=nu){return e===!1?e=0:e===!0&&(e=nu),{x:Ef(e,"left","right"),y:Ef(e,"top","bottom")}}function Ef(e,t,r){return{min:Df(e,t),max:Df(e,r)}}function Df(e,t){return typeof e=="number"?e:e[t]||0}const wf=()=>({translate:0,scale:1,origin:0,originPoint:0}),Xr=()=>({x:wf(),y:wf()}),jf=()=>({min:0,max:0}),J=()=>({x:jf(),y:jf()});function $e(e){return[e("x"),e("y")]}function Nf({top:e,left:t,right:r,bottom:n}){return{x:{min:t,max:r},y:{min:e,max:n}}}function mC({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function pC(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 au(e){return e===void 0||e===1}function su({scale:e,scaleX:t,scaleY:r}){return!au(e)||!au(t)||!au(r)}function cr(e){return su(e)||Bf(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function Bf(e){return Pf(e.x)||Pf(e.y)}function Pf(e){return e&&e!=="0%"}function Ms(e,t,r){const n=e-r,a=t*n;return r+a}function Uf(e,t,r,n,a){return a!==void 0&&(e=Ms(e,a,n)),Ms(e,r,n)+t}function lu(e,t=0,r=1,n,a){e.min=Uf(e.min,t,r,n,a),e.max=Uf(e.max,t,r,n,a)}function Of(e,{x:t,y:r}){lu(e.x,t.translate,t.scale,t.originPoint),lu(e.y,r.translate,r.scale,r.originPoint)}const kf=.999999999999,Rf=1.0000000000001;function fC(e,t,r,n=!1){const a=r.length;if(!a)return;t.x=t.y=1;let s,l;for(let i=0;ikf&&(t.x=1),t.ykf&&(t.y=1)}function Jr(e,t){e.min=e.min+t,e.max=e.max+t}function qf(e,t,r,n,a=.5){const s=H(e.min,e.max,a);lu(e,t,r,s,n)}function en(e,t){qf(e.x,t.x,t.scaleX,t.scale,t.originX),qf(e.y,t.y,t.scaleY,t.scale,t.originY)}function Mf(e,t){return Nf(pC(e.getBoundingClientRect(),t))}function yC(e,t,r){const n=Mf(e,r),{scroll:a}=t;return a&&(Jr(n.x,a.offset.x),Jr(n.y,a.offset.y)),n}const zf=({current:e})=>e?e.ownerDocument.defaultView:null,hC=new WeakMap;class bC{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=J(),this.visualElement=t}start(t,{snapToCursor:r=!1}={}){const{presenceContext:n}=this.visualElement;if(n&&n.isPresent===!1)return;const a=d=>{const{dragSnapToOrigin:c}=this.getProps();c?this.pauseAnimation():this.stopAnimation(),r&&this.snapToCursor(ra(d).point)},s=(d,c)=>{const{drag:m,dragPropagation:h,onDragStart:b}=this.getProps();if(m&&!h&&(this.openDragLock&&this.openDragLock(),this.openDragLock=cv(m),!this.openDragLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),$e(C=>{let f=this.getAxisMotionValue(C).get()||0;if(it.test(f)){const{projection:p}=this.visualElement;if(p&&p.layout){const y=p.layout.layoutBox[C];y&&(f=Re(y)*(parseFloat(f)/100))}}this.originPoint[C]=f}),b&&V.postRender(()=>b(d,c)),Oo(this.visualElement,"transform");const{animationState:g}=this.visualElement;g&&g.setActive("whileDrag",!0)},l=(d,c)=>{const{dragPropagation:m,dragDirectionLock:h,onDirectionLock:b,onDrag:g}=this.getProps();if(!m&&!this.openDragLock)return;const{offset:C}=c;if(h&&this.currentDirection===null){this.currentDirection=gC(C),this.currentDirection!==null&&b&&b(this.currentDirection);return}this.updateAxis("x",c.point,C),this.updateAxis("y",c.point,C),this.visualElement.render(),g&&g(d,c)},i=(d,c)=>this.stop(d,c),o=()=>$e(d=>{var c;return this.getAnimationState(d)==="paused"&&((c=this.getAxisMotionValue(d).animation)===null||c===void 0?void 0:c.play())}),{dragSnapToOrigin:u}=this.getProps();this.panSession=new bf(t,{onSessionStart:a,onStart:s,onMove:l,onSessionEnd:i,resumeAnimation:o},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,contextWindow:zf(this.visualElement)})}stop(t,r){const n=this.isDragging;if(this.cancel(),!n)return;const{velocity:a}=r;this.startAnimation(a);const{onDragEnd:s}=this.getProps();s&&V.postRender(()=>s(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.openDragLock&&(this.openDragLock(),this.openDragLock=null),r&&r.setActive("whileDrag",!1)}updateAxis(t,r,n){const{drag:a}=this.getProps();if(!n||!zs(t,a,this.currentDirection))return;const s=this.getAxisMotionValue(t);let l=this.originPoint[t]+n[t];this.constraints&&this.constraints[t]&&(l=lC(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&&Wr(r)?this.constraints||(this.constraints=this.resolveRefConstraints()):r&&a?this.constraints=iC(a.layoutBox,r):this.constraints=!1,this.elastic=cC(n),s!==this.constraints&&a&&this.constraints&&!this.hasMutatedConstraints&&$e(l=>{this.constraints!==!1&&this.getAxisMotionValue(l)&&(this.constraints[l]=dC(a.layoutBox[l],this.constraints[l]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:r}=this.getProps();if(!t||!Wr(t))return!1;const n=t.current,{projection:a}=this.visualElement;if(!a||!a.layout)return!1;const s=yC(n,a.root,this.visualElement.getTransformPagePoint());let l=oC(a.layout.layoutBox,s);if(r){const i=r(mC(l));this.hasMutatedConstraints=!!i,i&&(l=Nf(i))}return l}startAnimation(t){const{drag:r,dragMomentum:n,dragElastic:a,dragTransition:s,dragSnapToOrigin:l,onDragTransitionEnd:i}=this.getProps(),o=this.constraints||{},u=$e(d=>{if(!zs(d,r,this.currentDirection))return;let c=o[d]||{};l&&(c={min:0,max:0});const m=a?200:1e6,h=a?40:1e7,b=I(I({type:"inertia",velocity:n?t[d]:0,bounceStiffness:m,bounceDamping:h,timeConstant:750,restDelta:1,restSpeed:10},s),c);return this.startAxisValueAnimation(d,b)});return Promise.all(u).then(i)}startAxisValueAnimation(t,r){const n=this.getAxisMotionValue(t);return Oo(this.visualElement,t),n.start(Jo(t,n,0,r,this.visualElement,!1))}stopAnimation(){$e(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){$e(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){$e(r=>{const{drag:n}=this.getProps();if(!zs(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(!Wr(r)||!n||!this.constraints)return;this.stopAnimation();const a={x:0,y:0};$e(l=>{const i=this.getAxisMotionValue(l);if(i&&this.constraints!==!1){const o=i.get();a[l]=uC({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(),$e(l=>{if(!zs(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;hC.set(this.visualElement,this);const t=this.visualElement.current,r=na(t,"pointerdown",o=>{const{drag:u,dragListener:d=!0}=this.getProps();u&&d&&this.start(o)}),n=()=>{const{dragConstraints:o}=this.getProps();Wr(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()),V.read(n);const l=ta(window,"resize",()=>this.scalePositionWithinConstraints()),i=a.addEventListener("didUpdate",({delta:o,hasLayoutChanged:u})=>{this.isDragging&&u&&($e(d=>{const c=this.getAxisMotionValue(d);c&&(this.originPoint[d]+=o[d].translate,c.set(c.get()+o[d].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=nu,dragMomentum:i=!0}=t;return k(I({},t),{drag:r,dragDirectionLock:n,dragPropagation:a,dragConstraints:s,dragElastic:l,dragMomentum:i})}}function zs(e,t,r){return(t===!0||t===e)&&(r===null||r===e)}function gC(e,t=10){let r=null;return Math.abs(e.y)>t?r="y":Math.abs(e.x)>t&&(r="x"),r}class vC extends $t{constructor(t){super(t),this.removeGroupControls=ke,this.removeListeners=ke,this.controls=new bC(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||ke}unmount(){this.removeGroupControls(),this.removeListeners()}}const Ff=e=>(t,r)=>{e&&V.postRender(()=>e(t,r))};class AC extends $t{constructor(){super(...arguments),this.removePointerDownListener=ke}onPointerDown(t){this.session=new bf(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:zf(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:r,onPan:n,onPanEnd:a}=this.node.getProps();return{onSessionStart:Ff(t),onStart:Ff(r),onMove:n,onEnd:(s,l)=>{delete this.session,a&&V.postRender(()=>a(s,l))}}}mount(){this.removePointerDownListener=na(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const Fs={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function _f(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=_f(e,t.target.x),n=_f(e,t.target.y);return`${r}% ${n}%`}},CC={correct:(e,{treeScale:t,projectionDelta:r})=>{const n=e,a=Zt.parse(e);if(a.length>5)return n;const s=Zt.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 TC extends w.Component{componentDidMount(){const{visualElement:t,layoutGroup:r,switchLayoutGroup:n,layoutId:a}=this.props,{projection:s}=t;Zg(SC),s&&(r.group&&r.group.add(s),n&&n.register&&a&&n.register(s),s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions(k(I({},s.options),{onExitComplete:()=>this.safeToRemove()}))),Fs.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()||V.postRender(()=>{const i=l.getStack();(!i||!i.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),fo.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 Vf(e){const[t,r]=lg(),n=w.useContext(Um);return R.jsx(TC,k(I({},e),{layoutGroup:n,switchLayoutGroup:w.useContext(Vm),isPresent:t,safeToRemove:r}))}const SC={borderRadius:k(I({},la),{applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]}),borderTopLeftRadius:la,borderTopRightRadius:la,borderBottomLeftRadius:la,borderBottomRightRadius:la,boxShadow:CC};function xC(e,t,r){const n=ve(e)?e:Qn(e);return n.start(Jo("",n,t,r)),n.animation}function IC(e){return e instanceof SVGElement&&e.tagName!=="svg"}const LC=(e,t)=>e.depth-t.depth;class EC{constructor(){this.children=[],this.isDirty=!1}add(t){Bo(this.children,t),this.isDirty=!0}remove(t){Po(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(LC),this.isDirty=!1,this.children.forEach(t)}}function DC(e,t){const r=ot.now(),n=({timestamp:a})=>{const s=a-r;s>=t&&(_t(n),e(s-t))};return V.read(n,!0),()=>_t(n)}const Zf=["TopLeft","TopRight","BottomLeft","BottomRight"],wC=Zf.length,$f=e=>typeof e=="string"?parseFloat(e):e,Gf=e=>typeof e=="number"||j.test(e);function jC(e,t,r,n,a,s){a?(e.opacity=H(0,r.opacity!==void 0?r.opacity:1,NC(n)),e.opacityExit=H(t.opacity!==void 0?t.opacity:1,0,BC(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($r(e,t,n))}function Kf(e,t){e.min=t.min,e.max=t.max}function Ge(e,t){Kf(e.x,t.x),Kf(e.y,t.y)}function Qf(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function Yf(e,t,r,n,a){return e-=t,e=Ms(e,1/r,n),a!==void 0&&(e=Ms(e,1/a,n)),e}function PC(e,t=0,r=1,n=.5,a,s=e,l=e){if(it.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=Yf(e.min,t,r,i,a),e.max=Yf(e.max,t,r,i,a)}function Xf(e,t,[r,n,a],s,l){PC(e,t[r],t[n],t[a],t.scale,s,l)}const UC=["x","scaleX","originX"],OC=["y","scaleY","originY"];function Jf(e,t,r,n){Xf(e.x,t,UC,r?r.x:void 0,n?n.x:void 0),Xf(e.y,t,OC,r?r.y:void 0,n?n.y:void 0)}function ey(e){return e.translate===0&&e.scale===1}function ty(e){return ey(e.x)&&ey(e.y)}function ry(e,t){return e.min===t.min&&e.max===t.max}function kC(e,t){return ry(e.x,t.x)&&ry(e.y,t.y)}function ny(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function ay(e,t){return ny(e.x,t.x)&&ny(e.y,t.y)}function sy(e){return Re(e.x)/Re(e.y)}function ly(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class RC{constructor(){this.members=[]}add(t){Bo(this.members,t),t.scheduleRender()}remove(t){if(Po(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 qC(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:d,rotateX:c,rotateY:m,skewX:h,skewY:b}=r;u&&(n=`perspective(${u}px) ${n}`),d&&(n+=`rotate(${d}deg) `),c&&(n+=`rotateX(${c}deg) `),m&&(n+=`rotateY(${m}deg) `),h&&(n+=`skewX(${h}deg) `),b&&(n+=`skewY(${b}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 mr={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},ia=typeof window!="undefined"&&window.MotionDebug!==void 0,iu=["","X","Y","Z"],MC={visibility:"hidden"},iy=1e3;let zC=0;function ou(e,t,r,n){const{latestValues:a}=t;a[e]&&(r[e]=a[e],t.setStaticValue(e,0),n&&(n[e]=0))}function oy(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const r=Tp(t);if(window.MotionHasOptimisedAnimation(r,"transform")){const{layout:a,layoutId:s}=e.options;window.MotionCancelOptimisedAnimation(r,"transform",V,!(a||s))}const{parent:n}=e;n&&!n.hasCheckedOptimisedAppear&&oy(n)}function uy({attachResizeListener:e,defaultParent:t,measureScroll:r,checkIsScrollRoot:n,resetTransform:a}){return class{constructor(l={},i=t==null?void 0:t()){this.id=zC++,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&&(mr.totalNodes=mr.resolvedTargetDeltas=mr.recalculatedProjection=0),this.nodes.forEach(VC),this.nodes.forEach(HC),this.nodes.forEach(KC),this.nodes.forEach(ZC),ia&&window.MotionDebug.record(mr)},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,c&&c(),c=DC(m,250),Fs.hasAnimatedSinceResize&&(Fs.hasAnimatedSinceResize=!1,this.nodes.forEach(cy))})}o&&this.root.registerSharedNode(o,this),this.options.animate!==!1&&d&&(o||u)&&this.addEventListener("didUpdate",({delta:c,hasLayoutChanged:m,hasRelativeTargetChanged:h,layout:b})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const g=this.options.transition||d.getDefaultTransition()||eT,{onLayoutAnimationStart:C,onLayoutAnimationComplete:f}=d.getProps(),p=!this.targetLayout||!ay(this.targetLayout,b)||h,y=!m&&h;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||y||m&&(p||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(c,y);const v=k(I({},Io(g,"layout")),{onPlay:C,onComplete:f});(d.shouldReduceMotion||this.options.layoutRoot)&&(v.delay=0,v.type=!1),this.startAnimation(v)}else m||cy(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=b})}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,_t(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(QC),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.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&oy(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d{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 A=v/1e3;my(c.x,l.x,A),my(c.y,l.y,A),this.setTargetDelta(c),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(sa(m,this.layout.layoutBox,this.relativeParent.layout.layoutBox),XC(this.relativeTarget,this.relativeTargetOrigin,m,A),y&&kC(this.relativeTarget,y)&&(this.isProjectionDirty=!1),y||(y=J()),Ge(y,this.relativeTarget)),g&&(this.animationValues=d,jC(d,u,this.latestValues,A,p,f)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=A},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&&(_t(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=V.update(()=>{Fs.hasAnimatedSinceResize=!0,this.currentAnimation=xC(0,iy,k(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(iy),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const l=this.getLead();let{targetWithTransforms:i,target:o,layout:u,latestValues:d}=l;if(!(!i||!o||!u)){if(this!==l&&this.layout&&u&&by(this.options.animationType,this.layout.layoutBox,u.layoutBox)){o=this.target||J();const c=Re(this.layout.layoutBox.x);o.x.min=l.target.x.min,o.x.max=o.x.min+c;const m=Re(this.layout.layoutBox.y);o.y.min=l.target.y.min,o.y.max=o.y.min+m}Ge(i,o),en(i,d),aa(this.projectionDeltaWithTransform,this.layoutCorrected,i,d)}}registerSharedNode(l,i){this.sharedNodes.has(l)||this.sharedNodes.set(l,new RC),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&&ou("z",l,u,this.animationValues);for(let d=0;d{var i;return(i=l.currentAnimation)===null||i===void 0?void 0:i.stop()}),this.root.nodes.forEach(dy),this.root.sharedNodes.clear()}}}function FC(e){e.updateLayout()}function _C(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"?$e(c=>{const m=l?r.measuredBox[c]:r.layoutBox[c],h=Re(m);m.min=n[c].min,m.max=m.min+h}):by(s,r.layoutBox,n)&&$e(c=>{const m=l?r.measuredBox[c]:r.layoutBox[c],h=Re(n[c]);m.max=m.min+h,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[c].max=e.relativeTarget[c].min+h)});const i=Xr();aa(i,n,r.layoutBox);const o=Xr();l?aa(o,e.applyTransform(a,!0),r.measuredBox):aa(o,n,r.layoutBox);const u=!ty(i);let d=!1;if(!e.resumeFrom){const c=e.getClosestProjectingParent();if(c&&!c.resumeFrom){const{snapshot:m,layout:h}=c;if(m&&h){const b=J();sa(b,r.layoutBox,m.layoutBox);const g=J();sa(g,n,h.layoutBox),ay(b,g)||(d=!0),c.options.layoutRoot&&(e.relativeTarget=g,e.relativeTargetOrigin=b,e.relativeParent=c)}}}e.notifyListeners("didUpdate",{layout:n,snapshot:r,delta:o,layoutDelta:i,hasLayoutChanged:u,hasRelativeTargetChanged:d})}else if(e.isLead()){const{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function VC(e){ia&&mr.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 ZC(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function $C(e){e.clearSnapshot()}function dy(e){e.clearMeasurements()}function GC(e){e.isLayoutDirty=!1}function WC(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function cy(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function HC(e){e.resolveTargetDelta()}function KC(e){e.calcProjection()}function QC(e){e.resetSkewAndRotation()}function YC(e){e.removeLeadSnapshot()}function my(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 py(e,t,r,n){e.min=H(t.min,r.min,n),e.max=H(t.max,r.max,n)}function XC(e,t,r,n){py(e.x,t.x,r.x,n),py(e.y,t.y,r.y,n)}function JC(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const eT={duration:.45,ease:[.4,0,.1,1]},fy=e=>typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),yy=fy("applewebkit/")&&!fy("chrome/")?Math.round:ke;function hy(e){e.min=yy(e.min),e.max=yy(e.max)}function tT(e){hy(e.x),hy(e.y)}function by(e,t,r){return e==="position"||e==="preserve-aspect"&&!aC(sy(t),sy(r),.2)}function rT(e){var t;return e!==e.root&&((t=e.scroll)===null||t===void 0?void 0:t.wasRoot)}const nT=uy({attachResizeListener:(e,t)=>ta(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),uu={current:void 0},gy=uy({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!uu.current){const e=new nT({});e.mount(window),e.setOptions({layoutScroll:!0}),uu.current=e}return uu.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),aT={pan:{Feature:AC},drag:{Feature:vC,ProjectionNode:gy,MeasureLayout:Vf}};function vy(e,t,r){const{props:n}=e;e.animationState&&n.whileHover&&e.animationState.setActive("whileHover",r==="Start");const a="onHover"+r,s=n[a];s&&V.postRender(()=>s(t,ra(t)))}class sT extends $t{mount(){const{current:t}=this.node;t&&(this.unmount=lv(t,r=>(vy(this.node,r,"Start"),n=>vy(this.node,n,"End"))))}unmount(){}}class lT 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=ea(ta(this.node.current,"focus",()=>this.onFocus()),ta(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Ay(e,t,r){const{props:n}=e;e.animationState&&n.whileTap&&e.animationState.setActive("whileTap",r==="Start");const a="onTap"+(r==="End"?"":r),s=n[a];s&&V.postRender(()=>s(t,ra(t)))}class iT extends $t{mount(){const{current:t}=this.node;t&&(this.unmount=dv(t,r=>(Ay(this.node,r,"Start"),(n,{success:a})=>Ay(this.node,n,a?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const du=new WeakMap,cu=new WeakMap,oT=e=>{const t=du.get(e.target);t&&t(e)},uT=e=>{e.forEach(oT)};function dT(r){var n=r,{root:e}=n,t=We(n,["root"]);const a=e||document;cu.has(a)||cu.set(a,{});const s=cu.get(a),l=JSON.stringify(t);return s[l]||(s[l]=new IntersectionObserver(uT,I({root:e},t))),s[l]}function cT(e,t,r){const n=dT(t);return du.set(e,r),n.observe(e),()=>{du.delete(e),n.unobserve(e)}}const mT={some:0,all:1};class pT 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:mT[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:d,onViewportLeave:c}=this.node.getProps(),m=u?d:c;m&&m(o)};return cT(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(fT(t,r))&&this.startObserver()}unmount(){}}function fT({viewport:e={}},{viewport:t={}}={}){return r=>e[r]!==t[r]}const yT={inView:{Feature:pT},tap:{Feature:iT},focus:{Feature:lT},hover:{Feature:sT}},hT={layout:{ProjectionNode:gy,MeasureLayout:Vf}},mu={current:null},Cy={current:!1};function bT(){if(Cy.current=!0,!!lo)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>mu.current=e.matches;e.addListener(t),t()}else mu.current=!1}const gT=[...Wp,Ae,Zt],vT=e=>gT.find(Gp(e)),Ty=new WeakMap;function AT(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,Qn(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,Qn(l!==void 0?l:a,{owner:e}))}}for(const n in r)t[n]===void 0&&e.removeValue(n);return t}const Sy=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class CT{scrapeMotionValuesFromProps(t,r,n){return{}}constructor({parent:t,props:r,presenceContext:n,reducedMotionConfig:a,blockInitialAnimation:s,visualState:l},i={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Go,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const b=ot.now();this.renderScheduledAtthis.bindToMotionValue(n,r)),Cy.current||bT(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:mu.current,this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){Ty.delete(this.current),this.projection&&this.projection.unmount(),_t(this.notifyUpdate),_t(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(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){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const n=ir.has(t),a=r.on("change",i=>{this.latestValues[t]=i,this.props.onUpdate&&V.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)}),s=r.on("renderRequest",this.scheduleRender);let l;window.MotionCheckAppearSync&&(l=window.MotionCheckAppearSync(this,t,r)),this.valueSubscriptions.set(t,()=>{a(),s(),l&&l(),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 Gr){const r=Gr[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):J()}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=Qn(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"&&(Zp(a)||Np(a))?a=parseFloat(a):!vT(a)&&Zt.test(r)&&(a=qp(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=ho(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 Uo),this.events[t].add(r)}notify(t,...r){this.events[t]&&this.events[t].notify(...r)}}class xy extends CT{constructor(){super(...arguments),this.KeyframeResolver=Kp}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]}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}`)}))}}function TT(e){return window.getComputedStyle(e)}class ST extends xy{constructor(){super(...arguments),this.type="html",this.renderInstance=ep}readValueFromInstance(t,r){if(ir.has(r)){const n=Vo(r);return n&&n.default||0}else{const n=TT(t),a=(Hm(r)?n.getPropertyValue(r):n[r])||0;return typeof a=="string"?a.trim():a}}measureInstanceViewportBox(t,{transformPagePoint:r}){return Mf(t,r)}build(t,r,n){Ao(t,r,n.transformTemplate)}scrapeMotionValuesFromProps(t,r,n){return xo(t,r,n)}}class xT extends xy{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=J}getBaseTargetFromProps(t,r){return t[r]}readValueFromInstance(t,r){if(ir.has(r)){const n=Vo(r);return n&&n.default||0}return r=tp.has(r)?r:po(r),t.getAttribute(r)}scrapeMotionValuesFromProps(t,r,n){return ap(t,r,n)}build(t,r,n){Co(t,r,this.isSVGTag,n.transformTemplate)}renderInstance(t,r,n,a){rp(t,r,n,a)}mount(t){this.isSVGTag=So(t.tagName),super.mount(t)}}const IT=(e,t)=>yo(e)?new xT(t):new ST(t,{allowProjection:e!==w.Fragment}),LT=Jg(I(I(I(I({},KA),yT),aT),hT),IT),ET=yg(LT),Iy={name:"dc-connectors",private:!0,version:"0.1.3",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"}}},DT={hidden:{opacity:0,y:20},visible:{opacity:1,y:0,transition:{duration:.6,ease:[.45,.14,.1,.97]}}},wT=Iy.version,jT=Iy.name,NT=window.location.hostname==="localhost"?`${window.location.origin}/`:`https://a.sfdcstatic.com/digital/@sfdc-www/open-blade-libs/${jT}/v${wT}`,oa=new URLSearchParams(window.location.search).has("retroMode"),BT=({index:e,item:t,isVisible:r,shouldAnimate:n})=>{const a=s=>R.jsxs(ET.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:DT,"data-index":e,animate:n?"visible":"hidden",children:[R.jsx("div",{className:`flex-none py-3 pr-4 ${oa?"border-yellow-400":"border-gray-200"} border-r-2`,children:R.jsx("img",{role:"presentation",src:NT+t.iconUrl,alt:t.label,className:"w-10 h-10 align-middle"})}),R.jsxs("div",{className:"pl-4 flex-grow overflow-hidden items-center",children:[R.jsxs("div",{className:"flex-grow",children:[t.releaseLevel==="IN_DEV"&&R.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:R.jsx("div",{className:"text-white text-[10px] font-bold leading-none tracking-tight",children:"Coming Soon"})}),t.releaseLevel==="BETA"&&R.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:R.jsx("div",{className:"text-[10px] font-bold leading-none tracking-tight",children:"Beta"})})]}),R.jsx("h3",{className:`mb-2 font-bold overflow-hidden truncate ${oa?"text-green-400":"text-sfnavy"}`,children:t.label}),R.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 R.jsxs(R.Fragment,{children:[a(t.ingressDescription),t.egressDescription&&a(t.egressDescription)]})},PT=ng.map(e=>k(I({},e),{name:e.label||"",features:e.label||[],featuresConfig:{IncrementalUpdate:{deleteSupport:"No"}},connectionAttributes:{},extractAttributes:{}})),UT=[...rg.filter(e=>e.releaseLevel!=="IN_DEV"&&e.releaseLevel!=="PILOT"&&e.name!=="OCI"&&e.name!=="TenantBillingUsageConnector"),...PT,ag].sort((e,t)=>e.label.localeCompare(t.label));function OT(){const[e,t]=w.useState(""),[r,n]=w.useState(new Set),[a,s]=w.useState(new Set),[l,i]=w.useState(0),o=h=>{t(h.target.value),n(new Set)},u=UT.filter(h=>e?e==="GA"?h.releaseLevel==="GA"||h.releaseLevel==="MuleSoft":h.releaseLevel===e:!0);w.useEffect(()=>{i(u.length)},[u]);const d=w.useRef(new IntersectionObserver(h=>{const b=h.filter(g=>g.isIntersecting);if(b.length){const g=new Set(r),C=new Set(a);b.forEach(f=>{const p=Number(f.target.getAttribute("data-index"));g.add(p),C.add(p)}),n(g),s(C)}},{threshold:.5}));w.useEffect(()=>{const h=d.current;return document.querySelectorAll(".card").forEach(g=>{h.observe(g)}),()=>{h.disconnect()}},[u]);const m=new URLSearchParams(window.location.search).has("retroMode");return R.jsxs(R.Fragment,{children:[m&&R.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; } `}),R.jsx("div",{className:`${m?"bg-black text-green-400 py-10":""}`,children:R.jsx("div",{className:"container mx-auto lg:mt-0 md:mt-5 pt-0 min-h-screen ",children:R.jsxs("div",{className:"flex flex-col items-center min-h-screen text-gray-900 font-sans",children:[R.jsxs("div",{className:"flex space-x-4 mb-6",children:[R.jsx("label",{htmlFor:"filter",className:`mr-2 font-bold text-[18px]${m?"text-green-400":""}`,children:"Filter:"}),R.jsxs("select",{id:"filter",value:e,onChange:o,className:`border p-1 rounded ${m?"bg-black text-green-400 border-green-400":""}`,children:[R.jsx("option",{value:"",children:"All"}),R.jsx("option",{value:"BETA",children:"Beta"}),R.jsx("option",{value:"GA",children:"General Availability"})]})]}),m&&R.jsxs("div",{id:"connectorCounter",className:"mb-4 font-mono text-4xl text-green-600 bg-black p-4 rounded",children:[l," Data Sources"]}),!m&&R.jsxs("div",{id:"connectorCounter",className:" mb-4",children:[l," Data Sources"]}),R.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((h,b)=>R.jsx(BT,{index:b,item:h,isVisible:r.has(b)||a.has(b),shouldAnimate:r.has(b),"data-index":b,retroMode:m},b))})]})})})]})}Ys.createRoot(document.getElementById("wps-dc-integrator")).render(R.jsx($y.StrictMode,{children:R.jsx(OT,{})}))});