var bU=Object.defineProperty;var xU=(e,t,r)=>t in e?bU(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var hm=(e,t,r)=>(xU(e,typeof t!="symbol"?t+"":t,r),r);function N9(e,t){for(var r=0;rn[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))n(i);new MutationObserver(i=>{for(const a of i)if(a.type==="childList")for(const s of a.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&n(s)}).observe(document,{childList:!0,subtree:!0});function r(i){const a={};return i.integrity&&(a.integrity=i.integrity),i.referrerPolicy&&(a.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?a.credentials="include":i.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function n(i){if(i.ep)return;i.ep=!0;const a=r(i);fetch(i.href,a)}})();const _U="modulepreload",SU=function(e){return"/"+e},UM={},xt=function(t,r,n){let i=Promise.resolve();if(r&&r.length>0){const a=document.getElementsByTagName("link");i=Promise.all(r.map(s=>{if(s=SU(s),s in UM)return;UM[s]=!0;const f=s.endsWith(".css"),d=f?'[rel="stylesheet"]':"";if(!!n)for(let w=a.length-1;w>=0;w--){const _=a[w];if(_.href===s&&(!f||_.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${s}"]${d}`))return;const y=document.createElement("link");if(y.rel=f?"stylesheet":_U,f||(y.as="script",y.crossOrigin=""),y.href=s,document.head.appendChild(y),f)return new Promise((w,_)=>{y.addEventListener("load",w),y.addEventListener("error",()=>_(new Error(`Unable to preload CSS for ${s}`)))})}))}return i.then(()=>t()).catch(a=>{const s=new Event("vite:preloadError",{cancelable:!0});if(s.payload=a,window.dispatchEvent(s),!s.defaultPrevented)throw a})};var Ut=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};function Ci(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function K1(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var r=function n(){return this instanceof n?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(e).forEach(function(n){var i=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(r,n,i.get?i:{enumerable:!0,get:function(){return e[n]}})}),r}var j9={exports:{}},G1={},B9={exports:{}},gr={};/** * @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 ep=Symbol.for("react.element"),MU=Symbol.for("react.portal"),EU=Symbol.for("react.fragment"),kU=Symbol.for("react.strict_mode"),TU=Symbol.for("react.profiler"),CU=Symbol.for("react.provider"),PU=Symbol.for("react.context"),OU=Symbol.for("react.forward_ref"),RU=Symbol.for("react.suspense"),AU=Symbol.for("react.memo"),DU=Symbol.for("react.lazy"),HM=Symbol.iterator;function $U(e){return e===null||typeof e!="object"?null:(e=HM&&e[HM]||e["@@iterator"],typeof e=="function"?e:null)}var F9={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},z9=Object.assign,U9={};function bd(e,t,r){this.props=e,this.context=t,this.refs=U9,this.updater=r||F9}bd.prototype.isReactComponent={};bd.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")};bd.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function H9(){}H9.prototype=bd.prototype;function O6(e,t,r){this.props=e,this.context=t,this.refs=U9,this.updater=r||F9}var R6=O6.prototype=new H9;R6.constructor=O6;z9(R6,bd.prototype);R6.isPureReactComponent=!0;var VM=Array.isArray,V9=Object.prototype.hasOwnProperty,A6={current:null},q9={key:!0,ref:!0,__self:!0,__source:!0};function W9(e,t,r){var n,i={},a=null,s=null;if(t!=null)for(n in t.ref!==void 0&&(s=t.ref),t.key!==void 0&&(a=""+t.key),t)V9.call(t,n)&&!q9.hasOwnProperty(n)&&(i[n]=t[n]);var f=arguments.length-2;if(f===1)i.children=r;else if(1>>1,P=E[m];if(0>>1;mi(ee,l))qi(ae,ee)?(E[m]=ae,E[q]=l,m=q):(E[m]=ee,E[F]=l,m=F);else if(qi(ae,l))E[m]=ae,E[q]=l,m=q;else break e}}return v}function i(E,v){var l=E.sortIndex-v.sortIndex;return l!==0?l:E.id-v.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var s=Date,f=s.now();e.unstable_now=function(){return s.now()-f}}var d=[],p=[],y=1,w=null,_=3,S=!1,M=!1,C=!1,O=typeof setTimeout=="function"?setTimeout:null,T=typeof clearTimeout=="function"?clearTimeout:null,k=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function R(E){for(var v=r(p);v!==null;){if(v.callback===null)n(p);else if(v.startTime<=E)n(p),v.sortIndex=v.expirationTime,t(d,v);else break;v=r(p)}}function $(E){if(C=!1,R(E),!M)if(r(d)!==null)M=!0,g(L);else{var v=r(p);v!==null&&x($,v.startTime-E)}}function L(E,v){M=!1,C&&(C=!1,T(V),V=-1),S=!0;var l=_;try{for(R(v),w=r(d);w!==null&&(!(w.expirationTime>v)||E&&!b());){var m=w.callback;if(typeof m=="function"){w.callback=null,_=w.priorityLevel;var P=m(w.expirationTime<=v);v=e.unstable_now(),typeof P=="function"?w.callback=P:w===r(d)&&n(d),R(v)}else n(d);w=r(d)}if(w!==null)var N=!0;else{var F=r(p);F!==null&&x($,F.startTime-v),N=!1}return N}finally{w=null,_=l,S=!1}}var j=!1,A=null,V=-1,z=5,Y=-1;function b(){return!(e.unstable_now()-YE||125m?(E.sortIndex=l,t(p,E),r(d)===null&&E===r(p)&&(C?(T(V),V=-1):C=!0,x($,l-m))):(E.sortIndex=P,t(d,E),M||S||(M=!0,g(L))),E},e.unstable_shouldYield=b,e.unstable_wrapCallback=function(E){var v=_;return function(){var l=_;_=v;try{return E.apply(this,arguments)}finally{_=l}}}})(X9);Y9.exports=X9;var qU=Y9.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 Z9=X,ua=qU;function gt(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),R_=Object.prototype.hasOwnProperty,WU=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,WM={},KM={};function KU(e){return R_.call(KM,e)?!0:R_.call(WM,e)?!1:WU.test(e)?KM[e]=!0:(WM[e]=!0,!1)}function GU(e,t,r,n){if(r!==null&&r.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return n?!1:r!==null?!r.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function YU(e,t,r,n){if(t===null||typeof t>"u"||GU(e,t,r,n))return!0;if(n)return!1;if(r!==null)switch(r.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function Oi(e,t,r,n,i,a,s){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=n,this.attributeNamespace=i,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=a,this.removeEmptyString=s}var Jn={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Jn[e]=new Oi(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Jn[t]=new Oi(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Jn[e]=new Oi(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Jn[e]=new Oi(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){Jn[e]=new Oi(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Jn[e]=new Oi(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Jn[e]=new Oi(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Jn[e]=new Oi(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Jn[e]=new Oi(e,5,!1,e.toLowerCase(),null,!1,!1)});var I6=/[\-:]([a-z])/g;function L6(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(I6,L6);Jn[t]=new Oi(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(I6,L6);Jn[t]=new Oi(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(I6,L6);Jn[t]=new Oi(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Jn[e]=new Oi(e,1,!1,e.toLowerCase(),null,!1,!1)});Jn.xlinkHref=new Oi("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Jn[e]=new Oi(e,1,!1,e.toLowerCase(),null,!0,!0)});function N6(e,t,r,n){var i=Jn.hasOwnProperty(t)?Jn[t]:null;(i!==null?i.type!==0:n||!(2f||i[s]!==a[f]){var d=` `+i[s].replace(" at new "," at ");return e.displayName&&d.includes("")&&(d=d.replace("",e.displayName)),d}while(1<=s&&0<=f);break}}}finally{Db=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?Lh(e):""}function XU(e){switch(e.tag){case 5:return Lh(e.type);case 16:return Lh("Lazy");case 13:return Lh("Suspense");case 19:return Lh("SuspenseList");case 0:case 2:case 15:return e=$b(e.type,!1),e;case 11:return e=$b(e.type.render,!1),e;case 1:return e=$b(e.type,!0),e;default:return""}}function I_(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 ef:return"Fragment";case Qc:return"Portal";case A_:return"Profiler";case j6:return"StrictMode";case D_:return"Suspense";case $_:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case eR:return(e.displayName||"Context")+".Consumer";case Q9:return(e._context.displayName||"Context")+".Provider";case B6:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case F6:return t=e.displayName||null,t!==null?t:I_(e.type)||"Memo";case _l:t=e._payload,e=e._init;try{return I_(e(t))}catch{}}return null}function ZU(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 I_(t);case 8:return t===j6?"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 Ql(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function rR(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function JU(e){var t=rR(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),n=""+e[t];if(!e.hasOwnProperty(t)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(s){n=""+s,a.call(this,s)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(s){n=""+s},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function vm(e){e._valueTracker||(e._valueTracker=JU(e))}function nR(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),n="";return e&&(n=rR(e)?e.checked?"true":"false":e.value),e=n,e!==r?(t.setValue(e),!0):!1}function eg(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function L_(e,t){var r=t.checked;return ln({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r??e._wrapperState.initialChecked})}function YM(e,t){var r=t.defaultValue==null?"":t.defaultValue,n=t.checked!=null?t.checked:t.defaultChecked;r=Ql(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 iR(e,t){t=t.checked,t!=null&&N6(e,"checked",t,!1)}function N_(e,t){iR(e,t);var r=Ql(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")?j_(e,t.type,r):t.hasOwnProperty("defaultValue")&&j_(e,t.type,Ql(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function XM(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 j_(e,t,r){(t!=="number"||eg(e.ownerDocument)!==e)&&(r==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}var Nh=Array.isArray;function yf(e,t,r,n){if(e=e.options,t){t={};for(var i=0;i"+t.valueOf().toString()+"",t=gm.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function h0(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var Kh={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},QU=["Webkit","ms","Moz","O"];Object.keys(Kh).forEach(function(e){QU.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Kh[t]=Kh[e]})});function lR(e,t,r){return t==null||typeof t=="boolean"||t===""?"":r||typeof t!="number"||t===0||Kh.hasOwnProperty(e)&&Kh[e]?(""+t).trim():t+"px"}function uR(e,t){e=e.style;for(var r in t)if(t.hasOwnProperty(r)){var n=r.indexOf("--")===0,i=lR(r,t[r],n);r==="float"&&(r="cssFloat"),n?e.setProperty(r,i):e[r]=i}}var eH=ln({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 z_(e,t){if(t){if(eH[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(gt(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(gt(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(gt(61))}if(t.style!=null&&typeof t.style!="object")throw Error(gt(62))}}function U_(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 H_=null;function z6(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var V_=null,wf=null,bf=null;function QM(e){if(e=np(e)){if(typeof V_!="function")throw Error(gt(280));var t=e.stateNode;t&&(t=Q1(t),V_(e.stateNode,e.type,t))}}function cR(e){wf?bf?bf.push(e):bf=[e]:wf=e}function fR(){if(wf){var e=wf,t=bf;if(bf=wf=null,QM(e),t)for(e=0;e>>=0,e===0?32:31-(fH(e)/dH|0)|0}var ym=64,wm=4194304;function jh(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 ig(e,t){var r=e.pendingLanes;if(r===0)return 0;var n=0,i=e.suspendedLanes,a=e.pingedLanes,s=r&268435455;if(s!==0){var f=s&~i;f!==0?n=jh(f):(a&=s,a!==0&&(n=jh(a)))}else s=r&~i,s!==0?n=jh(s):a!==0&&(n=jh(a));if(n===0)return 0;if(t!==0&&t!==n&&!(t&i)&&(i=n&-n,a=t&-t,i>=a||i===16&&(a&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 tp(e,t,r){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-vo(t),e[t]=r}function vH(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=Yh),lE=" ",uE=!1;function RR(e,t){switch(e){case"keyup":return VH.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function AR(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var tf=!1;function WH(e,t){switch(e){case"compositionend":return AR(t);case"keypress":return t.which!==32?null:(uE=!0,lE);case"textInput":return e=t.data,e===lE&&uE?null:e;default:return null}}function KH(e,t){if(tf)return e==="compositionend"||!Y6&&RR(e,t)?(e=PR(),mv=W6=Rl=null,tf=!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=hE(r)}}function LR(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?LR(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function NR(){for(var e=window,t=eg();t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch{r=!1}if(r)e=t.contentWindow;else break;t=eg(e.document)}return t}function X6(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 rV(e){var t=NR(),r=e.focusedElem,n=e.selectionRange;if(t!==r&&r&&r.ownerDocument&&LR(r.ownerDocument.documentElement,r)){if(n!==null&&X6(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 i=r.textContent.length,a=Math.min(n.start,i);n=n.end===void 0?a:Math.min(n.end,i),!e.extend&&a>n&&(i=n,n=a,a=i),i=pE(r,a);var s=pE(r,n);i&&s&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==s.node||e.focusOffset!==s.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),a>n?(e.addRange(t),e.extend(s.node,s.offset)):(t.setEnd(s.node,s.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,rf=null,X_=null,Zh=null,Z_=!1;function mE(e,t,r){var n=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;Z_||rf==null||rf!==eg(n)||(n=rf,"selectionStart"in n&&X6(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}),Zh&&w0(Zh,n)||(Zh=n,n=sg(X_,"onSelect"),0of||(e.current=n4[of],n4[of]=null,of--)}function Yr(e,t){of++,n4[of]=e.current,e.current=t}var eu={},pi=lu(eu),Ni=lu(!1),tc=eu;function Nf(e,t){var r=e.type.contextTypes;if(!r)return eu;var n=e.stateNode;if(n&&n.__reactInternalMemoizedUnmaskedChildContext===t)return n.__reactInternalMemoizedMaskedChildContext;var i={},a;for(a in r)i[a]=t[a];return n&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function ji(e){return e=e.childContextTypes,e!=null}function ug(){en(Ni),en(pi)}function _E(e,t,r){if(pi.current!==eu)throw Error(gt(168));Yr(pi,t),Yr(Ni,r)}function WR(e,t,r){var n=e.stateNode;if(t=t.childContextTypes,typeof n.getChildContext!="function")return r;n=n.getChildContext();for(var i in n)if(!(i in t))throw Error(gt(108,ZU(e)||"Unknown",i));return ln({},r,n)}function cg(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||eu,tc=pi.current,Yr(pi,e),Yr(Ni,Ni.current),!0}function SE(e,t,r){var n=e.stateNode;if(!n)throw Error(gt(169));r?(e=WR(e,t,tc),n.__reactInternalMemoizedMergedChildContext=e,en(Ni),en(pi),Yr(pi,e)):en(Ni),Yr(Ni,r)}var Ls=null,ey=!1,Gb=!1;function KR(e){Ls===null?Ls=[e]:Ls.push(e)}function pV(e){ey=!0,KR(e)}function uu(){if(!Gb&&Ls!==null){Gb=!0;var e=0,t=jr;try{var r=Ls;for(jr=1;e>=s,i-=s,Bs=1<<32-vo(t)+i|r<V?(z=A,A=null):z=A.sibling;var Y=_(T,A,R[V],$);if(Y===null){A===null&&(A=z);break}e&&A&&Y.alternate===null&&t(T,A),k=a(Y,k,V),j===null?L=Y:j.sibling=Y,j=Y,A=z}if(V===R.length)return r(T,A),nn&&Ru(T,V),L;if(A===null){for(;VV?(z=A,A=null):z=A.sibling;var b=_(T,A,Y.value,$);if(b===null){A===null&&(A=z);break}e&&A&&b.alternate===null&&t(T,A),k=a(b,k,V),j===null?L=b:j.sibling=b,j=b,A=z}if(Y.done)return r(T,A),nn&&Ru(T,V),L;if(A===null){for(;!Y.done;V++,Y=R.next())Y=w(T,Y.value,$),Y!==null&&(k=a(Y,k,V),j===null?L=Y:j.sibling=Y,j=Y);return nn&&Ru(T,V),L}for(A=n(T,A);!Y.done;V++,Y=R.next())Y=S(A,T,V,Y.value,$),Y!==null&&(e&&Y.alternate!==null&&A.delete(Y.key===null?V:Y.key),k=a(Y,k,V),j===null?L=Y:j.sibling=Y,j=Y);return e&&A.forEach(function(o){return t(T,o)}),nn&&Ru(T,V),L}function O(T,k,R,$){if(typeof R=="object"&&R!==null&&R.type===ef&&R.key===null&&(R=R.props.children),typeof R=="object"&&R!==null){switch(R.$$typeof){case mm:e:{for(var L=R.key,j=k;j!==null;){if(j.key===L){if(L=R.type,L===ef){if(j.tag===7){r(T,j.sibling),k=i(j,R.props.children),k.return=T,T=k;break e}}else if(j.elementType===L||typeof L=="object"&&L!==null&&L.$$typeof===_l&&OE(L)===j.type){r(T,j.sibling),k=i(j,R.props),k.ref=dh(T,j,R),k.return=T,T=k;break e}r(T,j);break}else t(T,j);j=j.sibling}R.type===ef?(k=Zu(R.props.children,T.mode,$,R.key),k.return=T,T=k):($=Sv(R.type,R.key,R.props,null,T.mode,$),$.ref=dh(T,k,R),$.return=T,T=$)}return s(T);case Qc:e:{for(j=R.key;k!==null;){if(k.key===j)if(k.tag===4&&k.stateNode.containerInfo===R.containerInfo&&k.stateNode.implementation===R.implementation){r(T,k.sibling),k=i(k,R.children||[]),k.return=T,T=k;break e}else{r(T,k);break}else t(T,k);k=k.sibling}k=r2(R,T.mode,$),k.return=T,T=k}return s(T);case _l:return j=R._init,O(T,k,j(R._payload),$)}if(Nh(R))return M(T,k,R,$);if(sh(R))return C(T,k,R,$);km(T,R)}return typeof R=="string"&&R!==""||typeof R=="number"?(R=""+R,k!==null&&k.tag===6?(r(T,k.sibling),k=i(k,R),k.return=T,T=k):(r(T,k),k=t2(R,T.mode,$),k.return=T,T=k),s(T)):r(T,k)}return O}var Bf=tA(!0),rA=tA(!1),ip={},Qo=lu(ip),S0=lu(ip),M0=lu(ip);function zu(e){if(e===ip)throw Error(gt(174));return e}function aS(e,t){switch(Yr(M0,t),Yr(S0,e),Yr(Qo,ip),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:F_(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=F_(t,e)}en(Qo),Yr(Qo,t)}function Ff(){en(Qo),en(S0),en(M0)}function nA(e){zu(M0.current);var t=zu(Qo.current),r=F_(t,e.type);t!==r&&(Yr(S0,e),Yr(Qo,r))}function oS(e){S0.current===e&&(en(Qo),en(S0))}var on=lu(0);function vg(e){for(var t=e;t!==null;){if(t.tag===13){var r=t.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||r.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Yb=[];function sS(){for(var e=0;er?r:4,e(!0);var n=Xb.transition;Xb.transition={};try{e(!1),t()}finally{jr=r,Xb.transition=n}}function wA(){return Fa().memoizedState}function yV(e,t,r){var n=Ul(e);if(r={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null},bA(e))xA(t,r);else if(r=ZR(e,t,r,n),r!==null){var i=ki();go(r,e,n,i),_A(r,t,n)}}function wV(e,t,r){var n=Ul(e),i={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null};if(bA(e))xA(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var s=t.lastRenderedState,f=a(s,r);if(i.hasEagerState=!0,i.eagerState=f,yo(f,s)){var d=t.interleaved;d===null?(i.next=i,nS(t)):(i.next=d.next,d.next=i),t.interleaved=i;return}}catch{}finally{}r=ZR(e,t,i,n),r!==null&&(i=ki(),go(r,e,n,i),_A(r,t,n))}}function bA(e){var t=e.alternate;return e===sn||t!==null&&t===sn}function xA(e,t){Jh=gg=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function _A(e,t,r){if(r&4194240){var n=t.lanes;n&=e.pendingLanes,r|=n,t.lanes=r,H6(e,r)}}var yg={readContext:Ba,useCallback:ri,useContext:ri,useEffect:ri,useImperativeHandle:ri,useInsertionEffect:ri,useLayoutEffect:ri,useMemo:ri,useReducer:ri,useRef:ri,useState:ri,useDebugValue:ri,useDeferredValue:ri,useTransition:ri,useMutableSource:ri,useSyncExternalStore:ri,useId:ri,unstable_isNewReconciler:!1},bV={readContext:Ba,useCallback:function(e,t){return zo().memoizedState=[e,t===void 0?null:t],e},useContext:Ba,useEffect:AE,useImperativeHandle:function(e,t,r){return r=r!=null?r.concat([e]):null,wv(4194308,4,pA.bind(null,t,e),r)},useLayoutEffect:function(e,t){return wv(4194308,4,e,t)},useInsertionEffect:function(e,t){return wv(4,2,e,t)},useMemo:function(e,t){var r=zo();return t=t===void 0?null:t,e=e(),r.memoizedState=[e,t],e},useReducer:function(e,t,r){var n=zo();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=yV.bind(null,sn,e),[n.memoizedState,e]},useRef:function(e){var t=zo();return e={current:e},t.memoizedState=e},useState:RE,useDebugValue:dS,useDeferredValue:function(e){return zo().memoizedState=e},useTransition:function(){var e=RE(!1),t=e[0];return e=gV.bind(null,e[1]),zo().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var n=sn,i=zo();if(nn){if(r===void 0)throw Error(gt(407));r=r()}else{if(r=t(),Nn===null)throw Error(gt(349));nc&30||oA(n,t,r)}i.memoizedState=r;var a={value:r,getSnapshot:t};return i.queue=a,AE(lA.bind(null,n,a,e),[e]),n.flags|=2048,T0(9,sA.bind(null,n,a,r,t),void 0,null),r},useId:function(){var e=zo(),t=Nn.identifierPrefix;if(nn){var r=Fs,n=Bs;r=(n&~(1<<32-vo(n)-1)).toString(32)+r,t=":"+t+"R"+r,r=E0++,0<\/script>",e=e.removeChild(e.firstChild)):typeof n.is=="string"?e=s.createElement(r,{is:n.is}):(e=s.createElement(r),r==="select"&&(s=e,n.multiple?s.multiple=!0:n.size&&(s.size=n.size))):e=s.createElementNS(e,r),e[Vo]=t,e[_0]=n,RA(e,t,!1,!1),t.stateNode=e;e:{switch(s=U_(r,n),r){case"dialog":Jr("cancel",e),Jr("close",e),i=n;break;case"iframe":case"object":case"embed":Jr("load",e),i=n;break;case"video":case"audio":for(i=0;iUf&&(t.flags|=128,n=!0,hh(a,!1),t.lanes=4194304)}else{if(!n)if(e=vg(s),e!==null){if(t.flags|=128,n=!0,r=e.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),hh(a,!0),a.tail===null&&a.tailMode==="hidden"&&!s.alternate&&!nn)return ni(t),null}else 2*pn()-a.renderingStartTime>Uf&&r!==1073741824&&(t.flags|=128,n=!0,hh(a,!1),t.lanes=4194304);a.isBackwards?(s.sibling=t.child,t.child=s):(r=a.last,r!==null?r.sibling=s:t.child=s,a.last=s)}return a.tail!==null?(t=a.tail,a.rendering=t,a.tail=t.sibling,a.renderingStartTime=pn(),t.sibling=null,r=on.current,Yr(on,n?r&1|2:r&1),t):(ni(t),null);case 22:case 23:return yS(),n=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==n&&(t.flags|=8192),n&&t.mode&1?ea&1073741824&&(ni(t),t.subtreeFlags&6&&(t.flags|=8192)):ni(t),null;case 24:return null;case 25:return null}throw Error(gt(156,t.tag))}function CV(e,t){switch(J6(t),t.tag){case 1:return ji(t.type)&&ug(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Ff(),en(Ni),en(pi),sS(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return oS(t),null;case 13:if(en(on),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(gt(340));jf()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return en(on),null;case 4:return Ff(),null;case 10:return rS(t.type._context),null;case 22:case 23:return yS(),null;case 24:return null;default:return null}}var Cm=!1,di=!1,PV=typeof WeakSet=="function"?WeakSet:Set,Tt=null;function cf(e,t){var r=e.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(n){cn(e,t,n)}else r.current=null}function m4(e,t,r){try{r()}catch(n){cn(e,t,n)}}var zE=!1;function OV(e,t){if(J_=ag,e=NR(),X6(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 i=n.anchorOffset,a=n.focusNode;n=n.focusOffset;try{r.nodeType,a.nodeType}catch{r=null;break e}var s=0,f=-1,d=-1,p=0,y=0,w=e,_=null;t:for(;;){for(var S;w!==r||i!==0&&w.nodeType!==3||(f=s+i),w!==a||n!==0&&w.nodeType!==3||(d=s+n),w.nodeType===3&&(s+=w.nodeValue.length),(S=w.firstChild)!==null;)_=w,w=S;for(;;){if(w===e)break t;if(_===r&&++p===i&&(f=s),_===a&&++y===n&&(d=s),(S=w.nextSibling)!==null)break;w=_,_=w.parentNode}w=S}r=f===-1||d===-1?null:{start:f,end:d}}else r=null}r=r||{start:0,end:0}}else r=null;for(Q_={focusedElem:e,selectionRange:r},ag=!1,Tt=t;Tt!==null;)if(t=Tt,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,Tt=e;else for(;Tt!==null;){t=Tt;try{var M=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(M!==null){var C=M.memoizedProps,O=M.memoizedState,T=t.stateNode,k=T.getSnapshotBeforeUpdate(t.elementType===t.type?C:uo(t.type,C),O);T.__reactInternalSnapshotBeforeUpdate=k}break;case 3:var R=t.stateNode.containerInfo;R.nodeType===1?R.textContent="":R.nodeType===9&&R.documentElement&&R.removeChild(R.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(gt(163))}}catch($){cn(t,t.return,$)}if(e=t.sibling,e!==null){e.return=t.return,Tt=e;break}Tt=t.return}return M=zE,zE=!1,M}function Qh(e,t,r){var n=t.updateQueue;if(n=n!==null?n.lastEffect:null,n!==null){var i=n=n.next;do{if((i.tag&e)===e){var a=i.destroy;i.destroy=void 0,a!==void 0&&m4(t,r,a)}i=i.next}while(i!==n)}}function ny(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 v4(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 $A(e){var t=e.alternate;t!==null&&(e.alternate=null,$A(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Vo],delete t[_0],delete t[r4],delete t[dV],delete t[hV])),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 IA(e){return e.tag===5||e.tag===3||e.tag===4}function UE(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||IA(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 g4(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=lg));else if(n!==4&&(e=e.child,e!==null))for(g4(e,t,r),e=e.sibling;e!==null;)g4(e,t,r),e=e.sibling}function y4(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(y4(e,t,r),e=e.sibling;e!==null;)y4(e,t,r),e=e.sibling}var Yn=null,co=!1;function hl(e,t,r){for(r=r.child;r!==null;)LA(e,t,r),r=r.sibling}function LA(e,t,r){if(Jo&&typeof Jo.onCommitFiberUnmount=="function")try{Jo.onCommitFiberUnmount(Y1,r)}catch{}switch(r.tag){case 5:di||cf(r,t);case 6:var n=Yn,i=co;Yn=null,hl(e,t,r),Yn=n,co=i,Yn!==null&&(co?(e=Yn,r=r.stateNode,e.nodeType===8?e.parentNode.removeChild(r):e.removeChild(r)):Yn.removeChild(r.stateNode));break;case 18:Yn!==null&&(co?(e=Yn,r=r.stateNode,e.nodeType===8?Kb(e.parentNode,r):e.nodeType===1&&Kb(e,r),g0(e)):Kb(Yn,r.stateNode));break;case 4:n=Yn,i=co,Yn=r.stateNode.containerInfo,co=!0,hl(e,t,r),Yn=n,co=i;break;case 0:case 11:case 14:case 15:if(!di&&(n=r.updateQueue,n!==null&&(n=n.lastEffect,n!==null))){i=n=n.next;do{var a=i,s=a.destroy;a=a.tag,s!==void 0&&(a&2||a&4)&&m4(r,t,s),i=i.next}while(i!==n)}hl(e,t,r);break;case 1:if(!di&&(cf(r,t),n=r.stateNode,typeof n.componentWillUnmount=="function"))try{n.props=r.memoizedProps,n.state=r.memoizedState,n.componentWillUnmount()}catch(f){cn(r,t,f)}hl(e,t,r);break;case 21:hl(e,t,r);break;case 22:r.mode&1?(di=(n=di)||r.memoizedState!==null,hl(e,t,r),di=n):hl(e,t,r);break;default:hl(e,t,r)}}function HE(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var r=e.stateNode;r===null&&(r=e.stateNode=new PV),t.forEach(function(n){var i=BV.bind(null,e,n);r.has(n)||(r.add(n),n.then(i,i))})}}function ao(e,t){var r=t.deletions;if(r!==null)for(var n=0;ni&&(i=s),n&=~a}if(n=i,n=pn()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*AV(n/1960))-n,10e?16:e,Al===null)var n=!1;else{if(e=Al,Al=null,xg=0,Rr&6)throw Error(gt(331));var i=Rr;for(Rr|=4,Tt=e.current;Tt!==null;){var a=Tt,s=a.child;if(Tt.flags&16){var f=a.deletions;if(f!==null){for(var d=0;dpn()-vS?Xu(e,0):mS|=r),Bi(e,t)}function VA(e,t){t===0&&(e.mode&1?(t=wm,wm<<=1,!(wm&130023424)&&(wm=4194304)):t=1);var r=ki();e=Xs(e,t),e!==null&&(tp(e,t,r),Bi(e,r))}function jV(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),VA(e,r)}function BV(e,t){var r=0;switch(e.tag){case 13:var n=e.stateNode,i=e.memoizedState;i!==null&&(r=i.retryLane);break;case 19:n=e.stateNode;break;default:throw Error(gt(314))}n!==null&&n.delete(t),VA(e,r)}var qA;qA=function(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps||Ni.current)Li=!0;else{if(!(e.lanes&r)&&!(t.flags&128))return Li=!1,kV(e,t,r);Li=!!(e.flags&131072)}else Li=!1,nn&&t.flags&1048576&&GR(t,dg,t.index);switch(t.lanes=0,t.tag){case 2:var n=t.type;bv(e,t),e=t.pendingProps;var i=Nf(t,pi.current);_f(t,r),i=uS(null,t,n,e,i,r);var a=cS();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,ji(n)?(a=!0,cg(t)):a=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,iS(t),i.updater=ty,t.stateNode=i,i._reactInternals=t,l4(t,n,e,r),t=f4(null,t,n,!0,a,r)):(t.tag=0,nn&&a&&Z6(t),xi(null,t,i,r),t=t.child),t;case 16:n=t.elementType;e:{switch(bv(e,t),e=t.pendingProps,i=n._init,n=i(n._payload),t.type=n,i=t.tag=zV(n),e=uo(n,e),i){case 0:t=c4(null,t,n,e,r);break e;case 1:t=jE(null,t,n,e,r);break e;case 11:t=LE(null,t,n,e,r);break e;case 14:t=NE(null,t,n,uo(n.type,e),r);break e}throw Error(gt(306,n,""))}return t;case 0:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:uo(n,i),c4(e,t,n,i,r);case 1:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:uo(n,i),jE(e,t,n,i,r);case 3:e:{if(CA(t),e===null)throw Error(gt(387));n=t.pendingProps,a=t.memoizedState,i=a.element,JR(e,t),mg(t,n,null,r);var s=t.memoizedState;if(n=s.element,a.isDehydrated)if(a={element:n,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=a,t.memoizedState=a,t.flags&256){i=zf(Error(gt(423)),t),t=BE(e,t,n,r,i);break e}else if(n!==i){i=zf(Error(gt(424)),t),t=BE(e,t,n,r,i);break e}else for(na=Bl(t.stateNode.containerInfo.firstChild),oa=t,nn=!0,fo=null,r=rA(t,null,n,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(jf(),n===i){t=Zs(e,t,r);break e}xi(e,t,n,r)}t=t.child}return t;case 5:return nA(t),e===null&&a4(t),n=t.type,i=t.pendingProps,a=e!==null?e.memoizedProps:null,s=i.children,e4(n,i)?s=null:a!==null&&e4(n,a)&&(t.flags|=32),TA(e,t),xi(e,t,s,r),t.child;case 6:return e===null&&a4(t),null;case 13:return PA(e,t,r);case 4:return aS(t,t.stateNode.containerInfo),n=t.pendingProps,e===null?t.child=Bf(t,null,n,r):xi(e,t,n,r),t.child;case 11:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:uo(n,i),LE(e,t,n,i,r);case 7:return xi(e,t,t.pendingProps,r),t.child;case 8:return xi(e,t,t.pendingProps.children,r),t.child;case 12:return xi(e,t,t.pendingProps.children,r),t.child;case 10:e:{if(n=t.type._context,i=t.pendingProps,a=t.memoizedProps,s=i.value,Yr(hg,n._currentValue),n._currentValue=s,a!==null)if(yo(a.value,s)){if(a.children===i.children&&!Ni.current){t=Zs(e,t,r);break e}}else for(a=t.child,a!==null&&(a.return=t);a!==null;){var f=a.dependencies;if(f!==null){s=a.child;for(var d=f.firstContext;d!==null;){if(d.context===n){if(a.tag===1){d=Vs(-1,r&-r),d.tag=2;var p=a.updateQueue;if(p!==null){p=p.shared;var y=p.pending;y===null?d.next=d:(d.next=y.next,y.next=d),p.pending=d}}a.lanes|=r,d=a.alternate,d!==null&&(d.lanes|=r),o4(a.return,r,t),f.lanes|=r;break}d=d.next}}else if(a.tag===10)s=a.type===t.type?null:a.child;else if(a.tag===18){if(s=a.return,s===null)throw Error(gt(341));s.lanes|=r,f=s.alternate,f!==null&&(f.lanes|=r),o4(s,r,t),s=a.sibling}else s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===t){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}xi(e,t,i.children,r),t=t.child}return t;case 9:return i=t.type,n=t.pendingProps.children,_f(t,r),i=Ba(i),n=n(i),t.flags|=1,xi(e,t,n,r),t.child;case 14:return n=t.type,i=uo(n,t.pendingProps),i=uo(n.type,i),NE(e,t,n,i,r);case 15:return EA(e,t,t.type,t.pendingProps,r);case 17:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:uo(n,i),bv(e,t),t.tag=1,ji(n)?(e=!0,cg(t)):e=!1,_f(t,r),eA(t,n,i),l4(t,n,i,r),f4(null,t,n,!0,e,r);case 19:return OA(e,t,r);case 22:return kA(e,t,r)}throw Error(gt(156,t.tag))};function WA(e,t){return yR(e,t)}function FV(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 Ia(e,t,r,n){return new FV(e,t,r,n)}function bS(e){return e=e.prototype,!(!e||!e.isReactComponent)}function zV(e){if(typeof e=="function")return bS(e)?1:0;if(e!=null){if(e=e.$$typeof,e===B6)return 11;if(e===F6)return 14}return 2}function Hl(e,t){var r=e.alternate;return r===null?(r=Ia(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 Sv(e,t,r,n,i,a){var s=2;if(n=e,typeof e=="function")bS(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case ef:return Zu(r.children,i,a,t);case j6:s=8,i|=8;break;case A_:return e=Ia(12,r,t,i|2),e.elementType=A_,e.lanes=a,e;case D_:return e=Ia(13,r,t,i),e.elementType=D_,e.lanes=a,e;case $_:return e=Ia(19,r,t,i),e.elementType=$_,e.lanes=a,e;case tR:return ay(r,i,a,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Q9:s=10;break e;case eR:s=9;break e;case B6:s=11;break e;case F6:s=14;break e;case _l:s=16,n=null;break e}throw Error(gt(130,e==null?e:typeof e,""))}return t=Ia(s,r,t,i),t.elementType=e,t.type=n,t.lanes=a,t}function Zu(e,t,r,n){return e=Ia(7,e,n,t),e.lanes=r,e}function ay(e,t,r,n){return e=Ia(22,e,n,t),e.elementType=tR,e.lanes=r,e.stateNode={isHidden:!1},e}function t2(e,t,r){return e=Ia(6,e,null,t),e.lanes=r,e}function r2(e,t,r){return t=Ia(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function UV(e,t,r,n,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Lb(0),this.expirationTimes=Lb(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Lb(0),this.identifierPrefix=n,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function xS(e,t,r,n,i,a,s,f,d){return e=new UV(e,t,r,f,d),t===1?(t=1,a===!0&&(t|=8)):t=0,a=Ia(3,null,null,t),e.current=a,a.stateNode=e,a.memoizedState={element:n,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},iS(a),e}function HV(e,t,r){var n=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(XA)}catch(e){console.error(e)}}XA(),G9.exports=ha;var ap=G9.exports;const Uu=Ci(ap);var ES,ZE=ap;ES=ZE.createRoot,ZE.hydrateRoot;/** * @remix-run/router v1.7.2 * * Copyright (c) Remix Software Inc. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */function P0(){return P0=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function kS(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function YV(){return Math.random().toString(36).substr(2,8)}function QE(e,t){return{usr:e.state,key:e.key,idx:t}}function S4(e,t,r,n){return r===void 0&&(r=null),P0({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Sd(t):t,{state:r,key:t&&t.key||n||YV()})}function Mg(e){let{pathname:t="/",search:r="",hash:n=""}=e;return r&&r!=="?"&&(t+=r.charAt(0)==="?"?r:"?"+r),n&&n!=="#"&&(t+=n.charAt(0)==="#"?n:"#"+n),t}function Sd(e){let t={};if(e){let r=e.indexOf("#");r>=0&&(t.hash=e.substr(r),e=e.substr(0,r));let n=e.indexOf("?");n>=0&&(t.search=e.substr(n),e=e.substr(0,n)),e&&(t.pathname=e)}return t}function XV(e,t,r,n){n===void 0&&(n={});let{window:i=document.defaultView,v5Compat:a=!1}=n,s=i.history,f=Dl.Pop,d=null,p=y();p==null&&(p=0,s.replaceState(P0({},s.state,{idx:p}),""));function y(){return(s.state||{idx:null}).idx}function w(){f=Dl.Pop;let O=y(),T=O==null?null:O-p;p=O,d&&d({action:f,location:C.location,delta:T})}function _(O,T){f=Dl.Push;let k=S4(C.location,O,T);r&&r(k,O),p=y()+1;let R=QE(k,p),$=C.createHref(k);try{s.pushState(R,"",$)}catch(L){if(L instanceof DOMException&&L.name==="DataCloneError")throw L;i.location.assign($)}a&&d&&d({action:f,location:C.location,delta:1})}function S(O,T){f=Dl.Replace;let k=S4(C.location,O,T);r&&r(k,O),p=y();let R=QE(k,p),$=C.createHref(k);s.replaceState(R,"",$),a&&d&&d({action:f,location:C.location,delta:0})}function M(O){let T=i.location.origin!=="null"?i.location.origin:i.location.href,k=typeof O=="string"?O:Mg(O);return jn(T,"No window.location.(origin|href) available to create URL for href: "+k),new URL(k,T)}let C={get action(){return f},get location(){return e(i,s)},listen(O){if(d)throw new Error("A history only accepts one active listener");return i.addEventListener(JE,w),d=O,()=>{i.removeEventListener(JE,w),d=null}},createHref(O){return t(i,O)},createURL:M,encodeLocation(O){let T=M(O);return{pathname:T.pathname,search:T.search,hash:T.hash}},push:_,replace:S,go(O){return s.go(O)}};return C}var ek;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(ek||(ek={}));function ZV(e,t,r){r===void 0&&(r="/");let n=typeof t=="string"?Sd(t):t,i=TS(n.pathname||"/",r);if(i==null)return null;let a=ZA(e);JV(a);let s=null;for(let f=0;s==null&&f{let d={relativePath:f===void 0?a.path||"":f,caseSensitive:a.caseSensitive===!0,childrenIndex:s,route:a};d.relativePath.startsWith("/")&&(jn(d.relativePath.startsWith(n),'Absolute route path "'+d.relativePath+'" nested under path '+('"'+n+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),d.relativePath=d.relativePath.slice(n.length));let p=Vl([n,d.relativePath]),y=r.concat(d);a.children&&a.children.length>0&&(jn(a.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+p+'".')),ZA(a.children,t,y,p)),!(a.path==null&&!a.index)&&t.push({path:p,score:aq(p,a.index),routesMeta:y})};return e.forEach((a,s)=>{var f;if(a.path===""||!((f=a.path)!=null&&f.includes("?")))i(a,s);else for(let d of JA(a.path))i(a,s,d)}),t}function JA(e){let t=e.split("/");if(t.length===0)return[];let[r,...n]=t,i=r.endsWith("?"),a=r.replace(/\?$/,"");if(n.length===0)return i?[a,""]:[a];let s=JA(n.join("/")),f=[];return f.push(...s.map(d=>d===""?a:[a,d].join("/"))),i&&f.push(...s),f.map(d=>e.startsWith("/")&&d===""?"/":d)}function JV(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:oq(t.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}const QV=/^:\w+$/,eq=3,tq=2,rq=1,nq=10,iq=-2,tk=e=>e==="*";function aq(e,t){let r=e.split("/"),n=r.length;return r.some(tk)&&(n+=iq),t&&(n+=tq),r.filter(i=>!tk(i)).reduce((i,a)=>i+(QV.test(a)?eq:a===""?rq:nq),n)}function oq(e,t){return e.length===t.length&&e.slice(0,-1).every((n,i)=>n===t[i])?e[e.length-1]-t[t.length-1]:0}function sq(e,t){let{routesMeta:r}=e,n={},i="/",a=[];for(let s=0;s{if(y==="*"){let _=f[w]||"";s=a.slice(0,a.length-_.length).replace(/(.)\/+$/,"$1")}return p[y]=fq(f[w]||"",y),p},{}),pathname:a,pathnameBase:s,pattern:e}}function uq(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!0),kS(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let n=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^$?{}|()[\]]/g,"\\$&").replace(/\/:(\w+)/g,(s,f)=>(n.push(f),"/([^\\/]+)"));return e.endsWith("*")?(n.push("*"),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),n]}function cq(e){try{return decodeURI(e)}catch(t){return kS(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function fq(e,t){try{return decodeURIComponent(e)}catch(r){return kS(!1,'The value for the URL param "'+t+'" will not be decoded because'+(' the string "'+e+'" is a malformed URL segment. This is probably')+(" due to a bad percent encoding ("+r+").")),e}}function TS(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=t.endsWith("/")?t.length-1:t.length,n=e.charAt(r);return n&&n!=="/"?null:e.slice(r)||"/"}function dq(e,t){t===void 0&&(t="/");let{pathname:r,search:n="",hash:i=""}=typeof e=="string"?Sd(e):e;return{pathname:r?r.startsWith("/")?r:hq(r,t):t,search:mq(n),hash:vq(i)}}function hq(e,t){let r=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(i=>{i===".."?r.length>1&&r.pop():i!=="."&&r.push(i)}),r.length>1?r.join("/"):"/"}function n2(e,t,r,n){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(n)+"]. Please separate it out to the ")+("`to."+r+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function CS(e){return e.filter((t,r)=>r===0||t.route.path&&t.route.path.length>0)}function PS(e,t,r,n){n===void 0&&(n=!1);let i;typeof e=="string"?i=Sd(e):(i=P0({},e),jn(!i.pathname||!i.pathname.includes("?"),n2("?","pathname","search",i)),jn(!i.pathname||!i.pathname.includes("#"),n2("#","pathname","hash",i)),jn(!i.search||!i.search.includes("#"),n2("#","search","hash",i)));let a=e===""||i.pathname==="",s=a?"/":i.pathname,f;if(n||s==null)f=r;else{let w=t.length-1;if(s.startsWith("..")){let _=s.split("/");for(;_[0]==="..";)_.shift(),w-=1;i.pathname=_.join("/")}f=w>=0?t[w]:"/"}let d=dq(i,f),p=s&&s!=="/"&&s.endsWith("/"),y=(a||s===".")&&r.endsWith("/");return!d.pathname.endsWith("/")&&(p||y)&&(d.pathname+="/"),d}const Vl=e=>e.join("/").replace(/\/\/+/g,"/"),pq=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),mq=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,vq=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function gq(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const QA=["post","put","patch","delete"];new Set(QA);const yq=["get",...QA];new Set(yq);/** * React Router v6.14.2 * * Copyright (c) Remix Software Inc. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */function Eg(){return Eg=Object.assign?Object.assign.bind():function(e){for(var t=1;td.pathnameBase)),s=X.useRef(!1);return rD(()=>{s.current=!0}),X.useCallback(function(d,p){if(p===void 0&&(p={}),!s.current)return;if(typeof d=="number"){r.go(d);return}let y=PS(d,JSON.parse(a),i,p.relative==="path");e==null&&t!=="/"&&(y.pathname=y.pathname==="/"?t:Vl([t,y.pathname])),(p.replace?r.replace:r.push)(y,p.state,p)},[t,r,a,i,e])}const xq=X.createContext(null);function _q(e){let t=X.useContext(ys).outlet;return t&&J(xq.Provider,{value:e,children:t})}function eTe(){let{matches:e}=X.useContext(ys),t=e[e.length-1];return t?t.params:{}}function RS(e,t){let{relative:r}=t===void 0?{}:t,{matches:n}=X.useContext(ys),{pathname:i}=za(),a=JSON.stringify(CS(n).map(s=>s.pathnameBase));return X.useMemo(()=>PS(e,JSON.parse(a),i,r==="path"),[e,a,i,r])}function tTe(e,t){return Sq(e,t)}function Sq(e,t,r){Md()||jn(!1);let{navigator:n}=X.useContext(wc),{matches:i}=X.useContext(ys),a=i[i.length-1],s=a?a.params:{};a&&a.pathname;let f=a?a.pathnameBase:"/";a&&a.route;let d=za(),p;if(t){var y;let C=typeof t=="string"?Sd(t):t;f==="/"||(y=C.pathname)!=null&&y.startsWith(f)||jn(!1),p=C}else p=d;let w=p.pathname||"/",_=f==="/"?w:w.slice(f.length)||"/",S=ZV(e,{pathname:_}),M=Cq(S&&S.map(C=>Object.assign({},C,{params:Object.assign({},s,C.params),pathname:Vl([f,n.encodeLocation?n.encodeLocation(C.pathname).pathname:C.pathname]),pathnameBase:C.pathnameBase==="/"?f:Vl([f,n.encodeLocation?n.encodeLocation(C.pathnameBase).pathname:C.pathnameBase])})),i,r);return t&&M?J(cy.Provider,{value:{location:Eg({pathname:"/",search:"",hash:"",state:null,key:"default"},p),navigationType:Dl.Pop},children:M}):M}function Mq(){let e=Aq(),t=gq(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),r=e instanceof Error?e.stack:null;return dt(If,{children:[J("h2",{children:"Unexpected Application Error!"}),J("h3",{style:{fontStyle:"italic"},children:t}),r?J("pre",{style:{padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"},children:r}):null,null]})}const Eq=J(Mq,{});class kq extends X.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,r){return r.location!==t.location||r.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error||r.error,location:r.location,revalidation:t.revalidation||r.revalidation}}componentDidCatch(t,r){console.error("React Router caught the following error during render",t,r)}render(){return this.state.error?J(ys.Provider,{value:this.props.routeContext,children:J(tD.Provider,{value:this.state.error,children:this.props.component})}):this.props.children}}function Tq(e){let{routeContext:t,match:r,children:n}=e,i=X.useContext(OS);return i&&i.static&&i.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=r.route.id),J(ys.Provider,{value:t,children:n})}function Cq(e,t,r){var n;if(t===void 0&&(t=[]),r===void 0&&(r=null),e==null){var i;if((i=r)!=null&&i.errors)e=r.matches;else return null}let a=e,s=(n=r)==null?void 0:n.errors;if(s!=null){let f=a.findIndex(d=>d.route.id&&(s==null?void 0:s[d.route.id]));f>=0||jn(!1),a=a.slice(0,Math.min(a.length,f+1))}return a.reduceRight((f,d,p)=>{let y=d.route.id?s==null?void 0:s[d.route.id]:null,w=null;r&&(w=d.route.errorElement||Eq);let _=t.concat(a.slice(0,p+1)),S=()=>{let M;return y?M=w:d.route.Component?M=X.createElement(d.route.Component,null):d.route.element?M=d.route.element:M=f,J(Tq,{match:d,routeContext:{outlet:f,matches:_,isDataRoute:r!=null},children:M})};return r&&(d.route.ErrorBoundary||d.route.errorElement||p===0)?J(kq,{location:r.location,revalidation:r.revalidation,component:w,error:y,children:S(),routeContext:{outlet:null,matches:_,isDataRoute:!0}}):S()},null)}var M4;(function(e){e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate"})(M4||(M4={}));var O0;(function(e){e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId"})(O0||(O0={}));function Pq(e){let t=X.useContext(OS);return t||jn(!1),t}function Oq(e){let t=X.useContext(eD);return t||jn(!1),t}function Rq(e){let t=X.useContext(ys);return t||jn(!1),t}function nD(e){let t=Rq(),r=t.matches[t.matches.length-1];return r.route.id||jn(!1),r.route.id}function Aq(){var e;let t=X.useContext(tD),r=Oq(O0.UseRouteError),n=nD(O0.UseRouteError);return t||((e=r.errors)==null?void 0:e[n])}function Dq(){let{router:e}=Pq(M4.UseNavigateStable),t=nD(O0.UseNavigateStable),r=X.useRef(!1);return rD(()=>{r.current=!0}),X.useCallback(function(i,a){a===void 0&&(a={}),r.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,Eg({fromRouteId:t},a)))},[e,t])}function $q(e){let{to:t,replace:r,state:n,relative:i}=e;Md()||jn(!1);let{matches:a}=X.useContext(ys),{pathname:s}=za(),f=cu(),d=PS(t,CS(a).map(y=>y.pathnameBase),s,i==="path"),p=JSON.stringify(d);return X.useEffect(()=>f(JSON.parse(p),{replace:r,state:n,relative:i}),[f,p,i,r,n]),null}function AS(e){return _q(e.context)}function Iq(e){let{basename:t="/",children:r=null,location:n,navigationType:i=Dl.Pop,navigator:a,static:s=!1}=e;Md()&&jn(!1);let f=t.replace(/^\/*/,"/"),d=X.useMemo(()=>({basename:f,navigator:a,static:s}),[f,a,s]);typeof n=="string"&&(n=Sd(n));let{pathname:p="/",search:y="",hash:w="",state:_=null,key:S="default"}=n,M=X.useMemo(()=>{let C=TS(p,f);return C==null?null:{location:{pathname:C,search:y,hash:w,state:_,key:S},navigationType:i}},[f,p,y,w,_,S,i]);return M==null?null:J(wc.Provider,{value:d,children:J(cy.Provider,{children:r,value:M})})}var rk;(function(e){e[e.pending=0]="pending",e[e.success=1]="success",e[e.error=2]="error"})(rk||(rk={}));new Promise(()=>{});/** * React Router DOM v6.14.2 * * Copyright (c) Remix Software Inc. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */function iD(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,a;for(a=0;a=0)&&(r[i]=e[i]);return r}function Lq(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function Nq(e,t){return e.button===0&&(!t||t==="_self")&&!Lq(e)}const jq=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset"],Bq=["aria-current","caseSensitive","className","end","style","to","children"],Fq="startTransition",nk=O_[Fq];function zq(e){let{basename:t,children:r,future:n,window:i}=e,a=X.useRef();a.current==null&&(a.current=GV({window:i,v5Compat:!0}));let s=a.current,[f,d]=X.useState({action:s.action,location:s.location}),{v7_startTransition:p}=n||{},y=X.useCallback(w=>{p&&nk?nk(()=>d(w)):d(w)},[d,p]);return X.useLayoutEffect(()=>s.listen(y),[s,y]),J(Iq,{basename:t,children:r,location:f.location,navigationType:f.action,navigator:s})}const Uq=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",Hq=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,tu=X.forwardRef(function(t,r){let{onClick:n,relative:i,reloadDocument:a,replace:s,state:f,target:d,to:p,preventScrollReset:y}=t,w=iD(t,jq),{basename:_}=X.useContext(wc),S,M=!1;if(typeof p=="string"&&Hq.test(p)&&(S=p,Uq))try{let k=new URL(window.location.href),R=p.startsWith("//")?new URL(k.protocol+p):new URL(p),$=TS(R.pathname,_);R.origin===k.origin&&$!=null?p=$+R.search+R.hash:M=!0}catch{}let C=wq(p,{relative:i}),O=Vq(p,{replace:s,state:f,target:d,preventScrollReset:y,relative:i});function T(k){n&&n(k),k.defaultPrevented||O(k)}return J("a",{...w,href:S||C,onClick:M||a?n:T,ref:r,target:d})}),DS=X.forwardRef(function(t,r){let{"aria-current":n="page",caseSensitive:i=!1,className:a="",end:s=!1,style:f,to:d,children:p}=t,y=iD(t,Bq),w=RS(d,{relative:y.relative}),_=za(),S=X.useContext(eD),{navigator:M}=X.useContext(wc),C=M.encodeLocation?M.encodeLocation(w).pathname:w.pathname,O=_.pathname,T=S&&S.navigation&&S.navigation.location?S.navigation.location.pathname:null;i||(O=O.toLowerCase(),T=T?T.toLowerCase():null,C=C.toLowerCase());let k=O===C||!s&&O.startsWith(C)&&O.charAt(C.length)==="/",R=T!=null&&(T===C||!s&&T.startsWith(C)&&T.charAt(C.length)==="/"),$=k?n:void 0,L;typeof a=="function"?L=a({isActive:k,isPending:R}):L=[a,k?"active":null,R?"pending":null].filter(Boolean).join(" ");let j=typeof f=="function"?f({isActive:k,isPending:R}):f;return J(tu,{...y,"aria-current":$,className:L,ref:r,style:j,to:d,children:typeof p=="function"?p({isActive:k,isPending:R}):p})});var ik;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher"})(ik||(ik={}));var ak;(function(e){e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(ak||(ak={}));function Vq(e,t){let{target:r,replace:n,state:i,preventScrollReset:a,relative:s}=t===void 0?{}:t,f=cu(),d=za(),p=RS(e,{relative:s});return X.useCallback(y=>{if(Nq(y,r)){y.preventDefault();let w=n!==void 0?n:Mg(d)===Mg(p);f(e,{replace:w,state:i,preventScrollReset:a,relative:s})}},[d,f,p,n,i,r,e,a,s])}function aD(){throw new Error("setTimeout has not been defined")}function oD(){throw new Error("clearTimeout has not been defined")}var wl=aD,bl=oD;typeof globalThis.setTimeout=="function"&&(wl=setTimeout);typeof globalThis.clearTimeout=="function"&&(bl=clearTimeout);function sD(e){if(wl===setTimeout)return setTimeout(e,0);if((wl===aD||!wl)&&setTimeout)return wl=setTimeout,setTimeout(e,0);try{return wl(e,0)}catch{try{return wl.call(null,e,0)}catch{return wl.call(this,e,0)}}}function qq(e){if(bl===clearTimeout)return clearTimeout(e);if((bl===oD||!bl)&&clearTimeout)return bl=clearTimeout,clearTimeout(e);try{return bl(e)}catch{try{return bl.call(null,e)}catch{return bl.call(this,e)}}}var zs=[],Mf=!1,Hu,Mv=-1;function Wq(){!Mf||!Hu||(Mf=!1,Hu.length?zs=Hu.concat(zs):Mv=-1,zs.length&&lD())}function lD(){if(!Mf){var e=sD(Wq);Mf=!0;for(var t=zs.length;t;){for(Hu=zs,zs=[];++Mv1)for(var r=1;r1?t-1:0),n=1;n3?t.i-4:t.i:Array.isArray(e)?1:$S(e)?2:IS(e)?3:0}function Ef(e,t){return Ed(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function yW(e,t){return Ed(e)===2?e.get(t):e[t]}function cD(e,t,r){var n=Ed(e);n===2?e.set(t,r):n===3?e.add(r):e[t]=r}function fD(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function $S(e){return MW&&e instanceof Map}function IS(e){return EW&&e instanceof Set}function Du(e){return e.o||e.t}function LS(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=hD(e);delete t[rn];for(var r=kf(t),n=0;n1&&(e.set=e.add=e.clear=e.delete=wW),Object.freeze(e),t&&oc(e,function(r,n){return NS(n,!0)},!0)),e}function wW(){po(2)}function jS(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function es(e){var t=C4[e];return t||po(18,e),t}function bW(e,t){C4[e]||(C4[e]=t)}function E4(){return R0}function i2(e,t){t&&(es("Patches"),e.u=[],e.s=[],e.v=t)}function kg(e){k4(e),e.p.forEach(xW),e.p=null}function k4(e){e===R0&&(R0=e.l)}function ok(e){return R0={p:[],l:R0,h:e,m:!0,_:0}}function xW(e){var t=e[rn];t.i===0||t.i===1?t.j():t.g=!0}function a2(e,t){t._=t.p.length;var r=t.p[0],n=e!==void 0&&e!==r;return t.h.O||es("ES5").S(t,e,n),n?(r[rn].P&&(kg(t),po(4)),Js(e)&&(e=Tg(t,e),t.l||Cg(t,e)),t.u&&es("Patches").M(r[rn].t,e,t.u,t.s)):e=Tg(t,r,[]),kg(t),t.u&&t.v(t.u,t.s),e!==dD?e:void 0}function Tg(e,t,r){if(jS(t))return t;var n=t[rn];if(!n)return oc(t,function(f,d){return sk(e,n,t,f,d,r)},!0),t;if(n.A!==e)return t;if(!n.P)return Cg(e,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var i=n.i===4||n.i===5?n.o=LS(n.k):n.o,a=i,s=!1;n.i===3&&(a=new Set(i),i.clear(),s=!0),oc(a,function(f,d){return sk(e,n,i,f,d,r,s)}),Cg(e,i,!1),r&&e.u&&es("Patches").N(n,r,e.u,e.s)}return n.o}function sk(e,t,r,n,i,a,s){if(ru(i)){var f=Tg(e,i,a&&t&&t.i!==3&&!Ef(t.R,n)?a.concat(n):void 0);if(cD(r,n,f),!ru(f))return;e.m=!1}else s&&r.add(i);if(Js(i)&&!jS(i)){if(!e.h.D&&e._<1)return;Tg(e,i),t&&t.A.l||Cg(e,i)}}function Cg(e,t,r){r===void 0&&(r=!1),!e.l&&e.h.D&&e.m&&NS(t,r)}function o2(e,t){var r=e[rn];return(r?Du(r):e)[t]}function lk(e,t){if(t in e)for(var r=Object.getPrototypeOf(e);r;){var n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=Object.getPrototypeOf(r)}}function Cl(e){e.P||(e.P=!0,e.l&&Cl(e.l))}function s2(e){e.o||(e.o=LS(e.t))}function T4(e,t,r){var n=$S(t)?es("MapSet").F(t,r):IS(t)?es("MapSet").T(t,r):e.O?function(i,a){var s=Array.isArray(i),f={i:s?1:0,A:a?a.A:E4(),P:!1,I:!1,R:{},l:a,t:i,k:null,o:null,j:null,C:!1},d=f,p=A0;s&&(d=[f],p=Fh);var y=Proxy.revocable(d,p),w=y.revoke,_=y.proxy;return f.k=_,f.j=w,_}(t,r):es("ES5").J(t,r);return(r?r.A:E4()).p.push(n),n}function _W(e){return ru(e)||po(22,e),function t(r){if(!Js(r))return r;var n,i=r[rn],a=Ed(r);if(i){if(!i.P&&(i.i<4||!es("ES5").K(i)))return i.t;i.I=!0,n=uk(r,a),i.I=!1}else n=uk(r,a);return oc(n,function(s,f){i&&yW(i.t,s)===f||cD(n,s,t(f))}),a===3?new Set(n):n}(e)}function uk(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return LS(e)}function SW(){function e(a,s){var f=i[a];return f?f.enumerable=s:i[a]=f={configurable:!0,enumerable:s,get:function(){var d=this[rn];return A0.get(d,a)},set:function(d){var p=this[rn];A0.set(p,a,d)}},f}function t(a){for(var s=a.length-1;s>=0;s--){var f=a[s][rn];if(!f.P)switch(f.i){case 5:n(f)&&Cl(f);break;case 4:r(f)&&Cl(f)}}}function r(a){for(var s=a.t,f=a.k,d=kf(f),p=d.length-1;p>=0;p--){var y=d[p];if(y!==rn){var w=s[y];if(w===void 0&&!Ef(s,y))return!0;var _=f[y],S=_&&_[rn];if(S?S.t!==w:!fD(_,w))return!0}}var M=!!s[rn];return d.length!==kf(s).length+(M?0:1)}function n(a){var s=a.k;if(s.length!==a.t.length)return!0;var f=Object.getOwnPropertyDescriptor(s,s.length-1);if(f&&!f.get)return!0;for(var d=0;d1?T-1:0),R=1;R1?y-1:0),_=1;_=0;i--){var a=n[i];if(a.path.length===0&&a.op==="replace"){r=a.value;break}}i>-1&&(n=n.slice(i+1));var s=es("Patches").$;return ru(r)?s(r,n):this.produce(r,function(f){return s(f,n)})},e}(),ca=new TW,pD=ca.produce;ca.produceWithPatches.bind(ca);ca.setAutoFreeze.bind(ca);ca.setUseProxies.bind(ca);ca.applyPatches.bind(ca);ca.createDraft.bind(ca);ca.finishDraft.bind(ca);function Fi(e){"@babel/helpers - typeof";return Fi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Fi(e)}function CW(e,t){if(Fi(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Fi(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function mD(e){var t=CW(e,"string");return Fi(t)=="symbol"?t:t+""}function Mi(e,t,r){return(t=mD(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function hk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Ft(e){for(var t=1;t"u"&&(r=t,t=void 0),typeof r<"u"){if(typeof r!="function")throw new Error(ci(1));return r(vD)(e,t)}if(typeof e!="function")throw new Error(ci(2));var i=e,a=t,s=[],f=s,d=!1;function p(){f===s&&(f=s.slice())}function y(){if(d)throw new Error(ci(3));return a}function w(C){if(typeof C!="function")throw new Error(ci(4));if(d)throw new Error(ci(5));var O=!0;return p(),f.push(C),function(){if(O){if(d)throw new Error(ci(6));O=!1,p();var k=f.indexOf(C);f.splice(k,1),s=null}}}function _(C){if(!PW(C))throw new Error(ci(7));if(typeof C.type>"u")throw new Error(ci(8));if(d)throw new Error(ci(9));try{d=!0,a=i(a,C)}finally{d=!1}for(var O=s=f,T=0;T"u")throw new Error(ci(12));if(typeof r(void 0,{type:Pg.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(ci(13))})}function RW(e){for(var t=Object.keys(e),r={},n=0;n"u")throw p&&p.type,new Error(ci(14));w[S]=O,y=y||O!==C}return y=y||a.length!==Object.keys(d).length,y?w:d}}function Og(){for(var e=arguments.length,t=new Array(e),r=0;r0&&a[a.length-1])&&(p[0]===6||p[0]===2)){r=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]t=>{const r=iK.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),bs=e=>(e=e.toLowerCase(),t=>fy(t)===e),dy=e=>t=>typeof t===e,{isArray:kd}=Array,D0=dy("undefined");function aK(e){return e!==null&&!D0(e)&&e.constructor!==null&&!D0(e.constructor)&&Na(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const _D=bs("ArrayBuffer");function oK(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&_D(e.buffer),t}const sK=dy("string"),Na=dy("function"),SD=dy("number"),hy=e=>e!==null&&typeof e=="object",lK=e=>e===!0||e===!1,Ev=e=>{if(fy(e)!=="object")return!1;const t=zS(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},uK=bs("Date"),cK=bs("File"),fK=bs("Blob"),dK=bs("FileList"),hK=e=>hy(e)&&Na(e.pipe),pK=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Na(e.append)&&((t=fy(e))==="formdata"||t==="object"&&Na(e.toString)&&e.toString()==="[object FormData]"))},mK=bs("URLSearchParams"),vK=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function op(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let n,i;if(typeof e!="object"&&(e=[e]),kd(e))for(n=0,i=e.length;n0;)if(i=r[n],t===i.toLowerCase())return i;return null}const ED=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:globalThis,kD=e=>!D0(e)&&e!==ED;function O4(){const{caseless:e}=kD(this)&&this||{},t={},r=(n,i)=>{const a=e&&MD(t,i)||i;Ev(t[a])&&Ev(n)?t[a]=O4(t[a],n):Ev(n)?t[a]=O4({},n):kd(n)?t[a]=n.slice():t[a]=n};for(let n=0,i=arguments.length;n(op(t,(i,a)=>{r&&Na(i)?e[a]=xD(i,r):e[a]=i},{allOwnKeys:n}),e),yK=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),wK=(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},bK=(e,t,r,n)=>{let i,a,s;const f={};if(t=t||{},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),a=i.length;a-- >0;)s=i[a],(!n||n(s,e,t))&&!f[s]&&(t[s]=e[s],f[s]=!0);e=r!==!1&&zS(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},xK=(e,t,r)=>{e=String(e),(r===void 0||r>e.length)&&(r=e.length),r-=t.length;const n=e.indexOf(t,r);return n!==-1&&n===r},_K=e=>{if(!e)return null;if(kd(e))return e;let t=e.length;if(!SD(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},SK=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&zS(Uint8Array)),MK=(e,t)=>{const n=(e&&e[Symbol.iterator]).call(e);let i;for(;(i=n.next())&&!i.done;){const a=i.value;t.call(e,a[0],a[1])}},EK=(e,t)=>{let r;const n=[];for(;(r=e.exec(t))!==null;)n.push(r);return n},kK=bs("HTMLFormElement"),TK=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,i){return n.toUpperCase()+i}),bk=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),CK=bs("RegExp"),TD=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),n={};op(r,(i,a)=>{let s;(s=t(i,a,e))!==!1&&(n[a]=s||i)}),Object.defineProperties(e,n)},PK=e=>{TD(e,(t,r)=>{if(Na(e)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=e[r];if(Na(n)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},OK=(e,t)=>{const r={},n=i=>{i.forEach(a=>{r[a]=!0})};return kd(e)?n(e):n(String(e).split(t)),r},RK=()=>{},AK=(e,t)=>(e=+e,Number.isFinite(e)?e:t),f2="abcdefghijklmnopqrstuvwxyz",xk="0123456789",CD={DIGIT:xk,ALPHA:f2,ALPHA_DIGIT:f2+f2.toUpperCase()+xk},DK=(e=16,t=CD.ALPHA_DIGIT)=>{let r="";const{length:n}=t;for(;e--;)r+=t[Math.random()*n|0];return r};function $K(e){return!!(e&&Na(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const IK=e=>{const t=new Array(10),r=(n,i)=>{if(hy(n)){if(t.indexOf(n)>=0)return;if(!("toJSON"in n)){t[i]=n;const a=kd(n)?[]:{};return op(n,(s,f)=>{const d=r(s,i+1);!D0(d)&&(a[f]=d)}),t[i]=void 0,a}}return n};return r(e,0)},LK=bs("AsyncFunction"),NK=e=>e&&(hy(e)||Na(e))&&Na(e.then)&&Na(e.catch),ht={isArray:kd,isArrayBuffer:_D,isBuffer:aK,isFormData:pK,isArrayBufferView:oK,isString:sK,isNumber:SD,isBoolean:lK,isObject:hy,isPlainObject:Ev,isUndefined:D0,isDate:uK,isFile:cK,isBlob:fK,isRegExp:CK,isFunction:Na,isStream:hK,isURLSearchParams:mK,isTypedArray:SK,isFileList:dK,forEach:op,merge:O4,extend:gK,trim:vK,stripBOM:yK,inherits:wK,toFlatObject:bK,kindOf:fy,kindOfTest:bs,endsWith:xK,toArray:_K,forEachEntry:MK,matchAll:EK,isHTMLForm:kK,hasOwnProperty:bk,hasOwnProp:bk,reduceDescriptors:TD,freezeMethods:PK,toObjectSet:OK,toCamelCase:TK,noop:RK,toFiniteNumber:AK,findKey:MD,global:ED,isContextDefined:kD,ALPHABET:CD,generateString:DK,isSpecCompliantForm:$K,toJSONObject:IK,isAsyncFn:LK,isThenable:NK};var qo=[],Ca=[],jK=typeof Uint8Array<"u"?Uint8Array:Array,US=!1;function PD(){US=!0;for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",t=0,r=e.length;t0)throw new Error("Invalid string. Length must be a multiple of 4");a=e[f-2]==="="?2:e[f-1]==="="?1:0,s=new jK(f*3/4-a),n=a>0?f-4:f;var d=0;for(t=0,r=0;t>16&255,s[d++]=i>>8&255,s[d++]=i&255;return a===2?(i=Ca[e.charCodeAt(t)]<<2|Ca[e.charCodeAt(t+1)]>>4,s[d++]=i&255):a===1&&(i=Ca[e.charCodeAt(t)]<<10|Ca[e.charCodeAt(t+1)]<<4|Ca[e.charCodeAt(t+2)]>>2,s[d++]=i>>8&255,s[d++]=i&255),s}function FK(e){return qo[e>>18&63]+qo[e>>12&63]+qo[e>>6&63]+qo[e&63]}function zK(e,t,r){for(var n,i=[],a=t;ad?d:f+s));return n===1?(t=e[r-1],i+=qo[t>>2],i+=qo[t<<4&63],i+="=="):n===2&&(t=(e[r-2]<<8)+e[r-1],i+=qo[t>>10],i+=qo[t>>4&63],i+=qo[t<<2&63],i+="="),a.push(i),a.join("")}function py(e,t,r,n,i){var a,s,f=i*8-n-1,d=(1<>1,y=-7,w=r?i-1:0,_=r?-1:1,S=e[t+w];for(w+=_,a=S&(1<<-y)-1,S>>=-y,y+=f;y>0;a=a*256+e[t+w],w+=_,y-=8);for(s=a&(1<<-y)-1,a>>=-y,y+=n;y>0;s=s*256+e[t+w],w+=_,y-=8);if(a===0)a=1-p;else{if(a===d)return s?NaN:(S?-1:1)*(1/0);s=s+Math.pow(2,n),a=a-p}return(S?-1:1)*s*Math.pow(2,a-n)}function OD(e,t,r,n,i,a){var s,f,d,p=a*8-i-1,y=(1<>1,_=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,S=n?0:a-1,M=n?1:-1,C=t<0||t===0&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(f=isNaN(t)?1:0,s=y):(s=Math.floor(Math.log(t)/Math.LN2),t*(d=Math.pow(2,-s))<1&&(s--,d*=2),s+w>=1?t+=_/d:t+=_*Math.pow(2,1-w),t*d>=2&&(s++,d/=2),s+w>=y?(f=0,s=y):s+w>=1?(f=(t*d-1)*Math.pow(2,i),s=s+w):(f=t*Math.pow(2,w-1)*Math.pow(2,i),s=0));i>=8;e[r+S]=f&255,S+=M,f/=256,i-=8);for(s=s<0;e[r+S]=s&255,S+=M,s/=256,p-=8);e[r+S-M]|=C*128}var UK={}.toString,RD=Array.isArray||function(e){return UK.call(e)=="[object Array]"};/*! * The buffer module from node.js, for the browser. * * @author Feross Aboukhadijeh * @license MIT */var AD=50;rt.TYPED_ARRAY_SUPPORT=globalThis.TYPED_ARRAY_SUPPORT!==void 0?globalThis.TYPED_ARRAY_SUPPORT:!0;var HK=Rg();function Rg(){return rt.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function Us(e,t){if(Rg()=Rg())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+Rg().toString(16)+" bytes");return e|0}function GK(e){return+e!=e&&(e=0),rt.alloc(+e)}rt.isBuffer=HD;function cs(e){return!!(e!=null&&e._isBuffer)}rt.compare=function(t,r){if(!cs(t)||!cs(r))throw new TypeError("Arguments must be Buffers");if(t===r)return 0;for(var n=t.length,i=r.length,a=0,s=Math.min(n,i);a>>1;case"base64":return UD(e).length;default:if(n)return Ag(e).length;t=(""+t).toLowerCase(),n=!0}}rt.byteLength=ID;function YK(e,t,r){var n=!1;if((t===void 0||t<0)&&(t=0),t>this.length||((r===void 0||r>this.length)&&(r=this.length),r<=0)||(r>>>=0,t>>>=0,r<=t))return"";for(e||(e="utf8");;)switch(e){case"hex":return aG(this,t,r);case"utf8":case"utf-8":return jD(this,t,r);case"ascii":return nG(this,t,r);case"latin1":case"binary":return iG(this,t,r);case"base64":return tG(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return oG(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}rt.prototype._isBuffer=!0;function Vu(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}rt.prototype.swap16=function(){var t=this.length;if(t%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var r=0;r0&&(t=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(t+=" ... ")),""};rt.prototype.compare=function(t,r,n,i,a){if(!cs(t))throw new TypeError("Argument must be a Buffer");if(r===void 0&&(r=0),n===void 0&&(n=t?t.length:0),i===void 0&&(i=0),a===void 0&&(a=this.length),r<0||n>t.length||i<0||a>this.length)throw new RangeError("out of range index");if(i>=a&&r>=n)return 0;if(i>=a)return-1;if(r>=n)return 1;if(r>>>=0,n>>>=0,i>>>=0,a>>>=0,this===t)return 0;for(var s=a-i,f=n-r,d=Math.min(s,f),p=this.slice(i,a),y=t.slice(r,n),w=0;w2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=i?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(i)return-1;r=e.length-1}else if(r<0)if(i)r=0;else return-1;if(typeof t=="string"&&(t=rt.from(t,n)),cs(t))return t.length===0?-1:Sk(e,t,r,n,i);if(typeof t=="number")return t=t&255,rt.TYPED_ARRAY_SUPPORT&&typeof Uint8Array.prototype.indexOf=="function"?i?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):Sk(e,[t],r,n,i);throw new TypeError("val must be string, number or Buffer")}function Sk(e,t,r,n,i){var a=1,s=e.length,f=t.length;if(n!==void 0&&(n=String(n).toLowerCase(),n==="ucs2"||n==="ucs-2"||n==="utf16le"||n==="utf-16le")){if(e.length<2||t.length<2)return-1;a=2,s/=2,f/=2,r/=2}function d(S,M){return a===1?S[M]:S.readUInt16BE(M*a)}var p;if(i){var y=-1;for(p=r;ps&&(r=s-f),p=r;p>=0;p--){for(var w=!0,_=0;_i&&(n=i)):n=i;var a=t.length;if(a%2!==0)throw new TypeError("Invalid hex string");n>a/2&&(n=a/2);for(var s=0;sa)&&(n=a),t.length>0&&(n<0||r<0)||r>this.length)throw new RangeError("Attempt to write outside buffer bounds");i||(i="utf8");for(var s=!1;;)switch(i){case"hex":return XK(this,t,r,n);case"utf8":case"utf-8":return ZK(this,t,r,n);case"ascii":return ND(this,t,r,n);case"latin1":case"binary":return JK(this,t,r,n);case"base64":return QK(this,t,r,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return eG(this,t,r,n);default:if(s)throw new TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase(),s=!0}};rt.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function tG(e,t,r){return t===0&&r===e.length?_k(e):_k(e.slice(t,r))}function jD(e,t,r){r=Math.min(e.length,r);for(var n=[],i=t;i239?4:a>223?3:a>191?2:1;if(i+f<=r){var d,p,y,w;switch(f){case 1:a<128&&(s=a);break;case 2:d=e[i+1],(d&192)===128&&(w=(a&31)<<6|d&63,w>127&&(s=w));break;case 3:d=e[i+1],p=e[i+2],(d&192)===128&&(p&192)===128&&(w=(a&15)<<12|(d&63)<<6|p&63,w>2047&&(w<55296||w>57343)&&(s=w));break;case 4:d=e[i+1],p=e[i+2],y=e[i+3],(d&192)===128&&(p&192)===128&&(y&192)===128&&(w=(a&15)<<18|(d&63)<<12|(p&63)<<6|y&63,w>65535&&w<1114112&&(s=w))}}s===null?(s=65533,f=1):s>65535&&(s-=65536,n.push(s>>>10&1023|55296),s=56320|s&1023),n.push(s),i+=f}return rG(n)}var Mk=4096;function rG(e){var t=e.length;if(t<=Mk)return String.fromCharCode.apply(String,e);for(var r="",n=0;nn)&&(r=n);for(var i="",a=t;an&&(t=n),r<0?(r+=n,r<0&&(r=0)):r>n&&(r=n),rr)throw new RangeError("Trying to access beyond buffer length")}rt.prototype.readUIntLE=function(t,r,n){t=t|0,r=r|0,n||zn(t,r,this.length);for(var i=this[t],a=1,s=0;++s0&&(a*=256);)i+=this[t+--r]*a;return i};rt.prototype.readUInt8=function(t,r){return r||zn(t,1,this.length),this[t]};rt.prototype.readUInt16LE=function(t,r){return r||zn(t,2,this.length),this[t]|this[t+1]<<8};rt.prototype.readUInt16BE=function(t,r){return r||zn(t,2,this.length),this[t]<<8|this[t+1]};rt.prototype.readUInt32LE=function(t,r){return r||zn(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+this[t+3]*16777216};rt.prototype.readUInt32BE=function(t,r){return r||zn(t,4,this.length),this[t]*16777216+(this[t+1]<<16|this[t+2]<<8|this[t+3])};rt.prototype.readIntLE=function(t,r,n){t=t|0,r=r|0,n||zn(t,r,this.length);for(var i=this[t],a=1,s=0;++s=a&&(i-=Math.pow(2,8*r)),i};rt.prototype.readIntBE=function(t,r,n){t=t|0,r=r|0,n||zn(t,r,this.length);for(var i=r,a=1,s=this[t+--i];i>0&&(a*=256);)s+=this[t+--i]*a;return a*=128,s>=a&&(s-=Math.pow(2,8*r)),s};rt.prototype.readInt8=function(t,r){return r||zn(t,1,this.length),this[t]&128?(255-this[t]+1)*-1:this[t]};rt.prototype.readInt16LE=function(t,r){r||zn(t,2,this.length);var n=this[t]|this[t+1]<<8;return n&32768?n|4294901760:n};rt.prototype.readInt16BE=function(t,r){r||zn(t,2,this.length);var n=this[t+1]|this[t]<<8;return n&32768?n|4294901760:n};rt.prototype.readInt32LE=function(t,r){return r||zn(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24};rt.prototype.readInt32BE=function(t,r){return r||zn(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]};rt.prototype.readFloatLE=function(t,r){return r||zn(t,4,this.length),py(this,t,!0,23,4)};rt.prototype.readFloatBE=function(t,r){return r||zn(t,4,this.length),py(this,t,!1,23,4)};rt.prototype.readDoubleLE=function(t,r){return r||zn(t,8,this.length),py(this,t,!0,52,8)};rt.prototype.readDoubleBE=function(t,r){return r||zn(t,8,this.length),py(this,t,!1,52,8)};function Wi(e,t,r,n,i,a){if(!cs(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw new RangeError("Index out of range")}rt.prototype.writeUIntLE=function(t,r,n,i){if(t=+t,r=r|0,n=n|0,!i){var a=Math.pow(2,8*n)-1;Wi(this,t,r,n,a,0)}var s=1,f=0;for(this[r]=t&255;++f=0&&(f*=256);)this[r+s]=t/f&255;return r+n};rt.prototype.writeUInt8=function(t,r,n){return t=+t,r=r|0,n||Wi(this,t,r,1,255,0),rt.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[r]=t&255,r+1};function my(e,t,r,n){t<0&&(t=65535+t+1);for(var i=0,a=Math.min(e.length-r,2);i>>(n?i:1-i)*8}rt.prototype.writeUInt16LE=function(t,r,n){return t=+t,r=r|0,n||Wi(this,t,r,2,65535,0),rt.TYPED_ARRAY_SUPPORT?(this[r]=t&255,this[r+1]=t>>>8):my(this,t,r,!0),r+2};rt.prototype.writeUInt16BE=function(t,r,n){return t=+t,r=r|0,n||Wi(this,t,r,2,65535,0),rt.TYPED_ARRAY_SUPPORT?(this[r]=t>>>8,this[r+1]=t&255):my(this,t,r,!1),r+2};function vy(e,t,r,n){t<0&&(t=4294967295+t+1);for(var i=0,a=Math.min(e.length-r,4);i>>(n?i:3-i)*8&255}rt.prototype.writeUInt32LE=function(t,r,n){return t=+t,r=r|0,n||Wi(this,t,r,4,4294967295,0),rt.TYPED_ARRAY_SUPPORT?(this[r+3]=t>>>24,this[r+2]=t>>>16,this[r+1]=t>>>8,this[r]=t&255):vy(this,t,r,!0),r+4};rt.prototype.writeUInt32BE=function(t,r,n){return t=+t,r=r|0,n||Wi(this,t,r,4,4294967295,0),rt.TYPED_ARRAY_SUPPORT?(this[r]=t>>>24,this[r+1]=t>>>16,this[r+2]=t>>>8,this[r+3]=t&255):vy(this,t,r,!1),r+4};rt.prototype.writeIntLE=function(t,r,n,i){if(t=+t,r=r|0,!i){var a=Math.pow(2,8*n-1);Wi(this,t,r,n,a-1,-a)}var s=0,f=1,d=0;for(this[r]=t&255;++s>0)-d&255;return r+n};rt.prototype.writeIntBE=function(t,r,n,i){if(t=+t,r=r|0,!i){var a=Math.pow(2,8*n-1);Wi(this,t,r,n,a-1,-a)}var s=n-1,f=1,d=0;for(this[r+s]=t&255;--s>=0&&(f*=256);)t<0&&d===0&&this[r+s+1]!==0&&(d=1),this[r+s]=(t/f>>0)-d&255;return r+n};rt.prototype.writeInt8=function(t,r,n){return t=+t,r=r|0,n||Wi(this,t,r,1,127,-128),rt.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[r]=t&255,r+1};rt.prototype.writeInt16LE=function(t,r,n){return t=+t,r=r|0,n||Wi(this,t,r,2,32767,-32768),rt.TYPED_ARRAY_SUPPORT?(this[r]=t&255,this[r+1]=t>>>8):my(this,t,r,!0),r+2};rt.prototype.writeInt16BE=function(t,r,n){return t=+t,r=r|0,n||Wi(this,t,r,2,32767,-32768),rt.TYPED_ARRAY_SUPPORT?(this[r]=t>>>8,this[r+1]=t&255):my(this,t,r,!1),r+2};rt.prototype.writeInt32LE=function(t,r,n){return t=+t,r=r|0,n||Wi(this,t,r,4,2147483647,-2147483648),rt.TYPED_ARRAY_SUPPORT?(this[r]=t&255,this[r+1]=t>>>8,this[r+2]=t>>>16,this[r+3]=t>>>24):vy(this,t,r,!0),r+4};rt.prototype.writeInt32BE=function(t,r,n){return t=+t,r=r|0,n||Wi(this,t,r,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),rt.TYPED_ARRAY_SUPPORT?(this[r]=t>>>24,this[r+1]=t>>>16,this[r+2]=t>>>8,this[r+3]=t&255):vy(this,t,r,!1),r+4};function BD(e,t,r,n,i,a){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function FD(e,t,r,n,i){return i||BD(e,t,r,4),OD(e,t,r,n,23,4),r+4}rt.prototype.writeFloatLE=function(t,r,n){return FD(this,t,r,!0,n)};rt.prototype.writeFloatBE=function(t,r,n){return FD(this,t,r,!1,n)};function zD(e,t,r,n,i){return i||BD(e,t,r,8),OD(e,t,r,n,52,8),r+8}rt.prototype.writeDoubleLE=function(t,r,n){return zD(this,t,r,!0,n)};rt.prototype.writeDoubleBE=function(t,r,n){return zD(this,t,r,!1,n)};rt.prototype.copy=function(t,r,n,i){if(n||(n=0),!i&&i!==0&&(i=this.length),r>=t.length&&(r=t.length),r||(r=0),i>0&&i=this.length)throw new RangeError("sourceStart out of bounds");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),t.length-r=0;--s)t[s+r]=this[s+n];else if(a<1e3||!rt.TYPED_ARRAY_SUPPORT)for(s=0;s>>0,n=n===void 0?this.length:n>>>0,t||(t=0);var s;if(typeof t=="number")for(s=r;s55295&&r<57344){if(!i){if(r>56319){(t-=3)>-1&&a.push(239,191,189);continue}else if(s+1===n){(t-=3)>-1&&a.push(239,191,189);continue}i=r;continue}if(r<56320){(t-=3)>-1&&a.push(239,191,189),i=r;continue}r=(i-55296<<10|r-56320)+65536}else i&&(t-=3)>-1&&a.push(239,191,189);if(i=null,r<128){if((t-=1)<0)break;a.push(r)}else if(r<2048){if((t-=2)<0)break;a.push(r>>6|192,r&63|128)}else if(r<65536){if((t-=3)<0)break;a.push(r>>12|224,r>>6&63|128,r&63|128)}else if(r<1114112){if((t-=4)<0)break;a.push(r>>18|240,r>>12&63|128,r>>6&63|128,r&63|128)}else throw new Error("Invalid code point")}return a}function fG(e){for(var t=[],r=0;r>8,i=r%256,a.push(i),a.push(n);return a}function UD(e){return BK(lG(e))}function gy(e,t,r,n){for(var i=0;i=t.length||i>=e.length);++i)t[i+r]=e[i];return i}function hG(e){return e!==e}function HD(e){return e!=null&&(!!e._isBuffer||VD(e)||pG(e))}function VD(e){return!!e.constructor&&typeof e.constructor.isBuffer=="function"&&e.constructor.isBuffer(e)}function pG(e){return typeof e.readFloatLE=="function"&&typeof e.slice=="function"&&VD(e.slice(0,0))}const mG=Object.freeze(Object.defineProperty({__proto__:null,Buffer:rt,INSPECT_MAX_BYTES:AD,SlowBuffer:GK,isBuffer:HD,kMaxLength:HK},Symbol.toStringTag,{value:"Module"}));function Tr(e,t,r,n,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),i&&(this.response=i)}ht.inherits(Tr,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:ht.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const qD=Tr.prototype,WD={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{WD[e]={value:e}});Object.defineProperties(Tr,WD);Object.defineProperty(qD,"isAxiosError",{value:!0});Tr.from=(e,t,r,n,i,a)=>{const s=Object.create(qD);return ht.toFlatObject(e,s,function(d){return d!==Error.prototype},f=>f!=="isAxiosError"),Tr.call(s,e.message,t,r,n,i),s.cause=e,s.name=e.name,a&&Object.assign(s,a),s};const vG=null;function A4(e){return ht.isPlainObject(e)||ht.isArray(e)}function KD(e){return ht.endsWith(e,"[]")?e.slice(0,-2):e}function Ek(e,t,r){return e?e.concat(t).map(function(i,a){return i=KD(i),!r&&a?"["+i+"]":i}).join(r?".":""):t}function gG(e){return ht.isArray(e)&&!e.some(A4)}const yG=ht.toFlatObject(ht,{},null,function(t){return/^is[A-Z]/.test(t)});function yy(e,t,r){if(!ht.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,r=ht.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(C,O){return!ht.isUndefined(O[C])});const n=r.metaTokens,i=r.visitor||y,a=r.dots,s=r.indexes,d=(r.Blob||typeof Blob<"u"&&Blob)&&ht.isSpecCompliantForm(t);if(!ht.isFunction(i))throw new TypeError("visitor must be a function");function p(M){if(M===null)return"";if(ht.isDate(M))return M.toISOString();if(!d&&ht.isBlob(M))throw new Tr("Blob is not supported. Use a Buffer instead.");return ht.isArrayBuffer(M)||ht.isTypedArray(M)?d&&typeof Blob=="function"?new Blob([M]):rt.from(M):M}function y(M,C,O){let T=M;if(M&&!O&&typeof M=="object"){if(ht.endsWith(C,"{}"))C=n?C:C.slice(0,-2),M=JSON.stringify(M);else if(ht.isArray(M)&&gG(M)||(ht.isFileList(M)||ht.endsWith(C,"[]"))&&(T=ht.toArray(M)))return C=KD(C),T.forEach(function(R,$){!(ht.isUndefined(R)||R===null)&&t.append(s===!0?Ek([C],$,a):s===null?C:C+"[]",p(R))}),!1}return A4(M)?!0:(t.append(Ek(O,C,a),p(M)),!1)}const w=[],_=Object.assign(yG,{defaultVisitor:y,convertValue:p,isVisitable:A4});function S(M,C){if(!ht.isUndefined(M)){if(w.indexOf(M)!==-1)throw Error("Circular reference detected in "+C.join("."));w.push(M),ht.forEach(M,function(T,k){(!(ht.isUndefined(T)||T===null)&&i.call(t,T,ht.isString(k)?k.trim():k,C,_))===!0&&S(T,C?C.concat(k):[k])}),w.pop()}}if(!ht.isObject(e))throw new TypeError("data must be an object");return S(e),t}function kk(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(n){return t[n]})}function qS(e,t){this._pairs=[],e&&yy(e,this,t)}const GD=qS.prototype;GD.append=function(t,r){this._pairs.push([t,r])};GD.toString=function(t){const r=t?function(n){return t.call(this,n,kk)}:kk;return this._pairs.map(function(i){return r(i[0])+"="+r(i[1])},"").join("&")};function wG(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function YD(e,t,r){if(!t)return e;const n=r&&r.encode||wG,i=r&&r.serialize;let a;if(i?a=i(t,r):a=ht.isURLSearchParams(t)?t.toString():new qS(t,r).toString(n),a){const s=e.indexOf("#");s!==-1&&(e=e.slice(0,s)),e+=(e.indexOf("?")===-1?"?":"&")+a}return e}class Tk{constructor(){this.handlers=[]}use(t,r,n){return this.handlers.push({fulfilled:t,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){ht.forEach(this.handlers,function(n){n!==null&&t(n)})}}const XD={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},bG=typeof URLSearchParams<"u"?URLSearchParams:qS,xG=typeof FormData<"u"?FormData:null,_G=typeof Blob<"u"?Blob:null,SG={isBrowser:!0,classes:{URLSearchParams:bG,FormData:xG,Blob:_G},protocols:["http","https","file","blob","url","data"]},ZD=typeof window<"u"&&typeof document<"u",MG=(e=>ZD&&["ReactNative","NativeScript","NS"].indexOf(e)<0)(typeof navigator<"u"&&navigator.product),EG=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",kG=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:ZD,hasStandardBrowserEnv:MG,hasStandardBrowserWebWorkerEnv:EG},Symbol.toStringTag,{value:"Module"})),Wo={...kG,...SG};function TG(e,t){return yy(e,new Wo.classes.URLSearchParams,Object.assign({visitor:function(r,n,i,a){return Wo.isNode&&ht.isBuffer(r)?(this.append(n,r.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function CG(e){return ht.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function PG(e){const t={},r=Object.keys(e);let n;const i=r.length;let a;for(n=0;n=r.length;return s=!s&&ht.isArray(i)?i.length:s,d?(ht.hasOwnProp(i,s)?i[s]=[i[s],n]:i[s]=n,!f):((!i[s]||!ht.isObject(i[s]))&&(i[s]=[]),t(r,n,i[s],a)&&ht.isArray(i[s])&&(i[s]=PG(i[s])),!f)}if(ht.isFormData(e)&&ht.isFunction(e.entries)){const r={};return ht.forEachEntry(e,(n,i)=>{t(CG(n),i,r,0)}),r}return null}function OG(e,t,r){if(ht.isString(e))try{return(t||JSON.parse)(e),ht.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(e)}const WS={transitional:XD,adapter:["xhr","http"],transformRequest:[function(t,r){const n=r.getContentType()||"",i=n.indexOf("application/json")>-1,a=ht.isObject(t);if(a&&ht.isHTMLForm(t)&&(t=new FormData(t)),ht.isFormData(t))return i&&i?JSON.stringify(JD(t)):t;if(ht.isArrayBuffer(t)||ht.isBuffer(t)||ht.isStream(t)||ht.isFile(t)||ht.isBlob(t))return t;if(ht.isArrayBufferView(t))return t.buffer;if(ht.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let f;if(a){if(n.indexOf("application/x-www-form-urlencoded")>-1)return TG(t,this.formSerializer).toString();if((f=ht.isFileList(t))||n.indexOf("multipart/form-data")>-1){const d=this.env&&this.env.FormData;return yy(f?{"files[]":t}:t,d&&new d,this.formSerializer)}}return a||i?(r.setContentType("application/json",!1),OG(t)):t}],transformResponse:[function(t){const r=this.transitional||WS.transitional,n=r&&r.forcedJSONParsing,i=this.responseType==="json";if(t&&ht.isString(t)&&(n&&!this.responseType||i)){const s=!(r&&r.silentJSONParsing)&&i;try{return JSON.parse(t)}catch(f){if(s)throw f.name==="SyntaxError"?Tr.from(f,Tr.ERR_BAD_RESPONSE,this,null,this.response):f}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Wo.classes.FormData,Blob:Wo.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};ht.forEach(["delete","get","head","post","put","patch"],e=>{WS.headers[e]={}});const KS=WS,RG=ht.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),AG=e=>{const t={};let r,n,i;return e&&e.split(` `).forEach(function(s){i=s.indexOf(":"),r=s.substring(0,i).trim().toLowerCase(),n=s.substring(i+1).trim(),!(!r||t[r]&&RG[r])&&(r==="set-cookie"?t[r]?t[r].push(n):t[r]=[n]:t[r]=t[r]?t[r]+", "+n:n)}),t},Ck=Symbol("internals");function mh(e){return e&&String(e).trim().toLowerCase()}function kv(e){return e===!1||e==null?e:ht.isArray(e)?e.map(kv):String(e)}function DG(e){const t=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(e);)t[n[1]]=n[2];return t}const $G=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function d2(e,t,r,n,i){if(ht.isFunction(n))return n.call(this,t,r);if(i&&(t=r),!!ht.isString(t)){if(ht.isString(n))return t.indexOf(n)!==-1;if(ht.isRegExp(n))return n.test(t)}}function IG(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,r,n)=>r.toUpperCase()+n)}function LG(e,t){const r=ht.toCamelCase(" "+t);["get","set","has"].forEach(n=>{Object.defineProperty(e,n+r,{value:function(i,a,s){return this[n].call(this,t,i,a,s)},configurable:!0})})}let wy=class{constructor(t){t&&this.set(t)}set(t,r,n){const i=this;function a(f,d,p){const y=mh(d);if(!y)throw new Error("header name must be a non-empty string");const w=ht.findKey(i,y);(!w||i[w]===void 0||p===!0||p===void 0&&i[w]!==!1)&&(i[w||d]=kv(f))}const s=(f,d)=>ht.forEach(f,(p,y)=>a(p,y,d));return ht.isPlainObject(t)||t instanceof this.constructor?s(t,r):ht.isString(t)&&(t=t.trim())&&!$G(t)?s(AG(t),r):t!=null&&a(r,t,n),this}get(t,r){if(t=mh(t),t){const n=ht.findKey(this,t);if(n){const i=this[n];if(!r)return i;if(r===!0)return DG(i);if(ht.isFunction(r))return r.call(this,i,n);if(ht.isRegExp(r))return r.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,r){if(t=mh(t),t){const n=ht.findKey(this,t);return!!(n&&this[n]!==void 0&&(!r||d2(this,this[n],n,r)))}return!1}delete(t,r){const n=this;let i=!1;function a(s){if(s=mh(s),s){const f=ht.findKey(n,s);f&&(!r||d2(n,n[f],f,r))&&(delete n[f],i=!0)}}return ht.isArray(t)?t.forEach(a):a(t),i}clear(t){const r=Object.keys(this);let n=r.length,i=!1;for(;n--;){const a=r[n];(!t||d2(this,this[a],a,t,!0))&&(delete this[a],i=!0)}return i}normalize(t){const r=this,n={};return ht.forEach(this,(i,a)=>{const s=ht.findKey(n,a);if(s){r[s]=kv(i),delete r[a];return}const f=t?IG(a):String(a).trim();f!==a&&delete r[a],r[f]=kv(i),n[f]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const r=Object.create(null);return ht.forEach(this,(n,i)=>{n!=null&&n!==!1&&(r[i]=t&&ht.isArray(n)?n.join(", "):n)}),r}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,r])=>t+": "+r).join(` `)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...r){const n=new this(t);return r.forEach(i=>n.set(i)),n}static accessor(t){const n=(this[Ck]=this[Ck]={accessors:{}}).accessors,i=this.prototype;function a(s){const f=mh(s);n[f]||(LG(i,s),n[f]=!0)}return ht.isArray(t)?t.forEach(a):a(t),this}};wy.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);ht.reduceDescriptors(wy.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(n){this[r]=n}}});ht.freezeMethods(wy);const qs=wy;function h2(e,t){const r=this||KS,n=t||r,i=qs.from(n.headers);let a=n.data;return ht.forEach(e,function(f){a=f.call(r,a,i.normalize(),t?t.status:void 0)}),i.normalize(),a}function QD(e){return!!(e&&e.__CANCEL__)}function sp(e,t,r){Tr.call(this,e??"canceled",Tr.ERR_CANCELED,t,r),this.name="CanceledError"}ht.inherits(sp,Tr,{__CANCEL__:!0});function NG(e,t,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?e(r):t(new Tr("Request failed with status code "+r.status,[Tr.ERR_BAD_REQUEST,Tr.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}const jG=Wo.hasStandardBrowserEnv?{write(e,t,r,n,i,a){const s=[e+"="+encodeURIComponent(t)];ht.isNumber(r)&&s.push("expires="+new Date(r).toGMTString()),ht.isString(n)&&s.push("path="+n),ht.isString(i)&&s.push("domain="+i),a===!0&&s.push("secure"),document.cookie=s.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function BG(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function FG(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function e$(e,t){return e&&!BG(t)?FG(e,t):t}const zG=Wo.hasStandardBrowserEnv?function(){const t=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a");let n;function i(a){let s=a;return t&&(r.setAttribute("href",s),s=r.href),r.setAttribute("href",s),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:r.pathname.charAt(0)==="/"?r.pathname:"/"+r.pathname}}return n=i(window.location.href),function(s){const f=ht.isString(s)?i(s):s;return f.protocol===n.protocol&&f.host===n.host}}():function(){return function(){return!0}}();function UG(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function HG(e,t){e=e||10;const r=new Array(e),n=new Array(e);let i=0,a=0,s;return t=t!==void 0?t:1e3,function(d){const p=Date.now(),y=n[a];s||(s=p),r[i]=d,n[i]=p;let w=a,_=0;for(;w!==i;)_+=r[w++],w=w%e;if(i=(i+1)%e,i===a&&(a=(a+1)%e),p-s{const a=i.loaded,s=i.lengthComputable?i.total:void 0,f=a-r,d=n(f),p=a<=s;r=a;const y={loaded:a,total:s,progress:s?a/s:void 0,bytes:f,rate:d||void 0,estimated:d&&s&&p?(s-a)/d:void 0,event:i};y[t?"download":"upload"]=!0,e(y)}}const VG=typeof XMLHttpRequest<"u",qG=VG&&function(e){return new Promise(function(r,n){let i=e.data;const a=qs.from(e.headers).normalize();let{responseType:s,withXSRFToken:f}=e,d;function p(){e.cancelToken&&e.cancelToken.unsubscribe(d),e.signal&&e.signal.removeEventListener("abort",d)}let y;if(ht.isFormData(i)){if(Wo.hasStandardBrowserEnv||Wo.hasStandardBrowserWebWorkerEnv)a.setContentType(!1);else if((y=a.getContentType())!==!1){const[C,...O]=y?y.split(";").map(T=>T.trim()).filter(Boolean):[];a.setContentType([C||"multipart/form-data",...O].join("; "))}}let w=new XMLHttpRequest;if(e.auth){const C=e.auth.username||"",O=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";a.set("Authorization","Basic "+btoa(C+":"+O))}const _=e$(e.baseURL,e.url);w.open(e.method.toUpperCase(),YD(_,e.params,e.paramsSerializer),!0),w.timeout=e.timeout;function S(){if(!w)return;const C=qs.from("getAllResponseHeaders"in w&&w.getAllResponseHeaders()),T={data:!s||s==="text"||s==="json"?w.responseText:w.response,status:w.status,statusText:w.statusText,headers:C,config:e,request:w};NG(function(R){r(R),p()},function(R){n(R),p()},T),w=null}if("onloadend"in w?w.onloadend=S:w.onreadystatechange=function(){!w||w.readyState!==4||w.status===0&&!(w.responseURL&&w.responseURL.indexOf("file:")===0)||setTimeout(S)},w.onabort=function(){w&&(n(new Tr("Request aborted",Tr.ECONNABORTED,e,w)),w=null)},w.onerror=function(){n(new Tr("Network Error",Tr.ERR_NETWORK,e,w)),w=null},w.ontimeout=function(){let O=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const T=e.transitional||XD;e.timeoutErrorMessage&&(O=e.timeoutErrorMessage),n(new Tr(O,T.clarifyTimeoutError?Tr.ETIMEDOUT:Tr.ECONNABORTED,e,w)),w=null},Wo.hasStandardBrowserEnv&&(f&&ht.isFunction(f)&&(f=f(e)),f||f!==!1&&zG(_))){const C=e.xsrfHeaderName&&e.xsrfCookieName&&jG.read(e.xsrfCookieName);C&&a.set(e.xsrfHeaderName,C)}i===void 0&&a.setContentType(null),"setRequestHeader"in w&&ht.forEach(a.toJSON(),function(O,T){w.setRequestHeader(T,O)}),ht.isUndefined(e.withCredentials)||(w.withCredentials=!!e.withCredentials),s&&s!=="json"&&(w.responseType=e.responseType),typeof e.onDownloadProgress=="function"&&w.addEventListener("progress",Pk(e.onDownloadProgress,!0)),typeof e.onUploadProgress=="function"&&w.upload&&w.upload.addEventListener("progress",Pk(e.onUploadProgress)),(e.cancelToken||e.signal)&&(d=C=>{w&&(n(!C||C.type?new sp(null,e,w):C),w.abort(),w=null)},e.cancelToken&&e.cancelToken.subscribe(d),e.signal&&(e.signal.aborted?d():e.signal.addEventListener("abort",d)));const M=UG(_);if(M&&Wo.protocols.indexOf(M)===-1){n(new Tr("Unsupported protocol "+M+":",Tr.ERR_BAD_REQUEST,e));return}w.send(i||null)})},D4={http:vG,xhr:qG};ht.forEach(D4,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const Ok=e=>`- ${e}`,WG=e=>ht.isFunction(e)||e===null||e===!1,t$={getAdapter:e=>{e=ht.isArray(e)?e:[e];const{length:t}=e;let r,n;const i={};for(let a=0;a`adapter ${f} `+(d===!1?"is not supported by the environment":"is not available in the build"));let s=t?a.length>1?`since : `+a.map(Ok).join(` `):" "+Ok(a[0]):"as no adapter specified";throw new Tr("There is no suitable adapter to dispatch the request "+s,"ERR_NOT_SUPPORT")}return n},adapters:D4};function p2(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new sp(null,e)}function Rk(e){return p2(e),e.headers=qs.from(e.headers),e.data=h2.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),t$.getAdapter(e.adapter||KS.adapter)(e).then(function(n){return p2(e),n.data=h2.call(e,e.transformResponse,n),n.headers=qs.from(n.headers),n},function(n){return QD(n)||(p2(e),n&&n.response&&(n.response.data=h2.call(e,e.transformResponse,n.response),n.response.headers=qs.from(n.response.headers))),Promise.reject(n)})}const Ak=e=>e instanceof qs?e.toJSON():e;function Vf(e,t){t=t||{};const r={};function n(p,y,w){return ht.isPlainObject(p)&&ht.isPlainObject(y)?ht.merge.call({caseless:w},p,y):ht.isPlainObject(y)?ht.merge({},y):ht.isArray(y)?y.slice():y}function i(p,y,w){if(ht.isUndefined(y)){if(!ht.isUndefined(p))return n(void 0,p,w)}else return n(p,y,w)}function a(p,y){if(!ht.isUndefined(y))return n(void 0,y)}function s(p,y){if(ht.isUndefined(y)){if(!ht.isUndefined(p))return n(void 0,p)}else return n(void 0,y)}function f(p,y,w){if(w in t)return n(p,y);if(w in e)return n(void 0,p)}const d={url:a,method:a,data:a,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:f,headers:(p,y)=>i(Ak(p),Ak(y),!0)};return ht.forEach(Object.keys(Object.assign({},e,t)),function(y){const w=d[y]||i,_=w(e[y],t[y],y);ht.isUndefined(_)&&w!==f||(r[y]=_)}),r}const r$="1.6.5",GS={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{GS[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});const Dk={};GS.transitional=function(t,r,n){function i(a,s){return"[Axios v"+r$+"] Transitional option '"+a+"'"+s+(n?". "+n:"")}return(a,s,f)=>{if(t===!1)throw new Tr(i(s," has been removed"+(r?" in "+r:"")),Tr.ERR_DEPRECATED);return r&&!Dk[s]&&(Dk[s]=!0,console.warn(i(s," has been deprecated since v"+r+" and will be removed in the near future"))),t?t(a,s,f):!0}};function KG(e,t,r){if(typeof e!="object")throw new Tr("options must be an object",Tr.ERR_BAD_OPTION_VALUE);const n=Object.keys(e);let i=n.length;for(;i-- >0;){const a=n[i],s=t[a];if(s){const f=e[a],d=f===void 0||s(f,a,e);if(d!==!0)throw new Tr("option "+a+" must be "+d,Tr.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new Tr("Unknown option "+a,Tr.ERR_BAD_OPTION)}}const $4={assertOptions:KG,validators:GS},pl=$4.validators;let Dg=class{constructor(t){this.defaults=t,this.interceptors={request:new Tk,response:new Tk}}request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=Vf(this.defaults,r);const{transitional:n,paramsSerializer:i,headers:a}=r;n!==void 0&&$4.assertOptions(n,{silentJSONParsing:pl.transitional(pl.boolean),forcedJSONParsing:pl.transitional(pl.boolean),clarifyTimeoutError:pl.transitional(pl.boolean)},!1),i!=null&&(ht.isFunction(i)?r.paramsSerializer={serialize:i}:$4.assertOptions(i,{encode:pl.function,serialize:pl.function},!0)),r.method=(r.method||this.defaults.method||"get").toLowerCase();let s=a&&ht.merge(a.common,a[r.method]);a&&ht.forEach(["delete","get","head","post","put","patch","common"],M=>{delete a[M]}),r.headers=qs.concat(s,a);const f=[];let d=!0;this.interceptors.request.forEach(function(C){typeof C.runWhen=="function"&&C.runWhen(r)===!1||(d=d&&C.synchronous,f.unshift(C.fulfilled,C.rejected))});const p=[];this.interceptors.response.forEach(function(C){p.push(C.fulfilled,C.rejected)});let y,w=0,_;if(!d){const M=[Rk.bind(this),void 0];for(M.unshift.apply(M,f),M.push.apply(M,p),_=M.length,y=Promise.resolve(r);w<_;)y=y.then(M[w++],M[w++]);return y}_=f.length;let S=r;for(w=0;w<_;){const M=f[w++],C=f[w++];try{S=M(S)}catch(O){C.call(this,O);break}}try{y=Rk.call(this,S)}catch(M){return Promise.reject(M)}for(w=0,_=p.length;w<_;)y=y.then(p[w++],p[w++]);return y}getUri(t){t=Vf(this.defaults,t);const r=e$(t.baseURL,t.url);return YD(r,t.params,t.paramsSerializer)}};ht.forEach(["delete","get","head","options"],function(t){Dg.prototype[t]=function(r,n){return this.request(Vf(n||{},{method:t,url:r,data:(n||{}).data}))}});ht.forEach(["post","put","patch"],function(t){function r(n){return function(a,s,f){return this.request(Vf(f||{},{method:t,headers:n?{"Content-Type":"multipart/form-data"}:{},url:a,data:s}))}}Dg.prototype[t]=r(),Dg.prototype[t+"Form"]=r(!0)});const Tv=Dg;let GG=class n${constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(a){r=a});const n=this;this.promise.then(i=>{if(!n._listeners)return;let a=n._listeners.length;for(;a-- >0;)n._listeners[a](i);n._listeners=null}),this.promise.then=i=>{let a;const s=new Promise(f=>{n.subscribe(f),a=f}).then(i);return s.cancel=function(){n.unsubscribe(a)},s},t(function(a,s,f){n.reason||(n.reason=new sp(a,s,f),r(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const r=this._listeners.indexOf(t);r!==-1&&this._listeners.splice(r,1)}static source(){let t;return{token:new n$(function(i){t=i}),cancel:t}}};const YG=GG;function XG(e){return function(r){return e.apply(null,r)}}function ZG(e){return ht.isObject(e)&&e.isAxiosError===!0}const I4={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(I4).forEach(([e,t])=>{I4[t]=e});const JG=I4;function i$(e){const t=new Tv(e),r=xD(Tv.prototype.request,t);return ht.extend(r,Tv.prototype,t,{allOwnKeys:!0}),ht.extend(r,t,null,{allOwnKeys:!0}),r.create=function(i){return i$(Vf(e,i))},r}const Ir=i$(KS);Ir.Axios=Tv;Ir.CanceledError=sp;Ir.CancelToken=YG;Ir.isCancel=QD;Ir.VERSION=r$;Ir.toFormData=yy;Ir.AxiosError=Tr;Ir.Cancel=Ir.CanceledError;Ir.all=function(t){return Promise.all(t)};Ir.spread=XG;Ir.isAxiosError=ZG;Ir.mergeConfig=Vf;Ir.AxiosHeaders=qs;Ir.formToJSON=e=>JD(ht.isHTMLForm(e)?new FormData(e):e);Ir.getAdapter=t$.getAdapter;Ir.HttpStatusCode=JG;Ir.default=Ir;const{Axios:QG,AxiosError:eY,CanceledError:tY,isCancel:rY,CancelToken:nY,VERSION:iY,all:aY,Cancel:oY,isAxiosError:sY,spread:lY,toFormData:uY,AxiosHeaders:cY,HttpStatusCode:fY,formToJSON:dY,getAdapter:hY,mergeConfig:pY}=Ir,mY=Object.freeze(Object.defineProperty({__proto__:null,Axios:QG,AxiosError:eY,AxiosHeaders:cY,Cancel:oY,CancelToken:nY,CanceledError:tY,HttpStatusCode:fY,VERSION:iY,all:aY,default:Ir,formToJSON:dY,getAdapter:hY,isAxiosError:sY,isCancel:rY,mergeConfig:pY,spread:lY,toFormData:uY},Symbol.toStringTag,{value:"Module"})),a$=te("layout/getBookmarks",async()=>{const e=await Ir.get("/api/bookmarks/data");return{data:e.data.suggestions,bookmarks:e.data.bookmarks}}),vY=te("layout/updateBookmarked",async e=>(await Ir.post("/api/bookmarks/update",{id:e}),e)),gY=er({name:"layout",initialState:{query:"",bookmarks:[],suggestions:[]},reducers:{handleSearchQuery:(e,t)=>{e.query=t.payload}},extraReducers:e=>{e.addCase(a$.fulfilled,(t,r)=>{t.suggestions=r.payload.data,t.bookmarks=r.payload.bookmarks}).addCase(vY.fulfilled,(t,r)=>{let n;t.suggestions.find(a=>{a.id===r.payload&&(a.isBookmarked=!a.isBookmarked,n=a)});const i=t.bookmarks.findIndex(a=>a.id===r.payload);i===-1?t.bookmarks.push(n):t.bookmarks.splice(i,1)})}}),yY=gY.reducer,YS="/assets/deepknit--logo-XMVLvWx7.png",fi={app:{appName:"DeepKnit.ai",appLogoImage:YS},layout:{isRTL:!1,skin:"semi-dark",type:"vertical",contentWidth:"boxed",menu:{isHidden:!1,isCollapsed:!1},navbar:{type:"sticky",backgroundColor:"white"},footer:{type:"static"},customizer:!1,scrollTop:!0,toastPosition:"top-center"}},wY=()=>{const e=window.localStorage.getItem("menuCollapsed");return e?JSON.parse(e):fi.layout.menu.isCollapsed},bY=()=>{const e=window.localStorage.getItem("direction");return e?JSON.parse(e):fi.layout.isRTL},xY=()=>(window.localStorage.getItem("skin"),fi.layout.skin),o$=er({name:"layout",initialState:{skin:xY(),isRTL:bY(),layout:fi.layout.type,lastLayout:fi.layout.type,menuCollapsed:wY(),footerType:fi.layout.footer.type,navbarType:fi.layout.navbar.type,menuHidden:fi.layout.menu.isHidden,contentWidth:fi.layout.contentWidth,navbarColor:fi.layout.navbar.backgroundColor},reducers:{handleRTL:(e,t)=>{e.isRTL=t.payload,window.localStorage.setItem("direction",JSON.stringify(t.payload))},handleSkin:(e,t)=>{e.skin=t.payload,window.localStorage.setItem("skin",JSON.stringify(t.payload))},handleLayout:(e,t)=>{e.layout=t.payload},handleFooterType:(e,t)=>{e.footerType=t.payload},handleNavbarType:(e,t)=>{e.navbarType=t.payload},handleMenuHidden:(e,t)=>{e.menuHidden=t.payload},handleLastLayout:(e,t)=>{e.lastLayout=t.payload},handleNavbarColor:(e,t)=>{e.navbarColor=t.payload},handleContentWidth:(e,t)=>{e.contentWidth=t.payload},handleMenuCollapsed:(e,t)=>{e.menuCollapsed=t.payload,window.localStorage.setItem("menuCollapsed",JSON.stringify(t.payload))}}}),{handleRTL:_Y,handleSkin:SY,handleLayout:MY,handleLastLayout:EY,handleMenuHidden:$k,handleNavbarType:kY,handleFooterType:TY,handleNavbarColor:CY,handleContentWidth:Ik,handleMenuCollapsed:L4}=o$.actions,PY=o$.reducer,OY={loginEndpoint:"/jwt/login-basic",registerEndpoint:"/jwt/register",refreshEndpoint:"/jwt/refresh-token",logoutEndpoint:"/jwt/logout",tokenType:"Bearer",storageTokenKeyName:"accessToken",storageRefreshTokenKeyName:"refreshToken"};class RY{constructor(t){hm(this,"jwtConfig",{...OY});hm(this,"isAlreadyFetchingAccessToken",!1);hm(this,"subscribers",[]);this.jwtConfig={...this.jwtConfig,...t},Ir.interceptors.request.use(r=>{const n=this.getToken();return n&&(r.headers.Authorization=`${this.jwtConfig.tokenType} ${n}`),r},r=>Promise.reject(r)),Ir.interceptors.response.use(r=>r,r=>{const{config:n,response:i}=r,a=n;return i&&i.status===401?(this.isAlreadyFetchingAccessToken||(this.isAlreadyFetchingAccessToken=!0,this.refreshToken().then(f=>{this.isAlreadyFetchingAccessToken=!1,this.setToken(f.data.accessToken),this.setRefreshToken(f.data.refreshToken),this.onAccessTokenFetched(f.data.accessToken)})),new Promise(f=>{this.addSubscriber(d=>{a.headers.Authorization=`${this.jwtConfig.tokenType} ${d}`,f(this.axios(a))})})):Promise.reject(r)})}onAccessTokenFetched(t){this.subscribers=this.subscribers.filter(r=>r(t))}addSubscriber(t){this.subscribers.push(t)}getToken(){return localStorage.getItem(this.jwtConfig.storageTokenKeyName)}getRefreshToken(){return localStorage.getItem(this.jwtConfig.storageRefreshTokenKeyName)}setToken(t){localStorage.setItem(this.jwtConfig.storageTokenKeyName,t)}setRefreshToken(t){localStorage.setItem(this.jwtConfig.storageRefreshTokenKeyName,t)}login(...t){return Ir.post(this.jwtConfig.loginEndpoint,...t)}register(...t){return Ir.post(this.jwtConfig.registerEndpoint,...t)}refreshToken(){return Ir.post(this.jwtConfig.refreshEndpoint,{refreshToken:this.getRefreshToken()})}}function AY(e){return{jwt:new RY(e)}}const{jwt:DY}=AY({}),jo=DY.jwtConfig,$Y=()=>{const e=window.localStorage.getItem("userData");return e?JSON.parse(e):{}},s$=er({name:"authentication",initialState:{userData:$Y()},reducers:{handleLogin:(e,t)=>{e.userData=t.payload,e[jo.storageTokenKeyName]=t.payload[jo.storageTokenKeyName],e[jo.storageRefreshTokenKeyName]=t.payload[jo.storageRefreshTokenKeyName],localStorage.setItem("userData",JSON.stringify(t.payload)),localStorage.setItem(jo.storageTokenKeyName,JSON.stringify(t.payload.accessToken)),localStorage.setItem("navigationType","FromLogin"),localStorage.setItem(jo.storageRefreshTokenKeyName,JSON.stringify(t.payload.refreshToken))},handleLogout:e=>{e.userData={},e[jo.storageTokenKeyName]=null,e[jo.storageRefreshTokenKeyName]=null,localStorage.removeItem("userData"),localStorage.removeItem("version"),localStorage.removeItem(jo.storageTokenKeyName),localStorage.removeItem(jo.storageRefreshTokenKeyName)}}}),{handleLogin:iTe,handleLogout:IY}=s$.actions,LY=s$.reducer,NY="0dc4fc329fafec687c00e6c8f5b02f4b",jY={ENCRYPTION_KEY:NY},BY=e=>new TextEncoder().encode(e),FY=e=>new TextDecoder().decode(e);async function zY(e){const t=new TextEncoder().encode(e);return await crypto.subtle.importKey("raw",t,{name:"AES-GCM"},!0,["encrypt","decrypt"])}const UY=e=>{const t=new Uint8Array(e);let r="";const n=8192;for(let i=0;i{const t=new Uint8Array(e.length),r=e.length;for(let n=0;nlocalStorage.getItem(m2),getRefresh:()=>localStorage.getItem(v2),set:(e,t)=>{e&&localStorage.setItem(m2,e),t&&localStorage.setItem(v2,t)},clear:()=>{localStorage.removeItem(m2),localStorage.removeItem(v2)},isPublicEndpoint:e=>HY.some(t=>e.includes(t))},N4=()=>{Kl.clear(),window.location.pathname!=="/pages/login-basic"&&(localStorage.clear(),window.location.href="/pages/login-basic")},l$=async()=>{const e=Kl.getRefresh();if(!e)throw N4(),new Error("No refresh token available");try{const t=await ue,r=await ge(t,{refresh_token:e}),n=await fetch($0+"api/Authentication/refresh-token",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({EncParams:r})});if(!n.ok)throw new Error("Token refresh failed");const i=await n.json();try{const a=await Me(t,i);if(a.status==="OK"&&a.access_token)return Kl.set(a.access_token,(a==null?void 0:a.refresh_token)||e),a.access_token;throw new Error(a.message||"Invalid refresh response")}catch(a){if(i.status==="OK"&&i.access_token)return Kl.set(i.access_token,(i==null?void 0:i.refresh_token)||e),i.access_token;throw a}}catch(t){throw console.error("🔴 Token refresh failed:",t),N4(),t}};let Rm=!1,j4=[];const Nk=(e,t=null)=>{j4.forEach(({resolve:r,reject:n})=>{e?n(e):r(t)}),j4=[]},jk=async(e,t={})=>{const r=$0+e,n={"Content-Type":"application/json",...t.headers};if(t.body instanceof FormData&&delete n["Content-Type"],!Kl.isPublicEndpoint(e)){const i=Kl.get();if(!i)throw N4(),new Error("No access token available");n.Authorization=`Bearer ${i}`}try{const i=await fetch(r,{...t,headers:n});return i.status===401&&!Kl.isPublicEndpoint(e)?await VY(r,t,n):i}catch(i){throw console.error("API request failed:",i),i}},VY=async(e,t,r)=>{if(Rm)return new Promise((n,i)=>{j4.push({resolve:a=>{r.Authorization=`Bearer ${a}`,n(fetch(e,{...t,headers:r}))},reject:i})});Rm=!0;try{const n=await l$();return Rm=!1,Nk(null,n),r.Authorization=`Bearer ${n}`,fetch(e,{...t,headers:r})}catch(n){throw Rm=!1,Nk(n,null),n}},Q={get:(e,t={})=>jk(e,{...t,method:"GET"}),post:(e,t,r={})=>jk(e,{...r,method:"POST",body:t instanceof FormData?t:JSON.stringify(t)}),refreshToken:l$,token:Kl},by=te("appEmail/getMails",async e=>{const{q:t="",folder:r="inbox",label:n}=e;try{let i=function(w){if(r!=="sent"&&w.user_id===localStorage.id)return r==="trash"?w.folder==="trash":r==="starred"?w.isStarred&&w.folder!=="trash":w.folder===(r||w.folder)&&w.folder!=="trash";if(r==="sent"&&w.folder_sent_id===localStorage.id)return w.folder_sent===(r||w.folder_sent)&&w.folder_sent!=="trash";if(r==="trash")return w.folder_sent==="trash"};const a=await Q.get("api/communication/get-emails");if(!a.ok)throw new Error("Failed to fetch emails");const f=(await a.json()).map(w=>({id:w.id,from:w.from,to:w.to,subject:w.subject,message:w.message,isStarred:w.isStarred,time:w.time,replies:w.replies,folder:w.folder,folder_sent:w.folder_sent,folder_sent_id:w.folder_sent_id,isRead:w.isRead,user_id:w.user_id,sent_isStarred:w.sent_isStarred,sent_isRead:w.sent_isRead})),d=t.toLowerCase(),p=f.filter(w=>(w.from.name.toLowerCase().includes(d)||w.subject.toLowerCase().includes(d))&&i(w)&&(n?w.labels.includes(n):!0)),y={inbox:f.filter(w=>!w.isDeleted&&!w.isRead&&w.folder==="inbox"&&w.folder_sent_id!==localStorage.id&&w.user_id===localStorage.id).length,draft:f.filter(w=>w.folder==="draft"&&w.folder_sent_id!==localStorage.id&&w.user_id===localStorage.id).length,spam:f.filter(w=>!w.isDeleted&&!w.isRead&&w.folder==="spam"&&w.folder_sent_id!==localStorage.id&&w.user_id===localStorage.id).length};return{params:e,emails:p.reverse(),emailsMeta:y}}catch(i){throw console.error("Error fetching emails:",i),i}}),qY=te("appEmail/updateMails",async({emailIds:e,dataToUpdate:t},{dispatch:r,getState:n})=>{const a=await(await Q.post("api/communication/update-emails",{emailIds:e,dataToUpdate:t})).json();return await r(by(n().email.params)),{emailIds:e,dataToUpdate:t,data:a}}),aTe=te("appEmail/getUserDetails",async({UserType:e,userId:t,ParentUserId:r},{dispatch:n,getState:i})=>await(await Q.post("api/communication/get-user-details",{UserType:e,userId:t,ParentUserId:r})).json()),oTe=te("appEmail/getUserAllocatedFiles",async({UserType:e,userId:t,ParentUserId:r},{dispatch:n,getState:i})=>await(await Q.post("api/communication/get-user-allocated-files",{UserType:e,userId:t,ParentUserId:r})).json()),sTe=te("appEmail/AddComposeMail",async(e,{dispatch:t,getState:r})=>{const i=await(await Q.post("api/communication/compose-mail",{data:e})).json();return await t(by(r().email.params)),i}),lTe=te("appEmail/updateMailLabel",async({emailIds:e,label:t},{dispatch:r,getState:n})=>{const i=await Ir.post("/apps/email/update-emails-label",{emailIds:e,label:t});return await r(by(n().email.params)),i.data}),WY=te("appEmail/paginateMail",async({dir:e,emailId:t})=>(await Ir.get("/apps/email/paginate-email",{params:{dir:e,emailId:t}})).data),KY=te("appEmail/selectCurrentMail",async e=>await(await Q.post("api/communication/get-email",{id:e})).json()),u$=er({name:"appEmail",initialState:{mails:[],params:{},emailsMeta:{},selectedMails:[],currentMail:null},reducers:{selectMail:(e,t)=>{const r=e.selectedMails;r.includes(t.payload)?r.splice(r.indexOf(t.payload),1):r.push(t.payload),e.selectedMails=r},selectAllMail:(e,t)=>{const r=[];t.payload?(r.length=0,e.mails.forEach(n=>r.push(n.id))):r.length=0,e.selectedMails=r},resetSelectedMail:e=>{e.selectedMails=[]}},extraReducers:e=>{e.addCase(by.fulfilled,(t,r)=>{let n=null;t.currentMail!==null&&t.currentMail!==void 0&&(n=r.payload.emails.find(i=>i.id===t.currentMail.id)),t.currentMail=n,t.params=r.payload.params,t.mails=r.payload.emails,t.emailsMeta=r.payload.emailsMeta}).addCase(qY.fulfilled,(t,r)=>{function n(i){Object.assign(i,r.payload.dataToUpdate)}t.mails.forEach(i=>{r.payload.emailIds.includes(i.id)&&n(i)})}).addCase(WY.fulfilled,(t,r)=>{const n=r.payload,i=t.mails.findIndex(a=>a.id===n.id);i===0?n.hasPreviousMail=!1:n.hasPreviousMail=!0,i===t.mails.length-1?n.hasNextMail=!1:n.hasNextMail=!0,t.currentMail=n}).addCase(KY.fulfilled,(t,r)=>{t.currentMail=r.payload})}}),{selectMail:uTe,selectAllMail:cTe,resetSelectedMail:fTe}=u$.actions,GY=u$.reducer;let Am;const YY=new Uint8Array(16);function XY(){if(!Am&&(Am=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Am))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Am(YY)}const Gn=[];for(let e=0;e<256;++e)Gn.push((e+256).toString(16).slice(1));function ZY(e,t=0){return(Gn[e[t+0]]+Gn[e[t+1]]+Gn[e[t+2]]+Gn[e[t+3]]+"-"+Gn[e[t+4]]+Gn[e[t+5]]+"-"+Gn[e[t+6]]+Gn[e[t+7]]+"-"+Gn[e[t+8]]+Gn[e[t+9]]+"-"+Gn[e[t+10]]+Gn[e[t+11]]+Gn[e[t+12]]+Gn[e[t+13]]+Gn[e[t+14]]+Gn[e[t+15]]).toLowerCase()}const JY=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),Bk={randomUUID:JY};function Un(e,t,r){if(Bk.randomUUID&&!t&&!e)return Bk.randomUUID();e=e||{};const n=e.random||(e.rng||XY)();if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,t){r=r||0;for(let i=0;i<16;++i)t[r+i]=n[i];return t}return ZY(n)}const tn=(e,t,r)=>e.slice((r-1)*t,r*t),dTe=te("appCalendar/getClientDetails",async()=>{const e=await ue,t=await Q.get("api/user-management/get-client-details").then(n=>n.json());return await Me(e,t)}),hTe=te("appCalendar/getClientDetails",async()=>{const e=await ue,t=await Q.get("api/dashboard/get-user-type").then(n=>n.json());return Me(e,t)}),pTe=te("appCalendar/getuser",async()=>{const e=await ue,t=await Q.get("api/dashboard/get-client").then(n=>n.json());return await Me(e,t)}),mTe=te("appCalendar/getVendorDetails",async()=>{const e=await ue,t=await Q.get("api/user-management/get-vendor-details").then(n=>n.json());return await Me(e,t)}),vTe=te("appCalendar/Get_FileReceived_Count",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/get-file-received-count",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),gTe=te("appCalendar/Announcement",async e=>{const t=await ue,r=await ge(t,e);return await Q.post("api/dashboard/add-announcement",{EncParams:r}).then(i=>i.json())}),yTe=te("appCalendar/get_uploadedFiles",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/get-uploaded-files",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),wTe=te("appCalendar/Get_Mapped_vendors",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/get-mapped-vendors",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),bTe=te("appCalendar/getUserDetails",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/get-user-details",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),xTe=te("appCalendar/parentusersname",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/parent-users-name",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),_Te=te("appCalendar/UserDetails",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/users-details",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),STe=te("appCalendar/getuserearningsfile",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/Client-details",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),MTe=te("appCalendar/getUserCapacity",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/get-user-capacity",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),ETe=te("appCalendar/get_allocatedFiles",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/get-allocated-files",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),kTe=te("appCalendar/get_User_allocatedFiles",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/get-user-allocated-files",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),TTe=te("appCalendar/addCapacity",async(e,{dispatch:t,getState:r})=>{try{e.Refid=Un();const n=await ue,i=await ge(n,e),s=await(await Q.post("api/dashboard/add-capacity",{EncParams:i})).json(),f=await Me(n,s);return await t(B4()),await t(B4(r().calendar.selectedCalendars)),e}catch(n){throw console.error("Error in addCapacity:",n),n}}),CTe=te("appCalendar/auditLogdata",async e=>{const t=e.Refid,r=await ue,n=await ge(r,{Data:e,ID:t}),i=await Q.post("api/dashboard/add-audit-log",{EncParams:n}).then(s=>s.json());return await Me(r,i)}),PTe=te("appCalendar/auditLogdata",async e=>{const t=await ue,r=await ge(t,{Data:e}),n=await Q.post("api/dashboard/audit-log",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),OTe=te("appCalendar/updateEvent",async(e,{dispatch:t,getState:r})=>{const n=await ue,i=await ge(n,e),a=await Q.post("api/dashboard/update-event",{EncParams:i}).then(f=>f.json());return await Me(n,a)}),RTe=te("Dashboard/updateAuditlog",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/update-audit-log",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),B4=te("appCalendar/fetchEvents",async()=>{const e=await ue,t=await Q.get("api/dashboard/get-capacity").then(n=>n.json());return await Me(e,t)}),ATe=te("appCalendar/files",async e=>{const t=await ue,r=await ge(t,e);return await Q.post("api/dashboard/files-count",{EncParams:r}).then(i=>i.json())}),DTe=te("appCalendar/files",async e=>{const t=await ue,r=await ge(t,e);return await Q.post("api/dashboard/get-count-received",{EncParams:r}).then(i=>i.json())});te("appCalendar/files",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/get-count-ocr",{EncParams:r}).then(a=>a.json());return await Me(t,n)});const $Te=te("appCalendar/OCR_Status",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/dashboard/ocr-status",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),ITe=te("appCalendar/Get_permission",async e=>{const t=await ue,r=await ge(t,e);return await Q.post("api/get-permission/",{EncParams:r}).then(i=>i.json())}),LTe=te("VendorUserAllocation/venorNameAllocation",async()=>{const e=await ue,t=await Q.get("api/dashboard/vendor-details").then(n=>n.json());return await Me(e,t)});function QY(e,t,r,n,i){return(e.id&&String(e.id).toLowerCase().includes(t)||e.file_Name&&String(e.file_Name).toLowerCase().includes(t)||e.client_name&&String(e.client_name).toLowerCase().includes(t)||e.created_at&&String(e.created_at).toLowerCase().includes(t)||e.patient_name&&String(e.patient_name).toLowerCase().includes(t)||e.modified_at&&String(e.modified_at).toLowerCase().includes(t)||e.download_status&&String(e.download_status).toLowerCase().includes(t)||e.ocr_status&&String(e.ocr_status).toLowerCase().includes(t)||e.extract_status&&String(e.extract_status).toLowerCase().includes(t)||e.data_extraction&&String(e.data_extraction).toLowerCase().includes(t)||e.document_count&&String(e.document_count).toLowerCase().includes(t)||e.pdf_count&&String(e.pdf_count).toLowerCase().includes(t)||e.folder_size&&String(e.folder_size).toLowerCase().includes(t)||e.page_count&&String(e.page_count).toLowerCase().includes(t)||e.document_type&&String(e.document_type).toLowerCase().includes(t))&&e.client_name===(i||e.client_name)&&e.patient_name===(n||e.patient_name)&&e.data_extraction===(r||e.data_extraction)}const eX=te("ClientFileStatus/getData",async e=>{try{const t=e.id||localStorage.Clientid,r=e.usertype||localStorage.UserType,n={id:t,usertype:r},i=await ue,a=await ge(i,n),f=await(await Q.post("api/dashboard/client-file-status",{EncParams:a})).json(),d=await Me(i,f);if(d!=="There is no Record Found"){d.forEach(L=>{const j=localStorage.timezone,A=new Date(L.created_at),V=new Date().getTimezoneOffset(j),z=new Date(A.getTime()-V*60*1e3);L.created_at=z.toLocaleString("en-US")});const p=d,{q:y="",perPage:w=5,page:_=1,sort:S,data_extraction:M=null,patient_name:C=null,client_name:O=null}=e,T=p.sort((L,j)=>{const A=new Date(L.created_at),V=new Date(j.created_at);return S==="desc"?A-V:V-A}),k=S==="asc"?T:T.reverse(),R=y.toLowerCase(),$=k.filter(L=>QY(L,R,M,C,O));return $.length===0?{params:e,data:[],allData:p,totalPages:0,no_Data:"There is no Record Found"}:{params:e,data:$.length<=w?$:tn($,w,_),allData:p,totalPages:$.length,no_Data:[]}}else if(d==="There is no Record Found")return{params:e,data:[],allData:[],totalPages:0,no_Data:d}}catch(t){throw console.error(t),t}}),tX=er({name:"ClientFileStatus",initialState:{data:[],total:0,params:{},allData:[]},reducers:{},extraReducers:e=>{e.addCase(eX.fulfilled,(t,r)=>{t.data=r.payload.data,t.allData=r.payload.allData,t.total=r.payload.totalPages,t.params=r.payload.params,t.no_Data=r.payload.no_Data})}}),c$=er({name:"appCalendar",initialState:{events:[],selectedEvent:{},selectedCalendars:["Personal","Business","Family","Holiday","ETC"]},reducers:{selectEvent:(e,t)=>{e.selectedEvent=t.payload}},extraReducers:e=>{e.addCase(B4.fulfilled,(t,r)=>{t.events=r.payload})}}),{selectEvent:NTe}=c$.actions,rX=c$.reducer,nX=tX.reducer,f$=(e,t)=>{const{operation:r,document:n,document_id:i}=t.payload,a=i,s=(f,d)=>f.findIndex(p=>String(p.id)===String(d)||String(p._id)===String(d));if(r==="update"||r==="replace"){const f=s(e.data,a);if(f!==-1&&(e.data[f]={...e.data[f],...n},e.data[f].id||(e.data[f].id=a)),e.allData){const d=s(e.allData,a);d!==-1&&(e.allData[d]={...e.allData[d],...n},e.allData[d].id||(e.allData[d].id=a))}}else if(r==="insert"){if(s(e.data,a)===-1){const f={...n};f.id||(f.id=a),e.data.unshift(f),e.allData&&e.allData.unshift(f),typeof e.total=="number"&&(e.total+=1)}}else r==="delete"&&(e.data=e.data.filter(f=>String(f.id)!==String(a)&&String(f._id)!==String(a)),e.allData&&(e.allData=e.allData.filter(f=>String(f.id)!==String(a)&&String(f._id)!==String(a))),typeof e.total=="number"&&(e.total=Math.max(0,e.total-1)))};var d$={exports:{}};function df(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var g2={exports:{}},tr={},F4={exports:{}},z4={exports:{}};const mi=K1(mG);/*! safe-buffer. MIT License. Feross Aboukhadijeh */(function(e,t){var r=mi,n=r.Buffer;function i(s,f){for(var d in s)f[d]=s[d]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=r:(i(r,t),t.Buffer=a);function a(s,f,d){return n(s,f,d)}a.prototype=Object.create(n.prototype),i(n,a),a.from=function(s,f,d){if(typeof s=="number")throw new TypeError("Argument must not be a number");return n(s,f,d)},a.alloc=function(s,f,d){if(typeof s!="number")throw new TypeError("Argument must be a number");var p=n(s);return f!==void 0?typeof d=="string"?p.fill(f,d):p.fill(f):p.fill(0),p},a.allocUnsafe=function(s){if(typeof s!="number")throw new TypeError("Argument must be a number");return n(s)},a.allocUnsafeSlow=function(s){if(typeof s!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(s)}})(z4,z4.exports);var Jt=z4.exports,y2=65536,iX=4294967295;function aX(){throw new Error(`Secure random number generation is not supported by this browser. Use Chrome, Firefox or Internet Explorer 11`)}var oX=Jt.Buffer,$g=globalThis.crypto||globalThis.msCrypto;$g&&$g.getRandomValues?F4.exports=sX:F4.exports=aX;function sX(e,t){if(e>iX)throw new RangeError("requested too many random bytes");var r=oX.allocUnsafe(e);if(e>0)if(e>y2)for(var n=0;n0&&(s=r[0]),s instanceof Error)throw s;var f=new Error("Unhandled error."+(s?" ("+s.message+")":""));throw f.context=s,f}var d=a[t];if(d===void 0)return!1;if(typeof d=="function")Fk(d,this,r);else for(var p=d.length,y=w$(d,p),n=0;n0&&s.length>i&&!s.warned){s.warned=!0;var f=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");f.name="MaxListenersExceededWarning",f.emitter=e,f.type=t,f.count=s.length,lX(f)}return e}Ur.prototype.addListener=function(t,r){return m$(this,t,r,!1)};Ur.prototype.on=Ur.prototype.addListener;Ur.prototype.prependListener=function(t,r){return m$(this,t,r,!0)};function uX(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function v$(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},i=uX.bind(n);return i.listener=r,n.wrapFn=i,i}Ur.prototype.once=function(t,r){return xy(r),this.on(t,v$(this,t,r)),this};Ur.prototype.prependOnceListener=function(t,r){return xy(r),this.prependListener(t,v$(this,t,r)),this};Ur.prototype.removeListener=function(t,r){var n,i,a,s,f;if(xy(r),i=this._events,i===void 0)return this;if(n=i[t],n===void 0)return this;if(n===r||n.listener===r)--this._eventsCount===0?this._events=Object.create(null):(delete i[t],i.removeListener&&this.emit("removeListener",t,n.listener||r));else if(typeof n!="function"){for(a=-1,s=n.length-1;s>=0;s--)if(n[s]===r||n[s].listener===r){f=n[s].listener,a=s;break}if(a<0)return this;a===0?n.shift():cX(n,a),n.length===1&&(i[t]=n[0]),i.removeListener!==void 0&&this.emit("removeListener",t,f||r)}return this};Ur.prototype.off=Ur.prototype.removeListener;Ur.prototype.removeAllListeners=function(t){var r,n,i;if(n=this._events,n===void 0)return this;if(n.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):n[t]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete n[t]),this;if(arguments.length===0){var a=Object.keys(n),s;for(i=0;i=0;i--)this.removeListener(t,r[i]);return this};function g$(e,t,r){var n=e._events;if(n===void 0)return[];var i=n[t];return i===void 0?[]:typeof i=="function"?r?[i.listener||i]:[i]:r?fX(i):w$(i,i.length)}Ur.prototype.listeners=function(t){return g$(this,t,!0)};Ur.prototype.rawListeners=function(t){return g$(this,t,!1)};Ur.listenerCount=function(e,t){return typeof e.listenerCount=="function"?e.listenerCount(t):y$.call(e,t)};Ur.prototype.listenerCount=y$;function y$(e){var t=this._events;if(t!==void 0){var r=t[e];if(typeof r=="function")return 1;if(r!==void 0)return r.length}return 0}Ur.prototype.eventNames=function(){return this._eventsCount>0?Cv(this._events):[]};function w$(e,t){for(var r=new Array(t),n=0;n=i)return f;switch(f){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch{return"[Circular]"}default:return f}}),s=n[r];r=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),My(t)?r.showHidden=t:t&&t5(r,t),Ko(r.showHidden)&&(r.showHidden=!1),Ko(r.depth)&&(r.depth=2),Ko(r.colors)&&(r.colors=!1),Ko(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=mX),Ig(r,e,r.depth)}ts.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]};ts.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function mX(e,t){var r=ts.styles[t];return r?"\x1B["+ts.colors[r][0]+"m"+e+"\x1B["+ts.colors[r][1]+"m":e}function vX(e,t){return e}function gX(e){var t={};return e.forEach(function(r,n){t[r]=!0}),t}function Ig(e,t,r){if(e.customInspect&&t&&i0(t.inspect)&&t.inspect!==ts&&!(t.constructor&&t.constructor.prototype===t)){var n=t.inspect(r,e);return up(n)||(n=Ig(e,n,r)),n}var i=yX(e,t);if(i)return i;var a=Object.keys(t),s=gX(a);if(e.showHidden&&(a=Object.getOwnPropertyNames(t)),n0(t)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return b2(t);if(a.length===0){if(i0(t)){var f=t.name?": "+t.name:"";return e.stylize("[Function"+f+"]","special")}if(r0(t))return e.stylize(RegExp.prototype.toString.call(t),"regexp");if(Lg(t))return e.stylize(Date.prototype.toString.call(t),"date");if(n0(t))return b2(t)}var d="",p=!1,y=["{","}"];if(JS(t)&&(p=!0,y=["[","]"]),i0(t)){var w=t.name?": "+t.name:"";d=" [Function"+w+"]"}if(r0(t)&&(d=" "+RegExp.prototype.toString.call(t)),Lg(t)&&(d=" "+Date.prototype.toUTCString.call(t)),n0(t)&&(d=" "+b2(t)),a.length===0&&(!p||t.length==0))return y[0]+d+y[1];if(r<0)return r0(t)?e.stylize(RegExp.prototype.toString.call(t),"regexp"):e.stylize("[Object]","special");e.seen.push(t);var _;return p?_=wX(e,t,r,s,a):_=a.map(function(S){return q4(e,t,r,s,S,p)}),e.seen.pop(),bX(_,d,y)}function yX(e,t){if(Ko(t))return e.stylize("undefined","undefined");if(up(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}if(QS(t))return e.stylize(""+t,"number");if(My(t))return e.stylize(""+t,"boolean");if(lp(t))return e.stylize("null","null")}function b2(e){return"["+Error.prototype.toString.call(e)+"]"}function wX(e,t,r,n,i){for(var a=[],s=0,f=t.length;s-1&&(a?f=f.split(` `).map(function(p){return" "+p}).join(` `).substr(2):f=` `+f.split(` `).map(function(p){return" "+p}).join(` `))):f=e.stylize("[Circular]","special")),Ko(s)){if(a&&i.match(/^\d+$/))return f;s=JSON.stringify(""+i),s.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(s=s.substr(1,s.length-2),s=e.stylize(s,"name")):(s=s.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),s=e.stylize(s,"string"))}return s+": "+f}function bX(e,t,r){var n=e.reduce(function(i,a){return a.indexOf(` `)>=0,i+a.replace(/\u001b\[\d\d?m/g,"").length+1},0);return n>60?r[0]+(t===""?"":t+` `)+" "+e.join(`, `)+" "+r[1]:r[0]+t+" "+e.join(", ")+" "+r[1]}function JS(e){return Array.isArray(e)}function My(e){return typeof e=="boolean"}function lp(e){return e===null}function M$(e){return e==null}function QS(e){return typeof e=="number"}function up(e){return typeof e=="string"}function E$(e){return typeof e=="symbol"}function Ko(e){return e===void 0}function r0(e){return xc(e)&&e5(e)==="[object RegExp]"}function xc(e){return typeof e=="object"&&e!==null}function Lg(e){return xc(e)&&e5(e)==="[object Date]"}function n0(e){return xc(e)&&(e5(e)==="[object Error]"||e instanceof Error)}function i0(e){return typeof e=="function"}function k$(e){return e===null||typeof e=="boolean"||typeof e=="number"||typeof e=="string"||typeof e=="symbol"||typeof e>"u"}function T$(e){return rt.isBuffer(e)}function e5(e){return Object.prototype.toString.call(e)}function x2(e){return e<10?"0"+e.toString(10):e.toString(10)}var xX=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function _X(){var e=new Date,t=[x2(e.getHours()),x2(e.getMinutes()),x2(e.getSeconds())].join(":");return[e.getDate(),xX[e.getMonth()],t].join(" ")}function C$(){console.log("%s - %s",_X(),Sy.apply(null,arguments))}function t5(e,t){if(!t||!xc(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e}function P$(e,t){return Object.prototype.hasOwnProperty.call(e,t)}const SX={inherits:_$,_extend:t5,log:C$,isBuffer:T$,isPrimitive:k$,isFunction:i0,isError:n0,isDate:Lg,isObject:xc,isRegExp:r0,isUndefined:Ko,isSymbol:E$,isString:up,isNumber:QS,isNullOrUndefined:M$,isNull:lp,isBoolean:My,isArray:JS,inspect:ts,deprecate:ZS,format:Sy,debuglog:S$},MX=Object.freeze(Object.defineProperty({__proto__:null,_extend:t5,debuglog:S$,default:SX,deprecate:ZS,format:Sy,inherits:_$,inspect:ts,isArray:JS,isBoolean:My,isBuffer:T$,isDate:Lg,isError:n0,isFunction:i0,isNull:lp,isNullOrUndefined:M$,isNumber:QS,isObject:xc,isPrimitive:k$,isRegExp:r0,isString:up,isSymbol:E$,isUndefined:Ko,log:C$},Symbol.toStringTag,{value:"Module"})),Cd=K1(MX);var _2,Uk;function EX(){if(Uk)return _2;Uk=1;function e(M,C){var O=Object.keys(M);if(Object.getOwnPropertySymbols){var T=Object.getOwnPropertySymbols(M);C&&(T=T.filter(function(k){return Object.getOwnPropertyDescriptor(M,k).enumerable})),O.push.apply(O,T)}return O}function t(M){for(var C=1;C0?this.tail.next=T:this.head=T,this.tail=T,++this.length}},{key:"unshift",value:function(O){var T={data:O,next:this.head};this.length===0&&(this.tail=T),this.head=T,++this.length}},{key:"shift",value:function(){if(this.length!==0){var O=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,O}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(O){if(this.length===0)return"";for(var T=this.head,k=""+T.data;T=T.next;)k+=O+T.data;return k}},{key:"concat",value:function(O){if(this.length===0)return p.alloc(0);for(var T=p.allocUnsafe(O>>>0),k=this.head,R=0;k;)S(k.data,T,R),R+=k.data.length,k=k.next;return T}},{key:"consume",value:function(O,T){var k;return O$.length?$.length:O;if(L===$.length?R+=$:R+=$.slice(0,O),O-=L,O===0){L===$.length?(++k,T.next?this.head=T.next:this.head=this.tail=null):(this.head=T,T.data=$.slice(L));break}++k}return this.length-=k,R}},{key:"_getBuffer",value:function(O){var T=p.allocUnsafe(O),k=this.head,R=1;for(k.data.copy(T),O-=k.data.length;k=k.next;){var $=k.data,L=O>$.length?$.length:O;if($.copy(T,T.length-O,0,L),O-=L,O===0){L===$.length?(++R,k.next?this.head=k.next:this.head=this.tail=null):(this.head=k,k.data=$.slice(L));break}++R}return this.length-=R,T}},{key:_,value:function(O,T){return w(this,t(t({},T),{},{depth:0,customInspect:!1}))}}]),M}(),_2}function kX(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return n||i?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,Yt.nextTick(W4,this,e)):Yt.nextTick(W4,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(a){!t&&a?r._writableState?r._writableState.errorEmitted?Yt.nextTick(Pv,r):(r._writableState.errorEmitted=!0,Yt.nextTick(Hk,r,a)):Yt.nextTick(Hk,r,a):t?(Yt.nextTick(Pv,r),t(a)):Yt.nextTick(Pv,r)}),this)}function Hk(e,t){W4(e,t),Pv(e)}function Pv(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function TX(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function W4(e,t){e.emit("error",t)}function CX(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}var O$={destroy:kX,undestroy:TX,errorOrDestroy:CX},_c={};function PX(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var R$={};function Ga(e,t,r){r||(r=Error);function n(a,s,f){return typeof t=="string"?t:t(a,s,f)}var i=function(a){PX(s,a);function s(f,d,p){return a.call(this,n(f,d,p))||this}return s}(r);i.prototype.name=r.name,i.prototype.code=e,R$[e]=i}function Vk(e,t){if(Array.isArray(e)){var r=e.length;return e=e.map(function(n){return String(n)}),r>2?"one of ".concat(t," ").concat(e.slice(0,r-1).join(", "),", or ")+e[r-1]:r===2?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}else return"of ".concat(t," ").concat(String(e))}function OX(e,t,r){return e.substr(!r||r<0?0:+r,t.length)===t}function RX(e,t,r){return(r===void 0||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}function AX(e,t,r){return typeof r!="number"&&(r=0),r+t.length>e.length?!1:e.indexOf(t,r)!==-1}Ga("ERR_INVALID_OPT_VALUE",function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'},TypeError);Ga("ERR_INVALID_ARG_TYPE",function(e,t,r){var n;typeof t=="string"&&OX(t,"not ")?(n="must not be",t=t.replace(/^not /,"")):n="must be";var i;if(RX(e," argument"))i="The ".concat(e," ").concat(n," ").concat(Vk(t,"type"));else{var a=AX(e,".")?"property":"argument";i='The "'.concat(e,'" ').concat(a," ").concat(n," ").concat(Vk(t,"type"))}return i+=". Received type ".concat(typeof r),i},TypeError);Ga("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");Ga("ERR_METHOD_NOT_IMPLEMENTED",function(e){return"The "+e+" method is not implemented"});Ga("ERR_STREAM_PREMATURE_CLOSE","Premature close");Ga("ERR_STREAM_DESTROYED",function(e){return"Cannot call "+e+" after a stream was destroyed"});Ga("ERR_MULTIPLE_CALLBACK","Callback called multiple times");Ga("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");Ga("ERR_STREAM_WRITE_AFTER_END","write after end");Ga("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);Ga("ERR_UNKNOWN_ENCODING",function(e){return"Unknown encoding: "+e},TypeError);Ga("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");_c.codes=R$;var DX=_c.codes.ERR_INVALID_OPT_VALUE;function $X(e,t,r){return e.highWaterMark!=null?e.highWaterMark:t?e[r]:null}function IX(e,t,r,n){var i=$X(t,n,r);if(i!=null){if(!(isFinite(i)&&Math.floor(i)===i)||i<0){var a=n?r:"highWaterMark";throw new DX(a,i)}return Math.floor(i)}return e.objectMode?16:16*1024}var A$={getHighWaterMark:IX},LX=NX;function NX(e,t){if(S2("noDeprecation"))return e;var r=!1;function n(){if(!r){if(S2("throwDeprecation"))throw new Error(t);S2("traceDeprecation")?console.trace(t):console.warn(t),r=!0}return e.apply(this,arguments)}return n}function S2(e){try{if(!globalThis.localStorage)return!1}catch{return!1}var t=globalThis.localStorage[e];return t==null?!1:String(t).toLowerCase()==="true"}var M2,qk;function r5(){if(qk)return M2;qk=1,M2=V;function e(q){var ae=this;this.next=null,this.entry=null,this.finish=function(){ee(ae,q)}}var t;V.WritableState=j;var r={deprecate:LX},n=x$,i=mi.Buffer,a=(typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function s(q){return i.from(q)}function f(q){return i.isBuffer(q)||q instanceof a}var d=O$,p=A$,y=p.getHighWaterMark,w=_c.codes,_=w.ERR_INVALID_ARG_TYPE,S=w.ERR_METHOD_NOT_IMPLEMENTED,M=w.ERR_MULTIPLE_CALLBACK,C=w.ERR_STREAM_CANNOT_PIPE,O=w.ERR_STREAM_DESTROYED,T=w.ERR_STREAM_NULL_VALUES,k=w.ERR_STREAM_WRITE_AFTER_END,R=w.ERR_UNKNOWN_ENCODING,$=d.errorOrDestroy;or(V,n);function L(){}function j(q,ae,pe){t=t||sc(),q=q||{},typeof pe!="boolean"&&(pe=ae instanceof t),this.objectMode=!!q.objectMode,pe&&(this.objectMode=this.objectMode||!!q.writableObjectMode),this.highWaterMark=y(this,q,"writableHighWaterMark",pe),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var we=q.decodeStrings===!1;this.decodeStrings=!we,this.defaultEncoding=q.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(Se){g(ae,Se)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=q.emitClose!==!1,this.autoDestroy=!!q.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new e(this)}j.prototype.getBuffer=function(){for(var ae=this.bufferedRequest,pe=[];ae;)pe.push(ae),ae=ae.next;return pe},function(){try{Object.defineProperty(j.prototype,"buffer",{get:r.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var A;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(A=Function.prototype[Symbol.hasInstance],Object.defineProperty(V,Symbol.hasInstance,{value:function(ae){return A.call(this,ae)?!0:this!==V?!1:ae&&ae._writableState instanceof j}})):A=function(ae){return ae instanceof this};function V(q){t=t||sc();var ae=this instanceof t;if(!ae&&!A.call(V,this))return new V(q);this._writableState=new j(q,this,ae),this.writable=!0,q&&(typeof q.write=="function"&&(this._write=q.write),typeof q.writev=="function"&&(this._writev=q.writev),typeof q.destroy=="function"&&(this._destroy=q.destroy),typeof q.final=="function"&&(this._final=q.final)),n.call(this)}V.prototype.pipe=function(){$(this,new C)};function z(q,ae){var pe=new k;$(q,pe),Yt.nextTick(ae,pe)}function Y(q,ae,pe,we){var Se;return pe===null?Se=new T:typeof pe!="string"&&!ae.objectMode&&(Se=new _("chunk",["string","Buffer"],pe)),Se?($(q,Se),Yt.nextTick(we,Se),!1):!0}V.prototype.write=function(q,ae,pe){var we=this._writableState,Se=!1,he=!we.objectMode&&f(q);return he&&!i.isBuffer(q)&&(q=s(q)),typeof ae=="function"&&(pe=ae,ae=null),he?ae="buffer":ae||(ae=we.defaultEncoding),typeof pe!="function"&&(pe=L),we.ending?z(this,pe):(he||Y(this,we,q,pe))&&(we.pendingcb++,Se=o(this,we,he,q,ae,pe)),Se},V.prototype.cork=function(){this._writableState.corked++},V.prototype.uncork=function(){var q=this._writableState;q.corked&&(q.corked--,!q.writing&&!q.corked&&!q.bufferProcessing&&q.bufferedRequest&&v(this,q))},V.prototype.setDefaultEncoding=function(ae){if(typeof ae=="string"&&(ae=ae.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((ae+"").toLowerCase())>-1))throw new R(ae);return this._writableState.defaultEncoding=ae,this},Object.defineProperty(V.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function b(q,ae,pe){return!q.objectMode&&q.decodeStrings!==!1&&typeof ae=="string"&&(ae=i.from(ae,pe)),ae}Object.defineProperty(V.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function o(q,ae,pe,we,Se,he){if(!pe){var re=b(ae,we,Se);we!==re&&(pe=!0,Se="buffer",we=re)}var _e=ae.objectMode?1:we.length;ae.length+=_e;var W=ae.length>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}function FX(e,t,r){var n=t.length-1;if(n=0?(i>0&&(e.lastNeed=i-1),i):--n=0?(i>0&&(e.lastNeed=i-2),i):--n=0?(i>0&&(i===2?i=0:e.lastNeed=i-3),i):0))}function zX(e,t,r){if((t[0]&192)!==128)return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if((t[1]&192)!==128)return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&(t[2]&192)!==128)return e.lastNeed=2,"�"}}function UX(e){var t=this.lastTotal-this.lastNeed,r=zX(this,e);if(r!==void 0)return r;if(this.lastNeed<=e.length)return e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length}function HX(e,t){var r=FX(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)}function VX(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�":t}function qX(e,t){if((e.length-t)%2===0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function WX(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function KX(e,t){var r=(e.length-t)%3;return r===0?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function GX(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function YX(e){return e.toString(this.encoding)}function XX(e){return e&&e.length?this.write(e):""}var Gk=_c.codes.ERR_STREAM_PREMATURE_CLOSE;function ZX(e){var t=!1;return function(){if(!t){t=!0;for(var r=arguments.length,n=new Array(r),i=0;i0)if(typeof re!="string"&&!Z.objectMode&&Object.getPrototypeOf(re)!==n.prototype&&(re=a(re)),W)Z.endEmitted?L(he,new T):b(he,Z,re,!0);else if(Z.ended)L(he,new C);else{if(Z.destroyed)return!1;Z.reading=!1,Z.decoder&&!_e?(re=Z.decoder.write(re),Z.objectMode||re.length!==0?b(he,Z,re,!1):v(he,Z)):b(he,Z,re,!1)}else W||(Z.reading=!1,v(he,Z))}return!Z.ended&&(Z.length=u?he=u:(he--,he|=he>>>1,he|=he>>>2,he|=he>>>4,he|=he>>>8,he|=he>>>16,he++),he}function h(he,re){return he<=0||re.length===0&&re.ended?0:re.objectMode?1:he!==he?re.flowing&&re.length?re.buffer.head.data.length:re.length:(he>re.highWaterMark&&(re.highWaterMark=c(he)),he<=re.length?he:re.ended?re.length:(re.needReadable=!0,0))}z.prototype.read=function(he){d("read",he),he=parseInt(he,10);var re=this._readableState,_e=he;if(he!==0&&(re.emittedReadable=!1),he===0&&re.needReadable&&((re.highWaterMark!==0?re.length>=re.highWaterMark:re.length>0)||re.ended))return d("read: emitReadable",re.length,re.ended),re.length===0&&re.ended?pe(this):x(this),null;if(he=h(he,re),he===0&&re.ended)return re.length===0&&pe(this),null;var W=re.needReadable;d("need readable",W),(re.length===0||re.length-he0?ve=ae(he,re):ve=null,ve===null?(re.needReadable=re.length<=re.highWaterMark,he=0):(re.length-=he,re.awaitDrain=0),re.length===0&&(re.ended||(re.needReadable=!0),_e!==he&&re.ended&&pe(this)),ve!==null&&this.emit("data",ve),ve};function g(he,re){if(d("onEofChunk"),!re.ended){if(re.decoder){var _e=re.decoder.end();_e&&_e.length&&(re.buffer.push(_e),re.length+=re.objectMode?1:_e.length)}re.ended=!0,re.sync?x(he):(re.needReadable=!1,re.emittedReadable||(re.emittedReadable=!0,E(he)))}}function x(he){var re=he._readableState;d("emitReadable",re.needReadable,re.emittedReadable),re.needReadable=!1,re.emittedReadable||(d("emitReadable",re.flowing),re.emittedReadable=!0,Yt.nextTick(E,he))}function E(he){var re=he._readableState;d("emitReadable_",re.destroyed,re.length,re.ended),!re.destroyed&&(re.length||re.ended)&&(he.emit("readable"),re.emittedReadable=!1),re.needReadable=!re.flowing&&!re.ended&&re.length<=re.highWaterMark,q(he)}function v(he,re){re.readingMore||(re.readingMore=!0,Yt.nextTick(l,he,re))}function l(he,re){for(;!re.reading&&!re.ended&&(re.length1&&Se(W.pipes,he)!==-1)&&!xe&&(d("false write response, pause",W.awaitDrain),W.awaitDrain++),_e.pause())}function Ae(Oe){d("onerror",Oe),tt(),he.removeListener("error",Ae),t(he,"error")===0&&L(he,Oe)}A(he,"error",Ae);function ye(){he.removeListener("finish",be),tt()}he.once("close",ye);function be(){d("onfinish"),he.removeListener("close",ye),tt()}he.once("finish",be);function tt(){d("unpipe"),_e.unpipe(he)}return he.emit("pipe",_e),W.flowing||(d("pipe resume"),_e.resume()),he};function m(he){return function(){var _e=he._readableState;d("pipeOnDrain",_e.awaitDrain),_e.awaitDrain&&_e.awaitDrain--,_e.awaitDrain===0&&t(he,"data")&&(_e.flowing=!0,q(he))}}z.prototype.unpipe=function(he){var re=this._readableState,_e={hasUnpiped:!1};if(re.pipesCount===0)return this;if(re.pipesCount===1)return he&&he!==re.pipes?this:(he||(he=re.pipes),re.pipes=null,re.pipesCount=0,re.flowing=!1,he&&he.emit("unpipe",this,_e),this);if(!he){var W=re.pipes,ve=re.pipesCount;re.pipes=null,re.pipesCount=0,re.flowing=!1;for(var Z=0;Z0,W.flowing!==!1&&this.resume()):he==="readable"&&!W.endEmitted&&!W.readableListening&&(W.readableListening=W.needReadable=!0,W.flowing=!1,W.emittedReadable=!1,d("on readable",W.length,W.reading),W.length?x(this):W.reading||Yt.nextTick(N,this)),_e},z.prototype.addListener=z.prototype.on,z.prototype.removeListener=function(he,re){var _e=r.prototype.removeListener.call(this,he,re);return he==="readable"&&Yt.nextTick(P,this),_e},z.prototype.removeAllListeners=function(he){var re=r.prototype.removeAllListeners.apply(this,arguments);return(he==="readable"||he===void 0)&&Yt.nextTick(P,this),re};function P(he){var re=he._readableState;re.readableListening=he.listenerCount("readable")>0,re.resumeScheduled&&!re.paused?re.flowing=!0:he.listenerCount("data")>0&&he.resume()}function N(he){d("readable nexttick read 0"),he.read(0)}z.prototype.resume=function(){var he=this._readableState;return he.flowing||(d("resume"),he.flowing=!he.readableListening,F(this,he)),he.paused=!1,this};function F(he,re){re.resumeScheduled||(re.resumeScheduled=!0,Yt.nextTick(ee,he,re))}function ee(he,re){d("resume",re.reading),re.reading||he.read(0),re.resumeScheduled=!1,he.emit("resume"),q(he),re.flowing&&!re.reading&&he.read(0)}z.prototype.pause=function(){return d("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(d("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function q(he){var re=he._readableState;for(d("flow",re.flowing);re.flowing&&he.read()!==null;);}z.prototype.wrap=function(he){var re=this,_e=this._readableState,W=!1;he.on("end",function(){if(d("wrapped end"),_e.decoder&&!_e.ended){var ne=_e.decoder.end();ne&&ne.length&&re.push(ne)}re.push(null)}),he.on("data",function(ne){if(d("wrapped data"),_e.decoder&&(ne=_e.decoder.write(ne)),!(_e.objectMode&&ne==null)&&!(!_e.objectMode&&(!ne||!ne.length))){var K=re.push(ne);K||(W=!0,he.pause())}});for(var ve in he)this[ve]===void 0&&typeof he[ve]=="function"&&(this[ve]=function(K){return function(){return he[K].apply(he,arguments)}}(ve));for(var Z=0;Z=re.length?(re.decoder?_e=re.buffer.join(""):re.buffer.length===1?_e=re.buffer.first():_e=re.buffer.concat(re.length),re.buffer.clear()):_e=re.buffer.consume(he,re.decoder),_e}function pe(he){var re=he._readableState;d("endReadable",re.endEmitted),re.endEmitted||(re.ended=!0,Yt.nextTick(we,re,he))}function we(he,re){if(d("endReadableNT",he.endEmitted,he.length),!he.endEmitted&&he.length===0&&(he.endEmitted=!0,re.readable=!1,re.emit("end"),he.autoDestroy)){var _e=re._writableState;(!_e||_e.autoDestroy&&_e.finished)&&re.destroy()}}typeof Symbol=="function"&&(z.from=function(he,re){return $===void 0&&($=tZ()),$(z,he,re)});function Se(he,re){for(var _e=0,W=he.length;_e0;return dZ(s,d,p,function(y){i||(i=y),y&&a.forEach(eT),!d&&(a.forEach(eT),n(i))})});return t.reduce(hZ)}var N$=mZ;(function(e,t){t=e.exports=i5(),t.Stream=t,t.Readable=t,t.Writable=r5(),t.Duplex=sc(),t.Transform=a5,t.PassThrough=$$,t.finished=Ey,t.pipeline=N$})(H4,H4.exports);var j$=H4.exports,jg=Jt.Buffer,B$=j$.Transform,vZ=or;function gZ(e,t){if(!jg.isBuffer(e)&&typeof e!="string")throw new TypeError(t+" must be a string or a buffer")}function fu(e){B$.call(this),this._block=jg.allocUnsafe(e),this._blockSize=e,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}vZ(fu,B$);fu.prototype._transform=function(e,t,r){var n=null;try{this.update(e,t)}catch(i){n=i}r(n)};fu.prototype._flush=function(e){var t=null;try{this.push(this.digest())}catch(r){t=r}e(t)};fu.prototype.update=function(e,t){if(gZ(e,"Data"),this._finalized)throw new Error("Digest already called");jg.isBuffer(e)||(e=jg.from(e,t));for(var r=this._block,n=0;this._blockOffset+e.length-n>=this._blockSize;){for(var i=this._blockOffset;i0;++a)this._length[a]+=s,s=this._length[a]/4294967296|0,s>0&&(this._length[a]-=4294967296*s);return this};fu.prototype._update=function(){throw new Error("_update is not implemented")};fu.prototype.digest=function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var t=this._digest();e!==void 0&&(t=t.toString(e)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return t};fu.prototype._digest=function(){throw new Error("_digest is not implemented")};var F$=fu,yZ=or,z$=F$,wZ=Jt.Buffer,bZ=new Array(16);function Cy(){z$.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}yZ(Cy,z$);Cy.prototype._update=function(){for(var e=bZ,t=0;t<16;++t)e[t]=this._block.readInt32LE(t*4);var r=this._a,n=this._b,i=this._c,a=this._d;r=ii(r,n,i,a,e[0],3614090360,7),a=ii(a,r,n,i,e[1],3905402710,12),i=ii(i,a,r,n,e[2],606105819,17),n=ii(n,i,a,r,e[3],3250441966,22),r=ii(r,n,i,a,e[4],4118548399,7),a=ii(a,r,n,i,e[5],1200080426,12),i=ii(i,a,r,n,e[6],2821735955,17),n=ii(n,i,a,r,e[7],4249261313,22),r=ii(r,n,i,a,e[8],1770035416,7),a=ii(a,r,n,i,e[9],2336552879,12),i=ii(i,a,r,n,e[10],4294925233,17),n=ii(n,i,a,r,e[11],2304563134,22),r=ii(r,n,i,a,e[12],1804603682,7),a=ii(a,r,n,i,e[13],4254626195,12),i=ii(i,a,r,n,e[14],2792965006,17),n=ii(n,i,a,r,e[15],1236535329,22),r=ai(r,n,i,a,e[1],4129170786,5),a=ai(a,r,n,i,e[6],3225465664,9),i=ai(i,a,r,n,e[11],643717713,14),n=ai(n,i,a,r,e[0],3921069994,20),r=ai(r,n,i,a,e[5],3593408605,5),a=ai(a,r,n,i,e[10],38016083,9),i=ai(i,a,r,n,e[15],3634488961,14),n=ai(n,i,a,r,e[4],3889429448,20),r=ai(r,n,i,a,e[9],568446438,5),a=ai(a,r,n,i,e[14],3275163606,9),i=ai(i,a,r,n,e[3],4107603335,14),n=ai(n,i,a,r,e[8],1163531501,20),r=ai(r,n,i,a,e[13],2850285829,5),a=ai(a,r,n,i,e[2],4243563512,9),i=ai(i,a,r,n,e[7],1735328473,14),n=ai(n,i,a,r,e[12],2368359562,20),r=oi(r,n,i,a,e[5],4294588738,4),a=oi(a,r,n,i,e[8],2272392833,11),i=oi(i,a,r,n,e[11],1839030562,16),n=oi(n,i,a,r,e[14],4259657740,23),r=oi(r,n,i,a,e[1],2763975236,4),a=oi(a,r,n,i,e[4],1272893353,11),i=oi(i,a,r,n,e[7],4139469664,16),n=oi(n,i,a,r,e[10],3200236656,23),r=oi(r,n,i,a,e[13],681279174,4),a=oi(a,r,n,i,e[0],3936430074,11),i=oi(i,a,r,n,e[3],3572445317,16),n=oi(n,i,a,r,e[6],76029189,23),r=oi(r,n,i,a,e[9],3654602809,4),a=oi(a,r,n,i,e[12],3873151461,11),i=oi(i,a,r,n,e[15],530742520,16),n=oi(n,i,a,r,e[2],3299628645,23),r=si(r,n,i,a,e[0],4096336452,6),a=si(a,r,n,i,e[7],1126891415,10),i=si(i,a,r,n,e[14],2878612391,15),n=si(n,i,a,r,e[5],4237533241,21),r=si(r,n,i,a,e[12],1700485571,6),a=si(a,r,n,i,e[3],2399980690,10),i=si(i,a,r,n,e[10],4293915773,15),n=si(n,i,a,r,e[1],2240044497,21),r=si(r,n,i,a,e[8],1873313359,6),a=si(a,r,n,i,e[15],4264355552,10),i=si(i,a,r,n,e[6],2734768916,15),n=si(n,i,a,r,e[13],1309151649,21),r=si(r,n,i,a,e[4],4149444226,6),a=si(a,r,n,i,e[11],3174756917,10),i=si(i,a,r,n,e[2],718787259,15),n=si(n,i,a,r,e[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+n|0,this._c=this._c+i|0,this._d=this._d+a|0};Cy.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var e=wZ.allocUnsafe(16);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e};function Py(e,t){return e<>>32-t}function ii(e,t,r,n,i,a,s){return Py(e+(t&r|~t&n)+i+a|0,s)+t|0}function ai(e,t,r,n,i,a,s){return Py(e+(t&n|r&~n)+i+a|0,s)+t|0}function oi(e,t,r,n,i,a,s){return Py(e+(t^r^n)+i+a|0,s)+t|0}function si(e,t,r,n,i,a,s){return Py(e+(r^(t|~n))+i+a|0,s)+t|0}var o5=Cy,R2=mi.Buffer,xZ=or,U$=F$,_Z=new Array(16),vh=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],gh=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],yh=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],wh=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],bh=[0,1518500249,1859775393,2400959708,2840853838],xh=[1352829926,1548603684,1836072691,2053994217,0];function Oy(){U$.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}xZ(Oy,U$);Oy.prototype._update=function(){for(var e=_Z,t=0;t<16;++t)e[t]=this._block.readInt32LE(t*4);for(var r=this._a|0,n=this._b|0,i=this._c|0,a=this._d|0,s=this._e|0,f=this._a|0,d=this._b|0,p=this._c|0,y=this._d|0,w=this._e|0,_=0;_<80;_+=1){var S,M;_<16?(S=tT(r,n,i,a,s,e[vh[_]],bh[0],yh[_]),M=aT(f,d,p,y,w,e[gh[_]],xh[0],wh[_])):_<32?(S=rT(r,n,i,a,s,e[vh[_]],bh[1],yh[_]),M=iT(f,d,p,y,w,e[gh[_]],xh[1],wh[_])):_<48?(S=nT(r,n,i,a,s,e[vh[_]],bh[2],yh[_]),M=nT(f,d,p,y,w,e[gh[_]],xh[2],wh[_])):_<64?(S=iT(r,n,i,a,s,e[vh[_]],bh[3],yh[_]),M=rT(f,d,p,y,w,e[gh[_]],xh[3],wh[_])):(S=aT(r,n,i,a,s,e[vh[_]],bh[4],yh[_]),M=tT(f,d,p,y,w,e[gh[_]],xh[4],wh[_])),r=s,s=a,a=lc(i,10),i=n,n=S,f=w,w=y,y=lc(p,10),p=d,d=M}var C=this._b+i+y|0;this._b=this._c+a+w|0,this._c=this._d+s+f|0,this._d=this._e+r+d|0,this._e=this._a+n+p|0,this._a=C};Oy.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var e=R2.alloc?R2.alloc(20):new R2(20);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e.writeInt32LE(this._e,16),e};function lc(e,t){return e<>>32-t}function tT(e,t,r,n,i,a,s,f){return lc(e+(t^r^n)+a+s|0,f)+i|0}function rT(e,t,r,n,i,a,s,f){return lc(e+(t&r|~t&n)+a+s|0,f)+i|0}function nT(e,t,r,n,i,a,s,f){return lc(e+((t|~r)^n)+a+s|0,f)+i|0}function iT(e,t,r,n,i,a,s,f){return lc(e+(t&n|r&~n)+a+s|0,f)+i|0}function aT(e,t,r,n,i,a,s,f){return lc(e+(t^(r|~n))+a+s|0,f)+i|0}var s5=Oy,H$={exports:{}},V$=Jt.Buffer;function Ry(e,t){this._block=V$.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}Ry.prototype.update=function(e,t){typeof e=="string"&&(t=t||"utf8",e=V$.from(e,t));for(var r=this._block,n=this._blockSize,i=e.length,a=this._len,s=0;s=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=this._len*8;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(r&4294967295)>>>0,i=(r-n)/4294967296;this._block.writeUInt32BE(i,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var a=this._hash();return e?a.toString(e):a};Ry.prototype._update=function(){throw new Error("_update must be implemented by subclass")};var Pd=Ry,SZ=or,q$=Pd,MZ=Jt.Buffer,EZ=[1518500249,1859775393,-1894007588,-899497514],kZ=new Array(80);function fp(){this.init(),this._w=kZ,q$.call(this,64,56)}SZ(fp,q$);fp.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function TZ(e){return e<<5|e>>>27}function CZ(e){return e<<30|e>>>2}function PZ(e,t,r,n){return e===0?t&r|~t&n:e===2?t&r|t&n|r&n:t^r^n}fp.prototype._update=function(e){for(var t=this._w,r=this._a|0,n=this._b|0,i=this._c|0,a=this._d|0,s=this._e|0,f=0;f<16;++f)t[f]=e.readInt32BE(f*4);for(;f<80;++f)t[f]=t[f-3]^t[f-8]^t[f-14]^t[f-16];for(var d=0;d<80;++d){var p=~~(d/20),y=TZ(r)+PZ(p,n,i,a)+s+t[d]+EZ[p]|0;s=a,a=i,i=CZ(n),n=r,r=y}this._a=r+this._a|0,this._b=n+this._b|0,this._c=i+this._c|0,this._d=a+this._d|0,this._e=s+this._e|0};fp.prototype._hash=function(){var e=MZ.allocUnsafe(20);return e.writeInt32BE(this._a|0,0),e.writeInt32BE(this._b|0,4),e.writeInt32BE(this._c|0,8),e.writeInt32BE(this._d|0,12),e.writeInt32BE(this._e|0,16),e};var OZ=fp,RZ=or,W$=Pd,AZ=Jt.Buffer,DZ=[1518500249,1859775393,-1894007588,-899497514],$Z=new Array(80);function dp(){this.init(),this._w=$Z,W$.call(this,64,56)}RZ(dp,W$);dp.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function IZ(e){return e<<1|e>>>31}function LZ(e){return e<<5|e>>>27}function NZ(e){return e<<30|e>>>2}function jZ(e,t,r,n){return e===0?t&r|~t&n:e===2?t&r|t&n|r&n:t^r^n}dp.prototype._update=function(e){for(var t=this._w,r=this._a|0,n=this._b|0,i=this._c|0,a=this._d|0,s=this._e|0,f=0;f<16;++f)t[f]=e.readInt32BE(f*4);for(;f<80;++f)t[f]=IZ(t[f-3]^t[f-8]^t[f-14]^t[f-16]);for(var d=0;d<80;++d){var p=~~(d/20),y=LZ(r)+jZ(p,n,i,a)+s+t[d]+DZ[p]|0;s=a,a=i,i=NZ(n),n=r,r=y}this._a=r+this._a|0,this._b=n+this._b|0,this._c=i+this._c|0,this._d=a+this._d|0,this._e=s+this._e|0};dp.prototype._hash=function(){var e=AZ.allocUnsafe(20);return e.writeInt32BE(this._a|0,0),e.writeInt32BE(this._b|0,4),e.writeInt32BE(this._c|0,8),e.writeInt32BE(this._d|0,12),e.writeInt32BE(this._e|0,16),e};var BZ=dp,FZ=or,K$=Pd,zZ=Jt.Buffer,UZ=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],HZ=new Array(64);function hp(){this.init(),this._w=HZ,K$.call(this,64,56)}FZ(hp,K$);hp.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this};function VZ(e,t,r){return r^e&(t^r)}function qZ(e,t,r){return e&t|r&(e|t)}function WZ(e){return(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function KZ(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function GZ(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}function YZ(e){return(e>>>17|e<<15)^(e>>>19|e<<13)^e>>>10}hp.prototype._update=function(e){for(var t=this._w,r=this._a|0,n=this._b|0,i=this._c|0,a=this._d|0,s=this._e|0,f=this._f|0,d=this._g|0,p=this._h|0,y=0;y<16;++y)t[y]=e.readInt32BE(y*4);for(;y<64;++y)t[y]=YZ(t[y-2])+t[y-7]+GZ(t[y-15])+t[y-16]|0;for(var w=0;w<64;++w){var _=p+KZ(s)+VZ(s,f,d)+UZ[w]+t[w]|0,S=WZ(r)+qZ(r,n,i)|0;p=d,d=f,f=s,s=a+_|0,a=i,i=n,n=r,r=_+S|0}this._a=r+this._a|0,this._b=n+this._b|0,this._c=i+this._c|0,this._d=a+this._d|0,this._e=s+this._e|0,this._f=f+this._f|0,this._g=d+this._g|0,this._h=p+this._h|0};hp.prototype._hash=function(){var e=zZ.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e};var G$=hp,XZ=or,ZZ=G$,JZ=Pd,QZ=Jt.Buffer,eJ=new Array(64);function Ay(){this.init(),this._w=eJ,JZ.call(this,64,56)}XZ(Ay,ZZ);Ay.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this};Ay.prototype._hash=function(){var e=QZ.allocUnsafe(28);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e};var tJ=Ay,rJ=or,Y$=Pd,nJ=Jt.Buffer,oT=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],iJ=new Array(160);function pp(){this.init(),this._w=iJ,Y$.call(this,128,112)}rJ(pp,Y$);pp.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this};function sT(e,t,r){return r^e&(t^r)}function lT(e,t,r){return e&t|r&(e|t)}function uT(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function cT(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function aJ(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function oJ(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function sJ(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function lJ(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function Dn(e,t){return e>>>0>>0?1:0}pp.prototype._update=function(e){for(var t=this._w,r=this._ah|0,n=this._bh|0,i=this._ch|0,a=this._dh|0,s=this._eh|0,f=this._fh|0,d=this._gh|0,p=this._hh|0,y=this._al|0,w=this._bl|0,_=this._cl|0,S=this._dl|0,M=this._el|0,C=this._fl|0,O=this._gl|0,T=this._hl|0,k=0;k<32;k+=2)t[k]=e.readInt32BE(k*4),t[k+1]=e.readInt32BE(k*4+4);for(;k<160;k+=2){var R=t[k-30],$=t[k-15*2+1],L=aJ(R,$),j=oJ($,R);R=t[k-2*2],$=t[k-2*2+1];var A=sJ(R,$),V=lJ($,R),z=t[k-7*2],Y=t[k-7*2+1],b=t[k-16*2],o=t[k-16*2+1],u=j+Y|0,c=L+z+Dn(u,j)|0;u=u+V|0,c=c+A+Dn(u,V)|0,u=u+o|0,c=c+b+Dn(u,o)|0,t[k]=c,t[k+1]=u}for(var h=0;h<160;h+=2){c=t[h],u=t[h+1];var g=lT(r,n,i),x=lT(y,w,_),E=uT(r,y),v=uT(y,r),l=cT(s,M),m=cT(M,s),P=oT[h],N=oT[h+1],F=sT(s,f,d),ee=sT(M,C,O),q=T+m|0,ae=p+l+Dn(q,T)|0;q=q+ee|0,ae=ae+F+Dn(q,ee)|0,q=q+N|0,ae=ae+P+Dn(q,N)|0,q=q+u|0,ae=ae+c+Dn(q,u)|0;var pe=v+x|0,we=E+g+Dn(pe,v)|0;p=d,T=O,d=f,O=C,f=s,C=M,M=S+q|0,s=a+ae+Dn(M,S)|0,a=i,S=_,i=n,_=w,n=r,w=y,y=q+pe|0,r=ae+we+Dn(y,q)|0}this._al=this._al+y|0,this._bl=this._bl+w|0,this._cl=this._cl+_|0,this._dl=this._dl+S|0,this._el=this._el+M|0,this._fl=this._fl+C|0,this._gl=this._gl+O|0,this._hl=this._hl+T|0,this._ah=this._ah+r+Dn(this._al,y)|0,this._bh=this._bh+n+Dn(this._bl,w)|0,this._ch=this._ch+i+Dn(this._cl,_)|0,this._dh=this._dh+a+Dn(this._dl,S)|0,this._eh=this._eh+s+Dn(this._el,M)|0,this._fh=this._fh+f+Dn(this._fl,C)|0,this._gh=this._gh+d+Dn(this._gl,O)|0,this._hh=this._hh+p+Dn(this._hl,T)|0};pp.prototype._hash=function(){var e=nJ.allocUnsafe(64);function t(r,n,i){e.writeInt32BE(r,i),e.writeInt32BE(n,i+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),t(this._gh,this._gl,48),t(this._hh,this._hl,56),e};var X$=pp,uJ=or,cJ=X$,fJ=Pd,dJ=Jt.Buffer,hJ=new Array(160);function Dy(){this.init(),this._w=hJ,fJ.call(this,128,112)}uJ(Dy,cJ);Dy.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this};Dy.prototype._hash=function(){var e=dJ.allocUnsafe(48);function t(r,n,i){e.writeInt32BE(r,i),e.writeInt32BE(n,i+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),e};var pJ=Dy,Sc=H$.exports=function(t){t=t.toLowerCase();var r=Sc[t];if(!r)throw new Error(t+" is not supported (we accept pull requests)");return new r};Sc.sha=OZ;Sc.sha1=BZ;Sc.sha224=tJ;Sc.sha256=G$;Sc.sha384=pJ;Sc.sha512=X$;var l5=H$.exports,mp=Ua,u5=_y.EventEmitter,mJ=or;mJ(Ua,u5);Ua.Readable=i5();Ua.Writable=r5();Ua.Duplex=sc();Ua.Transform=a5;Ua.PassThrough=$$;Ua.finished=Ey;Ua.pipeline=N$;Ua.Stream=Ua;function Ua(){u5.call(this)}Ua.prototype.pipe=function(e,t){var r=this;function n(y){e.writable&&e.write(y)===!1&&r.pause&&r.pause()}r.on("data",n);function i(){r.readable&&r.resume&&r.resume()}e.on("drain",i),!e._isStdio&&(!t||t.end!==!1)&&(r.on("end",s),r.on("close",f));var a=!1;function s(){a||(a=!0,e.end())}function f(){a||(a=!0,typeof e.destroy=="function"&&e.destroy())}function d(y){if(p(),u5.listenerCount(this,"error")===0)throw y}r.on("error",d),e.on("error",d);function p(){r.removeListener("data",n),e.removeListener("drain",i),r.removeListener("end",s),r.removeListener("close",f),r.removeListener("error",d),e.removeListener("error",d),r.removeListener("end",p),r.removeListener("close",p),e.removeListener("close",p)}return r.on("end",p),r.on("close",p),e.on("close",p),e.emit("pipe",r),e};const BTe=Ci(mp);var Z$=Jt.Buffer,J$=mp.Transform,vJ=Ng.StringDecoder,gJ=or;function Mo(e){J$.call(this),this.hashMode=typeof e=="string",this.hashMode?this[e]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}gJ(Mo,J$);Mo.prototype.update=function(e,t,r){typeof e=="string"&&(e=Z$.from(e,t));var n=this._update(e);return this.hashMode?this:(r&&(n=this._toString(n,r)),n)};Mo.prototype.setAutoPadding=function(){};Mo.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")};Mo.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")};Mo.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")};Mo.prototype._transform=function(e,t,r){var n;try{this.hashMode?this._update(e):this.push(this._update(e))}catch(i){n=i}finally{r(n)}};Mo.prototype._flush=function(e){var t;try{this.push(this.__final())}catch(r){t=r}e(t)};Mo.prototype._finalOrDigest=function(e){var t=this.__final()||Z$.alloc(0);return e&&(t=this._toString(t,e,!0)),t};Mo.prototype._toString=function(e,t,r){if(this._decoder||(this._decoder=new vJ(t),this._encoding=t),this._encoding!==t)throw new Error("can't switch encodings");var n=this._decoder.write(e);return r&&(n+=this._decoder.end()),n};var du=Mo,yJ=or,wJ=o5,bJ=s5,xJ=l5,Q$=du;function $y(e){Q$.call(this,"digest"),this._hash=e}yJ($y,Q$);$y.prototype._update=function(e){this._hash.update(e)};$y.prototype._final=function(){return this._hash.digest()};var vp=function(t){return t=t.toLowerCase(),t==="md5"?new wJ:t==="rmd160"||t==="ripemd160"?new bJ:new $y(xJ(t))},_J=or,qu=Jt.Buffer,eI=du,SJ=qu.alloc(128),Dc=64;function Iy(e,t){eI.call(this,"digest"),typeof t=="string"&&(t=qu.from(t)),this._alg=e,this._key=t,t.length>Dc?t=e(t):t.lengthr){var n=e==="rmd160"?new K4:G4(e);t=n.update(t).digest()}else t.lengthUJ||t!==t)throw new TypeError("Bad key length")},Ov;if(globalThis.process&&globalThis.process.browser)Ov="utf-8";else if(globalThis.process&&globalThis.process.version){var HJ=parseInt(Yt.version.split(".")[0].slice(1),10);Ov=HJ>=6?"utf-8":"binary"}else Ov="utf-8";var oI=Ov,A2=Jt.Buffer,sI=function(e,t,r){if(A2.isBuffer(e))return e;if(typeof e=="string")return A2.from(e,t);if(ArrayBuffer.isView(e))return A2.from(e.buffer);throw new TypeError(r+" must be a string, a Buffer, a typed array or a DataView")},VJ=tI,qJ=s5,WJ=l5,Wu=Jt.Buffer,KJ=aI,fT=oI,dT=sI,GJ=Wu.alloc(128),Rv={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function lI(e,t,r){var n=YJ(e),i=e==="sha512"||e==="sha384"?128:64;t.length>i?t=n(t):t.length>>0};ma.writeUInt32BE=function(t,r,n){t[0+n]=r>>>24,t[1+n]=r>>>16&255,t[2+n]=r>>>8&255,t[3+n]=r&255};ma.ip=function(t,r,n,i){for(var a=0,s=0,f=6;f>=0;f-=2){for(var d=0;d<=24;d+=8)a<<=1,a|=r>>>d+f&1;for(var d=0;d<=24;d+=8)a<<=1,a|=t>>>d+f&1}for(var f=6;f>=0;f-=2){for(var d=1;d<=25;d+=8)s<<=1,s|=r>>>d+f&1;for(var d=1;d<=25;d+=8)s<<=1,s|=t>>>d+f&1}n[i+0]=a>>>0,n[i+1]=s>>>0};ma.rip=function(t,r,n,i){for(var a=0,s=0,f=0;f<4;f++)for(var d=24;d>=0;d-=8)a<<=1,a|=r>>>d+f&1,a<<=1,a|=t>>>d+f&1;for(var f=4;f<8;f++)for(var d=24;d>=0;d-=8)s<<=1,s|=r>>>d+f&1,s<<=1,s|=t>>>d+f&1;n[i+0]=a>>>0,n[i+1]=s>>>0};ma.pc1=function(t,r,n,i){for(var a=0,s=0,f=7;f>=5;f--){for(var d=0;d<=24;d+=8)a<<=1,a|=r>>d+f&1;for(var d=0;d<=24;d+=8)a<<=1,a|=t>>d+f&1}for(var d=0;d<=24;d+=8)a<<=1,a|=r>>d+f&1;for(var f=1;f<=3;f++){for(var d=0;d<=24;d+=8)s<<=1,s|=r>>d+f&1;for(var d=0;d<=24;d+=8)s<<=1,s|=t>>d+f&1}for(var d=0;d<=24;d+=8)s<<=1,s|=t>>d+f&1;n[i+0]=a>>>0,n[i+1]=s>>>0};ma.r28shl=function(t,r){return t<>>28-r};var Im=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];ma.pc2=function(t,r,n,i){for(var a=0,s=0,f=Im.length>>>1,d=0;d>>Im[d]&1;for(var d=f;d>>Im[d]&1;n[i+0]=a>>>0,n[i+1]=s>>>0};ma.expand=function(t,r,n){var i=0,a=0;i=(t&1)<<5|t>>>27;for(var s=23;s>=15;s-=4)i<<=6,i|=t>>>s&63;for(var s=11;s>=3;s-=4)a|=t>>>s&63,a<<=6;a|=(t&31)<<1|t>>>31,r[n+0]=i>>>0,r[n+1]=a>>>0};var vT=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];ma.substitute=function(t,r){for(var n=0,i=0;i<4;i++){var a=t>>>18-i*6&63,s=vT[i*64+a];n<<=4,n|=s}for(var i=0;i<4;i++){var a=r>>>18-i*6&63,s=vT[4*64+i*64+a];n<<=4,n|=s}return n>>>0};var gT=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];ma.permute=function(t){for(var r=0,n=0;n>>gT[n]&1;return r>>>0};ma.padSplit=function(t,r,n){for(var i=t.toString(2);i.length0;i--)r+=this._buffer(t,r),n+=this._flushBuffer(a,n);return r+=this._buffer(t,r),a};Xa.prototype.final=function(t){var r;t&&(r=this.update(t));var n;return this.type==="encrypt"?n=this._finalEncrypt():n=this._finalDecrypt(),r?r.concat(n):n};Xa.prototype._pad=function(t,r){if(r===0)return!1;for(;r>>1];n=Cn.r28shl(n,s),i=Cn.r28shl(i,s),Cn.pc2(n,i,t.keys,a)}};fs.prototype._update=function(t,r,n,i){var a=this._desState,s=Cn.readUInt32BE(t,r),f=Cn.readUInt32BE(t,r+4);Cn.ip(s,f,a.tmp,0),s=a.tmp[0],f=a.tmp[1],this.type==="encrypt"?this._encrypt(a,s,f,a.tmp,0):this._decrypt(a,s,f,a.tmp,0),s=a.tmp[0],f=a.tmp[1],Cn.writeUInt32BE(n,s,i),Cn.writeUInt32BE(n,f,i+4)};fs.prototype._pad=function(t,r){if(this.padding===!1)return!1;for(var n=t.length-r,i=r;i>>0,s=S}Cn.rip(f,s,i,a)};fs.prototype._decrypt=function(t,r,n,i,a){for(var s=n,f=r,d=t.keys.length-2;d>=0;d-=2){var p=t.keys[d],y=t.keys[d+1];Cn.expand(s,t.tmp,0),p^=t.tmp[0],y^=t.tmp[1];var w=Cn.substitute(p,y),_=Cn.permute(w),S=s;s=(f^_)>>>0,f=S}Cn.rip(s,f,i,a)};var vI={},oQ=Ya,sQ=or,Bg={};function lQ(e){oQ.equal(e.length,8,"Invalid IV length"),this.iv=new Array(8);for(var t=0;t>i%8,e._prev=wQ(e._prev,r?f:d);return s}function wQ(e,t){var r=e.length,n=-1,i=Av.allocUnsafe(e.length);for(e=Av.concat([e,Av.from([t])]);++n>7;return i}_I.encrypt=function(e,t,r){for(var n=t.length,i=Av.allocUnsafe(n),a=-1;++a>>24]^s[y>>>16&255]^f[w>>>8&255]^d[_&255]^t[T++],M=a[y>>>24]^s[w>>>16&255]^f[_>>>8&255]^d[p&255]^t[T++],C=a[w>>>24]^s[_>>>16&255]^f[p>>>8&255]^d[y&255]^t[T++],O=a[_>>>24]^s[p>>>16&255]^f[y>>>8&255]^d[w&255]^t[T++],p=S,y=M,w=C,_=O;return S=(n[p>>>24]<<24|n[y>>>16&255]<<16|n[w>>>8&255]<<8|n[_&255])^t[T++],M=(n[y>>>24]<<24|n[w>>>16&255]<<16|n[_>>>8&255]<<8|n[p&255])^t[T++],C=(n[w>>>24]<<24|n[_>>>16&255]<<16|n[p>>>8&255]<<8|n[y&255])^t[T++],O=(n[_>>>24]<<24|n[p>>>16&255]<<16|n[y>>>8&255]<<8|n[w&255])^t[T++],S=S>>>0,M=M>>>0,C=C>>>0,O=O>>>0,[S,M,C,O]}var OQ=[0,1,2,4,8,16,32,64,128,27,54],yn=function(){for(var e=new Array(256),t=0;t<256;t++)t<128?e[t]=t<<1:e[t]=t<<1^283;for(var r=[],n=[],i=[[],[],[],[]],a=[[],[],[],[]],s=0,f=0,d=0;d<256;++d){var p=f^f<<1^f<<2^f<<3^f<<4;p=p>>>8^p&255^99,r[s]=p,n[p]=s;var y=e[s],w=e[y],_=e[w],S=e[p]*257^p*16843008;i[0][s]=S<<24|S>>>8,i[1][s]=S<<16|S>>>16,i[2][s]=S<<8|S>>>24,i[3][s]=S,S=_*16843009^w*65537^y*257^s*16843008,a[0][p]=S<<24|S>>>8,a[1][p]=S<<16|S>>>16,a[2][p]=S<<8|S>>>24,a[3][p]=S,s===0?s=f=1:(s=y^e[e[e[_^y]]],f^=e[e[f]])}return{SBOX:r,INV_SBOX:n,SUB_MIX:i,INV_SUB_MIX:a}}();function Ha(e){this._key=m5(e),this._reset()}Ha.blockSize=4*4;Ha.keySize=256/8;Ha.prototype.blockSize=Ha.blockSize;Ha.prototype.keySize=Ha.keySize;Ha.prototype._reset=function(){for(var e=this._key,t=e.length,r=t+6,n=(r+1)*4,i=[],a=0;a>>24,s=yn.SBOX[s>>>24]<<24|yn.SBOX[s>>>16&255]<<16|yn.SBOX[s>>>8&255]<<8|yn.SBOX[s&255],s^=OQ[a/t|0]<<24):t>6&&a%t===4&&(s=yn.SBOX[s>>>24]<<24|yn.SBOX[s>>>16&255]<<16|yn.SBOX[s>>>8&255]<<8|yn.SBOX[s&255]),i[a]=i[a-t]^s}for(var f=[],d=0;d>>24]]^yn.INV_SUB_MIX[1][yn.SBOX[y>>>16&255]]^yn.INV_SUB_MIX[2][yn.SBOX[y>>>8&255]]^yn.INV_SUB_MIX[3][yn.SBOX[y&255]]}this._nRounds=r,this._keySchedule=i,this._invKeySchedule=f};Ha.prototype.encryptBlockRaw=function(e){return e=m5(e),kI(e,this._keySchedule,yn.SUB_MIX,yn.SBOX,this._nRounds)};Ha.prototype.encryptBlock=function(e){var t=this.encryptBlockRaw(e),r=Fg.allocUnsafe(16);return r.writeUInt32BE(t[0],0),r.writeUInt32BE(t[1],4),r.writeUInt32BE(t[2],8),r.writeUInt32BE(t[3],12),r};Ha.prototype.decryptBlock=function(e){e=m5(e);var t=e[1];e[1]=e[3],e[3]=t;var r=kI(e,this._invKeySchedule,yn.INV_SUB_MIX,yn.INV_SBOX,this._nRounds),n=Fg.allocUnsafe(16);return n.writeUInt32BE(r[0],0),n.writeUInt32BE(r[3],4),n.writeUInt32BE(r[2],8),n.writeUInt32BE(r[1],12),n};Ha.prototype.scrub=function(){I2(this._keySchedule),I2(this._invKeySchedule),I2(this._key)};yp.AES=Ha;var qf=Jt.Buffer,RQ=qf.alloc(16,0);function AQ(e){return[e.readUInt32BE(0),e.readUInt32BE(4),e.readUInt32BE(8),e.readUInt32BE(12)]}function TI(e){var t=qf.allocUnsafe(16);return t.writeUInt32BE(e[0]>>>0,0),t.writeUInt32BE(e[1]>>>0,4),t.writeUInt32BE(e[2]>>>0,8),t.writeUInt32BE(e[3]>>>0,12),t}function wp(e){this.h=e,this.state=qf.alloc(16,0),this.cache=qf.allocUnsafe(0)}wp.prototype.ghash=function(e){for(var t=-1;++t0;r--)e[r]=e[r]>>>1|(e[r-1]&1)<<31;e[0]=e[0]>>>1,i&&(e[0]=e[0]^225<<24)}this.state=TI(t)};wp.prototype.update=function(e){this.cache=qf.concat([this.cache,e]);for(var t;this.cache.length>=16;)t=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(t)};wp.prototype.final=function(e,t){return this.cache.length&&this.ghash(qf.concat([this.cache,RQ],16)),this.ghash(TI([0,e,0,t])),this.state};var DQ=wp,$Q=yp,Di=Jt.Buffer,CI=du,IQ=or,PI=DQ,LQ=gp,NQ=MI;function jQ(e,t){var r=0;e.length!==t.length&&r++;for(var n=Math.min(e.length,t.length),i=0;i0||n>0;){var d=new UQ;d.update(f),d.update(e),t&&d.update(t),f=d.digest();var p=0;if(i>0){var y=a.length-i;p=Math.min(i,f.length),f.copy(a,y,0,p),i-=p}if(p0){var w=s.length-n,_=Math.min(n,f.length-p);f.copy(s,w,p,p+_),n-=_}}return f.fill(0),{key:a,iv:s}}var By=HQ,DI=p5,VQ=OI,el=Jt.Buffer,qQ=AI,$I=du,WQ=yp,KQ=By,GQ=or;function bp(e,t,r){$I.call(this),this._cache=new Fy,this._cipher=new WQ.AES(t),this._prev=el.from(r),this._mode=e,this._autopadding=!0}GQ(bp,$I);bp.prototype._update=function(e){this._cache.add(e);for(var t,r,n=[];t=this._cache.get();)r=this._mode.encrypt(this,t),n.push(r);return el.concat(n)};var YQ=el.alloc(16,16);bp.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return e=this._mode.encrypt(this,e),this._cipher.scrub(),e;if(!e.equals(YQ))throw this._cipher.scrub(),new Error("data not multiple of block length")};bp.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this};function Fy(){this.cache=el.allocUnsafe(0)}Fy.prototype.add=function(e){this.cache=el.concat([this.cache,e])};Fy.prototype.get=function(){if(this.cache.length>15){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null};Fy.prototype.flush=function(){for(var e=16-this.cache.length,t=el.allocUnsafe(e),r=-1;++r16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t}else if(this.cache.length>=16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t;return null};zy.prototype.flush=function(){if(this.cache.length)return this.cache};function ree(e){var t=e[15];if(t<1||t>16)throw new Error("unable to decrypt data");for(var r=-1;++r0?o:u},a.min=function(o,u){return o.cmp(u)<0?o:u},a.prototype._init=function(o,u,c){if(typeof o=="number")return this._initNumber(o,u,c);if(typeof o=="object")return this._initArray(o,u,c);u==="hex"&&(u=16),n(u===(u|0)&&u>=2&&u<=36),o=o.toString().replace(/\s+/g,"");var h=0;o[0]==="-"&&(h++,this.negative=1),h=0;h-=3)x=o[h]|o[h-1]<<8|o[h-2]<<16,this.words[g]|=x<>>26-E&67108863,E+=24,E>=26&&(E-=26,g++);else if(c==="le")for(h=0,g=0;h>>26-E&67108863,E+=24,E>=26&&(E-=26,g++);return this.strip()};function f(b,o){var u=b.charCodeAt(o);return u>=65&&u<=70?u-55:u>=97&&u<=102?u-87:u-48&15}function d(b,o,u){var c=f(b,u);return u-1>=o&&(c|=f(b,u-1)<<4),c}a.prototype._parseHex=function(o,u,c){this.length=Math.ceil((o.length-u)/6),this.words=new Array(this.length);for(var h=0;h=u;h-=2)E=d(o,u,h)<=18?(g-=18,x+=1,this.words[x]|=E>>>26):g+=8;else{var v=o.length-u;for(h=v%2===0?u+1:u;h=18?(g-=18,x+=1,this.words[x]|=E>>>26):g+=8}this.strip()};function p(b,o,u,c){for(var h=0,g=Math.min(b.length,u),x=o;x=49?h+=E-49+10:E>=17?h+=E-17+10:h+=E}return h}a.prototype._parseBase=function(o,u,c){this.words=[0],this.length=1;for(var h=0,g=1;g<=67108863;g*=u)h++;h--,g=g/u|0;for(var x=o.length-c,E=x%h,v=Math.min(x,x-E)+c,l=0,m=c;m1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},a.prototype.inspect=function(){return(this.red?""};var y=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],w=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],_=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(o,u){o=o||10,u=u|0||1;var c;if(o===16||o==="hex"){c="";for(var h=0,g=0,x=0;x>>24-h&16777215,g!==0||x!==this.length-1?c=y[6-v.length]+v+c:c=v+c,h+=2,h>=26&&(h-=26,x--)}for(g!==0&&(c=g.toString(16)+c);c.length%u!==0;)c="0"+c;return this.negative!==0&&(c="-"+c),c}if(o===(o|0)&&o>=2&&o<=36){var l=w[o],m=_[o];c="";var P=this.clone();for(P.negative=0;!P.isZero();){var N=P.modn(m).toString(o);P=P.idivn(m),P.isZero()?c=N+c:c=y[l-N.length]+N+c}for(this.isZero()&&(c="0"+c);c.length%u!==0;)c="0"+c;return this.negative!==0&&(c="-"+c),c}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var o=this.words[0];return this.length===2?o+=this.words[1]*67108864:this.length===3&&this.words[2]===1?o+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-o:o},a.prototype.toJSON=function(){return this.toString(16)},a.prototype.toBuffer=function(o,u){return n(typeof s<"u"),this.toArrayLike(s,o,u)},a.prototype.toArray=function(o,u){return this.toArrayLike(Array,o,u)},a.prototype.toArrayLike=function(o,u,c){var h=this.byteLength(),g=c||Math.max(1,h);n(h<=g,"byte array longer than desired length"),n(g>0,"Requested array length <= 0"),this.strip();var x=u==="le",E=new o(g),v,l,m=this.clone();if(x){for(l=0;!m.isZero();l++)v=m.andln(255),m.iushrn(8),E[l]=v;for(;l=4096&&(c+=13,u>>>=13),u>=64&&(c+=7,u>>>=7),u>=8&&(c+=4,u>>>=4),u>=2&&(c+=2,u>>>=2),c+u},a.prototype._zeroBits=function(o){if(o===0)return 26;var u=o,c=0;return u&8191||(c+=13,u>>>=13),u&127||(c+=7,u>>>=7),u&15||(c+=4,u>>>=4),u&3||(c+=2,u>>>=2),u&1||c++,c},a.prototype.bitLength=function(){var o=this.words[this.length-1],u=this._countBits(o);return(this.length-1)*26+u};function S(b){for(var o=new Array(b.bitLength()),u=0;u>>h}return o}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var o=0,u=0;uo.length?this.clone().ior(o):o.clone().ior(this)},a.prototype.uor=function(o){return this.length>o.length?this.clone().iuor(o):o.clone().iuor(this)},a.prototype.iuand=function(o){var u;this.length>o.length?u=o:u=this;for(var c=0;co.length?this.clone().iand(o):o.clone().iand(this)},a.prototype.uand=function(o){return this.length>o.length?this.clone().iuand(o):o.clone().iuand(this)},a.prototype.iuxor=function(o){var u,c;this.length>o.length?(u=this,c=o):(u=o,c=this);for(var h=0;ho.length?this.clone().ixor(o):o.clone().ixor(this)},a.prototype.uxor=function(o){return this.length>o.length?this.clone().iuxor(o):o.clone().iuxor(this)},a.prototype.inotn=function(o){n(typeof o=="number"&&o>=0);var u=Math.ceil(o/26)|0,c=o%26;this._expand(u),c>0&&u--;for(var h=0;h0&&(this.words[h]=~this.words[h]&67108863>>26-c),this.strip()},a.prototype.notn=function(o){return this.clone().inotn(o)},a.prototype.setn=function(o,u){n(typeof o=="number"&&o>=0);var c=o/26|0,h=o%26;return this._expand(c+1),u?this.words[c]=this.words[c]|1<o.length?(c=this,h=o):(c=o,h=this);for(var g=0,x=0;x>>26;for(;g!==0&&x>>26;if(this.length=c.length,g!==0)this.words[this.length]=g,this.length++;else if(c!==this)for(;xo.length?this.clone().iadd(o):o.clone().iadd(this)},a.prototype.isub=function(o){if(o.negative!==0){o.negative=0;var u=this.iadd(o);return o.negative=1,u._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(o),this.negative=1,this._normSign();var c=this.cmp(o);if(c===0)return this.negative=0,this.length=1,this.words[0]=0,this;var h,g;c>0?(h=this,g=o):(h=o,g=this);for(var x=0,E=0;E>26,this.words[E]=u&67108863;for(;x!==0&&E>26,this.words[E]=u&67108863;if(x===0&&E>>26,P=v&67108863,N=Math.min(l,o.length-1),F=Math.max(0,l-b.length+1);F<=N;F++){var ee=l-F|0;h=b.words[ee]|0,g=o.words[F]|0,x=h*g+P,m+=x/67108864|0,P=x&67108863}u.words[l]=P|0,v=m|0}return v!==0?u.words[l]=v|0:u.length--,u.strip()}var C=function(o,u,c){var h=o.words,g=u.words,x=c.words,E=0,v,l,m,P=h[0]|0,N=P&8191,F=P>>>13,ee=h[1]|0,q=ee&8191,ae=ee>>>13,pe=h[2]|0,we=pe&8191,Se=pe>>>13,he=h[3]|0,re=he&8191,_e=he>>>13,W=h[4]|0,ve=W&8191,Z=W>>>13,ne=h[5]|0,K=ne&8191,le=ne>>>13,xe=h[6]|0,ce=xe&8191,de=xe>>>13,Ae=h[7]|0,ye=Ae&8191,be=Ae>>>13,tt=h[8]|0,Oe=tt&8191,$e=tt>>>13,Et=h[9]|0,ze=Et&8191,He=Et>>>13,Fe=g[0]|0,Te=Fe&8191,Pe=Fe>>>13,pt=g[1]|0,De=pt&8191,je=pt>>>13,bt=g[2]|0,Le=bt&8191,Ge=bt>>>13,Ct=g[3]|0,Be=Ct&8191,Ye=Ct>>>13,Pt=g[4]|0,Ue=Pt&8191,et=Pt>>>13,Vt=g[5]|0,Xe=Vt&8191,ot=Vt>>>13,Kt=g[6]|0,Ve=Kt&8191,Je=Kt>>>13,It=g[7]|0,We=It&8191,it=It>>>13,jt=g[8]|0,Qe=jt&8191,lt=jt>>>13,Xt=g[9]|0,qe=Xt&8191,at=Xt>>>13;c.negative=o.negative^u.negative,c.length=19,v=Math.imul(N,Te),l=Math.imul(N,Pe),l=l+Math.imul(F,Te)|0,m=Math.imul(F,Pe);var Bt=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,v=Math.imul(q,Te),l=Math.imul(q,Pe),l=l+Math.imul(ae,Te)|0,m=Math.imul(ae,Pe),v=v+Math.imul(N,De)|0,l=l+Math.imul(N,je)|0,l=l+Math.imul(F,De)|0,m=m+Math.imul(F,je)|0;var Ot=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,v=Math.imul(we,Te),l=Math.imul(we,Pe),l=l+Math.imul(Se,Te)|0,m=Math.imul(Se,Pe),v=v+Math.imul(q,De)|0,l=l+Math.imul(q,je)|0,l=l+Math.imul(ae,De)|0,m=m+Math.imul(ae,je)|0,v=v+Math.imul(N,Le)|0,l=l+Math.imul(N,Ge)|0,l=l+Math.imul(F,Le)|0,m=m+Math.imul(F,Ge)|0;var sr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(sr>>>26)|0,sr&=67108863,v=Math.imul(re,Te),l=Math.imul(re,Pe),l=l+Math.imul(_e,Te)|0,m=Math.imul(_e,Pe),v=v+Math.imul(we,De)|0,l=l+Math.imul(we,je)|0,l=l+Math.imul(Se,De)|0,m=m+Math.imul(Se,je)|0,v=v+Math.imul(q,Le)|0,l=l+Math.imul(q,Ge)|0,l=l+Math.imul(ae,Le)|0,m=m+Math.imul(ae,Ge)|0,v=v+Math.imul(N,Be)|0,l=l+Math.imul(N,Ye)|0,l=l+Math.imul(F,Be)|0,m=m+Math.imul(F,Ye)|0;var Ht=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,v=Math.imul(ve,Te),l=Math.imul(ve,Pe),l=l+Math.imul(Z,Te)|0,m=Math.imul(Z,Pe),v=v+Math.imul(re,De)|0,l=l+Math.imul(re,je)|0,l=l+Math.imul(_e,De)|0,m=m+Math.imul(_e,je)|0,v=v+Math.imul(we,Le)|0,l=l+Math.imul(we,Ge)|0,l=l+Math.imul(Se,Le)|0,m=m+Math.imul(Se,Ge)|0,v=v+Math.imul(q,Be)|0,l=l+Math.imul(q,Ye)|0,l=l+Math.imul(ae,Be)|0,m=m+Math.imul(ae,Ye)|0,v=v+Math.imul(N,Ue)|0,l=l+Math.imul(N,et)|0,l=l+Math.imul(F,Ue)|0,m=m+Math.imul(F,et)|0;var hr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(hr>>>26)|0,hr&=67108863,v=Math.imul(K,Te),l=Math.imul(K,Pe),l=l+Math.imul(le,Te)|0,m=Math.imul(le,Pe),v=v+Math.imul(ve,De)|0,l=l+Math.imul(ve,je)|0,l=l+Math.imul(Z,De)|0,m=m+Math.imul(Z,je)|0,v=v+Math.imul(re,Le)|0,l=l+Math.imul(re,Ge)|0,l=l+Math.imul(_e,Le)|0,m=m+Math.imul(_e,Ge)|0,v=v+Math.imul(we,Be)|0,l=l+Math.imul(we,Ye)|0,l=l+Math.imul(Se,Be)|0,m=m+Math.imul(Se,Ye)|0,v=v+Math.imul(q,Ue)|0,l=l+Math.imul(q,et)|0,l=l+Math.imul(ae,Ue)|0,m=m+Math.imul(ae,et)|0,v=v+Math.imul(N,Xe)|0,l=l+Math.imul(N,ot)|0,l=l+Math.imul(F,Xe)|0,m=m+Math.imul(F,ot)|0;var pr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(pr>>>26)|0,pr&=67108863,v=Math.imul(ce,Te),l=Math.imul(ce,Pe),l=l+Math.imul(de,Te)|0,m=Math.imul(de,Pe),v=v+Math.imul(K,De)|0,l=l+Math.imul(K,je)|0,l=l+Math.imul(le,De)|0,m=m+Math.imul(le,je)|0,v=v+Math.imul(ve,Le)|0,l=l+Math.imul(ve,Ge)|0,l=l+Math.imul(Z,Le)|0,m=m+Math.imul(Z,Ge)|0,v=v+Math.imul(re,Be)|0,l=l+Math.imul(re,Ye)|0,l=l+Math.imul(_e,Be)|0,m=m+Math.imul(_e,Ye)|0,v=v+Math.imul(we,Ue)|0,l=l+Math.imul(we,et)|0,l=l+Math.imul(Se,Ue)|0,m=m+Math.imul(Se,et)|0,v=v+Math.imul(q,Xe)|0,l=l+Math.imul(q,ot)|0,l=l+Math.imul(ae,Xe)|0,m=m+Math.imul(ae,ot)|0,v=v+Math.imul(N,Ve)|0,l=l+Math.imul(N,Je)|0,l=l+Math.imul(F,Ve)|0,m=m+Math.imul(F,Je)|0;var _r=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(_r>>>26)|0,_r&=67108863,v=Math.imul(ye,Te),l=Math.imul(ye,Pe),l=l+Math.imul(be,Te)|0,m=Math.imul(be,Pe),v=v+Math.imul(ce,De)|0,l=l+Math.imul(ce,je)|0,l=l+Math.imul(de,De)|0,m=m+Math.imul(de,je)|0,v=v+Math.imul(K,Le)|0,l=l+Math.imul(K,Ge)|0,l=l+Math.imul(le,Le)|0,m=m+Math.imul(le,Ge)|0,v=v+Math.imul(ve,Be)|0,l=l+Math.imul(ve,Ye)|0,l=l+Math.imul(Z,Be)|0,m=m+Math.imul(Z,Ye)|0,v=v+Math.imul(re,Ue)|0,l=l+Math.imul(re,et)|0,l=l+Math.imul(_e,Ue)|0,m=m+Math.imul(_e,et)|0,v=v+Math.imul(we,Xe)|0,l=l+Math.imul(we,ot)|0,l=l+Math.imul(Se,Xe)|0,m=m+Math.imul(Se,ot)|0,v=v+Math.imul(q,Ve)|0,l=l+Math.imul(q,Je)|0,l=l+Math.imul(ae,Ve)|0,m=m+Math.imul(ae,Je)|0,v=v+Math.imul(N,We)|0,l=l+Math.imul(N,it)|0,l=l+Math.imul(F,We)|0,m=m+Math.imul(F,it)|0;var Sr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,v=Math.imul(Oe,Te),l=Math.imul(Oe,Pe),l=l+Math.imul($e,Te)|0,m=Math.imul($e,Pe),v=v+Math.imul(ye,De)|0,l=l+Math.imul(ye,je)|0,l=l+Math.imul(be,De)|0,m=m+Math.imul(be,je)|0,v=v+Math.imul(ce,Le)|0,l=l+Math.imul(ce,Ge)|0,l=l+Math.imul(de,Le)|0,m=m+Math.imul(de,Ge)|0,v=v+Math.imul(K,Be)|0,l=l+Math.imul(K,Ye)|0,l=l+Math.imul(le,Be)|0,m=m+Math.imul(le,Ye)|0,v=v+Math.imul(ve,Ue)|0,l=l+Math.imul(ve,et)|0,l=l+Math.imul(Z,Ue)|0,m=m+Math.imul(Z,et)|0,v=v+Math.imul(re,Xe)|0,l=l+Math.imul(re,ot)|0,l=l+Math.imul(_e,Xe)|0,m=m+Math.imul(_e,ot)|0,v=v+Math.imul(we,Ve)|0,l=l+Math.imul(we,Je)|0,l=l+Math.imul(Se,Ve)|0,m=m+Math.imul(Se,Je)|0,v=v+Math.imul(q,We)|0,l=l+Math.imul(q,it)|0,l=l+Math.imul(ae,We)|0,m=m+Math.imul(ae,it)|0,v=v+Math.imul(N,Qe)|0,l=l+Math.imul(N,lt)|0,l=l+Math.imul(F,Qe)|0,m=m+Math.imul(F,lt)|0;var cr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(cr>>>26)|0,cr&=67108863,v=Math.imul(ze,Te),l=Math.imul(ze,Pe),l=l+Math.imul(He,Te)|0,m=Math.imul(He,Pe),v=v+Math.imul(Oe,De)|0,l=l+Math.imul(Oe,je)|0,l=l+Math.imul($e,De)|0,m=m+Math.imul($e,je)|0,v=v+Math.imul(ye,Le)|0,l=l+Math.imul(ye,Ge)|0,l=l+Math.imul(be,Le)|0,m=m+Math.imul(be,Ge)|0,v=v+Math.imul(ce,Be)|0,l=l+Math.imul(ce,Ye)|0,l=l+Math.imul(de,Be)|0,m=m+Math.imul(de,Ye)|0,v=v+Math.imul(K,Ue)|0,l=l+Math.imul(K,et)|0,l=l+Math.imul(le,Ue)|0,m=m+Math.imul(le,et)|0,v=v+Math.imul(ve,Xe)|0,l=l+Math.imul(ve,ot)|0,l=l+Math.imul(Z,Xe)|0,m=m+Math.imul(Z,ot)|0,v=v+Math.imul(re,Ve)|0,l=l+Math.imul(re,Je)|0,l=l+Math.imul(_e,Ve)|0,m=m+Math.imul(_e,Je)|0,v=v+Math.imul(we,We)|0,l=l+Math.imul(we,it)|0,l=l+Math.imul(Se,We)|0,m=m+Math.imul(Se,it)|0,v=v+Math.imul(q,Qe)|0,l=l+Math.imul(q,lt)|0,l=l+Math.imul(ae,Qe)|0,m=m+Math.imul(ae,lt)|0,v=v+Math.imul(N,qe)|0,l=l+Math.imul(N,at)|0,l=l+Math.imul(F,qe)|0,m=m+Math.imul(F,at)|0;var qt=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(qt>>>26)|0,qt&=67108863,v=Math.imul(ze,De),l=Math.imul(ze,je),l=l+Math.imul(He,De)|0,m=Math.imul(He,je),v=v+Math.imul(Oe,Le)|0,l=l+Math.imul(Oe,Ge)|0,l=l+Math.imul($e,Le)|0,m=m+Math.imul($e,Ge)|0,v=v+Math.imul(ye,Be)|0,l=l+Math.imul(ye,Ye)|0,l=l+Math.imul(be,Be)|0,m=m+Math.imul(be,Ye)|0,v=v+Math.imul(ce,Ue)|0,l=l+Math.imul(ce,et)|0,l=l+Math.imul(de,Ue)|0,m=m+Math.imul(de,et)|0,v=v+Math.imul(K,Xe)|0,l=l+Math.imul(K,ot)|0,l=l+Math.imul(le,Xe)|0,m=m+Math.imul(le,ot)|0,v=v+Math.imul(ve,Ve)|0,l=l+Math.imul(ve,Je)|0,l=l+Math.imul(Z,Ve)|0,m=m+Math.imul(Z,Je)|0,v=v+Math.imul(re,We)|0,l=l+Math.imul(re,it)|0,l=l+Math.imul(_e,We)|0,m=m+Math.imul(_e,it)|0,v=v+Math.imul(we,Qe)|0,l=l+Math.imul(we,lt)|0,l=l+Math.imul(Se,Qe)|0,m=m+Math.imul(Se,lt)|0,v=v+Math.imul(q,qe)|0,l=l+Math.imul(q,at)|0,l=l+Math.imul(ae,qe)|0,m=m+Math.imul(ae,at)|0;var lr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(lr>>>26)|0,lr&=67108863,v=Math.imul(ze,Le),l=Math.imul(ze,Ge),l=l+Math.imul(He,Le)|0,m=Math.imul(He,Ge),v=v+Math.imul(Oe,Be)|0,l=l+Math.imul(Oe,Ye)|0,l=l+Math.imul($e,Be)|0,m=m+Math.imul($e,Ye)|0,v=v+Math.imul(ye,Ue)|0,l=l+Math.imul(ye,et)|0,l=l+Math.imul(be,Ue)|0,m=m+Math.imul(be,et)|0,v=v+Math.imul(ce,Xe)|0,l=l+Math.imul(ce,ot)|0,l=l+Math.imul(de,Xe)|0,m=m+Math.imul(de,ot)|0,v=v+Math.imul(K,Ve)|0,l=l+Math.imul(K,Je)|0,l=l+Math.imul(le,Ve)|0,m=m+Math.imul(le,Je)|0,v=v+Math.imul(ve,We)|0,l=l+Math.imul(ve,it)|0,l=l+Math.imul(Z,We)|0,m=m+Math.imul(Z,it)|0,v=v+Math.imul(re,Qe)|0,l=l+Math.imul(re,lt)|0,l=l+Math.imul(_e,Qe)|0,m=m+Math.imul(_e,lt)|0,v=v+Math.imul(we,qe)|0,l=l+Math.imul(we,at)|0,l=l+Math.imul(Se,qe)|0,m=m+Math.imul(Se,at)|0;var br=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(br>>>26)|0,br&=67108863,v=Math.imul(ze,Be),l=Math.imul(ze,Ye),l=l+Math.imul(He,Be)|0,m=Math.imul(He,Ye),v=v+Math.imul(Oe,Ue)|0,l=l+Math.imul(Oe,et)|0,l=l+Math.imul($e,Ue)|0,m=m+Math.imul($e,et)|0,v=v+Math.imul(ye,Xe)|0,l=l+Math.imul(ye,ot)|0,l=l+Math.imul(be,Xe)|0,m=m+Math.imul(be,ot)|0,v=v+Math.imul(ce,Ve)|0,l=l+Math.imul(ce,Je)|0,l=l+Math.imul(de,Ve)|0,m=m+Math.imul(de,Je)|0,v=v+Math.imul(K,We)|0,l=l+Math.imul(K,it)|0,l=l+Math.imul(le,We)|0,m=m+Math.imul(le,it)|0,v=v+Math.imul(ve,Qe)|0,l=l+Math.imul(ve,lt)|0,l=l+Math.imul(Z,Qe)|0,m=m+Math.imul(Z,lt)|0,v=v+Math.imul(re,qe)|0,l=l+Math.imul(re,at)|0,l=l+Math.imul(_e,qe)|0,m=m+Math.imul(_e,at)|0;var Mr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,v=Math.imul(ze,Ue),l=Math.imul(ze,et),l=l+Math.imul(He,Ue)|0,m=Math.imul(He,et),v=v+Math.imul(Oe,Xe)|0,l=l+Math.imul(Oe,ot)|0,l=l+Math.imul($e,Xe)|0,m=m+Math.imul($e,ot)|0,v=v+Math.imul(ye,Ve)|0,l=l+Math.imul(ye,Je)|0,l=l+Math.imul(be,Ve)|0,m=m+Math.imul(be,Je)|0,v=v+Math.imul(ce,We)|0,l=l+Math.imul(ce,it)|0,l=l+Math.imul(de,We)|0,m=m+Math.imul(de,it)|0,v=v+Math.imul(K,Qe)|0,l=l+Math.imul(K,lt)|0,l=l+Math.imul(le,Qe)|0,m=m+Math.imul(le,lt)|0,v=v+Math.imul(ve,qe)|0,l=l+Math.imul(ve,at)|0,l=l+Math.imul(Z,qe)|0,m=m+Math.imul(Z,at)|0;var Er=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Er>>>26)|0,Er&=67108863,v=Math.imul(ze,Xe),l=Math.imul(ze,ot),l=l+Math.imul(He,Xe)|0,m=Math.imul(He,ot),v=v+Math.imul(Oe,Ve)|0,l=l+Math.imul(Oe,Je)|0,l=l+Math.imul($e,Ve)|0,m=m+Math.imul($e,Je)|0,v=v+Math.imul(ye,We)|0,l=l+Math.imul(ye,it)|0,l=l+Math.imul(be,We)|0,m=m+Math.imul(be,it)|0,v=v+Math.imul(ce,Qe)|0,l=l+Math.imul(ce,lt)|0,l=l+Math.imul(de,Qe)|0,m=m+Math.imul(de,lt)|0,v=v+Math.imul(K,qe)|0,l=l+Math.imul(K,at)|0,l=l+Math.imul(le,qe)|0,m=m+Math.imul(le,at)|0;var xr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(xr>>>26)|0,xr&=67108863,v=Math.imul(ze,Ve),l=Math.imul(ze,Je),l=l+Math.imul(He,Ve)|0,m=Math.imul(He,Je),v=v+Math.imul(Oe,We)|0,l=l+Math.imul(Oe,it)|0,l=l+Math.imul($e,We)|0,m=m+Math.imul($e,it)|0,v=v+Math.imul(ye,Qe)|0,l=l+Math.imul(ye,lt)|0,l=l+Math.imul(be,Qe)|0,m=m+Math.imul(be,lt)|0,v=v+Math.imul(ce,qe)|0,l=l+Math.imul(ce,at)|0,l=l+Math.imul(de,qe)|0,m=m+Math.imul(de,at)|0;var Pr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Pr>>>26)|0,Pr&=67108863,v=Math.imul(ze,We),l=Math.imul(ze,it),l=l+Math.imul(He,We)|0,m=Math.imul(He,it),v=v+Math.imul(Oe,Qe)|0,l=l+Math.imul(Oe,lt)|0,l=l+Math.imul($e,Qe)|0,m=m+Math.imul($e,lt)|0,v=v+Math.imul(ye,qe)|0,l=l+Math.imul(ye,at)|0,l=l+Math.imul(be,qe)|0,m=m+Math.imul(be,at)|0;var Or=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Or>>>26)|0,Or&=67108863,v=Math.imul(ze,Qe),l=Math.imul(ze,lt),l=l+Math.imul(He,Qe)|0,m=Math.imul(He,lt),v=v+Math.imul(Oe,qe)|0,l=l+Math.imul(Oe,at)|0,l=l+Math.imul($e,qe)|0,m=m+Math.imul($e,at)|0;var kr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(kr>>>26)|0,kr&=67108863,v=Math.imul(ze,qe),l=Math.imul(ze,at),l=l+Math.imul(He,qe)|0,m=Math.imul(He,at);var rr=(E+v|0)+((l&8191)<<13)|0;return E=(m+(l>>>13)|0)+(rr>>>26)|0,rr&=67108863,x[0]=Bt,x[1]=Ot,x[2]=sr,x[3]=Ht,x[4]=hr,x[5]=pr,x[6]=_r,x[7]=Sr,x[8]=cr,x[9]=qt,x[10]=lr,x[11]=br,x[12]=Mr,x[13]=Er,x[14]=xr,x[15]=Pr,x[16]=Or,x[17]=kr,x[18]=rr,E!==0&&(x[19]=E,c.length++),c};Math.imul||(C=M);function O(b,o,u){u.negative=o.negative^b.negative,u.length=b.length+o.length;for(var c=0,h=0,g=0;g>>26)|0,h+=x>>>26,x&=67108863}u.words[g]=E,c=x,x=h}return c!==0?u.words[g]=c:u.length--,u.strip()}function T(b,o,u){var c=new k;return c.mulp(b,o,u)}a.prototype.mulTo=function(o,u){var c,h=this.length+o.length;return this.length===10&&o.length===10?c=C(this,o,u):h<63?c=M(this,o,u):h<1024?c=O(this,o,u):c=T(this,o,u),c};function k(b,o){this.x=b,this.y=o}k.prototype.makeRBT=function(o){for(var u=new Array(o),c=a.prototype._countBits(o)-1,h=0;h>=1;return h},k.prototype.permute=function(o,u,c,h,g,x){for(var E=0;E>>1)g++;return 1<>>13,c[2*x+1]=g&8191,g=g>>>13;for(x=2*u;x>=26,u+=h/67108864|0,u+=g>>>26,this.words[c]=g&67108863}return u!==0&&(this.words[c]=u,this.length++),this},a.prototype.muln=function(o){return this.clone().imuln(o)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(o){var u=S(o);if(u.length===0)return new a(1);for(var c=this,h=0;h=0);var u=o%26,c=(o-u)/26,h=67108863>>>26-u<<26-u,g;if(u!==0){var x=0;for(g=0;g>>26-u}x&&(this.words[g]=x,this.length++)}if(c!==0){for(g=this.length-1;g>=0;g--)this.words[g+c]=this.words[g];for(g=0;g=0);var h;u?h=(u-u%26)/26:h=0;var g=o%26,x=Math.min((o-g)/26,this.length),E=67108863^67108863>>>g<x)for(this.length-=x,l=0;l=0&&(m!==0||l>=h);l--){var P=this.words[l]|0;this.words[l]=m<<26-g|P>>>g,m=P&E}return v&&m!==0&&(v.words[v.length++]=m),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},a.prototype.ishrn=function(o,u,c){return n(this.negative===0),this.iushrn(o,u,c)},a.prototype.shln=function(o){return this.clone().ishln(o)},a.prototype.ushln=function(o){return this.clone().iushln(o)},a.prototype.shrn=function(o){return this.clone().ishrn(o)},a.prototype.ushrn=function(o){return this.clone().iushrn(o)},a.prototype.testn=function(o){n(typeof o=="number"&&o>=0);var u=o%26,c=(o-u)/26,h=1<=0);var u=o%26,c=(o-u)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=c)return this;if(u!==0&&c++,this.length=Math.min(c,this.length),u!==0){var h=67108863^67108863>>>u<=67108864;u++)this.words[u]-=67108864,u===this.length-1?this.words[u+1]=1:this.words[u+1]++;return this.length=Math.max(this.length,u+1),this},a.prototype.isubn=function(o){if(n(typeof o=="number"),n(o<67108864),o<0)return this.iaddn(-o);if(this.negative!==0)return this.negative=0,this.iaddn(o),this.negative=1,this;if(this.words[0]-=o,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var u=0;u>26)-(v/67108864|0),this.words[g+c]=x&67108863}for(;g>26,this.words[g+c]=x&67108863;if(E===0)return this.strip();for(n(E===-1),E=0,g=0;g>26,this.words[g]=x&67108863;return this.negative=1,this.strip()},a.prototype._wordDiv=function(o,u){var c=this.length-o.length,h=this.clone(),g=o,x=g.words[g.length-1]|0,E=this._countBits(x);c=26-E,c!==0&&(g=g.ushln(c),h.iushln(c),x=g.words[g.length-1]|0);var v=h.length-g.length,l;if(u!=="mod"){l=new a(null),l.length=v+1,l.words=new Array(l.length);for(var m=0;m=0;N--){var F=(h.words[g.length+N]|0)*67108864+(h.words[g.length+N-1]|0);for(F=Math.min(F/x|0,67108863),h._ishlnsubmul(g,F,N);h.negative!==0;)F--,h.negative=0,h._ishlnsubmul(g,1,N),h.isZero()||(h.negative^=1);l&&(l.words[N]=F)}return l&&l.strip(),h.strip(),u!=="div"&&c!==0&&h.iushrn(c),{div:l||null,mod:h}},a.prototype.divmod=function(o,u,c){if(n(!o.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var h,g,x;return this.negative!==0&&o.negative===0?(x=this.neg().divmod(o,u),u!=="mod"&&(h=x.div.neg()),u!=="div"&&(g=x.mod.neg(),c&&g.negative!==0&&g.iadd(o)),{div:h,mod:g}):this.negative===0&&o.negative!==0?(x=this.divmod(o.neg(),u),u!=="mod"&&(h=x.div.neg()),{div:h,mod:x.mod}):this.negative&o.negative?(x=this.neg().divmod(o.neg(),u),u!=="div"&&(g=x.mod.neg(),c&&g.negative!==0&&g.isub(o)),{div:x.div,mod:g}):o.length>this.length||this.cmp(o)<0?{div:new a(0),mod:this}:o.length===1?u==="div"?{div:this.divn(o.words[0]),mod:null}:u==="mod"?{div:null,mod:new a(this.modn(o.words[0]))}:{div:this.divn(o.words[0]),mod:new a(this.modn(o.words[0]))}:this._wordDiv(o,u)},a.prototype.div=function(o){return this.divmod(o,"div",!1).div},a.prototype.mod=function(o){return this.divmod(o,"mod",!1).mod},a.prototype.umod=function(o){return this.divmod(o,"mod",!0).mod},a.prototype.divRound=function(o){var u=this.divmod(o);if(u.mod.isZero())return u.div;var c=u.div.negative!==0?u.mod.isub(o):u.mod,h=o.ushrn(1),g=o.andln(1),x=c.cmp(h);return x<0||g===1&&x===0?u.div:u.div.negative!==0?u.div.isubn(1):u.div.iaddn(1)},a.prototype.modn=function(o){n(o<=67108863);for(var u=(1<<26)%o,c=0,h=this.length-1;h>=0;h--)c=(u*c+(this.words[h]|0))%o;return c},a.prototype.idivn=function(o){n(o<=67108863);for(var u=0,c=this.length-1;c>=0;c--){var h=(this.words[c]|0)+u*67108864;this.words[c]=h/o|0,u=h%o}return this.strip()},a.prototype.divn=function(o){return this.clone().idivn(o)},a.prototype.egcd=function(o){n(o.negative===0),n(!o.isZero());var u=this,c=o.clone();u.negative!==0?u=u.umod(o):u=u.clone();for(var h=new a(1),g=new a(0),x=new a(0),E=new a(1),v=0;u.isEven()&&c.isEven();)u.iushrn(1),c.iushrn(1),++v;for(var l=c.clone(),m=u.clone();!u.isZero();){for(var P=0,N=1;!(u.words[0]&N)&&P<26;++P,N<<=1);if(P>0)for(u.iushrn(P);P-- >0;)(h.isOdd()||g.isOdd())&&(h.iadd(l),g.isub(m)),h.iushrn(1),g.iushrn(1);for(var F=0,ee=1;!(c.words[0]&ee)&&F<26;++F,ee<<=1);if(F>0)for(c.iushrn(F);F-- >0;)(x.isOdd()||E.isOdd())&&(x.iadd(l),E.isub(m)),x.iushrn(1),E.iushrn(1);u.cmp(c)>=0?(u.isub(c),h.isub(x),g.isub(E)):(c.isub(u),x.isub(h),E.isub(g))}return{a:x,b:E,gcd:c.iushln(v)}},a.prototype._invmp=function(o){n(o.negative===0),n(!o.isZero());var u=this,c=o.clone();u.negative!==0?u=u.umod(o):u=u.clone();for(var h=new a(1),g=new a(0),x=c.clone();u.cmpn(1)>0&&c.cmpn(1)>0;){for(var E=0,v=1;!(u.words[0]&v)&&E<26;++E,v<<=1);if(E>0)for(u.iushrn(E);E-- >0;)h.isOdd()&&h.iadd(x),h.iushrn(1);for(var l=0,m=1;!(c.words[0]&m)&&l<26;++l,m<<=1);if(l>0)for(c.iushrn(l);l-- >0;)g.isOdd()&&g.iadd(x),g.iushrn(1);u.cmp(c)>=0?(u.isub(c),h.isub(g)):(c.isub(u),g.isub(h))}var P;return u.cmpn(1)===0?P=h:P=g,P.cmpn(0)<0&&P.iadd(o),P},a.prototype.gcd=function(o){if(this.isZero())return o.abs();if(o.isZero())return this.abs();var u=this.clone(),c=o.clone();u.negative=0,c.negative=0;for(var h=0;u.isEven()&&c.isEven();h++)u.iushrn(1),c.iushrn(1);do{for(;u.isEven();)u.iushrn(1);for(;c.isEven();)c.iushrn(1);var g=u.cmp(c);if(g<0){var x=u;u=c,c=x}else if(g===0||c.cmpn(1)===0)break;u.isub(c)}while(!0);return c.iushln(h)},a.prototype.invm=function(o){return this.egcd(o).a.umod(o)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(o){return this.words[0]&o},a.prototype.bincn=function(o){n(typeof o=="number");var u=o%26,c=(o-u)/26,h=1<>>26,E&=67108863,this.words[x]=E}return g!==0&&(this.words[x]=g,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(o){var u=o<0;if(this.negative!==0&&!u)return-1;if(this.negative===0&&u)return 1;this.strip();var c;if(this.length>1)c=1;else{u&&(o=-o),n(o<=67108863,"Number is too big");var h=this.words[0]|0;c=h===o?0:ho.length)return 1;if(this.length=0;c--){var h=this.words[c]|0,g=o.words[c]|0;if(h!==g){hg&&(u=1);break}}return u},a.prototype.gtn=function(o){return this.cmpn(o)===1},a.prototype.gt=function(o){return this.cmp(o)===1},a.prototype.gten=function(o){return this.cmpn(o)>=0},a.prototype.gte=function(o){return this.cmp(o)>=0},a.prototype.ltn=function(o){return this.cmpn(o)===-1},a.prototype.lt=function(o){return this.cmp(o)===-1},a.prototype.lten=function(o){return this.cmpn(o)<=0},a.prototype.lte=function(o){return this.cmp(o)<=0},a.prototype.eqn=function(o){return this.cmpn(o)===0},a.prototype.eq=function(o){return this.cmp(o)===0},a.red=function(o){return new z(o)},a.prototype.toRed=function(o){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),o.convertTo(this)._forceRed(o)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(o){return this.red=o,this},a.prototype.forceRed=function(o){return n(!this.red,"Already a number in reduction context"),this._forceRed(o)},a.prototype.redAdd=function(o){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,o)},a.prototype.redIAdd=function(o){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,o)},a.prototype.redSub=function(o){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,o)},a.prototype.redISub=function(o){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,o)},a.prototype.redShl=function(o){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,o)},a.prototype.redMul=function(o){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,o),this.red.mul(this,o)},a.prototype.redIMul=function(o){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,o),this.red.imul(this,o)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(o){return n(this.red&&!o.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,o)};var R={k256:null,p224:null,p192:null,p25519:null};function $(b,o){this.name=b,this.p=new a(o,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}$.prototype._tmp=function(){var o=new a(null);return o.words=new Array(Math.ceil(this.n/13)),o},$.prototype.ireduce=function(o){var u=o,c;do this.split(u,this.tmp),u=this.imulK(u),u=u.iadd(this.tmp),c=u.bitLength();while(c>this.n);var h=c0?u.isub(this.p):u.strip!==void 0?u.strip():u._strip(),u},$.prototype.split=function(o,u){o.iushrn(this.n,0,u)},$.prototype.imulK=function(o){return o.imul(this.k)};function L(){$.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}i(L,$),L.prototype.split=function(o,u){for(var c=4194303,h=Math.min(o.length,9),g=0;g>>22,x=E}x>>>=22,o.words[g-10]=x,x===0&&o.length>10?o.length-=10:o.length-=9},L.prototype.imulK=function(o){o.words[o.length]=0,o.words[o.length+1]=0,o.length+=2;for(var u=0,c=0;c>>=26,o.words[c]=g,u=h}return u!==0&&(o.words[o.length++]=u),o},a._prime=function(o){if(R[o])return R[o];var u;if(o==="k256")u=new L;else if(o==="p224")u=new j;else if(o==="p192")u=new A;else if(o==="p25519")u=new V;else throw new Error("Unknown prime "+o);return R[o]=u,u};function z(b){if(typeof b=="string"){var o=a._prime(b);this.m=o.p,this.prime=o}else n(b.gtn(1),"modulus must be greater than 1"),this.m=b,this.prime=null}z.prototype._verify1=function(o){n(o.negative===0,"red works only with positives"),n(o.red,"red works only with red numbers")},z.prototype._verify2=function(o,u){n((o.negative|u.negative)===0,"red works only with positives"),n(o.red&&o.red===u.red,"red works only with red numbers")},z.prototype.imod=function(o){return this.prime?this.prime.ireduce(o)._forceRed(this):o.umod(this.m)._forceRed(this)},z.prototype.neg=function(o){return o.isZero()?o.clone():this.m.sub(o)._forceRed(this)},z.prototype.add=function(o,u){this._verify2(o,u);var c=o.add(u);return c.cmp(this.m)>=0&&c.isub(this.m),c._forceRed(this)},z.prototype.iadd=function(o,u){this._verify2(o,u);var c=o.iadd(u);return c.cmp(this.m)>=0&&c.isub(this.m),c},z.prototype.sub=function(o,u){this._verify2(o,u);var c=o.sub(u);return c.cmpn(0)<0&&c.iadd(this.m),c._forceRed(this)},z.prototype.isub=function(o,u){this._verify2(o,u);var c=o.isub(u);return c.cmpn(0)<0&&c.iadd(this.m),c},z.prototype.shl=function(o,u){return this._verify1(o),this.imod(o.ushln(u))},z.prototype.imul=function(o,u){return this._verify2(o,u),this.imod(o.imul(u))},z.prototype.mul=function(o,u){return this._verify2(o,u),this.imod(o.mul(u))},z.prototype.isqr=function(o){return this.imul(o,o.clone())},z.prototype.sqr=function(o){return this.mul(o,o)},z.prototype.sqrt=function(o){if(o.isZero())return o.clone();var u=this.m.andln(3);if(n(u%2===1),u===3){var c=this.m.add(new a(1)).iushrn(2);return this.pow(o,c)}for(var h=this.m.subn(1),g=0;!h.isZero()&&h.andln(1)===0;)g++,h.iushrn(1);n(!h.isZero());var x=new a(1).toRed(this),E=x.redNeg(),v=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new a(2*l*l).toRed(this);this.pow(l,v).cmp(E)!==0;)l.redIAdd(E);for(var m=this.pow(l,h),P=this.pow(o,h.addn(1).iushrn(1)),N=this.pow(o,h),F=g;N.cmp(x)!==0;){for(var ee=N,q=0;ee.cmp(x)!==0;q++)ee=ee.redSqr();n(q=0;g--){for(var m=u.words[g],P=l-1;P>=0;P--){var N=m>>P&1;if(x!==h[0]&&(x=this.sqr(x)),N===0&&E===0){v=0;continue}E<<=1,E|=N,v++,!(v!==c&&(g!==0||P!==0))&&(x=this.mul(x,h[E]),v=0,E=0)}l=26}return x},z.prototype.convertTo=function(o){var u=o.umod(this.m);return u===o?u.clone():u},z.prototype.convertFrom=function(o){var u=o.clone();return u.red=null,u},a.mont=function(o){return new Y(o)};function Y(b){z.call(this,b),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}i(Y,z),Y.prototype.convertTo=function(o){return this.imod(o.ushln(this.shift))},Y.prototype.convertFrom=function(o){var u=this.imod(o.mul(this.rinv));return u.red=null,u},Y.prototype.imul=function(o,u){if(o.isZero()||u.isZero())return o.words[0]=0,o.length=1,o;var c=o.imul(u),h=c.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),g=c.isub(h).iushrn(this.shift),x=g;return g.cmp(this.m)>=0?x=g.isub(this.m):g.cmpn(0)<0&&(x=g.iadd(this.m)),x._forceRed(this)},Y.prototype.mul=function(o,u){if(o.isZero()||u.isZero())return new a(0)._forceRed(this);var c=o.mul(u),h=c.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),g=c.isub(h).iushrn(this.shift),x=g;return g.cmp(this.m)>=0?x=g.isub(this.m):g.cmpn(0)<0&&(x=g.iadd(this.m)),x._forceRed(this)},Y.prototype.invm=function(o){var u=this.imod(o._invmp(this.m).mul(this.r2));return u._forceRed(this)}})(e,Ut)})(y5);var WI=y5.exports,w5={exports:{}};w5.exports;(function(e){(function(t,r){function n(b,o){if(!b)throw new Error(o||"Assertion failed")}function i(b,o){b.super_=o;var u=function(){};u.prototype=o.prototype,b.prototype=new u,b.prototype.constructor=b}function a(b,o,u){if(a.isBN(b))return b;this.negative=0,this.words=null,this.length=0,this.red=null,b!==null&&((o==="le"||o==="be")&&(u=o,o=10),this._init(b||0,o||10,u||"be"))}typeof t=="object"?t.exports=a:r.BN=a,a.BN=a,a.wordSize=26;var s;try{typeof window<"u"&&typeof window.Buffer<"u"?s=window.Buffer:s=mi.Buffer}catch{}a.isBN=function(o){return o instanceof a?!0:o!==null&&typeof o=="object"&&o.constructor.wordSize===a.wordSize&&Array.isArray(o.words)},a.max=function(o,u){return o.cmp(u)>0?o:u},a.min=function(o,u){return o.cmp(u)<0?o:u},a.prototype._init=function(o,u,c){if(typeof o=="number")return this._initNumber(o,u,c);if(typeof o=="object")return this._initArray(o,u,c);u==="hex"&&(u=16),n(u===(u|0)&&u>=2&&u<=36),o=o.toString().replace(/\s+/g,"");var h=0;o[0]==="-"&&(h++,this.negative=1),h=0;h-=3)x=o[h]|o[h-1]<<8|o[h-2]<<16,this.words[g]|=x<>>26-E&67108863,E+=24,E>=26&&(E-=26,g++);else if(c==="le")for(h=0,g=0;h>>26-E&67108863,E+=24,E>=26&&(E-=26,g++);return this.strip()};function f(b,o){var u=b.charCodeAt(o);return u>=65&&u<=70?u-55:u>=97&&u<=102?u-87:u-48&15}function d(b,o,u){var c=f(b,u);return u-1>=o&&(c|=f(b,u-1)<<4),c}a.prototype._parseHex=function(o,u,c){this.length=Math.ceil((o.length-u)/6),this.words=new Array(this.length);for(var h=0;h=u;h-=2)E=d(o,u,h)<=18?(g-=18,x+=1,this.words[x]|=E>>>26):g+=8;else{var v=o.length-u;for(h=v%2===0?u+1:u;h=18?(g-=18,x+=1,this.words[x]|=E>>>26):g+=8}this.strip()};function p(b,o,u,c){for(var h=0,g=Math.min(b.length,u),x=o;x=49?h+=E-49+10:E>=17?h+=E-17+10:h+=E}return h}a.prototype._parseBase=function(o,u,c){this.words=[0],this.length=1;for(var h=0,g=1;g<=67108863;g*=u)h++;h--,g=g/u|0;for(var x=o.length-c,E=x%h,v=Math.min(x,x-E)+c,l=0,m=c;m1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},a.prototype.inspect=function(){return(this.red?""};var y=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],w=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],_=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(o,u){o=o||10,u=u|0||1;var c;if(o===16||o==="hex"){c="";for(var h=0,g=0,x=0;x>>24-h&16777215,g!==0||x!==this.length-1?c=y[6-v.length]+v+c:c=v+c,h+=2,h>=26&&(h-=26,x--)}for(g!==0&&(c=g.toString(16)+c);c.length%u!==0;)c="0"+c;return this.negative!==0&&(c="-"+c),c}if(o===(o|0)&&o>=2&&o<=36){var l=w[o],m=_[o];c="";var P=this.clone();for(P.negative=0;!P.isZero();){var N=P.modn(m).toString(o);P=P.idivn(m),P.isZero()?c=N+c:c=y[l-N.length]+N+c}for(this.isZero()&&(c="0"+c);c.length%u!==0;)c="0"+c;return this.negative!==0&&(c="-"+c),c}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var o=this.words[0];return this.length===2?o+=this.words[1]*67108864:this.length===3&&this.words[2]===1?o+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-o:o},a.prototype.toJSON=function(){return this.toString(16)},a.prototype.toBuffer=function(o,u){return n(typeof s<"u"),this.toArrayLike(s,o,u)},a.prototype.toArray=function(o,u){return this.toArrayLike(Array,o,u)},a.prototype.toArrayLike=function(o,u,c){var h=this.byteLength(),g=c||Math.max(1,h);n(h<=g,"byte array longer than desired length"),n(g>0,"Requested array length <= 0"),this.strip();var x=u==="le",E=new o(g),v,l,m=this.clone();if(x){for(l=0;!m.isZero();l++)v=m.andln(255),m.iushrn(8),E[l]=v;for(;l=4096&&(c+=13,u>>>=13),u>=64&&(c+=7,u>>>=7),u>=8&&(c+=4,u>>>=4),u>=2&&(c+=2,u>>>=2),c+u},a.prototype._zeroBits=function(o){if(o===0)return 26;var u=o,c=0;return u&8191||(c+=13,u>>>=13),u&127||(c+=7,u>>>=7),u&15||(c+=4,u>>>=4),u&3||(c+=2,u>>>=2),u&1||c++,c},a.prototype.bitLength=function(){var o=this.words[this.length-1],u=this._countBits(o);return(this.length-1)*26+u};function S(b){for(var o=new Array(b.bitLength()),u=0;u>>h}return o}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var o=0,u=0;uo.length?this.clone().ior(o):o.clone().ior(this)},a.prototype.uor=function(o){return this.length>o.length?this.clone().iuor(o):o.clone().iuor(this)},a.prototype.iuand=function(o){var u;this.length>o.length?u=o:u=this;for(var c=0;co.length?this.clone().iand(o):o.clone().iand(this)},a.prototype.uand=function(o){return this.length>o.length?this.clone().iuand(o):o.clone().iuand(this)},a.prototype.iuxor=function(o){var u,c;this.length>o.length?(u=this,c=o):(u=o,c=this);for(var h=0;ho.length?this.clone().ixor(o):o.clone().ixor(this)},a.prototype.uxor=function(o){return this.length>o.length?this.clone().iuxor(o):o.clone().iuxor(this)},a.prototype.inotn=function(o){n(typeof o=="number"&&o>=0);var u=Math.ceil(o/26)|0,c=o%26;this._expand(u),c>0&&u--;for(var h=0;h0&&(this.words[h]=~this.words[h]&67108863>>26-c),this.strip()},a.prototype.notn=function(o){return this.clone().inotn(o)},a.prototype.setn=function(o,u){n(typeof o=="number"&&o>=0);var c=o/26|0,h=o%26;return this._expand(c+1),u?this.words[c]=this.words[c]|1<o.length?(c=this,h=o):(c=o,h=this);for(var g=0,x=0;x>>26;for(;g!==0&&x>>26;if(this.length=c.length,g!==0)this.words[this.length]=g,this.length++;else if(c!==this)for(;xo.length?this.clone().iadd(o):o.clone().iadd(this)},a.prototype.isub=function(o){if(o.negative!==0){o.negative=0;var u=this.iadd(o);return o.negative=1,u._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(o),this.negative=1,this._normSign();var c=this.cmp(o);if(c===0)return this.negative=0,this.length=1,this.words[0]=0,this;var h,g;c>0?(h=this,g=o):(h=o,g=this);for(var x=0,E=0;E>26,this.words[E]=u&67108863;for(;x!==0&&E>26,this.words[E]=u&67108863;if(x===0&&E>>26,P=v&67108863,N=Math.min(l,o.length-1),F=Math.max(0,l-b.length+1);F<=N;F++){var ee=l-F|0;h=b.words[ee]|0,g=o.words[F]|0,x=h*g+P,m+=x/67108864|0,P=x&67108863}u.words[l]=P|0,v=m|0}return v!==0?u.words[l]=v|0:u.length--,u.strip()}var C=function(o,u,c){var h=o.words,g=u.words,x=c.words,E=0,v,l,m,P=h[0]|0,N=P&8191,F=P>>>13,ee=h[1]|0,q=ee&8191,ae=ee>>>13,pe=h[2]|0,we=pe&8191,Se=pe>>>13,he=h[3]|0,re=he&8191,_e=he>>>13,W=h[4]|0,ve=W&8191,Z=W>>>13,ne=h[5]|0,K=ne&8191,le=ne>>>13,xe=h[6]|0,ce=xe&8191,de=xe>>>13,Ae=h[7]|0,ye=Ae&8191,be=Ae>>>13,tt=h[8]|0,Oe=tt&8191,$e=tt>>>13,Et=h[9]|0,ze=Et&8191,He=Et>>>13,Fe=g[0]|0,Te=Fe&8191,Pe=Fe>>>13,pt=g[1]|0,De=pt&8191,je=pt>>>13,bt=g[2]|0,Le=bt&8191,Ge=bt>>>13,Ct=g[3]|0,Be=Ct&8191,Ye=Ct>>>13,Pt=g[4]|0,Ue=Pt&8191,et=Pt>>>13,Vt=g[5]|0,Xe=Vt&8191,ot=Vt>>>13,Kt=g[6]|0,Ve=Kt&8191,Je=Kt>>>13,It=g[7]|0,We=It&8191,it=It>>>13,jt=g[8]|0,Qe=jt&8191,lt=jt>>>13,Xt=g[9]|0,qe=Xt&8191,at=Xt>>>13;c.negative=o.negative^u.negative,c.length=19,v=Math.imul(N,Te),l=Math.imul(N,Pe),l=l+Math.imul(F,Te)|0,m=Math.imul(F,Pe);var Bt=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,v=Math.imul(q,Te),l=Math.imul(q,Pe),l=l+Math.imul(ae,Te)|0,m=Math.imul(ae,Pe),v=v+Math.imul(N,De)|0,l=l+Math.imul(N,je)|0,l=l+Math.imul(F,De)|0,m=m+Math.imul(F,je)|0;var Ot=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,v=Math.imul(we,Te),l=Math.imul(we,Pe),l=l+Math.imul(Se,Te)|0,m=Math.imul(Se,Pe),v=v+Math.imul(q,De)|0,l=l+Math.imul(q,je)|0,l=l+Math.imul(ae,De)|0,m=m+Math.imul(ae,je)|0,v=v+Math.imul(N,Le)|0,l=l+Math.imul(N,Ge)|0,l=l+Math.imul(F,Le)|0,m=m+Math.imul(F,Ge)|0;var sr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(sr>>>26)|0,sr&=67108863,v=Math.imul(re,Te),l=Math.imul(re,Pe),l=l+Math.imul(_e,Te)|0,m=Math.imul(_e,Pe),v=v+Math.imul(we,De)|0,l=l+Math.imul(we,je)|0,l=l+Math.imul(Se,De)|0,m=m+Math.imul(Se,je)|0,v=v+Math.imul(q,Le)|0,l=l+Math.imul(q,Ge)|0,l=l+Math.imul(ae,Le)|0,m=m+Math.imul(ae,Ge)|0,v=v+Math.imul(N,Be)|0,l=l+Math.imul(N,Ye)|0,l=l+Math.imul(F,Be)|0,m=m+Math.imul(F,Ye)|0;var Ht=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,v=Math.imul(ve,Te),l=Math.imul(ve,Pe),l=l+Math.imul(Z,Te)|0,m=Math.imul(Z,Pe),v=v+Math.imul(re,De)|0,l=l+Math.imul(re,je)|0,l=l+Math.imul(_e,De)|0,m=m+Math.imul(_e,je)|0,v=v+Math.imul(we,Le)|0,l=l+Math.imul(we,Ge)|0,l=l+Math.imul(Se,Le)|0,m=m+Math.imul(Se,Ge)|0,v=v+Math.imul(q,Be)|0,l=l+Math.imul(q,Ye)|0,l=l+Math.imul(ae,Be)|0,m=m+Math.imul(ae,Ye)|0,v=v+Math.imul(N,Ue)|0,l=l+Math.imul(N,et)|0,l=l+Math.imul(F,Ue)|0,m=m+Math.imul(F,et)|0;var hr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(hr>>>26)|0,hr&=67108863,v=Math.imul(K,Te),l=Math.imul(K,Pe),l=l+Math.imul(le,Te)|0,m=Math.imul(le,Pe),v=v+Math.imul(ve,De)|0,l=l+Math.imul(ve,je)|0,l=l+Math.imul(Z,De)|0,m=m+Math.imul(Z,je)|0,v=v+Math.imul(re,Le)|0,l=l+Math.imul(re,Ge)|0,l=l+Math.imul(_e,Le)|0,m=m+Math.imul(_e,Ge)|0,v=v+Math.imul(we,Be)|0,l=l+Math.imul(we,Ye)|0,l=l+Math.imul(Se,Be)|0,m=m+Math.imul(Se,Ye)|0,v=v+Math.imul(q,Ue)|0,l=l+Math.imul(q,et)|0,l=l+Math.imul(ae,Ue)|0,m=m+Math.imul(ae,et)|0,v=v+Math.imul(N,Xe)|0,l=l+Math.imul(N,ot)|0,l=l+Math.imul(F,Xe)|0,m=m+Math.imul(F,ot)|0;var pr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(pr>>>26)|0,pr&=67108863,v=Math.imul(ce,Te),l=Math.imul(ce,Pe),l=l+Math.imul(de,Te)|0,m=Math.imul(de,Pe),v=v+Math.imul(K,De)|0,l=l+Math.imul(K,je)|0,l=l+Math.imul(le,De)|0,m=m+Math.imul(le,je)|0,v=v+Math.imul(ve,Le)|0,l=l+Math.imul(ve,Ge)|0,l=l+Math.imul(Z,Le)|0,m=m+Math.imul(Z,Ge)|0,v=v+Math.imul(re,Be)|0,l=l+Math.imul(re,Ye)|0,l=l+Math.imul(_e,Be)|0,m=m+Math.imul(_e,Ye)|0,v=v+Math.imul(we,Ue)|0,l=l+Math.imul(we,et)|0,l=l+Math.imul(Se,Ue)|0,m=m+Math.imul(Se,et)|0,v=v+Math.imul(q,Xe)|0,l=l+Math.imul(q,ot)|0,l=l+Math.imul(ae,Xe)|0,m=m+Math.imul(ae,ot)|0,v=v+Math.imul(N,Ve)|0,l=l+Math.imul(N,Je)|0,l=l+Math.imul(F,Ve)|0,m=m+Math.imul(F,Je)|0;var _r=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(_r>>>26)|0,_r&=67108863,v=Math.imul(ye,Te),l=Math.imul(ye,Pe),l=l+Math.imul(be,Te)|0,m=Math.imul(be,Pe),v=v+Math.imul(ce,De)|0,l=l+Math.imul(ce,je)|0,l=l+Math.imul(de,De)|0,m=m+Math.imul(de,je)|0,v=v+Math.imul(K,Le)|0,l=l+Math.imul(K,Ge)|0,l=l+Math.imul(le,Le)|0,m=m+Math.imul(le,Ge)|0,v=v+Math.imul(ve,Be)|0,l=l+Math.imul(ve,Ye)|0,l=l+Math.imul(Z,Be)|0,m=m+Math.imul(Z,Ye)|0,v=v+Math.imul(re,Ue)|0,l=l+Math.imul(re,et)|0,l=l+Math.imul(_e,Ue)|0,m=m+Math.imul(_e,et)|0,v=v+Math.imul(we,Xe)|0,l=l+Math.imul(we,ot)|0,l=l+Math.imul(Se,Xe)|0,m=m+Math.imul(Se,ot)|0,v=v+Math.imul(q,Ve)|0,l=l+Math.imul(q,Je)|0,l=l+Math.imul(ae,Ve)|0,m=m+Math.imul(ae,Je)|0,v=v+Math.imul(N,We)|0,l=l+Math.imul(N,it)|0,l=l+Math.imul(F,We)|0,m=m+Math.imul(F,it)|0;var Sr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,v=Math.imul(Oe,Te),l=Math.imul(Oe,Pe),l=l+Math.imul($e,Te)|0,m=Math.imul($e,Pe),v=v+Math.imul(ye,De)|0,l=l+Math.imul(ye,je)|0,l=l+Math.imul(be,De)|0,m=m+Math.imul(be,je)|0,v=v+Math.imul(ce,Le)|0,l=l+Math.imul(ce,Ge)|0,l=l+Math.imul(de,Le)|0,m=m+Math.imul(de,Ge)|0,v=v+Math.imul(K,Be)|0,l=l+Math.imul(K,Ye)|0,l=l+Math.imul(le,Be)|0,m=m+Math.imul(le,Ye)|0,v=v+Math.imul(ve,Ue)|0,l=l+Math.imul(ve,et)|0,l=l+Math.imul(Z,Ue)|0,m=m+Math.imul(Z,et)|0,v=v+Math.imul(re,Xe)|0,l=l+Math.imul(re,ot)|0,l=l+Math.imul(_e,Xe)|0,m=m+Math.imul(_e,ot)|0,v=v+Math.imul(we,Ve)|0,l=l+Math.imul(we,Je)|0,l=l+Math.imul(Se,Ve)|0,m=m+Math.imul(Se,Je)|0,v=v+Math.imul(q,We)|0,l=l+Math.imul(q,it)|0,l=l+Math.imul(ae,We)|0,m=m+Math.imul(ae,it)|0,v=v+Math.imul(N,Qe)|0,l=l+Math.imul(N,lt)|0,l=l+Math.imul(F,Qe)|0,m=m+Math.imul(F,lt)|0;var cr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(cr>>>26)|0,cr&=67108863,v=Math.imul(ze,Te),l=Math.imul(ze,Pe),l=l+Math.imul(He,Te)|0,m=Math.imul(He,Pe),v=v+Math.imul(Oe,De)|0,l=l+Math.imul(Oe,je)|0,l=l+Math.imul($e,De)|0,m=m+Math.imul($e,je)|0,v=v+Math.imul(ye,Le)|0,l=l+Math.imul(ye,Ge)|0,l=l+Math.imul(be,Le)|0,m=m+Math.imul(be,Ge)|0,v=v+Math.imul(ce,Be)|0,l=l+Math.imul(ce,Ye)|0,l=l+Math.imul(de,Be)|0,m=m+Math.imul(de,Ye)|0,v=v+Math.imul(K,Ue)|0,l=l+Math.imul(K,et)|0,l=l+Math.imul(le,Ue)|0,m=m+Math.imul(le,et)|0,v=v+Math.imul(ve,Xe)|0,l=l+Math.imul(ve,ot)|0,l=l+Math.imul(Z,Xe)|0,m=m+Math.imul(Z,ot)|0,v=v+Math.imul(re,Ve)|0,l=l+Math.imul(re,Je)|0,l=l+Math.imul(_e,Ve)|0,m=m+Math.imul(_e,Je)|0,v=v+Math.imul(we,We)|0,l=l+Math.imul(we,it)|0,l=l+Math.imul(Se,We)|0,m=m+Math.imul(Se,it)|0,v=v+Math.imul(q,Qe)|0,l=l+Math.imul(q,lt)|0,l=l+Math.imul(ae,Qe)|0,m=m+Math.imul(ae,lt)|0,v=v+Math.imul(N,qe)|0,l=l+Math.imul(N,at)|0,l=l+Math.imul(F,qe)|0,m=m+Math.imul(F,at)|0;var qt=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(qt>>>26)|0,qt&=67108863,v=Math.imul(ze,De),l=Math.imul(ze,je),l=l+Math.imul(He,De)|0,m=Math.imul(He,je),v=v+Math.imul(Oe,Le)|0,l=l+Math.imul(Oe,Ge)|0,l=l+Math.imul($e,Le)|0,m=m+Math.imul($e,Ge)|0,v=v+Math.imul(ye,Be)|0,l=l+Math.imul(ye,Ye)|0,l=l+Math.imul(be,Be)|0,m=m+Math.imul(be,Ye)|0,v=v+Math.imul(ce,Ue)|0,l=l+Math.imul(ce,et)|0,l=l+Math.imul(de,Ue)|0,m=m+Math.imul(de,et)|0,v=v+Math.imul(K,Xe)|0,l=l+Math.imul(K,ot)|0,l=l+Math.imul(le,Xe)|0,m=m+Math.imul(le,ot)|0,v=v+Math.imul(ve,Ve)|0,l=l+Math.imul(ve,Je)|0,l=l+Math.imul(Z,Ve)|0,m=m+Math.imul(Z,Je)|0,v=v+Math.imul(re,We)|0,l=l+Math.imul(re,it)|0,l=l+Math.imul(_e,We)|0,m=m+Math.imul(_e,it)|0,v=v+Math.imul(we,Qe)|0,l=l+Math.imul(we,lt)|0,l=l+Math.imul(Se,Qe)|0,m=m+Math.imul(Se,lt)|0,v=v+Math.imul(q,qe)|0,l=l+Math.imul(q,at)|0,l=l+Math.imul(ae,qe)|0,m=m+Math.imul(ae,at)|0;var lr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(lr>>>26)|0,lr&=67108863,v=Math.imul(ze,Le),l=Math.imul(ze,Ge),l=l+Math.imul(He,Le)|0,m=Math.imul(He,Ge),v=v+Math.imul(Oe,Be)|0,l=l+Math.imul(Oe,Ye)|0,l=l+Math.imul($e,Be)|0,m=m+Math.imul($e,Ye)|0,v=v+Math.imul(ye,Ue)|0,l=l+Math.imul(ye,et)|0,l=l+Math.imul(be,Ue)|0,m=m+Math.imul(be,et)|0,v=v+Math.imul(ce,Xe)|0,l=l+Math.imul(ce,ot)|0,l=l+Math.imul(de,Xe)|0,m=m+Math.imul(de,ot)|0,v=v+Math.imul(K,Ve)|0,l=l+Math.imul(K,Je)|0,l=l+Math.imul(le,Ve)|0,m=m+Math.imul(le,Je)|0,v=v+Math.imul(ve,We)|0,l=l+Math.imul(ve,it)|0,l=l+Math.imul(Z,We)|0,m=m+Math.imul(Z,it)|0,v=v+Math.imul(re,Qe)|0,l=l+Math.imul(re,lt)|0,l=l+Math.imul(_e,Qe)|0,m=m+Math.imul(_e,lt)|0,v=v+Math.imul(we,qe)|0,l=l+Math.imul(we,at)|0,l=l+Math.imul(Se,qe)|0,m=m+Math.imul(Se,at)|0;var br=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(br>>>26)|0,br&=67108863,v=Math.imul(ze,Be),l=Math.imul(ze,Ye),l=l+Math.imul(He,Be)|0,m=Math.imul(He,Ye),v=v+Math.imul(Oe,Ue)|0,l=l+Math.imul(Oe,et)|0,l=l+Math.imul($e,Ue)|0,m=m+Math.imul($e,et)|0,v=v+Math.imul(ye,Xe)|0,l=l+Math.imul(ye,ot)|0,l=l+Math.imul(be,Xe)|0,m=m+Math.imul(be,ot)|0,v=v+Math.imul(ce,Ve)|0,l=l+Math.imul(ce,Je)|0,l=l+Math.imul(de,Ve)|0,m=m+Math.imul(de,Je)|0,v=v+Math.imul(K,We)|0,l=l+Math.imul(K,it)|0,l=l+Math.imul(le,We)|0,m=m+Math.imul(le,it)|0,v=v+Math.imul(ve,Qe)|0,l=l+Math.imul(ve,lt)|0,l=l+Math.imul(Z,Qe)|0,m=m+Math.imul(Z,lt)|0,v=v+Math.imul(re,qe)|0,l=l+Math.imul(re,at)|0,l=l+Math.imul(_e,qe)|0,m=m+Math.imul(_e,at)|0;var Mr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,v=Math.imul(ze,Ue),l=Math.imul(ze,et),l=l+Math.imul(He,Ue)|0,m=Math.imul(He,et),v=v+Math.imul(Oe,Xe)|0,l=l+Math.imul(Oe,ot)|0,l=l+Math.imul($e,Xe)|0,m=m+Math.imul($e,ot)|0,v=v+Math.imul(ye,Ve)|0,l=l+Math.imul(ye,Je)|0,l=l+Math.imul(be,Ve)|0,m=m+Math.imul(be,Je)|0,v=v+Math.imul(ce,We)|0,l=l+Math.imul(ce,it)|0,l=l+Math.imul(de,We)|0,m=m+Math.imul(de,it)|0,v=v+Math.imul(K,Qe)|0,l=l+Math.imul(K,lt)|0,l=l+Math.imul(le,Qe)|0,m=m+Math.imul(le,lt)|0,v=v+Math.imul(ve,qe)|0,l=l+Math.imul(ve,at)|0,l=l+Math.imul(Z,qe)|0,m=m+Math.imul(Z,at)|0;var Er=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Er>>>26)|0,Er&=67108863,v=Math.imul(ze,Xe),l=Math.imul(ze,ot),l=l+Math.imul(He,Xe)|0,m=Math.imul(He,ot),v=v+Math.imul(Oe,Ve)|0,l=l+Math.imul(Oe,Je)|0,l=l+Math.imul($e,Ve)|0,m=m+Math.imul($e,Je)|0,v=v+Math.imul(ye,We)|0,l=l+Math.imul(ye,it)|0,l=l+Math.imul(be,We)|0,m=m+Math.imul(be,it)|0,v=v+Math.imul(ce,Qe)|0,l=l+Math.imul(ce,lt)|0,l=l+Math.imul(de,Qe)|0,m=m+Math.imul(de,lt)|0,v=v+Math.imul(K,qe)|0,l=l+Math.imul(K,at)|0,l=l+Math.imul(le,qe)|0,m=m+Math.imul(le,at)|0;var xr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(xr>>>26)|0,xr&=67108863,v=Math.imul(ze,Ve),l=Math.imul(ze,Je),l=l+Math.imul(He,Ve)|0,m=Math.imul(He,Je),v=v+Math.imul(Oe,We)|0,l=l+Math.imul(Oe,it)|0,l=l+Math.imul($e,We)|0,m=m+Math.imul($e,it)|0,v=v+Math.imul(ye,Qe)|0,l=l+Math.imul(ye,lt)|0,l=l+Math.imul(be,Qe)|0,m=m+Math.imul(be,lt)|0,v=v+Math.imul(ce,qe)|0,l=l+Math.imul(ce,at)|0,l=l+Math.imul(de,qe)|0,m=m+Math.imul(de,at)|0;var Pr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Pr>>>26)|0,Pr&=67108863,v=Math.imul(ze,We),l=Math.imul(ze,it),l=l+Math.imul(He,We)|0,m=Math.imul(He,it),v=v+Math.imul(Oe,Qe)|0,l=l+Math.imul(Oe,lt)|0,l=l+Math.imul($e,Qe)|0,m=m+Math.imul($e,lt)|0,v=v+Math.imul(ye,qe)|0,l=l+Math.imul(ye,at)|0,l=l+Math.imul(be,qe)|0,m=m+Math.imul(be,at)|0;var Or=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Or>>>26)|0,Or&=67108863,v=Math.imul(ze,Qe),l=Math.imul(ze,lt),l=l+Math.imul(He,Qe)|0,m=Math.imul(He,lt),v=v+Math.imul(Oe,qe)|0,l=l+Math.imul(Oe,at)|0,l=l+Math.imul($e,qe)|0,m=m+Math.imul($e,at)|0;var kr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(kr>>>26)|0,kr&=67108863,v=Math.imul(ze,qe),l=Math.imul(ze,at),l=l+Math.imul(He,qe)|0,m=Math.imul(He,at);var rr=(E+v|0)+((l&8191)<<13)|0;return E=(m+(l>>>13)|0)+(rr>>>26)|0,rr&=67108863,x[0]=Bt,x[1]=Ot,x[2]=sr,x[3]=Ht,x[4]=hr,x[5]=pr,x[6]=_r,x[7]=Sr,x[8]=cr,x[9]=qt,x[10]=lr,x[11]=br,x[12]=Mr,x[13]=Er,x[14]=xr,x[15]=Pr,x[16]=Or,x[17]=kr,x[18]=rr,E!==0&&(x[19]=E,c.length++),c};Math.imul||(C=M);function O(b,o,u){u.negative=o.negative^b.negative,u.length=b.length+o.length;for(var c=0,h=0,g=0;g>>26)|0,h+=x>>>26,x&=67108863}u.words[g]=E,c=x,x=h}return c!==0?u.words[g]=c:u.length--,u.strip()}function T(b,o,u){var c=new k;return c.mulp(b,o,u)}a.prototype.mulTo=function(o,u){var c,h=this.length+o.length;return this.length===10&&o.length===10?c=C(this,o,u):h<63?c=M(this,o,u):h<1024?c=O(this,o,u):c=T(this,o,u),c};function k(b,o){this.x=b,this.y=o}k.prototype.makeRBT=function(o){for(var u=new Array(o),c=a.prototype._countBits(o)-1,h=0;h>=1;return h},k.prototype.permute=function(o,u,c,h,g,x){for(var E=0;E>>1)g++;return 1<>>13,c[2*x+1]=g&8191,g=g>>>13;for(x=2*u;x>=26,u+=h/67108864|0,u+=g>>>26,this.words[c]=g&67108863}return u!==0&&(this.words[c]=u,this.length++),this},a.prototype.muln=function(o){return this.clone().imuln(o)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(o){var u=S(o);if(u.length===0)return new a(1);for(var c=this,h=0;h=0);var u=o%26,c=(o-u)/26,h=67108863>>>26-u<<26-u,g;if(u!==0){var x=0;for(g=0;g>>26-u}x&&(this.words[g]=x,this.length++)}if(c!==0){for(g=this.length-1;g>=0;g--)this.words[g+c]=this.words[g];for(g=0;g=0);var h;u?h=(u-u%26)/26:h=0;var g=o%26,x=Math.min((o-g)/26,this.length),E=67108863^67108863>>>g<x)for(this.length-=x,l=0;l=0&&(m!==0||l>=h);l--){var P=this.words[l]|0;this.words[l]=m<<26-g|P>>>g,m=P&E}return v&&m!==0&&(v.words[v.length++]=m),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},a.prototype.ishrn=function(o,u,c){return n(this.negative===0),this.iushrn(o,u,c)},a.prototype.shln=function(o){return this.clone().ishln(o)},a.prototype.ushln=function(o){return this.clone().iushln(o)},a.prototype.shrn=function(o){return this.clone().ishrn(o)},a.prototype.ushrn=function(o){return this.clone().iushrn(o)},a.prototype.testn=function(o){n(typeof o=="number"&&o>=0);var u=o%26,c=(o-u)/26,h=1<=0);var u=o%26,c=(o-u)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=c)return this;if(u!==0&&c++,this.length=Math.min(c,this.length),u!==0){var h=67108863^67108863>>>u<=67108864;u++)this.words[u]-=67108864,u===this.length-1?this.words[u+1]=1:this.words[u+1]++;return this.length=Math.max(this.length,u+1),this},a.prototype.isubn=function(o){if(n(typeof o=="number"),n(o<67108864),o<0)return this.iaddn(-o);if(this.negative!==0)return this.negative=0,this.iaddn(o),this.negative=1,this;if(this.words[0]-=o,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var u=0;u>26)-(v/67108864|0),this.words[g+c]=x&67108863}for(;g>26,this.words[g+c]=x&67108863;if(E===0)return this.strip();for(n(E===-1),E=0,g=0;g>26,this.words[g]=x&67108863;return this.negative=1,this.strip()},a.prototype._wordDiv=function(o,u){var c=this.length-o.length,h=this.clone(),g=o,x=g.words[g.length-1]|0,E=this._countBits(x);c=26-E,c!==0&&(g=g.ushln(c),h.iushln(c),x=g.words[g.length-1]|0);var v=h.length-g.length,l;if(u!=="mod"){l=new a(null),l.length=v+1,l.words=new Array(l.length);for(var m=0;m=0;N--){var F=(h.words[g.length+N]|0)*67108864+(h.words[g.length+N-1]|0);for(F=Math.min(F/x|0,67108863),h._ishlnsubmul(g,F,N);h.negative!==0;)F--,h.negative=0,h._ishlnsubmul(g,1,N),h.isZero()||(h.negative^=1);l&&(l.words[N]=F)}return l&&l.strip(),h.strip(),u!=="div"&&c!==0&&h.iushrn(c),{div:l||null,mod:h}},a.prototype.divmod=function(o,u,c){if(n(!o.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var h,g,x;return this.negative!==0&&o.negative===0?(x=this.neg().divmod(o,u),u!=="mod"&&(h=x.div.neg()),u!=="div"&&(g=x.mod.neg(),c&&g.negative!==0&&g.iadd(o)),{div:h,mod:g}):this.negative===0&&o.negative!==0?(x=this.divmod(o.neg(),u),u!=="mod"&&(h=x.div.neg()),{div:h,mod:x.mod}):this.negative&o.negative?(x=this.neg().divmod(o.neg(),u),u!=="div"&&(g=x.mod.neg(),c&&g.negative!==0&&g.isub(o)),{div:x.div,mod:g}):o.length>this.length||this.cmp(o)<0?{div:new a(0),mod:this}:o.length===1?u==="div"?{div:this.divn(o.words[0]),mod:null}:u==="mod"?{div:null,mod:new a(this.modn(o.words[0]))}:{div:this.divn(o.words[0]),mod:new a(this.modn(o.words[0]))}:this._wordDiv(o,u)},a.prototype.div=function(o){return this.divmod(o,"div",!1).div},a.prototype.mod=function(o){return this.divmod(o,"mod",!1).mod},a.prototype.umod=function(o){return this.divmod(o,"mod",!0).mod},a.prototype.divRound=function(o){var u=this.divmod(o);if(u.mod.isZero())return u.div;var c=u.div.negative!==0?u.mod.isub(o):u.mod,h=o.ushrn(1),g=o.andln(1),x=c.cmp(h);return x<0||g===1&&x===0?u.div:u.div.negative!==0?u.div.isubn(1):u.div.iaddn(1)},a.prototype.modn=function(o){n(o<=67108863);for(var u=(1<<26)%o,c=0,h=this.length-1;h>=0;h--)c=(u*c+(this.words[h]|0))%o;return c},a.prototype.idivn=function(o){n(o<=67108863);for(var u=0,c=this.length-1;c>=0;c--){var h=(this.words[c]|0)+u*67108864;this.words[c]=h/o|0,u=h%o}return this.strip()},a.prototype.divn=function(o){return this.clone().idivn(o)},a.prototype.egcd=function(o){n(o.negative===0),n(!o.isZero());var u=this,c=o.clone();u.negative!==0?u=u.umod(o):u=u.clone();for(var h=new a(1),g=new a(0),x=new a(0),E=new a(1),v=0;u.isEven()&&c.isEven();)u.iushrn(1),c.iushrn(1),++v;for(var l=c.clone(),m=u.clone();!u.isZero();){for(var P=0,N=1;!(u.words[0]&N)&&P<26;++P,N<<=1);if(P>0)for(u.iushrn(P);P-- >0;)(h.isOdd()||g.isOdd())&&(h.iadd(l),g.isub(m)),h.iushrn(1),g.iushrn(1);for(var F=0,ee=1;!(c.words[0]&ee)&&F<26;++F,ee<<=1);if(F>0)for(c.iushrn(F);F-- >0;)(x.isOdd()||E.isOdd())&&(x.iadd(l),E.isub(m)),x.iushrn(1),E.iushrn(1);u.cmp(c)>=0?(u.isub(c),h.isub(x),g.isub(E)):(c.isub(u),x.isub(h),E.isub(g))}return{a:x,b:E,gcd:c.iushln(v)}},a.prototype._invmp=function(o){n(o.negative===0),n(!o.isZero());var u=this,c=o.clone();u.negative!==0?u=u.umod(o):u=u.clone();for(var h=new a(1),g=new a(0),x=c.clone();u.cmpn(1)>0&&c.cmpn(1)>0;){for(var E=0,v=1;!(u.words[0]&v)&&E<26;++E,v<<=1);if(E>0)for(u.iushrn(E);E-- >0;)h.isOdd()&&h.iadd(x),h.iushrn(1);for(var l=0,m=1;!(c.words[0]&m)&&l<26;++l,m<<=1);if(l>0)for(c.iushrn(l);l-- >0;)g.isOdd()&&g.iadd(x),g.iushrn(1);u.cmp(c)>=0?(u.isub(c),h.isub(g)):(c.isub(u),g.isub(h))}var P;return u.cmpn(1)===0?P=h:P=g,P.cmpn(0)<0&&P.iadd(o),P},a.prototype.gcd=function(o){if(this.isZero())return o.abs();if(o.isZero())return this.abs();var u=this.clone(),c=o.clone();u.negative=0,c.negative=0;for(var h=0;u.isEven()&&c.isEven();h++)u.iushrn(1),c.iushrn(1);do{for(;u.isEven();)u.iushrn(1);for(;c.isEven();)c.iushrn(1);var g=u.cmp(c);if(g<0){var x=u;u=c,c=x}else if(g===0||c.cmpn(1)===0)break;u.isub(c)}while(!0);return c.iushln(h)},a.prototype.invm=function(o){return this.egcd(o).a.umod(o)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(o){return this.words[0]&o},a.prototype.bincn=function(o){n(typeof o=="number");var u=o%26,c=(o-u)/26,h=1<>>26,E&=67108863,this.words[x]=E}return g!==0&&(this.words[x]=g,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(o){var u=o<0;if(this.negative!==0&&!u)return-1;if(this.negative===0&&u)return 1;this.strip();var c;if(this.length>1)c=1;else{u&&(o=-o),n(o<=67108863,"Number is too big");var h=this.words[0]|0;c=h===o?0:ho.length)return 1;if(this.length=0;c--){var h=this.words[c]|0,g=o.words[c]|0;if(h!==g){hg&&(u=1);break}}return u},a.prototype.gtn=function(o){return this.cmpn(o)===1},a.prototype.gt=function(o){return this.cmp(o)===1},a.prototype.gten=function(o){return this.cmpn(o)>=0},a.prototype.gte=function(o){return this.cmp(o)>=0},a.prototype.ltn=function(o){return this.cmpn(o)===-1},a.prototype.lt=function(o){return this.cmp(o)===-1},a.prototype.lten=function(o){return this.cmpn(o)<=0},a.prototype.lte=function(o){return this.cmp(o)<=0},a.prototype.eqn=function(o){return this.cmpn(o)===0},a.prototype.eq=function(o){return this.cmp(o)===0},a.red=function(o){return new z(o)},a.prototype.toRed=function(o){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),o.convertTo(this)._forceRed(o)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(o){return this.red=o,this},a.prototype.forceRed=function(o){return n(!this.red,"Already a number in reduction context"),this._forceRed(o)},a.prototype.redAdd=function(o){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,o)},a.prototype.redIAdd=function(o){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,o)},a.prototype.redSub=function(o){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,o)},a.prototype.redISub=function(o){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,o)},a.prototype.redShl=function(o){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,o)},a.prototype.redMul=function(o){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,o),this.red.mul(this,o)},a.prototype.redIMul=function(o){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,o),this.red.imul(this,o)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(o){return n(this.red&&!o.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,o)};var R={k256:null,p224:null,p192:null,p25519:null};function $(b,o){this.name=b,this.p=new a(o,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}$.prototype._tmp=function(){var o=new a(null);return o.words=new Array(Math.ceil(this.n/13)),o},$.prototype.ireduce=function(o){var u=o,c;do this.split(u,this.tmp),u=this.imulK(u),u=u.iadd(this.tmp),c=u.bitLength();while(c>this.n);var h=c0?u.isub(this.p):u.strip!==void 0?u.strip():u._strip(),u},$.prototype.split=function(o,u){o.iushrn(this.n,0,u)},$.prototype.imulK=function(o){return o.imul(this.k)};function L(){$.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}i(L,$),L.prototype.split=function(o,u){for(var c=4194303,h=Math.min(o.length,9),g=0;g>>22,x=E}x>>>=22,o.words[g-10]=x,x===0&&o.length>10?o.length-=10:o.length-=9},L.prototype.imulK=function(o){o.words[o.length]=0,o.words[o.length+1]=0,o.length+=2;for(var u=0,c=0;c>>=26,o.words[c]=g,u=h}return u!==0&&(o.words[o.length++]=u),o},a._prime=function(o){if(R[o])return R[o];var u;if(o==="k256")u=new L;else if(o==="p224")u=new j;else if(o==="p192")u=new A;else if(o==="p25519")u=new V;else throw new Error("Unknown prime "+o);return R[o]=u,u};function z(b){if(typeof b=="string"){var o=a._prime(b);this.m=o.p,this.prime=o}else n(b.gtn(1),"modulus must be greater than 1"),this.m=b,this.prime=null}z.prototype._verify1=function(o){n(o.negative===0,"red works only with positives"),n(o.red,"red works only with red numbers")},z.prototype._verify2=function(o,u){n((o.negative|u.negative)===0,"red works only with positives"),n(o.red&&o.red===u.red,"red works only with red numbers")},z.prototype.imod=function(o){return this.prime?this.prime.ireduce(o)._forceRed(this):o.umod(this.m)._forceRed(this)},z.prototype.neg=function(o){return o.isZero()?o.clone():this.m.sub(o)._forceRed(this)},z.prototype.add=function(o,u){this._verify2(o,u);var c=o.add(u);return c.cmp(this.m)>=0&&c.isub(this.m),c._forceRed(this)},z.prototype.iadd=function(o,u){this._verify2(o,u);var c=o.iadd(u);return c.cmp(this.m)>=0&&c.isub(this.m),c},z.prototype.sub=function(o,u){this._verify2(o,u);var c=o.sub(u);return c.cmpn(0)<0&&c.iadd(this.m),c._forceRed(this)},z.prototype.isub=function(o,u){this._verify2(o,u);var c=o.isub(u);return c.cmpn(0)<0&&c.iadd(this.m),c},z.prototype.shl=function(o,u){return this._verify1(o),this.imod(o.ushln(u))},z.prototype.imul=function(o,u){return this._verify2(o,u),this.imod(o.imul(u))},z.prototype.mul=function(o,u){return this._verify2(o,u),this.imod(o.mul(u))},z.prototype.isqr=function(o){return this.imul(o,o.clone())},z.prototype.sqr=function(o){return this.mul(o,o)},z.prototype.sqrt=function(o){if(o.isZero())return o.clone();var u=this.m.andln(3);if(n(u%2===1),u===3){var c=this.m.add(new a(1)).iushrn(2);return this.pow(o,c)}for(var h=this.m.subn(1),g=0;!h.isZero()&&h.andln(1)===0;)g++,h.iushrn(1);n(!h.isZero());var x=new a(1).toRed(this),E=x.redNeg(),v=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new a(2*l*l).toRed(this);this.pow(l,v).cmp(E)!==0;)l.redIAdd(E);for(var m=this.pow(l,h),P=this.pow(o,h.addn(1).iushrn(1)),N=this.pow(o,h),F=g;N.cmp(x)!==0;){for(var ee=N,q=0;ee.cmp(x)!==0;q++)ee=ee.redSqr();n(q=0;g--){for(var m=u.words[g],P=l-1;P>=0;P--){var N=m>>P&1;if(x!==h[0]&&(x=this.sqr(x)),N===0&&E===0){v=0;continue}E<<=1,E|=N,v++,!(v!==c&&(g!==0||P!==0))&&(x=this.mul(x,h[E]),v=0,E=0)}l=26}return x},z.prototype.convertTo=function(o){var u=o.umod(this.m);return u===o?u.clone():u},z.prototype.convertFrom=function(o){var u=o.clone();return u.red=null,u},a.mont=function(o){return new Y(o)};function Y(b){z.call(this,b),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}i(Y,z),Y.prototype.convertTo=function(o){return this.imod(o.ushln(this.shift))},Y.prototype.convertFrom=function(o){var u=this.imod(o.mul(this.rinv));return u.red=null,u},Y.prototype.imul=function(o,u){if(o.isZero()||u.isZero())return o.words[0]=0,o.length=1,o;var c=o.imul(u),h=c.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),g=c.isub(h).iushrn(this.shift),x=g;return g.cmp(this.m)>=0?x=g.isub(this.m):g.cmpn(0)<0&&(x=g.iadd(this.m)),x._forceRed(this)},Y.prototype.mul=function(o,u){if(o.isZero()||u.isZero())return new a(0)._forceRed(this);var c=o.mul(u),h=c.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),g=c.isub(h).iushrn(this.shift),x=g;return g.cmp(this.m)>=0?x=g.isub(this.m):g.cmpn(0)<0&&(x=g.iadd(this.m)),x._forceRed(this)},Y.prototype.invm=function(o){var u=this.imod(o._invmp(this.m).mul(this.r2));return u._forceRed(this)}})(e,Ut)})(w5);var uee=w5.exports,Lm={exports:{}},xT;function b5(){if(xT)return Lm.exports;xT=1;var e;Lm.exports=function(i){return e||(e=new t(null)),e.generate(i)};function t(n){this.rand=n}if(Lm.exports.Rand=t,t.prototype.generate=function(i){return this._rand(i)},t.prototype._rand=function(i){if(this.rand.getBytes)return this.rand.getBytes(i);for(var a=new Uint8Array(i),s=0;s=0);return f},r.prototype._randrange=function(i,a){var s=a.sub(i);return i.add(this._randbelow(s))},r.prototype.test=function(i,a,s){var f=i.bitLength(),d=e.mont(i),p=new e(1).toRed(d);a||(a=Math.max(1,f/48|0));for(var y=i.subn(1),w=0;!y.testn(w);w++);for(var _=i.shrn(w),S=y.toRed(d),M=!0;a>0;a--){var C=this._randrange(new e(2),y);s&&s(C);var O=C.toRed(d).redPow(_);if(!(O.cmp(p)===0||O.cmp(S)===0)){for(var T=1;T0;a--){var S=this._randrange(new e(2),p),M=i.gcd(S);if(M.cmpn(1)!==0)return M;var C=S.toRed(f).redPow(w);if(!(C.cmp(d)===0||C.cmp(_)===0)){for(var O=1;OT;)R.ishrn(1);if(R.isEven()&&R.iadd(a),R.testn(1)||R.iadd(s),k.cmp(s)){if(!k.cmp(f))for(;R.mod(d).cmp(p);)R.iadd(w)}else for(;R.mod(r).cmp(y);)R.iadd(w);if($=R.shrn(1),M($)&&M(R)&&C($)&&C(R)&&i.test($)&&i.test(R))return R}}return j2}const cee={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},fee={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},dee={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},hee={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},pee={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},mee={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},vee={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},gee={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"},yee={modp1:cee,modp2:fee,modp5:dee,modp14:hee,modp15:pee,modp16:mee,modp17:vee,modp18:gee};var B2,MT;function wee(){if(MT)return B2;MT=1;var e=WI,t=KI(),r=new t,n=new e(24),i=new e(11),a=new e(10),s=new e(3),f=new e(7),d=GI(),p=Td;B2=M;function y(O,T){return T=T||"utf8",rt.isBuffer(O)||(O=new rt(O,T)),this._pub=new e(O),this}function w(O,T){return T=T||"utf8",rt.isBuffer(O)||(O=new rt(O,T)),this._priv=new e(O),this}var _={};function S(O,T){var k=T.toString("hex"),R=[k,O.toString(16)].join("_");if(R in _)return _[R];var $=0;if(O.isEven()||!d.simpleSieve||!d.fermatTest(O)||!r.test(O))return $+=1,k==="02"||k==="05"?$+=8:$+=4,_[R]=$,$;r.test(O.shrn(1))||($+=2);var L;switch(k){case"02":O.mod(n).cmp(i)&&($+=8);break;case"05":L=O.mod(a),L.cmp(s)&&L.cmp(f)&&($+=8);break;default:$+=4}return _[R]=$,$}function M(O,T,k){this.setGenerator(T),this.__prime=new e(O),this._prime=e.mont(this.__prime),this._primeLen=O.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,k?(this.setPublicKey=y,this.setPrivateKey=w):this._primeCode=8}Object.defineProperty(M.prototype,"verifyError",{enumerable:!0,get:function(){return typeof this._primeCode!="number"&&(this._primeCode=S(this.__prime,this.__gen)),this._primeCode}}),M.prototype.generateKeys=function(){return this._priv||(this._priv=new e(p(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},M.prototype.computeSecret=function(O){O=new e(O),O=O.toRed(this._prime);var T=O.redPow(this._priv).fromRed(),k=new rt(T.toArray()),R=this.getPrime();if(k.length0?c:h},a.min=function(c,h){return c.cmp(h)<0?c:h},a.prototype._init=function(c,h,g){if(typeof c=="number")return this._initNumber(c,h,g);if(typeof c=="object")return this._initArray(c,h,g);h==="hex"&&(h=16),n(h===(h|0)&&h>=2&&h<=36),c=c.toString().replace(/\s+/g,"");var x=0;c[0]==="-"&&(x++,this.negative=1),x=0;x-=3)v=c[x]|c[x-1]<<8|c[x-2]<<16,this.words[E]|=v<>>26-l&67108863,l+=24,l>=26&&(l-=26,E++);else if(g==="le")for(x=0,E=0;x>>26-l&67108863,l+=24,l>=26&&(l-=26,E++);return this._strip()};function f(u,c){var h=u.charCodeAt(c);if(h>=48&&h<=57)return h-48;if(h>=65&&h<=70)return h-55;if(h>=97&&h<=102)return h-87;n(!1,"Invalid character in "+u)}function d(u,c,h){var g=f(u,h);return h-1>=c&&(g|=f(u,h-1)<<4),g}a.prototype._parseHex=function(c,h,g){this.length=Math.ceil((c.length-h)/6),this.words=new Array(this.length);for(var x=0;x=h;x-=2)l=d(c,h,x)<=18?(E-=18,v+=1,this.words[v]|=l>>>26):E+=8;else{var m=c.length-h;for(x=m%2===0?h+1:h;x=18?(E-=18,v+=1,this.words[v]|=l>>>26):E+=8}this._strip()};function p(u,c,h,g){for(var x=0,E=0,v=Math.min(u.length,h),l=c;l=49?E=m-49+10:m>=17?E=m-17+10:E=m,n(m>=0&&E1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},typeof Symbol<"u"&&typeof Symbol.for=="function")try{a.prototype[Symbol.for("nodejs.util.inspect.custom")]=w}catch{a.prototype.inspect=w}else a.prototype.inspect=w;function w(){return(this.red?""}var _=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],S=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],M=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(c,h){c=c||10,h=h|0||1;var g;if(c===16||c==="hex"){g="";for(var x=0,E=0,v=0;v>>24-x&16777215,x+=2,x>=26&&(x-=26,v--),E!==0||v!==this.length-1?g=_[6-m.length]+m+g:g=m+g}for(E!==0&&(g=E.toString(16)+g);g.length%h!==0;)g="0"+g;return this.negative!==0&&(g="-"+g),g}if(c===(c|0)&&c>=2&&c<=36){var P=S[c],N=M[c];g="";var F=this.clone();for(F.negative=0;!F.isZero();){var ee=F.modrn(N).toString(c);F=F.idivn(N),F.isZero()?g=ee+g:g=_[P-ee.length]+ee+g}for(this.isZero()&&(g="0"+g);g.length%h!==0;)g="0"+g;return this.negative!==0&&(g="-"+g),g}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var c=this.words[0];return this.length===2?c+=this.words[1]*67108864:this.length===3&&this.words[2]===1?c+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-c:c},a.prototype.toJSON=function(){return this.toString(16,2)},s&&(a.prototype.toBuffer=function(c,h){return this.toArrayLike(s,c,h)}),a.prototype.toArray=function(c,h){return this.toArrayLike(Array,c,h)};var C=function(c,h){return c.allocUnsafe?c.allocUnsafe(h):new c(h)};a.prototype.toArrayLike=function(c,h,g){this._strip();var x=this.byteLength(),E=g||Math.max(1,x);n(x<=E,"byte array longer than desired length"),n(E>0,"Requested array length <= 0");var v=C(c,E),l=h==="le"?"LE":"BE";return this["_toArrayLike"+l](v,x),v},a.prototype._toArrayLikeLE=function(c,h){for(var g=0,x=0,E=0,v=0;E>8&255),g>16&255),v===6?(g>24&255),x=0,v=0):(x=l>>>24,v+=2)}if(g=0&&(c[g--]=l>>8&255),g>=0&&(c[g--]=l>>16&255),v===6?(g>=0&&(c[g--]=l>>24&255),x=0,v=0):(x=l>>>24,v+=2)}if(g>=0)for(c[g--]=x;g>=0;)c[g--]=0},Math.clz32?a.prototype._countBits=function(c){return 32-Math.clz32(c)}:a.prototype._countBits=function(c){var h=c,g=0;return h>=4096&&(g+=13,h>>>=13),h>=64&&(g+=7,h>>>=7),h>=8&&(g+=4,h>>>=4),h>=2&&(g+=2,h>>>=2),g+h},a.prototype._zeroBits=function(c){if(c===0)return 26;var h=c,g=0;return h&8191||(g+=13,h>>>=13),h&127||(g+=7,h>>>=7),h&15||(g+=4,h>>>=4),h&3||(g+=2,h>>>=2),h&1||g++,g},a.prototype.bitLength=function(){var c=this.words[this.length-1],h=this._countBits(c);return(this.length-1)*26+h};function O(u){for(var c=new Array(u.bitLength()),h=0;h>>x&1}return c}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var c=0,h=0;hc.length?this.clone().ior(c):c.clone().ior(this)},a.prototype.uor=function(c){return this.length>c.length?this.clone().iuor(c):c.clone().iuor(this)},a.prototype.iuand=function(c){var h;this.length>c.length?h=c:h=this;for(var g=0;gc.length?this.clone().iand(c):c.clone().iand(this)},a.prototype.uand=function(c){return this.length>c.length?this.clone().iuand(c):c.clone().iuand(this)},a.prototype.iuxor=function(c){var h,g;this.length>c.length?(h=this,g=c):(h=c,g=this);for(var x=0;xc.length?this.clone().ixor(c):c.clone().ixor(this)},a.prototype.uxor=function(c){return this.length>c.length?this.clone().iuxor(c):c.clone().iuxor(this)},a.prototype.inotn=function(c){n(typeof c=="number"&&c>=0);var h=Math.ceil(c/26)|0,g=c%26;this._expand(h),g>0&&h--;for(var x=0;x0&&(this.words[x]=~this.words[x]&67108863>>26-g),this._strip()},a.prototype.notn=function(c){return this.clone().inotn(c)},a.prototype.setn=function(c,h){n(typeof c=="number"&&c>=0);var g=c/26|0,x=c%26;return this._expand(g+1),h?this.words[g]=this.words[g]|1<c.length?(g=this,x=c):(g=c,x=this);for(var E=0,v=0;v>>26;for(;E!==0&&v>>26;if(this.length=g.length,E!==0)this.words[this.length]=E,this.length++;else if(g!==this)for(;vc.length?this.clone().iadd(c):c.clone().iadd(this)},a.prototype.isub=function(c){if(c.negative!==0){c.negative=0;var h=this.iadd(c);return c.negative=1,h._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(c),this.negative=1,this._normSign();var g=this.cmp(c);if(g===0)return this.negative=0,this.length=1,this.words[0]=0,this;var x,E;g>0?(x=this,E=c):(x=c,E=this);for(var v=0,l=0;l>26,this.words[l]=h&67108863;for(;v!==0&&l>26,this.words[l]=h&67108863;if(v===0&&l>>26,F=m&67108863,ee=Math.min(P,c.length-1),q=Math.max(0,P-u.length+1);q<=ee;q++){var ae=P-q|0;x=u.words[ae]|0,E=c.words[q]|0,v=x*E+F,N+=v/67108864|0,F=v&67108863}h.words[P]=F|0,m=N|0}return m!==0?h.words[P]=m|0:h.length--,h._strip()}var k=function(c,h,g){var x=c.words,E=h.words,v=g.words,l=0,m,P,N,F=x[0]|0,ee=F&8191,q=F>>>13,ae=x[1]|0,pe=ae&8191,we=ae>>>13,Se=x[2]|0,he=Se&8191,re=Se>>>13,_e=x[3]|0,W=_e&8191,ve=_e>>>13,Z=x[4]|0,ne=Z&8191,K=Z>>>13,le=x[5]|0,xe=le&8191,ce=le>>>13,de=x[6]|0,Ae=de&8191,ye=de>>>13,be=x[7]|0,tt=be&8191,Oe=be>>>13,$e=x[8]|0,Et=$e&8191,ze=$e>>>13,He=x[9]|0,Fe=He&8191,Te=He>>>13,Pe=E[0]|0,pt=Pe&8191,De=Pe>>>13,je=E[1]|0,bt=je&8191,Le=je>>>13,Ge=E[2]|0,Ct=Ge&8191,Be=Ge>>>13,Ye=E[3]|0,Pt=Ye&8191,Ue=Ye>>>13,et=E[4]|0,Vt=et&8191,Xe=et>>>13,ot=E[5]|0,Kt=ot&8191,Ve=ot>>>13,Je=E[6]|0,It=Je&8191,We=Je>>>13,it=E[7]|0,jt=it&8191,Qe=it>>>13,lt=E[8]|0,Xt=lt&8191,qe=lt>>>13,at=E[9]|0,Bt=at&8191,Ot=at>>>13;g.negative=c.negative^h.negative,g.length=19,m=Math.imul(ee,pt),P=Math.imul(ee,De),P=P+Math.imul(q,pt)|0,N=Math.imul(q,De);var sr=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(sr>>>26)|0,sr&=67108863,m=Math.imul(pe,pt),P=Math.imul(pe,De),P=P+Math.imul(we,pt)|0,N=Math.imul(we,De),m=m+Math.imul(ee,bt)|0,P=P+Math.imul(ee,Le)|0,P=P+Math.imul(q,bt)|0,N=N+Math.imul(q,Le)|0;var Ht=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,m=Math.imul(he,pt),P=Math.imul(he,De),P=P+Math.imul(re,pt)|0,N=Math.imul(re,De),m=m+Math.imul(pe,bt)|0,P=P+Math.imul(pe,Le)|0,P=P+Math.imul(we,bt)|0,N=N+Math.imul(we,Le)|0,m=m+Math.imul(ee,Ct)|0,P=P+Math.imul(ee,Be)|0,P=P+Math.imul(q,Ct)|0,N=N+Math.imul(q,Be)|0;var hr=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(hr>>>26)|0,hr&=67108863,m=Math.imul(W,pt),P=Math.imul(W,De),P=P+Math.imul(ve,pt)|0,N=Math.imul(ve,De),m=m+Math.imul(he,bt)|0,P=P+Math.imul(he,Le)|0,P=P+Math.imul(re,bt)|0,N=N+Math.imul(re,Le)|0,m=m+Math.imul(pe,Ct)|0,P=P+Math.imul(pe,Be)|0,P=P+Math.imul(we,Ct)|0,N=N+Math.imul(we,Be)|0,m=m+Math.imul(ee,Pt)|0,P=P+Math.imul(ee,Ue)|0,P=P+Math.imul(q,Pt)|0,N=N+Math.imul(q,Ue)|0;var pr=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(pr>>>26)|0,pr&=67108863,m=Math.imul(ne,pt),P=Math.imul(ne,De),P=P+Math.imul(K,pt)|0,N=Math.imul(K,De),m=m+Math.imul(W,bt)|0,P=P+Math.imul(W,Le)|0,P=P+Math.imul(ve,bt)|0,N=N+Math.imul(ve,Le)|0,m=m+Math.imul(he,Ct)|0,P=P+Math.imul(he,Be)|0,P=P+Math.imul(re,Ct)|0,N=N+Math.imul(re,Be)|0,m=m+Math.imul(pe,Pt)|0,P=P+Math.imul(pe,Ue)|0,P=P+Math.imul(we,Pt)|0,N=N+Math.imul(we,Ue)|0,m=m+Math.imul(ee,Vt)|0,P=P+Math.imul(ee,Xe)|0,P=P+Math.imul(q,Vt)|0,N=N+Math.imul(q,Xe)|0;var _r=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(_r>>>26)|0,_r&=67108863,m=Math.imul(xe,pt),P=Math.imul(xe,De),P=P+Math.imul(ce,pt)|0,N=Math.imul(ce,De),m=m+Math.imul(ne,bt)|0,P=P+Math.imul(ne,Le)|0,P=P+Math.imul(K,bt)|0,N=N+Math.imul(K,Le)|0,m=m+Math.imul(W,Ct)|0,P=P+Math.imul(W,Be)|0,P=P+Math.imul(ve,Ct)|0,N=N+Math.imul(ve,Be)|0,m=m+Math.imul(he,Pt)|0,P=P+Math.imul(he,Ue)|0,P=P+Math.imul(re,Pt)|0,N=N+Math.imul(re,Ue)|0,m=m+Math.imul(pe,Vt)|0,P=P+Math.imul(pe,Xe)|0,P=P+Math.imul(we,Vt)|0,N=N+Math.imul(we,Xe)|0,m=m+Math.imul(ee,Kt)|0,P=P+Math.imul(ee,Ve)|0,P=P+Math.imul(q,Kt)|0,N=N+Math.imul(q,Ve)|0;var Sr=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,m=Math.imul(Ae,pt),P=Math.imul(Ae,De),P=P+Math.imul(ye,pt)|0,N=Math.imul(ye,De),m=m+Math.imul(xe,bt)|0,P=P+Math.imul(xe,Le)|0,P=P+Math.imul(ce,bt)|0,N=N+Math.imul(ce,Le)|0,m=m+Math.imul(ne,Ct)|0,P=P+Math.imul(ne,Be)|0,P=P+Math.imul(K,Ct)|0,N=N+Math.imul(K,Be)|0,m=m+Math.imul(W,Pt)|0,P=P+Math.imul(W,Ue)|0,P=P+Math.imul(ve,Pt)|0,N=N+Math.imul(ve,Ue)|0,m=m+Math.imul(he,Vt)|0,P=P+Math.imul(he,Xe)|0,P=P+Math.imul(re,Vt)|0,N=N+Math.imul(re,Xe)|0,m=m+Math.imul(pe,Kt)|0,P=P+Math.imul(pe,Ve)|0,P=P+Math.imul(we,Kt)|0,N=N+Math.imul(we,Ve)|0,m=m+Math.imul(ee,It)|0,P=P+Math.imul(ee,We)|0,P=P+Math.imul(q,It)|0,N=N+Math.imul(q,We)|0;var cr=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(cr>>>26)|0,cr&=67108863,m=Math.imul(tt,pt),P=Math.imul(tt,De),P=P+Math.imul(Oe,pt)|0,N=Math.imul(Oe,De),m=m+Math.imul(Ae,bt)|0,P=P+Math.imul(Ae,Le)|0,P=P+Math.imul(ye,bt)|0,N=N+Math.imul(ye,Le)|0,m=m+Math.imul(xe,Ct)|0,P=P+Math.imul(xe,Be)|0,P=P+Math.imul(ce,Ct)|0,N=N+Math.imul(ce,Be)|0,m=m+Math.imul(ne,Pt)|0,P=P+Math.imul(ne,Ue)|0,P=P+Math.imul(K,Pt)|0,N=N+Math.imul(K,Ue)|0,m=m+Math.imul(W,Vt)|0,P=P+Math.imul(W,Xe)|0,P=P+Math.imul(ve,Vt)|0,N=N+Math.imul(ve,Xe)|0,m=m+Math.imul(he,Kt)|0,P=P+Math.imul(he,Ve)|0,P=P+Math.imul(re,Kt)|0,N=N+Math.imul(re,Ve)|0,m=m+Math.imul(pe,It)|0,P=P+Math.imul(pe,We)|0,P=P+Math.imul(we,It)|0,N=N+Math.imul(we,We)|0,m=m+Math.imul(ee,jt)|0,P=P+Math.imul(ee,Qe)|0,P=P+Math.imul(q,jt)|0,N=N+Math.imul(q,Qe)|0;var qt=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(qt>>>26)|0,qt&=67108863,m=Math.imul(Et,pt),P=Math.imul(Et,De),P=P+Math.imul(ze,pt)|0,N=Math.imul(ze,De),m=m+Math.imul(tt,bt)|0,P=P+Math.imul(tt,Le)|0,P=P+Math.imul(Oe,bt)|0,N=N+Math.imul(Oe,Le)|0,m=m+Math.imul(Ae,Ct)|0,P=P+Math.imul(Ae,Be)|0,P=P+Math.imul(ye,Ct)|0,N=N+Math.imul(ye,Be)|0,m=m+Math.imul(xe,Pt)|0,P=P+Math.imul(xe,Ue)|0,P=P+Math.imul(ce,Pt)|0,N=N+Math.imul(ce,Ue)|0,m=m+Math.imul(ne,Vt)|0,P=P+Math.imul(ne,Xe)|0,P=P+Math.imul(K,Vt)|0,N=N+Math.imul(K,Xe)|0,m=m+Math.imul(W,Kt)|0,P=P+Math.imul(W,Ve)|0,P=P+Math.imul(ve,Kt)|0,N=N+Math.imul(ve,Ve)|0,m=m+Math.imul(he,It)|0,P=P+Math.imul(he,We)|0,P=P+Math.imul(re,It)|0,N=N+Math.imul(re,We)|0,m=m+Math.imul(pe,jt)|0,P=P+Math.imul(pe,Qe)|0,P=P+Math.imul(we,jt)|0,N=N+Math.imul(we,Qe)|0,m=m+Math.imul(ee,Xt)|0,P=P+Math.imul(ee,qe)|0,P=P+Math.imul(q,Xt)|0,N=N+Math.imul(q,qe)|0;var lr=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(lr>>>26)|0,lr&=67108863,m=Math.imul(Fe,pt),P=Math.imul(Fe,De),P=P+Math.imul(Te,pt)|0,N=Math.imul(Te,De),m=m+Math.imul(Et,bt)|0,P=P+Math.imul(Et,Le)|0,P=P+Math.imul(ze,bt)|0,N=N+Math.imul(ze,Le)|0,m=m+Math.imul(tt,Ct)|0,P=P+Math.imul(tt,Be)|0,P=P+Math.imul(Oe,Ct)|0,N=N+Math.imul(Oe,Be)|0,m=m+Math.imul(Ae,Pt)|0,P=P+Math.imul(Ae,Ue)|0,P=P+Math.imul(ye,Pt)|0,N=N+Math.imul(ye,Ue)|0,m=m+Math.imul(xe,Vt)|0,P=P+Math.imul(xe,Xe)|0,P=P+Math.imul(ce,Vt)|0,N=N+Math.imul(ce,Xe)|0,m=m+Math.imul(ne,Kt)|0,P=P+Math.imul(ne,Ve)|0,P=P+Math.imul(K,Kt)|0,N=N+Math.imul(K,Ve)|0,m=m+Math.imul(W,It)|0,P=P+Math.imul(W,We)|0,P=P+Math.imul(ve,It)|0,N=N+Math.imul(ve,We)|0,m=m+Math.imul(he,jt)|0,P=P+Math.imul(he,Qe)|0,P=P+Math.imul(re,jt)|0,N=N+Math.imul(re,Qe)|0,m=m+Math.imul(pe,Xt)|0,P=P+Math.imul(pe,qe)|0,P=P+Math.imul(we,Xt)|0,N=N+Math.imul(we,qe)|0,m=m+Math.imul(ee,Bt)|0,P=P+Math.imul(ee,Ot)|0,P=P+Math.imul(q,Bt)|0,N=N+Math.imul(q,Ot)|0;var br=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(br>>>26)|0,br&=67108863,m=Math.imul(Fe,bt),P=Math.imul(Fe,Le),P=P+Math.imul(Te,bt)|0,N=Math.imul(Te,Le),m=m+Math.imul(Et,Ct)|0,P=P+Math.imul(Et,Be)|0,P=P+Math.imul(ze,Ct)|0,N=N+Math.imul(ze,Be)|0,m=m+Math.imul(tt,Pt)|0,P=P+Math.imul(tt,Ue)|0,P=P+Math.imul(Oe,Pt)|0,N=N+Math.imul(Oe,Ue)|0,m=m+Math.imul(Ae,Vt)|0,P=P+Math.imul(Ae,Xe)|0,P=P+Math.imul(ye,Vt)|0,N=N+Math.imul(ye,Xe)|0,m=m+Math.imul(xe,Kt)|0,P=P+Math.imul(xe,Ve)|0,P=P+Math.imul(ce,Kt)|0,N=N+Math.imul(ce,Ve)|0,m=m+Math.imul(ne,It)|0,P=P+Math.imul(ne,We)|0,P=P+Math.imul(K,It)|0,N=N+Math.imul(K,We)|0,m=m+Math.imul(W,jt)|0,P=P+Math.imul(W,Qe)|0,P=P+Math.imul(ve,jt)|0,N=N+Math.imul(ve,Qe)|0,m=m+Math.imul(he,Xt)|0,P=P+Math.imul(he,qe)|0,P=P+Math.imul(re,Xt)|0,N=N+Math.imul(re,qe)|0,m=m+Math.imul(pe,Bt)|0,P=P+Math.imul(pe,Ot)|0,P=P+Math.imul(we,Bt)|0,N=N+Math.imul(we,Ot)|0;var Mr=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,m=Math.imul(Fe,Ct),P=Math.imul(Fe,Be),P=P+Math.imul(Te,Ct)|0,N=Math.imul(Te,Be),m=m+Math.imul(Et,Pt)|0,P=P+Math.imul(Et,Ue)|0,P=P+Math.imul(ze,Pt)|0,N=N+Math.imul(ze,Ue)|0,m=m+Math.imul(tt,Vt)|0,P=P+Math.imul(tt,Xe)|0,P=P+Math.imul(Oe,Vt)|0,N=N+Math.imul(Oe,Xe)|0,m=m+Math.imul(Ae,Kt)|0,P=P+Math.imul(Ae,Ve)|0,P=P+Math.imul(ye,Kt)|0,N=N+Math.imul(ye,Ve)|0,m=m+Math.imul(xe,It)|0,P=P+Math.imul(xe,We)|0,P=P+Math.imul(ce,It)|0,N=N+Math.imul(ce,We)|0,m=m+Math.imul(ne,jt)|0,P=P+Math.imul(ne,Qe)|0,P=P+Math.imul(K,jt)|0,N=N+Math.imul(K,Qe)|0,m=m+Math.imul(W,Xt)|0,P=P+Math.imul(W,qe)|0,P=P+Math.imul(ve,Xt)|0,N=N+Math.imul(ve,qe)|0,m=m+Math.imul(he,Bt)|0,P=P+Math.imul(he,Ot)|0,P=P+Math.imul(re,Bt)|0,N=N+Math.imul(re,Ot)|0;var Er=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(Er>>>26)|0,Er&=67108863,m=Math.imul(Fe,Pt),P=Math.imul(Fe,Ue),P=P+Math.imul(Te,Pt)|0,N=Math.imul(Te,Ue),m=m+Math.imul(Et,Vt)|0,P=P+Math.imul(Et,Xe)|0,P=P+Math.imul(ze,Vt)|0,N=N+Math.imul(ze,Xe)|0,m=m+Math.imul(tt,Kt)|0,P=P+Math.imul(tt,Ve)|0,P=P+Math.imul(Oe,Kt)|0,N=N+Math.imul(Oe,Ve)|0,m=m+Math.imul(Ae,It)|0,P=P+Math.imul(Ae,We)|0,P=P+Math.imul(ye,It)|0,N=N+Math.imul(ye,We)|0,m=m+Math.imul(xe,jt)|0,P=P+Math.imul(xe,Qe)|0,P=P+Math.imul(ce,jt)|0,N=N+Math.imul(ce,Qe)|0,m=m+Math.imul(ne,Xt)|0,P=P+Math.imul(ne,qe)|0,P=P+Math.imul(K,Xt)|0,N=N+Math.imul(K,qe)|0,m=m+Math.imul(W,Bt)|0,P=P+Math.imul(W,Ot)|0,P=P+Math.imul(ve,Bt)|0,N=N+Math.imul(ve,Ot)|0;var xr=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(xr>>>26)|0,xr&=67108863,m=Math.imul(Fe,Vt),P=Math.imul(Fe,Xe),P=P+Math.imul(Te,Vt)|0,N=Math.imul(Te,Xe),m=m+Math.imul(Et,Kt)|0,P=P+Math.imul(Et,Ve)|0,P=P+Math.imul(ze,Kt)|0,N=N+Math.imul(ze,Ve)|0,m=m+Math.imul(tt,It)|0,P=P+Math.imul(tt,We)|0,P=P+Math.imul(Oe,It)|0,N=N+Math.imul(Oe,We)|0,m=m+Math.imul(Ae,jt)|0,P=P+Math.imul(Ae,Qe)|0,P=P+Math.imul(ye,jt)|0,N=N+Math.imul(ye,Qe)|0,m=m+Math.imul(xe,Xt)|0,P=P+Math.imul(xe,qe)|0,P=P+Math.imul(ce,Xt)|0,N=N+Math.imul(ce,qe)|0,m=m+Math.imul(ne,Bt)|0,P=P+Math.imul(ne,Ot)|0,P=P+Math.imul(K,Bt)|0,N=N+Math.imul(K,Ot)|0;var Pr=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(Pr>>>26)|0,Pr&=67108863,m=Math.imul(Fe,Kt),P=Math.imul(Fe,Ve),P=P+Math.imul(Te,Kt)|0,N=Math.imul(Te,Ve),m=m+Math.imul(Et,It)|0,P=P+Math.imul(Et,We)|0,P=P+Math.imul(ze,It)|0,N=N+Math.imul(ze,We)|0,m=m+Math.imul(tt,jt)|0,P=P+Math.imul(tt,Qe)|0,P=P+Math.imul(Oe,jt)|0,N=N+Math.imul(Oe,Qe)|0,m=m+Math.imul(Ae,Xt)|0,P=P+Math.imul(Ae,qe)|0,P=P+Math.imul(ye,Xt)|0,N=N+Math.imul(ye,qe)|0,m=m+Math.imul(xe,Bt)|0,P=P+Math.imul(xe,Ot)|0,P=P+Math.imul(ce,Bt)|0,N=N+Math.imul(ce,Ot)|0;var Or=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(Or>>>26)|0,Or&=67108863,m=Math.imul(Fe,It),P=Math.imul(Fe,We),P=P+Math.imul(Te,It)|0,N=Math.imul(Te,We),m=m+Math.imul(Et,jt)|0,P=P+Math.imul(Et,Qe)|0,P=P+Math.imul(ze,jt)|0,N=N+Math.imul(ze,Qe)|0,m=m+Math.imul(tt,Xt)|0,P=P+Math.imul(tt,qe)|0,P=P+Math.imul(Oe,Xt)|0,N=N+Math.imul(Oe,qe)|0,m=m+Math.imul(Ae,Bt)|0,P=P+Math.imul(Ae,Ot)|0,P=P+Math.imul(ye,Bt)|0,N=N+Math.imul(ye,Ot)|0;var kr=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(kr>>>26)|0,kr&=67108863,m=Math.imul(Fe,jt),P=Math.imul(Fe,Qe),P=P+Math.imul(Te,jt)|0,N=Math.imul(Te,Qe),m=m+Math.imul(Et,Xt)|0,P=P+Math.imul(Et,qe)|0,P=P+Math.imul(ze,Xt)|0,N=N+Math.imul(ze,qe)|0,m=m+Math.imul(tt,Bt)|0,P=P+Math.imul(tt,Ot)|0,P=P+Math.imul(Oe,Bt)|0,N=N+Math.imul(Oe,Ot)|0;var rr=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(rr>>>26)|0,rr&=67108863,m=Math.imul(Fe,Xt),P=Math.imul(Fe,qe),P=P+Math.imul(Te,Xt)|0,N=Math.imul(Te,qe),m=m+Math.imul(Et,Bt)|0,P=P+Math.imul(Et,Ot)|0,P=P+Math.imul(ze,Bt)|0,N=N+Math.imul(ze,Ot)|0;var ro=(l+m|0)+((P&8191)<<13)|0;l=(N+(P>>>13)|0)+(ro>>>26)|0,ro&=67108863,m=Math.imul(Fe,Bt),P=Math.imul(Fe,Ot),P=P+Math.imul(Te,Bt)|0,N=Math.imul(Te,Ot);var Ao=(l+m|0)+((P&8191)<<13)|0;return l=(N+(P>>>13)|0)+(Ao>>>26)|0,Ao&=67108863,v[0]=sr,v[1]=Ht,v[2]=hr,v[3]=pr,v[4]=_r,v[5]=Sr,v[6]=cr,v[7]=qt,v[8]=lr,v[9]=br,v[10]=Mr,v[11]=Er,v[12]=xr,v[13]=Pr,v[14]=Or,v[15]=kr,v[16]=rr,v[17]=ro,v[18]=Ao,l!==0&&(v[19]=l,g.length++),g};Math.imul||(k=T);function R(u,c,h){h.negative=c.negative^u.negative,h.length=u.length+c.length;for(var g=0,x=0,E=0;E>>26)|0,x+=v>>>26,v&=67108863}h.words[E]=l,g=v,v=x}return g!==0?h.words[E]=g:h.length--,h._strip()}function $(u,c,h){return R(u,c,h)}a.prototype.mulTo=function(c,h){var g,x=this.length+c.length;return this.length===10&&c.length===10?g=k(this,c,h):x<63?g=T(this,c,h):x<1024?g=R(this,c,h):g=$(this,c,h),g},a.prototype.mul=function(c){var h=new a(null);return h.words=new Array(this.length+c.length),this.mulTo(c,h)},a.prototype.mulf=function(c){var h=new a(null);return h.words=new Array(this.length+c.length),$(this,c,h)},a.prototype.imul=function(c){return this.clone().mulTo(c,this)},a.prototype.imuln=function(c){var h=c<0;h&&(c=-c),n(typeof c=="number"),n(c<67108864);for(var g=0,x=0;x>=26,g+=E/67108864|0,g+=v>>>26,this.words[x]=v&67108863}return g!==0&&(this.words[x]=g,this.length++),h?this.ineg():this},a.prototype.muln=function(c){return this.clone().imuln(c)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(c){var h=O(c);if(h.length===0)return new a(1);for(var g=this,x=0;x=0);var h=c%26,g=(c-h)/26,x=67108863>>>26-h<<26-h,E;if(h!==0){var v=0;for(E=0;E>>26-h}v&&(this.words[E]=v,this.length++)}if(g!==0){for(E=this.length-1;E>=0;E--)this.words[E+g]=this.words[E];for(E=0;E=0);var x;h?x=(h-h%26)/26:x=0;var E=c%26,v=Math.min((c-E)/26,this.length),l=67108863^67108863>>>E<v)for(this.length-=v,P=0;P=0&&(N!==0||P>=x);P--){var F=this.words[P]|0;this.words[P]=N<<26-E|F>>>E,N=F&l}return m&&N!==0&&(m.words[m.length++]=N),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},a.prototype.ishrn=function(c,h,g){return n(this.negative===0),this.iushrn(c,h,g)},a.prototype.shln=function(c){return this.clone().ishln(c)},a.prototype.ushln=function(c){return this.clone().iushln(c)},a.prototype.shrn=function(c){return this.clone().ishrn(c)},a.prototype.ushrn=function(c){return this.clone().iushrn(c)},a.prototype.testn=function(c){n(typeof c=="number"&&c>=0);var h=c%26,g=(c-h)/26,x=1<=0);var h=c%26,g=(c-h)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=g)return this;if(h!==0&&g++,this.length=Math.min(g,this.length),h!==0){var x=67108863^67108863>>>h<=67108864;h++)this.words[h]-=67108864,h===this.length-1?this.words[h+1]=1:this.words[h+1]++;return this.length=Math.max(this.length,h+1),this},a.prototype.isubn=function(c){if(n(typeof c=="number"),n(c<67108864),c<0)return this.iaddn(-c);if(this.negative!==0)return this.negative=0,this.iaddn(c),this.negative=1,this;if(this.words[0]-=c,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var h=0;h>26)-(m/67108864|0),this.words[E+g]=v&67108863}for(;E>26,this.words[E+g]=v&67108863;if(l===0)return this._strip();for(n(l===-1),l=0,E=0;E>26,this.words[E]=v&67108863;return this.negative=1,this._strip()},a.prototype._wordDiv=function(c,h){var g=this.length-c.length,x=this.clone(),E=c,v=E.words[E.length-1]|0,l=this._countBits(v);g=26-l,g!==0&&(E=E.ushln(g),x.iushln(g),v=E.words[E.length-1]|0);var m=x.length-E.length,P;if(h!=="mod"){P=new a(null),P.length=m+1,P.words=new Array(P.length);for(var N=0;N=0;ee--){var q=(x.words[E.length+ee]|0)*67108864+(x.words[E.length+ee-1]|0);for(q=Math.min(q/v|0,67108863),x._ishlnsubmul(E,q,ee);x.negative!==0;)q--,x.negative=0,x._ishlnsubmul(E,1,ee),x.isZero()||(x.negative^=1);P&&(P.words[ee]=q)}return P&&P._strip(),x._strip(),h!=="div"&&g!==0&&x.iushrn(g),{div:P||null,mod:x}},a.prototype.divmod=function(c,h,g){if(n(!c.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var x,E,v;return this.negative!==0&&c.negative===0?(v=this.neg().divmod(c,h),h!=="mod"&&(x=v.div.neg()),h!=="div"&&(E=v.mod.neg(),g&&E.negative!==0&&E.iadd(c)),{div:x,mod:E}):this.negative===0&&c.negative!==0?(v=this.divmod(c.neg(),h),h!=="mod"&&(x=v.div.neg()),{div:x,mod:v.mod}):this.negative&c.negative?(v=this.neg().divmod(c.neg(),h),h!=="div"&&(E=v.mod.neg(),g&&E.negative!==0&&E.isub(c)),{div:v.div,mod:E}):c.length>this.length||this.cmp(c)<0?{div:new a(0),mod:this}:c.length===1?h==="div"?{div:this.divn(c.words[0]),mod:null}:h==="mod"?{div:null,mod:new a(this.modrn(c.words[0]))}:{div:this.divn(c.words[0]),mod:new a(this.modrn(c.words[0]))}:this._wordDiv(c,h)},a.prototype.div=function(c){return this.divmod(c,"div",!1).div},a.prototype.mod=function(c){return this.divmod(c,"mod",!1).mod},a.prototype.umod=function(c){return this.divmod(c,"mod",!0).mod},a.prototype.divRound=function(c){var h=this.divmod(c);if(h.mod.isZero())return h.div;var g=h.div.negative!==0?h.mod.isub(c):h.mod,x=c.ushrn(1),E=c.andln(1),v=g.cmp(x);return v<0||E===1&&v===0?h.div:h.div.negative!==0?h.div.isubn(1):h.div.iaddn(1)},a.prototype.modrn=function(c){var h=c<0;h&&(c=-c),n(c<=67108863);for(var g=(1<<26)%c,x=0,E=this.length-1;E>=0;E--)x=(g*x+(this.words[E]|0))%c;return h?-x:x},a.prototype.modn=function(c){return this.modrn(c)},a.prototype.idivn=function(c){var h=c<0;h&&(c=-c),n(c<=67108863);for(var g=0,x=this.length-1;x>=0;x--){var E=(this.words[x]|0)+g*67108864;this.words[x]=E/c|0,g=E%c}return this._strip(),h?this.ineg():this},a.prototype.divn=function(c){return this.clone().idivn(c)},a.prototype.egcd=function(c){n(c.negative===0),n(!c.isZero());var h=this,g=c.clone();h.negative!==0?h=h.umod(c):h=h.clone();for(var x=new a(1),E=new a(0),v=new a(0),l=new a(1),m=0;h.isEven()&&g.isEven();)h.iushrn(1),g.iushrn(1),++m;for(var P=g.clone(),N=h.clone();!h.isZero();){for(var F=0,ee=1;!(h.words[0]&ee)&&F<26;++F,ee<<=1);if(F>0)for(h.iushrn(F);F-- >0;)(x.isOdd()||E.isOdd())&&(x.iadd(P),E.isub(N)),x.iushrn(1),E.iushrn(1);for(var q=0,ae=1;!(g.words[0]&ae)&&q<26;++q,ae<<=1);if(q>0)for(g.iushrn(q);q-- >0;)(v.isOdd()||l.isOdd())&&(v.iadd(P),l.isub(N)),v.iushrn(1),l.iushrn(1);h.cmp(g)>=0?(h.isub(g),x.isub(v),E.isub(l)):(g.isub(h),v.isub(x),l.isub(E))}return{a:v,b:l,gcd:g.iushln(m)}},a.prototype._invmp=function(c){n(c.negative===0),n(!c.isZero());var h=this,g=c.clone();h.negative!==0?h=h.umod(c):h=h.clone();for(var x=new a(1),E=new a(0),v=g.clone();h.cmpn(1)>0&&g.cmpn(1)>0;){for(var l=0,m=1;!(h.words[0]&m)&&l<26;++l,m<<=1);if(l>0)for(h.iushrn(l);l-- >0;)x.isOdd()&&x.iadd(v),x.iushrn(1);for(var P=0,N=1;!(g.words[0]&N)&&P<26;++P,N<<=1);if(P>0)for(g.iushrn(P);P-- >0;)E.isOdd()&&E.iadd(v),E.iushrn(1);h.cmp(g)>=0?(h.isub(g),x.isub(E)):(g.isub(h),E.isub(x))}var F;return h.cmpn(1)===0?F=x:F=E,F.cmpn(0)<0&&F.iadd(c),F},a.prototype.gcd=function(c){if(this.isZero())return c.abs();if(c.isZero())return this.abs();var h=this.clone(),g=c.clone();h.negative=0,g.negative=0;for(var x=0;h.isEven()&&g.isEven();x++)h.iushrn(1),g.iushrn(1);do{for(;h.isEven();)h.iushrn(1);for(;g.isEven();)g.iushrn(1);var E=h.cmp(g);if(E<0){var v=h;h=g,g=v}else if(E===0||g.cmpn(1)===0)break;h.isub(g)}while(!0);return g.iushln(x)},a.prototype.invm=function(c){return this.egcd(c).a.umod(c)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(c){return this.words[0]&c},a.prototype.bincn=function(c){n(typeof c=="number");var h=c%26,g=(c-h)/26,x=1<>>26,l&=67108863,this.words[v]=l}return E!==0&&(this.words[v]=E,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(c){var h=c<0;if(this.negative!==0&&!h)return-1;if(this.negative===0&&h)return 1;this._strip();var g;if(this.length>1)g=1;else{h&&(c=-c),n(c<=67108863,"Number is too big");var x=this.words[0]|0;g=x===c?0:xc.length)return 1;if(this.length=0;g--){var x=this.words[g]|0,E=c.words[g]|0;if(x!==E){xE&&(h=1);break}}return h},a.prototype.gtn=function(c){return this.cmpn(c)===1},a.prototype.gt=function(c){return this.cmp(c)===1},a.prototype.gten=function(c){return this.cmpn(c)>=0},a.prototype.gte=function(c){return this.cmp(c)>=0},a.prototype.ltn=function(c){return this.cmpn(c)===-1},a.prototype.lt=function(c){return this.cmp(c)===-1},a.prototype.lten=function(c){return this.cmpn(c)<=0},a.prototype.lte=function(c){return this.cmp(c)<=0},a.prototype.eqn=function(c){return this.cmpn(c)===0},a.prototype.eq=function(c){return this.cmp(c)===0},a.red=function(c){return new b(c)},a.prototype.toRed=function(c){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),c.convertTo(this)._forceRed(c)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(c){return this.red=c,this},a.prototype.forceRed=function(c){return n(!this.red,"Already a number in reduction context"),this._forceRed(c)},a.prototype.redAdd=function(c){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,c)},a.prototype.redIAdd=function(c){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,c)},a.prototype.redSub=function(c){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,c)},a.prototype.redISub=function(c){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,c)},a.prototype.redShl=function(c){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,c)},a.prototype.redMul=function(c){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,c),this.red.mul(this,c)},a.prototype.redIMul=function(c){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,c),this.red.imul(this,c)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(c){return n(this.red&&!c.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,c)};var L={k256:null,p224:null,p192:null,p25519:null};function j(u,c){this.name=u,this.p=new a(c,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}j.prototype._tmp=function(){var c=new a(null);return c.words=new Array(Math.ceil(this.n/13)),c},j.prototype.ireduce=function(c){var h=c,g;do this.split(h,this.tmp),h=this.imulK(h),h=h.iadd(this.tmp),g=h.bitLength();while(g>this.n);var x=g0?h.isub(this.p):h.strip!==void 0?h.strip():h._strip(),h},j.prototype.split=function(c,h){c.iushrn(this.n,0,h)},j.prototype.imulK=function(c){return c.imul(this.k)};function A(){j.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}i(A,j),A.prototype.split=function(c,h){for(var g=4194303,x=Math.min(c.length,9),E=0;E>>22,v=l}v>>>=22,c.words[E-10]=v,v===0&&c.length>10?c.length-=10:c.length-=9},A.prototype.imulK=function(c){c.words[c.length]=0,c.words[c.length+1]=0,c.length+=2;for(var h=0,g=0;g>>=26,c.words[g]=E,h=x}return h!==0&&(c.words[c.length++]=h),c},a._prime=function(c){if(L[c])return L[c];var h;if(c==="k256")h=new A;else if(c==="p224")h=new V;else if(c==="p192")h=new z;else if(c==="p25519")h=new Y;else throw new Error("Unknown prime "+c);return L[c]=h,h};function b(u){if(typeof u=="string"){var c=a._prime(u);this.m=c.p,this.prime=c}else n(u.gtn(1),"modulus must be greater than 1"),this.m=u,this.prime=null}b.prototype._verify1=function(c){n(c.negative===0,"red works only with positives"),n(c.red,"red works only with red numbers")},b.prototype._verify2=function(c,h){n((c.negative|h.negative)===0,"red works only with positives"),n(c.red&&c.red===h.red,"red works only with red numbers")},b.prototype.imod=function(c){return this.prime?this.prime.ireduce(c)._forceRed(this):(y(c,c.umod(this.m)._forceRed(this)),c)},b.prototype.neg=function(c){return c.isZero()?c.clone():this.m.sub(c)._forceRed(this)},b.prototype.add=function(c,h){this._verify2(c,h);var g=c.add(h);return g.cmp(this.m)>=0&&g.isub(this.m),g._forceRed(this)},b.prototype.iadd=function(c,h){this._verify2(c,h);var g=c.iadd(h);return g.cmp(this.m)>=0&&g.isub(this.m),g},b.prototype.sub=function(c,h){this._verify2(c,h);var g=c.sub(h);return g.cmpn(0)<0&&g.iadd(this.m),g._forceRed(this)},b.prototype.isub=function(c,h){this._verify2(c,h);var g=c.isub(h);return g.cmpn(0)<0&&g.iadd(this.m),g},b.prototype.shl=function(c,h){return this._verify1(c),this.imod(c.ushln(h))},b.prototype.imul=function(c,h){return this._verify2(c,h),this.imod(c.imul(h))},b.prototype.mul=function(c,h){return this._verify2(c,h),this.imod(c.mul(h))},b.prototype.isqr=function(c){return this.imul(c,c.clone())},b.prototype.sqr=function(c){return this.mul(c,c)},b.prototype.sqrt=function(c){if(c.isZero())return c.clone();var h=this.m.andln(3);if(n(h%2===1),h===3){var g=this.m.add(new a(1)).iushrn(2);return this.pow(c,g)}for(var x=this.m.subn(1),E=0;!x.isZero()&&x.andln(1)===0;)E++,x.iushrn(1);n(!x.isZero());var v=new a(1).toRed(this),l=v.redNeg(),m=this.m.subn(1).iushrn(1),P=this.m.bitLength();for(P=new a(2*P*P).toRed(this);this.pow(P,m).cmp(l)!==0;)P.redIAdd(l);for(var N=this.pow(P,x),F=this.pow(c,x.addn(1).iushrn(1)),ee=this.pow(c,x),q=E;ee.cmp(v)!==0;){for(var ae=ee,pe=0;ae.cmp(v)!==0;pe++)ae=ae.redSqr();n(pe=0;E--){for(var N=h.words[E],F=P-1;F>=0;F--){var ee=N>>F&1;if(v!==x[0]&&(v=this.sqr(v)),ee===0&&l===0){m=0;continue}l<<=1,l|=ee,m++,!(m!==g&&(E!==0||F!==0))&&(v=this.mul(v,x[l]),m=0,l=0)}P=26}return v},b.prototype.convertTo=function(c){var h=c.umod(this.m);return h===c?h.clone():h},b.prototype.convertFrom=function(c){var h=c.clone();return h.red=null,h},a.mont=function(c){return new o(c)};function o(u){b.call(this,u),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}i(o,b),o.prototype.convertTo=function(c){return this.imod(c.ushln(this.shift))},o.prototype.convertFrom=function(c){var h=this.imod(c.mul(this.rinv));return h.red=null,h},o.prototype.imul=function(c,h){if(c.isZero()||h.isZero())return c.words[0]=0,c.length=1,c;var g=c.imul(h),x=g.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),E=g.isub(x).iushrn(this.shift),v=E;return E.cmp(this.m)>=0?v=E.isub(this.m):E.cmpn(0)<0&&(v=E.iadd(this.m)),v._forceRed(this)},o.prototype.mul=function(c,h){if(c.isZero()||h.isZero())return new a(0)._forceRed(this);var g=c.mul(h),x=g.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),E=g.isub(x).iushrn(this.shift),v=E;return E.cmp(this.m)>=0?v=E.isub(this.m):E.cmpn(0)<0&&(v=E.iadd(this.m)),v._forceRed(this)},o.prototype.invm=function(c){var h=this.imod(c._invmp(this.m).mul(this.r2));return h._forceRed(this)}})(e,Ut)})(x5);var _5=x5.exports,Cf=_5,xee=Td;function _ee(e){var t=YI(e),r=t.toRed(Cf.mont(e.modulus)).redPow(new Cf(e.publicExponent)).fromRed();return{blinder:r,unblinder:t.invm(e.modulus)}}function YI(e){var t=e.modulus.byteLength(),r;do r=new Cf(xee(t));while(r.cmp(e.modulus)>=0||!r.umod(e.prime1)||!r.umod(e.prime2));return r}function XI(e,t){var r=_ee(t),n=t.modulus.byteLength(),i=new Cf(e).mul(r.blinder).umod(t.modulus),a=i.toRed(Cf.mont(t.prime1)),s=i.toRed(Cf.mont(t.prime2)),f=t.coefficient,d=t.prime1,p=t.prime2,y=a.redPow(t.exponent1).fromRed(),w=s.redPow(t.exponent2).fromRed(),_=y.isub(w).imul(f).umod(d).imul(p);return w.iadd(_).imul(r.unblinder).umod(t.modulus).toArrayLike(rt,"be",n)}XI.getr=YI;var S5=XI,F2={};const See="elliptic",Mee="6.5.4",Eee="EC cryptography",kee="lib/elliptic.js",Tee=["lib"],Cee={lint:"eslint lib test","lint:fix":"npm run lint -- --fix",unit:"istanbul test _mocha --reporter=spec test/index.js",test:"npm run lint && npm run unit",version:"grunt dist && git add dist/"},Pee={type:"git",url:"git@github.com:indutny/elliptic"},Oee=["EC","Elliptic","curve","Cryptography"],Ree="Fedor Indutny ",Aee="MIT",Dee={url:"https://github.com/indutny/elliptic/issues"},$ee="https://github.com/indutny/elliptic",Iee={brfs:"^2.0.2",coveralls:"^3.1.0",eslint:"^7.6.0",grunt:"^1.2.1","grunt-browserify":"^5.3.0","grunt-cli":"^1.3.2","grunt-contrib-connect":"^3.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^5.0.0","grunt-mocha-istanbul":"^5.0.2","grunt-saucelabs":"^9.0.1",istanbul:"^0.4.5",mocha:"^8.0.1"},Lee={"bn.js":"^4.11.9",brorand:"^1.1.0","hash.js":"^1.0.0","hmac-drbg":"^1.0.1",inherits:"^2.0.4","minimalistic-assert":"^1.0.1","minimalistic-crypto-utils":"^1.0.1"},Nee={name:See,version:Mee,description:Eee,main:kee,files:Tee,scripts:Cee,repository:Pee,keywords:Oee,author:Ree,license:Aee,bugs:Dee,homepage:$ee,devDependencies:Iee,dependencies:Lee};var va={},M5={exports:{}};M5.exports;(function(e){(function(t,r){function n(b,o){if(!b)throw new Error(o||"Assertion failed")}function i(b,o){b.super_=o;var u=function(){};u.prototype=o.prototype,b.prototype=new u,b.prototype.constructor=b}function a(b,o,u){if(a.isBN(b))return b;this.negative=0,this.words=null,this.length=0,this.red=null,b!==null&&((o==="le"||o==="be")&&(u=o,o=10),this._init(b||0,o||10,u||"be"))}typeof t=="object"?t.exports=a:r.BN=a,a.BN=a,a.wordSize=26;var s;try{typeof window<"u"&&typeof window.Buffer<"u"?s=window.Buffer:s=mi.Buffer}catch{}a.isBN=function(o){return o instanceof a?!0:o!==null&&typeof o=="object"&&o.constructor.wordSize===a.wordSize&&Array.isArray(o.words)},a.max=function(o,u){return o.cmp(u)>0?o:u},a.min=function(o,u){return o.cmp(u)<0?o:u},a.prototype._init=function(o,u,c){if(typeof o=="number")return this._initNumber(o,u,c);if(typeof o=="object")return this._initArray(o,u,c);u==="hex"&&(u=16),n(u===(u|0)&&u>=2&&u<=36),o=o.toString().replace(/\s+/g,"");var h=0;o[0]==="-"&&(h++,this.negative=1),h=0;h-=3)x=o[h]|o[h-1]<<8|o[h-2]<<16,this.words[g]|=x<>>26-E&67108863,E+=24,E>=26&&(E-=26,g++);else if(c==="le")for(h=0,g=0;h>>26-E&67108863,E+=24,E>=26&&(E-=26,g++);return this.strip()};function f(b,o){var u=b.charCodeAt(o);return u>=65&&u<=70?u-55:u>=97&&u<=102?u-87:u-48&15}function d(b,o,u){var c=f(b,u);return u-1>=o&&(c|=f(b,u-1)<<4),c}a.prototype._parseHex=function(o,u,c){this.length=Math.ceil((o.length-u)/6),this.words=new Array(this.length);for(var h=0;h=u;h-=2)E=d(o,u,h)<=18?(g-=18,x+=1,this.words[x]|=E>>>26):g+=8;else{var v=o.length-u;for(h=v%2===0?u+1:u;h=18?(g-=18,x+=1,this.words[x]|=E>>>26):g+=8}this.strip()};function p(b,o,u,c){for(var h=0,g=Math.min(b.length,u),x=o;x=49?h+=E-49+10:E>=17?h+=E-17+10:h+=E}return h}a.prototype._parseBase=function(o,u,c){this.words=[0],this.length=1;for(var h=0,g=1;g<=67108863;g*=u)h++;h--,g=g/u|0;for(var x=o.length-c,E=x%h,v=Math.min(x,x-E)+c,l=0,m=c;m1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},a.prototype.inspect=function(){return(this.red?""};var y=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],w=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],_=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(o,u){o=o||10,u=u|0||1;var c;if(o===16||o==="hex"){c="";for(var h=0,g=0,x=0;x>>24-h&16777215,g!==0||x!==this.length-1?c=y[6-v.length]+v+c:c=v+c,h+=2,h>=26&&(h-=26,x--)}for(g!==0&&(c=g.toString(16)+c);c.length%u!==0;)c="0"+c;return this.negative!==0&&(c="-"+c),c}if(o===(o|0)&&o>=2&&o<=36){var l=w[o],m=_[o];c="";var P=this.clone();for(P.negative=0;!P.isZero();){var N=P.modn(m).toString(o);P=P.idivn(m),P.isZero()?c=N+c:c=y[l-N.length]+N+c}for(this.isZero()&&(c="0"+c);c.length%u!==0;)c="0"+c;return this.negative!==0&&(c="-"+c),c}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var o=this.words[0];return this.length===2?o+=this.words[1]*67108864:this.length===3&&this.words[2]===1?o+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-o:o},a.prototype.toJSON=function(){return this.toString(16)},a.prototype.toBuffer=function(o,u){return n(typeof s<"u"),this.toArrayLike(s,o,u)},a.prototype.toArray=function(o,u){return this.toArrayLike(Array,o,u)},a.prototype.toArrayLike=function(o,u,c){var h=this.byteLength(),g=c||Math.max(1,h);n(h<=g,"byte array longer than desired length"),n(g>0,"Requested array length <= 0"),this.strip();var x=u==="le",E=new o(g),v,l,m=this.clone();if(x){for(l=0;!m.isZero();l++)v=m.andln(255),m.iushrn(8),E[l]=v;for(;l=4096&&(c+=13,u>>>=13),u>=64&&(c+=7,u>>>=7),u>=8&&(c+=4,u>>>=4),u>=2&&(c+=2,u>>>=2),c+u},a.prototype._zeroBits=function(o){if(o===0)return 26;var u=o,c=0;return u&8191||(c+=13,u>>>=13),u&127||(c+=7,u>>>=7),u&15||(c+=4,u>>>=4),u&3||(c+=2,u>>>=2),u&1||c++,c},a.prototype.bitLength=function(){var o=this.words[this.length-1],u=this._countBits(o);return(this.length-1)*26+u};function S(b){for(var o=new Array(b.bitLength()),u=0;u>>h}return o}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var o=0,u=0;uo.length?this.clone().ior(o):o.clone().ior(this)},a.prototype.uor=function(o){return this.length>o.length?this.clone().iuor(o):o.clone().iuor(this)},a.prototype.iuand=function(o){var u;this.length>o.length?u=o:u=this;for(var c=0;co.length?this.clone().iand(o):o.clone().iand(this)},a.prototype.uand=function(o){return this.length>o.length?this.clone().iuand(o):o.clone().iuand(this)},a.prototype.iuxor=function(o){var u,c;this.length>o.length?(u=this,c=o):(u=o,c=this);for(var h=0;ho.length?this.clone().ixor(o):o.clone().ixor(this)},a.prototype.uxor=function(o){return this.length>o.length?this.clone().iuxor(o):o.clone().iuxor(this)},a.prototype.inotn=function(o){n(typeof o=="number"&&o>=0);var u=Math.ceil(o/26)|0,c=o%26;this._expand(u),c>0&&u--;for(var h=0;h0&&(this.words[h]=~this.words[h]&67108863>>26-c),this.strip()},a.prototype.notn=function(o){return this.clone().inotn(o)},a.prototype.setn=function(o,u){n(typeof o=="number"&&o>=0);var c=o/26|0,h=o%26;return this._expand(c+1),u?this.words[c]=this.words[c]|1<o.length?(c=this,h=o):(c=o,h=this);for(var g=0,x=0;x>>26;for(;g!==0&&x>>26;if(this.length=c.length,g!==0)this.words[this.length]=g,this.length++;else if(c!==this)for(;xo.length?this.clone().iadd(o):o.clone().iadd(this)},a.prototype.isub=function(o){if(o.negative!==0){o.negative=0;var u=this.iadd(o);return o.negative=1,u._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(o),this.negative=1,this._normSign();var c=this.cmp(o);if(c===0)return this.negative=0,this.length=1,this.words[0]=0,this;var h,g;c>0?(h=this,g=o):(h=o,g=this);for(var x=0,E=0;E>26,this.words[E]=u&67108863;for(;x!==0&&E>26,this.words[E]=u&67108863;if(x===0&&E>>26,P=v&67108863,N=Math.min(l,o.length-1),F=Math.max(0,l-b.length+1);F<=N;F++){var ee=l-F|0;h=b.words[ee]|0,g=o.words[F]|0,x=h*g+P,m+=x/67108864|0,P=x&67108863}u.words[l]=P|0,v=m|0}return v!==0?u.words[l]=v|0:u.length--,u.strip()}var C=function(o,u,c){var h=o.words,g=u.words,x=c.words,E=0,v,l,m,P=h[0]|0,N=P&8191,F=P>>>13,ee=h[1]|0,q=ee&8191,ae=ee>>>13,pe=h[2]|0,we=pe&8191,Se=pe>>>13,he=h[3]|0,re=he&8191,_e=he>>>13,W=h[4]|0,ve=W&8191,Z=W>>>13,ne=h[5]|0,K=ne&8191,le=ne>>>13,xe=h[6]|0,ce=xe&8191,de=xe>>>13,Ae=h[7]|0,ye=Ae&8191,be=Ae>>>13,tt=h[8]|0,Oe=tt&8191,$e=tt>>>13,Et=h[9]|0,ze=Et&8191,He=Et>>>13,Fe=g[0]|0,Te=Fe&8191,Pe=Fe>>>13,pt=g[1]|0,De=pt&8191,je=pt>>>13,bt=g[2]|0,Le=bt&8191,Ge=bt>>>13,Ct=g[3]|0,Be=Ct&8191,Ye=Ct>>>13,Pt=g[4]|0,Ue=Pt&8191,et=Pt>>>13,Vt=g[5]|0,Xe=Vt&8191,ot=Vt>>>13,Kt=g[6]|0,Ve=Kt&8191,Je=Kt>>>13,It=g[7]|0,We=It&8191,it=It>>>13,jt=g[8]|0,Qe=jt&8191,lt=jt>>>13,Xt=g[9]|0,qe=Xt&8191,at=Xt>>>13;c.negative=o.negative^u.negative,c.length=19,v=Math.imul(N,Te),l=Math.imul(N,Pe),l=l+Math.imul(F,Te)|0,m=Math.imul(F,Pe);var Bt=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,v=Math.imul(q,Te),l=Math.imul(q,Pe),l=l+Math.imul(ae,Te)|0,m=Math.imul(ae,Pe),v=v+Math.imul(N,De)|0,l=l+Math.imul(N,je)|0,l=l+Math.imul(F,De)|0,m=m+Math.imul(F,je)|0;var Ot=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,v=Math.imul(we,Te),l=Math.imul(we,Pe),l=l+Math.imul(Se,Te)|0,m=Math.imul(Se,Pe),v=v+Math.imul(q,De)|0,l=l+Math.imul(q,je)|0,l=l+Math.imul(ae,De)|0,m=m+Math.imul(ae,je)|0,v=v+Math.imul(N,Le)|0,l=l+Math.imul(N,Ge)|0,l=l+Math.imul(F,Le)|0,m=m+Math.imul(F,Ge)|0;var sr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(sr>>>26)|0,sr&=67108863,v=Math.imul(re,Te),l=Math.imul(re,Pe),l=l+Math.imul(_e,Te)|0,m=Math.imul(_e,Pe),v=v+Math.imul(we,De)|0,l=l+Math.imul(we,je)|0,l=l+Math.imul(Se,De)|0,m=m+Math.imul(Se,je)|0,v=v+Math.imul(q,Le)|0,l=l+Math.imul(q,Ge)|0,l=l+Math.imul(ae,Le)|0,m=m+Math.imul(ae,Ge)|0,v=v+Math.imul(N,Be)|0,l=l+Math.imul(N,Ye)|0,l=l+Math.imul(F,Be)|0,m=m+Math.imul(F,Ye)|0;var Ht=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,v=Math.imul(ve,Te),l=Math.imul(ve,Pe),l=l+Math.imul(Z,Te)|0,m=Math.imul(Z,Pe),v=v+Math.imul(re,De)|0,l=l+Math.imul(re,je)|0,l=l+Math.imul(_e,De)|0,m=m+Math.imul(_e,je)|0,v=v+Math.imul(we,Le)|0,l=l+Math.imul(we,Ge)|0,l=l+Math.imul(Se,Le)|0,m=m+Math.imul(Se,Ge)|0,v=v+Math.imul(q,Be)|0,l=l+Math.imul(q,Ye)|0,l=l+Math.imul(ae,Be)|0,m=m+Math.imul(ae,Ye)|0,v=v+Math.imul(N,Ue)|0,l=l+Math.imul(N,et)|0,l=l+Math.imul(F,Ue)|0,m=m+Math.imul(F,et)|0;var hr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(hr>>>26)|0,hr&=67108863,v=Math.imul(K,Te),l=Math.imul(K,Pe),l=l+Math.imul(le,Te)|0,m=Math.imul(le,Pe),v=v+Math.imul(ve,De)|0,l=l+Math.imul(ve,je)|0,l=l+Math.imul(Z,De)|0,m=m+Math.imul(Z,je)|0,v=v+Math.imul(re,Le)|0,l=l+Math.imul(re,Ge)|0,l=l+Math.imul(_e,Le)|0,m=m+Math.imul(_e,Ge)|0,v=v+Math.imul(we,Be)|0,l=l+Math.imul(we,Ye)|0,l=l+Math.imul(Se,Be)|0,m=m+Math.imul(Se,Ye)|0,v=v+Math.imul(q,Ue)|0,l=l+Math.imul(q,et)|0,l=l+Math.imul(ae,Ue)|0,m=m+Math.imul(ae,et)|0,v=v+Math.imul(N,Xe)|0,l=l+Math.imul(N,ot)|0,l=l+Math.imul(F,Xe)|0,m=m+Math.imul(F,ot)|0;var pr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(pr>>>26)|0,pr&=67108863,v=Math.imul(ce,Te),l=Math.imul(ce,Pe),l=l+Math.imul(de,Te)|0,m=Math.imul(de,Pe),v=v+Math.imul(K,De)|0,l=l+Math.imul(K,je)|0,l=l+Math.imul(le,De)|0,m=m+Math.imul(le,je)|0,v=v+Math.imul(ve,Le)|0,l=l+Math.imul(ve,Ge)|0,l=l+Math.imul(Z,Le)|0,m=m+Math.imul(Z,Ge)|0,v=v+Math.imul(re,Be)|0,l=l+Math.imul(re,Ye)|0,l=l+Math.imul(_e,Be)|0,m=m+Math.imul(_e,Ye)|0,v=v+Math.imul(we,Ue)|0,l=l+Math.imul(we,et)|0,l=l+Math.imul(Se,Ue)|0,m=m+Math.imul(Se,et)|0,v=v+Math.imul(q,Xe)|0,l=l+Math.imul(q,ot)|0,l=l+Math.imul(ae,Xe)|0,m=m+Math.imul(ae,ot)|0,v=v+Math.imul(N,Ve)|0,l=l+Math.imul(N,Je)|0,l=l+Math.imul(F,Ve)|0,m=m+Math.imul(F,Je)|0;var _r=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(_r>>>26)|0,_r&=67108863,v=Math.imul(ye,Te),l=Math.imul(ye,Pe),l=l+Math.imul(be,Te)|0,m=Math.imul(be,Pe),v=v+Math.imul(ce,De)|0,l=l+Math.imul(ce,je)|0,l=l+Math.imul(de,De)|0,m=m+Math.imul(de,je)|0,v=v+Math.imul(K,Le)|0,l=l+Math.imul(K,Ge)|0,l=l+Math.imul(le,Le)|0,m=m+Math.imul(le,Ge)|0,v=v+Math.imul(ve,Be)|0,l=l+Math.imul(ve,Ye)|0,l=l+Math.imul(Z,Be)|0,m=m+Math.imul(Z,Ye)|0,v=v+Math.imul(re,Ue)|0,l=l+Math.imul(re,et)|0,l=l+Math.imul(_e,Ue)|0,m=m+Math.imul(_e,et)|0,v=v+Math.imul(we,Xe)|0,l=l+Math.imul(we,ot)|0,l=l+Math.imul(Se,Xe)|0,m=m+Math.imul(Se,ot)|0,v=v+Math.imul(q,Ve)|0,l=l+Math.imul(q,Je)|0,l=l+Math.imul(ae,Ve)|0,m=m+Math.imul(ae,Je)|0,v=v+Math.imul(N,We)|0,l=l+Math.imul(N,it)|0,l=l+Math.imul(F,We)|0,m=m+Math.imul(F,it)|0;var Sr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,v=Math.imul(Oe,Te),l=Math.imul(Oe,Pe),l=l+Math.imul($e,Te)|0,m=Math.imul($e,Pe),v=v+Math.imul(ye,De)|0,l=l+Math.imul(ye,je)|0,l=l+Math.imul(be,De)|0,m=m+Math.imul(be,je)|0,v=v+Math.imul(ce,Le)|0,l=l+Math.imul(ce,Ge)|0,l=l+Math.imul(de,Le)|0,m=m+Math.imul(de,Ge)|0,v=v+Math.imul(K,Be)|0,l=l+Math.imul(K,Ye)|0,l=l+Math.imul(le,Be)|0,m=m+Math.imul(le,Ye)|0,v=v+Math.imul(ve,Ue)|0,l=l+Math.imul(ve,et)|0,l=l+Math.imul(Z,Ue)|0,m=m+Math.imul(Z,et)|0,v=v+Math.imul(re,Xe)|0,l=l+Math.imul(re,ot)|0,l=l+Math.imul(_e,Xe)|0,m=m+Math.imul(_e,ot)|0,v=v+Math.imul(we,Ve)|0,l=l+Math.imul(we,Je)|0,l=l+Math.imul(Se,Ve)|0,m=m+Math.imul(Se,Je)|0,v=v+Math.imul(q,We)|0,l=l+Math.imul(q,it)|0,l=l+Math.imul(ae,We)|0,m=m+Math.imul(ae,it)|0,v=v+Math.imul(N,Qe)|0,l=l+Math.imul(N,lt)|0,l=l+Math.imul(F,Qe)|0,m=m+Math.imul(F,lt)|0;var cr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(cr>>>26)|0,cr&=67108863,v=Math.imul(ze,Te),l=Math.imul(ze,Pe),l=l+Math.imul(He,Te)|0,m=Math.imul(He,Pe),v=v+Math.imul(Oe,De)|0,l=l+Math.imul(Oe,je)|0,l=l+Math.imul($e,De)|0,m=m+Math.imul($e,je)|0,v=v+Math.imul(ye,Le)|0,l=l+Math.imul(ye,Ge)|0,l=l+Math.imul(be,Le)|0,m=m+Math.imul(be,Ge)|0,v=v+Math.imul(ce,Be)|0,l=l+Math.imul(ce,Ye)|0,l=l+Math.imul(de,Be)|0,m=m+Math.imul(de,Ye)|0,v=v+Math.imul(K,Ue)|0,l=l+Math.imul(K,et)|0,l=l+Math.imul(le,Ue)|0,m=m+Math.imul(le,et)|0,v=v+Math.imul(ve,Xe)|0,l=l+Math.imul(ve,ot)|0,l=l+Math.imul(Z,Xe)|0,m=m+Math.imul(Z,ot)|0,v=v+Math.imul(re,Ve)|0,l=l+Math.imul(re,Je)|0,l=l+Math.imul(_e,Ve)|0,m=m+Math.imul(_e,Je)|0,v=v+Math.imul(we,We)|0,l=l+Math.imul(we,it)|0,l=l+Math.imul(Se,We)|0,m=m+Math.imul(Se,it)|0,v=v+Math.imul(q,Qe)|0,l=l+Math.imul(q,lt)|0,l=l+Math.imul(ae,Qe)|0,m=m+Math.imul(ae,lt)|0,v=v+Math.imul(N,qe)|0,l=l+Math.imul(N,at)|0,l=l+Math.imul(F,qe)|0,m=m+Math.imul(F,at)|0;var qt=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(qt>>>26)|0,qt&=67108863,v=Math.imul(ze,De),l=Math.imul(ze,je),l=l+Math.imul(He,De)|0,m=Math.imul(He,je),v=v+Math.imul(Oe,Le)|0,l=l+Math.imul(Oe,Ge)|0,l=l+Math.imul($e,Le)|0,m=m+Math.imul($e,Ge)|0,v=v+Math.imul(ye,Be)|0,l=l+Math.imul(ye,Ye)|0,l=l+Math.imul(be,Be)|0,m=m+Math.imul(be,Ye)|0,v=v+Math.imul(ce,Ue)|0,l=l+Math.imul(ce,et)|0,l=l+Math.imul(de,Ue)|0,m=m+Math.imul(de,et)|0,v=v+Math.imul(K,Xe)|0,l=l+Math.imul(K,ot)|0,l=l+Math.imul(le,Xe)|0,m=m+Math.imul(le,ot)|0,v=v+Math.imul(ve,Ve)|0,l=l+Math.imul(ve,Je)|0,l=l+Math.imul(Z,Ve)|0,m=m+Math.imul(Z,Je)|0,v=v+Math.imul(re,We)|0,l=l+Math.imul(re,it)|0,l=l+Math.imul(_e,We)|0,m=m+Math.imul(_e,it)|0,v=v+Math.imul(we,Qe)|0,l=l+Math.imul(we,lt)|0,l=l+Math.imul(Se,Qe)|0,m=m+Math.imul(Se,lt)|0,v=v+Math.imul(q,qe)|0,l=l+Math.imul(q,at)|0,l=l+Math.imul(ae,qe)|0,m=m+Math.imul(ae,at)|0;var lr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(lr>>>26)|0,lr&=67108863,v=Math.imul(ze,Le),l=Math.imul(ze,Ge),l=l+Math.imul(He,Le)|0,m=Math.imul(He,Ge),v=v+Math.imul(Oe,Be)|0,l=l+Math.imul(Oe,Ye)|0,l=l+Math.imul($e,Be)|0,m=m+Math.imul($e,Ye)|0,v=v+Math.imul(ye,Ue)|0,l=l+Math.imul(ye,et)|0,l=l+Math.imul(be,Ue)|0,m=m+Math.imul(be,et)|0,v=v+Math.imul(ce,Xe)|0,l=l+Math.imul(ce,ot)|0,l=l+Math.imul(de,Xe)|0,m=m+Math.imul(de,ot)|0,v=v+Math.imul(K,Ve)|0,l=l+Math.imul(K,Je)|0,l=l+Math.imul(le,Ve)|0,m=m+Math.imul(le,Je)|0,v=v+Math.imul(ve,We)|0,l=l+Math.imul(ve,it)|0,l=l+Math.imul(Z,We)|0,m=m+Math.imul(Z,it)|0,v=v+Math.imul(re,Qe)|0,l=l+Math.imul(re,lt)|0,l=l+Math.imul(_e,Qe)|0,m=m+Math.imul(_e,lt)|0,v=v+Math.imul(we,qe)|0,l=l+Math.imul(we,at)|0,l=l+Math.imul(Se,qe)|0,m=m+Math.imul(Se,at)|0;var br=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(br>>>26)|0,br&=67108863,v=Math.imul(ze,Be),l=Math.imul(ze,Ye),l=l+Math.imul(He,Be)|0,m=Math.imul(He,Ye),v=v+Math.imul(Oe,Ue)|0,l=l+Math.imul(Oe,et)|0,l=l+Math.imul($e,Ue)|0,m=m+Math.imul($e,et)|0,v=v+Math.imul(ye,Xe)|0,l=l+Math.imul(ye,ot)|0,l=l+Math.imul(be,Xe)|0,m=m+Math.imul(be,ot)|0,v=v+Math.imul(ce,Ve)|0,l=l+Math.imul(ce,Je)|0,l=l+Math.imul(de,Ve)|0,m=m+Math.imul(de,Je)|0,v=v+Math.imul(K,We)|0,l=l+Math.imul(K,it)|0,l=l+Math.imul(le,We)|0,m=m+Math.imul(le,it)|0,v=v+Math.imul(ve,Qe)|0,l=l+Math.imul(ve,lt)|0,l=l+Math.imul(Z,Qe)|0,m=m+Math.imul(Z,lt)|0,v=v+Math.imul(re,qe)|0,l=l+Math.imul(re,at)|0,l=l+Math.imul(_e,qe)|0,m=m+Math.imul(_e,at)|0;var Mr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,v=Math.imul(ze,Ue),l=Math.imul(ze,et),l=l+Math.imul(He,Ue)|0,m=Math.imul(He,et),v=v+Math.imul(Oe,Xe)|0,l=l+Math.imul(Oe,ot)|0,l=l+Math.imul($e,Xe)|0,m=m+Math.imul($e,ot)|0,v=v+Math.imul(ye,Ve)|0,l=l+Math.imul(ye,Je)|0,l=l+Math.imul(be,Ve)|0,m=m+Math.imul(be,Je)|0,v=v+Math.imul(ce,We)|0,l=l+Math.imul(ce,it)|0,l=l+Math.imul(de,We)|0,m=m+Math.imul(de,it)|0,v=v+Math.imul(K,Qe)|0,l=l+Math.imul(K,lt)|0,l=l+Math.imul(le,Qe)|0,m=m+Math.imul(le,lt)|0,v=v+Math.imul(ve,qe)|0,l=l+Math.imul(ve,at)|0,l=l+Math.imul(Z,qe)|0,m=m+Math.imul(Z,at)|0;var Er=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Er>>>26)|0,Er&=67108863,v=Math.imul(ze,Xe),l=Math.imul(ze,ot),l=l+Math.imul(He,Xe)|0,m=Math.imul(He,ot),v=v+Math.imul(Oe,Ve)|0,l=l+Math.imul(Oe,Je)|0,l=l+Math.imul($e,Ve)|0,m=m+Math.imul($e,Je)|0,v=v+Math.imul(ye,We)|0,l=l+Math.imul(ye,it)|0,l=l+Math.imul(be,We)|0,m=m+Math.imul(be,it)|0,v=v+Math.imul(ce,Qe)|0,l=l+Math.imul(ce,lt)|0,l=l+Math.imul(de,Qe)|0,m=m+Math.imul(de,lt)|0,v=v+Math.imul(K,qe)|0,l=l+Math.imul(K,at)|0,l=l+Math.imul(le,qe)|0,m=m+Math.imul(le,at)|0;var xr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(xr>>>26)|0,xr&=67108863,v=Math.imul(ze,Ve),l=Math.imul(ze,Je),l=l+Math.imul(He,Ve)|0,m=Math.imul(He,Je),v=v+Math.imul(Oe,We)|0,l=l+Math.imul(Oe,it)|0,l=l+Math.imul($e,We)|0,m=m+Math.imul($e,it)|0,v=v+Math.imul(ye,Qe)|0,l=l+Math.imul(ye,lt)|0,l=l+Math.imul(be,Qe)|0,m=m+Math.imul(be,lt)|0,v=v+Math.imul(ce,qe)|0,l=l+Math.imul(ce,at)|0,l=l+Math.imul(de,qe)|0,m=m+Math.imul(de,at)|0;var Pr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Pr>>>26)|0,Pr&=67108863,v=Math.imul(ze,We),l=Math.imul(ze,it),l=l+Math.imul(He,We)|0,m=Math.imul(He,it),v=v+Math.imul(Oe,Qe)|0,l=l+Math.imul(Oe,lt)|0,l=l+Math.imul($e,Qe)|0,m=m+Math.imul($e,lt)|0,v=v+Math.imul(ye,qe)|0,l=l+Math.imul(ye,at)|0,l=l+Math.imul(be,qe)|0,m=m+Math.imul(be,at)|0;var Or=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Or>>>26)|0,Or&=67108863,v=Math.imul(ze,Qe),l=Math.imul(ze,lt),l=l+Math.imul(He,Qe)|0,m=Math.imul(He,lt),v=v+Math.imul(Oe,qe)|0,l=l+Math.imul(Oe,at)|0,l=l+Math.imul($e,qe)|0,m=m+Math.imul($e,at)|0;var kr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(kr>>>26)|0,kr&=67108863,v=Math.imul(ze,qe),l=Math.imul(ze,at),l=l+Math.imul(He,qe)|0,m=Math.imul(He,at);var rr=(E+v|0)+((l&8191)<<13)|0;return E=(m+(l>>>13)|0)+(rr>>>26)|0,rr&=67108863,x[0]=Bt,x[1]=Ot,x[2]=sr,x[3]=Ht,x[4]=hr,x[5]=pr,x[6]=_r,x[7]=Sr,x[8]=cr,x[9]=qt,x[10]=lr,x[11]=br,x[12]=Mr,x[13]=Er,x[14]=xr,x[15]=Pr,x[16]=Or,x[17]=kr,x[18]=rr,E!==0&&(x[19]=E,c.length++),c};Math.imul||(C=M);function O(b,o,u){u.negative=o.negative^b.negative,u.length=b.length+o.length;for(var c=0,h=0,g=0;g>>26)|0,h+=x>>>26,x&=67108863}u.words[g]=E,c=x,x=h}return c!==0?u.words[g]=c:u.length--,u.strip()}function T(b,o,u){var c=new k;return c.mulp(b,o,u)}a.prototype.mulTo=function(o,u){var c,h=this.length+o.length;return this.length===10&&o.length===10?c=C(this,o,u):h<63?c=M(this,o,u):h<1024?c=O(this,o,u):c=T(this,o,u),c};function k(b,o){this.x=b,this.y=o}k.prototype.makeRBT=function(o){for(var u=new Array(o),c=a.prototype._countBits(o)-1,h=0;h>=1;return h},k.prototype.permute=function(o,u,c,h,g,x){for(var E=0;E>>1)g++;return 1<>>13,c[2*x+1]=g&8191,g=g>>>13;for(x=2*u;x>=26,u+=h/67108864|0,u+=g>>>26,this.words[c]=g&67108863}return u!==0&&(this.words[c]=u,this.length++),this},a.prototype.muln=function(o){return this.clone().imuln(o)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(o){var u=S(o);if(u.length===0)return new a(1);for(var c=this,h=0;h=0);var u=o%26,c=(o-u)/26,h=67108863>>>26-u<<26-u,g;if(u!==0){var x=0;for(g=0;g>>26-u}x&&(this.words[g]=x,this.length++)}if(c!==0){for(g=this.length-1;g>=0;g--)this.words[g+c]=this.words[g];for(g=0;g=0);var h;u?h=(u-u%26)/26:h=0;var g=o%26,x=Math.min((o-g)/26,this.length),E=67108863^67108863>>>g<x)for(this.length-=x,l=0;l=0&&(m!==0||l>=h);l--){var P=this.words[l]|0;this.words[l]=m<<26-g|P>>>g,m=P&E}return v&&m!==0&&(v.words[v.length++]=m),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},a.prototype.ishrn=function(o,u,c){return n(this.negative===0),this.iushrn(o,u,c)},a.prototype.shln=function(o){return this.clone().ishln(o)},a.prototype.ushln=function(o){return this.clone().iushln(o)},a.prototype.shrn=function(o){return this.clone().ishrn(o)},a.prototype.ushrn=function(o){return this.clone().iushrn(o)},a.prototype.testn=function(o){n(typeof o=="number"&&o>=0);var u=o%26,c=(o-u)/26,h=1<=0);var u=o%26,c=(o-u)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=c)return this;if(u!==0&&c++,this.length=Math.min(c,this.length),u!==0){var h=67108863^67108863>>>u<=67108864;u++)this.words[u]-=67108864,u===this.length-1?this.words[u+1]=1:this.words[u+1]++;return this.length=Math.max(this.length,u+1),this},a.prototype.isubn=function(o){if(n(typeof o=="number"),n(o<67108864),o<0)return this.iaddn(-o);if(this.negative!==0)return this.negative=0,this.iaddn(o),this.negative=1,this;if(this.words[0]-=o,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var u=0;u>26)-(v/67108864|0),this.words[g+c]=x&67108863}for(;g>26,this.words[g+c]=x&67108863;if(E===0)return this.strip();for(n(E===-1),E=0,g=0;g>26,this.words[g]=x&67108863;return this.negative=1,this.strip()},a.prototype._wordDiv=function(o,u){var c=this.length-o.length,h=this.clone(),g=o,x=g.words[g.length-1]|0,E=this._countBits(x);c=26-E,c!==0&&(g=g.ushln(c),h.iushln(c),x=g.words[g.length-1]|0);var v=h.length-g.length,l;if(u!=="mod"){l=new a(null),l.length=v+1,l.words=new Array(l.length);for(var m=0;m=0;N--){var F=(h.words[g.length+N]|0)*67108864+(h.words[g.length+N-1]|0);for(F=Math.min(F/x|0,67108863),h._ishlnsubmul(g,F,N);h.negative!==0;)F--,h.negative=0,h._ishlnsubmul(g,1,N),h.isZero()||(h.negative^=1);l&&(l.words[N]=F)}return l&&l.strip(),h.strip(),u!=="div"&&c!==0&&h.iushrn(c),{div:l||null,mod:h}},a.prototype.divmod=function(o,u,c){if(n(!o.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var h,g,x;return this.negative!==0&&o.negative===0?(x=this.neg().divmod(o,u),u!=="mod"&&(h=x.div.neg()),u!=="div"&&(g=x.mod.neg(),c&&g.negative!==0&&g.iadd(o)),{div:h,mod:g}):this.negative===0&&o.negative!==0?(x=this.divmod(o.neg(),u),u!=="mod"&&(h=x.div.neg()),{div:h,mod:x.mod}):this.negative&o.negative?(x=this.neg().divmod(o.neg(),u),u!=="div"&&(g=x.mod.neg(),c&&g.negative!==0&&g.isub(o)),{div:x.div,mod:g}):o.length>this.length||this.cmp(o)<0?{div:new a(0),mod:this}:o.length===1?u==="div"?{div:this.divn(o.words[0]),mod:null}:u==="mod"?{div:null,mod:new a(this.modn(o.words[0]))}:{div:this.divn(o.words[0]),mod:new a(this.modn(o.words[0]))}:this._wordDiv(o,u)},a.prototype.div=function(o){return this.divmod(o,"div",!1).div},a.prototype.mod=function(o){return this.divmod(o,"mod",!1).mod},a.prototype.umod=function(o){return this.divmod(o,"mod",!0).mod},a.prototype.divRound=function(o){var u=this.divmod(o);if(u.mod.isZero())return u.div;var c=u.div.negative!==0?u.mod.isub(o):u.mod,h=o.ushrn(1),g=o.andln(1),x=c.cmp(h);return x<0||g===1&&x===0?u.div:u.div.negative!==0?u.div.isubn(1):u.div.iaddn(1)},a.prototype.modn=function(o){n(o<=67108863);for(var u=(1<<26)%o,c=0,h=this.length-1;h>=0;h--)c=(u*c+(this.words[h]|0))%o;return c},a.prototype.idivn=function(o){n(o<=67108863);for(var u=0,c=this.length-1;c>=0;c--){var h=(this.words[c]|0)+u*67108864;this.words[c]=h/o|0,u=h%o}return this.strip()},a.prototype.divn=function(o){return this.clone().idivn(o)},a.prototype.egcd=function(o){n(o.negative===0),n(!o.isZero());var u=this,c=o.clone();u.negative!==0?u=u.umod(o):u=u.clone();for(var h=new a(1),g=new a(0),x=new a(0),E=new a(1),v=0;u.isEven()&&c.isEven();)u.iushrn(1),c.iushrn(1),++v;for(var l=c.clone(),m=u.clone();!u.isZero();){for(var P=0,N=1;!(u.words[0]&N)&&P<26;++P,N<<=1);if(P>0)for(u.iushrn(P);P-- >0;)(h.isOdd()||g.isOdd())&&(h.iadd(l),g.isub(m)),h.iushrn(1),g.iushrn(1);for(var F=0,ee=1;!(c.words[0]&ee)&&F<26;++F,ee<<=1);if(F>0)for(c.iushrn(F);F-- >0;)(x.isOdd()||E.isOdd())&&(x.iadd(l),E.isub(m)),x.iushrn(1),E.iushrn(1);u.cmp(c)>=0?(u.isub(c),h.isub(x),g.isub(E)):(c.isub(u),x.isub(h),E.isub(g))}return{a:x,b:E,gcd:c.iushln(v)}},a.prototype._invmp=function(o){n(o.negative===0),n(!o.isZero());var u=this,c=o.clone();u.negative!==0?u=u.umod(o):u=u.clone();for(var h=new a(1),g=new a(0),x=c.clone();u.cmpn(1)>0&&c.cmpn(1)>0;){for(var E=0,v=1;!(u.words[0]&v)&&E<26;++E,v<<=1);if(E>0)for(u.iushrn(E);E-- >0;)h.isOdd()&&h.iadd(x),h.iushrn(1);for(var l=0,m=1;!(c.words[0]&m)&&l<26;++l,m<<=1);if(l>0)for(c.iushrn(l);l-- >0;)g.isOdd()&&g.iadd(x),g.iushrn(1);u.cmp(c)>=0?(u.isub(c),h.isub(g)):(c.isub(u),g.isub(h))}var P;return u.cmpn(1)===0?P=h:P=g,P.cmpn(0)<0&&P.iadd(o),P},a.prototype.gcd=function(o){if(this.isZero())return o.abs();if(o.isZero())return this.abs();var u=this.clone(),c=o.clone();u.negative=0,c.negative=0;for(var h=0;u.isEven()&&c.isEven();h++)u.iushrn(1),c.iushrn(1);do{for(;u.isEven();)u.iushrn(1);for(;c.isEven();)c.iushrn(1);var g=u.cmp(c);if(g<0){var x=u;u=c,c=x}else if(g===0||c.cmpn(1)===0)break;u.isub(c)}while(!0);return c.iushln(h)},a.prototype.invm=function(o){return this.egcd(o).a.umod(o)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(o){return this.words[0]&o},a.prototype.bincn=function(o){n(typeof o=="number");var u=o%26,c=(o-u)/26,h=1<>>26,E&=67108863,this.words[x]=E}return g!==0&&(this.words[x]=g,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(o){var u=o<0;if(this.negative!==0&&!u)return-1;if(this.negative===0&&u)return 1;this.strip();var c;if(this.length>1)c=1;else{u&&(o=-o),n(o<=67108863,"Number is too big");var h=this.words[0]|0;c=h===o?0:ho.length)return 1;if(this.length=0;c--){var h=this.words[c]|0,g=o.words[c]|0;if(h!==g){hg&&(u=1);break}}return u},a.prototype.gtn=function(o){return this.cmpn(o)===1},a.prototype.gt=function(o){return this.cmp(o)===1},a.prototype.gten=function(o){return this.cmpn(o)>=0},a.prototype.gte=function(o){return this.cmp(o)>=0},a.prototype.ltn=function(o){return this.cmpn(o)===-1},a.prototype.lt=function(o){return this.cmp(o)===-1},a.prototype.lten=function(o){return this.cmpn(o)<=0},a.prototype.lte=function(o){return this.cmp(o)<=0},a.prototype.eqn=function(o){return this.cmpn(o)===0},a.prototype.eq=function(o){return this.cmp(o)===0},a.red=function(o){return new z(o)},a.prototype.toRed=function(o){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),o.convertTo(this)._forceRed(o)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(o){return this.red=o,this},a.prototype.forceRed=function(o){return n(!this.red,"Already a number in reduction context"),this._forceRed(o)},a.prototype.redAdd=function(o){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,o)},a.prototype.redIAdd=function(o){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,o)},a.prototype.redSub=function(o){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,o)},a.prototype.redISub=function(o){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,o)},a.prototype.redShl=function(o){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,o)},a.prototype.redMul=function(o){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,o),this.red.mul(this,o)},a.prototype.redIMul=function(o){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,o),this.red.imul(this,o)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(o){return n(this.red&&!o.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,o)};var R={k256:null,p224:null,p192:null,p25519:null};function $(b,o){this.name=b,this.p=new a(o,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}$.prototype._tmp=function(){var o=new a(null);return o.words=new Array(Math.ceil(this.n/13)),o},$.prototype.ireduce=function(o){var u=o,c;do this.split(u,this.tmp),u=this.imulK(u),u=u.iadd(this.tmp),c=u.bitLength();while(c>this.n);var h=c0?u.isub(this.p):u.strip!==void 0?u.strip():u._strip(),u},$.prototype.split=function(o,u){o.iushrn(this.n,0,u)},$.prototype.imulK=function(o){return o.imul(this.k)};function L(){$.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}i(L,$),L.prototype.split=function(o,u){for(var c=4194303,h=Math.min(o.length,9),g=0;g>>22,x=E}x>>>=22,o.words[g-10]=x,x===0&&o.length>10?o.length-=10:o.length-=9},L.prototype.imulK=function(o){o.words[o.length]=0,o.words[o.length+1]=0,o.length+=2;for(var u=0,c=0;c>>=26,o.words[c]=g,u=h}return u!==0&&(o.words[o.length++]=u),o},a._prime=function(o){if(R[o])return R[o];var u;if(o==="k256")u=new L;else if(o==="p224")u=new j;else if(o==="p192")u=new A;else if(o==="p25519")u=new V;else throw new Error("Unknown prime "+o);return R[o]=u,u};function z(b){if(typeof b=="string"){var o=a._prime(b);this.m=o.p,this.prime=o}else n(b.gtn(1),"modulus must be greater than 1"),this.m=b,this.prime=null}z.prototype._verify1=function(o){n(o.negative===0,"red works only with positives"),n(o.red,"red works only with red numbers")},z.prototype._verify2=function(o,u){n((o.negative|u.negative)===0,"red works only with positives"),n(o.red&&o.red===u.red,"red works only with red numbers")},z.prototype.imod=function(o){return this.prime?this.prime.ireduce(o)._forceRed(this):o.umod(this.m)._forceRed(this)},z.prototype.neg=function(o){return o.isZero()?o.clone():this.m.sub(o)._forceRed(this)},z.prototype.add=function(o,u){this._verify2(o,u);var c=o.add(u);return c.cmp(this.m)>=0&&c.isub(this.m),c._forceRed(this)},z.prototype.iadd=function(o,u){this._verify2(o,u);var c=o.iadd(u);return c.cmp(this.m)>=0&&c.isub(this.m),c},z.prototype.sub=function(o,u){this._verify2(o,u);var c=o.sub(u);return c.cmpn(0)<0&&c.iadd(this.m),c._forceRed(this)},z.prototype.isub=function(o,u){this._verify2(o,u);var c=o.isub(u);return c.cmpn(0)<0&&c.iadd(this.m),c},z.prototype.shl=function(o,u){return this._verify1(o),this.imod(o.ushln(u))},z.prototype.imul=function(o,u){return this._verify2(o,u),this.imod(o.imul(u))},z.prototype.mul=function(o,u){return this._verify2(o,u),this.imod(o.mul(u))},z.prototype.isqr=function(o){return this.imul(o,o.clone())},z.prototype.sqr=function(o){return this.mul(o,o)},z.prototype.sqrt=function(o){if(o.isZero())return o.clone();var u=this.m.andln(3);if(n(u%2===1),u===3){var c=this.m.add(new a(1)).iushrn(2);return this.pow(o,c)}for(var h=this.m.subn(1),g=0;!h.isZero()&&h.andln(1)===0;)g++,h.iushrn(1);n(!h.isZero());var x=new a(1).toRed(this),E=x.redNeg(),v=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new a(2*l*l).toRed(this);this.pow(l,v).cmp(E)!==0;)l.redIAdd(E);for(var m=this.pow(l,h),P=this.pow(o,h.addn(1).iushrn(1)),N=this.pow(o,h),F=g;N.cmp(x)!==0;){for(var ee=N,q=0;ee.cmp(x)!==0;q++)ee=ee.redSqr();n(q=0;g--){for(var m=u.words[g],P=l-1;P>=0;P--){var N=m>>P&1;if(x!==h[0]&&(x=this.sqr(x)),N===0&&E===0){v=0;continue}E<<=1,E|=N,v++,!(v!==c&&(g!==0||P!==0))&&(x=this.mul(x,h[E]),v=0,E=0)}l=26}return x},z.prototype.convertTo=function(o){var u=o.umod(this.m);return u===o?u.clone():u},z.prototype.convertFrom=function(o){var u=o.clone();return u.red=null,u},a.mont=function(o){return new Y(o)};function Y(b){z.call(this,b),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}i(Y,z),Y.prototype.convertTo=function(o){return this.imod(o.ushln(this.shift))},Y.prototype.convertFrom=function(o){var u=this.imod(o.mul(this.rinv));return u.red=null,u},Y.prototype.imul=function(o,u){if(o.isZero()||u.isZero())return o.words[0]=0,o.length=1,o;var c=o.imul(u),h=c.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),g=c.isub(h).iushrn(this.shift),x=g;return g.cmp(this.m)>=0?x=g.isub(this.m):g.cmpn(0)<0&&(x=g.iadd(this.m)),x._forceRed(this)},Y.prototype.mul=function(o,u){if(o.isZero()||u.isZero())return new a(0)._forceRed(this);var c=o.mul(u),h=c.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),g=c.isub(h).iushrn(this.shift),x=g;return g.cmp(this.m)>=0?x=g.isub(this.m):g.cmpn(0)<0&&(x=g.iadd(this.m)),x._forceRed(this)},Y.prototype.invm=function(o){var u=this.imod(o._invmp(this.m).mul(this.r2));return u._forceRed(this)}})(e,Ut)})(M5);var sl=M5.exports,E5={};(function(e){var t=e;function r(a,s){if(Array.isArray(a))return a.slice();if(!a)return[];var f=[];if(typeof a!="string"){for(var d=0;d>8,w=p&255;y?f.push(y,w):f.push(w)}return f}t.toArray=r;function n(a){return a.length===1?"0"+a:a}t.zero2=n;function i(a){for(var s="",f=0;f(M>>1)-1?T=(M>>1)-k:T=k,C.isubn(T)):T=0,S[O]=T,C.iushrn(1)}return S}t.getNAF=a;function s(y,w){var _=[[],[]];y=y.clone(),w=w.clone();for(var S=0,M=0,C;y.cmpn(-S)>0||w.cmpn(-M)>0;){var O=y.andln(3)+S&3,T=w.andln(3)+M&3;O===3&&(O=-1),T===3&&(T=-1);var k;O&1?(C=y.andln(7)+S&7,(C===3||C===5)&&T===2?k=-O:k=O):k=0,_[0].push(k);var R;T&1?(C=w.andln(7)+M&7,(C===3||C===5)&&O===2?R=-T:R=T):R=0,_[1].push(R),2*S===k+1&&(S=1-S),2*M===R+1&&(M=1-M),y.iushrn(1),w.iushrn(1)}return _}t.getJSF=s;function f(y,w,_){var S="_"+w;y.prototype[w]=function(){return this[S]!==void 0?this[S]:this[S]=_.call(this)}}t.cachedProperty=f;function d(y){return typeof y=="string"?t.toArray(y,"hex"):y}t.parseBytes=d;function p(y){return new r(y,"hex","le")}t.intFromLE=p})(va);var k5={},Ou=sl,_p=va,zg=_p.getNAF,jee=_p.getJSF,Ug=_p.assert;function hu(e,t){this.type=e,this.p=new Ou(t.p,16),this.red=t.prime?Ou.red(t.prime):Ou.mont(this.p),this.zero=new Ou(0).toRed(this.red),this.one=new Ou(1).toRed(this.red),this.two=new Ou(2).toRed(this.red),this.n=t.n&&new Ou(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var Uy=hu;hu.prototype.point=function(){throw new Error("Not implemented")};hu.prototype.validate=function(){throw new Error("Not implemented")};hu.prototype._fixedNafMul=function(t,r){Ug(t.precomputed);var n=t._getDoubles(),i=zg(r,1,this._bitLength),a=(1<=f;p--)d=(d<<1)+i[p];s.push(d)}for(var y=this.jpoint(null,null,null),w=this.jpoint(null,null,null),_=a;_>0;_--){for(f=0;f=0;d--){for(var p=0;d>=0&&s[d]===0;d--)p++;if(d>=0&&p++,f=f.dblp(p),d<0)break;var y=s[d];Ug(y!==0),t.type==="affine"?y>0?f=f.mixedAdd(a[y-1>>1]):f=f.mixedAdd(a[-y-1>>1].neg()):y>0?f=f.add(a[y-1>>1]):f=f.add(a[-y-1>>1].neg())}return t.type==="affine"?f.toP():f};hu.prototype._wnafMulAdd=function(t,r,n,i,a){var s=this._wnafT1,f=this._wnafT2,d=this._wnafT3,p=0,y,w,_;for(y=0;y=1;y-=2){var M=y-1,C=y;if(s[M]!==1||s[C]!==1){d[M]=zg(n[M],s[M],this._bitLength),d[C]=zg(n[C],s[C],this._bitLength),p=Math.max(d[M].length,p),p=Math.max(d[C].length,p);continue}var O=[r[M],null,null,r[C]];r[M].y.cmp(r[C].y)===0?(O[1]=r[M].add(r[C]),O[2]=r[M].toJ().mixedAdd(r[C].neg())):r[M].y.cmp(r[C].y.redNeg())===0?(O[1]=r[M].toJ().mixedAdd(r[C]),O[2]=r[M].add(r[C].neg())):(O[1]=r[M].toJ().mixedAdd(r[C]),O[2]=r[M].toJ().mixedAdd(r[C].neg()));var T=[-3,-1,-5,-7,0,7,5,1,3],k=jee(n[M],n[C]);for(p=Math.max(k[0].length,p),d[M]=new Array(p),d[C]=new Array(p),w=0;w=0;y--){for(var A=0;y>=0;){var V=!0;for(w=0;w=0&&A++,L=L.dblp(A),y<0)break;for(w=0;w0?_=f[w][z-1>>1]:z<0&&(_=f[w][-z-1>>1].neg()),_.type==="affine"?L=L.mixedAdd(_):L=L.add(_))}}for(y=0;y=Math.ceil((t.bitLength()+1)/r.step):!1};Za.prototype._getDoubles=function(t,r){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var n=[this],i=this,a=0;a=0&&(S=p,M=y),w.negative&&(w=w.neg(),_=_.neg()),S.negative&&(S=S.neg(),M=M.neg()),[{a:w,b:_},{a:S,b:M}]};Ja.prototype._endoSplit=function(t){var r=this.endo.basis,n=r[0],i=r[1],a=i.b.mul(t).divRound(this.n),s=n.b.neg().mul(t).divRound(this.n),f=a.mul(n.a),d=s.mul(i.a),p=a.mul(n.b),y=s.mul(i.b),w=t.sub(f).sub(d),_=p.add(y).neg();return{k1:w,k2:_}};Ja.prototype.pointFromX=function(t,r){t=new fn(t,16),t.red||(t=t.toRed(this.red));var n=t.redSqr().redMul(t).redIAdd(t.redMul(this.a)).redIAdd(this.b),i=n.redSqrt();if(i.redSqr().redSub(n).cmp(this.zero)!==0)throw new Error("invalid point");var a=i.fromRed().isOdd();return(r&&!a||!r&&a)&&(i=i.redNeg()),this.point(t,i)};Ja.prototype.validate=function(t){if(t.inf)return!0;var r=t.x,n=t.y,i=this.a.redMul(r),a=r.redSqr().redMul(r).redIAdd(i).redIAdd(this.b);return n.redSqr().redISub(a).cmpn(0)===0};Ja.prototype._endoWnafMulAdd=function(t,r,n){for(var i=this._endoWnafT1,a=this._endoWnafT2,s=0;s":""};Hn.prototype.isInfinity=function(){return this.inf};Hn.prototype.add=function(t){if(this.inf)return t;if(t.inf)return this;if(this.eq(t))return this.dbl();if(this.neg().eq(t))return this.curve.point(null,null);if(this.x.cmp(t.x)===0)return this.curve.point(null,null);var r=this.y.redSub(t.y);r.cmpn(0)!==0&&(r=r.redMul(this.x.redSub(t.x).redInvm()));var n=r.redSqr().redISub(this.x).redISub(t.x),i=r.redMul(this.x.redSub(n)).redISub(this.y);return this.curve.point(n,i)};Hn.prototype.dbl=function(){if(this.inf)return this;var t=this.y.redAdd(this.y);if(t.cmpn(0)===0)return this.curve.point(null,null);var r=this.curve.a,n=this.x.redSqr(),i=t.redInvm(),a=n.redAdd(n).redIAdd(n).redIAdd(r).redMul(i),s=a.redSqr().redISub(this.x.redAdd(this.x)),f=a.redMul(this.x.redSub(s)).redISub(this.y);return this.curve.point(s,f)};Hn.prototype.getX=function(){return this.x.fromRed()};Hn.prototype.getY=function(){return this.y.fromRed()};Hn.prototype.mul=function(t){return t=new fn(t,16),this.isInfinity()?this:this._hasDoubles(t)?this.curve._fixedNafMul(this,t):this.curve.endo?this.curve._endoWnafMulAdd([this],[t]):this.curve._wnafMul(this,t)};Hn.prototype.mulAdd=function(t,r,n){var i=[this,r],a=[t,n];return this.curve.endo?this.curve._endoWnafMulAdd(i,a):this.curve._wnafMulAdd(1,i,a,2)};Hn.prototype.jmulAdd=function(t,r,n){var i=[this,r],a=[t,n];return this.curve.endo?this.curve._endoWnafMulAdd(i,a,!0):this.curve._wnafMulAdd(1,i,a,2,!0)};Hn.prototype.eq=function(t){return this===t||this.inf===t.inf&&(this.inf||this.x.cmp(t.x)===0&&this.y.cmp(t.y)===0)};Hn.prototype.neg=function(t){if(this.inf)return this;var r=this.curve.point(this.x,this.y.redNeg());if(t&&this.precomputed){var n=this.precomputed,i=function(a){return a.neg()};r.precomputed={naf:n.naf&&{wnd:n.naf.wnd,points:n.naf.points.map(i)},doubles:n.doubles&&{step:n.doubles.step,points:n.doubles.points.map(i)}}}return r};Hn.prototype.toJ=function(){if(this.inf)return this.curve.jpoint(null,null,null);var t=this.curve.jpoint(this.x,this.y,this.curve.one);return t};function Qn(e,t,r,n){Rd.BasePoint.call(this,e,"jacobian"),t===null&&r===null&&n===null?(this.x=this.curve.one,this.y=this.curve.one,this.z=new fn(0)):(this.x=new fn(t,16),this.y=new fn(r,16),this.z=new fn(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}T5(Qn,Rd.BasePoint);Ja.prototype.jpoint=function(t,r,n){return new Qn(this,t,r,n)};Qn.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var t=this.z.redInvm(),r=t.redSqr(),n=this.x.redMul(r),i=this.y.redMul(r).redMul(t);return this.curve.point(n,i)};Qn.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)};Qn.prototype.add=function(t){if(this.isInfinity())return t;if(t.isInfinity())return this;var r=t.z.redSqr(),n=this.z.redSqr(),i=this.x.redMul(r),a=t.x.redMul(n),s=this.y.redMul(r.redMul(t.z)),f=t.y.redMul(n.redMul(this.z)),d=i.redSub(a),p=s.redSub(f);if(d.cmpn(0)===0)return p.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var y=d.redSqr(),w=y.redMul(d),_=i.redMul(y),S=p.redSqr().redIAdd(w).redISub(_).redISub(_),M=p.redMul(_.redISub(S)).redISub(s.redMul(w)),C=this.z.redMul(t.z).redMul(d);return this.curve.jpoint(S,M,C)};Qn.prototype.mixedAdd=function(t){if(this.isInfinity())return t.toJ();if(t.isInfinity())return this;var r=this.z.redSqr(),n=this.x,i=t.x.redMul(r),a=this.y,s=t.y.redMul(r).redMul(this.z),f=n.redSub(i),d=a.redSub(s);if(f.cmpn(0)===0)return d.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var p=f.redSqr(),y=p.redMul(f),w=n.redMul(p),_=d.redSqr().redIAdd(y).redISub(w).redISub(w),S=d.redMul(w.redISub(_)).redISub(a.redMul(y)),M=this.z.redMul(f);return this.curve.jpoint(_,S,M)};Qn.prototype.dblp=function(t){if(t===0)return this;if(this.isInfinity())return this;if(!t)return this.dbl();var r;if(this.curve.zeroA||this.curve.threeA){var n=this;for(r=0;r=0)return!1;if(n.redIAdd(a),this.x.cmp(n)===0)return!0}};Qn.prototype.inspect=function(){return this.isInfinity()?"":""};Qn.prototype.isInfinity=function(){return this.z.cmpn(0)===0};var hf=sl,ZI=or,Hy=Uy,Uee=va;function Ad(e){Hy.call(this,"mont",e),this.a=new hf(e.a,16).toRed(this.red),this.b=new hf(e.b,16).toRed(this.red),this.i4=new hf(4).toRed(this.red).redInvm(),this.two=new hf(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}ZI(Ad,Hy);var Hee=Ad;Ad.prototype.validate=function(t){var r=t.normalize().x,n=r.redSqr(),i=n.redMul(r).redAdd(n.redMul(this.a)).redAdd(r),a=i.redSqrt();return a.redSqr().cmp(i)===0};function Fn(e,t,r){Hy.BasePoint.call(this,e,"projective"),t===null&&r===null?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new hf(t,16),this.z=new hf(r,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}ZI(Fn,Hy.BasePoint);Ad.prototype.decodePoint=function(t,r){return this.point(Uee.toArray(t,r),1)};Ad.prototype.point=function(t,r){return new Fn(this,t,r)};Ad.prototype.pointFromJSON=function(t){return Fn.fromJSON(this,t)};Fn.prototype.precompute=function(){};Fn.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())};Fn.fromJSON=function(t,r){return new Fn(t,r[0],r[1]||t.one)};Fn.prototype.inspect=function(){return this.isInfinity()?"":""};Fn.prototype.isInfinity=function(){return this.z.cmpn(0)===0};Fn.prototype.dbl=function(){var t=this.x.redAdd(this.z),r=t.redSqr(),n=this.x.redSub(this.z),i=n.redSqr(),a=r.redSub(i),s=r.redMul(i),f=a.redMul(i.redAdd(this.curve.a24.redMul(a)));return this.curve.point(s,f)};Fn.prototype.add=function(){throw new Error("Not supported on Montgomery curve")};Fn.prototype.diffAdd=function(t,r){var n=this.x.redAdd(this.z),i=this.x.redSub(this.z),a=t.x.redAdd(t.z),s=t.x.redSub(t.z),f=s.redMul(n),d=a.redMul(i),p=r.z.redMul(f.redAdd(d).redSqr()),y=r.x.redMul(f.redISub(d).redSqr());return this.curve.point(p,y)};Fn.prototype.mul=function(t){for(var r=t.clone(),n=this,i=this.curve.point(null,null),a=this,s=[];r.cmpn(0)!==0;r.iushrn(1))s.push(r.andln(1));for(var f=s.length-1;f>=0;f--)s[f]===0?(n=n.diffAdd(i,a),i=i.dbl()):(i=n.diffAdd(i,a),n=n.dbl());return i};Fn.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")};Fn.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")};Fn.prototype.eq=function(t){return this.getX().cmp(t.getX())===0};Fn.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this};Fn.prototype.getX=function(){return this.normalize(),this.x.fromRed()};var Vee=va,Hs=sl,JI=or,Vy=Uy,qee=Vee.assert;function xs(e){this.twisted=(e.a|0)!==1,this.mOneA=this.twisted&&(e.a|0)===-1,this.extended=this.mOneA,Vy.call(this,"edwards",e),this.a=new Hs(e.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new Hs(e.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new Hs(e.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),qee(!this.twisted||this.c.fromRed().cmpn(1)===0),this.oneC=(e.c|0)===1}JI(xs,Vy);var Wee=xs;xs.prototype._mulA=function(t){return this.mOneA?t.redNeg():this.a.redMul(t)};xs.prototype._mulC=function(t){return this.oneC?t:this.c.redMul(t)};xs.prototype.jpoint=function(t,r,n,i){return this.point(t,r,n,i)};xs.prototype.pointFromX=function(t,r){t=new Hs(t,16),t.red||(t=t.toRed(this.red));var n=t.redSqr(),i=this.c2.redSub(this.a.redMul(n)),a=this.one.redSub(this.c2.redMul(this.d).redMul(n)),s=i.redMul(a.redInvm()),f=s.redSqrt();if(f.redSqr().redSub(s).cmp(this.zero)!==0)throw new Error("invalid point");var d=f.fromRed().isOdd();return(r&&!d||!r&&d)&&(f=f.redNeg()),this.point(t,f)};xs.prototype.pointFromY=function(t,r){t=new Hs(t,16),t.red||(t=t.toRed(this.red));var n=t.redSqr(),i=n.redSub(this.c2),a=n.redMul(this.d).redMul(this.c2).redSub(this.a),s=i.redMul(a.redInvm());if(s.cmp(this.zero)===0){if(r)throw new Error("invalid point");return this.point(this.zero,t)}var f=s.redSqrt();if(f.redSqr().redSub(s).cmp(this.zero)!==0)throw new Error("invalid point");return f.fromRed().isOdd()!==r&&(f=f.redNeg()),this.point(f,t)};xs.prototype.validate=function(t){if(t.isInfinity())return!0;t.normalize();var r=t.x.redSqr(),n=t.y.redSqr(),i=r.redMul(this.a).redAdd(n),a=this.c2.redMul(this.one.redAdd(this.d.redMul(r).redMul(n)));return i.cmp(a)===0};function Xr(e,t,r,n,i){Vy.BasePoint.call(this,e,"projective"),t===null&&r===null&&n===null?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new Hs(t,16),this.y=new Hs(r,16),this.z=n?new Hs(n,16):this.curve.one,this.t=i&&new Hs(i,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}JI(Xr,Vy.BasePoint);xs.prototype.pointFromJSON=function(t){return Xr.fromJSON(this,t)};xs.prototype.point=function(t,r,n,i){return new Xr(this,t,r,n,i)};Xr.fromJSON=function(t,r){return new Xr(t,r[0],r[1],r[2])};Xr.prototype.inspect=function(){return this.isInfinity()?"":""};Xr.prototype.isInfinity=function(){return this.x.cmpn(0)===0&&(this.y.cmp(this.z)===0||this.zOne&&this.y.cmp(this.curve.c)===0)};Xr.prototype._extDbl=function(){var t=this.x.redSqr(),r=this.y.redSqr(),n=this.z.redSqr();n=n.redIAdd(n);var i=this.curve._mulA(t),a=this.x.redAdd(this.y).redSqr().redISub(t).redISub(r),s=i.redAdd(r),f=s.redSub(n),d=i.redSub(r),p=a.redMul(f),y=s.redMul(d),w=a.redMul(d),_=f.redMul(s);return this.curve.point(p,y,_,w)};Xr.prototype._projDbl=function(){var t=this.x.redAdd(this.y).redSqr(),r=this.x.redSqr(),n=this.y.redSqr(),i,a,s,f,d,p;if(this.curve.twisted){f=this.curve._mulA(r);var y=f.redAdd(n);this.zOne?(i=t.redSub(r).redSub(n).redMul(y.redSub(this.curve.two)),a=y.redMul(f.redSub(n)),s=y.redSqr().redSub(y).redSub(y)):(d=this.z.redSqr(),p=y.redSub(d).redISub(d),i=t.redSub(r).redISub(n).redMul(p),a=y.redMul(f.redSub(n)),s=y.redMul(p))}else f=r.redAdd(n),d=this.curve._mulC(this.z).redSqr(),p=f.redSub(d).redSub(d),i=this.curve._mulC(t.redISub(f)).redMul(p),a=this.curve._mulC(f).redMul(r.redISub(n)),s=f.redMul(p);return this.curve.point(i,a,s)};Xr.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()};Xr.prototype._extAdd=function(t){var r=this.y.redSub(this.x).redMul(t.y.redSub(t.x)),n=this.y.redAdd(this.x).redMul(t.y.redAdd(t.x)),i=this.t.redMul(this.curve.dd).redMul(t.t),a=this.z.redMul(t.z.redAdd(t.z)),s=n.redSub(r),f=a.redSub(i),d=a.redAdd(i),p=n.redAdd(r),y=s.redMul(f),w=d.redMul(p),_=s.redMul(p),S=f.redMul(d);return this.curve.point(y,w,S,_)};Xr.prototype._projAdd=function(t){var r=this.z.redMul(t.z),n=r.redSqr(),i=this.x.redMul(t.x),a=this.y.redMul(t.y),s=this.curve.d.redMul(i).redMul(a),f=n.redSub(s),d=n.redAdd(s),p=this.x.redAdd(this.y).redMul(t.x.redAdd(t.y)).redISub(i).redISub(a),y=r.redMul(f).redMul(p),w,_;return this.curve.twisted?(w=r.redMul(d).redMul(a.redSub(this.curve._mulA(i))),_=f.redMul(d)):(w=r.redMul(d).redMul(a.redSub(i)),_=this.curve._mulC(f).redMul(d)),this.curve.point(y,w,_)};Xr.prototype.add=function(t){return this.isInfinity()?t:t.isInfinity()?this:this.curve.extended?this._extAdd(t):this._projAdd(t)};Xr.prototype.mul=function(t){return this._hasDoubles(t)?this.curve._fixedNafMul(this,t):this.curve._wnafMul(this,t)};Xr.prototype.mulAdd=function(t,r,n){return this.curve._wnafMulAdd(1,[this,r],[t,n],2,!1)};Xr.prototype.jmulAdd=function(t,r,n){return this.curve._wnafMulAdd(1,[this,r],[t,n],2,!0)};Xr.prototype.normalize=function(){if(this.zOne)return this;var t=this.z.redInvm();return this.x=this.x.redMul(t),this.y=this.y.redMul(t),this.t&&(this.t=this.t.redMul(t)),this.z=this.curve.one,this.zOne=!0,this};Xr.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())};Xr.prototype.getX=function(){return this.normalize(),this.x.fromRed()};Xr.prototype.getY=function(){return this.normalize(),this.y.fromRed()};Xr.prototype.eq=function(t){return this===t||this.getX().cmp(t.getX())===0&&this.getY().cmp(t.getY())===0};Xr.prototype.eqXToP=function(t){var r=t.toRed(this.curve.red).redMul(this.z);if(this.x.cmp(r)===0)return!0;for(var n=t.clone(),i=this.curve.redN.redMul(this.z);;){if(n.iadd(this.curve.n),n.cmp(this.curve.p)>=0)return!1;if(r.redIAdd(i),this.x.cmp(r)===0)return!0}};Xr.prototype.toP=Xr.prototype.normalize;Xr.prototype.mixedAdd=Xr.prototype.add;(function(e){var t=e;t.base=Uy,t.short=zee,t.mont=Hee,t.edwards=Wee})(k5);var qy={},Wy={},yr={},Kee=Ya,Gee=or;yr.inherits=Gee;function Yee(e,t){return(e.charCodeAt(t)&64512)!==55296||t<0||t+1>=e.length?!1:(e.charCodeAt(t+1)&64512)===56320}function Xee(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if(typeof e=="string")if(t){if(t==="hex")for(e=e.replace(/[^a-z0-9]+/ig,""),e.length%2!==0&&(e="0"+e),i=0;i>6|192,r[n++]=a&63|128):Yee(e,i)?(a=65536+((a&1023)<<10)+(e.charCodeAt(++i)&1023),r[n++]=a>>18|240,r[n++]=a>>12&63|128,r[n++]=a>>6&63|128,r[n++]=a&63|128):(r[n++]=a>>12|224,r[n++]=a>>6&63|128,r[n++]=a&63|128)}else for(i=0;i>>24|e>>>8&65280|e<<8&16711680|(e&255)<<24;return t>>>0}yr.htonl=QI;function Jee(e,t){for(var r="",n=0;n>>0}return a}yr.join32=Qee;function ete(e,t){for(var r=new Array(e.length*4),n=0,i=0;n>>24,r[i+1]=a>>>16&255,r[i+2]=a>>>8&255,r[i+3]=a&255):(r[i+3]=a>>>24,r[i+2]=a>>>16&255,r[i+1]=a>>>8&255,r[i]=a&255)}return r}yr.split32=ete;function tte(e,t){return e>>>t|e<<32-t}yr.rotr32=tte;function rte(e,t){return e<>>32-t}yr.rotl32=rte;function nte(e,t){return e+t>>>0}yr.sum32=nte;function ite(e,t,r){return e+t+r>>>0}yr.sum32_3=ite;function ate(e,t,r,n){return e+t+r+n>>>0}yr.sum32_4=ate;function ote(e,t,r,n,i){return e+t+r+n+i>>>0}yr.sum32_5=ote;function ste(e,t,r,n){var i=e[t],a=e[t+1],s=n+a>>>0,f=(s>>0,e[t+1]=s}yr.sum64=ste;function lte(e,t,r,n){var i=t+n>>>0,a=(i>>0}yr.sum64_hi=lte;function ute(e,t,r,n){var i=t+n;return i>>>0}yr.sum64_lo=ute;function cte(e,t,r,n,i,a,s,f){var d=0,p=t;p=p+n>>>0,d+=p>>0,d+=p>>0,d+=p>>0}yr.sum64_4_hi=cte;function fte(e,t,r,n,i,a,s,f){var d=t+n+a+f;return d>>>0}yr.sum64_4_lo=fte;function dte(e,t,r,n,i,a,s,f,d,p){var y=0,w=t;w=w+n>>>0,y+=w>>0,y+=w>>0,y+=w>>0,y+=w>>0}yr.sum64_5_hi=dte;function hte(e,t,r,n,i,a,s,f,d,p){var y=t+n+a+f+p;return y>>>0}yr.sum64_5_lo=hte;function pte(e,t,r){var n=t<<32-r|e>>>r;return n>>>0}yr.rotr64_hi=pte;function mte(e,t,r){var n=e<<32-r|t>>>r;return n>>>0}yr.rotr64_lo=mte;function vte(e,t,r){return e>>>r}yr.shr64_hi=vte;function gte(e,t,r){var n=e<<32-r|t>>>r;return n>>>0}yr.shr64_lo=gte;var Dd={},kT=yr,yte=Ya;function Ky(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}Dd.BlockHash=Ky;Ky.prototype.update=function(t,r){if(t=kT.toArray(t,r),this.pending?this.pending=this.pending.concat(t):this.pending=t,this.pendingTotal+=t.length,this.pending.length>=this._delta8){t=this.pending;var n=t.length%this._delta8;this.pending=t.slice(t.length-n,t.length),this.pending.length===0&&(this.pending=null),t=kT.join32(t,0,t.length-n,this.endian);for(var i=0;i>>24&255,i[a++]=t>>>16&255,i[a++]=t>>>8&255,i[a++]=t&255}else for(i[a++]=t&255,i[a++]=t>>>8&255,i[a++]=t>>>16&255,i[a++]=t>>>24&255,i[a++]=0,i[a++]=0,i[a++]=0,i[a++]=0,s=8;s>>3}_s.g0_256=Ste;function Mte(e){return rs(e,17)^rs(e,19)^e>>>10}_s.g1_256=Mte;var Kf=yr,Ete=Dd,kte=_s,z2=Kf.rotl32,Sh=Kf.sum32,Tte=Kf.sum32_5,Cte=kte.ft_1,aL=Ete.BlockHash,Pte=[1518500249,1859775393,2400959708,3395469782];function ds(){if(!(this instanceof ds))return new ds;aL.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}Kf.inherits(ds,aL);var Ote=ds;ds.blockSize=512;ds.outSize=160;ds.hmacStrength=80;ds.padLength=64;ds.prototype._update=function(t,r){for(var n=this.W,i=0;i<16;i++)n[i]=t[r+i];for(;ithis.blockSize&&(t=new this.Hash().update(t).digest()),gre(t.length<=this.blockSize);for(var r=t.length;r=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}var xre=nu;nu.prototype._init=function(t,r,n){var i=t.concat(r).concat(n);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var a=0;a=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(t.concat(n||[])),this._reseed=1};nu.prototype.generate=function(t,r,n,i){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");typeof r!="string"&&(i=n,n=r,r=null),n&&(n=Ju.toArray(n,i||"hex"),this._update(n));for(var a=[];a.length"};var Hg=sl,C5=va,Ere=C5.assert;function Gy(e,t){if(e instanceof Gy)return e;this._importDER(e,t)||(Ere(e.r&&e.s,"Signature without r or s"),this.r=new Hg(e.r,16),this.s=new Hg(e.s,16),e.recoveryParam===void 0?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}var kre=Gy;function Tre(){this.place=0}function q2(e,t){var r=e[t.place++];if(!(r&128))return r;var n=r&15;if(n===0||n>4)return!1;for(var i=0,a=0,s=t.place;a>>=0;return i<=127?!1:(t.place=s,i)}function RT(e){for(var t=0,r=e.length-1;!e[t]&&!(e[t+1]&128)&&t>>3);for(e.push(r|128);--r;)e.push(t>>>(r<<3)&255);e.push(t)}Gy.prototype.toDER=function(t){var r=this.r.toArray(),n=this.s.toArray();for(r[0]&128&&(r=[0].concat(r)),n[0]&128&&(n=[0].concat(n)),r=RT(r),n=RT(n);!n[0]&&!(n[1]&128);)n=n.slice(1);var i=[2];W2(i,r.length),i=i.concat(r),i.push(2),W2(i,n.length);var a=i.concat(n),s=[48];return W2(s,a.length),s=s.concat(a),C5.encode(s,t)};var K2,AT;function Cre(){if(AT)return K2;AT=1;var e=sl,t=xre,r=va,n=qy,i=b5(),a=r.assert,s=Mre,f=kre;function d(p){if(!(this instanceof d))return new d(p);typeof p=="string"&&(a(Object.prototype.hasOwnProperty.call(n,p),"Unknown curve "+p),p=n[p]),p instanceof n.PresetCurve&&(p={curve:p}),this.curve=p.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=p.curve.g,this.g.precompute(p.curve.n.bitLength()+1),this.hash=p.hash||p.curve.hash}return K2=d,d.prototype.keyPair=function(y){return new s(this,y)},d.prototype.keyFromPrivate=function(y,w){return s.fromPrivate(this,y,w)},d.prototype.keyFromPublic=function(y,w){return s.fromPublic(this,y,w)},d.prototype.genKeyPair=function(y){y||(y={});for(var w=new t({hash:this.hash,pers:y.pers,persEnc:y.persEnc||"utf8",entropy:y.entropy||i(this.hash.hmacStrength),entropyEnc:y.entropy&&y.entropyEnc||"utf8",nonce:this.n.toArray()}),_=this.n.byteLength(),S=this.n.sub(new e(2));;){var M=new e(w.generate(_));if(!(M.cmp(S)>0))return M.iaddn(1),this.keyFromPrivate(M)}},d.prototype._truncateToN=function(y,w){var _=y.byteLength()*8-this.n.bitLength();return _>0&&(y=y.ushrn(_)),!w&&y.cmp(this.n)>=0?y.sub(this.n):y},d.prototype.sign=function(y,w,_,S){typeof _=="object"&&(S=_,_=null),S||(S={}),w=this.keyFromPrivate(w,_),y=this._truncateToN(new e(y,16));for(var M=this.n.byteLength(),C=w.getPrivate().toArray("be",M),O=y.toArray("be",M),T=new t({hash:this.hash,entropy:C,nonce:O,pers:S.pers,persEnc:S.persEnc||"utf8"}),k=this.n.sub(new e(1)),R=0;;R++){var $=S.k?S.k(R):new e(T.generate(this.n.byteLength()));if($=this._truncateToN($,!0),!($.cmpn(1)<=0||$.cmp(k)>=0)){var L=this.g.mul($);if(!L.isInfinity()){var j=L.getX(),A=j.umod(this.n);if(A.cmpn(0)!==0){var V=$.invm(this.n).mul(A.mul(w.getPrivate()).iadd(y));if(V=V.umod(this.n),V.cmpn(0)!==0){var z=(L.getY().isOdd()?1:0)|(j.cmp(A)!==0?2:0);return S.canonical&&V.cmp(this.nh)>0&&(V=this.n.sub(V),z^=1),new f({r:A,s:V,recoveryParam:z})}}}}}},d.prototype.verify=function(y,w,_,S){y=this._truncateToN(new e(y,16)),_=this.keyFromPublic(_,S),w=new f(w,"hex");var M=w.r,C=w.s;if(M.cmpn(1)<0||M.cmp(this.n)>=0||C.cmpn(1)<0||C.cmp(this.n)>=0)return!1;var O=C.invm(this.n),T=O.mul(y).umod(this.n),k=O.mul(M).umod(this.n),R;return this.curve._maxwellTrick?(R=this.g.jmulAdd(T,_.getPublic(),k),R.isInfinity()?!1:R.eqXToP(M)):(R=this.g.mulAdd(T,_.getPublic(),k),R.isInfinity()?!1:R.getX().umod(this.n).cmp(M)===0)},d.prototype.recoverPubKey=function(p,y,w,_){a((3&w)===w,"The recovery param is more than two bits"),y=new f(y,_);var S=this.n,M=new e(p),C=y.r,O=y.s,T=w&1,k=w>>1;if(C.cmp(this.curve.p.umod(this.curve.n))>=0&&k)throw new Error("Unable to find sencond key candinate");k?C=this.curve.pointFromX(C.add(this.curve.n),T):C=this.curve.pointFromX(C,T);var R=y.r.invm(S),$=S.sub(M).mul(R).umod(S),L=O.mul(R).umod(S);return this.g.mulAdd($,C,L)},d.prototype.getKeyRecoveryParam=function(p,y,w,_){if(y=new f(y,_),y.recoveryParam!==null)return y.recoveryParam;for(var S=0;S<4;S++){var M;try{M=this.recoverPubKey(p,y,S)}catch{continue}if(M.eq(w))return S}throw new Error("Unable to find valid recovery factor")},K2}var Sp=va,gL=Sp.assert,DT=Sp.parseBytes,Ld=Sp.cachedProperty;function Bn(e,t){this.eddsa=e,this._secret=DT(t.secret),e.isPoint(t.pub)?this._pub=t.pub:this._pubBytes=DT(t.pub)}Bn.fromPublic=function(t,r){return r instanceof Bn?r:new Bn(t,{pub:r})};Bn.fromSecret=function(t,r){return r instanceof Bn?r:new Bn(t,{secret:r})};Bn.prototype.secret=function(){return this._secret};Ld(Bn,"pubBytes",function(){return this.eddsa.encodePoint(this.pub())});Ld(Bn,"pub",function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())});Ld(Bn,"privBytes",function(){var t=this.eddsa,r=this.hash(),n=t.encodingLength-1,i=r.slice(0,t.encodingLength);return i[0]&=248,i[n]&=127,i[n]|=64,i});Ld(Bn,"priv",function(){return this.eddsa.decodeInt(this.privBytes())});Ld(Bn,"hash",function(){return this.eddsa.hash().update(this.secret()).digest()});Ld(Bn,"messagePrefix",function(){return this.hash().slice(this.eddsa.encodingLength)});Bn.prototype.sign=function(t){return gL(this._secret,"KeyPair can only verify"),this.eddsa.sign(t,this)};Bn.prototype.verify=function(t,r){return this.eddsa.verify(t,r,this)};Bn.prototype.getSecret=function(t){return gL(this._secret,"KeyPair is public only"),Sp.encode(this.secret(),t)};Bn.prototype.getPublic=function(t){return Sp.encode(this.pubBytes(),t)};var Pre=Bn,Ore=sl,Yy=va,Rre=Yy.assert,Xy=Yy.cachedProperty,Are=Yy.parseBytes;function Ec(e,t){this.eddsa=e,typeof t!="object"&&(t=Are(t)),Array.isArray(t)&&(t={R:t.slice(0,e.encodingLength),S:t.slice(e.encodingLength)}),Rre(t.R&&t.S,"Signature without R or S"),e.isPoint(t.R)&&(this._R=t.R),t.S instanceof Ore&&(this._S=t.S),this._Rencoded=Array.isArray(t.R)?t.R:t.Rencoded,this._Sencoded=Array.isArray(t.S)?t.S:t.Sencoded}Xy(Ec,"S",function(){return this.eddsa.decodeInt(this.Sencoded())});Xy(Ec,"R",function(){return this.eddsa.decodePoint(this.Rencoded())});Xy(Ec,"Rencoded",function(){return this.eddsa.encodePoint(this.R())});Xy(Ec,"Sencoded",function(){return this.eddsa.encodeInt(this.S())});Ec.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())};Ec.prototype.toHex=function(){return Yy.encode(this.toBytes(),"hex").toUpperCase()};var Dre=Ec,$re=Wy,Ire=qy,Xf=va,Lre=Xf.assert,yL=Xf.parseBytes,wL=Pre,$T=Dre;function Vi(e){if(Lre(e==="ed25519","only tested with ed25519 so far"),!(this instanceof Vi))return new Vi(e);e=Ire[e].curve,this.curve=e,this.g=e.g,this.g.precompute(e.n.bitLength()+1),this.pointClass=e.point().constructor,this.encodingLength=Math.ceil(e.n.bitLength()/8),this.hash=$re.sha512}var Nre=Vi;Vi.prototype.sign=function(t,r){t=yL(t);var n=this.keyFromSecret(r),i=this.hashInt(n.messagePrefix(),t),a=this.g.mul(i),s=this.encodePoint(a),f=this.hashInt(s,n.pubBytes(),t).mul(n.priv()),d=i.add(f).umod(this.curve.n);return this.makeSignature({R:a,S:d,Rencoded:s})};Vi.prototype.verify=function(t,r,n){t=yL(t),r=this.makeSignature(r);var i=this.keyFromPublic(n),a=this.hashInt(r.Rencoded(),i.pubBytes(),t),s=this.g.mul(r.S()),f=r.R().add(i.pub().mul(a));return f.eq(s)};Vi.prototype.hashInt=function(){for(var t=this.hash(),r=0;r0?o:u},a.min=function(o,u){return o.cmp(u)<0?o:u},a.prototype._init=function(o,u,c){if(typeof o=="number")return this._initNumber(o,u,c);if(typeof o=="object")return this._initArray(o,u,c);u==="hex"&&(u=16),n(u===(u|0)&&u>=2&&u<=36),o=o.toString().replace(/\s+/g,"");var h=0;o[0]==="-"&&(h++,this.negative=1),h=0;h-=3)x=o[h]|o[h-1]<<8|o[h-2]<<16,this.words[g]|=x<>>26-E&67108863,E+=24,E>=26&&(E-=26,g++);else if(c==="le")for(h=0,g=0;h>>26-E&67108863,E+=24,E>=26&&(E-=26,g++);return this.strip()};function f(b,o){var u=b.charCodeAt(o);return u>=65&&u<=70?u-55:u>=97&&u<=102?u-87:u-48&15}function d(b,o,u){var c=f(b,u);return u-1>=o&&(c|=f(b,u-1)<<4),c}a.prototype._parseHex=function(o,u,c){this.length=Math.ceil((o.length-u)/6),this.words=new Array(this.length);for(var h=0;h=u;h-=2)E=d(o,u,h)<=18?(g-=18,x+=1,this.words[x]|=E>>>26):g+=8;else{var v=o.length-u;for(h=v%2===0?u+1:u;h=18?(g-=18,x+=1,this.words[x]|=E>>>26):g+=8}this.strip()};function p(b,o,u,c){for(var h=0,g=Math.min(b.length,u),x=o;x=49?h+=E-49+10:E>=17?h+=E-17+10:h+=E}return h}a.prototype._parseBase=function(o,u,c){this.words=[0],this.length=1;for(var h=0,g=1;g<=67108863;g*=u)h++;h--,g=g/u|0;for(var x=o.length-c,E=x%h,v=Math.min(x,x-E)+c,l=0,m=c;m1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},a.prototype.inspect=function(){return(this.red?""};var y=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],w=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],_=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(o,u){o=o||10,u=u|0||1;var c;if(o===16||o==="hex"){c="";for(var h=0,g=0,x=0;x>>24-h&16777215,g!==0||x!==this.length-1?c=y[6-v.length]+v+c:c=v+c,h+=2,h>=26&&(h-=26,x--)}for(g!==0&&(c=g.toString(16)+c);c.length%u!==0;)c="0"+c;return this.negative!==0&&(c="-"+c),c}if(o===(o|0)&&o>=2&&o<=36){var l=w[o],m=_[o];c="";var P=this.clone();for(P.negative=0;!P.isZero();){var N=P.modn(m).toString(o);P=P.idivn(m),P.isZero()?c=N+c:c=y[l-N.length]+N+c}for(this.isZero()&&(c="0"+c);c.length%u!==0;)c="0"+c;return this.negative!==0&&(c="-"+c),c}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var o=this.words[0];return this.length===2?o+=this.words[1]*67108864:this.length===3&&this.words[2]===1?o+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-o:o},a.prototype.toJSON=function(){return this.toString(16)},a.prototype.toBuffer=function(o,u){return n(typeof s<"u"),this.toArrayLike(s,o,u)},a.prototype.toArray=function(o,u){return this.toArrayLike(Array,o,u)},a.prototype.toArrayLike=function(o,u,c){var h=this.byteLength(),g=c||Math.max(1,h);n(h<=g,"byte array longer than desired length"),n(g>0,"Requested array length <= 0"),this.strip();var x=u==="le",E=new o(g),v,l,m=this.clone();if(x){for(l=0;!m.isZero();l++)v=m.andln(255),m.iushrn(8),E[l]=v;for(;l=4096&&(c+=13,u>>>=13),u>=64&&(c+=7,u>>>=7),u>=8&&(c+=4,u>>>=4),u>=2&&(c+=2,u>>>=2),c+u},a.prototype._zeroBits=function(o){if(o===0)return 26;var u=o,c=0;return u&8191||(c+=13,u>>>=13),u&127||(c+=7,u>>>=7),u&15||(c+=4,u>>>=4),u&3||(c+=2,u>>>=2),u&1||c++,c},a.prototype.bitLength=function(){var o=this.words[this.length-1],u=this._countBits(o);return(this.length-1)*26+u};function S(b){for(var o=new Array(b.bitLength()),u=0;u>>h}return o}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var o=0,u=0;uo.length?this.clone().ior(o):o.clone().ior(this)},a.prototype.uor=function(o){return this.length>o.length?this.clone().iuor(o):o.clone().iuor(this)},a.prototype.iuand=function(o){var u;this.length>o.length?u=o:u=this;for(var c=0;co.length?this.clone().iand(o):o.clone().iand(this)},a.prototype.uand=function(o){return this.length>o.length?this.clone().iuand(o):o.clone().iuand(this)},a.prototype.iuxor=function(o){var u,c;this.length>o.length?(u=this,c=o):(u=o,c=this);for(var h=0;ho.length?this.clone().ixor(o):o.clone().ixor(this)},a.prototype.uxor=function(o){return this.length>o.length?this.clone().iuxor(o):o.clone().iuxor(this)},a.prototype.inotn=function(o){n(typeof o=="number"&&o>=0);var u=Math.ceil(o/26)|0,c=o%26;this._expand(u),c>0&&u--;for(var h=0;h0&&(this.words[h]=~this.words[h]&67108863>>26-c),this.strip()},a.prototype.notn=function(o){return this.clone().inotn(o)},a.prototype.setn=function(o,u){n(typeof o=="number"&&o>=0);var c=o/26|0,h=o%26;return this._expand(c+1),u?this.words[c]=this.words[c]|1<o.length?(c=this,h=o):(c=o,h=this);for(var g=0,x=0;x>>26;for(;g!==0&&x>>26;if(this.length=c.length,g!==0)this.words[this.length]=g,this.length++;else if(c!==this)for(;xo.length?this.clone().iadd(o):o.clone().iadd(this)},a.prototype.isub=function(o){if(o.negative!==0){o.negative=0;var u=this.iadd(o);return o.negative=1,u._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(o),this.negative=1,this._normSign();var c=this.cmp(o);if(c===0)return this.negative=0,this.length=1,this.words[0]=0,this;var h,g;c>0?(h=this,g=o):(h=o,g=this);for(var x=0,E=0;E>26,this.words[E]=u&67108863;for(;x!==0&&E>26,this.words[E]=u&67108863;if(x===0&&E>>26,P=v&67108863,N=Math.min(l,o.length-1),F=Math.max(0,l-b.length+1);F<=N;F++){var ee=l-F|0;h=b.words[ee]|0,g=o.words[F]|0,x=h*g+P,m+=x/67108864|0,P=x&67108863}u.words[l]=P|0,v=m|0}return v!==0?u.words[l]=v|0:u.length--,u.strip()}var C=function(o,u,c){var h=o.words,g=u.words,x=c.words,E=0,v,l,m,P=h[0]|0,N=P&8191,F=P>>>13,ee=h[1]|0,q=ee&8191,ae=ee>>>13,pe=h[2]|0,we=pe&8191,Se=pe>>>13,he=h[3]|0,re=he&8191,_e=he>>>13,W=h[4]|0,ve=W&8191,Z=W>>>13,ne=h[5]|0,K=ne&8191,le=ne>>>13,xe=h[6]|0,ce=xe&8191,de=xe>>>13,Ae=h[7]|0,ye=Ae&8191,be=Ae>>>13,tt=h[8]|0,Oe=tt&8191,$e=tt>>>13,Et=h[9]|0,ze=Et&8191,He=Et>>>13,Fe=g[0]|0,Te=Fe&8191,Pe=Fe>>>13,pt=g[1]|0,De=pt&8191,je=pt>>>13,bt=g[2]|0,Le=bt&8191,Ge=bt>>>13,Ct=g[3]|0,Be=Ct&8191,Ye=Ct>>>13,Pt=g[4]|0,Ue=Pt&8191,et=Pt>>>13,Vt=g[5]|0,Xe=Vt&8191,ot=Vt>>>13,Kt=g[6]|0,Ve=Kt&8191,Je=Kt>>>13,It=g[7]|0,We=It&8191,it=It>>>13,jt=g[8]|0,Qe=jt&8191,lt=jt>>>13,Xt=g[9]|0,qe=Xt&8191,at=Xt>>>13;c.negative=o.negative^u.negative,c.length=19,v=Math.imul(N,Te),l=Math.imul(N,Pe),l=l+Math.imul(F,Te)|0,m=Math.imul(F,Pe);var Bt=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,v=Math.imul(q,Te),l=Math.imul(q,Pe),l=l+Math.imul(ae,Te)|0,m=Math.imul(ae,Pe),v=v+Math.imul(N,De)|0,l=l+Math.imul(N,je)|0,l=l+Math.imul(F,De)|0,m=m+Math.imul(F,je)|0;var Ot=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,v=Math.imul(we,Te),l=Math.imul(we,Pe),l=l+Math.imul(Se,Te)|0,m=Math.imul(Se,Pe),v=v+Math.imul(q,De)|0,l=l+Math.imul(q,je)|0,l=l+Math.imul(ae,De)|0,m=m+Math.imul(ae,je)|0,v=v+Math.imul(N,Le)|0,l=l+Math.imul(N,Ge)|0,l=l+Math.imul(F,Le)|0,m=m+Math.imul(F,Ge)|0;var sr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(sr>>>26)|0,sr&=67108863,v=Math.imul(re,Te),l=Math.imul(re,Pe),l=l+Math.imul(_e,Te)|0,m=Math.imul(_e,Pe),v=v+Math.imul(we,De)|0,l=l+Math.imul(we,je)|0,l=l+Math.imul(Se,De)|0,m=m+Math.imul(Se,je)|0,v=v+Math.imul(q,Le)|0,l=l+Math.imul(q,Ge)|0,l=l+Math.imul(ae,Le)|0,m=m+Math.imul(ae,Ge)|0,v=v+Math.imul(N,Be)|0,l=l+Math.imul(N,Ye)|0,l=l+Math.imul(F,Be)|0,m=m+Math.imul(F,Ye)|0;var Ht=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,v=Math.imul(ve,Te),l=Math.imul(ve,Pe),l=l+Math.imul(Z,Te)|0,m=Math.imul(Z,Pe),v=v+Math.imul(re,De)|0,l=l+Math.imul(re,je)|0,l=l+Math.imul(_e,De)|0,m=m+Math.imul(_e,je)|0,v=v+Math.imul(we,Le)|0,l=l+Math.imul(we,Ge)|0,l=l+Math.imul(Se,Le)|0,m=m+Math.imul(Se,Ge)|0,v=v+Math.imul(q,Be)|0,l=l+Math.imul(q,Ye)|0,l=l+Math.imul(ae,Be)|0,m=m+Math.imul(ae,Ye)|0,v=v+Math.imul(N,Ue)|0,l=l+Math.imul(N,et)|0,l=l+Math.imul(F,Ue)|0,m=m+Math.imul(F,et)|0;var hr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(hr>>>26)|0,hr&=67108863,v=Math.imul(K,Te),l=Math.imul(K,Pe),l=l+Math.imul(le,Te)|0,m=Math.imul(le,Pe),v=v+Math.imul(ve,De)|0,l=l+Math.imul(ve,je)|0,l=l+Math.imul(Z,De)|0,m=m+Math.imul(Z,je)|0,v=v+Math.imul(re,Le)|0,l=l+Math.imul(re,Ge)|0,l=l+Math.imul(_e,Le)|0,m=m+Math.imul(_e,Ge)|0,v=v+Math.imul(we,Be)|0,l=l+Math.imul(we,Ye)|0,l=l+Math.imul(Se,Be)|0,m=m+Math.imul(Se,Ye)|0,v=v+Math.imul(q,Ue)|0,l=l+Math.imul(q,et)|0,l=l+Math.imul(ae,Ue)|0,m=m+Math.imul(ae,et)|0,v=v+Math.imul(N,Xe)|0,l=l+Math.imul(N,ot)|0,l=l+Math.imul(F,Xe)|0,m=m+Math.imul(F,ot)|0;var pr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(pr>>>26)|0,pr&=67108863,v=Math.imul(ce,Te),l=Math.imul(ce,Pe),l=l+Math.imul(de,Te)|0,m=Math.imul(de,Pe),v=v+Math.imul(K,De)|0,l=l+Math.imul(K,je)|0,l=l+Math.imul(le,De)|0,m=m+Math.imul(le,je)|0,v=v+Math.imul(ve,Le)|0,l=l+Math.imul(ve,Ge)|0,l=l+Math.imul(Z,Le)|0,m=m+Math.imul(Z,Ge)|0,v=v+Math.imul(re,Be)|0,l=l+Math.imul(re,Ye)|0,l=l+Math.imul(_e,Be)|0,m=m+Math.imul(_e,Ye)|0,v=v+Math.imul(we,Ue)|0,l=l+Math.imul(we,et)|0,l=l+Math.imul(Se,Ue)|0,m=m+Math.imul(Se,et)|0,v=v+Math.imul(q,Xe)|0,l=l+Math.imul(q,ot)|0,l=l+Math.imul(ae,Xe)|0,m=m+Math.imul(ae,ot)|0,v=v+Math.imul(N,Ve)|0,l=l+Math.imul(N,Je)|0,l=l+Math.imul(F,Ve)|0,m=m+Math.imul(F,Je)|0;var _r=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(_r>>>26)|0,_r&=67108863,v=Math.imul(ye,Te),l=Math.imul(ye,Pe),l=l+Math.imul(be,Te)|0,m=Math.imul(be,Pe),v=v+Math.imul(ce,De)|0,l=l+Math.imul(ce,je)|0,l=l+Math.imul(de,De)|0,m=m+Math.imul(de,je)|0,v=v+Math.imul(K,Le)|0,l=l+Math.imul(K,Ge)|0,l=l+Math.imul(le,Le)|0,m=m+Math.imul(le,Ge)|0,v=v+Math.imul(ve,Be)|0,l=l+Math.imul(ve,Ye)|0,l=l+Math.imul(Z,Be)|0,m=m+Math.imul(Z,Ye)|0,v=v+Math.imul(re,Ue)|0,l=l+Math.imul(re,et)|0,l=l+Math.imul(_e,Ue)|0,m=m+Math.imul(_e,et)|0,v=v+Math.imul(we,Xe)|0,l=l+Math.imul(we,ot)|0,l=l+Math.imul(Se,Xe)|0,m=m+Math.imul(Se,ot)|0,v=v+Math.imul(q,Ve)|0,l=l+Math.imul(q,Je)|0,l=l+Math.imul(ae,Ve)|0,m=m+Math.imul(ae,Je)|0,v=v+Math.imul(N,We)|0,l=l+Math.imul(N,it)|0,l=l+Math.imul(F,We)|0,m=m+Math.imul(F,it)|0;var Sr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,v=Math.imul(Oe,Te),l=Math.imul(Oe,Pe),l=l+Math.imul($e,Te)|0,m=Math.imul($e,Pe),v=v+Math.imul(ye,De)|0,l=l+Math.imul(ye,je)|0,l=l+Math.imul(be,De)|0,m=m+Math.imul(be,je)|0,v=v+Math.imul(ce,Le)|0,l=l+Math.imul(ce,Ge)|0,l=l+Math.imul(de,Le)|0,m=m+Math.imul(de,Ge)|0,v=v+Math.imul(K,Be)|0,l=l+Math.imul(K,Ye)|0,l=l+Math.imul(le,Be)|0,m=m+Math.imul(le,Ye)|0,v=v+Math.imul(ve,Ue)|0,l=l+Math.imul(ve,et)|0,l=l+Math.imul(Z,Ue)|0,m=m+Math.imul(Z,et)|0,v=v+Math.imul(re,Xe)|0,l=l+Math.imul(re,ot)|0,l=l+Math.imul(_e,Xe)|0,m=m+Math.imul(_e,ot)|0,v=v+Math.imul(we,Ve)|0,l=l+Math.imul(we,Je)|0,l=l+Math.imul(Se,Ve)|0,m=m+Math.imul(Se,Je)|0,v=v+Math.imul(q,We)|0,l=l+Math.imul(q,it)|0,l=l+Math.imul(ae,We)|0,m=m+Math.imul(ae,it)|0,v=v+Math.imul(N,Qe)|0,l=l+Math.imul(N,lt)|0,l=l+Math.imul(F,Qe)|0,m=m+Math.imul(F,lt)|0;var cr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(cr>>>26)|0,cr&=67108863,v=Math.imul(ze,Te),l=Math.imul(ze,Pe),l=l+Math.imul(He,Te)|0,m=Math.imul(He,Pe),v=v+Math.imul(Oe,De)|0,l=l+Math.imul(Oe,je)|0,l=l+Math.imul($e,De)|0,m=m+Math.imul($e,je)|0,v=v+Math.imul(ye,Le)|0,l=l+Math.imul(ye,Ge)|0,l=l+Math.imul(be,Le)|0,m=m+Math.imul(be,Ge)|0,v=v+Math.imul(ce,Be)|0,l=l+Math.imul(ce,Ye)|0,l=l+Math.imul(de,Be)|0,m=m+Math.imul(de,Ye)|0,v=v+Math.imul(K,Ue)|0,l=l+Math.imul(K,et)|0,l=l+Math.imul(le,Ue)|0,m=m+Math.imul(le,et)|0,v=v+Math.imul(ve,Xe)|0,l=l+Math.imul(ve,ot)|0,l=l+Math.imul(Z,Xe)|0,m=m+Math.imul(Z,ot)|0,v=v+Math.imul(re,Ve)|0,l=l+Math.imul(re,Je)|0,l=l+Math.imul(_e,Ve)|0,m=m+Math.imul(_e,Je)|0,v=v+Math.imul(we,We)|0,l=l+Math.imul(we,it)|0,l=l+Math.imul(Se,We)|0,m=m+Math.imul(Se,it)|0,v=v+Math.imul(q,Qe)|0,l=l+Math.imul(q,lt)|0,l=l+Math.imul(ae,Qe)|0,m=m+Math.imul(ae,lt)|0,v=v+Math.imul(N,qe)|0,l=l+Math.imul(N,at)|0,l=l+Math.imul(F,qe)|0,m=m+Math.imul(F,at)|0;var qt=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(qt>>>26)|0,qt&=67108863,v=Math.imul(ze,De),l=Math.imul(ze,je),l=l+Math.imul(He,De)|0,m=Math.imul(He,je),v=v+Math.imul(Oe,Le)|0,l=l+Math.imul(Oe,Ge)|0,l=l+Math.imul($e,Le)|0,m=m+Math.imul($e,Ge)|0,v=v+Math.imul(ye,Be)|0,l=l+Math.imul(ye,Ye)|0,l=l+Math.imul(be,Be)|0,m=m+Math.imul(be,Ye)|0,v=v+Math.imul(ce,Ue)|0,l=l+Math.imul(ce,et)|0,l=l+Math.imul(de,Ue)|0,m=m+Math.imul(de,et)|0,v=v+Math.imul(K,Xe)|0,l=l+Math.imul(K,ot)|0,l=l+Math.imul(le,Xe)|0,m=m+Math.imul(le,ot)|0,v=v+Math.imul(ve,Ve)|0,l=l+Math.imul(ve,Je)|0,l=l+Math.imul(Z,Ve)|0,m=m+Math.imul(Z,Je)|0,v=v+Math.imul(re,We)|0,l=l+Math.imul(re,it)|0,l=l+Math.imul(_e,We)|0,m=m+Math.imul(_e,it)|0,v=v+Math.imul(we,Qe)|0,l=l+Math.imul(we,lt)|0,l=l+Math.imul(Se,Qe)|0,m=m+Math.imul(Se,lt)|0,v=v+Math.imul(q,qe)|0,l=l+Math.imul(q,at)|0,l=l+Math.imul(ae,qe)|0,m=m+Math.imul(ae,at)|0;var lr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(lr>>>26)|0,lr&=67108863,v=Math.imul(ze,Le),l=Math.imul(ze,Ge),l=l+Math.imul(He,Le)|0,m=Math.imul(He,Ge),v=v+Math.imul(Oe,Be)|0,l=l+Math.imul(Oe,Ye)|0,l=l+Math.imul($e,Be)|0,m=m+Math.imul($e,Ye)|0,v=v+Math.imul(ye,Ue)|0,l=l+Math.imul(ye,et)|0,l=l+Math.imul(be,Ue)|0,m=m+Math.imul(be,et)|0,v=v+Math.imul(ce,Xe)|0,l=l+Math.imul(ce,ot)|0,l=l+Math.imul(de,Xe)|0,m=m+Math.imul(de,ot)|0,v=v+Math.imul(K,Ve)|0,l=l+Math.imul(K,Je)|0,l=l+Math.imul(le,Ve)|0,m=m+Math.imul(le,Je)|0,v=v+Math.imul(ve,We)|0,l=l+Math.imul(ve,it)|0,l=l+Math.imul(Z,We)|0,m=m+Math.imul(Z,it)|0,v=v+Math.imul(re,Qe)|0,l=l+Math.imul(re,lt)|0,l=l+Math.imul(_e,Qe)|0,m=m+Math.imul(_e,lt)|0,v=v+Math.imul(we,qe)|0,l=l+Math.imul(we,at)|0,l=l+Math.imul(Se,qe)|0,m=m+Math.imul(Se,at)|0;var br=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(br>>>26)|0,br&=67108863,v=Math.imul(ze,Be),l=Math.imul(ze,Ye),l=l+Math.imul(He,Be)|0,m=Math.imul(He,Ye),v=v+Math.imul(Oe,Ue)|0,l=l+Math.imul(Oe,et)|0,l=l+Math.imul($e,Ue)|0,m=m+Math.imul($e,et)|0,v=v+Math.imul(ye,Xe)|0,l=l+Math.imul(ye,ot)|0,l=l+Math.imul(be,Xe)|0,m=m+Math.imul(be,ot)|0,v=v+Math.imul(ce,Ve)|0,l=l+Math.imul(ce,Je)|0,l=l+Math.imul(de,Ve)|0,m=m+Math.imul(de,Je)|0,v=v+Math.imul(K,We)|0,l=l+Math.imul(K,it)|0,l=l+Math.imul(le,We)|0,m=m+Math.imul(le,it)|0,v=v+Math.imul(ve,Qe)|0,l=l+Math.imul(ve,lt)|0,l=l+Math.imul(Z,Qe)|0,m=m+Math.imul(Z,lt)|0,v=v+Math.imul(re,qe)|0,l=l+Math.imul(re,at)|0,l=l+Math.imul(_e,qe)|0,m=m+Math.imul(_e,at)|0;var Mr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,v=Math.imul(ze,Ue),l=Math.imul(ze,et),l=l+Math.imul(He,Ue)|0,m=Math.imul(He,et),v=v+Math.imul(Oe,Xe)|0,l=l+Math.imul(Oe,ot)|0,l=l+Math.imul($e,Xe)|0,m=m+Math.imul($e,ot)|0,v=v+Math.imul(ye,Ve)|0,l=l+Math.imul(ye,Je)|0,l=l+Math.imul(be,Ve)|0,m=m+Math.imul(be,Je)|0,v=v+Math.imul(ce,We)|0,l=l+Math.imul(ce,it)|0,l=l+Math.imul(de,We)|0,m=m+Math.imul(de,it)|0,v=v+Math.imul(K,Qe)|0,l=l+Math.imul(K,lt)|0,l=l+Math.imul(le,Qe)|0,m=m+Math.imul(le,lt)|0,v=v+Math.imul(ve,qe)|0,l=l+Math.imul(ve,at)|0,l=l+Math.imul(Z,qe)|0,m=m+Math.imul(Z,at)|0;var Er=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Er>>>26)|0,Er&=67108863,v=Math.imul(ze,Xe),l=Math.imul(ze,ot),l=l+Math.imul(He,Xe)|0,m=Math.imul(He,ot),v=v+Math.imul(Oe,Ve)|0,l=l+Math.imul(Oe,Je)|0,l=l+Math.imul($e,Ve)|0,m=m+Math.imul($e,Je)|0,v=v+Math.imul(ye,We)|0,l=l+Math.imul(ye,it)|0,l=l+Math.imul(be,We)|0,m=m+Math.imul(be,it)|0,v=v+Math.imul(ce,Qe)|0,l=l+Math.imul(ce,lt)|0,l=l+Math.imul(de,Qe)|0,m=m+Math.imul(de,lt)|0,v=v+Math.imul(K,qe)|0,l=l+Math.imul(K,at)|0,l=l+Math.imul(le,qe)|0,m=m+Math.imul(le,at)|0;var xr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(xr>>>26)|0,xr&=67108863,v=Math.imul(ze,Ve),l=Math.imul(ze,Je),l=l+Math.imul(He,Ve)|0,m=Math.imul(He,Je),v=v+Math.imul(Oe,We)|0,l=l+Math.imul(Oe,it)|0,l=l+Math.imul($e,We)|0,m=m+Math.imul($e,it)|0,v=v+Math.imul(ye,Qe)|0,l=l+Math.imul(ye,lt)|0,l=l+Math.imul(be,Qe)|0,m=m+Math.imul(be,lt)|0,v=v+Math.imul(ce,qe)|0,l=l+Math.imul(ce,at)|0,l=l+Math.imul(de,qe)|0,m=m+Math.imul(de,at)|0;var Pr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Pr>>>26)|0,Pr&=67108863,v=Math.imul(ze,We),l=Math.imul(ze,it),l=l+Math.imul(He,We)|0,m=Math.imul(He,it),v=v+Math.imul(Oe,Qe)|0,l=l+Math.imul(Oe,lt)|0,l=l+Math.imul($e,Qe)|0,m=m+Math.imul($e,lt)|0,v=v+Math.imul(ye,qe)|0,l=l+Math.imul(ye,at)|0,l=l+Math.imul(be,qe)|0,m=m+Math.imul(be,at)|0;var Or=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Or>>>26)|0,Or&=67108863,v=Math.imul(ze,Qe),l=Math.imul(ze,lt),l=l+Math.imul(He,Qe)|0,m=Math.imul(He,lt),v=v+Math.imul(Oe,qe)|0,l=l+Math.imul(Oe,at)|0,l=l+Math.imul($e,qe)|0,m=m+Math.imul($e,at)|0;var kr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(kr>>>26)|0,kr&=67108863,v=Math.imul(ze,qe),l=Math.imul(ze,at),l=l+Math.imul(He,qe)|0,m=Math.imul(He,at);var rr=(E+v|0)+((l&8191)<<13)|0;return E=(m+(l>>>13)|0)+(rr>>>26)|0,rr&=67108863,x[0]=Bt,x[1]=Ot,x[2]=sr,x[3]=Ht,x[4]=hr,x[5]=pr,x[6]=_r,x[7]=Sr,x[8]=cr,x[9]=qt,x[10]=lr,x[11]=br,x[12]=Mr,x[13]=Er,x[14]=xr,x[15]=Pr,x[16]=Or,x[17]=kr,x[18]=rr,E!==0&&(x[19]=E,c.length++),c};Math.imul||(C=M);function O(b,o,u){u.negative=o.negative^b.negative,u.length=b.length+o.length;for(var c=0,h=0,g=0;g>>26)|0,h+=x>>>26,x&=67108863}u.words[g]=E,c=x,x=h}return c!==0?u.words[g]=c:u.length--,u.strip()}function T(b,o,u){var c=new k;return c.mulp(b,o,u)}a.prototype.mulTo=function(o,u){var c,h=this.length+o.length;return this.length===10&&o.length===10?c=C(this,o,u):h<63?c=M(this,o,u):h<1024?c=O(this,o,u):c=T(this,o,u),c};function k(b,o){this.x=b,this.y=o}k.prototype.makeRBT=function(o){for(var u=new Array(o),c=a.prototype._countBits(o)-1,h=0;h>=1;return h},k.prototype.permute=function(o,u,c,h,g,x){for(var E=0;E>>1)g++;return 1<>>13,c[2*x+1]=g&8191,g=g>>>13;for(x=2*u;x>=26,u+=h/67108864|0,u+=g>>>26,this.words[c]=g&67108863}return u!==0&&(this.words[c]=u,this.length++),this},a.prototype.muln=function(o){return this.clone().imuln(o)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(o){var u=S(o);if(u.length===0)return new a(1);for(var c=this,h=0;h=0);var u=o%26,c=(o-u)/26,h=67108863>>>26-u<<26-u,g;if(u!==0){var x=0;for(g=0;g>>26-u}x&&(this.words[g]=x,this.length++)}if(c!==0){for(g=this.length-1;g>=0;g--)this.words[g+c]=this.words[g];for(g=0;g=0);var h;u?h=(u-u%26)/26:h=0;var g=o%26,x=Math.min((o-g)/26,this.length),E=67108863^67108863>>>g<x)for(this.length-=x,l=0;l=0&&(m!==0||l>=h);l--){var P=this.words[l]|0;this.words[l]=m<<26-g|P>>>g,m=P&E}return v&&m!==0&&(v.words[v.length++]=m),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},a.prototype.ishrn=function(o,u,c){return n(this.negative===0),this.iushrn(o,u,c)},a.prototype.shln=function(o){return this.clone().ishln(o)},a.prototype.ushln=function(o){return this.clone().iushln(o)},a.prototype.shrn=function(o){return this.clone().ishrn(o)},a.prototype.ushrn=function(o){return this.clone().iushrn(o)},a.prototype.testn=function(o){n(typeof o=="number"&&o>=0);var u=o%26,c=(o-u)/26,h=1<=0);var u=o%26,c=(o-u)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=c)return this;if(u!==0&&c++,this.length=Math.min(c,this.length),u!==0){var h=67108863^67108863>>>u<=67108864;u++)this.words[u]-=67108864,u===this.length-1?this.words[u+1]=1:this.words[u+1]++;return this.length=Math.max(this.length,u+1),this},a.prototype.isubn=function(o){if(n(typeof o=="number"),n(o<67108864),o<0)return this.iaddn(-o);if(this.negative!==0)return this.negative=0,this.iaddn(o),this.negative=1,this;if(this.words[0]-=o,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var u=0;u>26)-(v/67108864|0),this.words[g+c]=x&67108863}for(;g>26,this.words[g+c]=x&67108863;if(E===0)return this.strip();for(n(E===-1),E=0,g=0;g>26,this.words[g]=x&67108863;return this.negative=1,this.strip()},a.prototype._wordDiv=function(o,u){var c=this.length-o.length,h=this.clone(),g=o,x=g.words[g.length-1]|0,E=this._countBits(x);c=26-E,c!==0&&(g=g.ushln(c),h.iushln(c),x=g.words[g.length-1]|0);var v=h.length-g.length,l;if(u!=="mod"){l=new a(null),l.length=v+1,l.words=new Array(l.length);for(var m=0;m=0;N--){var F=(h.words[g.length+N]|0)*67108864+(h.words[g.length+N-1]|0);for(F=Math.min(F/x|0,67108863),h._ishlnsubmul(g,F,N);h.negative!==0;)F--,h.negative=0,h._ishlnsubmul(g,1,N),h.isZero()||(h.negative^=1);l&&(l.words[N]=F)}return l&&l.strip(),h.strip(),u!=="div"&&c!==0&&h.iushrn(c),{div:l||null,mod:h}},a.prototype.divmod=function(o,u,c){if(n(!o.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var h,g,x;return this.negative!==0&&o.negative===0?(x=this.neg().divmod(o,u),u!=="mod"&&(h=x.div.neg()),u!=="div"&&(g=x.mod.neg(),c&&g.negative!==0&&g.iadd(o)),{div:h,mod:g}):this.negative===0&&o.negative!==0?(x=this.divmod(o.neg(),u),u!=="mod"&&(h=x.div.neg()),{div:h,mod:x.mod}):this.negative&o.negative?(x=this.neg().divmod(o.neg(),u),u!=="div"&&(g=x.mod.neg(),c&&g.negative!==0&&g.isub(o)),{div:x.div,mod:g}):o.length>this.length||this.cmp(o)<0?{div:new a(0),mod:this}:o.length===1?u==="div"?{div:this.divn(o.words[0]),mod:null}:u==="mod"?{div:null,mod:new a(this.modn(o.words[0]))}:{div:this.divn(o.words[0]),mod:new a(this.modn(o.words[0]))}:this._wordDiv(o,u)},a.prototype.div=function(o){return this.divmod(o,"div",!1).div},a.prototype.mod=function(o){return this.divmod(o,"mod",!1).mod},a.prototype.umod=function(o){return this.divmod(o,"mod",!0).mod},a.prototype.divRound=function(o){var u=this.divmod(o);if(u.mod.isZero())return u.div;var c=u.div.negative!==0?u.mod.isub(o):u.mod,h=o.ushrn(1),g=o.andln(1),x=c.cmp(h);return x<0||g===1&&x===0?u.div:u.div.negative!==0?u.div.isubn(1):u.div.iaddn(1)},a.prototype.modn=function(o){n(o<=67108863);for(var u=(1<<26)%o,c=0,h=this.length-1;h>=0;h--)c=(u*c+(this.words[h]|0))%o;return c},a.prototype.idivn=function(o){n(o<=67108863);for(var u=0,c=this.length-1;c>=0;c--){var h=(this.words[c]|0)+u*67108864;this.words[c]=h/o|0,u=h%o}return this.strip()},a.prototype.divn=function(o){return this.clone().idivn(o)},a.prototype.egcd=function(o){n(o.negative===0),n(!o.isZero());var u=this,c=o.clone();u.negative!==0?u=u.umod(o):u=u.clone();for(var h=new a(1),g=new a(0),x=new a(0),E=new a(1),v=0;u.isEven()&&c.isEven();)u.iushrn(1),c.iushrn(1),++v;for(var l=c.clone(),m=u.clone();!u.isZero();){for(var P=0,N=1;!(u.words[0]&N)&&P<26;++P,N<<=1);if(P>0)for(u.iushrn(P);P-- >0;)(h.isOdd()||g.isOdd())&&(h.iadd(l),g.isub(m)),h.iushrn(1),g.iushrn(1);for(var F=0,ee=1;!(c.words[0]&ee)&&F<26;++F,ee<<=1);if(F>0)for(c.iushrn(F);F-- >0;)(x.isOdd()||E.isOdd())&&(x.iadd(l),E.isub(m)),x.iushrn(1),E.iushrn(1);u.cmp(c)>=0?(u.isub(c),h.isub(x),g.isub(E)):(c.isub(u),x.isub(h),E.isub(g))}return{a:x,b:E,gcd:c.iushln(v)}},a.prototype._invmp=function(o){n(o.negative===0),n(!o.isZero());var u=this,c=o.clone();u.negative!==0?u=u.umod(o):u=u.clone();for(var h=new a(1),g=new a(0),x=c.clone();u.cmpn(1)>0&&c.cmpn(1)>0;){for(var E=0,v=1;!(u.words[0]&v)&&E<26;++E,v<<=1);if(E>0)for(u.iushrn(E);E-- >0;)h.isOdd()&&h.iadd(x),h.iushrn(1);for(var l=0,m=1;!(c.words[0]&m)&&l<26;++l,m<<=1);if(l>0)for(c.iushrn(l);l-- >0;)g.isOdd()&&g.iadd(x),g.iushrn(1);u.cmp(c)>=0?(u.isub(c),h.isub(g)):(c.isub(u),g.isub(h))}var P;return u.cmpn(1)===0?P=h:P=g,P.cmpn(0)<0&&P.iadd(o),P},a.prototype.gcd=function(o){if(this.isZero())return o.abs();if(o.isZero())return this.abs();var u=this.clone(),c=o.clone();u.negative=0,c.negative=0;for(var h=0;u.isEven()&&c.isEven();h++)u.iushrn(1),c.iushrn(1);do{for(;u.isEven();)u.iushrn(1);for(;c.isEven();)c.iushrn(1);var g=u.cmp(c);if(g<0){var x=u;u=c,c=x}else if(g===0||c.cmpn(1)===0)break;u.isub(c)}while(!0);return c.iushln(h)},a.prototype.invm=function(o){return this.egcd(o).a.umod(o)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(o){return this.words[0]&o},a.prototype.bincn=function(o){n(typeof o=="number");var u=o%26,c=(o-u)/26,h=1<>>26,E&=67108863,this.words[x]=E}return g!==0&&(this.words[x]=g,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(o){var u=o<0;if(this.negative!==0&&!u)return-1;if(this.negative===0&&u)return 1;this.strip();var c;if(this.length>1)c=1;else{u&&(o=-o),n(o<=67108863,"Number is too big");var h=this.words[0]|0;c=h===o?0:ho.length)return 1;if(this.length=0;c--){var h=this.words[c]|0,g=o.words[c]|0;if(h!==g){hg&&(u=1);break}}return u},a.prototype.gtn=function(o){return this.cmpn(o)===1},a.prototype.gt=function(o){return this.cmp(o)===1},a.prototype.gten=function(o){return this.cmpn(o)>=0},a.prototype.gte=function(o){return this.cmp(o)>=0},a.prototype.ltn=function(o){return this.cmpn(o)===-1},a.prototype.lt=function(o){return this.cmp(o)===-1},a.prototype.lten=function(o){return this.cmpn(o)<=0},a.prototype.lte=function(o){return this.cmp(o)<=0},a.prototype.eqn=function(o){return this.cmpn(o)===0},a.prototype.eq=function(o){return this.cmp(o)===0},a.red=function(o){return new z(o)},a.prototype.toRed=function(o){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),o.convertTo(this)._forceRed(o)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(o){return this.red=o,this},a.prototype.forceRed=function(o){return n(!this.red,"Already a number in reduction context"),this._forceRed(o)},a.prototype.redAdd=function(o){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,o)},a.prototype.redIAdd=function(o){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,o)},a.prototype.redSub=function(o){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,o)},a.prototype.redISub=function(o){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,o)},a.prototype.redShl=function(o){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,o)},a.prototype.redMul=function(o){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,o),this.red.mul(this,o)},a.prototype.redIMul=function(o){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,o),this.red.imul(this,o)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(o){return n(this.red&&!o.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,o)};var R={k256:null,p224:null,p192:null,p25519:null};function $(b,o){this.name=b,this.p=new a(o,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}$.prototype._tmp=function(){var o=new a(null);return o.words=new Array(Math.ceil(this.n/13)),o},$.prototype.ireduce=function(o){var u=o,c;do this.split(u,this.tmp),u=this.imulK(u),u=u.iadd(this.tmp),c=u.bitLength();while(c>this.n);var h=c0?u.isub(this.p):u.strip!==void 0?u.strip():u._strip(),u},$.prototype.split=function(o,u){o.iushrn(this.n,0,u)},$.prototype.imulK=function(o){return o.imul(this.k)};function L(){$.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}i(L,$),L.prototype.split=function(o,u){for(var c=4194303,h=Math.min(o.length,9),g=0;g>>22,x=E}x>>>=22,o.words[g-10]=x,x===0&&o.length>10?o.length-=10:o.length-=9},L.prototype.imulK=function(o){o.words[o.length]=0,o.words[o.length+1]=0,o.length+=2;for(var u=0,c=0;c>>=26,o.words[c]=g,u=h}return u!==0&&(o.words[o.length++]=u),o},a._prime=function(o){if(R[o])return R[o];var u;if(o==="k256")u=new L;else if(o==="p224")u=new j;else if(o==="p192")u=new A;else if(o==="p25519")u=new V;else throw new Error("Unknown prime "+o);return R[o]=u,u};function z(b){if(typeof b=="string"){var o=a._prime(b);this.m=o.p,this.prime=o}else n(b.gtn(1),"modulus must be greater than 1"),this.m=b,this.prime=null}z.prototype._verify1=function(o){n(o.negative===0,"red works only with positives"),n(o.red,"red works only with red numbers")},z.prototype._verify2=function(o,u){n((o.negative|u.negative)===0,"red works only with positives"),n(o.red&&o.red===u.red,"red works only with red numbers")},z.prototype.imod=function(o){return this.prime?this.prime.ireduce(o)._forceRed(this):o.umod(this.m)._forceRed(this)},z.prototype.neg=function(o){return o.isZero()?o.clone():this.m.sub(o)._forceRed(this)},z.prototype.add=function(o,u){this._verify2(o,u);var c=o.add(u);return c.cmp(this.m)>=0&&c.isub(this.m),c._forceRed(this)},z.prototype.iadd=function(o,u){this._verify2(o,u);var c=o.iadd(u);return c.cmp(this.m)>=0&&c.isub(this.m),c},z.prototype.sub=function(o,u){this._verify2(o,u);var c=o.sub(u);return c.cmpn(0)<0&&c.iadd(this.m),c._forceRed(this)},z.prototype.isub=function(o,u){this._verify2(o,u);var c=o.isub(u);return c.cmpn(0)<0&&c.iadd(this.m),c},z.prototype.shl=function(o,u){return this._verify1(o),this.imod(o.ushln(u))},z.prototype.imul=function(o,u){return this._verify2(o,u),this.imod(o.imul(u))},z.prototype.mul=function(o,u){return this._verify2(o,u),this.imod(o.mul(u))},z.prototype.isqr=function(o){return this.imul(o,o.clone())},z.prototype.sqr=function(o){return this.mul(o,o)},z.prototype.sqrt=function(o){if(o.isZero())return o.clone();var u=this.m.andln(3);if(n(u%2===1),u===3){var c=this.m.add(new a(1)).iushrn(2);return this.pow(o,c)}for(var h=this.m.subn(1),g=0;!h.isZero()&&h.andln(1)===0;)g++,h.iushrn(1);n(!h.isZero());var x=new a(1).toRed(this),E=x.redNeg(),v=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new a(2*l*l).toRed(this);this.pow(l,v).cmp(E)!==0;)l.redIAdd(E);for(var m=this.pow(l,h),P=this.pow(o,h.addn(1).iushrn(1)),N=this.pow(o,h),F=g;N.cmp(x)!==0;){for(var ee=N,q=0;ee.cmp(x)!==0;q++)ee=ee.redSqr();n(q=0;g--){for(var m=u.words[g],P=l-1;P>=0;P--){var N=m>>P&1;if(x!==h[0]&&(x=this.sqr(x)),N===0&&E===0){v=0;continue}E<<=1,E|=N,v++,!(v!==c&&(g!==0||P!==0))&&(x=this.mul(x,h[E]),v=0,E=0)}l=26}return x},z.prototype.convertTo=function(o){var u=o.umod(this.m);return u===o?u.clone():u},z.prototype.convertFrom=function(o){var u=o.clone();return u.red=null,u},a.mont=function(o){return new Y(o)};function Y(b){z.call(this,b),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}i(Y,z),Y.prototype.convertTo=function(o){return this.imod(o.ushln(this.shift))},Y.prototype.convertFrom=function(o){var u=this.imod(o.mul(this.rinv));return u.red=null,u},Y.prototype.imul=function(o,u){if(o.isZero()||u.isZero())return o.words[0]=0,o.length=1,o;var c=o.imul(u),h=c.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),g=c.isub(h).iushrn(this.shift),x=g;return g.cmp(this.m)>=0?x=g.isub(this.m):g.cmpn(0)<0&&(x=g.iadd(this.m)),x._forceRed(this)},Y.prototype.mul=function(o,u){if(o.isZero()||u.isZero())return new a(0)._forceRed(this);var c=o.mul(u),h=c.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),g=c.isub(h).iushrn(this.shift),x=g;return g.cmp(this.m)>=0?x=g.isub(this.m):g.cmpn(0)<0&&(x=g.iadd(this.m)),x._forceRed(this)},Y.prototype.invm=function(o){var u=this.imod(o._invmp(this.m).mul(this.r2));return u._forceRed(this)}})(e,Ut)})(R5);var bL=R5.exports,xL={},A5={},$v=mi,Pf=$v.Buffer,Aa={},Da;for(Da in $v)$v.hasOwnProperty(Da)&&(Da==="SlowBuffer"||Da==="Buffer"||(Aa[Da]=$v[Da]));var Of=Aa.Buffer={};for(Da in Pf)Pf.hasOwnProperty(Da)&&(Da==="allocUnsafe"||Da==="allocUnsafeSlow"||(Of[Da]=Pf[Da]));Aa.Buffer.prototype=Pf.prototype;(!Of.from||Of.from===Uint8Array.from)&&(Of.from=function(e,t,r){if(typeof e=="number")throw new TypeError('The "value" argument must not be of type number. Received type '+typeof e);if(e&&typeof e.length>"u")throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);return Pf(e,t,r)});Of.alloc||(Of.alloc=function(e,t,r){if(typeof e!="number")throw new TypeError('The "size" argument must be of type number. Received type '+typeof e);if(e<0||e>=2*(1<<30))throw new RangeError('The value "'+e+'" is invalid for option "size"');var n=Pf(e);return!t||t.length===0?n.fill(0):typeof r=="string"?n.fill(t,r):n.fill(t),n});if(!Aa.kStringMaxLength)try{Aa.kStringMaxLength=Yt.binding("buffer").kStringMaxLength}catch{}Aa.constants||(Aa.constants={MAX_LENGTH:Aa.kMaxLength},Aa.kStringMaxLength&&(Aa.constants.MAX_STRING_LENGTH=Aa.kStringMaxLength));var D5=Aa,Zy={};const jre=or;function Qa(e){this._reporterState={obj:null,path:[],options:e||{},errors:[]}}Zy.Reporter=Qa;Qa.prototype.isError=function(t){return t instanceof Zf};Qa.prototype.save=function(){const t=this._reporterState;return{obj:t.obj,pathLen:t.path.length}};Qa.prototype.restore=function(t){const r=this._reporterState;r.obj=t.obj,r.path=r.path.slice(0,t.pathLen)};Qa.prototype.enterKey=function(t){return this._reporterState.path.push(t)};Qa.prototype.exitKey=function(t){const r=this._reporterState;r.path=r.path.slice(0,t-1)};Qa.prototype.leaveKey=function(t,r,n){const i=this._reporterState;this.exitKey(t),i.obj!==null&&(i.obj[r]=n)};Qa.prototype.path=function(){return this._reporterState.path.join("/")};Qa.prototype.enterObject=function(){const t=this._reporterState,r=t.obj;return t.obj={},r};Qa.prototype.leaveObject=function(t){const r=this._reporterState,n=r.obj;return r.obj=t,n};Qa.prototype.error=function(t){let r;const n=this._reporterState,i=t instanceof Zf;if(i?r=t:r=new Zf(n.path.map(function(a){return"["+JSON.stringify(a)+"]"}).join(""),t.message||t,t.stack),!n.options.partial)throw r;return i||n.errors.push(r),r};Qa.prototype.wrapResult=function(t){const r=this._reporterState;return r.options.partial?{result:this.isError(t)?null:t,errors:r.errors}:t};function Zf(e,t){this.path=e,this.rethrow(t)}jre(Zf,Error);Zf.prototype.rethrow=function(t){if(this.message=t+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,Zf),!this.stack)try{throw new Error(this.message)}catch(r){this.stack=r.stack}return this};var fc={};const Bre=or,Jy=Zy.Reporter,Jf=D5.Buffer;function Va(e,t){if(Jy.call(this,t),!Jf.isBuffer(e)){this.error("Input not Buffer");return}this.base=e,this.offset=0,this.length=e.length}Bre(Va,Jy);fc.DecoderBuffer=Va;Va.isDecoderBuffer=function(t){return t instanceof Va?!0:typeof t=="object"&&Jf.isBuffer(t.base)&&t.constructor.name==="DecoderBuffer"&&typeof t.offset=="number"&&typeof t.length=="number"&&typeof t.save=="function"&&typeof t.restore=="function"&&typeof t.isEmpty=="function"&&typeof t.readUInt8=="function"&&typeof t.skip=="function"&&typeof t.raw=="function"};Va.prototype.save=function(){return{offset:this.offset,reporter:Jy.prototype.save.call(this)}};Va.prototype.restore=function(t){const r=new Va(this.base);return r.offset=t.offset,r.length=this.offset,this.offset=t.offset,Jy.prototype.restore.call(this,t.reporter),r};Va.prototype.isEmpty=function(){return this.offset===this.length};Va.prototype.readUInt8=function(t){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(t||"DecoderBuffer overrun")};Va.prototype.skip=function(t,r){if(!(this.offset+t<=this.length))return this.error(r||"DecoderBuffer overrun");const n=new Va(this.base);return n._reporterState=this._reporterState,n.offset=this.offset,n.length=this.offset+t,this.offset+=t,n};Va.prototype.raw=function(t){return this.base.slice(t?t.offset:this.offset,this.length)};function Qf(e,t){if(Array.isArray(e))this.length=0,this.value=e.map(function(r){return Qf.isEncoderBuffer(r)||(r=new Qf(r,t)),this.length+=r.length,r},this);else if(typeof e=="number"){if(!(0<=e&&e<=255))return t.error("non-byte EncoderBuffer value");this.value=e,this.length=1}else if(typeof e=="string")this.value=e,this.length=Jf.byteLength(e);else if(Jf.isBuffer(e))this.value=e,this.length=e.length;else return t.error("Unsupported type: "+typeof e)}fc.EncoderBuffer=Qf;Qf.isEncoderBuffer=function(t){return t instanceof Qf?!0:typeof t=="object"&&t.constructor.name==="EncoderBuffer"&&typeof t.length=="number"&&typeof t.join=="function"};Qf.prototype.join=function(t,r){return t||(t=Jf.alloc(this.length)),r||(r=0),this.length===0||(Array.isArray(this.value)?this.value.forEach(function(n){n.join(t,r),r+=n.length}):(typeof this.value=="number"?t[r]=this.value:typeof this.value=="string"?t.write(this.value,r):Jf.isBuffer(this.value)&&this.value.copy(t,r),r+=this.length)),t};const Fre=Zy.Reporter,zre=fc.EncoderBuffer,Ure=fc.DecoderBuffer,Ti=Ya,_L=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],Hre=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(_L),Vre=["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"];function Vr(e,t,r){const n={};this._baseState=n,n.name=r,n.enc=e,n.parent=t||null,n.children=null,n.tag=null,n.args=null,n.reverseArgs=null,n.choice=null,n.optional=!1,n.any=!1,n.obj=!1,n.use=null,n.useDecoder=null,n.key=null,n.default=null,n.explicit=null,n.implicit=null,n.contains=null,n.parent||(n.children=[],this._wrap())}var $5=Vr;const qre=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];Vr.prototype.clone=function(){const t=this._baseState,r={};qre.forEach(function(i){r[i]=t[i]});const n=new this.constructor(r.parent);return n._baseState=r,n};Vr.prototype._wrap=function(){const t=this._baseState;Hre.forEach(function(r){this[r]=function(){const i=new this.constructor(this);return t.children.push(i),i[r].apply(i,arguments)}},this)};Vr.prototype._init=function(t){const r=this._baseState;Ti(r.parent===null),t.call(this),r.children=r.children.filter(function(n){return n._baseState.parent===this},this),Ti.equal(r.children.length,1,"Root node can have only one child")};Vr.prototype._useArgs=function(t){const r=this._baseState,n=t.filter(function(i){return i instanceof this.constructor},this);t=t.filter(function(i){return!(i instanceof this.constructor)},this),n.length!==0&&(Ti(r.children===null),r.children=n,n.forEach(function(i){i._baseState.parent=this},this)),t.length!==0&&(Ti(r.args===null),r.args=t,r.reverseArgs=t.map(function(i){if(typeof i!="object"||i.constructor!==Object)return i;const a={};return Object.keys(i).forEach(function(s){s==(s|0)&&(s|=0);const f=i[s];a[f]=s}),a}))};Vre.forEach(function(e){Vr.prototype[e]=function(){const r=this._baseState;throw new Error(e+" not implemented for encoding: "+r.enc)}});_L.forEach(function(e){Vr.prototype[e]=function(){const r=this._baseState,n=Array.prototype.slice.call(arguments);return Ti(r.tag===null),r.tag=e,this._useArgs(n),this}});Vr.prototype.use=function(t){Ti(t);const r=this._baseState;return Ti(r.use===null),r.use=t,this};Vr.prototype.optional=function(){const t=this._baseState;return t.optional=!0,this};Vr.prototype.def=function(t){const r=this._baseState;return Ti(r.default===null),r.default=t,r.optional=!0,this};Vr.prototype.explicit=function(t){const r=this._baseState;return Ti(r.explicit===null&&r.implicit===null),r.explicit=t,this};Vr.prototype.implicit=function(t){const r=this._baseState;return Ti(r.explicit===null&&r.implicit===null),r.implicit=t,this};Vr.prototype.obj=function(){const t=this._baseState,r=Array.prototype.slice.call(arguments);return t.obj=!0,r.length!==0&&this._useArgs(r),this};Vr.prototype.key=function(t){const r=this._baseState;return Ti(r.key===null),r.key=t,this};Vr.prototype.any=function(){const t=this._baseState;return t.any=!0,this};Vr.prototype.choice=function(t){const r=this._baseState;return Ti(r.choice===null),r.choice=t,this._useArgs(Object.keys(t).map(function(n){return t[n]})),this};Vr.prototype.contains=function(t){const r=this._baseState;return Ti(r.use===null),r.contains=t,this};Vr.prototype._decode=function(t,r){const n=this._baseState;if(n.parent===null)return t.wrapResult(n.children[0]._decode(t,r));let i=n.default,a=!0,s=null;if(n.key!==null&&(s=t.enterKey(n.key)),n.optional){let d=null;if(n.explicit!==null?d=n.explicit:n.implicit!==null?d=n.implicit:n.tag!==null&&(d=n.tag),d===null&&!n.any){const p=t.save();try{n.choice===null?this._decodeGeneric(n.tag,t,r):this._decodeChoice(t,r),a=!0}catch{a=!1}t.restore(p)}else if(a=this._peekTag(t,d,n.any),t.isError(a))return a}let f;if(n.obj&&a&&(f=t.enterObject()),a){if(n.explicit!==null){const p=this._decodeTag(t,n.explicit);if(t.isError(p))return p;t=p}const d=t.offset;if(n.use===null&&n.choice===null){let p;n.any&&(p=t.save());const y=this._decodeTag(t,n.implicit!==null?n.implicit:n.tag,n.any);if(t.isError(y))return y;n.any?i=t.raw(p):t=y}if(r&&r.track&&n.tag!==null&&r.track(t.path(),d,t.length,"tagged"),r&&r.track&&n.tag!==null&&r.track(t.path(),t.offset,t.length,"content"),n.any||(n.choice===null?i=this._decodeGeneric(n.tag,t,r):i=this._decodeChoice(t,r)),t.isError(i))return i;if(!n.any&&n.choice===null&&n.children!==null&&n.children.forEach(function(y){y._decode(t,r)}),n.contains&&(n.tag==="octstr"||n.tag==="bitstr")){const p=new Ure(i);i=this._getUse(n.contains,t._reporterState.obj)._decode(p,r)}}return n.obj&&a&&(i=t.leaveObject(f)),n.key!==null&&(i!==null||a===!0)?t.leaveKey(s,n.key,i):s!==null&&t.exitKey(s),i};Vr.prototype._decodeGeneric=function(t,r,n){const i=this._baseState;return t==="seq"||t==="set"?null:t==="seqof"||t==="setof"?this._decodeList(r,t,i.args[0],n):/str$/.test(t)?this._decodeStr(r,t,n):t==="objid"&&i.args?this._decodeObjid(r,i.args[0],i.args[1],n):t==="objid"?this._decodeObjid(r,null,null,n):t==="gentime"||t==="utctime"?this._decodeTime(r,t,n):t==="null_"?this._decodeNull(r,n):t==="bool"?this._decodeBool(r,n):t==="objDesc"?this._decodeStr(r,t,n):t==="int"||t==="enum"?this._decodeInt(r,i.args&&i.args[0],n):i.use!==null?this._getUse(i.use,r._reporterState.obj)._decode(r,n):r.error("unknown tag: "+t)};Vr.prototype._getUse=function(t,r){const n=this._baseState;return n.useDecoder=this._use(t,r),Ti(n.useDecoder._baseState.parent===null),n.useDecoder=n.useDecoder._baseState.children[0],n.implicit!==n.useDecoder._baseState.implicit&&(n.useDecoder=n.useDecoder.clone(),n.useDecoder._baseState.implicit=n.implicit),n.useDecoder};Vr.prototype._decodeChoice=function(t,r){const n=this._baseState;let i=null,a=!1;return Object.keys(n.choice).some(function(s){const f=t.save(),d=n.choice[s];try{const p=d._decode(t,r);if(t.isError(p))return!1;i={type:s,value:p},a=!0}catch{return t.restore(f),!1}return!0},this),a?i:t.error("Choice not matched")};Vr.prototype._createEncoderBuffer=function(t){return new zre(t,this.reporter)};Vr.prototype._encode=function(t,r,n){const i=this._baseState;if(i.default!==null&&i.default===t)return;const a=this._encodeValue(t,r,n);if(a!==void 0&&!this._skipDefault(a,r,n))return a};Vr.prototype._encodeValue=function(t,r,n){const i=this._baseState;if(i.parent===null)return i.children[0]._encode(t,r||new Fre);let a=null;if(this.reporter=r,i.optional&&t===void 0)if(i.default!==null)t=i.default;else return;let s=null,f=!1;if(i.any)a=this._createEncoderBuffer(t);else if(i.choice)a=this._encodeChoice(t,r);else if(i.contains)s=this._getUse(i.contains,n)._encode(t,r),f=!0;else if(i.children)s=i.children.map(function(d){if(d._baseState.tag==="null_")return d._encode(null,r,t);if(d._baseState.key===null)return r.error("Child should have a key");const p=r.enterKey(d._baseState.key);if(typeof t!="object")return r.error("Child expected, but input is not object");const y=d._encode(t[d._baseState.key],r,t);return r.leaveKey(p),y},this).filter(function(d){return d}),s=this._createEncoderBuffer(s);else if(i.tag==="seqof"||i.tag==="setof"){if(!(i.args&&i.args.length===1))return r.error("Too many args for : "+i.tag);if(!Array.isArray(t))return r.error("seqof/setof, but data is not Array");const d=this.clone();d._baseState.implicit=null,s=this._createEncoderBuffer(t.map(function(p){const y=this._baseState;return this._getUse(y.args[0],t)._encode(p,r)},d))}else i.use!==null?a=this._getUse(i.use,n)._encode(t,r):(s=this._encodePrimitive(i.tag,t),f=!0);if(!i.any&&i.choice===null){const d=i.implicit!==null?i.implicit:i.tag,p=i.implicit===null?"universal":"context";d===null?i.use===null&&r.error("Tag could be omitted only for .use()"):i.use===null&&(a=this._encodeComposite(d,f,p,s))}return i.explicit!==null&&(a=this._encodeComposite(i.explicit,!1,"context",a)),a};Vr.prototype._encodeChoice=function(t,r){const n=this._baseState,i=n.choice[t.type];return i||Ti(!1,t.type+" not found in "+JSON.stringify(Object.keys(n.choice))),i._encode(t.value,r)};Vr.prototype._encodePrimitive=function(t,r){const n=this._baseState;if(/str$/.test(t))return this._encodeStr(r,t);if(t==="objid"&&n.args)return this._encodeObjid(r,n.reverseArgs[0],n.args[1]);if(t==="objid")return this._encodeObjid(r,null,null);if(t==="gentime"||t==="utctime")return this._encodeTime(r,t);if(t==="null_")return this._encodeNull();if(t==="int"||t==="enum")return this._encodeInt(r,n.args&&n.reverseArgs[0]);if(t==="bool")return this._encodeBool(r);if(t==="objDesc")return this._encodeStr(r,t);throw new Error("Unsupported tag: "+t)};Vr.prototype._isNumstr=function(t){return/^[0-9 ]*$/.test(t)};Vr.prototype._isPrintstr=function(t){return/^[A-Za-z0-9 '()+,-./:=?]*$/.test(t)};var Qy={};(function(e){function t(r){const n={};return Object.keys(r).forEach(function(i){(i|0)==i&&(i=i|0);const a=r[i];n[a]=i}),n}e.tagClass={0:"universal",1:"application",2:"context",3:"private"},e.tagClassByName=t(e.tagClass),e.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},e.tagByName=t(e.tag)})(Qy);const Wre=or,js=D5.Buffer,SL=$5,G2=Qy;function ML(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new ko,this.tree._init(e.body)}var EL=ML;ML.prototype.encode=function(t,r){return this.tree._encode(t,r).join()};function ko(e){SL.call(this,"der",e)}Wre(ko,SL);ko.prototype._encodeComposite=function(t,r,n,i){const a=Kre(t,r,n,this.reporter);if(i.length<128){const d=js.alloc(2);return d[0]=a,d[1]=i.length,this._createEncoderBuffer([d,i])}let s=1;for(let d=i.length;d>=256;d>>=8)s++;const f=js.alloc(2+s);f[0]=a,f[1]=128|s;for(let d=1+s,p=i.length;p>0;d--,p>>=8)f[d]=p&255;return this._createEncoderBuffer([f,i])};ko.prototype._encodeStr=function(t,r){if(r==="bitstr")return this._createEncoderBuffer([t.unused|0,t.data]);if(r==="bmpstr"){const n=js.alloc(t.length*2);for(let i=0;i=40)return this.reporter.error("Second objid identifier OOB");t.splice(0,2,t[0]*40+t[1])}let i=0;for(let f=0;f=128;d>>=7)i++}const a=js.alloc(i);let s=a.length-1;for(let f=t.length-1;f>=0;f--){let d=t[f];for(a[s--]=d&127;(d>>=7)>0;)a[s--]=128|d&127}return this._createEncoderBuffer(a)};function ka(e){return e<10?"0"+e:e}ko.prototype._encodeTime=function(t,r){let n;const i=new Date(t);return r==="gentime"?n=[ka(i.getUTCFullYear()),ka(i.getUTCMonth()+1),ka(i.getUTCDate()),ka(i.getUTCHours()),ka(i.getUTCMinutes()),ka(i.getUTCSeconds()),"Z"].join(""):r==="utctime"?n=[ka(i.getUTCFullYear()%100),ka(i.getUTCMonth()+1),ka(i.getUTCDate()),ka(i.getUTCHours()),ka(i.getUTCMinutes()),ka(i.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+r+" time is not supported yet"),this._encodeStr(n,"octstr")};ko.prototype._encodeNull=function(){return this._createEncoderBuffer("")};ko.prototype._encodeInt=function(t,r){if(typeof t=="string"){if(!r)return this.reporter.error("String int or enum given, but no values map");if(!r.hasOwnProperty(t))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(t));t=r[t]}if(typeof t!="number"&&!js.isBuffer(t)){const a=t.toArray();!t.sign&&a[0]&128&&a.unshift(0),t=js.from(a)}if(js.isBuffer(t)){let a=t.length;t.length===0&&a++;const s=js.alloc(a);return t.copy(s),t.length===0&&(s[0]=0),this._createEncoderBuffer(s)}if(t<128)return this._createEncoderBuffer(t);if(t<256)return this._createEncoderBuffer([0,t]);let n=1;for(let a=t;a>=256;a>>=8)n++;const i=new Array(n);for(let a=i.length-1;a>=0;a--)i[a]=t&255,t>>=8;return i[0]&128&&i.unshift(0),this._createEncoderBuffer(js.from(i))};ko.prototype._encodeBool=function(t){return this._createEncoderBuffer(t?255:0)};ko.prototype._use=function(t,r){return typeof t=="function"&&(t=t(r)),t._getEncoder("der").tree};ko.prototype._skipDefault=function(t,r,n){const i=this._baseState;let a;if(i.default===null)return!1;const s=t.join();if(i.defaultBuffer===void 0&&(i.defaultBuffer=this._encodeValue(i.default,r,n).join()),s.length!==i.defaultBuffer.length)return!1;for(a=0;a=31?n.error("Multi-octet tag encoding unsupported"):(t||(i|=32),i|=G2.tagClassByName[r||"universal"]<<6,i)}const Gre=or,I5=EL;function L5(e){I5.call(this,e),this.enc="pem"}Gre(L5,I5);var Yre=L5;L5.prototype.encode=function(t,r){const i=I5.prototype.encode.call(this,t).toString("base64"),a=["-----BEGIN "+r.label+"-----"];for(let s=0;s>6],i=(r&32)===0;if((r&31)===31){let s=r;for(r=0;(s&128)===128;){if(s=e.readUInt8(t),e.isError(s))return s;r<<=7,r|=s&127}}else r&=31;const a=NT.tag[r];return{cls:n,primitive:i,tag:r,tagStr:a}}function PL(e,t,r){let n=e.readUInt8(r);if(e.isError(n))return n;if(!t&&n===128)return null;if(!(n&128))return n;const i=n&127;if(i>4)return e.error("length octect is too long");n=0;for(let a=0;a0&&k.ishrn(R),k}function S(O,T){O=_(O,T),O=O.mod(T);var k=e.from(O.toArray());if(k.length=y)throw new Error("invalid sig")}return Y2=a,Y2}var X2,UT;function Ane(){if(UT)return X2;UT=1;var e=Jt.Buffer,t=vp,r=j$,n=or,i=One(),a=Rne(),s=iI;Object.keys(s).forEach(function(w){s[w].id=e.from(s[w].id,"hex"),s[w.toLowerCase()]=s[w]});function f(w){r.Writable.call(this);var _=s[w];if(!_)throw new Error("Unknown message digest");this._hashType=_.hash,this._hash=t(_.hash),this._tag=_.id,this._signType=_.sign}n(f,r.Writable),f.prototype._write=function(_,S,M){this._hash.update(_),M()},f.prototype.update=function(_,S){return typeof _=="string"&&(_=e.from(_,S)),this._hash.update(_),this},f.prototype.sign=function(_,S){this.end();var M=this._hash.digest(),C=i(M,_,this._hashType,this._signType,this._tag);return S?C.toString(S):C};function d(w){r.Writable.call(this);var _=s[w];if(!_)throw new Error("Unknown message digest");this._hash=t(_.hash),this._tag=_.id,this._signType=_.sign}n(d,r.Writable),d.prototype._write=function(_,S,M){this._hash.update(_),M()},d.prototype.update=function(_,S){return typeof _=="string"&&(_=e.from(_,S)),this._hash.update(_),this},d.prototype.verify=function(_,S,M){typeof S=="string"&&(S=e.from(S,M)),this.end();var C=this._hash.digest();return a(S,C,_,this._signType,this._tag)};function p(w){return new f(w)}function y(w){return new d(w)}return X2={Sign:p,Verify:y,createSign:p,createVerify:y},X2}var U5={exports:{}};U5.exports;(function(e){(function(t,r){function n(b,o){if(!b)throw new Error(o||"Assertion failed")}function i(b,o){b.super_=o;var u=function(){};u.prototype=o.prototype,b.prototype=new u,b.prototype.constructor=b}function a(b,o,u){if(a.isBN(b))return b;this.negative=0,this.words=null,this.length=0,this.red=null,b!==null&&((o==="le"||o==="be")&&(u=o,o=10),this._init(b||0,o||10,u||"be"))}typeof t=="object"?t.exports=a:r.BN=a,a.BN=a,a.wordSize=26;var s;try{typeof window<"u"&&typeof window.Buffer<"u"?s=window.Buffer:s=mi.Buffer}catch{}a.isBN=function(o){return o instanceof a?!0:o!==null&&typeof o=="object"&&o.constructor.wordSize===a.wordSize&&Array.isArray(o.words)},a.max=function(o,u){return o.cmp(u)>0?o:u},a.min=function(o,u){return o.cmp(u)<0?o:u},a.prototype._init=function(o,u,c){if(typeof o=="number")return this._initNumber(o,u,c);if(typeof o=="object")return this._initArray(o,u,c);u==="hex"&&(u=16),n(u===(u|0)&&u>=2&&u<=36),o=o.toString().replace(/\s+/g,"");var h=0;o[0]==="-"&&(h++,this.negative=1),h=0;h-=3)x=o[h]|o[h-1]<<8|o[h-2]<<16,this.words[g]|=x<>>26-E&67108863,E+=24,E>=26&&(E-=26,g++);else if(c==="le")for(h=0,g=0;h>>26-E&67108863,E+=24,E>=26&&(E-=26,g++);return this.strip()};function f(b,o){var u=b.charCodeAt(o);return u>=65&&u<=70?u-55:u>=97&&u<=102?u-87:u-48&15}function d(b,o,u){var c=f(b,u);return u-1>=o&&(c|=f(b,u-1)<<4),c}a.prototype._parseHex=function(o,u,c){this.length=Math.ceil((o.length-u)/6),this.words=new Array(this.length);for(var h=0;h=u;h-=2)E=d(o,u,h)<=18?(g-=18,x+=1,this.words[x]|=E>>>26):g+=8;else{var v=o.length-u;for(h=v%2===0?u+1:u;h=18?(g-=18,x+=1,this.words[x]|=E>>>26):g+=8}this.strip()};function p(b,o,u,c){for(var h=0,g=Math.min(b.length,u),x=o;x=49?h+=E-49+10:E>=17?h+=E-17+10:h+=E}return h}a.prototype._parseBase=function(o,u,c){this.words=[0],this.length=1;for(var h=0,g=1;g<=67108863;g*=u)h++;h--,g=g/u|0;for(var x=o.length-c,E=x%h,v=Math.min(x,x-E)+c,l=0,m=c;m1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},a.prototype.inspect=function(){return(this.red?""};var y=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],w=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],_=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(o,u){o=o||10,u=u|0||1;var c;if(o===16||o==="hex"){c="";for(var h=0,g=0,x=0;x>>24-h&16777215,g!==0||x!==this.length-1?c=y[6-v.length]+v+c:c=v+c,h+=2,h>=26&&(h-=26,x--)}for(g!==0&&(c=g.toString(16)+c);c.length%u!==0;)c="0"+c;return this.negative!==0&&(c="-"+c),c}if(o===(o|0)&&o>=2&&o<=36){var l=w[o],m=_[o];c="";var P=this.clone();for(P.negative=0;!P.isZero();){var N=P.modn(m).toString(o);P=P.idivn(m),P.isZero()?c=N+c:c=y[l-N.length]+N+c}for(this.isZero()&&(c="0"+c);c.length%u!==0;)c="0"+c;return this.negative!==0&&(c="-"+c),c}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var o=this.words[0];return this.length===2?o+=this.words[1]*67108864:this.length===3&&this.words[2]===1?o+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-o:o},a.prototype.toJSON=function(){return this.toString(16)},a.prototype.toBuffer=function(o,u){return n(typeof s<"u"),this.toArrayLike(s,o,u)},a.prototype.toArray=function(o,u){return this.toArrayLike(Array,o,u)},a.prototype.toArrayLike=function(o,u,c){var h=this.byteLength(),g=c||Math.max(1,h);n(h<=g,"byte array longer than desired length"),n(g>0,"Requested array length <= 0"),this.strip();var x=u==="le",E=new o(g),v,l,m=this.clone();if(x){for(l=0;!m.isZero();l++)v=m.andln(255),m.iushrn(8),E[l]=v;for(;l=4096&&(c+=13,u>>>=13),u>=64&&(c+=7,u>>>=7),u>=8&&(c+=4,u>>>=4),u>=2&&(c+=2,u>>>=2),c+u},a.prototype._zeroBits=function(o){if(o===0)return 26;var u=o,c=0;return u&8191||(c+=13,u>>>=13),u&127||(c+=7,u>>>=7),u&15||(c+=4,u>>>=4),u&3||(c+=2,u>>>=2),u&1||c++,c},a.prototype.bitLength=function(){var o=this.words[this.length-1],u=this._countBits(o);return(this.length-1)*26+u};function S(b){for(var o=new Array(b.bitLength()),u=0;u>>h}return o}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var o=0,u=0;uo.length?this.clone().ior(o):o.clone().ior(this)},a.prototype.uor=function(o){return this.length>o.length?this.clone().iuor(o):o.clone().iuor(this)},a.prototype.iuand=function(o){var u;this.length>o.length?u=o:u=this;for(var c=0;co.length?this.clone().iand(o):o.clone().iand(this)},a.prototype.uand=function(o){return this.length>o.length?this.clone().iuand(o):o.clone().iuand(this)},a.prototype.iuxor=function(o){var u,c;this.length>o.length?(u=this,c=o):(u=o,c=this);for(var h=0;ho.length?this.clone().ixor(o):o.clone().ixor(this)},a.prototype.uxor=function(o){return this.length>o.length?this.clone().iuxor(o):o.clone().iuxor(this)},a.prototype.inotn=function(o){n(typeof o=="number"&&o>=0);var u=Math.ceil(o/26)|0,c=o%26;this._expand(u),c>0&&u--;for(var h=0;h0&&(this.words[h]=~this.words[h]&67108863>>26-c),this.strip()},a.prototype.notn=function(o){return this.clone().inotn(o)},a.prototype.setn=function(o,u){n(typeof o=="number"&&o>=0);var c=o/26|0,h=o%26;return this._expand(c+1),u?this.words[c]=this.words[c]|1<o.length?(c=this,h=o):(c=o,h=this);for(var g=0,x=0;x>>26;for(;g!==0&&x>>26;if(this.length=c.length,g!==0)this.words[this.length]=g,this.length++;else if(c!==this)for(;xo.length?this.clone().iadd(o):o.clone().iadd(this)},a.prototype.isub=function(o){if(o.negative!==0){o.negative=0;var u=this.iadd(o);return o.negative=1,u._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(o),this.negative=1,this._normSign();var c=this.cmp(o);if(c===0)return this.negative=0,this.length=1,this.words[0]=0,this;var h,g;c>0?(h=this,g=o):(h=o,g=this);for(var x=0,E=0;E>26,this.words[E]=u&67108863;for(;x!==0&&E>26,this.words[E]=u&67108863;if(x===0&&E>>26,P=v&67108863,N=Math.min(l,o.length-1),F=Math.max(0,l-b.length+1);F<=N;F++){var ee=l-F|0;h=b.words[ee]|0,g=o.words[F]|0,x=h*g+P,m+=x/67108864|0,P=x&67108863}u.words[l]=P|0,v=m|0}return v!==0?u.words[l]=v|0:u.length--,u.strip()}var C=function(o,u,c){var h=o.words,g=u.words,x=c.words,E=0,v,l,m,P=h[0]|0,N=P&8191,F=P>>>13,ee=h[1]|0,q=ee&8191,ae=ee>>>13,pe=h[2]|0,we=pe&8191,Se=pe>>>13,he=h[3]|0,re=he&8191,_e=he>>>13,W=h[4]|0,ve=W&8191,Z=W>>>13,ne=h[5]|0,K=ne&8191,le=ne>>>13,xe=h[6]|0,ce=xe&8191,de=xe>>>13,Ae=h[7]|0,ye=Ae&8191,be=Ae>>>13,tt=h[8]|0,Oe=tt&8191,$e=tt>>>13,Et=h[9]|0,ze=Et&8191,He=Et>>>13,Fe=g[0]|0,Te=Fe&8191,Pe=Fe>>>13,pt=g[1]|0,De=pt&8191,je=pt>>>13,bt=g[2]|0,Le=bt&8191,Ge=bt>>>13,Ct=g[3]|0,Be=Ct&8191,Ye=Ct>>>13,Pt=g[4]|0,Ue=Pt&8191,et=Pt>>>13,Vt=g[5]|0,Xe=Vt&8191,ot=Vt>>>13,Kt=g[6]|0,Ve=Kt&8191,Je=Kt>>>13,It=g[7]|0,We=It&8191,it=It>>>13,jt=g[8]|0,Qe=jt&8191,lt=jt>>>13,Xt=g[9]|0,qe=Xt&8191,at=Xt>>>13;c.negative=o.negative^u.negative,c.length=19,v=Math.imul(N,Te),l=Math.imul(N,Pe),l=l+Math.imul(F,Te)|0,m=Math.imul(F,Pe);var Bt=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,v=Math.imul(q,Te),l=Math.imul(q,Pe),l=l+Math.imul(ae,Te)|0,m=Math.imul(ae,Pe),v=v+Math.imul(N,De)|0,l=l+Math.imul(N,je)|0,l=l+Math.imul(F,De)|0,m=m+Math.imul(F,je)|0;var Ot=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,v=Math.imul(we,Te),l=Math.imul(we,Pe),l=l+Math.imul(Se,Te)|0,m=Math.imul(Se,Pe),v=v+Math.imul(q,De)|0,l=l+Math.imul(q,je)|0,l=l+Math.imul(ae,De)|0,m=m+Math.imul(ae,je)|0,v=v+Math.imul(N,Le)|0,l=l+Math.imul(N,Ge)|0,l=l+Math.imul(F,Le)|0,m=m+Math.imul(F,Ge)|0;var sr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(sr>>>26)|0,sr&=67108863,v=Math.imul(re,Te),l=Math.imul(re,Pe),l=l+Math.imul(_e,Te)|0,m=Math.imul(_e,Pe),v=v+Math.imul(we,De)|0,l=l+Math.imul(we,je)|0,l=l+Math.imul(Se,De)|0,m=m+Math.imul(Se,je)|0,v=v+Math.imul(q,Le)|0,l=l+Math.imul(q,Ge)|0,l=l+Math.imul(ae,Le)|0,m=m+Math.imul(ae,Ge)|0,v=v+Math.imul(N,Be)|0,l=l+Math.imul(N,Ye)|0,l=l+Math.imul(F,Be)|0,m=m+Math.imul(F,Ye)|0;var Ht=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,v=Math.imul(ve,Te),l=Math.imul(ve,Pe),l=l+Math.imul(Z,Te)|0,m=Math.imul(Z,Pe),v=v+Math.imul(re,De)|0,l=l+Math.imul(re,je)|0,l=l+Math.imul(_e,De)|0,m=m+Math.imul(_e,je)|0,v=v+Math.imul(we,Le)|0,l=l+Math.imul(we,Ge)|0,l=l+Math.imul(Se,Le)|0,m=m+Math.imul(Se,Ge)|0,v=v+Math.imul(q,Be)|0,l=l+Math.imul(q,Ye)|0,l=l+Math.imul(ae,Be)|0,m=m+Math.imul(ae,Ye)|0,v=v+Math.imul(N,Ue)|0,l=l+Math.imul(N,et)|0,l=l+Math.imul(F,Ue)|0,m=m+Math.imul(F,et)|0;var hr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(hr>>>26)|0,hr&=67108863,v=Math.imul(K,Te),l=Math.imul(K,Pe),l=l+Math.imul(le,Te)|0,m=Math.imul(le,Pe),v=v+Math.imul(ve,De)|0,l=l+Math.imul(ve,je)|0,l=l+Math.imul(Z,De)|0,m=m+Math.imul(Z,je)|0,v=v+Math.imul(re,Le)|0,l=l+Math.imul(re,Ge)|0,l=l+Math.imul(_e,Le)|0,m=m+Math.imul(_e,Ge)|0,v=v+Math.imul(we,Be)|0,l=l+Math.imul(we,Ye)|0,l=l+Math.imul(Se,Be)|0,m=m+Math.imul(Se,Ye)|0,v=v+Math.imul(q,Ue)|0,l=l+Math.imul(q,et)|0,l=l+Math.imul(ae,Ue)|0,m=m+Math.imul(ae,et)|0,v=v+Math.imul(N,Xe)|0,l=l+Math.imul(N,ot)|0,l=l+Math.imul(F,Xe)|0,m=m+Math.imul(F,ot)|0;var pr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(pr>>>26)|0,pr&=67108863,v=Math.imul(ce,Te),l=Math.imul(ce,Pe),l=l+Math.imul(de,Te)|0,m=Math.imul(de,Pe),v=v+Math.imul(K,De)|0,l=l+Math.imul(K,je)|0,l=l+Math.imul(le,De)|0,m=m+Math.imul(le,je)|0,v=v+Math.imul(ve,Le)|0,l=l+Math.imul(ve,Ge)|0,l=l+Math.imul(Z,Le)|0,m=m+Math.imul(Z,Ge)|0,v=v+Math.imul(re,Be)|0,l=l+Math.imul(re,Ye)|0,l=l+Math.imul(_e,Be)|0,m=m+Math.imul(_e,Ye)|0,v=v+Math.imul(we,Ue)|0,l=l+Math.imul(we,et)|0,l=l+Math.imul(Se,Ue)|0,m=m+Math.imul(Se,et)|0,v=v+Math.imul(q,Xe)|0,l=l+Math.imul(q,ot)|0,l=l+Math.imul(ae,Xe)|0,m=m+Math.imul(ae,ot)|0,v=v+Math.imul(N,Ve)|0,l=l+Math.imul(N,Je)|0,l=l+Math.imul(F,Ve)|0,m=m+Math.imul(F,Je)|0;var _r=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(_r>>>26)|0,_r&=67108863,v=Math.imul(ye,Te),l=Math.imul(ye,Pe),l=l+Math.imul(be,Te)|0,m=Math.imul(be,Pe),v=v+Math.imul(ce,De)|0,l=l+Math.imul(ce,je)|0,l=l+Math.imul(de,De)|0,m=m+Math.imul(de,je)|0,v=v+Math.imul(K,Le)|0,l=l+Math.imul(K,Ge)|0,l=l+Math.imul(le,Le)|0,m=m+Math.imul(le,Ge)|0,v=v+Math.imul(ve,Be)|0,l=l+Math.imul(ve,Ye)|0,l=l+Math.imul(Z,Be)|0,m=m+Math.imul(Z,Ye)|0,v=v+Math.imul(re,Ue)|0,l=l+Math.imul(re,et)|0,l=l+Math.imul(_e,Ue)|0,m=m+Math.imul(_e,et)|0,v=v+Math.imul(we,Xe)|0,l=l+Math.imul(we,ot)|0,l=l+Math.imul(Se,Xe)|0,m=m+Math.imul(Se,ot)|0,v=v+Math.imul(q,Ve)|0,l=l+Math.imul(q,Je)|0,l=l+Math.imul(ae,Ve)|0,m=m+Math.imul(ae,Je)|0,v=v+Math.imul(N,We)|0,l=l+Math.imul(N,it)|0,l=l+Math.imul(F,We)|0,m=m+Math.imul(F,it)|0;var Sr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,v=Math.imul(Oe,Te),l=Math.imul(Oe,Pe),l=l+Math.imul($e,Te)|0,m=Math.imul($e,Pe),v=v+Math.imul(ye,De)|0,l=l+Math.imul(ye,je)|0,l=l+Math.imul(be,De)|0,m=m+Math.imul(be,je)|0,v=v+Math.imul(ce,Le)|0,l=l+Math.imul(ce,Ge)|0,l=l+Math.imul(de,Le)|0,m=m+Math.imul(de,Ge)|0,v=v+Math.imul(K,Be)|0,l=l+Math.imul(K,Ye)|0,l=l+Math.imul(le,Be)|0,m=m+Math.imul(le,Ye)|0,v=v+Math.imul(ve,Ue)|0,l=l+Math.imul(ve,et)|0,l=l+Math.imul(Z,Ue)|0,m=m+Math.imul(Z,et)|0,v=v+Math.imul(re,Xe)|0,l=l+Math.imul(re,ot)|0,l=l+Math.imul(_e,Xe)|0,m=m+Math.imul(_e,ot)|0,v=v+Math.imul(we,Ve)|0,l=l+Math.imul(we,Je)|0,l=l+Math.imul(Se,Ve)|0,m=m+Math.imul(Se,Je)|0,v=v+Math.imul(q,We)|0,l=l+Math.imul(q,it)|0,l=l+Math.imul(ae,We)|0,m=m+Math.imul(ae,it)|0,v=v+Math.imul(N,Qe)|0,l=l+Math.imul(N,lt)|0,l=l+Math.imul(F,Qe)|0,m=m+Math.imul(F,lt)|0;var cr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(cr>>>26)|0,cr&=67108863,v=Math.imul(ze,Te),l=Math.imul(ze,Pe),l=l+Math.imul(He,Te)|0,m=Math.imul(He,Pe),v=v+Math.imul(Oe,De)|0,l=l+Math.imul(Oe,je)|0,l=l+Math.imul($e,De)|0,m=m+Math.imul($e,je)|0,v=v+Math.imul(ye,Le)|0,l=l+Math.imul(ye,Ge)|0,l=l+Math.imul(be,Le)|0,m=m+Math.imul(be,Ge)|0,v=v+Math.imul(ce,Be)|0,l=l+Math.imul(ce,Ye)|0,l=l+Math.imul(de,Be)|0,m=m+Math.imul(de,Ye)|0,v=v+Math.imul(K,Ue)|0,l=l+Math.imul(K,et)|0,l=l+Math.imul(le,Ue)|0,m=m+Math.imul(le,et)|0,v=v+Math.imul(ve,Xe)|0,l=l+Math.imul(ve,ot)|0,l=l+Math.imul(Z,Xe)|0,m=m+Math.imul(Z,ot)|0,v=v+Math.imul(re,Ve)|0,l=l+Math.imul(re,Je)|0,l=l+Math.imul(_e,Ve)|0,m=m+Math.imul(_e,Je)|0,v=v+Math.imul(we,We)|0,l=l+Math.imul(we,it)|0,l=l+Math.imul(Se,We)|0,m=m+Math.imul(Se,it)|0,v=v+Math.imul(q,Qe)|0,l=l+Math.imul(q,lt)|0,l=l+Math.imul(ae,Qe)|0,m=m+Math.imul(ae,lt)|0,v=v+Math.imul(N,qe)|0,l=l+Math.imul(N,at)|0,l=l+Math.imul(F,qe)|0,m=m+Math.imul(F,at)|0;var qt=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(qt>>>26)|0,qt&=67108863,v=Math.imul(ze,De),l=Math.imul(ze,je),l=l+Math.imul(He,De)|0,m=Math.imul(He,je),v=v+Math.imul(Oe,Le)|0,l=l+Math.imul(Oe,Ge)|0,l=l+Math.imul($e,Le)|0,m=m+Math.imul($e,Ge)|0,v=v+Math.imul(ye,Be)|0,l=l+Math.imul(ye,Ye)|0,l=l+Math.imul(be,Be)|0,m=m+Math.imul(be,Ye)|0,v=v+Math.imul(ce,Ue)|0,l=l+Math.imul(ce,et)|0,l=l+Math.imul(de,Ue)|0,m=m+Math.imul(de,et)|0,v=v+Math.imul(K,Xe)|0,l=l+Math.imul(K,ot)|0,l=l+Math.imul(le,Xe)|0,m=m+Math.imul(le,ot)|0,v=v+Math.imul(ve,Ve)|0,l=l+Math.imul(ve,Je)|0,l=l+Math.imul(Z,Ve)|0,m=m+Math.imul(Z,Je)|0,v=v+Math.imul(re,We)|0,l=l+Math.imul(re,it)|0,l=l+Math.imul(_e,We)|0,m=m+Math.imul(_e,it)|0,v=v+Math.imul(we,Qe)|0,l=l+Math.imul(we,lt)|0,l=l+Math.imul(Se,Qe)|0,m=m+Math.imul(Se,lt)|0,v=v+Math.imul(q,qe)|0,l=l+Math.imul(q,at)|0,l=l+Math.imul(ae,qe)|0,m=m+Math.imul(ae,at)|0;var lr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(lr>>>26)|0,lr&=67108863,v=Math.imul(ze,Le),l=Math.imul(ze,Ge),l=l+Math.imul(He,Le)|0,m=Math.imul(He,Ge),v=v+Math.imul(Oe,Be)|0,l=l+Math.imul(Oe,Ye)|0,l=l+Math.imul($e,Be)|0,m=m+Math.imul($e,Ye)|0,v=v+Math.imul(ye,Ue)|0,l=l+Math.imul(ye,et)|0,l=l+Math.imul(be,Ue)|0,m=m+Math.imul(be,et)|0,v=v+Math.imul(ce,Xe)|0,l=l+Math.imul(ce,ot)|0,l=l+Math.imul(de,Xe)|0,m=m+Math.imul(de,ot)|0,v=v+Math.imul(K,Ve)|0,l=l+Math.imul(K,Je)|0,l=l+Math.imul(le,Ve)|0,m=m+Math.imul(le,Je)|0,v=v+Math.imul(ve,We)|0,l=l+Math.imul(ve,it)|0,l=l+Math.imul(Z,We)|0,m=m+Math.imul(Z,it)|0,v=v+Math.imul(re,Qe)|0,l=l+Math.imul(re,lt)|0,l=l+Math.imul(_e,Qe)|0,m=m+Math.imul(_e,lt)|0,v=v+Math.imul(we,qe)|0,l=l+Math.imul(we,at)|0,l=l+Math.imul(Se,qe)|0,m=m+Math.imul(Se,at)|0;var br=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(br>>>26)|0,br&=67108863,v=Math.imul(ze,Be),l=Math.imul(ze,Ye),l=l+Math.imul(He,Be)|0,m=Math.imul(He,Ye),v=v+Math.imul(Oe,Ue)|0,l=l+Math.imul(Oe,et)|0,l=l+Math.imul($e,Ue)|0,m=m+Math.imul($e,et)|0,v=v+Math.imul(ye,Xe)|0,l=l+Math.imul(ye,ot)|0,l=l+Math.imul(be,Xe)|0,m=m+Math.imul(be,ot)|0,v=v+Math.imul(ce,Ve)|0,l=l+Math.imul(ce,Je)|0,l=l+Math.imul(de,Ve)|0,m=m+Math.imul(de,Je)|0,v=v+Math.imul(K,We)|0,l=l+Math.imul(K,it)|0,l=l+Math.imul(le,We)|0,m=m+Math.imul(le,it)|0,v=v+Math.imul(ve,Qe)|0,l=l+Math.imul(ve,lt)|0,l=l+Math.imul(Z,Qe)|0,m=m+Math.imul(Z,lt)|0,v=v+Math.imul(re,qe)|0,l=l+Math.imul(re,at)|0,l=l+Math.imul(_e,qe)|0,m=m+Math.imul(_e,at)|0;var Mr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,v=Math.imul(ze,Ue),l=Math.imul(ze,et),l=l+Math.imul(He,Ue)|0,m=Math.imul(He,et),v=v+Math.imul(Oe,Xe)|0,l=l+Math.imul(Oe,ot)|0,l=l+Math.imul($e,Xe)|0,m=m+Math.imul($e,ot)|0,v=v+Math.imul(ye,Ve)|0,l=l+Math.imul(ye,Je)|0,l=l+Math.imul(be,Ve)|0,m=m+Math.imul(be,Je)|0,v=v+Math.imul(ce,We)|0,l=l+Math.imul(ce,it)|0,l=l+Math.imul(de,We)|0,m=m+Math.imul(de,it)|0,v=v+Math.imul(K,Qe)|0,l=l+Math.imul(K,lt)|0,l=l+Math.imul(le,Qe)|0,m=m+Math.imul(le,lt)|0,v=v+Math.imul(ve,qe)|0,l=l+Math.imul(ve,at)|0,l=l+Math.imul(Z,qe)|0,m=m+Math.imul(Z,at)|0;var Er=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Er>>>26)|0,Er&=67108863,v=Math.imul(ze,Xe),l=Math.imul(ze,ot),l=l+Math.imul(He,Xe)|0,m=Math.imul(He,ot),v=v+Math.imul(Oe,Ve)|0,l=l+Math.imul(Oe,Je)|0,l=l+Math.imul($e,Ve)|0,m=m+Math.imul($e,Je)|0,v=v+Math.imul(ye,We)|0,l=l+Math.imul(ye,it)|0,l=l+Math.imul(be,We)|0,m=m+Math.imul(be,it)|0,v=v+Math.imul(ce,Qe)|0,l=l+Math.imul(ce,lt)|0,l=l+Math.imul(de,Qe)|0,m=m+Math.imul(de,lt)|0,v=v+Math.imul(K,qe)|0,l=l+Math.imul(K,at)|0,l=l+Math.imul(le,qe)|0,m=m+Math.imul(le,at)|0;var xr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(xr>>>26)|0,xr&=67108863,v=Math.imul(ze,Ve),l=Math.imul(ze,Je),l=l+Math.imul(He,Ve)|0,m=Math.imul(He,Je),v=v+Math.imul(Oe,We)|0,l=l+Math.imul(Oe,it)|0,l=l+Math.imul($e,We)|0,m=m+Math.imul($e,it)|0,v=v+Math.imul(ye,Qe)|0,l=l+Math.imul(ye,lt)|0,l=l+Math.imul(be,Qe)|0,m=m+Math.imul(be,lt)|0,v=v+Math.imul(ce,qe)|0,l=l+Math.imul(ce,at)|0,l=l+Math.imul(de,qe)|0,m=m+Math.imul(de,at)|0;var Pr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Pr>>>26)|0,Pr&=67108863,v=Math.imul(ze,We),l=Math.imul(ze,it),l=l+Math.imul(He,We)|0,m=Math.imul(He,it),v=v+Math.imul(Oe,Qe)|0,l=l+Math.imul(Oe,lt)|0,l=l+Math.imul($e,Qe)|0,m=m+Math.imul($e,lt)|0,v=v+Math.imul(ye,qe)|0,l=l+Math.imul(ye,at)|0,l=l+Math.imul(be,qe)|0,m=m+Math.imul(be,at)|0;var Or=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Or>>>26)|0,Or&=67108863,v=Math.imul(ze,Qe),l=Math.imul(ze,lt),l=l+Math.imul(He,Qe)|0,m=Math.imul(He,lt),v=v+Math.imul(Oe,qe)|0,l=l+Math.imul(Oe,at)|0,l=l+Math.imul($e,qe)|0,m=m+Math.imul($e,at)|0;var kr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(kr>>>26)|0,kr&=67108863,v=Math.imul(ze,qe),l=Math.imul(ze,at),l=l+Math.imul(He,qe)|0,m=Math.imul(He,at);var rr=(E+v|0)+((l&8191)<<13)|0;return E=(m+(l>>>13)|0)+(rr>>>26)|0,rr&=67108863,x[0]=Bt,x[1]=Ot,x[2]=sr,x[3]=Ht,x[4]=hr,x[5]=pr,x[6]=_r,x[7]=Sr,x[8]=cr,x[9]=qt,x[10]=lr,x[11]=br,x[12]=Mr,x[13]=Er,x[14]=xr,x[15]=Pr,x[16]=Or,x[17]=kr,x[18]=rr,E!==0&&(x[19]=E,c.length++),c};Math.imul||(C=M);function O(b,o,u){u.negative=o.negative^b.negative,u.length=b.length+o.length;for(var c=0,h=0,g=0;g>>26)|0,h+=x>>>26,x&=67108863}u.words[g]=E,c=x,x=h}return c!==0?u.words[g]=c:u.length--,u.strip()}function T(b,o,u){var c=new k;return c.mulp(b,o,u)}a.prototype.mulTo=function(o,u){var c,h=this.length+o.length;return this.length===10&&o.length===10?c=C(this,o,u):h<63?c=M(this,o,u):h<1024?c=O(this,o,u):c=T(this,o,u),c};function k(b,o){this.x=b,this.y=o}k.prototype.makeRBT=function(o){for(var u=new Array(o),c=a.prototype._countBits(o)-1,h=0;h>=1;return h},k.prototype.permute=function(o,u,c,h,g,x){for(var E=0;E>>1)g++;return 1<>>13,c[2*x+1]=g&8191,g=g>>>13;for(x=2*u;x>=26,u+=h/67108864|0,u+=g>>>26,this.words[c]=g&67108863}return u!==0&&(this.words[c]=u,this.length++),this},a.prototype.muln=function(o){return this.clone().imuln(o)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(o){var u=S(o);if(u.length===0)return new a(1);for(var c=this,h=0;h=0);var u=o%26,c=(o-u)/26,h=67108863>>>26-u<<26-u,g;if(u!==0){var x=0;for(g=0;g>>26-u}x&&(this.words[g]=x,this.length++)}if(c!==0){for(g=this.length-1;g>=0;g--)this.words[g+c]=this.words[g];for(g=0;g=0);var h;u?h=(u-u%26)/26:h=0;var g=o%26,x=Math.min((o-g)/26,this.length),E=67108863^67108863>>>g<x)for(this.length-=x,l=0;l=0&&(m!==0||l>=h);l--){var P=this.words[l]|0;this.words[l]=m<<26-g|P>>>g,m=P&E}return v&&m!==0&&(v.words[v.length++]=m),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},a.prototype.ishrn=function(o,u,c){return n(this.negative===0),this.iushrn(o,u,c)},a.prototype.shln=function(o){return this.clone().ishln(o)},a.prototype.ushln=function(o){return this.clone().iushln(o)},a.prototype.shrn=function(o){return this.clone().ishrn(o)},a.prototype.ushrn=function(o){return this.clone().iushrn(o)},a.prototype.testn=function(o){n(typeof o=="number"&&o>=0);var u=o%26,c=(o-u)/26,h=1<=0);var u=o%26,c=(o-u)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=c)return this;if(u!==0&&c++,this.length=Math.min(c,this.length),u!==0){var h=67108863^67108863>>>u<=67108864;u++)this.words[u]-=67108864,u===this.length-1?this.words[u+1]=1:this.words[u+1]++;return this.length=Math.max(this.length,u+1),this},a.prototype.isubn=function(o){if(n(typeof o=="number"),n(o<67108864),o<0)return this.iaddn(-o);if(this.negative!==0)return this.negative=0,this.iaddn(o),this.negative=1,this;if(this.words[0]-=o,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var u=0;u>26)-(v/67108864|0),this.words[g+c]=x&67108863}for(;g>26,this.words[g+c]=x&67108863;if(E===0)return this.strip();for(n(E===-1),E=0,g=0;g>26,this.words[g]=x&67108863;return this.negative=1,this.strip()},a.prototype._wordDiv=function(o,u){var c=this.length-o.length,h=this.clone(),g=o,x=g.words[g.length-1]|0,E=this._countBits(x);c=26-E,c!==0&&(g=g.ushln(c),h.iushln(c),x=g.words[g.length-1]|0);var v=h.length-g.length,l;if(u!=="mod"){l=new a(null),l.length=v+1,l.words=new Array(l.length);for(var m=0;m=0;N--){var F=(h.words[g.length+N]|0)*67108864+(h.words[g.length+N-1]|0);for(F=Math.min(F/x|0,67108863),h._ishlnsubmul(g,F,N);h.negative!==0;)F--,h.negative=0,h._ishlnsubmul(g,1,N),h.isZero()||(h.negative^=1);l&&(l.words[N]=F)}return l&&l.strip(),h.strip(),u!=="div"&&c!==0&&h.iushrn(c),{div:l||null,mod:h}},a.prototype.divmod=function(o,u,c){if(n(!o.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var h,g,x;return this.negative!==0&&o.negative===0?(x=this.neg().divmod(o,u),u!=="mod"&&(h=x.div.neg()),u!=="div"&&(g=x.mod.neg(),c&&g.negative!==0&&g.iadd(o)),{div:h,mod:g}):this.negative===0&&o.negative!==0?(x=this.divmod(o.neg(),u),u!=="mod"&&(h=x.div.neg()),{div:h,mod:x.mod}):this.negative&o.negative?(x=this.neg().divmod(o.neg(),u),u!=="div"&&(g=x.mod.neg(),c&&g.negative!==0&&g.isub(o)),{div:x.div,mod:g}):o.length>this.length||this.cmp(o)<0?{div:new a(0),mod:this}:o.length===1?u==="div"?{div:this.divn(o.words[0]),mod:null}:u==="mod"?{div:null,mod:new a(this.modn(o.words[0]))}:{div:this.divn(o.words[0]),mod:new a(this.modn(o.words[0]))}:this._wordDiv(o,u)},a.prototype.div=function(o){return this.divmod(o,"div",!1).div},a.prototype.mod=function(o){return this.divmod(o,"mod",!1).mod},a.prototype.umod=function(o){return this.divmod(o,"mod",!0).mod},a.prototype.divRound=function(o){var u=this.divmod(o);if(u.mod.isZero())return u.div;var c=u.div.negative!==0?u.mod.isub(o):u.mod,h=o.ushrn(1),g=o.andln(1),x=c.cmp(h);return x<0||g===1&&x===0?u.div:u.div.negative!==0?u.div.isubn(1):u.div.iaddn(1)},a.prototype.modn=function(o){n(o<=67108863);for(var u=(1<<26)%o,c=0,h=this.length-1;h>=0;h--)c=(u*c+(this.words[h]|0))%o;return c},a.prototype.idivn=function(o){n(o<=67108863);for(var u=0,c=this.length-1;c>=0;c--){var h=(this.words[c]|0)+u*67108864;this.words[c]=h/o|0,u=h%o}return this.strip()},a.prototype.divn=function(o){return this.clone().idivn(o)},a.prototype.egcd=function(o){n(o.negative===0),n(!o.isZero());var u=this,c=o.clone();u.negative!==0?u=u.umod(o):u=u.clone();for(var h=new a(1),g=new a(0),x=new a(0),E=new a(1),v=0;u.isEven()&&c.isEven();)u.iushrn(1),c.iushrn(1),++v;for(var l=c.clone(),m=u.clone();!u.isZero();){for(var P=0,N=1;!(u.words[0]&N)&&P<26;++P,N<<=1);if(P>0)for(u.iushrn(P);P-- >0;)(h.isOdd()||g.isOdd())&&(h.iadd(l),g.isub(m)),h.iushrn(1),g.iushrn(1);for(var F=0,ee=1;!(c.words[0]&ee)&&F<26;++F,ee<<=1);if(F>0)for(c.iushrn(F);F-- >0;)(x.isOdd()||E.isOdd())&&(x.iadd(l),E.isub(m)),x.iushrn(1),E.iushrn(1);u.cmp(c)>=0?(u.isub(c),h.isub(x),g.isub(E)):(c.isub(u),x.isub(h),E.isub(g))}return{a:x,b:E,gcd:c.iushln(v)}},a.prototype._invmp=function(o){n(o.negative===0),n(!o.isZero());var u=this,c=o.clone();u.negative!==0?u=u.umod(o):u=u.clone();for(var h=new a(1),g=new a(0),x=c.clone();u.cmpn(1)>0&&c.cmpn(1)>0;){for(var E=0,v=1;!(u.words[0]&v)&&E<26;++E,v<<=1);if(E>0)for(u.iushrn(E);E-- >0;)h.isOdd()&&h.iadd(x),h.iushrn(1);for(var l=0,m=1;!(c.words[0]&m)&&l<26;++l,m<<=1);if(l>0)for(c.iushrn(l);l-- >0;)g.isOdd()&&g.iadd(x),g.iushrn(1);u.cmp(c)>=0?(u.isub(c),h.isub(g)):(c.isub(u),g.isub(h))}var P;return u.cmpn(1)===0?P=h:P=g,P.cmpn(0)<0&&P.iadd(o),P},a.prototype.gcd=function(o){if(this.isZero())return o.abs();if(o.isZero())return this.abs();var u=this.clone(),c=o.clone();u.negative=0,c.negative=0;for(var h=0;u.isEven()&&c.isEven();h++)u.iushrn(1),c.iushrn(1);do{for(;u.isEven();)u.iushrn(1);for(;c.isEven();)c.iushrn(1);var g=u.cmp(c);if(g<0){var x=u;u=c,c=x}else if(g===0||c.cmpn(1)===0)break;u.isub(c)}while(!0);return c.iushln(h)},a.prototype.invm=function(o){return this.egcd(o).a.umod(o)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(o){return this.words[0]&o},a.prototype.bincn=function(o){n(typeof o=="number");var u=o%26,c=(o-u)/26,h=1<>>26,E&=67108863,this.words[x]=E}return g!==0&&(this.words[x]=g,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(o){var u=o<0;if(this.negative!==0&&!u)return-1;if(this.negative===0&&u)return 1;this.strip();var c;if(this.length>1)c=1;else{u&&(o=-o),n(o<=67108863,"Number is too big");var h=this.words[0]|0;c=h===o?0:ho.length)return 1;if(this.length=0;c--){var h=this.words[c]|0,g=o.words[c]|0;if(h!==g){hg&&(u=1);break}}return u},a.prototype.gtn=function(o){return this.cmpn(o)===1},a.prototype.gt=function(o){return this.cmp(o)===1},a.prototype.gten=function(o){return this.cmpn(o)>=0},a.prototype.gte=function(o){return this.cmp(o)>=0},a.prototype.ltn=function(o){return this.cmpn(o)===-1},a.prototype.lt=function(o){return this.cmp(o)===-1},a.prototype.lten=function(o){return this.cmpn(o)<=0},a.prototype.lte=function(o){return this.cmp(o)<=0},a.prototype.eqn=function(o){return this.cmpn(o)===0},a.prototype.eq=function(o){return this.cmp(o)===0},a.red=function(o){return new z(o)},a.prototype.toRed=function(o){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),o.convertTo(this)._forceRed(o)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(o){return this.red=o,this},a.prototype.forceRed=function(o){return n(!this.red,"Already a number in reduction context"),this._forceRed(o)},a.prototype.redAdd=function(o){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,o)},a.prototype.redIAdd=function(o){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,o)},a.prototype.redSub=function(o){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,o)},a.prototype.redISub=function(o){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,o)},a.prototype.redShl=function(o){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,o)},a.prototype.redMul=function(o){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,o),this.red.mul(this,o)},a.prototype.redIMul=function(o){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,o),this.red.imul(this,o)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(o){return n(this.red&&!o.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,o)};var R={k256:null,p224:null,p192:null,p25519:null};function $(b,o){this.name=b,this.p=new a(o,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}$.prototype._tmp=function(){var o=new a(null);return o.words=new Array(Math.ceil(this.n/13)),o},$.prototype.ireduce=function(o){var u=o,c;do this.split(u,this.tmp),u=this.imulK(u),u=u.iadd(this.tmp),c=u.bitLength();while(c>this.n);var h=c0?u.isub(this.p):u.strip!==void 0?u.strip():u._strip(),u},$.prototype.split=function(o,u){o.iushrn(this.n,0,u)},$.prototype.imulK=function(o){return o.imul(this.k)};function L(){$.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}i(L,$),L.prototype.split=function(o,u){for(var c=4194303,h=Math.min(o.length,9),g=0;g>>22,x=E}x>>>=22,o.words[g-10]=x,x===0&&o.length>10?o.length-=10:o.length-=9},L.prototype.imulK=function(o){o.words[o.length]=0,o.words[o.length+1]=0,o.length+=2;for(var u=0,c=0;c>>=26,o.words[c]=g,u=h}return u!==0&&(o.words[o.length++]=u),o},a._prime=function(o){if(R[o])return R[o];var u;if(o==="k256")u=new L;else if(o==="p224")u=new j;else if(o==="p192")u=new A;else if(o==="p25519")u=new V;else throw new Error("Unknown prime "+o);return R[o]=u,u};function z(b){if(typeof b=="string"){var o=a._prime(b);this.m=o.p,this.prime=o}else n(b.gtn(1),"modulus must be greater than 1"),this.m=b,this.prime=null}z.prototype._verify1=function(o){n(o.negative===0,"red works only with positives"),n(o.red,"red works only with red numbers")},z.prototype._verify2=function(o,u){n((o.negative|u.negative)===0,"red works only with positives"),n(o.red&&o.red===u.red,"red works only with red numbers")},z.prototype.imod=function(o){return this.prime?this.prime.ireduce(o)._forceRed(this):o.umod(this.m)._forceRed(this)},z.prototype.neg=function(o){return o.isZero()?o.clone():this.m.sub(o)._forceRed(this)},z.prototype.add=function(o,u){this._verify2(o,u);var c=o.add(u);return c.cmp(this.m)>=0&&c.isub(this.m),c._forceRed(this)},z.prototype.iadd=function(o,u){this._verify2(o,u);var c=o.iadd(u);return c.cmp(this.m)>=0&&c.isub(this.m),c},z.prototype.sub=function(o,u){this._verify2(o,u);var c=o.sub(u);return c.cmpn(0)<0&&c.iadd(this.m),c._forceRed(this)},z.prototype.isub=function(o,u){this._verify2(o,u);var c=o.isub(u);return c.cmpn(0)<0&&c.iadd(this.m),c},z.prototype.shl=function(o,u){return this._verify1(o),this.imod(o.ushln(u))},z.prototype.imul=function(o,u){return this._verify2(o,u),this.imod(o.imul(u))},z.prototype.mul=function(o,u){return this._verify2(o,u),this.imod(o.mul(u))},z.prototype.isqr=function(o){return this.imul(o,o.clone())},z.prototype.sqr=function(o){return this.mul(o,o)},z.prototype.sqrt=function(o){if(o.isZero())return o.clone();var u=this.m.andln(3);if(n(u%2===1),u===3){var c=this.m.add(new a(1)).iushrn(2);return this.pow(o,c)}for(var h=this.m.subn(1),g=0;!h.isZero()&&h.andln(1)===0;)g++,h.iushrn(1);n(!h.isZero());var x=new a(1).toRed(this),E=x.redNeg(),v=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new a(2*l*l).toRed(this);this.pow(l,v).cmp(E)!==0;)l.redIAdd(E);for(var m=this.pow(l,h),P=this.pow(o,h.addn(1).iushrn(1)),N=this.pow(o,h),F=g;N.cmp(x)!==0;){for(var ee=N,q=0;ee.cmp(x)!==0;q++)ee=ee.redSqr();n(q=0;g--){for(var m=u.words[g],P=l-1;P>=0;P--){var N=m>>P&1;if(x!==h[0]&&(x=this.sqr(x)),N===0&&E===0){v=0;continue}E<<=1,E|=N,v++,!(v!==c&&(g!==0||P!==0))&&(x=this.mul(x,h[E]),v=0,E=0)}l=26}return x},z.prototype.convertTo=function(o){var u=o.umod(this.m);return u===o?u.clone():u},z.prototype.convertFrom=function(o){var u=o.clone();return u.red=null,u},a.mont=function(o){return new Y(o)};function Y(b){z.call(this,b),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}i(Y,z),Y.prototype.convertTo=function(o){return this.imod(o.ushln(this.shift))},Y.prototype.convertFrom=function(o){var u=this.imod(o.mul(this.rinv));return u.red=null,u},Y.prototype.imul=function(o,u){if(o.isZero()||u.isZero())return o.words[0]=0,o.length=1,o;var c=o.imul(u),h=c.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),g=c.isub(h).iushrn(this.shift),x=g;return g.cmp(this.m)>=0?x=g.isub(this.m):g.cmpn(0)<0&&(x=g.iadd(this.m)),x._forceRed(this)},Y.prototype.mul=function(o,u){if(o.isZero()||u.isZero())return new a(0)._forceRed(this);var c=o.mul(u),h=c.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),g=c.isub(h).iushrn(this.shift),x=g;return g.cmp(this.m)>=0?x=g.isub(this.m):g.cmpn(0)<0&&(x=g.iadd(this.m)),x._forceRed(this)},Y.prototype.invm=function(o){var u=this.imod(o._invmp(this.m).mul(this.r2));return u._forceRed(this)}})(e,Ut)})(U5);var Dne=U5.exports,Z2,HT;function $ne(){if(HT)return Z2;HT=1;var e=P5(),t=Dne;Z2=function(s){return new n(s)};var r={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};r.p224=r.secp224r1,r.p256=r.secp256r1=r.prime256v1,r.p192=r.secp192r1=r.prime192v1,r.p384=r.secp384r1,r.p521=r.secp521r1;function n(a){this.curveType=r[a],this.curveType||(this.curveType={name:a}),this.curve=new e.ec(this.curveType.name),this.keys=void 0}n.prototype.generateKeys=function(a,s){return this.keys=this.curve.genKeyPair(),this.getPublicKey(a,s)},n.prototype.computeSecret=function(a,s,f){s=s||"utf8",rt.isBuffer(a)||(a=new rt(a,s));var d=this.curve.keyFromPublic(a).getPublic(),p=d.mul(this.keys.getPrivate()).getX();return i(p,f,this.curveType.byteLength)},n.prototype.getPublicKey=function(a,s){var f=this.keys.getPublic(s==="compressed",!0);return s==="hybrid"&&(f[f.length-1]%2?f[0]=7:f[0]=6),i(f,a)},n.prototype.getPrivateKey=function(a){return i(this.keys.getPrivate(),a)},n.prototype.setPublicKey=function(a,s){return s=s||"utf8",rt.isBuffer(a)||(a=new rt(a,s)),this.keys._importPublic(a),this},n.prototype.setPrivateKey=function(a,s){s=s||"utf8",rt.isBuffer(a)||(a=new rt(a,s));var f=new t(a);return f=f.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(f),this};function i(a,s,f){Array.isArray(a)||(a=a.toArray());var d=new rt(a);if(f&&d.length0?o:u},a.min=function(o,u){return o.cmp(u)<0?o:u},a.prototype._init=function(o,u,c){if(typeof o=="number")return this._initNumber(o,u,c);if(typeof o=="object")return this._initArray(o,u,c);u==="hex"&&(u=16),n(u===(u|0)&&u>=2&&u<=36),o=o.toString().replace(/\s+/g,"");var h=0;o[0]==="-"&&(h++,this.negative=1),h=0;h-=3)x=o[h]|o[h-1]<<8|o[h-2]<<16,this.words[g]|=x<>>26-E&67108863,E+=24,E>=26&&(E-=26,g++);else if(c==="le")for(h=0,g=0;h>>26-E&67108863,E+=24,E>=26&&(E-=26,g++);return this.strip()};function f(b,o){var u=b.charCodeAt(o);return u>=65&&u<=70?u-55:u>=97&&u<=102?u-87:u-48&15}function d(b,o,u){var c=f(b,u);return u-1>=o&&(c|=f(b,u-1)<<4),c}a.prototype._parseHex=function(o,u,c){this.length=Math.ceil((o.length-u)/6),this.words=new Array(this.length);for(var h=0;h=u;h-=2)E=d(o,u,h)<=18?(g-=18,x+=1,this.words[x]|=E>>>26):g+=8;else{var v=o.length-u;for(h=v%2===0?u+1:u;h=18?(g-=18,x+=1,this.words[x]|=E>>>26):g+=8}this.strip()};function p(b,o,u,c){for(var h=0,g=Math.min(b.length,u),x=o;x=49?h+=E-49+10:E>=17?h+=E-17+10:h+=E}return h}a.prototype._parseBase=function(o,u,c){this.words=[0],this.length=1;for(var h=0,g=1;g<=67108863;g*=u)h++;h--,g=g/u|0;for(var x=o.length-c,E=x%h,v=Math.min(x,x-E)+c,l=0,m=c;m1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},a.prototype.inspect=function(){return(this.red?""};var y=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],w=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],_=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(o,u){o=o||10,u=u|0||1;var c;if(o===16||o==="hex"){c="";for(var h=0,g=0,x=0;x>>24-h&16777215,g!==0||x!==this.length-1?c=y[6-v.length]+v+c:c=v+c,h+=2,h>=26&&(h-=26,x--)}for(g!==0&&(c=g.toString(16)+c);c.length%u!==0;)c="0"+c;return this.negative!==0&&(c="-"+c),c}if(o===(o|0)&&o>=2&&o<=36){var l=w[o],m=_[o];c="";var P=this.clone();for(P.negative=0;!P.isZero();){var N=P.modn(m).toString(o);P=P.idivn(m),P.isZero()?c=N+c:c=y[l-N.length]+N+c}for(this.isZero()&&(c="0"+c);c.length%u!==0;)c="0"+c;return this.negative!==0&&(c="-"+c),c}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var o=this.words[0];return this.length===2?o+=this.words[1]*67108864:this.length===3&&this.words[2]===1?o+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-o:o},a.prototype.toJSON=function(){return this.toString(16)},a.prototype.toBuffer=function(o,u){return n(typeof s<"u"),this.toArrayLike(s,o,u)},a.prototype.toArray=function(o,u){return this.toArrayLike(Array,o,u)},a.prototype.toArrayLike=function(o,u,c){var h=this.byteLength(),g=c||Math.max(1,h);n(h<=g,"byte array longer than desired length"),n(g>0,"Requested array length <= 0"),this.strip();var x=u==="le",E=new o(g),v,l,m=this.clone();if(x){for(l=0;!m.isZero();l++)v=m.andln(255),m.iushrn(8),E[l]=v;for(;l=4096&&(c+=13,u>>>=13),u>=64&&(c+=7,u>>>=7),u>=8&&(c+=4,u>>>=4),u>=2&&(c+=2,u>>>=2),c+u},a.prototype._zeroBits=function(o){if(o===0)return 26;var u=o,c=0;return u&8191||(c+=13,u>>>=13),u&127||(c+=7,u>>>=7),u&15||(c+=4,u>>>=4),u&3||(c+=2,u>>>=2),u&1||c++,c},a.prototype.bitLength=function(){var o=this.words[this.length-1],u=this._countBits(o);return(this.length-1)*26+u};function S(b){for(var o=new Array(b.bitLength()),u=0;u>>h}return o}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var o=0,u=0;uo.length?this.clone().ior(o):o.clone().ior(this)},a.prototype.uor=function(o){return this.length>o.length?this.clone().iuor(o):o.clone().iuor(this)},a.prototype.iuand=function(o){var u;this.length>o.length?u=o:u=this;for(var c=0;co.length?this.clone().iand(o):o.clone().iand(this)},a.prototype.uand=function(o){return this.length>o.length?this.clone().iuand(o):o.clone().iuand(this)},a.prototype.iuxor=function(o){var u,c;this.length>o.length?(u=this,c=o):(u=o,c=this);for(var h=0;ho.length?this.clone().ixor(o):o.clone().ixor(this)},a.prototype.uxor=function(o){return this.length>o.length?this.clone().iuxor(o):o.clone().iuxor(this)},a.prototype.inotn=function(o){n(typeof o=="number"&&o>=0);var u=Math.ceil(o/26)|0,c=o%26;this._expand(u),c>0&&u--;for(var h=0;h0&&(this.words[h]=~this.words[h]&67108863>>26-c),this.strip()},a.prototype.notn=function(o){return this.clone().inotn(o)},a.prototype.setn=function(o,u){n(typeof o=="number"&&o>=0);var c=o/26|0,h=o%26;return this._expand(c+1),u?this.words[c]=this.words[c]|1<o.length?(c=this,h=o):(c=o,h=this);for(var g=0,x=0;x>>26;for(;g!==0&&x>>26;if(this.length=c.length,g!==0)this.words[this.length]=g,this.length++;else if(c!==this)for(;xo.length?this.clone().iadd(o):o.clone().iadd(this)},a.prototype.isub=function(o){if(o.negative!==0){o.negative=0;var u=this.iadd(o);return o.negative=1,u._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(o),this.negative=1,this._normSign();var c=this.cmp(o);if(c===0)return this.negative=0,this.length=1,this.words[0]=0,this;var h,g;c>0?(h=this,g=o):(h=o,g=this);for(var x=0,E=0;E>26,this.words[E]=u&67108863;for(;x!==0&&E>26,this.words[E]=u&67108863;if(x===0&&E>>26,P=v&67108863,N=Math.min(l,o.length-1),F=Math.max(0,l-b.length+1);F<=N;F++){var ee=l-F|0;h=b.words[ee]|0,g=o.words[F]|0,x=h*g+P,m+=x/67108864|0,P=x&67108863}u.words[l]=P|0,v=m|0}return v!==0?u.words[l]=v|0:u.length--,u.strip()}var C=function(o,u,c){var h=o.words,g=u.words,x=c.words,E=0,v,l,m,P=h[0]|0,N=P&8191,F=P>>>13,ee=h[1]|0,q=ee&8191,ae=ee>>>13,pe=h[2]|0,we=pe&8191,Se=pe>>>13,he=h[3]|0,re=he&8191,_e=he>>>13,W=h[4]|0,ve=W&8191,Z=W>>>13,ne=h[5]|0,K=ne&8191,le=ne>>>13,xe=h[6]|0,ce=xe&8191,de=xe>>>13,Ae=h[7]|0,ye=Ae&8191,be=Ae>>>13,tt=h[8]|0,Oe=tt&8191,$e=tt>>>13,Et=h[9]|0,ze=Et&8191,He=Et>>>13,Fe=g[0]|0,Te=Fe&8191,Pe=Fe>>>13,pt=g[1]|0,De=pt&8191,je=pt>>>13,bt=g[2]|0,Le=bt&8191,Ge=bt>>>13,Ct=g[3]|0,Be=Ct&8191,Ye=Ct>>>13,Pt=g[4]|0,Ue=Pt&8191,et=Pt>>>13,Vt=g[5]|0,Xe=Vt&8191,ot=Vt>>>13,Kt=g[6]|0,Ve=Kt&8191,Je=Kt>>>13,It=g[7]|0,We=It&8191,it=It>>>13,jt=g[8]|0,Qe=jt&8191,lt=jt>>>13,Xt=g[9]|0,qe=Xt&8191,at=Xt>>>13;c.negative=o.negative^u.negative,c.length=19,v=Math.imul(N,Te),l=Math.imul(N,Pe),l=l+Math.imul(F,Te)|0,m=Math.imul(F,Pe);var Bt=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,v=Math.imul(q,Te),l=Math.imul(q,Pe),l=l+Math.imul(ae,Te)|0,m=Math.imul(ae,Pe),v=v+Math.imul(N,De)|0,l=l+Math.imul(N,je)|0,l=l+Math.imul(F,De)|0,m=m+Math.imul(F,je)|0;var Ot=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,v=Math.imul(we,Te),l=Math.imul(we,Pe),l=l+Math.imul(Se,Te)|0,m=Math.imul(Se,Pe),v=v+Math.imul(q,De)|0,l=l+Math.imul(q,je)|0,l=l+Math.imul(ae,De)|0,m=m+Math.imul(ae,je)|0,v=v+Math.imul(N,Le)|0,l=l+Math.imul(N,Ge)|0,l=l+Math.imul(F,Le)|0,m=m+Math.imul(F,Ge)|0;var sr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(sr>>>26)|0,sr&=67108863,v=Math.imul(re,Te),l=Math.imul(re,Pe),l=l+Math.imul(_e,Te)|0,m=Math.imul(_e,Pe),v=v+Math.imul(we,De)|0,l=l+Math.imul(we,je)|0,l=l+Math.imul(Se,De)|0,m=m+Math.imul(Se,je)|0,v=v+Math.imul(q,Le)|0,l=l+Math.imul(q,Ge)|0,l=l+Math.imul(ae,Le)|0,m=m+Math.imul(ae,Ge)|0,v=v+Math.imul(N,Be)|0,l=l+Math.imul(N,Ye)|0,l=l+Math.imul(F,Be)|0,m=m+Math.imul(F,Ye)|0;var Ht=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Ht>>>26)|0,Ht&=67108863,v=Math.imul(ve,Te),l=Math.imul(ve,Pe),l=l+Math.imul(Z,Te)|0,m=Math.imul(Z,Pe),v=v+Math.imul(re,De)|0,l=l+Math.imul(re,je)|0,l=l+Math.imul(_e,De)|0,m=m+Math.imul(_e,je)|0,v=v+Math.imul(we,Le)|0,l=l+Math.imul(we,Ge)|0,l=l+Math.imul(Se,Le)|0,m=m+Math.imul(Se,Ge)|0,v=v+Math.imul(q,Be)|0,l=l+Math.imul(q,Ye)|0,l=l+Math.imul(ae,Be)|0,m=m+Math.imul(ae,Ye)|0,v=v+Math.imul(N,Ue)|0,l=l+Math.imul(N,et)|0,l=l+Math.imul(F,Ue)|0,m=m+Math.imul(F,et)|0;var hr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(hr>>>26)|0,hr&=67108863,v=Math.imul(K,Te),l=Math.imul(K,Pe),l=l+Math.imul(le,Te)|0,m=Math.imul(le,Pe),v=v+Math.imul(ve,De)|0,l=l+Math.imul(ve,je)|0,l=l+Math.imul(Z,De)|0,m=m+Math.imul(Z,je)|0,v=v+Math.imul(re,Le)|0,l=l+Math.imul(re,Ge)|0,l=l+Math.imul(_e,Le)|0,m=m+Math.imul(_e,Ge)|0,v=v+Math.imul(we,Be)|0,l=l+Math.imul(we,Ye)|0,l=l+Math.imul(Se,Be)|0,m=m+Math.imul(Se,Ye)|0,v=v+Math.imul(q,Ue)|0,l=l+Math.imul(q,et)|0,l=l+Math.imul(ae,Ue)|0,m=m+Math.imul(ae,et)|0,v=v+Math.imul(N,Xe)|0,l=l+Math.imul(N,ot)|0,l=l+Math.imul(F,Xe)|0,m=m+Math.imul(F,ot)|0;var pr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(pr>>>26)|0,pr&=67108863,v=Math.imul(ce,Te),l=Math.imul(ce,Pe),l=l+Math.imul(de,Te)|0,m=Math.imul(de,Pe),v=v+Math.imul(K,De)|0,l=l+Math.imul(K,je)|0,l=l+Math.imul(le,De)|0,m=m+Math.imul(le,je)|0,v=v+Math.imul(ve,Le)|0,l=l+Math.imul(ve,Ge)|0,l=l+Math.imul(Z,Le)|0,m=m+Math.imul(Z,Ge)|0,v=v+Math.imul(re,Be)|0,l=l+Math.imul(re,Ye)|0,l=l+Math.imul(_e,Be)|0,m=m+Math.imul(_e,Ye)|0,v=v+Math.imul(we,Ue)|0,l=l+Math.imul(we,et)|0,l=l+Math.imul(Se,Ue)|0,m=m+Math.imul(Se,et)|0,v=v+Math.imul(q,Xe)|0,l=l+Math.imul(q,ot)|0,l=l+Math.imul(ae,Xe)|0,m=m+Math.imul(ae,ot)|0,v=v+Math.imul(N,Ve)|0,l=l+Math.imul(N,Je)|0,l=l+Math.imul(F,Ve)|0,m=m+Math.imul(F,Je)|0;var _r=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(_r>>>26)|0,_r&=67108863,v=Math.imul(ye,Te),l=Math.imul(ye,Pe),l=l+Math.imul(be,Te)|0,m=Math.imul(be,Pe),v=v+Math.imul(ce,De)|0,l=l+Math.imul(ce,je)|0,l=l+Math.imul(de,De)|0,m=m+Math.imul(de,je)|0,v=v+Math.imul(K,Le)|0,l=l+Math.imul(K,Ge)|0,l=l+Math.imul(le,Le)|0,m=m+Math.imul(le,Ge)|0,v=v+Math.imul(ve,Be)|0,l=l+Math.imul(ve,Ye)|0,l=l+Math.imul(Z,Be)|0,m=m+Math.imul(Z,Ye)|0,v=v+Math.imul(re,Ue)|0,l=l+Math.imul(re,et)|0,l=l+Math.imul(_e,Ue)|0,m=m+Math.imul(_e,et)|0,v=v+Math.imul(we,Xe)|0,l=l+Math.imul(we,ot)|0,l=l+Math.imul(Se,Xe)|0,m=m+Math.imul(Se,ot)|0,v=v+Math.imul(q,Ve)|0,l=l+Math.imul(q,Je)|0,l=l+Math.imul(ae,Ve)|0,m=m+Math.imul(ae,Je)|0,v=v+Math.imul(N,We)|0,l=l+Math.imul(N,it)|0,l=l+Math.imul(F,We)|0,m=m+Math.imul(F,it)|0;var Sr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Sr>>>26)|0,Sr&=67108863,v=Math.imul(Oe,Te),l=Math.imul(Oe,Pe),l=l+Math.imul($e,Te)|0,m=Math.imul($e,Pe),v=v+Math.imul(ye,De)|0,l=l+Math.imul(ye,je)|0,l=l+Math.imul(be,De)|0,m=m+Math.imul(be,je)|0,v=v+Math.imul(ce,Le)|0,l=l+Math.imul(ce,Ge)|0,l=l+Math.imul(de,Le)|0,m=m+Math.imul(de,Ge)|0,v=v+Math.imul(K,Be)|0,l=l+Math.imul(K,Ye)|0,l=l+Math.imul(le,Be)|0,m=m+Math.imul(le,Ye)|0,v=v+Math.imul(ve,Ue)|0,l=l+Math.imul(ve,et)|0,l=l+Math.imul(Z,Ue)|0,m=m+Math.imul(Z,et)|0,v=v+Math.imul(re,Xe)|0,l=l+Math.imul(re,ot)|0,l=l+Math.imul(_e,Xe)|0,m=m+Math.imul(_e,ot)|0,v=v+Math.imul(we,Ve)|0,l=l+Math.imul(we,Je)|0,l=l+Math.imul(Se,Ve)|0,m=m+Math.imul(Se,Je)|0,v=v+Math.imul(q,We)|0,l=l+Math.imul(q,it)|0,l=l+Math.imul(ae,We)|0,m=m+Math.imul(ae,it)|0,v=v+Math.imul(N,Qe)|0,l=l+Math.imul(N,lt)|0,l=l+Math.imul(F,Qe)|0,m=m+Math.imul(F,lt)|0;var cr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(cr>>>26)|0,cr&=67108863,v=Math.imul(ze,Te),l=Math.imul(ze,Pe),l=l+Math.imul(He,Te)|0,m=Math.imul(He,Pe),v=v+Math.imul(Oe,De)|0,l=l+Math.imul(Oe,je)|0,l=l+Math.imul($e,De)|0,m=m+Math.imul($e,je)|0,v=v+Math.imul(ye,Le)|0,l=l+Math.imul(ye,Ge)|0,l=l+Math.imul(be,Le)|0,m=m+Math.imul(be,Ge)|0,v=v+Math.imul(ce,Be)|0,l=l+Math.imul(ce,Ye)|0,l=l+Math.imul(de,Be)|0,m=m+Math.imul(de,Ye)|0,v=v+Math.imul(K,Ue)|0,l=l+Math.imul(K,et)|0,l=l+Math.imul(le,Ue)|0,m=m+Math.imul(le,et)|0,v=v+Math.imul(ve,Xe)|0,l=l+Math.imul(ve,ot)|0,l=l+Math.imul(Z,Xe)|0,m=m+Math.imul(Z,ot)|0,v=v+Math.imul(re,Ve)|0,l=l+Math.imul(re,Je)|0,l=l+Math.imul(_e,Ve)|0,m=m+Math.imul(_e,Je)|0,v=v+Math.imul(we,We)|0,l=l+Math.imul(we,it)|0,l=l+Math.imul(Se,We)|0,m=m+Math.imul(Se,it)|0,v=v+Math.imul(q,Qe)|0,l=l+Math.imul(q,lt)|0,l=l+Math.imul(ae,Qe)|0,m=m+Math.imul(ae,lt)|0,v=v+Math.imul(N,qe)|0,l=l+Math.imul(N,at)|0,l=l+Math.imul(F,qe)|0,m=m+Math.imul(F,at)|0;var qt=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(qt>>>26)|0,qt&=67108863,v=Math.imul(ze,De),l=Math.imul(ze,je),l=l+Math.imul(He,De)|0,m=Math.imul(He,je),v=v+Math.imul(Oe,Le)|0,l=l+Math.imul(Oe,Ge)|0,l=l+Math.imul($e,Le)|0,m=m+Math.imul($e,Ge)|0,v=v+Math.imul(ye,Be)|0,l=l+Math.imul(ye,Ye)|0,l=l+Math.imul(be,Be)|0,m=m+Math.imul(be,Ye)|0,v=v+Math.imul(ce,Ue)|0,l=l+Math.imul(ce,et)|0,l=l+Math.imul(de,Ue)|0,m=m+Math.imul(de,et)|0,v=v+Math.imul(K,Xe)|0,l=l+Math.imul(K,ot)|0,l=l+Math.imul(le,Xe)|0,m=m+Math.imul(le,ot)|0,v=v+Math.imul(ve,Ve)|0,l=l+Math.imul(ve,Je)|0,l=l+Math.imul(Z,Ve)|0,m=m+Math.imul(Z,Je)|0,v=v+Math.imul(re,We)|0,l=l+Math.imul(re,it)|0,l=l+Math.imul(_e,We)|0,m=m+Math.imul(_e,it)|0,v=v+Math.imul(we,Qe)|0,l=l+Math.imul(we,lt)|0,l=l+Math.imul(Se,Qe)|0,m=m+Math.imul(Se,lt)|0,v=v+Math.imul(q,qe)|0,l=l+Math.imul(q,at)|0,l=l+Math.imul(ae,qe)|0,m=m+Math.imul(ae,at)|0;var lr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(lr>>>26)|0,lr&=67108863,v=Math.imul(ze,Le),l=Math.imul(ze,Ge),l=l+Math.imul(He,Le)|0,m=Math.imul(He,Ge),v=v+Math.imul(Oe,Be)|0,l=l+Math.imul(Oe,Ye)|0,l=l+Math.imul($e,Be)|0,m=m+Math.imul($e,Ye)|0,v=v+Math.imul(ye,Ue)|0,l=l+Math.imul(ye,et)|0,l=l+Math.imul(be,Ue)|0,m=m+Math.imul(be,et)|0,v=v+Math.imul(ce,Xe)|0,l=l+Math.imul(ce,ot)|0,l=l+Math.imul(de,Xe)|0,m=m+Math.imul(de,ot)|0,v=v+Math.imul(K,Ve)|0,l=l+Math.imul(K,Je)|0,l=l+Math.imul(le,Ve)|0,m=m+Math.imul(le,Je)|0,v=v+Math.imul(ve,We)|0,l=l+Math.imul(ve,it)|0,l=l+Math.imul(Z,We)|0,m=m+Math.imul(Z,it)|0,v=v+Math.imul(re,Qe)|0,l=l+Math.imul(re,lt)|0,l=l+Math.imul(_e,Qe)|0,m=m+Math.imul(_e,lt)|0,v=v+Math.imul(we,qe)|0,l=l+Math.imul(we,at)|0,l=l+Math.imul(Se,qe)|0,m=m+Math.imul(Se,at)|0;var br=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(br>>>26)|0,br&=67108863,v=Math.imul(ze,Be),l=Math.imul(ze,Ye),l=l+Math.imul(He,Be)|0,m=Math.imul(He,Ye),v=v+Math.imul(Oe,Ue)|0,l=l+Math.imul(Oe,et)|0,l=l+Math.imul($e,Ue)|0,m=m+Math.imul($e,et)|0,v=v+Math.imul(ye,Xe)|0,l=l+Math.imul(ye,ot)|0,l=l+Math.imul(be,Xe)|0,m=m+Math.imul(be,ot)|0,v=v+Math.imul(ce,Ve)|0,l=l+Math.imul(ce,Je)|0,l=l+Math.imul(de,Ve)|0,m=m+Math.imul(de,Je)|0,v=v+Math.imul(K,We)|0,l=l+Math.imul(K,it)|0,l=l+Math.imul(le,We)|0,m=m+Math.imul(le,it)|0,v=v+Math.imul(ve,Qe)|0,l=l+Math.imul(ve,lt)|0,l=l+Math.imul(Z,Qe)|0,m=m+Math.imul(Z,lt)|0,v=v+Math.imul(re,qe)|0,l=l+Math.imul(re,at)|0,l=l+Math.imul(_e,qe)|0,m=m+Math.imul(_e,at)|0;var Mr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Mr>>>26)|0,Mr&=67108863,v=Math.imul(ze,Ue),l=Math.imul(ze,et),l=l+Math.imul(He,Ue)|0,m=Math.imul(He,et),v=v+Math.imul(Oe,Xe)|0,l=l+Math.imul(Oe,ot)|0,l=l+Math.imul($e,Xe)|0,m=m+Math.imul($e,ot)|0,v=v+Math.imul(ye,Ve)|0,l=l+Math.imul(ye,Je)|0,l=l+Math.imul(be,Ve)|0,m=m+Math.imul(be,Je)|0,v=v+Math.imul(ce,We)|0,l=l+Math.imul(ce,it)|0,l=l+Math.imul(de,We)|0,m=m+Math.imul(de,it)|0,v=v+Math.imul(K,Qe)|0,l=l+Math.imul(K,lt)|0,l=l+Math.imul(le,Qe)|0,m=m+Math.imul(le,lt)|0,v=v+Math.imul(ve,qe)|0,l=l+Math.imul(ve,at)|0,l=l+Math.imul(Z,qe)|0,m=m+Math.imul(Z,at)|0;var Er=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Er>>>26)|0,Er&=67108863,v=Math.imul(ze,Xe),l=Math.imul(ze,ot),l=l+Math.imul(He,Xe)|0,m=Math.imul(He,ot),v=v+Math.imul(Oe,Ve)|0,l=l+Math.imul(Oe,Je)|0,l=l+Math.imul($e,Ve)|0,m=m+Math.imul($e,Je)|0,v=v+Math.imul(ye,We)|0,l=l+Math.imul(ye,it)|0,l=l+Math.imul(be,We)|0,m=m+Math.imul(be,it)|0,v=v+Math.imul(ce,Qe)|0,l=l+Math.imul(ce,lt)|0,l=l+Math.imul(de,Qe)|0,m=m+Math.imul(de,lt)|0,v=v+Math.imul(K,qe)|0,l=l+Math.imul(K,at)|0,l=l+Math.imul(le,qe)|0,m=m+Math.imul(le,at)|0;var xr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(xr>>>26)|0,xr&=67108863,v=Math.imul(ze,Ve),l=Math.imul(ze,Je),l=l+Math.imul(He,Ve)|0,m=Math.imul(He,Je),v=v+Math.imul(Oe,We)|0,l=l+Math.imul(Oe,it)|0,l=l+Math.imul($e,We)|0,m=m+Math.imul($e,it)|0,v=v+Math.imul(ye,Qe)|0,l=l+Math.imul(ye,lt)|0,l=l+Math.imul(be,Qe)|0,m=m+Math.imul(be,lt)|0,v=v+Math.imul(ce,qe)|0,l=l+Math.imul(ce,at)|0,l=l+Math.imul(de,qe)|0,m=m+Math.imul(de,at)|0;var Pr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Pr>>>26)|0,Pr&=67108863,v=Math.imul(ze,We),l=Math.imul(ze,it),l=l+Math.imul(He,We)|0,m=Math.imul(He,it),v=v+Math.imul(Oe,Qe)|0,l=l+Math.imul(Oe,lt)|0,l=l+Math.imul($e,Qe)|0,m=m+Math.imul($e,lt)|0,v=v+Math.imul(ye,qe)|0,l=l+Math.imul(ye,at)|0,l=l+Math.imul(be,qe)|0,m=m+Math.imul(be,at)|0;var Or=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(Or>>>26)|0,Or&=67108863,v=Math.imul(ze,Qe),l=Math.imul(ze,lt),l=l+Math.imul(He,Qe)|0,m=Math.imul(He,lt),v=v+Math.imul(Oe,qe)|0,l=l+Math.imul(Oe,at)|0,l=l+Math.imul($e,qe)|0,m=m+Math.imul($e,at)|0;var kr=(E+v|0)+((l&8191)<<13)|0;E=(m+(l>>>13)|0)+(kr>>>26)|0,kr&=67108863,v=Math.imul(ze,qe),l=Math.imul(ze,at),l=l+Math.imul(He,qe)|0,m=Math.imul(He,at);var rr=(E+v|0)+((l&8191)<<13)|0;return E=(m+(l>>>13)|0)+(rr>>>26)|0,rr&=67108863,x[0]=Bt,x[1]=Ot,x[2]=sr,x[3]=Ht,x[4]=hr,x[5]=pr,x[6]=_r,x[7]=Sr,x[8]=cr,x[9]=qt,x[10]=lr,x[11]=br,x[12]=Mr,x[13]=Er,x[14]=xr,x[15]=Pr,x[16]=Or,x[17]=kr,x[18]=rr,E!==0&&(x[19]=E,c.length++),c};Math.imul||(C=M);function O(b,o,u){u.negative=o.negative^b.negative,u.length=b.length+o.length;for(var c=0,h=0,g=0;g>>26)|0,h+=x>>>26,x&=67108863}u.words[g]=E,c=x,x=h}return c!==0?u.words[g]=c:u.length--,u.strip()}function T(b,o,u){var c=new k;return c.mulp(b,o,u)}a.prototype.mulTo=function(o,u){var c,h=this.length+o.length;return this.length===10&&o.length===10?c=C(this,o,u):h<63?c=M(this,o,u):h<1024?c=O(this,o,u):c=T(this,o,u),c};function k(b,o){this.x=b,this.y=o}k.prototype.makeRBT=function(o){for(var u=new Array(o),c=a.prototype._countBits(o)-1,h=0;h>=1;return h},k.prototype.permute=function(o,u,c,h,g,x){for(var E=0;E>>1)g++;return 1<>>13,c[2*x+1]=g&8191,g=g>>>13;for(x=2*u;x>=26,u+=h/67108864|0,u+=g>>>26,this.words[c]=g&67108863}return u!==0&&(this.words[c]=u,this.length++),this},a.prototype.muln=function(o){return this.clone().imuln(o)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(o){var u=S(o);if(u.length===0)return new a(1);for(var c=this,h=0;h=0);var u=o%26,c=(o-u)/26,h=67108863>>>26-u<<26-u,g;if(u!==0){var x=0;for(g=0;g>>26-u}x&&(this.words[g]=x,this.length++)}if(c!==0){for(g=this.length-1;g>=0;g--)this.words[g+c]=this.words[g];for(g=0;g=0);var h;u?h=(u-u%26)/26:h=0;var g=o%26,x=Math.min((o-g)/26,this.length),E=67108863^67108863>>>g<x)for(this.length-=x,l=0;l=0&&(m!==0||l>=h);l--){var P=this.words[l]|0;this.words[l]=m<<26-g|P>>>g,m=P&E}return v&&m!==0&&(v.words[v.length++]=m),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},a.prototype.ishrn=function(o,u,c){return n(this.negative===0),this.iushrn(o,u,c)},a.prototype.shln=function(o){return this.clone().ishln(o)},a.prototype.ushln=function(o){return this.clone().iushln(o)},a.prototype.shrn=function(o){return this.clone().ishrn(o)},a.prototype.ushrn=function(o){return this.clone().iushrn(o)},a.prototype.testn=function(o){n(typeof o=="number"&&o>=0);var u=o%26,c=(o-u)/26,h=1<=0);var u=o%26,c=(o-u)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=c)return this;if(u!==0&&c++,this.length=Math.min(c,this.length),u!==0){var h=67108863^67108863>>>u<=67108864;u++)this.words[u]-=67108864,u===this.length-1?this.words[u+1]=1:this.words[u+1]++;return this.length=Math.max(this.length,u+1),this},a.prototype.isubn=function(o){if(n(typeof o=="number"),n(o<67108864),o<0)return this.iaddn(-o);if(this.negative!==0)return this.negative=0,this.iaddn(o),this.negative=1,this;if(this.words[0]-=o,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var u=0;u>26)-(v/67108864|0),this.words[g+c]=x&67108863}for(;g>26,this.words[g+c]=x&67108863;if(E===0)return this.strip();for(n(E===-1),E=0,g=0;g>26,this.words[g]=x&67108863;return this.negative=1,this.strip()},a.prototype._wordDiv=function(o,u){var c=this.length-o.length,h=this.clone(),g=o,x=g.words[g.length-1]|0,E=this._countBits(x);c=26-E,c!==0&&(g=g.ushln(c),h.iushln(c),x=g.words[g.length-1]|0);var v=h.length-g.length,l;if(u!=="mod"){l=new a(null),l.length=v+1,l.words=new Array(l.length);for(var m=0;m=0;N--){var F=(h.words[g.length+N]|0)*67108864+(h.words[g.length+N-1]|0);for(F=Math.min(F/x|0,67108863),h._ishlnsubmul(g,F,N);h.negative!==0;)F--,h.negative=0,h._ishlnsubmul(g,1,N),h.isZero()||(h.negative^=1);l&&(l.words[N]=F)}return l&&l.strip(),h.strip(),u!=="div"&&c!==0&&h.iushrn(c),{div:l||null,mod:h}},a.prototype.divmod=function(o,u,c){if(n(!o.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var h,g,x;return this.negative!==0&&o.negative===0?(x=this.neg().divmod(o,u),u!=="mod"&&(h=x.div.neg()),u!=="div"&&(g=x.mod.neg(),c&&g.negative!==0&&g.iadd(o)),{div:h,mod:g}):this.negative===0&&o.negative!==0?(x=this.divmod(o.neg(),u),u!=="mod"&&(h=x.div.neg()),{div:h,mod:x.mod}):this.negative&o.negative?(x=this.neg().divmod(o.neg(),u),u!=="div"&&(g=x.mod.neg(),c&&g.negative!==0&&g.isub(o)),{div:x.div,mod:g}):o.length>this.length||this.cmp(o)<0?{div:new a(0),mod:this}:o.length===1?u==="div"?{div:this.divn(o.words[0]),mod:null}:u==="mod"?{div:null,mod:new a(this.modn(o.words[0]))}:{div:this.divn(o.words[0]),mod:new a(this.modn(o.words[0]))}:this._wordDiv(o,u)},a.prototype.div=function(o){return this.divmod(o,"div",!1).div},a.prototype.mod=function(o){return this.divmod(o,"mod",!1).mod},a.prototype.umod=function(o){return this.divmod(o,"mod",!0).mod},a.prototype.divRound=function(o){var u=this.divmod(o);if(u.mod.isZero())return u.div;var c=u.div.negative!==0?u.mod.isub(o):u.mod,h=o.ushrn(1),g=o.andln(1),x=c.cmp(h);return x<0||g===1&&x===0?u.div:u.div.negative!==0?u.div.isubn(1):u.div.iaddn(1)},a.prototype.modn=function(o){n(o<=67108863);for(var u=(1<<26)%o,c=0,h=this.length-1;h>=0;h--)c=(u*c+(this.words[h]|0))%o;return c},a.prototype.idivn=function(o){n(o<=67108863);for(var u=0,c=this.length-1;c>=0;c--){var h=(this.words[c]|0)+u*67108864;this.words[c]=h/o|0,u=h%o}return this.strip()},a.prototype.divn=function(o){return this.clone().idivn(o)},a.prototype.egcd=function(o){n(o.negative===0),n(!o.isZero());var u=this,c=o.clone();u.negative!==0?u=u.umod(o):u=u.clone();for(var h=new a(1),g=new a(0),x=new a(0),E=new a(1),v=0;u.isEven()&&c.isEven();)u.iushrn(1),c.iushrn(1),++v;for(var l=c.clone(),m=u.clone();!u.isZero();){for(var P=0,N=1;!(u.words[0]&N)&&P<26;++P,N<<=1);if(P>0)for(u.iushrn(P);P-- >0;)(h.isOdd()||g.isOdd())&&(h.iadd(l),g.isub(m)),h.iushrn(1),g.iushrn(1);for(var F=0,ee=1;!(c.words[0]&ee)&&F<26;++F,ee<<=1);if(F>0)for(c.iushrn(F);F-- >0;)(x.isOdd()||E.isOdd())&&(x.iadd(l),E.isub(m)),x.iushrn(1),E.iushrn(1);u.cmp(c)>=0?(u.isub(c),h.isub(x),g.isub(E)):(c.isub(u),x.isub(h),E.isub(g))}return{a:x,b:E,gcd:c.iushln(v)}},a.prototype._invmp=function(o){n(o.negative===0),n(!o.isZero());var u=this,c=o.clone();u.negative!==0?u=u.umod(o):u=u.clone();for(var h=new a(1),g=new a(0),x=c.clone();u.cmpn(1)>0&&c.cmpn(1)>0;){for(var E=0,v=1;!(u.words[0]&v)&&E<26;++E,v<<=1);if(E>0)for(u.iushrn(E);E-- >0;)h.isOdd()&&h.iadd(x),h.iushrn(1);for(var l=0,m=1;!(c.words[0]&m)&&l<26;++l,m<<=1);if(l>0)for(c.iushrn(l);l-- >0;)g.isOdd()&&g.iadd(x),g.iushrn(1);u.cmp(c)>=0?(u.isub(c),h.isub(g)):(c.isub(u),g.isub(h))}var P;return u.cmpn(1)===0?P=h:P=g,P.cmpn(0)<0&&P.iadd(o),P},a.prototype.gcd=function(o){if(this.isZero())return o.abs();if(o.isZero())return this.abs();var u=this.clone(),c=o.clone();u.negative=0,c.negative=0;for(var h=0;u.isEven()&&c.isEven();h++)u.iushrn(1),c.iushrn(1);do{for(;u.isEven();)u.iushrn(1);for(;c.isEven();)c.iushrn(1);var g=u.cmp(c);if(g<0){var x=u;u=c,c=x}else if(g===0||c.cmpn(1)===0)break;u.isub(c)}while(!0);return c.iushln(h)},a.prototype.invm=function(o){return this.egcd(o).a.umod(o)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(o){return this.words[0]&o},a.prototype.bincn=function(o){n(typeof o=="number");var u=o%26,c=(o-u)/26,h=1<>>26,E&=67108863,this.words[x]=E}return g!==0&&(this.words[x]=g,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(o){var u=o<0;if(this.negative!==0&&!u)return-1;if(this.negative===0&&u)return 1;this.strip();var c;if(this.length>1)c=1;else{u&&(o=-o),n(o<=67108863,"Number is too big");var h=this.words[0]|0;c=h===o?0:ho.length)return 1;if(this.length=0;c--){var h=this.words[c]|0,g=o.words[c]|0;if(h!==g){hg&&(u=1);break}}return u},a.prototype.gtn=function(o){return this.cmpn(o)===1},a.prototype.gt=function(o){return this.cmp(o)===1},a.prototype.gten=function(o){return this.cmpn(o)>=0},a.prototype.gte=function(o){return this.cmp(o)>=0},a.prototype.ltn=function(o){return this.cmpn(o)===-1},a.prototype.lt=function(o){return this.cmp(o)===-1},a.prototype.lten=function(o){return this.cmpn(o)<=0},a.prototype.lte=function(o){return this.cmp(o)<=0},a.prototype.eqn=function(o){return this.cmpn(o)===0},a.prototype.eq=function(o){return this.cmp(o)===0},a.red=function(o){return new z(o)},a.prototype.toRed=function(o){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),o.convertTo(this)._forceRed(o)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(o){return this.red=o,this},a.prototype.forceRed=function(o){return n(!this.red,"Already a number in reduction context"),this._forceRed(o)},a.prototype.redAdd=function(o){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,o)},a.prototype.redIAdd=function(o){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,o)},a.prototype.redSub=function(o){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,o)},a.prototype.redISub=function(o){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,o)},a.prototype.redShl=function(o){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,o)},a.prototype.redMul=function(o){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,o),this.red.mul(this,o)},a.prototype.redIMul=function(o){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,o),this.red.imul(this,o)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(o){return n(this.red&&!o.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,o)};var R={k256:null,p224:null,p192:null,p25519:null};function $(b,o){this.name=b,this.p=new a(o,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}$.prototype._tmp=function(){var o=new a(null);return o.words=new Array(Math.ceil(this.n/13)),o},$.prototype.ireduce=function(o){var u=o,c;do this.split(u,this.tmp),u=this.imulK(u),u=u.iadd(this.tmp),c=u.bitLength();while(c>this.n);var h=c0?u.isub(this.p):u.strip!==void 0?u.strip():u._strip(),u},$.prototype.split=function(o,u){o.iushrn(this.n,0,u)},$.prototype.imulK=function(o){return o.imul(this.k)};function L(){$.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}i(L,$),L.prototype.split=function(o,u){for(var c=4194303,h=Math.min(o.length,9),g=0;g>>22,x=E}x>>>=22,o.words[g-10]=x,x===0&&o.length>10?o.length-=10:o.length-=9},L.prototype.imulK=function(o){o.words[o.length]=0,o.words[o.length+1]=0,o.length+=2;for(var u=0,c=0;c>>=26,o.words[c]=g,u=h}return u!==0&&(o.words[o.length++]=u),o},a._prime=function(o){if(R[o])return R[o];var u;if(o==="k256")u=new L;else if(o==="p224")u=new j;else if(o==="p192")u=new A;else if(o==="p25519")u=new V;else throw new Error("Unknown prime "+o);return R[o]=u,u};function z(b){if(typeof b=="string"){var o=a._prime(b);this.m=o.p,this.prime=o}else n(b.gtn(1),"modulus must be greater than 1"),this.m=b,this.prime=null}z.prototype._verify1=function(o){n(o.negative===0,"red works only with positives"),n(o.red,"red works only with red numbers")},z.prototype._verify2=function(o,u){n((o.negative|u.negative)===0,"red works only with positives"),n(o.red&&o.red===u.red,"red works only with red numbers")},z.prototype.imod=function(o){return this.prime?this.prime.ireduce(o)._forceRed(this):o.umod(this.m)._forceRed(this)},z.prototype.neg=function(o){return o.isZero()?o.clone():this.m.sub(o)._forceRed(this)},z.prototype.add=function(o,u){this._verify2(o,u);var c=o.add(u);return c.cmp(this.m)>=0&&c.isub(this.m),c._forceRed(this)},z.prototype.iadd=function(o,u){this._verify2(o,u);var c=o.iadd(u);return c.cmp(this.m)>=0&&c.isub(this.m),c},z.prototype.sub=function(o,u){this._verify2(o,u);var c=o.sub(u);return c.cmpn(0)<0&&c.iadd(this.m),c._forceRed(this)},z.prototype.isub=function(o,u){this._verify2(o,u);var c=o.isub(u);return c.cmpn(0)<0&&c.iadd(this.m),c},z.prototype.shl=function(o,u){return this._verify1(o),this.imod(o.ushln(u))},z.prototype.imul=function(o,u){return this._verify2(o,u),this.imod(o.imul(u))},z.prototype.mul=function(o,u){return this._verify2(o,u),this.imod(o.mul(u))},z.prototype.isqr=function(o){return this.imul(o,o.clone())},z.prototype.sqr=function(o){return this.mul(o,o)},z.prototype.sqrt=function(o){if(o.isZero())return o.clone();var u=this.m.andln(3);if(n(u%2===1),u===3){var c=this.m.add(new a(1)).iushrn(2);return this.pow(o,c)}for(var h=this.m.subn(1),g=0;!h.isZero()&&h.andln(1)===0;)g++,h.iushrn(1);n(!h.isZero());var x=new a(1).toRed(this),E=x.redNeg(),v=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new a(2*l*l).toRed(this);this.pow(l,v).cmp(E)!==0;)l.redIAdd(E);for(var m=this.pow(l,h),P=this.pow(o,h.addn(1).iushrn(1)),N=this.pow(o,h),F=g;N.cmp(x)!==0;){for(var ee=N,q=0;ee.cmp(x)!==0;q++)ee=ee.redSqr();n(q=0;g--){for(var m=u.words[g],P=l-1;P>=0;P--){var N=m>>P&1;if(x!==h[0]&&(x=this.sqr(x)),N===0&&E===0){v=0;continue}E<<=1,E|=N,v++,!(v!==c&&(g!==0||P!==0))&&(x=this.mul(x,h[E]),v=0,E=0)}l=26}return x},z.prototype.convertTo=function(o){var u=o.umod(this.m);return u===o?u.clone():u},z.prototype.convertFrom=function(o){var u=o.clone();return u.red=null,u},a.mont=function(o){return new Y(o)};function Y(b){z.call(this,b),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}i(Y,z),Y.prototype.convertTo=function(o){return this.imod(o.ushln(this.shift))},Y.prototype.convertFrom=function(o){var u=this.imod(o.mul(this.rinv));return u.red=null,u},Y.prototype.imul=function(o,u){if(o.isZero()||u.isZero())return o.words[0]=0,o.length=1,o;var c=o.imul(u),h=c.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),g=c.isub(h).iushrn(this.shift),x=g;return g.cmp(this.m)>=0?x=g.isub(this.m):g.cmpn(0)<0&&(x=g.iadd(this.m)),x._forceRed(this)},Y.prototype.mul=function(o,u){if(o.isZero()||u.isZero())return new a(0)._forceRed(this);var c=o.mul(u),h=c.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),g=c.isub(h).iushrn(this.shift),x=g;return g.cmp(this.m)>=0?x=g.isub(this.m):g.cmpn(0)<0&&(x=g.iadd(this.m)),x._forceRed(this)},Y.prototype.invm=function(o){var u=this.imod(o._invmp(this.m).mul(this.r2));return u._forceRed(this)}})(e,Ut)})(H5);var V5=H5.exports,VT=V5,Nne=Jt.Buffer;function jne(e,t){return Nne.from(e.toRed(VT.mont(t.modulus)).redPow(new VT(t.publicExponent)).fromRed().toArray())}var jL=jne,Bne=ew,n3=Td,Fne=vp,qT=LL,WT=NL,q5=V5,zne=jL,Une=S5,ho=Jt.Buffer,Hne=function(t,r,n){var i;t.padding?i=t.padding:n?i=1:i=4;var a=Bne(t),s;if(i===4)s=Vne(a,r);else if(i===1)s=qne(a,r,n);else if(i===3){if(s=new q5(r),s.cmp(a.modulus)>=0)throw new Error("data too long for modulus")}else throw new Error("unknown padding");return n?Une(s,a):zne(s,a)};function Vne(e,t){var r=e.modulus.byteLength(),n=t.length,i=Fne("sha1").update(ho.alloc(0)).digest(),a=i.length,s=2*a;if(n>r-s-2)throw new Error("message too long");var f=ho.alloc(r-n-s-2),d=r-a-1,p=n3(a),y=WT(ho.concat([i,f,ho.alloc(1,1),t],d),qT(p,d)),w=WT(p,qT(y,a));return new q5(ho.concat([ho.alloc(1),w,y],r))}function qne(e,t,r){var n=t.length,i=e.modulus.byteLength();if(n>i-11)throw new Error("message too long");var a;return r?a=ho.alloc(i-n-3,255):a=Wne(i-n-3),new q5(ho.concat([ho.from([0,r?1:2]),a,ho.alloc(1),t],i))}function Wne(e){for(var t=ho.allocUnsafe(e),r=0,n=n3(e*2),i=0,a;rs||new YT(r).cmp(a.modulus)>=0)throw new Error("decryption error");var f;n?f=Xne(new YT(r),a):f=Gne(r,a);var d=j0.alloc(s-f.length);if(f=j0.concat([d,f],s),i===4)return Jne(a,f);if(i===1)return Qne(a,f,n);if(i===3)return f;throw new Error("unknown padding")};function Jne(e,t){var r=e.modulus.byteLength(),n=Yne("sha1").update(j0.alloc(0)).digest(),i=n.length;if(t[0]!==0)throw new Error("decryption error");var a=t.slice(1,i+1),s=t.slice(i+1),f=GT(a,KT(s,i)),d=GT(s,KT(f,r-i-1));if(eie(n,d.slice(0,i)))throw new Error("decryption error");for(var p=i;d[p]===0;)p++;if(d[p++]!==1)throw new Error("decryption error");return d.slice(p)}function Qne(e,t,r){for(var n=t.slice(0,2),i=2,a=0;t[i++]!==0;)if(i>=t.length){a++;break}var s=t.slice(2,i-1);if((n.toString("hex")!=="0002"&&!r||n.toString("hex")!=="0001"&&r)&&a++,s.length<8&&a++,a)throw new Error("decryption error");return t.slice(i)}function eie(e,t){e=j0.from(e),t=j0.from(t);var r=0,n=e.length;e.length!==t.length&&(r++,n=Math.min(e.length,t.length));for(var i=-1;++iUL||e<0)throw new TypeError("offset must be a uint32");if(e>zL||e>t)throw new RangeError("offset out of range")}function VL(e,t,r){if(typeof e!="number"||e!==e)throw new TypeError("size must be a number");if(e>UL||e<0)throw new TypeError("size must be a uint32");if(e+t>r||e>zL)throw new RangeError("buffer too small")}i3&&i3.getRandomValues||!Yt.browser?(Hh.randomFill=tie,Hh.randomFillSync=rie):(Hh.randomFill=XT,Hh.randomFillSync=XT);function tie(e,t,r,n){if(!FL.isBuffer(e)&&!(e instanceof globalThis.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if(typeof t=="function")n=t,t=0,r=e.length;else if(typeof r=="function")n=r,r=e.length-t;else if(typeof n!="function")throw new TypeError('"cb" argument must be a function');return HL(t,e.length),VL(r,t,e.length),qL(e,t,r,n)}function qL(e,t,r,n){if(Yt.browser){var i=e.buffer,a=new Uint8Array(i,t,r);if(i3.getRandomValues(a),n){Yt.nextTick(function(){n(null,e)});return}return e}if(n){ZT(r,function(f,d){if(f)return n(f);d.copy(e,t),n(null,e)});return}var s=ZT(r);return s.copy(e,t),e}function rie(e,t,r){if(typeof t>"u"&&(t=0),!FL.isBuffer(e)&&!(e instanceof globalThis.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');return HL(t,e.length),r===void 0&&(r=e.length-t),VL(r,t,e.length),qL(e,t,r)}var JT;function Mp(){if(JT)return tr;JT=1,tr.randomBytes=tr.rng=tr.pseudoRandomBytes=tr.prng=Td,tr.createHash=tr.Hash=vp,tr.createHmac=tr.Hmac=nI;var e=zJ,t=Object.keys(e),r=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(t);tr.getHashes=function(){return r};var n=Ly;tr.pbkdf2=n.pbkdf2,tr.pbkdf2Sync=n.pbkdf2Sync;var i=wo;tr.Cipher=i.Cipher,tr.createCipher=i.createCipher,tr.Cipheriv=i.Cipheriv,tr.createCipheriv=i.createCipheriv,tr.Decipher=i.Decipher,tr.createDecipher=i.createDecipher,tr.Decipheriv=i.Decipheriv,tr.createDecipheriv=i.createDecipheriv,tr.getCiphers=i.getCiphers,tr.listCiphers=i.listCiphers;var a=bee();tr.DiffieHellmanGroup=a.DiffieHellmanGroup,tr.createDiffieHellmanGroup=a.createDiffieHellmanGroup,tr.getDiffieHellman=a.getDiffieHellman,tr.createDiffieHellman=a.createDiffieHellman,tr.DiffieHellman=a.DiffieHellman;var s=Ane();tr.createSign=s.createSign,tr.Sign=s.Sign,tr.createVerify=s.createVerify,tr.Verify=s.Verify,tr.createECDH=$ne();var f=IL;tr.publicEncrypt=f.publicEncrypt,tr.privateEncrypt=f.privateEncrypt,tr.publicDecrypt=f.publicDecrypt,tr.privateDecrypt=f.privateDecrypt;var d=Hh;return tr.randomFill=d.randomFill,tr.randomFillSync=d.randomFillSync,tr.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join(` `))},tr.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6},tr}var QT;function Cr(){return QT||(QT=1,function(e,t){(function(r,n){e.exports=n()})(Ut,function(){var r=r||function(n,i){var a;if(typeof window<"u"&&window.crypto&&(a=window.crypto),typeof self<"u"&&self.crypto&&(a=self.crypto),typeof globalThis<"u"&&globalThis.crypto&&(a=globalThis.crypto),!a&&typeof window<"u"&&window.msCrypto&&(a=window.msCrypto),!a&&typeof globalThis<"u"&&globalThis.crypto&&(a=globalThis.crypto),!a&&typeof df=="function")try{a=Mp()}catch{}var s=function(){if(a){if(typeof a.getRandomValues=="function")try{return a.getRandomValues(new Uint32Array(1))[0]}catch{}if(typeof a.randomBytes=="function")try{return a.randomBytes(4).readInt32LE()}catch{}}throw new Error("Native crypto module could not be used to get secure random number.")},f=Object.create||function(){function k(){}return function(R){var $;return k.prototype=R,$=new k,k.prototype=null,$}}(),d={},p=d.lib={},y=p.Base=function(){return{extend:function(k){var R=f(this);return k&&R.mixIn(k),(!R.hasOwnProperty("init")||this.init===R.init)&&(R.init=function(){R.$super.init.apply(this,arguments)}),R.init.prototype=R,R.$super=this,R},create:function(){var k=this.extend();return k.init.apply(k,arguments),k},init:function(){},mixIn:function(k){for(var R in k)k.hasOwnProperty(R)&&(this[R]=k[R]);k.hasOwnProperty("toString")&&(this.toString=k.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),w=p.WordArray=y.extend({init:function(k,R){k=this.words=k||[],R!=i?this.sigBytes=R:this.sigBytes=k.length*4},toString:function(k){return(k||S).stringify(this)},concat:function(k){var R=this.words,$=k.words,L=this.sigBytes,j=k.sigBytes;if(this.clamp(),L%4)for(var A=0;A>>2]>>>24-A%4*8&255;R[L+A>>>2]|=V<<24-(L+A)%4*8}else for(var z=0;z>>2]=$[z>>>2];return this.sigBytes+=j,this},clamp:function(){var k=this.words,R=this.sigBytes;k[R>>>2]&=4294967295<<32-R%4*8,k.length=n.ceil(R/4)},clone:function(){var k=y.clone.call(this);return k.words=this.words.slice(0),k},random:function(k){for(var R=[],$=0;$>>2]>>>24-j%4*8&255;L.push((A>>>4).toString(16)),L.push((A&15).toString(16))}return L.join("")},parse:function(k){for(var R=k.length,$=[],L=0;L>>3]|=parseInt(k.substr(L,2),16)<<24-L%8*4;return new w.init($,R/2)}},M=_.Latin1={stringify:function(k){for(var R=k.words,$=k.sigBytes,L=[],j=0;j<$;j++){var A=R[j>>>2]>>>24-j%4*8&255;L.push(String.fromCharCode(A))}return L.join("")},parse:function(k){for(var R=k.length,$=[],L=0;L>>2]|=(k.charCodeAt(L)&255)<<24-L%4*8;return new w.init($,R)}},C=_.Utf8={stringify:function(k){try{return decodeURIComponent(escape(M.stringify(k)))}catch{throw new Error("Malformed UTF-8 data")}},parse:function(k){return M.parse(unescape(encodeURIComponent(k)))}},O=p.BufferedBlockAlgorithm=y.extend({reset:function(){this._data=new w.init,this._nDataBytes=0},_append:function(k){typeof k=="string"&&(k=C.parse(k)),this._data.concat(k),this._nDataBytes+=k.sigBytes},_process:function(k){var R,$=this._data,L=$.words,j=$.sigBytes,A=this.blockSize,V=A*4,z=j/V;k?z=n.ceil(z):z=n.max((z|0)-this._minBufferSize,0);var Y=z*A,b=n.min(Y*4,j);if(Y){for(var o=0;o>>2]|=d[w]<<24-w%4*8;s.call(this,y,p)}else s.apply(this,arguments)};f.prototype=a}}(),r.lib.WordArray})}(Q2)),Q2.exports}var ex={exports:{}},rC;function iie(){return rC||(rC=1,function(e,t){(function(r,n){e.exports=n(Cr())})(Ut,function(r){return function(){var n=r,i=n.lib,a=i.WordArray,s=n.enc;s.Utf16=s.Utf16BE={stringify:function(d){for(var p=d.words,y=d.sigBytes,w=[],_=0;_>>2]>>>16-_%4*8&65535;w.push(String.fromCharCode(S))}return w.join("")},parse:function(d){for(var p=d.length,y=[],w=0;w>>1]|=d.charCodeAt(w)<<16-w%2*16;return a.create(y,p*2)}},s.Utf16LE={stringify:function(d){for(var p=d.words,y=d.sigBytes,w=[],_=0;_>>2]>>>16-_%4*8&65535);w.push(String.fromCharCode(S))}return w.join("")},parse:function(d){for(var p=d.length,y=[],w=0;w>>1]|=f(d.charCodeAt(w)<<16-w%2*16);return a.create(y,p*2)}};function f(d){return d<<8&4278255360|d>>>8&16711935}}(),r.enc.Utf16})}(ex)),ex.exports}var tx={exports:{}},nC;function Nd(){return nC||(nC=1,function(e,t){(function(r,n){e.exports=n(Cr())})(Ut,function(r){return function(){var n=r,i=n.lib,a=i.WordArray,s=n.enc;s.Base64={stringify:function(d){var p=d.words,y=d.sigBytes,w=this._map;d.clamp();for(var _=[],S=0;S>>2]>>>24-S%4*8&255,C=p[S+1>>>2]>>>24-(S+1)%4*8&255,O=p[S+2>>>2]>>>24-(S+2)%4*8&255,T=M<<16|C<<8|O,k=0;k<4&&S+k*.75>>6*(3-k)&63));var R=w.charAt(64);if(R)for(;_.length%4;)_.push(R);return _.join("")},parse:function(d){var p=d.length,y=this._map,w=this._reverseMap;if(!w){w=this._reverseMap=[];for(var _=0;_>>6-S%4*2,O=M|C;w[_>>>2]|=O<<24-_%4*8,_++}return a.create(w,_)}}(),r.enc.Base64})}(tx)),tx.exports}var rx={exports:{}},iC;function aie(){return iC||(iC=1,function(e,t){(function(r,n){e.exports=n(Cr())})(Ut,function(r){return function(){var n=r,i=n.lib,a=i.WordArray,s=n.enc;s.Base64url={stringify:function(d,p=!0){var y=d.words,w=d.sigBytes,_=p?this._safe_map:this._map;d.clamp();for(var S=[],M=0;M>>2]>>>24-M%4*8&255,O=y[M+1>>>2]>>>24-(M+1)%4*8&255,T=y[M+2>>>2]>>>24-(M+2)%4*8&255,k=C<<16|O<<8|T,R=0;R<4&&M+R*.75>>6*(3-R)&63));var $=_.charAt(64);if($)for(;S.length%4;)S.push($);return S.join("")},parse:function(d,p=!0){var y=d.length,w=p?this._safe_map:this._map,_=this._reverseMap;if(!_){_=this._reverseMap=[];for(var S=0;S>>6-S%4*2,O=M|C;w[_>>>2]|=O<<24-_%4*8,_++}return a.create(w,_)}}(),r.enc.Base64url})}(rx)),rx.exports}var nx={exports:{}},aC;function jd(){return aC||(aC=1,function(e,t){(function(r,n){e.exports=n(Cr())})(Ut,function(r){return function(n){var i=r,a=i.lib,s=a.WordArray,f=a.Hasher,d=i.algo,p=[];(function(){for(var C=0;C<64;C++)p[C]=n.abs(n.sin(C+1))*4294967296|0})();var y=d.MD5=f.extend({_doReset:function(){this._hash=new s.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(C,O){for(var T=0;T<16;T++){var k=O+T,R=C[k];C[k]=(R<<8|R>>>24)&16711935|(R<<24|R>>>8)&4278255360}var $=this._hash.words,L=C[O+0],j=C[O+1],A=C[O+2],V=C[O+3],z=C[O+4],Y=C[O+5],b=C[O+6],o=C[O+7],u=C[O+8],c=C[O+9],h=C[O+10],g=C[O+11],x=C[O+12],E=C[O+13],v=C[O+14],l=C[O+15],m=$[0],P=$[1],N=$[2],F=$[3];m=w(m,P,N,F,L,7,p[0]),F=w(F,m,P,N,j,12,p[1]),N=w(N,F,m,P,A,17,p[2]),P=w(P,N,F,m,V,22,p[3]),m=w(m,P,N,F,z,7,p[4]),F=w(F,m,P,N,Y,12,p[5]),N=w(N,F,m,P,b,17,p[6]),P=w(P,N,F,m,o,22,p[7]),m=w(m,P,N,F,u,7,p[8]),F=w(F,m,P,N,c,12,p[9]),N=w(N,F,m,P,h,17,p[10]),P=w(P,N,F,m,g,22,p[11]),m=w(m,P,N,F,x,7,p[12]),F=w(F,m,P,N,E,12,p[13]),N=w(N,F,m,P,v,17,p[14]),P=w(P,N,F,m,l,22,p[15]),m=_(m,P,N,F,j,5,p[16]),F=_(F,m,P,N,b,9,p[17]),N=_(N,F,m,P,g,14,p[18]),P=_(P,N,F,m,L,20,p[19]),m=_(m,P,N,F,Y,5,p[20]),F=_(F,m,P,N,h,9,p[21]),N=_(N,F,m,P,l,14,p[22]),P=_(P,N,F,m,z,20,p[23]),m=_(m,P,N,F,c,5,p[24]),F=_(F,m,P,N,v,9,p[25]),N=_(N,F,m,P,V,14,p[26]),P=_(P,N,F,m,u,20,p[27]),m=_(m,P,N,F,E,5,p[28]),F=_(F,m,P,N,A,9,p[29]),N=_(N,F,m,P,o,14,p[30]),P=_(P,N,F,m,x,20,p[31]),m=S(m,P,N,F,Y,4,p[32]),F=S(F,m,P,N,u,11,p[33]),N=S(N,F,m,P,g,16,p[34]),P=S(P,N,F,m,v,23,p[35]),m=S(m,P,N,F,j,4,p[36]),F=S(F,m,P,N,z,11,p[37]),N=S(N,F,m,P,o,16,p[38]),P=S(P,N,F,m,h,23,p[39]),m=S(m,P,N,F,E,4,p[40]),F=S(F,m,P,N,L,11,p[41]),N=S(N,F,m,P,V,16,p[42]),P=S(P,N,F,m,b,23,p[43]),m=S(m,P,N,F,c,4,p[44]),F=S(F,m,P,N,x,11,p[45]),N=S(N,F,m,P,l,16,p[46]),P=S(P,N,F,m,A,23,p[47]),m=M(m,P,N,F,L,6,p[48]),F=M(F,m,P,N,o,10,p[49]),N=M(N,F,m,P,v,15,p[50]),P=M(P,N,F,m,Y,21,p[51]),m=M(m,P,N,F,x,6,p[52]),F=M(F,m,P,N,V,10,p[53]),N=M(N,F,m,P,h,15,p[54]),P=M(P,N,F,m,j,21,p[55]),m=M(m,P,N,F,u,6,p[56]),F=M(F,m,P,N,l,10,p[57]),N=M(N,F,m,P,b,15,p[58]),P=M(P,N,F,m,E,21,p[59]),m=M(m,P,N,F,z,6,p[60]),F=M(F,m,P,N,g,10,p[61]),N=M(N,F,m,P,A,15,p[62]),P=M(P,N,F,m,c,21,p[63]),$[0]=$[0]+m|0,$[1]=$[1]+P|0,$[2]=$[2]+N|0,$[3]=$[3]+F|0},_doFinalize:function(){var C=this._data,O=C.words,T=this._nDataBytes*8,k=C.sigBytes*8;O[k>>>5]|=128<<24-k%32;var R=n.floor(T/4294967296),$=T;O[(k+64>>>9<<4)+15]=(R<<8|R>>>24)&16711935|(R<<24|R>>>8)&4278255360,O[(k+64>>>9<<4)+14]=($<<8|$>>>24)&16711935|($<<24|$>>>8)&4278255360,C.sigBytes=(O.length+1)*4,this._process();for(var L=this._hash,j=L.words,A=0;A<4;A++){var V=j[A];j[A]=(V<<8|V>>>24)&16711935|(V<<24|V>>>8)&4278255360}return L},clone:function(){var C=f.clone.call(this);return C._hash=this._hash.clone(),C}});function w(C,O,T,k,R,$,L){var j=C+(O&T|~O&k)+R+L;return(j<<$|j>>>32-$)+O}function _(C,O,T,k,R,$,L){var j=C+(O&k|T&~k)+R+L;return(j<<$|j>>>32-$)+O}function S(C,O,T,k,R,$,L){var j=C+(O^T^k)+R+L;return(j<<$|j>>>32-$)+O}function M(C,O,T,k,R,$,L){var j=C+(T^(O|~k))+R+L;return(j<<$|j>>>32-$)+O}i.MD5=f._createHelper(y),i.HmacMD5=f._createHmacHelper(y)}(Math),r.MD5})}(nx)),nx.exports}var ix={exports:{}},oC;function W5(){return oC||(oC=1,function(e,t){(function(r,n){e.exports=n(Cr())})(Ut,function(r){return function(){var n=r,i=n.lib,a=i.WordArray,s=i.Hasher,f=n.algo,d=[],p=f.SHA1=s.extend({_doReset:function(){this._hash=new a.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(y,w){for(var _=this._hash.words,S=_[0],M=_[1],C=_[2],O=_[3],T=_[4],k=0;k<80;k++){if(k<16)d[k]=y[w+k]|0;else{var R=d[k-3]^d[k-8]^d[k-14]^d[k-16];d[k]=R<<1|R>>>31}var $=(S<<5|S>>>27)+T+d[k];k<20?$+=(M&C|~M&O)+1518500249:k<40?$+=(M^C^O)+1859775393:k<60?$+=(M&C|M&O|C&O)-1894007588:$+=(M^C^O)-899497514,T=O,O=C,C=M<<30|M>>>2,M=S,S=$}_[0]=_[0]+S|0,_[1]=_[1]+M|0,_[2]=_[2]+C|0,_[3]=_[3]+O|0,_[4]=_[4]+T|0},_doFinalize:function(){var y=this._data,w=y.words,_=this._nDataBytes*8,S=y.sigBytes*8;return w[S>>>5]|=128<<24-S%32,w[(S+64>>>9<<4)+14]=Math.floor(_/4294967296),w[(S+64>>>9<<4)+15]=_,y.sigBytes=w.length*4,this._process(),this._hash},clone:function(){var y=s.clone.call(this);return y._hash=this._hash.clone(),y}});n.SHA1=s._createHelper(p),n.HmacSHA1=s._createHmacHelper(p)}(),r.SHA1})}(ix)),ix.exports}var ax={exports:{}},sC;function WL(){return sC||(sC=1,function(e,t){(function(r,n){e.exports=n(Cr())})(Ut,function(r){return function(n){var i=r,a=i.lib,s=a.WordArray,f=a.Hasher,d=i.algo,p=[],y=[];(function(){function S(T){for(var k=n.sqrt(T),R=2;R<=k;R++)if(!(T%R))return!1;return!0}function M(T){return(T-(T|0))*4294967296|0}for(var C=2,O=0;O<64;)S(C)&&(O<8&&(p[O]=M(n.pow(C,1/2))),y[O]=M(n.pow(C,1/3)),O++),C++})();var w=[],_=d.SHA256=f.extend({_doReset:function(){this._hash=new s.init(p.slice(0))},_doProcessBlock:function(S,M){for(var C=this._hash.words,O=C[0],T=C[1],k=C[2],R=C[3],$=C[4],L=C[5],j=C[6],A=C[7],V=0;V<64;V++){if(V<16)w[V]=S[M+V]|0;else{var z=w[V-15],Y=(z<<25|z>>>7)^(z<<14|z>>>18)^z>>>3,b=w[V-2],o=(b<<15|b>>>17)^(b<<13|b>>>19)^b>>>10;w[V]=Y+w[V-7]+o+w[V-16]}var u=$&L^~$&j,c=O&T^O&k^T&k,h=(O<<30|O>>>2)^(O<<19|O>>>13)^(O<<10|O>>>22),g=($<<26|$>>>6)^($<<21|$>>>11)^($<<7|$>>>25),x=A+g+u+y[V]+w[V],E=h+c;A=j,j=L,L=$,$=R+x|0,R=k,k=T,T=O,O=x+E|0}C[0]=C[0]+O|0,C[1]=C[1]+T|0,C[2]=C[2]+k|0,C[3]=C[3]+R|0,C[4]=C[4]+$|0,C[5]=C[5]+L|0,C[6]=C[6]+j|0,C[7]=C[7]+A|0},_doFinalize:function(){var S=this._data,M=S.words,C=this._nDataBytes*8,O=S.sigBytes*8;return M[O>>>5]|=128<<24-O%32,M[(O+64>>>9<<4)+14]=n.floor(C/4294967296),M[(O+64>>>9<<4)+15]=C,S.sigBytes=M.length*4,this._process(),this._hash},clone:function(){var S=f.clone.call(this);return S._hash=this._hash.clone(),S}});i.SHA256=f._createHelper(_),i.HmacSHA256=f._createHmacHelper(_)}(Math),r.SHA256})}(ax)),ax.exports}var ox={exports:{}},lC;function oie(){return lC||(lC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),WL())})(Ut,function(r){return function(){var n=r,i=n.lib,a=i.WordArray,s=n.algo,f=s.SHA256,d=s.SHA224=f.extend({_doReset:function(){this._hash=new a.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var p=f._doFinalize.call(this);return p.sigBytes-=4,p}});n.SHA224=f._createHelper(d),n.HmacSHA224=f._createHmacHelper(d)}(),r.SHA224})}(ox)),ox.exports}var sx={exports:{}},uC;function KL(){return uC||(uC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),tw())})(Ut,function(r){return function(){var n=r,i=n.lib,a=i.Hasher,s=n.x64,f=s.Word,d=s.WordArray,p=n.algo;function y(){return f.create.apply(f,arguments)}var w=[y(1116352408,3609767458),y(1899447441,602891725),y(3049323471,3964484399),y(3921009573,2173295548),y(961987163,4081628472),y(1508970993,3053834265),y(2453635748,2937671579),y(2870763221,3664609560),y(3624381080,2734883394),y(310598401,1164996542),y(607225278,1323610764),y(1426881987,3590304994),y(1925078388,4068182383),y(2162078206,991336113),y(2614888103,633803317),y(3248222580,3479774868),y(3835390401,2666613458),y(4022224774,944711139),y(264347078,2341262773),y(604807628,2007800933),y(770255983,1495990901),y(1249150122,1856431235),y(1555081692,3175218132),y(1996064986,2198950837),y(2554220882,3999719339),y(2821834349,766784016),y(2952996808,2566594879),y(3210313671,3203337956),y(3336571891,1034457026),y(3584528711,2466948901),y(113926993,3758326383),y(338241895,168717936),y(666307205,1188179964),y(773529912,1546045734),y(1294757372,1522805485),y(1396182291,2643833823),y(1695183700,2343527390),y(1986661051,1014477480),y(2177026350,1206759142),y(2456956037,344077627),y(2730485921,1290863460),y(2820302411,3158454273),y(3259730800,3505952657),y(3345764771,106217008),y(3516065817,3606008344),y(3600352804,1432725776),y(4094571909,1467031594),y(275423344,851169720),y(430227734,3100823752),y(506948616,1363258195),y(659060556,3750685593),y(883997877,3785050280),y(958139571,3318307427),y(1322822218,3812723403),y(1537002063,2003034995),y(1747873779,3602036899),y(1955562222,1575990012),y(2024104815,1125592928),y(2227730452,2716904306),y(2361852424,442776044),y(2428436474,593698344),y(2756734187,3733110249),y(3204031479,2999351573),y(3329325298,3815920427),y(3391569614,3928383900),y(3515267271,566280711),y(3940187606,3454069534),y(4118630271,4000239992),y(116418474,1914138554),y(174292421,2731055270),y(289380356,3203993006),y(460393269,320620315),y(685471733,587496836),y(852142971,1086792851),y(1017036298,365543100),y(1126000580,2618297676),y(1288033470,3409855158),y(1501505948,4234509866),y(1607167915,987167468),y(1816402316,1246189591)],_=[];(function(){for(var M=0;M<80;M++)_[M]=y()})();var S=p.SHA512=a.extend({_doReset:function(){this._hash=new d.init([new f.init(1779033703,4089235720),new f.init(3144134277,2227873595),new f.init(1013904242,4271175723),new f.init(2773480762,1595750129),new f.init(1359893119,2917565137),new f.init(2600822924,725511199),new f.init(528734635,4215389547),new f.init(1541459225,327033209)])},_doProcessBlock:function(M,C){for(var O=this._hash.words,T=O[0],k=O[1],R=O[2],$=O[3],L=O[4],j=O[5],A=O[6],V=O[7],z=T.high,Y=T.low,b=k.high,o=k.low,u=R.high,c=R.low,h=$.high,g=$.low,x=L.high,E=L.low,v=j.high,l=j.low,m=A.high,P=A.low,N=V.high,F=V.low,ee=z,q=Y,ae=b,pe=o,we=u,Se=c,he=h,re=g,_e=x,W=E,ve=v,Z=l,ne=m,K=P,le=N,xe=F,ce=0;ce<80;ce++){var de,Ae,ye=_[ce];if(ce<16)Ae=ye.high=M[C+ce*2]|0,de=ye.low=M[C+ce*2+1]|0;else{var be=_[ce-15],tt=be.high,Oe=be.low,$e=(tt>>>1|Oe<<31)^(tt>>>8|Oe<<24)^tt>>>7,Et=(Oe>>>1|tt<<31)^(Oe>>>8|tt<<24)^(Oe>>>7|tt<<25),ze=_[ce-2],He=ze.high,Fe=ze.low,Te=(He>>>19|Fe<<13)^(He<<3|Fe>>>29)^He>>>6,Pe=(Fe>>>19|He<<13)^(Fe<<3|He>>>29)^(Fe>>>6|He<<26),pt=_[ce-7],De=pt.high,je=pt.low,bt=_[ce-16],Le=bt.high,Ge=bt.low;de=Et+je,Ae=$e+De+(de>>>0>>0?1:0),de=de+Pe,Ae=Ae+Te+(de>>>0>>0?1:0),de=de+Ge,Ae=Ae+Le+(de>>>0>>0?1:0),ye.high=Ae,ye.low=de}var Ct=_e&ve^~_e&ne,Be=W&Z^~W&K,Ye=ee&ae^ee&we^ae&we,Pt=q&pe^q&Se^pe&Se,Ue=(ee>>>28|q<<4)^(ee<<30|q>>>2)^(ee<<25|q>>>7),et=(q>>>28|ee<<4)^(q<<30|ee>>>2)^(q<<25|ee>>>7),Vt=(_e>>>14|W<<18)^(_e>>>18|W<<14)^(_e<<23|W>>>9),Xe=(W>>>14|_e<<18)^(W>>>18|_e<<14)^(W<<23|_e>>>9),ot=w[ce],Kt=ot.high,Ve=ot.low,Je=xe+Xe,It=le+Vt+(Je>>>0>>0?1:0),Je=Je+Be,It=It+Ct+(Je>>>0>>0?1:0),Je=Je+Ve,It=It+Kt+(Je>>>0>>0?1:0),Je=Je+de,It=It+Ae+(Je>>>0>>0?1:0),We=et+Pt,it=Ue+Ye+(We>>>0>>0?1:0);le=ne,xe=K,ne=ve,K=Z,ve=_e,Z=W,W=re+Je|0,_e=he+It+(W>>>0>>0?1:0)|0,he=we,re=Se,we=ae,Se=pe,ae=ee,pe=q,q=Je+We|0,ee=It+it+(q>>>0>>0?1:0)|0}Y=T.low=Y+q,T.high=z+ee+(Y>>>0>>0?1:0),o=k.low=o+pe,k.high=b+ae+(o>>>0>>0?1:0),c=R.low=c+Se,R.high=u+we+(c>>>0>>0?1:0),g=$.low=g+re,$.high=h+he+(g>>>0>>0?1:0),E=L.low=E+W,L.high=x+_e+(E>>>0>>0?1:0),l=j.low=l+Z,j.high=v+ve+(l>>>0>>0?1:0),P=A.low=P+K,A.high=m+ne+(P>>>0>>0?1:0),F=V.low=F+xe,V.high=N+le+(F>>>0>>0?1:0)},_doFinalize:function(){var M=this._data,C=M.words,O=this._nDataBytes*8,T=M.sigBytes*8;C[T>>>5]|=128<<24-T%32,C[(T+128>>>10<<5)+30]=Math.floor(O/4294967296),C[(T+128>>>10<<5)+31]=O,M.sigBytes=C.length*4,this._process();var k=this._hash.toX32();return k},clone:function(){var M=a.clone.call(this);return M._hash=this._hash.clone(),M},blockSize:1024/32});n.SHA512=a._createHelper(S),n.HmacSHA512=a._createHmacHelper(S)}(),r.SHA512})}(sx)),sx.exports}var lx={exports:{}},cC;function sie(){return cC||(cC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),tw(),KL())})(Ut,function(r){return function(){var n=r,i=n.x64,a=i.Word,s=i.WordArray,f=n.algo,d=f.SHA512,p=f.SHA384=d.extend({_doReset:function(){this._hash=new s.init([new a.init(3418070365,3238371032),new a.init(1654270250,914150663),new a.init(2438529370,812702999),new a.init(355462360,4144912697),new a.init(1731405415,4290775857),new a.init(2394180231,1750603025),new a.init(3675008525,1694076839),new a.init(1203062813,3204075428)])},_doFinalize:function(){var y=d._doFinalize.call(this);return y.sigBytes-=16,y}});n.SHA384=d._createHelper(p),n.HmacSHA384=d._createHmacHelper(p)}(),r.SHA384})}(lx)),lx.exports}var ux={exports:{}},fC;function lie(){return fC||(fC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),tw())})(Ut,function(r){return function(n){var i=r,a=i.lib,s=a.WordArray,f=a.Hasher,d=i.x64,p=d.Word,y=i.algo,w=[],_=[],S=[];(function(){for(var O=1,T=0,k=0;k<24;k++){w[O+5*T]=(k+1)*(k+2)/2%64;var R=T%5,$=(2*O+3*T)%5;O=R,T=$}for(var O=0;O<5;O++)for(var T=0;T<5;T++)_[O+5*T]=T+(2*O+3*T)%5*5;for(var L=1,j=0;j<24;j++){for(var A=0,V=0,z=0;z<7;z++){if(L&1){var Y=(1<>>24)&16711935|(L<<24|L>>>8)&4278255360,j=(j<<8|j>>>24)&16711935|(j<<24|j>>>8)&4278255360;var A=k[$];A.high^=j,A.low^=L}for(var V=0;V<24;V++){for(var z=0;z<5;z++){for(var Y=0,b=0,o=0;o<5;o++){var A=k[z+5*o];Y^=A.high,b^=A.low}var u=M[z];u.high=Y,u.low=b}for(var z=0;z<5;z++)for(var c=M[(z+4)%5],h=M[(z+1)%5],g=h.high,x=h.low,Y=c.high^(g<<1|x>>>31),b=c.low^(x<<1|g>>>31),o=0;o<5;o++){var A=k[z+5*o];A.high^=Y,A.low^=b}for(var E=1;E<25;E++){var Y,b,A=k[E],v=A.high,l=A.low,m=w[E];m<32?(Y=v<>>32-m,b=l<>>32-m):(Y=l<>>64-m,b=v<>>64-m);var P=M[_[E]];P.high=Y,P.low=b}var N=M[0],F=k[0];N.high=F.high,N.low=F.low;for(var z=0;z<5;z++)for(var o=0;o<5;o++){var E=z+5*o,A=k[E],ee=M[E],q=M[(z+1)%5+5*o],ae=M[(z+2)%5+5*o];A.high=ee.high^~q.high&ae.high,A.low=ee.low^~q.low&ae.low}var A=k[0],pe=S[V];A.high^=pe.high,A.low^=pe.low}},_doFinalize:function(){var O=this._data,T=O.words;this._nDataBytes*8;var k=O.sigBytes*8,R=this.blockSize*32;T[k>>>5]|=1<<24-k%32,T[(n.ceil((k+1)/R)*R>>>5)-1]|=128,O.sigBytes=T.length*4,this._process();for(var $=this._state,L=this.cfg.outputLength/8,j=L/8,A=[],V=0;V>>24)&16711935|(Y<<24|Y>>>8)&4278255360,b=(b<<8|b>>>24)&16711935|(b<<24|b>>>8)&4278255360,A.push(b),A.push(Y)}return new s.init(A,L)},clone:function(){for(var O=f.clone.call(this),T=O._state=this._state.slice(0),k=0;k<25;k++)T[k]=T[k].clone();return O}});i.SHA3=f._createHelper(C),i.HmacSHA3=f._createHmacHelper(C)}(Math),r.SHA3})}(ux)),ux.exports}var cx={exports:{}},dC;function uie(){return dC||(dC=1,function(e,t){(function(r,n){e.exports=n(Cr())})(Ut,function(r){/** @preserve (c) 2012 by Cédric Mesnil. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */return function(n){var i=r,a=i.lib,s=a.WordArray,f=a.Hasher,d=i.algo,p=s.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13]),y=s.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),w=s.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),_=s.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),S=s.create([0,1518500249,1859775393,2400959708,2840853838]),M=s.create([1352829926,1548603684,1836072691,2053994217,0]),C=d.RIPEMD160=f.extend({_doReset:function(){this._hash=s.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(j,A){for(var V=0;V<16;V++){var z=A+V,Y=j[z];j[z]=(Y<<8|Y>>>24)&16711935|(Y<<24|Y>>>8)&4278255360}var b=this._hash.words,o=S.words,u=M.words,c=p.words,h=y.words,g=w.words,x=_.words,E,v,l,m,P,N,F,ee,q,ae;N=E=b[0],F=v=b[1],ee=l=b[2],q=m=b[3],ae=P=b[4];for(var pe,V=0;V<80;V+=1)pe=E+j[A+c[V]]|0,V<16?pe+=O(v,l,m)+o[0]:V<32?pe+=T(v,l,m)+o[1]:V<48?pe+=k(v,l,m)+o[2]:V<64?pe+=R(v,l,m)+o[3]:pe+=$(v,l,m)+o[4],pe=pe|0,pe=L(pe,g[V]),pe=pe+P|0,E=P,P=m,m=L(l,10),l=v,v=pe,pe=N+j[A+h[V]]|0,V<16?pe+=$(F,ee,q)+u[0]:V<32?pe+=R(F,ee,q)+u[1]:V<48?pe+=k(F,ee,q)+u[2]:V<64?pe+=T(F,ee,q)+u[3]:pe+=O(F,ee,q)+u[4],pe=pe|0,pe=L(pe,x[V]),pe=pe+ae|0,N=ae,ae=q,q=L(ee,10),ee=F,F=pe;pe=b[1]+l+q|0,b[1]=b[2]+m+ae|0,b[2]=b[3]+P+N|0,b[3]=b[4]+E+F|0,b[4]=b[0]+v+ee|0,b[0]=pe},_doFinalize:function(){var j=this._data,A=j.words,V=this._nDataBytes*8,z=j.sigBytes*8;A[z>>>5]|=128<<24-z%32,A[(z+64>>>9<<4)+14]=(V<<8|V>>>24)&16711935|(V<<24|V>>>8)&4278255360,j.sigBytes=(A.length+1)*4,this._process();for(var Y=this._hash,b=Y.words,o=0;o<5;o++){var u=b[o];b[o]=(u<<8|u>>>24)&16711935|(u<<24|u>>>8)&4278255360}return Y},clone:function(){var j=f.clone.call(this);return j._hash=this._hash.clone(),j}});function O(j,A,V){return j^A^V}function T(j,A,V){return j&A|~j&V}function k(j,A,V){return(j|~A)^V}function R(j,A,V){return j&V|A&~V}function $(j,A,V){return j^(A|~V)}function L(j,A){return j<>>32-A}i.RIPEMD160=f._createHelper(C),i.HmacRIPEMD160=f._createHmacHelper(C)}(),r.RIPEMD160})}(cx)),cx.exports}var fx={exports:{}},hC;function K5(){return hC||(hC=1,function(e,t){(function(r,n){e.exports=n(Cr())})(Ut,function(r){(function(){var n=r,i=n.lib,a=i.Base,s=n.enc,f=s.Utf8,d=n.algo;d.HMAC=a.extend({init:function(p,y){p=this._hasher=new p.init,typeof y=="string"&&(y=f.parse(y));var w=p.blockSize,_=w*4;y.sigBytes>_&&(y=p.finalize(y)),y.clamp();for(var S=this._oKey=y.clone(),M=this._iKey=y.clone(),C=S.words,O=M.words,T=0;T>>2]&255;Y.sigBytes-=b}};a.BlockCipher=S.extend({cfg:S.cfg.extend({mode:O,padding:k}),reset:function(){var Y;S.reset.call(this);var b=this.cfg,o=b.iv,u=b.mode;this._xformMode==this._ENC_XFORM_MODE?Y=u.createEncryptor:(Y=u.createDecryptor,this._minBufferSize=1),this._mode&&this._mode.__creator==Y?this._mode.init(this,o&&o.words):(this._mode=Y.call(u,this,o&&o.words),this._mode.__creator=Y)},_doProcessBlock:function(Y,b){this._mode.processBlock(Y,b)},_doFinalize:function(){var Y,b=this.cfg.padding;return this._xformMode==this._ENC_XFORM_MODE?(b.pad(this._data,this.blockSize),Y=this._process(!0)):(Y=this._process(!0),b.unpad(Y)),Y},blockSize:128/32});var R=a.CipherParams=s.extend({init:function(Y){this.mixIn(Y)},toString:function(Y){return(Y||this.formatter).stringify(this)}}),$=i.format={},L=$.OpenSSL={stringify:function(Y){var b,o=Y.ciphertext,u=Y.salt;return u?b=f.create([1398893684,1701076831]).concat(u).concat(o):b=o,b.toString(y)},parse:function(Y){var b,o=y.parse(Y),u=o.words;return u[0]==1398893684&&u[1]==1701076831&&(b=f.create(u.slice(2,4)),u.splice(0,4),o.sigBytes-=16),R.create({ciphertext:o,salt:b})}},j=a.SerializableCipher=s.extend({cfg:s.extend({format:L}),encrypt:function(Y,b,o,u){u=this.cfg.extend(u);var c=Y.createEncryptor(o,u),h=c.finalize(b),g=c.cfg;return R.create({ciphertext:h,key:o,iv:g.iv,algorithm:Y,mode:g.mode,padding:g.padding,blockSize:Y.blockSize,formatter:u.format})},decrypt:function(Y,b,o,u){u=this.cfg.extend(u),b=this._parse(b,u.format);var c=Y.createDecryptor(o,u).finalize(b.ciphertext);return c},_parse:function(Y,b){return typeof Y=="string"?b.parse(Y,this):Y}}),A=i.kdf={},V=A.OpenSSL={execute:function(Y,b,o,u){u||(u=f.random(64/8));var c=_.create({keySize:b+o}).compute(Y,u),h=f.create(c.words.slice(b),o*4);return c.sigBytes=b*4,R.create({key:c,iv:h,salt:u})}},z=a.PasswordBasedCipher=j.extend({cfg:j.cfg.extend({kdf:V}),encrypt:function(Y,b,o,u){u=this.cfg.extend(u);var c=u.kdf.execute(o,Y.keySize,Y.ivSize);u.iv=c.iv;var h=j.encrypt.call(this,Y,b,c.key,u);return h.mixIn(c),h},decrypt:function(Y,b,o,u){u=this.cfg.extend(u),b=this._parse(b,u.format);var c=u.kdf.execute(o,Y.keySize,Y.ivSize,b.salt);u.iv=c.iv;var h=j.decrypt.call(this,Y,b,c.key,u);return h}})}()})}(px)),px.exports}var mx={exports:{}},gC;function fie(){return gC||(gC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),ei())})(Ut,function(r){return r.mode.CFB=function(){var n=r.lib.BlockCipherMode.extend();n.Encryptor=n.extend({processBlock:function(a,s){var f=this._cipher,d=f.blockSize;i.call(this,a,s,d,f),this._prevBlock=a.slice(s,s+d)}}),n.Decryptor=n.extend({processBlock:function(a,s){var f=this._cipher,d=f.blockSize,p=a.slice(s,s+d);i.call(this,a,s,d,f),this._prevBlock=p}});function i(a,s,f,d){var p,y=this._iv;y?(p=y.slice(0),this._iv=void 0):p=this._prevBlock,d.encryptBlock(p,0);for(var w=0;w>24&255)===255){var d=f>>16&255,p=f>>8&255,y=f&255;d===255?(d=0,p===255?(p=0,y===255?y=0:++y):++p):++d,f=0,f+=d<<16,f+=p<<8,f+=y}else f+=1<<24;return f}function a(f){return(f[0]=i(f[0]))===0&&(f[1]=i(f[1])),f}var s=n.Encryptor=n.extend({processBlock:function(f,d){var p=this._cipher,y=p.blockSize,w=this._iv,_=this._counter;w&&(_=this._counter=w.slice(0),this._iv=void 0),a(_);var S=_.slice(0);p.encryptBlock(S,0);for(var M=0;M>>2]|=f<<24-d%4*8,n.sigBytes+=f},unpad:function(n){var i=n.words[n.sigBytes-1>>>2]&255;n.sigBytes-=i}},r.pad.Ansix923})}(bx)),bx.exports}var xx={exports:{}},SC;function gie(){return SC||(SC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),ei())})(Ut,function(r){return r.pad.Iso10126={pad:function(n,i){var a=i*4,s=a-n.sigBytes%a;n.concat(r.lib.WordArray.random(s-1)).concat(r.lib.WordArray.create([s<<24],1))},unpad:function(n){var i=n.words[n.sigBytes-1>>>2]&255;n.sigBytes-=i}},r.pad.Iso10126})}(xx)),xx.exports}var _x={exports:{}},MC;function yie(){return MC||(MC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),ei())})(Ut,function(r){return r.pad.Iso97971={pad:function(n,i){n.concat(r.lib.WordArray.create([2147483648],1)),r.pad.ZeroPadding.pad(n,i)},unpad:function(n){r.pad.ZeroPadding.unpad(n),n.sigBytes--}},r.pad.Iso97971})}(_x)),_x.exports}var Sx={exports:{}},EC;function wie(){return EC||(EC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),ei())})(Ut,function(r){return r.pad.ZeroPadding={pad:function(n,i){var a=i*4;n.clamp(),n.sigBytes+=a-(n.sigBytes%a||a)},unpad:function(n){for(var i=n.words,a=n.sigBytes-1,a=n.sigBytes-1;a>=0;a--)if(i[a>>>2]>>>24-a%4*8&255){n.sigBytes=a+1;break}}},r.pad.ZeroPadding})}(Sx)),Sx.exports}var Mx={exports:{}},kC;function bie(){return kC||(kC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),ei())})(Ut,function(r){return r.pad.NoPadding={pad:function(){},unpad:function(){}},r.pad.NoPadding})}(Mx)),Mx.exports}var Ex={exports:{}},TC;function xie(){return TC||(TC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),ei())})(Ut,function(r){return function(n){var i=r,a=i.lib,s=a.CipherParams,f=i.enc,d=f.Hex,p=i.format;p.Hex={stringify:function(y){return y.ciphertext.toString(d)},parse:function(y){var w=d.parse(y);return s.create({ciphertext:w})}}}(),r.format.Hex})}(Ex)),Ex.exports}var kx={exports:{}},CC;function _ie(){return CC||(CC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),Nd(),jd(),kc(),ei())})(Ut,function(r){return function(){var n=r,i=n.lib,a=i.BlockCipher,s=n.algo,f=[],d=[],p=[],y=[],w=[],_=[],S=[],M=[],C=[],O=[];(function(){for(var R=[],$=0;$<256;$++)$<128?R[$]=$<<1:R[$]=$<<1^283;for(var L=0,j=0,$=0;$<256;$++){var A=j^j<<1^j<<2^j<<3^j<<4;A=A>>>8^A&255^99,f[L]=A,d[A]=L;var V=R[L],z=R[V],Y=R[z],b=R[A]*257^A*16843008;p[L]=b<<24|b>>>8,y[L]=b<<16|b>>>16,w[L]=b<<8|b>>>24,_[L]=b;var b=Y*16843009^z*65537^V*257^L*16843008;S[A]=b<<24|b>>>8,M[A]=b<<16|b>>>16,C[A]=b<<8|b>>>24,O[A]=b,L?(L=V^R[R[R[Y^V]]],j^=R[R[j]]):L=j=1}})();var T=[0,1,2,4,8,16,32,64,128,27,54],k=s.AES=a.extend({_doReset:function(){var R;if(!(this._nRounds&&this._keyPriorReset===this._key)){for(var $=this._keyPriorReset=this._key,L=$.words,j=$.sigBytes/4,A=this._nRounds=j+6,V=(A+1)*4,z=this._keySchedule=[],Y=0;Y6&&Y%j==4&&(R=f[R>>>24]<<24|f[R>>>16&255]<<16|f[R>>>8&255]<<8|f[R&255]):(R=R<<8|R>>>24,R=f[R>>>24]<<24|f[R>>>16&255]<<16|f[R>>>8&255]<<8|f[R&255],R^=T[Y/j|0]<<24),z[Y]=z[Y-j]^R);for(var b=this._invKeySchedule=[],o=0;o>>24]]^M[f[R>>>16&255]]^C[f[R>>>8&255]]^O[f[R&255]]}}},encryptBlock:function(R,$){this._doCryptBlock(R,$,this._keySchedule,p,y,w,_,f)},decryptBlock:function(R,$){var L=R[$+1];R[$+1]=R[$+3],R[$+3]=L,this._doCryptBlock(R,$,this._invKeySchedule,S,M,C,O,d);var L=R[$+1];R[$+1]=R[$+3],R[$+3]=L},_doCryptBlock:function(R,$,L,j,A,V,z,Y){for(var b=this._nRounds,o=R[$]^L[0],u=R[$+1]^L[1],c=R[$+2]^L[2],h=R[$+3]^L[3],g=4,x=1;x>>24]^A[u>>>16&255]^V[c>>>8&255]^z[h&255]^L[g++],v=j[u>>>24]^A[c>>>16&255]^V[h>>>8&255]^z[o&255]^L[g++],l=j[c>>>24]^A[h>>>16&255]^V[o>>>8&255]^z[u&255]^L[g++],m=j[h>>>24]^A[o>>>16&255]^V[u>>>8&255]^z[c&255]^L[g++];o=E,u=v,c=l,h=m}var E=(Y[o>>>24]<<24|Y[u>>>16&255]<<16|Y[c>>>8&255]<<8|Y[h&255])^L[g++],v=(Y[u>>>24]<<24|Y[c>>>16&255]<<16|Y[h>>>8&255]<<8|Y[o&255])^L[g++],l=(Y[c>>>24]<<24|Y[h>>>16&255]<<16|Y[o>>>8&255]<<8|Y[u&255])^L[g++],m=(Y[h>>>24]<<24|Y[o>>>16&255]<<16|Y[u>>>8&255]<<8|Y[c&255])^L[g++];R[$]=E,R[$+1]=v,R[$+2]=l,R[$+3]=m},keySize:256/32});n.AES=a._createHelper(k)}(),r.AES})}(kx)),kx.exports}var Tx={exports:{}},PC;function Sie(){return PC||(PC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),Nd(),jd(),kc(),ei())})(Ut,function(r){return function(){var n=r,i=n.lib,a=i.WordArray,s=i.BlockCipher,f=n.algo,d=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],p=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],y=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],w=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],_=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],S=f.DES=s.extend({_doReset:function(){for(var T=this._key,k=T.words,R=[],$=0;$<56;$++){var L=d[$]-1;R[$]=k[L>>>5]>>>31-L%32&1}for(var j=this._subKeys=[],A=0;A<16;A++){for(var V=j[A]=[],z=y[A],$=0;$<24;$++)V[$/6|0]|=R[(p[$]-1+z)%28]<<31-$%6,V[4+($/6|0)]|=R[28+(p[$+24]-1+z)%28]<<31-$%6;V[0]=V[0]<<1|V[0]>>>31;for(var $=1;$<7;$++)V[$]=V[$]>>>($-1)*4+3;V[7]=V[7]<<5|V[7]>>>27}for(var Y=this._invSubKeys=[],$=0;$<16;$++)Y[$]=j[15-$]},encryptBlock:function(T,k){this._doCryptBlock(T,k,this._subKeys)},decryptBlock:function(T,k){this._doCryptBlock(T,k,this._invSubKeys)},_doCryptBlock:function(T,k,R){this._lBlock=T[k],this._rBlock=T[k+1],M.call(this,4,252645135),M.call(this,16,65535),C.call(this,2,858993459),C.call(this,8,16711935),M.call(this,1,1431655765);for(var $=0;$<16;$++){for(var L=R[$],j=this._lBlock,A=this._rBlock,V=0,z=0;z<8;z++)V|=w[z][((A^L[z])&_[z])>>>0];this._lBlock=A,this._rBlock=j^V}var Y=this._lBlock;this._lBlock=this._rBlock,this._rBlock=Y,M.call(this,1,1431655765),C.call(this,8,16711935),C.call(this,2,858993459),M.call(this,16,65535),M.call(this,4,252645135),T[k]=this._lBlock,T[k+1]=this._rBlock},keySize:64/32,ivSize:64/32,blockSize:64/32});function M(T,k){var R=(this._lBlock>>>T^this._rBlock)&k;this._rBlock^=R,this._lBlock^=R<>>T^this._lBlock)&k;this._lBlock^=R,this._rBlock^=R<192.");var R=k.slice(0,2),$=k.length<4?k.slice(0,2):k.slice(2,4),L=k.length<6?k.slice(0,2):k.slice(4,6);this._des1=S.createEncryptor(a.create(R)),this._des2=S.createEncryptor(a.create($)),this._des3=S.createEncryptor(a.create(L))},encryptBlock:function(T,k){this._des1.encryptBlock(T,k),this._des2.decryptBlock(T,k),this._des3.encryptBlock(T,k)},decryptBlock:function(T,k){this._des3.decryptBlock(T,k),this._des2.encryptBlock(T,k),this._des1.decryptBlock(T,k)},keySize:192/32,ivSize:64/32,blockSize:64/32});n.TripleDES=s._createHelper(O)}(),r.TripleDES})}(Tx)),Tx.exports}var Cx={exports:{}},OC;function Mie(){return OC||(OC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),Nd(),jd(),kc(),ei())})(Ut,function(r){return function(){var n=r,i=n.lib,a=i.StreamCipher,s=n.algo,f=s.RC4=a.extend({_doReset:function(){for(var y=this._key,w=y.words,_=y.sigBytes,S=this._S=[],M=0;M<256;M++)S[M]=M;for(var M=0,C=0;M<256;M++){var O=M%_,T=w[O>>>2]>>>24-O%4*8&255;C=(C+S[M]+T)%256;var k=S[M];S[M]=S[C],S[C]=k}this._i=this._j=0},_doProcessBlock:function(y,w){y[w]^=d.call(this)},keySize:256/32,ivSize:0});function d(){for(var y=this._S,w=this._i,_=this._j,S=0,M=0;M<4;M++){w=(w+1)%256,_=(_+y[w])%256;var C=y[w];y[w]=y[_],y[_]=C,S|=y[(y[w]+y[_])%256]<<24-M*8}return this._i=w,this._j=_,S}n.RC4=a._createHelper(f);var p=s.RC4Drop=f.extend({cfg:f.cfg.extend({drop:192}),_doReset:function(){f._doReset.call(this);for(var y=this.cfg.drop;y>0;y--)d.call(this)}});n.RC4Drop=a._createHelper(p)}(),r.RC4})}(Cx)),Cx.exports}var Px={exports:{}},RC;function Eie(){return RC||(RC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),Nd(),jd(),kc(),ei())})(Ut,function(r){return function(){var n=r,i=n.lib,a=i.StreamCipher,s=n.algo,f=[],d=[],p=[],y=s.Rabbit=a.extend({_doReset:function(){for(var _=this._key.words,S=this.cfg.iv,M=0;M<4;M++)_[M]=(_[M]<<8|_[M]>>>24)&16711935|(_[M]<<24|_[M]>>>8)&4278255360;var C=this._X=[_[0],_[3]<<16|_[2]>>>16,_[1],_[0]<<16|_[3]>>>16,_[2],_[1]<<16|_[0]>>>16,_[3],_[2]<<16|_[1]>>>16],O=this._C=[_[2]<<16|_[2]>>>16,_[0]&4294901760|_[1]&65535,_[3]<<16|_[3]>>>16,_[1]&4294901760|_[2]&65535,_[0]<<16|_[0]>>>16,_[2]&4294901760|_[3]&65535,_[1]<<16|_[1]>>>16,_[3]&4294901760|_[0]&65535];this._b=0;for(var M=0;M<4;M++)w.call(this);for(var M=0;M<8;M++)O[M]^=C[M+4&7];if(S){var T=S.words,k=T[0],R=T[1],$=(k<<8|k>>>24)&16711935|(k<<24|k>>>8)&4278255360,L=(R<<8|R>>>24)&16711935|(R<<24|R>>>8)&4278255360,j=$>>>16|L&4294901760,A=L<<16|$&65535;O[0]^=$,O[1]^=j,O[2]^=L,O[3]^=A,O[4]^=$,O[5]^=j,O[6]^=L,O[7]^=A;for(var M=0;M<4;M++)w.call(this)}},_doProcessBlock:function(_,S){var M=this._X;w.call(this),f[0]=M[0]^M[5]>>>16^M[3]<<16,f[1]=M[2]^M[7]>>>16^M[5]<<16,f[2]=M[4]^M[1]>>>16^M[7]<<16,f[3]=M[6]^M[3]>>>16^M[1]<<16;for(var C=0;C<4;C++)f[C]=(f[C]<<8|f[C]>>>24)&16711935|(f[C]<<24|f[C]>>>8)&4278255360,_[S+C]^=f[C]},blockSize:128/32,ivSize:64/32});function w(){for(var _=this._X,S=this._C,M=0;M<8;M++)d[M]=S[M];S[0]=S[0]+1295307597+this._b|0,S[1]=S[1]+3545052371+(S[0]>>>0>>0?1:0)|0,S[2]=S[2]+886263092+(S[1]>>>0>>0?1:0)|0,S[3]=S[3]+1295307597+(S[2]>>>0>>0?1:0)|0,S[4]=S[4]+3545052371+(S[3]>>>0>>0?1:0)|0,S[5]=S[5]+886263092+(S[4]>>>0>>0?1:0)|0,S[6]=S[6]+1295307597+(S[5]>>>0>>0?1:0)|0,S[7]=S[7]+3545052371+(S[6]>>>0>>0?1:0)|0,this._b=S[7]>>>0>>0?1:0;for(var M=0;M<8;M++){var C=_[M]+S[M],O=C&65535,T=C>>>16,k=((O*O>>>17)+O*T>>>15)+T*T,R=((C&4294901760)*C|0)+((C&65535)*C|0);p[M]=k^R}_[0]=p[0]+(p[7]<<16|p[7]>>>16)+(p[6]<<16|p[6]>>>16)|0,_[1]=p[1]+(p[0]<<8|p[0]>>>24)+p[7]|0,_[2]=p[2]+(p[1]<<16|p[1]>>>16)+(p[0]<<16|p[0]>>>16)|0,_[3]=p[3]+(p[2]<<8|p[2]>>>24)+p[1]|0,_[4]=p[4]+(p[3]<<16|p[3]>>>16)+(p[2]<<16|p[2]>>>16)|0,_[5]=p[5]+(p[4]<<8|p[4]>>>24)+p[3]|0,_[6]=p[6]+(p[5]<<16|p[5]>>>16)+(p[4]<<16|p[4]>>>16)|0,_[7]=p[7]+(p[6]<<8|p[6]>>>24)+p[5]|0}n.Rabbit=a._createHelper(y)}(),r.Rabbit})}(Px)),Px.exports}var Ox={exports:{}},AC;function kie(){return AC||(AC=1,function(e,t){(function(r,n,i){e.exports=n(Cr(),Nd(),jd(),kc(),ei())})(Ut,function(r){return function(){var n=r,i=n.lib,a=i.StreamCipher,s=n.algo,f=[],d=[],p=[],y=s.RabbitLegacy=a.extend({_doReset:function(){var _=this._key.words,S=this.cfg.iv,M=this._X=[_[0],_[3]<<16|_[2]>>>16,_[1],_[0]<<16|_[3]>>>16,_[2],_[1]<<16|_[0]>>>16,_[3],_[2]<<16|_[1]>>>16],C=this._C=[_[2]<<16|_[2]>>>16,_[0]&4294901760|_[1]&65535,_[3]<<16|_[3]>>>16,_[1]&4294901760|_[2]&65535,_[0]<<16|_[0]>>>16,_[2]&4294901760|_[3]&65535,_[1]<<16|_[1]>>>16,_[3]&4294901760|_[0]&65535];this._b=0;for(var O=0;O<4;O++)w.call(this);for(var O=0;O<8;O++)C[O]^=M[O+4&7];if(S){var T=S.words,k=T[0],R=T[1],$=(k<<8|k>>>24)&16711935|(k<<24|k>>>8)&4278255360,L=(R<<8|R>>>24)&16711935|(R<<24|R>>>8)&4278255360,j=$>>>16|L&4294901760,A=L<<16|$&65535;C[0]^=$,C[1]^=j,C[2]^=L,C[3]^=A,C[4]^=$,C[5]^=j,C[6]^=L,C[7]^=A;for(var O=0;O<4;O++)w.call(this)}},_doProcessBlock:function(_,S){var M=this._X;w.call(this),f[0]=M[0]^M[5]>>>16^M[3]<<16,f[1]=M[2]^M[7]>>>16^M[5]<<16,f[2]=M[4]^M[1]>>>16^M[7]<<16,f[3]=M[6]^M[3]>>>16^M[1]<<16;for(var C=0;C<4;C++)f[C]=(f[C]<<8|f[C]>>>24)&16711935|(f[C]<<24|f[C]>>>8)&4278255360,_[S+C]^=f[C]},blockSize:128/32,ivSize:64/32});function w(){for(var _=this._X,S=this._C,M=0;M<8;M++)d[M]=S[M];S[0]=S[0]+1295307597+this._b|0,S[1]=S[1]+3545052371+(S[0]>>>0>>0?1:0)|0,S[2]=S[2]+886263092+(S[1]>>>0>>0?1:0)|0,S[3]=S[3]+1295307597+(S[2]>>>0>>0?1:0)|0,S[4]=S[4]+3545052371+(S[3]>>>0>>0?1:0)|0,S[5]=S[5]+886263092+(S[4]>>>0>>0?1:0)|0,S[6]=S[6]+1295307597+(S[5]>>>0>>0?1:0)|0,S[7]=S[7]+3545052371+(S[6]>>>0>>0?1:0)|0,this._b=S[7]>>>0>>0?1:0;for(var M=0;M<8;M++){var C=_[M]+S[M],O=C&65535,T=C>>>16,k=((O*O>>>17)+O*T>>>15)+T*T,R=((C&4294901760)*C|0)+((C&65535)*C|0);p[M]=k^R}_[0]=p[0]+(p[7]<<16|p[7]>>>16)+(p[6]<<16|p[6]>>>16)|0,_[1]=p[1]+(p[0]<<8|p[0]>>>24)+p[7]|0,_[2]=p[2]+(p[1]<<16|p[1]>>>16)+(p[0]<<16|p[0]>>>16)|0,_[3]=p[3]+(p[2]<<8|p[2]>>>24)+p[1]|0,_[4]=p[4]+(p[3]<<16|p[3]>>>16)+(p[2]<<16|p[2]>>>16)|0,_[5]=p[5]+(p[4]<<8|p[4]>>>24)+p[3]|0,_[6]=p[6]+(p[5]<<16|p[5]>>>16)+(p[4]<<16|p[4]>>>16)|0,_[7]=p[7]+(p[6]<<8|p[6]>>>24)+p[5]|0}n.RabbitLegacy=a._createHelper(y)}(),r.RabbitLegacy})}(Ox)),Ox.exports}(function(e,t){(function(r,n,i){e.exports=n(Cr(),tw(),nie(),iie(),Nd(),aie(),jd(),W5(),WL(),oie(),KL(),sie(),lie(),uie(),K5(),cie(),kc(),ei(),fie(),die(),hie(),pie(),mie(),vie(),gie(),yie(),wie(),bie(),xie(),_ie(),Sie(),Mie(),Eie(),kie())})(Ut,function(r){return r})})(d$);var Tie=d$.exports;const Cie=te("usermanagement/getData",async e=>{let t={};const{q:r="",perPage:n=10,page:i=1,sort:a,sortColumn:s}=e,f=e.id;t.id=e.usertype==="MOS"?f:localStorage.Clientid,t.usertype=e.usertype||localStorage.UserType,t.Role=localStorage.Role,t.perPage=n,t.page=i,t.sort=a,t.sortColumn=s,t.q=r;const d=await ue,p=await ge(d,t);try{const w=await(await Q.post("api/user-management/get-user/",{EncParams:p})).json(),_=await Me(d,w);if(_.length===0||_==="There is no Record Found")return{params:e,data:[],allData:[],totalPages:0,no_Data:"There is no Record Found"};{const S=_.count,M=_.data;return{params:e,data:M.length<=n?M:tn(M,n,i),allData:M,totalPages:S,no_Data:[]}}}catch(y){throw console.error(y),y}}),FTe=te("Templateupload/Get_permission",async(e,{dispatch:t,getState:r})=>{const n=await ue,i=await ge(n,e);return await Q.post("api/get-permission/",{EncParams:i}).then(s=>s.json())}),zTe=te("Templateupload/resetMFA",async(e,{dispatch:t,getState:r})=>{const n=await ue,i=await ge(n,e),a=await Q.post("api/Authentication/mfa/reset/",{EncParams:i}).then(f=>f.json());return await Me(n,a)}),UTe=te("usermanagement/AddUser",async(e,{dispatch:t,getState:r})=>{const n=Un(),i=e.params,a=await ue,f=await ge(a,{params:i,Refid:n}),d=await Q.post("api/user-management/add-user/",{EncParams:f}).then(y=>y.json());return await Me(a,d)}),HTe=te("usermanagement/EditUser",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/user-management/edit-user/",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),VTe=te("usermanagement/deleteGetuser",async e=>{const t=await ue,r=await ge(t,e);return await Q.post("api/user-management/delete/",{EncParams:r}).then(i=>i.json())});te("usermanagement/get_userType",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/add-new-usertype/get_userType",{EncParams:r}).then(a=>a.json());return await Me(t,n)});te("usermanagement/get_userType_Name",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/user-management/get-user-type-name/",{EncParams:r}).then(a=>a.json());return await Me(t,n)});const qTe=te("usermanagement/getPermissionMenuData",async()=>{try{const e=await ue,r=await(await Q.get("api/user-management/permission/")).json(),n=await Me(e,r);return(s=>{const f={Menu:[]},d={};s.forEach(_=>{d[_.RefId]={RefID:_.RefId,MenuLabel:_.Menu_Label,Tooltip:_.Tool_tip,MenuUrl:_.Menu_url,MenuKey:_.Menu_key,MenuType:_.Menu_type,ParentID:_.ParentID,MenuActions:_.Menu_Action.map((S,M)=>({RefID:M+21,MenuLabel:S.charAt(0).toUpperCase()+S.slice(1),Tooltip:"",MenuUrl:"",MenuKey:`${_.Menu_key}_${S.toUpperCase()}`})),Menu:[]}}),s.sort((_,S)=>parseInt(_.Menu_order)-parseInt(S.Menu_order)).forEach(_=>{_.ParentID===0&&_.Menu_type==="Menu"?f.Menu.push(d[_.RefId]):d[_.ParentID]&&_.Menu_type==="Submenu"&&(d[_.ParentID].Menu.push(d[_.RefId]),d[_.ParentID].Menu.sort((S,M)=>parseInt(S.Menu_order)-parseInt(M.Menu_order)))});const y={Menu:[],RefID:"50",MenuLabel:"Prompt",Tooltip:"",MenuType:"Menu",MenuUrl:"/prompt",MenuKey:"PROMPT",ParentID:"",MenuActions:[{RefID:21,MenuLabel:"View",Tooltip:"",MenuUrl:"",MenuKey:"PROMPT_VIEW"}]};f.Menu.push(y);const w=localStorage.getItem("Role");return f.Menu=f.Menu.filter(_=>!(_.MenuKey==="PROMPTMASTER"&&w!=="Dev Admin")),f})(n)}catch(e){throw console.error("Error in getPermissionMenuData:",e),e}}),WTe=te("usermanagement/getUserData",async(e,{dispatch:t,getState:r})=>{const n=await ue,i=await ge(n,e),a=await Q.post("api/user-management/get-user-data/",{EncParams:i}).then(f=>f.json());return await Me(n,a)}),KTe=te("usermanagement/getAuditlogdata",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/user-management/get-audit-log-data/",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),GTe=te("usermanagement/auditLogdata",async e=>{e.Userid=localStorage.id,e.ParentUserId=localStorage.ParentUserId;const t=e.Refid.payload,r=await ue,n=await ge(r,{Data:e,ID:t}),i=await Q.post("api/user-management/add-audit-log-data/",{EncParams:n}).then(s=>s.json());return await Me(r,i)}),YTe=te("usermanagement/updateAuditlog",async e=>{e.Userid=localStorage.id;const t=await ue;e.ParentUserId=localStorage.ParentUserId||"";const r=await ge(t,e),n=await Q.post("api/user-management/update-audit-log-data/",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),XTe=te("usermanagement/DeleteAuditLogdata",async e=>{e.Userid=localStorage.id,e.ParentUserId=localStorage.ParentUserId;const t=await ue,r=await ge(t,e);return await Q.post("api/user-management/delete-audit-log/",{EncParams:r}).then(i=>i.json())}),ZTe=te("usermanagement/ViewAuditLog",async e=>{e.Userid=localStorage.id,e.ParentUserId=localStorage.ParentUserId;const t=await ue,r=await ge(t,e);return await Q.post("api/user-management/view-audit-log/",{EncParams:r}).then(i=>i.json())}),JTe=te("usermanagement/get_userType",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/user-type/get-user-type/",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),QTe=te("usermanagement/get_userType_Name",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/user-management/get-user-type-name/",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),eCe=te("usermanagement/getPermissionCheckboxKeys",async e=>{const t=await ue,r=await ge(t,e),n=await Q.post("api/user-management/get-permission-checkbox-keys/",{EncParams:r}).then(a=>a.json());return await Me(t,n)}),Pie=er({name:"usermanagement",initialState:{data:[],total:0,params:{},allData:[]},reducers:{updateData:(e,t)=>{e.data=t.payload},updateRealTime:f$},extraReducers:e=>{e.addCase(Cie.fulfilled,(t,r)=>{t.data=r.payload.data,t.allData=r.payload.allData,t.total=r.payload.totalPages,t.params=r.payload.params,t.no_Data=r.payload.no_Data})}}),Oie=Pie.reducer,tCe=te("VendorUserAllocation/UserNameAllocation",async()=>{const e=await ue,t=await Q.get("api/vendor-user-allocation/update-user-master").then(n=>n.json());return await Me(e,t)}),Rie=te("VendorUserAllocation/venorNameAllocation",async()=>{const e=await ue,t=await Q.get("api/vendor-user-allocation/get-vendor-names").then(n=>n.json());return await Me(e,t)}),rCe=te("Templateupload/Get_permission",async(e,{dispatch:t,getState:r})=>{const n=await ue,i=await ge(n,e);return await Q.post("api/get-permission/",{EncParams:i}).then(s=>s.json())}),nCe=te("VendorUserAllocation/files",async()=>await Q.get("api/vendor-user-allocation/get-files").then(t=>t.json())),iCe=te("VendorUserAllocation/vendorfiles",async(e,{dispatch:t,getState:r})=>{const n=await ue,i=await ge(n,e);return await Q.post("api/vendor-user-allocation/get-vendor-files",{EncParams:i}).then(s=>s.json())}),aCe=te("VendorUserAllocation/vendorusername",async(e,{dispatch:t,getState:r})=>{const n=await ue,i=await ge(n,e),a=await Q.post("api/vendor-user-allocation/get-usernames",{EncParams:i}).then(f=>f.json());return await Me(n,a)}),oCe=te("VendorUserAllocation/Allocation",async(e,{dispatch:t,getState:r})=>{const n=await ue,{payload:i}=e,a=await ge(n,i),s=await Q.post("api/vendor-user-allocation/allocate-files",{EncParams:a}).then(d=>d.json());return await Me(n,s)}),sCe=te("VendorUserAllocation/Allocationuserfiles",async(e,{dispatch:t,getState:r})=>{const{dropvalue:n}=e;if(n!=null){const i=await ue,a=await ge(i,n),s=await Q.post("api/vendor-user-allocation/get-allocations",{EncParams:a}).then(d=>d.json());return await Me(i,s)}}),lCe=te("VendorUserAllocation/selectionvendor",async(e,{dispatch:t,getState:r})=>{const{dropselectedvendorValue:n}=e,i=await ue,a=await ge(i,n),s=await Q.post("api/vendor-user-allocation/update-client",{EncParams:a}).then(d=>d.json());return await Me(i,s)}),uCe=te("VendorUserAllocation/AllocationfileAudit",async e=>{e.Userid=localStorage.id,e.ParentUserId=localStorage.ParentUserId;const t=await ue,r=await ge(t,e);return await Q.post("api/vendor-user-allocation/allocation-audit-log",{EncParams:r}).then(i=>i.json())}),Aie=er({name:"VendorUserAllocation",initialState:{data:[],total:1,params:{},allData:[]},reducers:{},extraReducers:e=>{e.addCase(Rie.fulfilled,(t,r)=>{t.data=r.payload.data,t.allData=r.payload.allData,t.total=r.payload.totalPages,t.params=r.payload.params})}}),Die=Aie.reducer;var $ie={exports:{}};/*! * jQuery JavaScript Library v3.7.0 * https://jquery.com/ * * Copyright OpenJS Foundation and other contributors * Released under the MIT license * https://jquery.org/license * * Date: 2023-05-11T18:29Z */(function(e){(function(t,r){e.exports=t.document?r(t,!0):function(n){if(!n.document)throw new Error("jQuery requires a window with a document");return r(n)}})(typeof window<"u"?window:Ut,function(t,r){var n=[],i=Object.getPrototypeOf,a=n.slice,s=n.flat?function(D){return n.flat.call(D)}:function(D){return n.concat.apply([],D)},f=n.push,d=n.indexOf,p={},y=p.toString,w=p.hasOwnProperty,_=w.toString,S=_.call(Object),M={},C=function(I){return typeof I=="function"&&typeof I.nodeType!="number"&&typeof I.item!="function"},O=function(I){return I!=null&&I===I.window},T=t.document,k={type:!0,src:!0,nonce:!0,noModule:!0};function R(D,I,U){U=U||T;var G,oe,se=U.createElement("script");if(se.text=D,I)for(G in k)oe=I[G]||I.getAttribute&&I.getAttribute(G),oe&&se.setAttribute(G,oe);U.head.appendChild(se).parentNode.removeChild(se)}function $(D){return D==null?D+"":typeof D=="object"||typeof D=="function"?p[y.call(D)]||"object":typeof D}var L="3.7.0",j=/HTML$/i,A=function(D,I){return new A.fn.init(D,I)};A.fn=A.prototype={jquery:L,constructor:A,length:0,toArray:function(){return a.call(this)},get:function(D){return D==null?a.call(this):D<0?this[D+this.length]:this[D]},pushStack:function(D){var I=A.merge(this.constructor(),D);return I.prevObject=this,I},each:function(D){return A.each(this,D)},map:function(D){return this.pushStack(A.map(this,function(I,U){return D.call(I,U,I)}))},slice:function(){return this.pushStack(a.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(A.grep(this,function(D,I){return(I+1)%2}))},odd:function(){return this.pushStack(A.grep(this,function(D,I){return I%2}))},eq:function(D){var I=this.length,U=+D+(D<0?I:0);return this.pushStack(U>=0&&U0&&I-1 in D}function z(D,I){return D.nodeName&&D.nodeName.toLowerCase()===I.toLowerCase()}var Y=n.pop,b=n.sort,o=n.splice,u="[\\x20\\t\\r\\n\\f]",c=new RegExp("^"+u+"+|((?:^|[^\\\\])(?:\\\\.)*)"+u+"+$","g");A.contains=function(D,I){var U=I&&I.parentNode;return D===U||!!(U&&U.nodeType===1&&(D.contains?D.contains(U):D.compareDocumentPosition&&D.compareDocumentPosition(U)&16))};var h=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\x80-\uFFFF\w-]/g;function g(D,I){return I?D==="\0"?"�":D.slice(0,-1)+"\\"+D.charCodeAt(D.length-1).toString(16)+" ":"\\"+D}A.escapeSelector=function(D){return(D+"").replace(h,g)};var x=T,E=f;(function(){var D,I,U,G,oe,se=E,me,Re,Ce,Ne,st,ct=A.expando,Ze=0,vt=0,Wt=Cs(),fr=Cs(),Qt=Cs(),vn=Cs(),un=function(Ee,Ie){return Ee===Ie&&(oe=!0),0},qn="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",xa="(?:\\\\[\\da-fA-F]{1,6}"+u+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",ur="\\["+u+"*("+xa+")(?:"+u+"*([*^$|!~]?=)"+u+`*(?:'((?:\\\\.|[^\\\\'])*)'|"((?:\\\\.|[^\\\\"])*)"|(`+xa+"))|)"+u+"*\\]",Ts=":("+xa+`)(?:\\((('((?:\\\\.|[^\\\\'])*)'|"((?:\\\\.|[^\\\\"])*)")|((?:\\\\.|[^\\\\()[\\]]|`+ur+")*)|.*)\\)|)",mr=new RegExp(u+"+","g"),Zr=new RegExp("^"+u+"*,"+u+"*"),cl=new RegExp("^"+u+"*([>+~]|"+u+")"+u+"*"),eh=new RegExp(u+"|>"),_a=new RegExp(Ts),_u=new RegExp("^"+xa+"$"),Sa={ID:new RegExp("^#("+xa+")"),CLASS:new RegExp("^\\.("+xa+")"),TAG:new RegExp("^("+xa+"|[*])"),ATTR:new RegExp("^"+ur),PSEUDO:new RegExp("^"+Ts),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+u+"*(even|odd|(([+-]|)(\\d*)n|)"+u+"*(?:([+-]|)"+u+"*(\\d+)|))"+u+"*\\)|)","i"),bool:new RegExp("^(?:"+qn+")$","i"),needsContext:new RegExp("^"+u+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+u+"*((?:-\\d)?\\d*)"+u+"*\\)|)(?=[^-]|$)","i")},no=/^(?:input|select|textarea|button)$/i,Io=/^h\d$/i,wi=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,th=/[+~]/,Ma=new RegExp("\\\\[\\da-fA-F]{1,6}"+u+"?|\\\\([^\\r\\n\\f])","g"),Zi=function(Ee,Ie){var Ke="0x"+Ee.slice(1)-65536;return Ie||(Ke<0?String.fromCharCode(Ke+65536):String.fromCharCode(Ke>>10|55296,Ke&1023|56320))},Sb=function(){Lo()},Mb=Oc(function(Ee){return Ee.disabled===!0&&z(Ee,"fieldset")},{dir:"parentNode",next:"legend"});function Eb(){try{return me.activeElement}catch{}}try{se.apply(n=a.call(x.childNodes),x.childNodes),n[x.childNodes.length].nodeType}catch{se={apply:function(Ie,Ke){E.apply(Ie,a.call(Ke))},call:function(Ie){E.apply(Ie,a.call(arguments,1))}}}function Lr(Ee,Ie,Ke,nt){var ft,wt,St,Rt,Mt,ir,$t,Gt=Ie&&Ie.ownerDocument,ar=Ie?Ie.nodeType:9;if(Ke=Ke||[],typeof Ee!="string"||!Ee||ar!==1&&ar!==9&&ar!==11)return Ke;if(!nt&&(Lo(Ie),Ie=Ie||me,Ce)){if(ar!==11&&(Mt=wi.exec(Ee)))if(ft=Mt[1]){if(ar===9)if(St=Ie.getElementById(ft)){if(St.id===ft)return se.call(Ke,St),Ke}else return Ke;else if(Gt&&(St=Gt.getElementById(ft))&&Lr.contains(Ie,St)&&St.id===ft)return se.call(Ke,St),Ke}else{if(Mt[2])return se.apply(Ke,Ie.getElementsByTagName(Ee)),Ke;if((ft=Mt[3])&&Ie.getElementsByClassName)return se.apply(Ke,Ie.getElementsByClassName(ft)),Ke}if(!vn[Ee+" "]&&(!Ne||!Ne.test(Ee))){if($t=Ee,Gt=Ie,ar===1&&(eh.test(Ee)||cl.test(Ee))){for(Gt=th.test(Ee)&&nh(Ie.parentNode)||Ie,(Gt!=Ie||!M.scope)&&((Rt=Ie.getAttribute("id"))?Rt=A.escapeSelector(Rt):Ie.setAttribute("id",Rt=ct)),ir=Su(Ee),wt=ir.length;wt--;)ir[wt]=(Rt?"#"+Rt:":scope")+" "+Mu(ir[wt]);$t=ir.join(",")}try{return se.apply(Ke,Gt.querySelectorAll($t)),Ke}catch{vn(Ee,!0)}finally{Rt===ct&&Ie.removeAttribute("id")}}}return fm(Ee.replace(c,"$1"),Ie,Ke,nt)}function Cs(){var Ee=[];function Ie(Ke,nt){return Ee.push(Ke+" ")>I.cacheLength&&delete Ie[Ee.shift()],Ie[Ke+" "]=nt}return Ie}function Ji(Ee){return Ee[ct]=!0,Ee}function fl(Ee){var Ie=me.createElement("fieldset");try{return!!Ee(Ie)}catch{return!1}finally{Ie.parentNode&&Ie.parentNode.removeChild(Ie),Ie=null}}function kb(Ee){return function(Ie){return z(Ie,"input")&&Ie.type===Ee}}function Tb(Ee){return function(Ie){return(z(Ie,"input")||z(Ie,"button"))&&Ie.type===Ee}}function rh(Ee){return function(Ie){return"form"in Ie?Ie.parentNode&&Ie.disabled===!1?"label"in Ie?"label"in Ie.parentNode?Ie.parentNode.disabled===Ee:Ie.disabled===Ee:Ie.isDisabled===Ee||Ie.isDisabled!==!Ee&&Mb(Ie)===Ee:Ie.disabled===Ee:"label"in Ie?Ie.disabled===Ee:!1}}function Ps(Ee){return Ji(function(Ie){return Ie=+Ie,Ji(function(Ke,nt){for(var ft,wt=Ee([],Ke.length,Ie),St=wt.length;St--;)Ke[ft=wt[St]]&&(Ke[ft]=!(nt[ft]=Ke[ft]))})})}function nh(Ee){return Ee&&typeof Ee.getElementsByTagName<"u"&&Ee}function Lo(Ee){var Ie,Ke=Ee?Ee.ownerDocument||Ee:x;return Ke==me||Ke.nodeType!==9||!Ke.documentElement||(me=Ke,Re=me.documentElement,Ce=!A.isXMLDoc(me),st=Re.matches||Re.webkitMatchesSelector||Re.msMatchesSelector,x!=me&&(Ie=me.defaultView)&&Ie.top!==Ie&&Ie.addEventListener("unload",Sb),M.getById=fl(function(nt){return Re.appendChild(nt).id=A.expando,!me.getElementsByName||!me.getElementsByName(A.expando).length}),M.disconnectedMatch=fl(function(nt){return st.call(nt,"*")}),M.scope=fl(function(){return me.querySelectorAll(":scope")}),M.cssHas=fl(function(){try{return me.querySelector(":has(*,:jqfake)"),!1}catch{return!0}}),M.getById?(I.filter.ID=function(nt){var ft=nt.replace(Ma,Zi);return function(wt){return wt.getAttribute("id")===ft}},I.find.ID=function(nt,ft){if(typeof ft.getElementById<"u"&&Ce){var wt=ft.getElementById(nt);return wt?[wt]:[]}}):(I.filter.ID=function(nt){var ft=nt.replace(Ma,Zi);return function(wt){var St=typeof wt.getAttributeNode<"u"&&wt.getAttributeNode("id");return St&&St.value===ft}},I.find.ID=function(nt,ft){if(typeof ft.getElementById<"u"&&Ce){var wt,St,Rt,Mt=ft.getElementById(nt);if(Mt){if(wt=Mt.getAttributeNode("id"),wt&&wt.value===nt)return[Mt];for(Rt=ft.getElementsByName(nt),St=0;Mt=Rt[St++];)if(wt=Mt.getAttributeNode("id"),wt&&wt.value===nt)return[Mt]}return[]}}),I.find.TAG=function(nt,ft){return typeof ft.getElementsByTagName<"u"?ft.getElementsByTagName(nt):ft.querySelectorAll(nt)},I.find.CLASS=function(nt,ft){if(typeof ft.getElementsByClassName<"u"&&Ce)return ft.getElementsByClassName(nt)},Ne=[],fl(function(nt){var ft;Re.appendChild(nt).innerHTML="",nt.querySelectorAll("[selected]").length||Ne.push("\\["+u+"*(?:value|"+qn+")"),nt.querySelectorAll("[id~="+ct+"-]").length||Ne.push("~="),nt.querySelectorAll("a#"+ct+"+*").length||Ne.push(".#.+[+~]"),nt.querySelectorAll(":checked").length||Ne.push(":checked"),ft=me.createElement("input"),ft.setAttribute("type","hidden"),nt.appendChild(ft).setAttribute("name","D"),Re.appendChild(nt).disabled=!0,nt.querySelectorAll(":disabled").length!==2&&Ne.push(":enabled",":disabled"),ft=me.createElement("input"),ft.setAttribute("name",""),nt.appendChild(ft),nt.querySelectorAll("[name='']").length||Ne.push("\\["+u+"*name"+u+"*="+u+`*(?:''|"")`)}),M.cssHas||Ne.push(":has"),Ne=Ne.length&&new RegExp(Ne.join("|")),un=function(nt,ft){if(nt===ft)return oe=!0,0;var wt=!nt.compareDocumentPosition-!ft.compareDocumentPosition;return wt||(wt=(nt.ownerDocument||nt)==(ft.ownerDocument||ft)?nt.compareDocumentPosition(ft):1,wt&1||!M.sortDetached&&ft.compareDocumentPosition(nt)===wt?nt===me||nt.ownerDocument==x&&Lr.contains(x,nt)?-1:ft===me||ft.ownerDocument==x&&Lr.contains(x,ft)?1:G?d.call(G,nt)-d.call(G,ft):0:wt&4?-1:1)}),me}Lr.matches=function(Ee,Ie){return Lr(Ee,null,null,Ie)},Lr.matchesSelector=function(Ee,Ie){if(Lo(Ee),Ce&&!vn[Ie+" "]&&(!Ne||!Ne.test(Ie)))try{var Ke=st.call(Ee,Ie);if(Ke||M.disconnectedMatch||Ee.document&&Ee.document.nodeType!==11)return Ke}catch{vn(Ie,!0)}return Lr(Ie,me,null,[Ee]).length>0},Lr.contains=function(Ee,Ie){return(Ee.ownerDocument||Ee)!=me&&Lo(Ee),A.contains(Ee,Ie)},Lr.attr=function(Ee,Ie){(Ee.ownerDocument||Ee)!=me&&Lo(Ee);var Ke=I.attrHandle[Ie.toLowerCase()],nt=Ke&&w.call(I.attrHandle,Ie.toLowerCase())?Ke(Ee,Ie,!Ce):void 0;return nt!==void 0?nt:Ee.getAttribute(Ie)},Lr.error=function(Ee){throw new Error("Syntax error, unrecognized expression: "+Ee)},A.uniqueSort=function(Ee){var Ie,Ke=[],nt=0,ft=0;if(oe=!M.sortStable,G=!M.sortStable&&a.call(Ee,0),b.call(Ee,un),oe){for(;Ie=Ee[ft++];)Ie===Ee[ft]&&(nt=Ke.push(ft));for(;nt--;)o.call(Ee,Ke[nt],1)}return G=null,Ee},A.fn.uniqueSort=function(){return this.pushStack(A.uniqueSort(a.apply(this)))},I=A.expr={cacheLength:50,createPseudo:Ji,match:Sa,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(Ee){return Ee[1]=Ee[1].replace(Ma,Zi),Ee[3]=(Ee[3]||Ee[4]||Ee[5]||"").replace(Ma,Zi),Ee[2]==="~="&&(Ee[3]=" "+Ee[3]+" "),Ee.slice(0,4)},CHILD:function(Ee){return Ee[1]=Ee[1].toLowerCase(),Ee[1].slice(0,3)==="nth"?(Ee[3]||Lr.error(Ee[0]),Ee[4]=+(Ee[4]?Ee[5]+(Ee[6]||1):2*(Ee[3]==="even"||Ee[3]==="odd")),Ee[5]=+(Ee[7]+Ee[8]||Ee[3]==="odd")):Ee[3]&&Lr.error(Ee[0]),Ee},PSEUDO:function(Ee){var Ie,Ke=!Ee[6]&&Ee[2];return Sa.CHILD.test(Ee[0])?null:(Ee[3]?Ee[2]=Ee[4]||Ee[5]||"":Ke&&_a.test(Ke)&&(Ie=Su(Ke,!0))&&(Ie=Ke.indexOf(")",Ke.length-Ie)-Ke.length)&&(Ee[0]=Ee[0].slice(0,Ie),Ee[2]=Ke.slice(0,Ie)),Ee.slice(0,3))}},filter:{TAG:function(Ee){var Ie=Ee.replace(Ma,Zi).toLowerCase();return Ee==="*"?function(){return!0}:function(Ke){return z(Ke,Ie)}},CLASS:function(Ee){var Ie=Wt[Ee+" "];return Ie||(Ie=new RegExp("(^|"+u+")"+Ee+"("+u+"|$)"))&&Wt(Ee,function(Ke){return Ie.test(typeof Ke.className=="string"&&Ke.className||typeof Ke.getAttribute<"u"&&Ke.getAttribute("class")||"")})},ATTR:function(Ee,Ie,Ke){return function(nt){var ft=Lr.attr(nt,Ee);return ft==null?Ie==="!=":Ie?(ft+="",Ie==="="?ft===Ke:Ie==="!="?ft!==Ke:Ie==="^="?Ke&&ft.indexOf(Ke)===0:Ie==="*="?Ke&&ft.indexOf(Ke)>-1:Ie==="$="?Ke&&ft.slice(-Ke.length)===Ke:Ie==="~="?(" "+ft.replace(mr," ")+" ").indexOf(Ke)>-1:Ie==="|="?ft===Ke||ft.slice(0,Ke.length+1)===Ke+"-":!1):!0}},CHILD:function(Ee,Ie,Ke,nt,ft){var wt=Ee.slice(0,3)!=="nth",St=Ee.slice(-4)!=="last",Rt=Ie==="of-type";return nt===1&&ft===0?function(Mt){return!!Mt.parentNode}:function(Mt,ir,$t){var Gt,ar,Nt,zr,ti,An=wt!==St?"nextSibling":"previousSibling",bi=Mt.parentNode,Ea=Rt&&Mt.nodeName.toLowerCase(),dl=!$t&&!Rt,Wn=!1;if(bi){if(wt){for(;An;){for(Nt=Mt;Nt=Nt[An];)if(Rt?z(Nt,Ea):Nt.nodeType===1)return!1;ti=An=Ee==="only"&&!ti&&"nextSibling"}return!0}if(ti=[St?bi.firstChild:bi.lastChild],St&&dl){for(ar=bi[ct]||(bi[ct]={}),Gt=ar[Ee]||[],zr=Gt[0]===Ze&&Gt[1],Wn=zr&&Gt[2],Nt=zr&&bi.childNodes[zr];Nt=++zr&&Nt&&Nt[An]||(Wn=zr=0)||ti.pop();)if(Nt.nodeType===1&&++Wn&&Nt===Mt){ar[Ee]=[Ze,zr,Wn];break}}else if(dl&&(ar=Mt[ct]||(Mt[ct]={}),Gt=ar[Ee]||[],zr=Gt[0]===Ze&&Gt[1],Wn=zr),Wn===!1)for(;(Nt=++zr&&Nt&&Nt[An]||(Wn=zr=0)||ti.pop())&&!((Rt?z(Nt,Ea):Nt.nodeType===1)&&++Wn&&(dl&&(ar=Nt[ct]||(Nt[ct]={}),ar[Ee]=[Ze,Wn]),Nt===Mt)););return Wn-=ft,Wn===nt||Wn%nt===0&&Wn/nt>=0}}},PSEUDO:function(Ee,Ie){var Ke,nt=I.pseudos[Ee]||I.setFilters[Ee.toLowerCase()]||Lr.error("unsupported pseudo: "+Ee);return nt[ct]?nt(Ie):nt.length>1?(Ke=[Ee,Ee,"",Ie],I.setFilters.hasOwnProperty(Ee.toLowerCase())?Ji(function(ft,wt){for(var St,Rt=nt(ft,Ie),Mt=Rt.length;Mt--;)St=d.call(ft,Rt[Mt]),ft[St]=!(wt[St]=Rt[Mt])}):function(ft){return nt(ft,0,Ke)}):nt}},pseudos:{not:Ji(function(Ee){var Ie=[],Ke=[],nt=oh(Ee.replace(c,"$1"));return nt[ct]?Ji(function(ft,wt,St,Rt){for(var Mt,ir=nt(ft,null,Rt,[]),$t=ft.length;$t--;)(Mt=ir[$t])&&(ft[$t]=!(wt[$t]=Mt))}):function(ft,wt,St){return Ie[0]=ft,nt(Ie,null,St,Ke),Ie[0]=null,!Ke.pop()}}),has:Ji(function(Ee){return function(Ie){return Lr(Ee,Ie).length>0}}),contains:Ji(function(Ee){return Ee=Ee.replace(Ma,Zi),function(Ie){return(Ie.textContent||A.text(Ie)).indexOf(Ee)>-1}}),lang:Ji(function(Ee){return _u.test(Ee||"")||Lr.error("unsupported lang: "+Ee),Ee=Ee.replace(Ma,Zi).toLowerCase(),function(Ie){var Ke;do if(Ke=Ce?Ie.lang:Ie.getAttribute("xml:lang")||Ie.getAttribute("lang"))return Ke=Ke.toLowerCase(),Ke===Ee||Ke.indexOf(Ee+"-")===0;while((Ie=Ie.parentNode)&&Ie.nodeType===1);return!1}}),target:function(Ee){var Ie=t.location&&t.location.hash;return Ie&&Ie.slice(1)===Ee.id},root:function(Ee){return Ee===Re},focus:function(Ee){return Ee===Eb()&&me.hasFocus()&&!!(Ee.type||Ee.href||~Ee.tabIndex)},enabled:rh(!1),disabled:rh(!0),checked:function(Ee){return z(Ee,"input")&&!!Ee.checked||z(Ee,"option")&&!!Ee.selected},selected:function(Ee){return Ee.parentNode&&Ee.parentNode.selectedIndex,Ee.selected===!0},empty:function(Ee){for(Ee=Ee.firstChild;Ee;Ee=Ee.nextSibling)if(Ee.nodeType<6)return!1;return!0},parent:function(Ee){return!I.pseudos.empty(Ee)},header:function(Ee){return Io.test(Ee.nodeName)},input:function(Ee){return no.test(Ee.nodeName)},button:function(Ee){return z(Ee,"input")&&Ee.type==="button"||z(Ee,"button")},text:function(Ee){var Ie;return z(Ee,"input")&&Ee.type==="text"&&((Ie=Ee.getAttribute("type"))==null||Ie.toLowerCase()==="text")},first:Ps(function(){return[0]}),last:Ps(function(Ee,Ie){return[Ie-1]}),eq:Ps(function(Ee,Ie,Ke){return[Ke<0?Ke+Ie:Ke]}),even:Ps(function(Ee,Ie){for(var Ke=0;KeIe?nt=Ie:nt=Ke;--nt>=0;)Ee.push(nt);return Ee}),gt:Ps(function(Ee,Ie,Ke){for(var nt=Ke<0?Ke+Ie:Ke;++nt1?function(Ie,Ke,nt){for(var ft=Ee.length;ft--;)if(!Ee[ft](Ie,Ke,nt))return!1;return!0}:Ee[0]}function Cb(Ee,Ie,Ke){for(var nt=0,ft=Ie.length;nt-1&&(St[$t]=!(Rt[$t]=ar))}}else Nt=Eu(Nt===Rt?Nt.splice(An,Nt.length):Nt),ft?ft(null,Rt,Nt,ir):se.apply(Rt,Nt)})}function ah(Ee){for(var Ie,Ke,nt,ft=Ee.length,wt=I.relative[Ee[0].type],St=wt||I.relative[" "],Rt=wt?1:0,Mt=Oc(function(Gt){return Gt===Ie},St,!0),ir=Oc(function(Gt){return d.call(Ie,Gt)>-1},St,!0),$t=[function(Gt,ar,Nt){var zr=!wt&&(Nt||ar!=U)||((Ie=ar).nodeType?Mt(Gt,ar,Nt):ir(Gt,ar,Nt));return Ie=null,zr}];Rt1&&ih($t),Rt>1&&Mu(Ee.slice(0,Rt-1).concat({value:Ee[Rt-2].type===" "?"*":""})).replace(c,"$1"),Ke,Rt0,nt=Ee.length>0,ft=function(wt,St,Rt,Mt,ir){var $t,Gt,ar,Nt=0,zr="0",ti=wt&&[],An=[],bi=U,Ea=wt||nt&&I.find.TAG("*",ir),dl=Ze+=bi==null?1:Math.random()||.1,Wn=Ea.length;for(ir&&(U=St==me||St||ir);zr!==Wn&&($t=Ea[zr])!=null;zr++){if(nt&&$t){for(Gt=0,!St&&$t.ownerDocument!=me&&(Lo($t),Rt=!Ce);ar=Ee[Gt++];)if(ar($t,St||me,Rt)){se.call(Mt,$t);break}ir&&(Ze=dl)}Ke&&(($t=!ar&&$t)&&Nt--,wt&&ti.push($t))}if(Nt+=zr,Ke&&zr!==Nt){for(Gt=0;ar=Ie[Gt++];)ar(ti,An,St,Rt);if(wt){if(Nt>0)for(;zr--;)ti[zr]||An[zr]||(An[zr]=Y.call(Mt));An=Eu(An)}se.apply(Mt,An),ir&&!wt&&An.length>0&&Nt+Ie.length>1&&A.uniqueSort(Mt)}return ir&&(Ze=dl,U=bi),ti};return Ke?Ji(ft):ft}function oh(Ee,Ie){var Ke,nt=[],ft=[],wt=Qt[Ee+" "];if(!wt){for(Ie||(Ie=Su(Ee)),Ke=Ie.length;Ke--;)wt=ah(Ie[Ke]),wt[ct]?nt.push(wt):ft.push(wt);wt=Qt(Ee,Pb(ft,nt)),wt.selector=Ee}return wt}function fm(Ee,Ie,Ke,nt){var ft,wt,St,Rt,Mt,ir=typeof Ee=="function"&&Ee,$t=!nt&&Su(Ee=ir.selector||Ee);if(Ke=Ke||[],$t.length===1){if(wt=$t[0]=$t[0].slice(0),wt.length>2&&(St=wt[0]).type==="ID"&&Ie.nodeType===9&&Ce&&I.relative[wt[1].type]){if(Ie=(I.find.ID(St.matches[0].replace(Ma,Zi),Ie)||[])[0],Ie)ir&&(Ie=Ie.parentNode);else return Ke;Ee=Ee.slice(wt.shift().value.length)}for(ft=Sa.needsContext.test(Ee)?0:wt.length;ft--&&(St=wt[ft],!I.relative[Rt=St.type]);)if((Mt=I.find[Rt])&&(nt=Mt(St.matches[0].replace(Ma,Zi),th.test(wt[0].type)&&nh(Ie.parentNode)||Ie))){if(wt.splice(ft,1),Ee=nt.length&&Mu(wt),!Ee)return se.apply(Ke,nt),Ke;break}}return(ir||oh(Ee,$t))(nt,Ie,!Ce,Ke,!Ie||th.test(Ee)&&nh(Ie.parentNode)||Ie),Ke}M.sortStable=ct.split("").sort(un).join("")===ct,Lo(),M.sortDetached=fl(function(Ee){return Ee.compareDocumentPosition(me.createElement("fieldset"))&1}),A.find=Lr,A.expr[":"]=A.expr.pseudos,A.unique=A.uniqueSort,Lr.compile=oh,Lr.select=fm,Lr.setDocument=Lo,Lr.escape=A.escapeSelector,Lr.getText=A.text,Lr.isXML=A.isXMLDoc,Lr.selectors=A.expr,Lr.support=A.support,Lr.uniqueSort=A.uniqueSort})();var v=function(D,I,U){for(var G=[],oe=U!==void 0;(D=D[I])&&D.nodeType!==9;)if(D.nodeType===1){if(oe&&A(D).is(U))break;G.push(D)}return G},l=function(D,I){for(var U=[];D;D=D.nextSibling)D.nodeType===1&&D!==I&&U.push(D);return U},m=A.expr.match.needsContext,P=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function N(D,I,U){return C(I)?A.grep(D,function(G,oe){return!!I.call(G,oe,G)!==U}):I.nodeType?A.grep(D,function(G){return G===I!==U}):typeof I!="string"?A.grep(D,function(G){return d.call(I,G)>-1!==U}):A.filter(I,D,U)}A.filter=function(D,I,U){var G=I[0];return U&&(D=":not("+D+")"),I.length===1&&G.nodeType===1?A.find.matchesSelector(G,D)?[G]:[]:A.find.matches(D,A.grep(I,function(oe){return oe.nodeType===1}))},A.fn.extend({find:function(D){var I,U,G=this.length,oe=this;if(typeof D!="string")return this.pushStack(A(D).filter(function(){for(I=0;I1?A.uniqueSort(U):U},filter:function(D){return this.pushStack(N(this,D||[],!1))},not:function(D){return this.pushStack(N(this,D||[],!0))},is:function(D){return!!N(this,typeof D=="string"&&m.test(D)?A(D):D||[],!1).length}});var F,ee=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/,q=A.fn.init=function(D,I,U){var G,oe;if(!D)return this;if(U=U||F,typeof D=="string")if(D[0]==="<"&&D[D.length-1]===">"&&D.length>=3?G=[null,D,null]:G=ee.exec(D),G&&(G[1]||!I))if(G[1]){if(I=I instanceof A?I[0]:I,A.merge(this,A.parseHTML(G[1],I&&I.nodeType?I.ownerDocument||I:T,!0)),P.test(G[1])&&A.isPlainObject(I))for(G in I)C(this[G])?this[G](I[G]):this.attr(G,I[G]);return this}else return oe=T.getElementById(G[2]),oe&&(this[0]=oe,this.length=1),this;else return!I||I.jquery?(I||U).find(D):this.constructor(I).find(D);else{if(D.nodeType)return this[0]=D,this.length=1,this;if(C(D))return U.ready!==void 0?U.ready(D):D(A)}return A.makeArray(D,this)};q.prototype=A.fn,F=A(T);var ae=/^(?:parents|prev(?:Until|All))/,pe={children:!0,contents:!0,next:!0,prev:!0};A.fn.extend({has:function(D){var I=A(D,this),U=I.length;return this.filter(function(){for(var G=0;G-1:U.nodeType===1&&A.find.matchesSelector(U,D))){se.push(U);break}}return this.pushStack(se.length>1?A.uniqueSort(se):se)},index:function(D){return D?typeof D=="string"?d.call(A(D),this[0]):d.call(this,D.jquery?D[0]:D):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(D,I){return this.pushStack(A.uniqueSort(A.merge(this.get(),A(D,I))))},addBack:function(D){return this.add(D==null?this.prevObject:this.prevObject.filter(D))}});function we(D,I){for(;(D=D[I])&&D.nodeType!==1;);return D}A.each({parent:function(D){var I=D.parentNode;return I&&I.nodeType!==11?I:null},parents:function(D){return v(D,"parentNode")},parentsUntil:function(D,I,U){return v(D,"parentNode",U)},next:function(D){return we(D,"nextSibling")},prev:function(D){return we(D,"previousSibling")},nextAll:function(D){return v(D,"nextSibling")},prevAll:function(D){return v(D,"previousSibling")},nextUntil:function(D,I,U){return v(D,"nextSibling",U)},prevUntil:function(D,I,U){return v(D,"previousSibling",U)},siblings:function(D){return l((D.parentNode||{}).firstChild,D)},children:function(D){return l(D.firstChild)},contents:function(D){return D.contentDocument!=null&&i(D.contentDocument)?D.contentDocument:(z(D,"template")&&(D=D.content||D),A.merge([],D.childNodes))}},function(D,I){A.fn[D]=function(U,G){var oe=A.map(this,I,U);return D.slice(-5)!=="Until"&&(G=U),G&&typeof G=="string"&&(oe=A.filter(G,oe)),this.length>1&&(pe[D]||A.uniqueSort(oe),ae.test(D)&&oe.reverse()),this.pushStack(oe)}});var Se=/[^\x20\t\r\n\f]+/g;function he(D){var I={};return A.each(D.match(Se)||[],function(U,G){I[G]=!0}),I}A.Callbacks=function(D){D=typeof D=="string"?he(D):A.extend({},D);var I,U,G,oe,se=[],me=[],Re=-1,Ce=function(){for(oe=oe||D.once,G=I=!0;me.length;Re=-1)for(U=me.shift();++Re-1;)se.splice(Ze,1),Ze<=Re&&Re--}),this},has:function(st){return st?A.inArray(st,se)>-1:se.length>0},empty:function(){return se&&(se=[]),this},disable:function(){return oe=me=[],se=U="",this},disabled:function(){return!se},lock:function(){return oe=me=[],!U&&!I&&(se=U=""),this},locked:function(){return!!oe},fireWith:function(st,ct){return oe||(ct=ct||[],ct=[st,ct.slice?ct.slice():ct],me.push(ct),I||Ce()),this},fire:function(){return Ne.fireWith(this,arguments),this},fired:function(){return!!G}};return Ne};function re(D){return D}function _e(D){throw D}function W(D,I,U,G){var oe;try{D&&C(oe=D.promise)?oe.call(D).done(I).fail(U):D&&C(oe=D.then)?oe.call(D,I,U):I.apply(void 0,[D].slice(G))}catch(se){U.apply(void 0,[se])}}A.extend({Deferred:function(D){var I=[["notify","progress",A.Callbacks("memory"),A.Callbacks("memory"),2],["resolve","done",A.Callbacks("once memory"),A.Callbacks("once memory"),0,"resolved"],["reject","fail",A.Callbacks("once memory"),A.Callbacks("once memory"),1,"rejected"]],U="pending",G={state:function(){return U},always:function(){return oe.done(arguments).fail(arguments),this},catch:function(se){return G.then(null,se)},pipe:function(){var se=arguments;return A.Deferred(function(me){A.each(I,function(Re,Ce){var Ne=C(se[Ce[4]])&&se[Ce[4]];oe[Ce[1]](function(){var st=Ne&&Ne.apply(this,arguments);st&&C(st.promise)?st.promise().progress(me.notify).done(me.resolve).fail(me.reject):me[Ce[0]+"With"](this,Ne?[st]:arguments)})}),se=null}).promise()},then:function(se,me,Re){var Ce=0;function Ne(st,ct,Ze,vt){return function(){var Wt=this,fr=arguments,Qt=function(){var un,qn;if(!(st=Ce&&(Ze!==_e&&(Wt=void 0,fr=[un]),ct.rejectWith(Wt,fr))}};st?vn():(A.Deferred.getErrorHook?vn.error=A.Deferred.getErrorHook():A.Deferred.getStackHook&&(vn.error=A.Deferred.getStackHook()),t.setTimeout(vn))}}return A.Deferred(function(st){I[0][3].add(Ne(0,st,C(Re)?Re:re,st.notifyWith)),I[1][3].add(Ne(0,st,C(se)?se:re)),I[2][3].add(Ne(0,st,C(me)?me:_e))}).promise()},promise:function(se){return se!=null?A.extend(se,G):G}},oe={};return A.each(I,function(se,me){var Re=me[2],Ce=me[5];G[me[1]]=Re.add,Ce&&Re.add(function(){U=Ce},I[3-se][2].disable,I[3-se][3].disable,I[0][2].lock,I[0][3].lock),Re.add(me[3].fire),oe[me[0]]=function(){return oe[me[0]+"With"](this===oe?void 0:this,arguments),this},oe[me[0]+"With"]=Re.fireWith}),G.promise(oe),D&&D.call(oe,oe),oe},when:function(D){var I=arguments.length,U=I,G=Array(U),oe=a.call(arguments),se=A.Deferred(),me=function(Re){return function(Ce){G[Re]=this,oe[Re]=arguments.length>1?a.call(arguments):Ce,--I||se.resolveWith(G,oe)}};if(I<=1&&(W(D,se.done(me(U)).resolve,se.reject,!I),se.state()==="pending"||C(oe[U]&&oe[U].then)))return se.then();for(;U--;)W(oe[U],me(U),se.reject);return se.promise()}});var ve=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;A.Deferred.exceptionHook=function(D,I){t.console&&t.console.warn&&D&&ve.test(D.name)&&t.console.warn("jQuery.Deferred exception: "+D.message,D.stack,I)},A.readyException=function(D){t.setTimeout(function(){throw D})};var Z=A.Deferred();A.fn.ready=function(D){return Z.then(D).catch(function(I){A.readyException(I)}),this},A.extend({isReady:!1,readyWait:1,ready:function(D){(D===!0?--A.readyWait:A.isReady)||(A.isReady=!0,!(D!==!0&&--A.readyWait>0)&&Z.resolveWith(T,[A]))}}),A.ready.then=Z.then;function ne(){T.removeEventListener("DOMContentLoaded",ne),t.removeEventListener("load",ne),A.ready()}T.readyState==="complete"||T.readyState!=="loading"&&!T.documentElement.doScroll?t.setTimeout(A.ready):(T.addEventListener("DOMContentLoaded",ne),t.addEventListener("load",ne));var K=function(D,I,U,G,oe,se,me){var Re=0,Ce=D.length,Ne=U==null;if($(U)==="object"){oe=!0;for(Re in U)K(D,I,Re,U[Re],!0,se,me)}else if(G!==void 0&&(oe=!0,C(G)||(me=!0),Ne&&(me?(I.call(D,G),I=null):(Ne=I,I=function(st,ct,Ze){return Ne.call(A(st),Ze)})),I))for(;Re1,null,!0)},removeData:function(D){return this.each(function(){tt.remove(this,D)})}}),A.extend({queue:function(D,I,U){var G;if(D)return I=(I||"fx")+"queue",G=be.get(D,I),U&&(!G||Array.isArray(U)?G=be.access(D,I,A.makeArray(U)):G.push(U)),G||[]},dequeue:function(D,I){I=I||"fx";var U=A.queue(D,I),G=U.length,oe=U.shift(),se=A._queueHooks(D,I),me=function(){A.dequeue(D,I)};oe==="inprogress"&&(oe=U.shift(),G--),oe&&(I==="fx"&&U.unshift("inprogress"),delete se.stop,oe.call(D,me,se)),!G&&se&&se.empty.fire()},_queueHooks:function(D,I){var U=I+"queueHooks";return be.get(D,U)||be.access(D,U,{empty:A.Callbacks("once memory").add(function(){be.remove(D,[I+"queue",U])})})}}),A.fn.extend({queue:function(D,I){var U=2;return typeof D!="string"&&(I=D,D="fx",U--),arguments.length\x20\t\r\n\f]*)/i,Pt=/^$|^module$|\/(?:java|ecma)script/i;(function(){var D=T.createDocumentFragment(),I=D.appendChild(T.createElement("div")),U=T.createElement("input");U.setAttribute("type","radio"),U.setAttribute("checked","checked"),U.setAttribute("name","t"),I.appendChild(U),M.checkClone=I.cloneNode(!0).cloneNode(!0).lastChild.checked,I.innerHTML="",M.noCloneChecked=!!I.cloneNode(!0).lastChild.defaultValue,I.innerHTML="",M.option=!!I.lastChild})();var Ue={thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};Ue.tbody=Ue.tfoot=Ue.colgroup=Ue.caption=Ue.thead,Ue.th=Ue.td,M.option||(Ue.optgroup=Ue.option=[1,""]);function et(D,I){var U;return typeof D.getElementsByTagName<"u"?U=D.getElementsByTagName(I||"*"):typeof D.querySelectorAll<"u"?U=D.querySelectorAll(I||"*"):U=[],I===void 0||I&&z(D,I)?A.merge([D],U):U}function Vt(D,I){for(var U=0,G=D.length;U-1){oe&&oe.push(se);continue}if(Ne=pt(se),me=et(ct.appendChild(se),"script"),Ne&&Vt(me),U)for(st=0;se=me[st++];)Pt.test(se.type||"")&&U.push(se)}return ct}var Kt=/^([^.]*)(?:\.(.+)|)/;function Ve(){return!0}function Je(){return!1}function It(D,I,U,G,oe,se){var me,Re;if(typeof I=="object"){typeof U!="string"&&(G=G||U,U=void 0);for(Re in I)It(D,Re,U,G,I[Re],se);return D}if(G==null&&oe==null?(oe=U,G=U=void 0):oe==null&&(typeof U=="string"?(oe=G,G=void 0):(oe=G,G=U,U=void 0)),oe===!1)oe=Je;else if(!oe)return D;return se===1&&(me=oe,oe=function(Ce){return A().off(Ce),me.apply(this,arguments)},oe.guid=me.guid||(me.guid=A.guid++)),D.each(function(){A.event.add(this,I,oe,G,U)})}A.event={global:{},add:function(D,I,U,G,oe){var se,me,Re,Ce,Ne,st,ct,Ze,vt,Wt,fr,Qt=be.get(D);if(Ae(D))for(U.handler&&(se=U,U=se.handler,oe=se.selector),oe&&A.find.matchesSelector(Pe,oe),U.guid||(U.guid=A.guid++),(Ce=Qt.events)||(Ce=Qt.events=Object.create(null)),(me=Qt.handle)||(me=Qt.handle=function(vn){return typeof A<"u"&&A.event.triggered!==vn.type?A.event.dispatch.apply(D,arguments):void 0}),I=(I||"").match(Se)||[""],Ne=I.length;Ne--;)Re=Kt.exec(I[Ne])||[],vt=fr=Re[1],Wt=(Re[2]||"").split(".").sort(),vt&&(ct=A.event.special[vt]||{},vt=(oe?ct.delegateType:ct.bindType)||vt,ct=A.event.special[vt]||{},st=A.extend({type:vt,origType:fr,data:G,handler:U,guid:U.guid,selector:oe,needsContext:oe&&A.expr.match.needsContext.test(oe),namespace:Wt.join(".")},se),(Ze=Ce[vt])||(Ze=Ce[vt]=[],Ze.delegateCount=0,(!ct.setup||ct.setup.call(D,G,Wt,me)===!1)&&D.addEventListener&&D.addEventListener(vt,me)),ct.add&&(ct.add.call(D,st),st.handler.guid||(st.handler.guid=U.guid)),oe?Ze.splice(Ze.delegateCount++,0,st):Ze.push(st),A.event.global[vt]=!0)},remove:function(D,I,U,G,oe){var se,me,Re,Ce,Ne,st,ct,Ze,vt,Wt,fr,Qt=be.hasData(D)&&be.get(D);if(!(!Qt||!(Ce=Qt.events))){for(I=(I||"").match(Se)||[""],Ne=I.length;Ne--;){if(Re=Kt.exec(I[Ne])||[],vt=fr=Re[1],Wt=(Re[2]||"").split(".").sort(),!vt){for(vt in Ce)A.event.remove(D,vt+I[Ne],U,G,!0);continue}for(ct=A.event.special[vt]||{},vt=(G?ct.delegateType:ct.bindType)||vt,Ze=Ce[vt]||[],Re=Re[2]&&new RegExp("(^|\\.)"+Wt.join("\\.(?:.*\\.|)")+"(\\.|$)"),me=se=Ze.length;se--;)st=Ze[se],(oe||fr===st.origType)&&(!U||U.guid===st.guid)&&(!Re||Re.test(st.namespace))&&(!G||G===st.selector||G==="**"&&st.selector)&&(Ze.splice(se,1),st.selector&&Ze.delegateCount--,ct.remove&&ct.remove.call(D,st));me&&!Ze.length&&((!ct.teardown||ct.teardown.call(D,Wt,Qt.handle)===!1)&&A.removeEvent(D,vt,Qt.handle),delete Ce[vt])}A.isEmptyObject(Ce)&&be.remove(D,"handle events")}},dispatch:function(D){var I,U,G,oe,se,me,Re=new Array(arguments.length),Ce=A.event.fix(D),Ne=(be.get(this,"events")||Object.create(null))[Ce.type]||[],st=A.event.special[Ce.type]||{};for(Re[0]=Ce,I=1;I=1)){for(;Ne!==this;Ne=Ne.parentNode||this)if(Ne.nodeType===1&&!(D.type==="click"&&Ne.disabled===!0)){for(se=[],me={},U=0;U-1:A.find(oe,this,null,[Ne]).length),me[oe]&&se.push(G);se.length&&Re.push({elem:Ne,handlers:se})}}return Ne=this,Ce\s*$/g;function lt(D,I){return z(D,"table")&&z(I.nodeType!==11?I:I.firstChild,"tr")&&A(D).children("tbody")[0]||D}function Xt(D){return D.type=(D.getAttribute("type")!==null)+"/"+D.type,D}function qe(D){return(D.type||"").slice(0,5)==="true/"?D.type=D.type.slice(5):D.removeAttribute("type"),D}function at(D,I){var U,G,oe,se,me,Re,Ce;if(I.nodeType===1){if(be.hasData(D)&&(se=be.get(D),Ce=se.events,Ce)){be.remove(I,"handle events");for(oe in Ce)for(U=0,G=Ce[oe].length;U1&&typeof vt=="string"&&!M.checkClone&&jt.test(vt))return D.each(function(fr){var Qt=D.eq(fr);Wt&&(I[0]=vt.call(this,fr,Qt.html())),Ot(Qt,I,U,G)});if(ct&&(oe=ot(I,D[0].ownerDocument,!1,D,G),se=oe.firstChild,oe.childNodes.length===1&&(oe=se),se||G)){for(me=A.map(et(oe,"script"),Xt),Re=me.length;st0&&Vt(me,!Ce&&et(D,"script")),Re},cleanData:function(D){for(var I,U,G,oe=A.event.special,se=0;(U=D[se])!==void 0;se++)if(Ae(U)){if(I=U[be.expando]){if(I.events)for(G in I.events)oe[G]?A.event.remove(U,G):A.removeEvent(U,G,I.handle);U[be.expando]=void 0}U[tt.expando]&&(U[tt.expando]=void 0)}}}),A.fn.extend({detach:function(D){return sr(this,D,!0)},remove:function(D){return sr(this,D)},text:function(D){return K(this,function(I){return I===void 0?A.text(this):this.empty().each(function(){(this.nodeType===1||this.nodeType===11||this.nodeType===9)&&(this.textContent=I)})},null,D,arguments.length)},append:function(){return Ot(this,arguments,function(D){if(this.nodeType===1||this.nodeType===11||this.nodeType===9){var I=lt(this,D);I.appendChild(D)}})},prepend:function(){return Ot(this,arguments,function(D){if(this.nodeType===1||this.nodeType===11||this.nodeType===9){var I=lt(this,D);I.insertBefore(D,I.firstChild)}})},before:function(){return Ot(this,arguments,function(D){this.parentNode&&this.parentNode.insertBefore(D,this)})},after:function(){return Ot(this,arguments,function(D){this.parentNode&&this.parentNode.insertBefore(D,this.nextSibling)})},empty:function(){for(var D,I=0;(D=this[I])!=null;I++)D.nodeType===1&&(A.cleanData(et(D,!1)),D.textContent="");return this},clone:function(D,I){return D=D??!1,I=I??D,this.map(function(){return A.clone(this,D,I)})},html:function(D){return K(this,function(I){var U=this[0]||{},G=0,oe=this.length;if(I===void 0&&U.nodeType===1)return U.innerHTML;if(typeof I=="string"&&!it.test(I)&&!Ue[(Ye.exec(I)||["",""])[1].toLowerCase()]){I=A.htmlPrefilter(I);try{for(;G=0&&(Ce+=Math.max(0,Math.ceil(D["offset"+I[0].toUpperCase()+I.slice(1)]-se-Ce-Re-.5))||0),Ce+Ne}function Ao(D,I,U){var G=pr(D),oe=!M.boxSizingReliable()||U,se=oe&&A.css(D,"boxSizing",!1,G)==="border-box",me=se,Re=cr(D,I,G),Ce="offset"+I[0].toUpperCase()+I.slice(1);if(Ht.test(Re)){if(!U)return Re;Re="auto"}return(!M.boxSizingReliable()&&se||!M.reliableTrDimensions()&&z(D,"tr")||Re==="auto"||!parseFloat(Re)&&A.css(D,"display",!1,G)==="inline")&&D.getClientRects().length&&(se=A.css(D,"boxSizing",!1,G)==="border-box",me=Ce in D,me&&(Re=D[Ce])),Re=parseFloat(Re)||0,Re+ro(D,I,U||(se?"border":"content"),me,G,Re)+"px"}A.extend({cssHooks:{opacity:{get:function(D,I){if(I){var U=cr(D,"opacity");return U===""?"1":U}}}},cssNumber:{animationIterationCount:!0,aspectRatio:!0,borderImageSlice:!0,columnCount:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,scale:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeMiterlimit:!0,strokeOpacity:!0},cssProps:{},style:function(D,I,U,G){if(!(!D||D.nodeType===3||D.nodeType===8||!D.style)){var oe,se,me,Re=de(I),Ce=hr.test(I),Ne=D.style;if(Ce||(I=xr(Re)),me=A.cssHooks[I]||A.cssHooks[Re],U!==void 0){if(se=typeof U,se==="string"&&(oe=Fe.exec(U))&&oe[1]&&(U=bt(D,I,oe),se="number"),U==null||U!==U)return;se==="number"&&!Ce&&(U+=oe&&oe[3]||(A.cssNumber[Re]?"":"px")),!M.clearCloneStyle&&U===""&&I.indexOf("background")===0&&(Ne[I]="inherit"),(!me||!("set"in me)||(U=me.set(D,U,G))!==void 0)&&(Ce?Ne.setProperty(I,U):Ne[I]=U)}else return me&&"get"in me&&(oe=me.get(D,!1,G))!==void 0?oe:Ne[I]}},css:function(D,I,U,G){var oe,se,me,Re=de(I),Ce=hr.test(I);return Ce||(I=xr(Re)),me=A.cssHooks[I]||A.cssHooks[Re],me&&"get"in me&&(oe=me.get(D,!0,U)),oe===void 0&&(oe=cr(D,I,G)),oe==="normal"&&I in kr&&(oe=kr[I]),U===""||U?(se=parseFloat(oe),U===!0||isFinite(se)?se||0:oe):oe}}),A.each(["height","width"],function(D,I){A.cssHooks[I]={get:function(U,G,oe){if(G)return Pr.test(A.css(U,"display"))&&(!U.getClientRects().length||!U.getBoundingClientRect().width)?_r(U,Or,function(){return Ao(U,I,oe)}):Ao(U,I,oe)},set:function(U,G,oe){var se,me=pr(U),Re=!M.scrollboxSize()&&me.position==="absolute",Ce=Re||oe,Ne=Ce&&A.css(U,"boxSizing",!1,me)==="border-box",st=oe?ro(U,I,oe,Ne,me):0;return Ne&&Re&&(st-=Math.ceil(U["offset"+I[0].toUpperCase()+I.slice(1)]-parseFloat(me[I])-ro(U,I,"border",!1,me)-.5)),st&&(se=Fe.exec(G))&&(se[3]||"px")!=="px"&&(U.style[I]=G,G=A.css(U,I)),rr(U,G,st)}}}),A.cssHooks.marginLeft=qt(M.reliableMarginLeft,function(D,I){if(I)return(parseFloat(cr(D,"marginLeft"))||D.getBoundingClientRect().left-_r(D,{marginLeft:0},function(){return D.getBoundingClientRect().left}))+"px"}),A.each({margin:"",padding:"",border:"Width"},function(D,I){A.cssHooks[D+I]={expand:function(U){for(var G=0,oe={},se=typeof U=="string"?U.split(" "):[U];G<4;G++)oe[D+Te[G]+I]=se[G]||se[G-2]||se[0];return oe}},D!=="margin"&&(A.cssHooks[D+I].set=rr)}),A.fn.extend({css:function(D,I){return K(this,function(U,G,oe){var se,me,Re={},Ce=0;if(Array.isArray(G)){for(se=pr(U),me=G.length;Ce1)}});function _n(D,I,U,G,oe){return new _n.prototype.init(D,I,U,G,oe)}A.Tween=_n,_n.prototype={constructor:_n,init:function(D,I,U,G,oe,se){this.elem=D,this.prop=U,this.easing=oe||A.easing._default,this.options=I,this.start=this.now=this.cur(),this.end=G,this.unit=se||(A.cssNumber[U]?"":"px")},cur:function(){var D=_n.propHooks[this.prop];return D&&D.get?D.get(this):_n.propHooks._default.get(this)},run:function(D){var I,U=_n.propHooks[this.prop];return this.options.duration?this.pos=I=A.easing[this.easing](D,this.options.duration*D,0,1,this.options.duration):this.pos=I=D,this.now=(this.end-this.start)*I+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),U&&U.set?U.set(this):_n.propHooks._default.set(this),this}},_n.prototype.init.prototype=_n.prototype,_n.propHooks={_default:{get:function(D){var I;return D.elem.nodeType!==1||D.elem[D.prop]!=null&&D.elem.style[D.prop]==null?D.elem[D.prop]:(I=A.css(D.elem,D.prop,""),!I||I==="auto"?0:I)},set:function(D){A.fx.step[D.prop]?A.fx.step[D.prop](D):D.elem.nodeType===1&&(A.cssHooks[D.prop]||D.elem.style[xr(D.prop)]!=null)?A.style(D.elem,D.prop,D.now+D.unit):D.elem[D.prop]=D.now}}},_n.propHooks.scrollTop=_n.propHooks.scrollLeft={set:function(D){D.elem.nodeType&&D.elem.parentNode&&(D.elem[D.prop]=D.now)}},A.easing={linear:function(D){return D},swing:function(D){return .5-Math.cos(D*Math.PI)/2},_default:"swing"},A.fx=_n.prototype.init,A.fx.step={};var Lt,nr,Sn=/^(?:toggle|show|hide)$/,gi=/queueHooks$/;function Dt(){nr&&(T.hidden===!1&&t.requestAnimationFrame?t.requestAnimationFrame(Dt):t.setTimeout(Dt,A.fx.interval),A.fx.tick())}function Es(){return t.setTimeout(function(){Lt=void 0}),Lt=Date.now()}function Gi(D,I){var U,G=0,oe={height:D};for(I=I?1:0;G<4;G+=2-I)U=Te[G],oe["margin"+U]=oe["padding"+U]=D;return I&&(oe.opacity=oe.width=D),oe}function yi(D,I,U){for(var G,oe=(Yi.tweeners[I]||[]).concat(Yi.tweeners["*"]),se=0,me=oe.length;se1)},removeAttr:function(D){return this.each(function(){A.removeAttr(this,D)})}}),A.extend({attr:function(D,I,U){var G,oe,se=D.nodeType;if(!(se===3||se===8||se===2)){if(typeof D.getAttribute>"u")return A.prop(D,I,U);if((se!==1||!A.isXMLDoc(D))&&(oe=A.attrHooks[I.toLowerCase()]||(A.expr.match.bool.test(I)?Zp:void 0)),U!==void 0){if(U===null){A.removeAttr(D,I);return}return oe&&"set"in oe&&(G=oe.set(D,U,I))!==void 0?G:(D.setAttribute(I,U+""),U)}return oe&&"get"in oe&&(G=oe.get(D,I))!==null?G:(G=A.find.attr(D,I),G??void 0)}},attrHooks:{type:{set:function(D,I){if(!M.radioValue&&I==="radio"&&z(D,"input")){var U=D.value;return D.setAttribute("type",I),U&&(D.value=U),I}}}},removeAttr:function(D,I){var U,G=0,oe=I&&I.match(Se);if(oe&&D.nodeType===1)for(;U=oe[G++];)D.removeAttribute(U)}}),Zp={set:function(D,I,U){return I===!1?A.removeAttr(D,U):D.setAttribute(U,U),U}},A.each(A.expr.match.bool.source.match(/\w+/g),function(D,I){var U=yu[I]||A.find.attr;yu[I]=function(G,oe,se){var me,Re,Ce=oe.toLowerCase();return se||(Re=yu[Ce],yu[Ce]=me,me=U(G,oe,se)!=null?Ce:null,yu[Ce]=Re),me}});var db=/^(?:input|select|textarea|button)$/i,hb=/^(?:a|area)$/i;A.fn.extend({prop:function(D,I){return K(this,A.prop,D,I,arguments.length>1)},removeProp:function(D){return this.each(function(){delete this[A.propFix[D]||D]})}}),A.extend({prop:function(D,I,U){var G,oe,se=D.nodeType;if(!(se===3||se===8||se===2))return(se!==1||!A.isXMLDoc(D))&&(I=A.propFix[I]||I,oe=A.propHooks[I]),U!==void 0?oe&&"set"in oe&&(G=oe.set(D,U,I))!==void 0?G:D[I]=U:oe&&"get"in oe&&(G=oe.get(D,I))!==null?G:D[I]},propHooks:{tabIndex:{get:function(D){var I=A.find.attr(D,"tabindex");return I?parseInt(I,10):db.test(D.nodeName)||hb.test(D.nodeName)&&D.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),M.optSelected||(A.propHooks.selected={get:function(D){var I=D.parentNode;return I&&I.parentNode&&I.parentNode.selectedIndex,null},set:function(D){var I=D.parentNode;I&&(I.selectedIndex,I.parentNode&&I.parentNode.selectedIndex)}}),A.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){A.propFix[this.toLowerCase()]=this});function Xi(D){var I=D.match(Se)||[];return I.join(" ")}function ks(D){return D.getAttribute&&D.getAttribute("class")||""}function Pc(D){return Array.isArray(D)?D:typeof D=="string"?D.match(Se)||[]:[]}A.fn.extend({addClass:function(D){var I,U,G,oe,se,me;return C(D)?this.each(function(Re){A(this).addClass(D.call(this,Re,ks(this)))}):(I=Pc(D),I.length?this.each(function(){if(G=ks(this),U=this.nodeType===1&&" "+Xi(G)+" ",U){for(se=0;se-1;)U=U.replace(" "+oe+" "," ");me=Xi(U),G!==me&&this.setAttribute("class",me)}}):this):this.attr("class","")},toggleClass:function(D,I){var U,G,oe,se,me=typeof D,Re=me==="string"||Array.isArray(D);return C(D)?this.each(function(Ce){A(this).toggleClass(D.call(this,Ce,ks(this),I),I)}):typeof I=="boolean"&&Re?I?this.addClass(D):this.removeClass(D):(U=Pc(D),this.each(function(){if(Re)for(se=A(this),oe=0;oe-1)return!0;return!1}});var Jp=/\r/g;A.fn.extend({val:function(D){var I,U,G,oe=this[0];return arguments.length?(G=C(D),this.each(function(se){var me;this.nodeType===1&&(G?me=D.call(this,se,A(this).val()):me=D,me==null?me="":typeof me=="number"?me+="":Array.isArray(me)&&(me=A.map(me,function(Re){return Re==null?"":Re+""})),I=A.valHooks[this.type]||A.valHooks[this.nodeName.toLowerCase()],(!I||!("set"in I)||I.set(this,me,"value")===void 0)&&(this.value=me))})):oe?(I=A.valHooks[oe.type]||A.valHooks[oe.nodeName.toLowerCase()],I&&"get"in I&&(U=I.get(oe,"value"))!==void 0?U:(U=oe.value,typeof U=="string"?U.replace(Jp,""):U??"")):void 0}}),A.extend({valHooks:{option:{get:function(D){var I=A.find.attr(D,"value");return I??Xi(A.text(D))}},select:{get:function(D){var I,U,G,oe=D.options,se=D.selectedIndex,me=D.type==="select-one",Re=me?null:[],Ce=me?se+1:oe.length;for(se<0?G=Ce:G=me?se:0;G-1)&&(U=!0);return U||(D.selectedIndex=-1),se}}}}),A.each(["radio","checkbox"],function(){A.valHooks[this]={set:function(D,I){if(Array.isArray(I))return D.checked=A.inArray(A(D).val(),I)>-1}},M.checkOn||(A.valHooks[this].get=function(D){return D.getAttribute("value")===null?"on":D.value})});var wu=t.location,Qp={guid:Date.now()},Kd=/\?/;A.parseXML=function(D){var I,U;if(!D||typeof D!="string")return null;try{I=new t.DOMParser().parseFromString(D,"text/xml")}catch{}return U=I&&I.getElementsByTagName("parsererror")[0],(!I||U)&&A.error("Invalid XML: "+(U?A.map(U.childNodes,function(G){return G.textContent}).join(` `):D)),I};var em=/^(?:focusinfocus|focusoutblur)$/,tm=function(D){D.stopPropagation()};A.extend(A.event,{trigger:function(D,I,U,G){var oe,se,me,Re,Ce,Ne,st,ct,Ze=[U||T],vt=w.call(D,"type")?D.type:D,Wt=w.call(D,"namespace")?D.namespace.split("."):[];if(se=ct=me=U=U||T,!(U.nodeType===3||U.nodeType===8)&&!em.test(vt+A.event.triggered)&&(vt.indexOf(".")>-1&&(Wt=vt.split("."),vt=Wt.shift(),Wt.sort()),Ce=vt.indexOf(":")<0&&"on"+vt,D=D[A.expando]?D:new A.Event(vt,typeof D=="object"&&D),D.isTrigger=G?2:3,D.namespace=Wt.join("."),D.rnamespace=D.namespace?new RegExp("(^|\\.)"+Wt.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,D.result=void 0,D.target||(D.target=U),I=I==null?[D]:A.makeArray(I,[D]),st=A.event.special[vt]||{},!(!G&&st.trigger&&st.trigger.apply(U,I)===!1))){if(!G&&!st.noBubble&&!O(U)){for(Re=st.delegateType||vt,em.test(Re+vt)||(se=se.parentNode);se;se=se.parentNode)Ze.push(se),me=se;me===(U.ownerDocument||T)&&Ze.push(me.defaultView||me.parentWindow||t)}for(oe=0;(se=Ze[oe++])&&!D.isPropagationStopped();)ct=se,D.type=oe>1?Re:st.bindType||vt,Ne=(be.get(se,"events")||Object.create(null))[D.type]&&be.get(se,"handle"),Ne&&Ne.apply(se,I),Ne=Ce&&se[Ce],Ne&&Ne.apply&&Ae(se)&&(D.result=Ne.apply(se,I),D.result===!1&&D.preventDefault());return D.type=vt,!G&&!D.isDefaultPrevented()&&(!st._default||st._default.apply(Ze.pop(),I)===!1)&&Ae(U)&&Ce&&C(U[vt])&&!O(U)&&(me=U[Ce],me&&(U[Ce]=null),A.event.triggered=vt,D.isPropagationStopped()&&ct.addEventListener(vt,tm),U[vt](),D.isPropagationStopped()&&ct.removeEventListener(vt,tm),A.event.triggered=void 0,me&&(U[Ce]=me)),D.result}},simulate:function(D,I,U){var G=A.extend(new A.Event,U,{type:D,isSimulated:!0});A.event.trigger(G,null,I)}}),A.fn.extend({trigger:function(D,I){return this.each(function(){A.event.trigger(D,I,this)})},triggerHandler:function(D,I){var U=this[0];if(U)return A.event.trigger(D,I,U,!0)}});var pb=/\[\]$/,rm=/\r?\n/g,ul=/^(?:submit|button|image|reset|file)$/i,mb=/^(?:input|select|textarea|keygen)/i;function Gd(D,I,U,G){var oe;if(Array.isArray(I))A.each(I,function(se,me){U||pb.test(D)?G(D,me):Gd(D+"["+(typeof me=="object"&&me!=null?se:"")+"]",me,U,G)});else if(!U&&$(I)==="object")for(oe in I)Gd(D+"["+oe+"]",I[oe],U,G);else G(D,I)}A.param=function(D,I){var U,G=[],oe=function(se,me){var Re=C(me)?me():me;G[G.length]=encodeURIComponent(se)+"="+encodeURIComponent(Re??"")};if(D==null)return"";if(Array.isArray(D)||D.jquery&&!A.isPlainObject(D))A.each(D,function(){oe(this.name,this.value)});else for(U in D)Gd(U,D[U],I,oe);return G.join("&")},A.fn.extend({serialize:function(){return A.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var D=A.prop(this,"elements");return D?A.makeArray(D):this}).filter(function(){var D=this.type;return this.name&&!A(this).is(":disabled")&&mb.test(this.nodeName)&&!ul.test(D)&&(this.checked||!Be.test(D))}).map(function(D,I){var U=A(this).val();return U==null?null:Array.isArray(U)?A.map(U,function(G){return{name:I.name,value:G.replace(rm,`\r `)}}):{name:I.name,value:U.replace(rm,`\r `)}}).get()}});var nm=/%20/g,vb=/#.*$/,Do=/([?&])_=[^&]*/,gb=/^(.*?):[ \t]*([^\r\n]*)$/mg,im=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,bu=/^(?:GET|HEAD)$/,yb=/^\/\//,am={},Yd={},Xd="*/".concat("*"),$o=T.createElement("a");$o.href=wu.href;function om(D){return function(I,U){typeof I!="string"&&(U=I,I="*");var G,oe=0,se=I.toLowerCase().match(Se)||[];if(C(U))for(;G=se[oe++];)G[0]==="+"?(G=G.slice(1)||"*",(D[G]=D[G]||[]).unshift(U)):(D[G]=D[G]||[]).push(U)}}function sm(D,I,U,G){var oe={},se=D===Yd;function me(Re){var Ce;return oe[Re]=!0,A.each(D[Re]||[],function(Ne,st){var ct=st(I,U,G);if(typeof ct=="string"&&!se&&!oe[ct])return I.dataTypes.unshift(ct),me(ct),!1;if(se)return!(Ce=ct)}),Ce}return me(I.dataTypes[0])||!oe["*"]&&me("*")}function Zd(D,I){var U,G,oe=A.ajaxSettings.flatOptions||{};for(U in I)I[U]!==void 0&&((oe[U]?D:G||(G={}))[U]=I[U]);return G&&A.extend(!0,D,G),D}function wb(D,I,U){for(var G,oe,se,me,Re=D.contents,Ce=D.dataTypes;Ce[0]==="*";)Ce.shift(),G===void 0&&(G=D.mimeType||I.getResponseHeader("Content-Type"));if(G){for(oe in Re)if(Re[oe]&&Re[oe].test(G)){Ce.unshift(oe);break}}if(Ce[0]in U)se=Ce[0];else{for(oe in U){if(!Ce[0]||D.converters[oe+" "+Ce[0]]){se=oe;break}me||(me=oe)}se=se||me}if(se)return se!==Ce[0]&&Ce.unshift(se),U[se]}function bb(D,I,U,G){var oe,se,me,Re,Ce,Ne={},st=D.dataTypes.slice();if(st[1])for(me in D.converters)Ne[me.toLowerCase()]=D.converters[me];for(se=st.shift();se;)if(D.responseFields[se]&&(U[D.responseFields[se]]=I),!Ce&&G&&D.dataFilter&&(I=D.dataFilter(I,D.dataType)),Ce=se,se=st.shift(),se){if(se==="*")se=Ce;else if(Ce!=="*"&&Ce!==se){if(me=Ne[Ce+" "+se]||Ne["* "+se],!me){for(oe in Ne)if(Re=oe.split(" "),Re[1]===se&&(me=Ne[Ce+" "+Re[0]]||Ne["* "+Re[0]],me)){me===!0?me=Ne[oe]:Ne[oe]!==!0&&(se=Re[0],st.unshift(Re[1]));break}}if(me!==!0)if(me&&D.throws)I=me(I);else try{I=me(I)}catch(ct){return{state:"parsererror",error:me?ct:"No conversion from "+Ce+" to "+se}}}}return{state:"success",data:I}}A.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:wu.href,type:"GET",isLocal:im.test(wu.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Xd,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":A.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(D,I){return I?Zd(Zd(D,A.ajaxSettings),I):Zd(A.ajaxSettings,D)},ajaxPrefilter:om(am),ajaxTransport:om(Yd),ajax:function(D,I){typeof D=="object"&&(I=D,D=void 0),I=I||{};var U,G,oe,se,me,Re,Ce,Ne,st,ct,Ze=A.ajaxSetup({},I),vt=Ze.context||Ze,Wt=Ze.context&&(vt.nodeType||vt.jquery)?A(vt):A.event,fr=A.Deferred(),Qt=A.Callbacks("once memory"),vn=Ze.statusCode||{},un={},qn={},xa="canceled",ur={readyState:0,getResponseHeader:function(mr){var Zr;if(Ce){if(!se)for(se={};Zr=gb.exec(oe);)se[Zr[1].toLowerCase()+" "]=(se[Zr[1].toLowerCase()+" "]||[]).concat(Zr[2]);Zr=se[mr.toLowerCase()+" "]}return Zr==null?null:Zr.join(", ")},getAllResponseHeaders:function(){return Ce?oe:null},setRequestHeader:function(mr,Zr){return Ce==null&&(mr=qn[mr.toLowerCase()]=qn[mr.toLowerCase()]||mr,un[mr]=Zr),this},overrideMimeType:function(mr){return Ce==null&&(Ze.mimeType=mr),this},statusCode:function(mr){var Zr;if(mr)if(Ce)ur.always(mr[ur.status]);else for(Zr in mr)vn[Zr]=[vn[Zr],mr[Zr]];return this},abort:function(mr){var Zr=mr||xa;return U&&U.abort(Zr),Ts(0,Zr),this}};if(fr.promise(ur),Ze.url=((D||Ze.url||wu.href)+"").replace(yb,wu.protocol+"//"),Ze.type=I.method||I.type||Ze.method||Ze.type,Ze.dataTypes=(Ze.dataType||"*").toLowerCase().match(Se)||[""],Ze.crossDomain==null){Re=T.createElement("a");try{Re.href=Ze.url,Re.href=Re.href,Ze.crossDomain=$o.protocol+"//"+$o.host!=Re.protocol+"//"+Re.host}catch{Ze.crossDomain=!0}}if(Ze.data&&Ze.processData&&typeof Ze.data!="string"&&(Ze.data=A.param(Ze.data,Ze.traditional)),sm(am,Ze,I,ur),Ce)return ur;Ne=A.event&&Ze.global,Ne&&A.active++===0&&A.event.trigger("ajaxStart"),Ze.type=Ze.type.toUpperCase(),Ze.hasContent=!bu.test(Ze.type),G=Ze.url.replace(vb,""),Ze.hasContent?Ze.data&&Ze.processData&&(Ze.contentType||"").indexOf("application/x-www-form-urlencoded")===0&&(Ze.data=Ze.data.replace(nm,"+")):(ct=Ze.url.slice(G.length),Ze.data&&(Ze.processData||typeof Ze.data=="string")&&(G+=(Kd.test(G)?"&":"?")+Ze.data,delete Ze.data),Ze.cache===!1&&(G=G.replace(Do,"$1"),ct=(Kd.test(G)?"&":"?")+"_="+Qp.guid+++ct),Ze.url=G+ct),Ze.ifModified&&(A.lastModified[G]&&ur.setRequestHeader("If-Modified-Since",A.lastModified[G]),A.etag[G]&&ur.setRequestHeader("If-None-Match",A.etag[G])),(Ze.data&&Ze.hasContent&&Ze.contentType!==!1||I.contentType)&&ur.setRequestHeader("Content-Type",Ze.contentType),ur.setRequestHeader("Accept",Ze.dataTypes[0]&&Ze.accepts[Ze.dataTypes[0]]?Ze.accepts[Ze.dataTypes[0]]+(Ze.dataTypes[0]!=="*"?", "+Xd+"; q=0.01":""):Ze.accepts["*"]);for(st in Ze.headers)ur.setRequestHeader(st,Ze.headers[st]);if(Ze.beforeSend&&(Ze.beforeSend.call(vt,ur,Ze)===!1||Ce))return ur.abort();if(xa="abort",Qt.add(Ze.complete),ur.done(Ze.success),ur.fail(Ze.error),U=sm(Yd,Ze,I,ur),!U)Ts(-1,"No Transport");else{if(ur.readyState=1,Ne&&Wt.trigger("ajaxSend",[ur,Ze]),Ce)return ur;Ze.async&&Ze.timeout>0&&(me=t.setTimeout(function(){ur.abort("timeout")},Ze.timeout));try{Ce=!1,U.send(un,Ts)}catch(mr){if(Ce)throw mr;Ts(-1,mr)}}function Ts(mr,Zr,cl,eh){var _a,_u,Sa,no,Io,wi=Zr;Ce||(Ce=!0,me&&t.clearTimeout(me),U=void 0,oe=eh||"",ur.readyState=mr>0?4:0,_a=mr>=200&&mr<300||mr===304,cl&&(no=wb(Ze,ur,cl)),!_a&&A.inArray("script",Ze.dataTypes)>-1&&A.inArray("json",Ze.dataTypes)<0&&(Ze.converters["text script"]=function(){}),no=bb(Ze,no,ur,_a),_a?(Ze.ifModified&&(Io=ur.getResponseHeader("Last-Modified"),Io&&(A.lastModified[G]=Io),Io=ur.getResponseHeader("etag"),Io&&(A.etag[G]=Io)),mr===204||Ze.type==="HEAD"?wi="nocontent":mr===304?wi="notmodified":(wi=no.state,_u=no.data,Sa=no.error,_a=!Sa)):(Sa=wi,(mr||!wi)&&(wi="error",mr<0&&(mr=0))),ur.status=mr,ur.statusText=(Zr||wi)+"",_a?fr.resolveWith(vt,[_u,wi,ur]):fr.rejectWith(vt,[ur,wi,Sa]),ur.statusCode(vn),vn=void 0,Ne&&Wt.trigger(_a?"ajaxSuccess":"ajaxError",[ur,Ze,_a?_u:Sa]),Qt.fireWith(vt,[ur,wi]),Ne&&(Wt.trigger("ajaxComplete",[ur,Ze]),--A.active||A.event.trigger("ajaxStop")))}return ur},getJSON:function(D,I,U){return A.get(D,I,U,"json")},getScript:function(D,I){return A.get(D,void 0,I,"script")}}),A.each(["get","post"],function(D,I){A[I]=function(U,G,oe,se){return C(G)&&(se=se||oe,oe=G,G=void 0),A.ajax(A.extend({url:U,type:I,dataType:se,data:G,success:oe},A.isPlainObject(U)&&U))}}),A.ajaxPrefilter(function(D){var I;for(I in D.headers)I.toLowerCase()==="content-type"&&(D.contentType=D.headers[I]||"")}),A._evalUrl=function(D,I,U){return A.ajax({url:D,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(G){A.globalEval(G,I,U)}})},A.fn.extend({wrapAll:function(D){var I;return this[0]&&(C(D)&&(D=D.call(this[0])),I=A(D,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&I.insertBefore(this[0]),I.map(function(){for(var U=this;U.firstElementChild;)U=U.firstElementChild;return U}).append(this)),this},wrapInner:function(D){return C(D)?this.each(function(I){A(this).wrapInner(D.call(this,I))}):this.each(function(){var I=A(this),U=I.contents();U.length?U.wrapAll(D):I.append(D)})},wrap:function(D){var I=C(D);return this.each(function(U){A(this).wrapAll(I?D.call(this,U):D)})},unwrap:function(D){return this.parent(D).not("body").each(function(){A(this).replaceWith(this.childNodes)}),this}}),A.expr.pseudos.hidden=function(D){return!A.expr.pseudos.visible(D)},A.expr.pseudos.visible=function(D){return!!(D.offsetWidth||D.offsetHeight||D.getClientRects().length)},A.ajaxSettings.xhr=function(){try{return new t.XMLHttpRequest}catch{}};var xb={0:200,1223:204},xu=A.ajaxSettings.xhr();M.cors=!!xu&&"withCredentials"in xu,M.ajax=xu=!!xu,A.ajaxTransport(function(D){var I,U;if(M.cors||xu&&!D.crossDomain)return{send:function(G,oe){var se,me=D.xhr();if(me.open(D.type,D.url,D.async,D.username,D.password),D.xhrFields)for(se in D.xhrFields)me[se]=D.xhrFields[se];D.mimeType&&me.overrideMimeType&&me.overrideMimeType(D.mimeType),!D.crossDomain&&!G["X-Requested-With"]&&(G["X-Requested-With"]="XMLHttpRequest");for(se in G)me.setRequestHeader(se,G[se]);I=function(Re){return function(){I&&(I=U=me.onload=me.onerror=me.onabort=me.ontimeout=me.onreadystatechange=null,Re==="abort"?me.abort():Re==="error"?typeof me.status!="number"?oe(0,"error"):oe(me.status,me.statusText):oe(xb[me.status]||me.status,me.statusText,(me.responseType||"text")!=="text"||typeof me.responseText!="string"?{binary:me.response}:{text:me.responseText},me.getAllResponseHeaders()))}},me.onload=I(),U=me.onerror=me.ontimeout=I("error"),me.onabort!==void 0?me.onabort=U:me.onreadystatechange=function(){me.readyState===4&&t.setTimeout(function(){I&&U()})},I=I("abort");try{me.send(D.hasContent&&D.data||null)}catch(Re){if(I)throw Re}},abort:function(){I&&I()}}}),A.ajaxPrefilter(function(D){D.crossDomain&&(D.contents.script=!1)}),A.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(D){return A.globalEval(D),D}}}),A.ajaxPrefilter("script",function(D){D.cache===void 0&&(D.cache=!1),D.crossDomain&&(D.type="GET")}),A.ajaxTransport("script",function(D){if(D.crossDomain||D.scriptAttrs){var I,U;return{send:function(G,oe){I=A("