const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["chunks/index-D5n26yMc.js","chunks/App-BLnEEK_h.js","chunks/request-fingerprint-BANtRL63.js","chunks/Logo1am-CaBWyNpM.js","chunks/_virtual_wxt-plugins-CDnz5Vh6.js","chunks/__vite-plugin-wasm-helper-D7K_KhUE.js","chunks/cardano-e2kMgYtl.js","chunks/___vite-browser-external_commonjs-proxy-DIugEvg0.js","chunks/index-BkMDDkpV.js"])))=>i.map(i=>d[i]);
import { O as ma, Q as Lr, R as Ih, U as Wr, V as Fe, X as Mh, Y as Rh, Z as Th, $ as fc, a0 as cc, __tla as __tla_0 } from "./App-BLnEEK_h.js";
import { r as cf, __tla as __tla_1 } from "./___vite-browser-external_commonjs-proxy-DIugEvg0.js";
import { s as L0 } from "./index-BkMDDkpV.js";
import { I as Ph, r as U0, h as Ao, e as Zn, D as df, G as Bh, a5 as Oh, a6 as Ei, P as dc, N as yn, a7 as Io, a8 as uf, a9 as kh, o as Nh, s as Ch, __tla as __tla_2 } from "./cardano-e2kMgYtl.js";
import { _ as Lh } from "./request-fingerprint-BANtRL63.js";
let he, ea, Be, If, si, Sr, S8, Br, vr, ai;
let __tla = Promise.all([
    (()=>{
        try {
            return __tla_0;
        } catch  {}
    })(),
    (()=>{
        try {
            return __tla_1;
        } catch  {}
    })(),
    (()=>{
        try {
            return __tla_2;
        } catch  {}
    })()
]).then(async ()=>{
    var He = {}, za, uc;
    function q0() {
        if (uc) return za;
        uc = 1, za = t, t.strict = n, t.loose = a;
        var r = Object.prototype.toString, e = {
            "[object Int8Array]": !0,
            "[object Int16Array]": !0,
            "[object Int32Array]": !0,
            "[object Uint8Array]": !0,
            "[object Uint8ClampedArray]": !0,
            "[object Uint16Array]": !0,
            "[object Uint32Array]": !0,
            "[object Float32Array]": !0,
            "[object Float64Array]": !0
        };
        function t(i) {
            return n(i) || a(i);
        }
        function n(i) {
            return i instanceof Int8Array || i instanceof Int16Array || i instanceof Int32Array || i instanceof Uint8Array || i instanceof Uint8ClampedArray || i instanceof Uint16Array || i instanceof Uint32Array || i instanceof Float32Array || i instanceof Float64Array;
        }
        function a(i) {
            return e[r.call(i)];
        }
        return za;
    }
    var Wa, lc;
    function Uh() {
        if (lc) return Wa;
        lc = 1;
        var r = q0().strict;
        return Wa = function(t) {
            if (r(t)) {
                var n = Buffer.from(t.buffer);
                return t.byteLength !== t.buffer.byteLength && (n = n.slice(t.byteOffset, t.byteOffset + t.byteLength)), n;
            } else return Buffer.from(t);
        }, Wa;
    }
    var hc;
    function qh() {
        if (hc) return He;
        hc = 1;
        var r = He && He.__importDefault || function(ne) {
            return ne && ne.__esModule ? ne : {
                default: ne
            };
        };
        Object.defineProperty(He, "__esModule", {
            value: !0
        });
        const e = r(q0()), t = r(Uh()), n = "hex", a = "utf8", i = "binary", s = "buffer", o = "array", f = "typed-array", c = "array-buffer", h = "0";
        function g(ne) {
            return new Uint8Array(ne);
        }
        He.bufferToArray = g;
        function v(ne, Oe = !1) {
            const We = ne.toString(n);
            return Oe ? ze(We) : We;
        }
        He.bufferToHex = v;
        function w(ne) {
            return ne.toString(a);
        }
        He.bufferToUtf8 = w;
        function E(ne) {
            return ne.readUIntBE(0, ne.length);
        }
        He.bufferToNumber = E;
        function x(ne) {
            return N(g(ne));
        }
        He.bufferToBinary = x;
        function S(ne) {
            return t.default(ne);
        }
        He.arrayToBuffer = S;
        function y(ne, Oe = !1) {
            return v(S(ne), Oe);
        }
        He.arrayToHex = y;
        function A(ne) {
            return w(S(ne));
        }
        He.arrayToUtf8 = A;
        function P(ne) {
            return E(S(ne));
        }
        He.arrayToNumber = P;
        function N(ne) {
            return Array.from(ne).map(R).join("");
        }
        He.arrayToBinary = N;
        function k(ne) {
            return Buffer.from(De(ne), n);
        }
        He.hexToBuffer = k;
        function D(ne) {
            return g(k(ne));
        }
        He.hexToArray = D;
        function V(ne) {
            return w(k(ne));
        }
        He.hexToUtf8 = V;
        function K(ne) {
            return P(D(ne));
        }
        He.hexToNumber = K;
        function j(ne) {
            return N(D(ne));
        }
        He.hexToBinary = j;
        function H(ne) {
            return Buffer.from(ne, a);
        }
        He.utf8ToBuffer = H;
        function O(ne) {
            return g(H(ne));
        }
        He.utf8ToArray = O;
        function d(ne, Oe = !1) {
            return v(H(ne), Oe);
        }
        He.utf8ToHex = d;
        function l(ne) {
            const Oe = parseInt(ne, 10);
            return qt(Qe(Oe), "Number can only safely store up to 53 bits"), Oe;
        }
        He.utf8ToNumber = l;
        function b(ne) {
            return N(O(ne));
        }
        He.utf8ToBinary = b;
        function m(ne) {
            return u(R(ne));
        }
        He.numberToBuffer = m;
        function _(ne) {
            return I(R(ne));
        }
        He.numberToArray = _;
        function B(ne, Oe) {
            return G(R(ne), Oe);
        }
        He.numberToHex = B;
        function T(ne) {
            return `${ne}`;
        }
        He.numberToUtf8 = T;
        function R(ne) {
            const Oe = (ne >>> 0).toString(2);
            return le(Oe);
        }
        He.numberToBinary = R;
        function u(ne) {
            return S(I(ne));
        }
        He.binaryToBuffer = u;
        function I(ne) {
            return new Uint8Array(Se(ne).map((Oe)=>parseInt(Oe, 2)));
        }
        He.binaryToArray = I;
        function G(ne, Oe) {
            return y(I(ne), Oe);
        }
        He.binaryToHex = G;
        function $(ne) {
            return A(I(ne));
        }
        He.binaryToUtf8 = $;
        function te(ne) {
            return P(I(ne));
        }
        He.binaryToNumber = te;
        function Z(ne) {
            return !(typeof ne != "string" || !new RegExp(/^[01]+$/).test(ne) || ne.length % 8 !== 0);
        }
        He.isBinaryString = Z;
        function fe(ne, Oe) {
            return !(typeof ne != "string" || !ne.match(/^0x[0-9A-Fa-f]*$/) || Oe && ne.length !== 2 + 2 * Oe);
        }
        He.isHexString = fe;
        function pe(ne) {
            return Buffer.isBuffer(ne);
        }
        He.isBuffer = pe;
        function ee(ne) {
            return e.default.strict(ne) && !pe(ne);
        }
        He.isTypedArray = ee;
        function J(ne) {
            return !ee(ne) && !pe(ne) && typeof ne.byteLength < "u";
        }
        He.isArrayBuffer = J;
        function oe(ne) {
            return pe(ne) ? s : ee(ne) ? f : J(ne) ? c : Array.isArray(ne) ? o : typeof ne;
        }
        He.getType = oe;
        function Me(ne) {
            return Z(ne) ? i : fe(ne) ? n : a;
        }
        He.getEncoding = Me;
        function xe(...ne) {
            return Buffer.concat(ne);
        }
        He.concatBuffers = xe;
        function z(...ne) {
            let Oe = [];
            return ne.forEach((We)=>Oe = Oe.concat(Array.from(We))), new Uint8Array([
                ...Oe
            ]);
        }
        He.concatArrays = z;
        function X(ne, Oe) {
            const We = ne.length - Oe;
            return We > 0 && (ne = ne.slice(We)), ne;
        }
        He.trimLeft = X;
        function re(ne, Oe) {
            return ne.slice(0, Oe);
        }
        He.trimRight = re;
        function ge(ne, Oe = 8) {
            const We = ne % Oe;
            return We ? (ne - We) / Oe * Oe + Oe : ne;
        }
        He.calcByteLength = ge;
        function Se(ne, Oe = 8) {
            const We = le(ne).match(new RegExp(`.{${Oe}}`, "gi"));
            return Array.from(We || []);
        }
        He.splitBytes = Se;
        function ye(ne) {
            return Se(ne).map(bt).join("");
        }
        He.swapBytes = ye;
        function Y(ne) {
            return G(ye(j(ne)));
        }
        He.swapHex = Y;
        function le(ne, Oe = 8, We = h) {
            return be(ne, ge(ne.length, Oe), We);
        }
        He.sanitizeBytes = le;
        function be(ne, Oe, We = h) {
            return et(ne, Oe, !0, We);
        }
        He.padLeft = be;
        function se(ne, Oe, We = h) {
            return et(ne, Oe, !1, We);
        }
        He.padRight = se;
        function De(ne) {
            return ne.replace(/^0x/, "");
        }
        He.removeHexPrefix = De;
        function ze(ne) {
            return ne.startsWith("0x") ? ne : `0x${ne}`;
        }
        He.addHexPrefix = ze;
        function $e(ne) {
            return ne = De(ne), ne = le(ne, 2), ne && (ne = ze(ne)), ne;
        }
        He.sanitizeHex = $e;
        function Ze(ne) {
            const Oe = ne.startsWith("0x");
            return ne = De(ne), ne = ne.startsWith(h) ? ne.substring(1) : ne, Oe ? ze(ne) : ne;
        }
        He.removeHexLeadingZeros = Ze;
        function je(ne) {
            return typeof ne > "u";
        }
        function Qe(ne) {
            return !je(ne);
        }
        function qt(ne, Oe) {
            if (!ne) throw new Error(Oe);
        }
        function bt(ne) {
            return ne.split("").reverse().join("");
        }
        function et(ne, Oe, We, Pt = h) {
            const pt = Oe - ne.length;
            let St = ne;
            if (pt > 0) {
                const ar = Pt.repeat(pt);
                St = We ? ar + ne : ne + ar;
            }
            return St;
        }
        return He;
    }
    var Bn = qh();
    const lf = BigInt(0), Mo = BigInt(1);
    function Ln(r) {
        return r instanceof Uint8Array || ArrayBuffer.isView(r) && r.constructor.name === "Uint8Array";
    }
    function hf(r) {
        if (!Ln(r)) throw new Error("Uint8Array expected");
    }
    function oi(r, e) {
        if (typeof e != "boolean") throw new Error(r + " boolean expected, got " + e);
    }
    function Ai(r) {
        const e = r.toString(16);
        return e.length & 1 ? "0" + e : e;
    }
    function D0(r) {
        if (typeof r != "string") throw new Error("hex string expected, got " + typeof r);
        return r === "" ? lf : BigInt("0x" + r);
    }
    const F0 = typeof Uint8Array.from([]).toHex == "function" && typeof Uint8Array.fromHex == "function", Dh = Array.from({
        length: 256
    }, (r, e)=>e.toString(16).padStart(2, "0"));
    function fi(r) {
        if (hf(r), F0) return r.toHex();
        let e = "";
        for(let t = 0; t < r.length; t++)e += Dh[r[t]];
        return e;
    }
    const qr = {
        _0: 48,
        _9: 57,
        A: 65,
        F: 70,
        a: 97,
        f: 102
    };
    function bc(r) {
        if (r >= qr._0 && r <= qr._9) return r - qr._0;
        if (r >= qr.A && r <= qr.F) return r - (qr.A - 10);
        if (r >= qr.a && r <= qr.f) return r - (qr.a - 10);
    }
    function ra(r) {
        if (typeof r != "string") throw new Error("hex string expected, got " + typeof r);
        if (F0) return Uint8Array.fromHex(r);
        const e = r.length, t = e / 2;
        if (e % 2) throw new Error("hex string expected, got unpadded hex of length " + e);
        const n = new Uint8Array(t);
        for(let a = 0, i = 0; a < t; a++, i += 2){
            const s = bc(r.charCodeAt(i)), o = bc(r.charCodeAt(i + 1));
            if (s === void 0 || o === void 0) {
                const f = r[i] + r[i + 1];
                throw new Error('hex string expected, got non-hex character "' + f + '" at index ' + i);
            }
            n[a] = s * 16 + o;
        }
        return n;
    }
    function _n(r) {
        return D0(fi(r));
    }
    function $0(r) {
        return hf(r), D0(fi(Uint8Array.from(r).reverse()));
    }
    function ci(r, e) {
        return ra(r.toString(16).padStart(e * 2, "0"));
    }
    function K0(r, e) {
        return ci(r, e).reverse();
    }
    function mr(r, e, t) {
        let n;
        if (typeof e == "string") try {
            n = ra(e);
        } catch (i) {
            throw new Error(r + " must be hex string or Uint8Array, cause: " + i);
        }
        else if (Ln(e)) n = Uint8Array.from(e);
        else throw new Error(r + " must be hex string or Uint8Array");
        const a = n.length;
        if (typeof t == "number" && a !== t) throw new Error(r + " of length " + t + " expected, got " + a);
        return n;
    }
    function na(...r) {
        let e = 0;
        for(let n = 0; n < r.length; n++){
            const a = r[n];
            hf(a), e += a.length;
        }
        const t = new Uint8Array(e);
        for(let n = 0, a = 0; n < r.length; n++){
            const i = r[n];
            t.set(i, a), a += i.length;
        }
        return t;
    }
    const Ya = (r)=>typeof r == "bigint" && lf <= r;
    function bf(r, e, t) {
        return Ya(r) && Ya(e) && Ya(t) && e <= r && r < t;
    }
    function On(r, e, t, n) {
        if (!bf(e, t, n)) throw new Error("expected valid " + r + ": " + t + " <= n < " + n + ", got " + e);
    }
    function Fh(r) {
        let e;
        for(e = 0; r > lf; r >>= Mo, e += 1);
        return e;
    }
    const wa = (r)=>(Mo << BigInt(r)) - Mo, Va = (r)=>new Uint8Array(r), pc = (r)=>Uint8Array.from(r);
    function $h(r, e, t) {
        if (typeof r != "number" || r < 2) throw new Error("hashLen must be a number");
        if (typeof e != "number" || e < 2) throw new Error("qByteLen must be a number");
        if (typeof t != "function") throw new Error("hmacFn must be a function");
        let n = Va(r), a = Va(r), i = 0;
        const s = ()=>{
            n.fill(1), a.fill(0), i = 0;
        }, o = (...g)=>t(a, n, ...g), f = (g = Va(0))=>{
            a = o(pc([
                0
            ]), g), n = o(), g.length !== 0 && (a = o(pc([
                1
            ]), g), n = o());
        }, c = ()=>{
            if (i++ >= 1e3) throw new Error("drbg: tried 1000 values");
            let g = 0;
            const v = [];
            for(; g < e;){
                n = o();
                const w = n.slice();
                v.push(w), g += n.length;
            }
            return na(...v);
        };
        return (g, v)=>{
            s(), f(g);
            let w;
            for(; !(w = v(c()));)f();
            return s(), w;
        };
    }
    const Kh = {
        bigint: (r)=>typeof r == "bigint",
        function: (r)=>typeof r == "function",
        boolean: (r)=>typeof r == "boolean",
        string: (r)=>typeof r == "string",
        stringOrUint8Array: (r)=>typeof r == "string" || Ln(r),
        isSafeInteger: (r)=>Number.isSafeInteger(r),
        array: (r)=>Array.isArray(r),
        field: (r, e)=>e.Fp.isValid(r),
        hash: (r)=>typeof r == "function" && Number.isSafeInteger(r.outputLen)
    };
    function xa(r, e, t = {}) {
        const n = (a, i, s)=>{
            const o = Kh[i];
            if (typeof o != "function") throw new Error("invalid validator function");
            const f = r[a];
            if (!(s && f === void 0) && !o(f, r)) throw new Error("param " + String(a) + " is invalid. Expected " + i + ", got " + f);
        };
        for (const [a, i] of Object.entries(e))n(a, i, !1);
        for (const [a, i] of Object.entries(t))n(a, i, !0);
        return r;
    }
    function gc(r) {
        const e = new WeakMap;
        return (t, ...n)=>{
            const a = e.get(t);
            if (a !== void 0) return a;
            const i = r(t, ...n);
            return e.set(t, i), i;
        };
    }
    const or = BigInt(0), er = BigInt(1), mn = BigInt(2), jh = BigInt(3), Ro = BigInt(4), yc = BigInt(5), vc = BigInt(8);
    function tr(r, e) {
        const t = r % e;
        return t >= or ? t : e + t;
    }
    function hr(r, e, t) {
        let n = r;
        for(; e-- > or;)n *= n, n %= t;
        return n;
    }
    function To(r, e) {
        if (r === or) throw new Error("invert: expected non-zero number");
        if (e <= or) throw new Error("invert: expected positive modulus, got " + e);
        let t = tr(r, e), n = e, a = or, i = er;
        for(; t !== or;){
            const o = n / t, f = n % t, c = a - i * o;
            n = t, t = f, a = i, i = c;
        }
        if (n !== er) throw new Error("invert: does not exist");
        return tr(a, e);
    }
    function Hh(r) {
        let e = r - er, t = 0;
        for(; e % mn === or;)e /= mn, t++;
        let n = mn;
        const a = pf(r);
        for(; n < r && mc(a, n);)if (n++ > 1e3) throw new Error("Cannot find square root: probably non-prime P");
        if (t === 1) {
            const s = (r + er) / Ro;
            return function(f, c) {
                const h = f.pow(c, s);
                if (!f.eql(f.sqr(h), c)) throw new Error("Cannot find square root");
                return h;
            };
        }
        const i = (e + er) / mn;
        return function(o, f) {
            if (!mc(o, f)) throw new Error("Cannot find square root");
            let c = t, h = o.pow(o.mul(o.ONE, n), e), g = o.pow(f, i), v = o.pow(f, e);
            for(; !o.eql(v, o.ONE);){
                if (o.eql(v, o.ZERO)) return o.ZERO;
                let w = 1;
                for(let x = o.sqr(v); w < c && !o.eql(x, o.ONE); w++)x = o.sqr(x);
                const E = o.pow(h, er << BigInt(c - w - 1));
                h = o.sqr(E), g = o.mul(g, E), v = o.mul(v, h), c = w;
            }
            return g;
        };
    }
    function zh(r) {
        return r % Ro === jh ? function(t, n) {
            const a = (r + er) / Ro, i = t.pow(n, a);
            if (!t.eql(t.sqr(i), n)) throw new Error("Cannot find square root");
            return i;
        } : r % vc === yc ? function(t, n) {
            const a = t.mul(n, mn), i = (r - yc) / vc, s = t.pow(a, i), o = t.mul(n, s), f = t.mul(t.mul(o, mn), s), c = t.mul(o, t.sub(f, t.ONE));
            if (!t.eql(t.sqr(c), n)) throw new Error("Cannot find square root");
            return c;
        } : Hh(r);
    }
    const Wh = [
        "create",
        "isValid",
        "is0",
        "neg",
        "inv",
        "sqrt",
        "sqr",
        "eql",
        "add",
        "sub",
        "mul",
        "pow",
        "div",
        "addN",
        "subN",
        "mulN",
        "sqrN"
    ];
    function Yh(r) {
        const e = {
            ORDER: "bigint",
            MASK: "bigint",
            BYTES: "isSafeInteger",
            BITS: "isSafeInteger"
        }, t = Wh.reduce((n, a)=>(n[a] = "function", n), e);
        return xa(r, t);
    }
    function Vh(r, e, t) {
        if (t < or) throw new Error("invalid exponent, negatives unsupported");
        if (t === or) return r.ONE;
        if (t === er) return e;
        let n = r.ONE, a = e;
        for(; t > or;)t & er && (n = r.mul(n, a)), a = r.sqr(a), t >>= er;
        return n;
    }
    function j0(r, e, t = !1) {
        const n = new Array(e.length).fill(t ? r.ZERO : void 0), a = e.reduce((s, o, f)=>r.is0(o) ? s : (n[f] = s, r.mul(s, o)), r.ONE), i = r.inv(a);
        return e.reduceRight((s, o, f)=>r.is0(o) ? s : (n[f] = r.mul(s, n[f]), r.mul(s, o)), i), n;
    }
    function Gh(r, e) {
        const t = (r.ORDER - er) / mn, n = r.pow(e, t), a = r.eql(n, r.ONE), i = r.eql(n, r.ZERO), s = r.eql(n, r.neg(r.ONE));
        if (!a && !i && !s) throw new Error("Cannot find square root: probably non-prime P");
        return a ? 1 : i ? 0 : -1;
    }
    function mc(r, e) {
        const t = Gh(r, e);
        return t === 0 || t === 1;
    }
    function H0(r, e) {
        e !== void 0 && Ph(e);
        const t = e !== void 0 ? e : r.toString(2).length, n = Math.ceil(t / 8);
        return {
            nBitLength: t,
            nByteLength: n
        };
    }
    function pf(r, e, t = !1, n = {}) {
        if (r <= or) throw new Error("invalid field: expected ORDER > 0, got " + r);
        const { nBitLength: a, nByteLength: i } = H0(r, e);
        if (i > 2048) throw new Error("invalid field: expected ORDER of <= 2048 bytes");
        let s;
        const o = Object.freeze({
            ORDER: r,
            isLE: t,
            BITS: a,
            BYTES: i,
            MASK: wa(a),
            ZERO: or,
            ONE: er,
            create: (f)=>tr(f, r),
            isValid: (f)=>{
                if (typeof f != "bigint") throw new Error("invalid field element: expected bigint, got " + typeof f);
                return or <= f && f < r;
            },
            is0: (f)=>f === or,
            isOdd: (f)=>(f & er) === er,
            neg: (f)=>tr(-f, r),
            eql: (f, c)=>f === c,
            sqr: (f)=>tr(f * f, r),
            add: (f, c)=>tr(f + c, r),
            sub: (f, c)=>tr(f - c, r),
            mul: (f, c)=>tr(f * c, r),
            pow: (f, c)=>Vh(o, f, c),
            div: (f, c)=>tr(f * To(c, r), r),
            sqrN: (f)=>f * f,
            addN: (f, c)=>f + c,
            subN: (f, c)=>f - c,
            mulN: (f, c)=>f * c,
            inv: (f)=>To(f, r),
            sqrt: n.sqrt || ((f)=>(s || (s = zh(r)), s(o, f))),
            toBytes: (f)=>t ? K0(f, i) : ci(f, i),
            fromBytes: (f)=>{
                if (f.length !== i) throw new Error("Field.fromBytes: expected " + i + " bytes, got " + f.length);
                return t ? $0(f) : _n(f);
            },
            invertBatch: (f)=>j0(o, f),
            cmov: (f, c, h)=>h ? c : f
        });
        return Object.freeze(o);
    }
    function z0(r) {
        if (typeof r != "bigint") throw new Error("field order must be bigint");
        const e = r.toString(2).length;
        return Math.ceil(e / 8);
    }
    function W0(r) {
        const e = z0(r);
        return e + Math.ceil(e / 2);
    }
    function Jh(r, e, t = !1) {
        const n = r.length, a = z0(e), i = W0(e);
        if (n < 16 || n < i || n > 1024) throw new Error("expected " + i + "-1024 bytes of input, got " + n);
        const s = t ? $0(r) : _n(r), o = tr(s, e - er) + er;
        return t ? K0(o, a) : ci(o, a);
    }
    const wc = BigInt(0), Po = BigInt(1);
    function Ga(r, e) {
        const t = e.negate();
        return r ? t : e;
    }
    function Y0(r, e) {
        if (!Number.isSafeInteger(r) || r <= 0 || r > e) throw new Error("invalid window size, expected [1.." + e + "], got W=" + r);
    }
    function Ja(r, e) {
        Y0(r, e);
        const t = Math.ceil(e / r) + 1, n = 2 ** (r - 1), a = 2 ** r, i = wa(r), s = BigInt(r);
        return {
            windows: t,
            windowSize: n,
            mask: i,
            maxNumber: a,
            shiftBy: s
        };
    }
    function xc(r, e, t) {
        const { windowSize: n, mask: a, maxNumber: i, shiftBy: s } = t;
        let o = Number(r & a), f = r >> s;
        o > n && (o -= i, f += Po);
        const c = e * n, h = c + Math.abs(o) - 1, g = o === 0, v = o < 0, w = e % 2 !== 0;
        return {
            nextN: f,
            offset: h,
            isZero: g,
            isNeg: v,
            isNegF: w,
            offsetF: c
        };
    }
    function Xh(r, e) {
        if (!Array.isArray(r)) throw new Error("array expected");
        r.forEach((t, n)=>{
            if (!(t instanceof e)) throw new Error("invalid point at index " + n);
        });
    }
    function Zh(r, e) {
        if (!Array.isArray(r)) throw new Error("array of scalars expected");
        r.forEach((t, n)=>{
            if (!e.isValid(t)) throw new Error("invalid scalar at index " + n);
        });
    }
    const Xa = new WeakMap, V0 = new WeakMap;
    function Za(r) {
        return V0.get(r) || 1;
    }
    function Qh(r, e) {
        return {
            constTimeNegate: Ga,
            hasPrecomputes (t) {
                return Za(t) !== 1;
            },
            unsafeLadder (t, n, a = r.ZERO) {
                let i = t;
                for(; n > wc;)n & Po && (a = a.add(i)), i = i.double(), n >>= Po;
                return a;
            },
            precomputeWindow (t, n) {
                const { windows: a, windowSize: i } = Ja(n, e), s = [];
                let o = t, f = o;
                for(let c = 0; c < a; c++){
                    f = o, s.push(f);
                    for(let h = 1; h < i; h++)f = f.add(o), s.push(f);
                    o = f.double();
                }
                return s;
            },
            wNAF (t, n, a) {
                let i = r.ZERO, s = r.BASE;
                const o = Ja(t, e);
                for(let f = 0; f < o.windows; f++){
                    const { nextN: c, offset: h, isZero: g, isNeg: v, isNegF: w, offsetF: E } = xc(a, f, o);
                    a = c, g ? s = s.add(Ga(w, n[E])) : i = i.add(Ga(v, n[h]));
                }
                return {
                    p: i,
                    f: s
                };
            },
            wNAFUnsafe (t, n, a, i = r.ZERO) {
                const s = Ja(t, e);
                for(let o = 0; o < s.windows && a !== wc; o++){
                    const { nextN: f, offset: c, isZero: h, isNeg: g } = xc(a, o, s);
                    if (a = f, !h) {
                        const v = n[c];
                        i = i.add(g ? v.negate() : v);
                    }
                }
                return i;
            },
            getPrecomputes (t, n, a) {
                let i = Xa.get(n);
                return i || (i = this.precomputeWindow(n, t), t !== 1 && Xa.set(n, a(i))), i;
            },
            wNAFCached (t, n, a) {
                const i = Za(t);
                return this.wNAF(i, this.getPrecomputes(i, t, a), n);
            },
            wNAFCachedUnsafe (t, n, a, i) {
                const s = Za(t);
                return s === 1 ? this.unsafeLadder(t, n, i) : this.wNAFUnsafe(s, this.getPrecomputes(s, t, a), n, i);
            },
            setWindowSize (t, n) {
                Y0(n, e), V0.set(t, n), Xa.delete(t);
            }
        };
    }
    function eb(r, e, t, n) {
        if (Xh(t, r), Zh(n, e), t.length !== n.length) throw new Error("arrays of points and scalars must have equal length");
        const a = r.ZERO, i = Fh(BigInt(t.length)), s = i > 12 ? i - 3 : i > 4 ? i - 2 : i ? 2 : 1, o = wa(s), f = new Array(Number(o) + 1).fill(a), c = Math.floor((e.BITS - 1) / s) * s;
        let h = a;
        for(let g = c; g >= 0; g -= s){
            f.fill(a);
            for(let w = 0; w < n.length; w++){
                const E = n[w], x = Number(E >> BigInt(g) & o);
                f[x] = f[x].add(t[w]);
            }
            let v = a;
            for(let w = f.length - 1, E = a; w > 0; w--)E = E.add(f[w]), v = v.add(E);
            if (h = h.add(v), g !== 0) for(let w = 0; w < s; w++)h = h.double();
        }
        return h;
    }
    function G0(r) {
        return Yh(r.Fp), xa(r, {
            n: "bigint",
            h: "bigint",
            Gx: "field",
            Gy: "field"
        }, {
            nBitLength: "isSafeInteger",
            nByteLength: "isSafeInteger"
        }), Object.freeze({
            ...H0(r.n, r.nBitLength),
            ...r,
            p: r.Fp.ORDER
        });
    }
    function _c(r) {
        r.lowS !== void 0 && oi("lowS", r.lowS), r.prehash !== void 0 && oi("prehash", r.prehash);
    }
    function tb(r) {
        const e = G0(r);
        xa(e, {
            a: "field",
            b: "field"
        }, {
            allowedPrivateKeyLengths: "array",
            wrapPrivateKey: "boolean",
            isTorsionFree: "function",
            clearCofactor: "function",
            allowInfinityPoint: "boolean",
            fromBytes: "function",
            toBytes: "function"
        });
        const { endo: t, Fp: n, a } = e;
        if (t) {
            if (!n.eql(a, n.ZERO)) throw new Error("invalid endomorphism, can only be defined for Koblitz curves that have a=0");
            if (typeof t != "object" || typeof t.beta != "bigint" || typeof t.splitScalar != "function") throw new Error("invalid endomorphism, expected beta: bigint and splitScalar: function");
        }
        return Object.freeze({
            ...e
        });
    }
    let rb = class extends Error {
        constructor(e = ""){
            super(e);
        }
    };
    const $r = {
        Err: rb,
        _tlv: {
            encode: (r, e)=>{
                const { Err: t } = $r;
                if (r < 0 || r > 256) throw new t("tlv.encode: wrong tag");
                if (e.length & 1) throw new t("tlv.encode: unpadded data");
                const n = e.length / 2, a = Ai(n);
                if (a.length / 2 & 128) throw new t("tlv.encode: long form length too big");
                const i = n > 127 ? Ai(a.length / 2 | 128) : "";
                return Ai(r) + i + a + e;
            },
            decode (r, e) {
                const { Err: t } = $r;
                let n = 0;
                if (r < 0 || r > 256) throw new t("tlv.encode: wrong tag");
                if (e.length < 2 || e[n++] !== r) throw new t("tlv.decode: wrong tlv");
                const a = e[n++], i = !!(a & 128);
                let s = 0;
                if (!i) s = a;
                else {
                    const f = a & 127;
                    if (!f) throw new t("tlv.decode(long): indefinite length not supported");
                    if (f > 4) throw new t("tlv.decode(long): byte length is too big");
                    const c = e.subarray(n, n + f);
                    if (c.length !== f) throw new t("tlv.decode: length bytes not complete");
                    if (c[0] === 0) throw new t("tlv.decode(long): zero leftmost byte");
                    for (const h of c)s = s << 8 | h;
                    if (n += f, s < 128) throw new t("tlv.decode(long): not minimal encoding");
                }
                const o = e.subarray(n, n + s);
                if (o.length !== s) throw new t("tlv.decode: wrong value length");
                return {
                    v: o,
                    l: e.subarray(n + s)
                };
            }
        },
        _int: {
            encode (r) {
                const { Err: e } = $r;
                if (r < Kr) throw new e("integer: negative integers are not allowed");
                let t = Ai(r);
                if (Number.parseInt(t[0], 16) & 8 && (t = "00" + t), t.length & 1) throw new e("unexpected DER parsing assertion: unpadded hex");
                return t;
            },
            decode (r) {
                const { Err: e } = $r;
                if (r[0] & 128) throw new e("invalid signature integer: negative");
                if (r[0] === 0 && !(r[1] & 128)) throw new e("invalid signature integer: unnecessary leading zero");
                return _n(r);
            }
        },
        toSig (r) {
            const { Err: e, _int: t, _tlv: n } = $r, a = mr("signature", r), { v: i, l: s } = n.decode(48, a);
            if (s.length) throw new e("invalid signature: left bytes after parsing");
            const { v: o, l: f } = n.decode(2, i), { v: c, l: h } = n.decode(2, f);
            if (h.length) throw new e("invalid signature: left bytes after parsing");
            return {
                r: t.decode(o),
                s: t.decode(c)
            };
        },
        hexFromSig (r) {
            const { _tlv: e, _int: t } = $r, n = e.encode(2, t.encode(r.r)), a = e.encode(2, t.encode(r.s)), i = n + a;
            return e.encode(48, i);
        }
    }, Kr = BigInt(0), Wt = BigInt(1);
    BigInt(2);
    const Sc = BigInt(3);
    BigInt(4);
    function nb(r) {
        const e = tb(r), { Fp: t } = e, n = pf(e.n, e.nBitLength), a = e.toBytes || ((x, S, y)=>{
            const A = S.toAffine();
            return na(Uint8Array.from([
                4
            ]), t.toBytes(A.x), t.toBytes(A.y));
        }), i = e.fromBytes || ((x)=>{
            const S = x.subarray(1), y = t.fromBytes(S.subarray(0, t.BYTES)), A = t.fromBytes(S.subarray(t.BYTES, 2 * t.BYTES));
            return {
                x: y,
                y: A
            };
        });
        function s(x) {
            const { a: S, b: y } = e, A = t.sqr(x), P = t.mul(A, x);
            return t.add(t.add(P, t.mul(x, S)), y);
        }
        if (!t.eql(t.sqr(e.Gy), s(e.Gx))) throw new Error("bad generator point: equation left != right");
        function o(x) {
            return bf(x, Wt, e.n);
        }
        function f(x) {
            const { allowedPrivateKeyLengths: S, nByteLength: y, wrapPrivateKey: A, n: P } = e;
            if (S && typeof x != "bigint") {
                if (Ln(x) && (x = fi(x)), typeof x != "string" || !S.includes(x.length)) throw new Error("invalid private key");
                x = x.padStart(y * 2, "0");
            }
            let N;
            try {
                N = typeof x == "bigint" ? x : _n(mr("private key", x, y));
            } catch  {
                throw new Error("invalid private key, expected hex or " + y + " bytes, got " + typeof x);
            }
            return A && (N = tr(N, P)), On("private key", N, Wt, P), N;
        }
        function c(x) {
            if (!(x instanceof v)) throw new Error("ProjectivePoint expected");
        }
        const h = gc((x, S)=>{
            const { px: y, py: A, pz: P } = x;
            if (t.eql(P, t.ONE)) return {
                x: y,
                y: A
            };
            const N = x.is0();
            S == null && (S = N ? t.ONE : t.inv(P));
            const k = t.mul(y, S), D = t.mul(A, S), V = t.mul(P, S);
            if (N) return {
                x: t.ZERO,
                y: t.ZERO
            };
            if (!t.eql(V, t.ONE)) throw new Error("invZ was invalid");
            return {
                x: k,
                y: D
            };
        }), g = gc((x)=>{
            if (x.is0()) {
                if (e.allowInfinityPoint && !t.is0(x.py)) return;
                throw new Error("bad point: ZERO");
            }
            const { x: S, y } = x.toAffine();
            if (!t.isValid(S) || !t.isValid(y)) throw new Error("bad point: x or y not FE");
            const A = t.sqr(y), P = s(S);
            if (!t.eql(A, P)) throw new Error("bad point: equation left != right");
            if (!x.isTorsionFree()) throw new Error("bad point: not in prime-order subgroup");
            return !0;
        });
        class v {
            constructor(S, y, A){
                if (S == null || !t.isValid(S)) throw new Error("x required");
                if (y == null || !t.isValid(y) || t.is0(y)) throw new Error("y required");
                if (A == null || !t.isValid(A)) throw new Error("z required");
                this.px = S, this.py = y, this.pz = A, Object.freeze(this);
            }
            static fromAffine(S) {
                const { x: y, y: A } = S || {};
                if (!S || !t.isValid(y) || !t.isValid(A)) throw new Error("invalid affine point");
                if (S instanceof v) throw new Error("projective point not allowed");
                const P = (N)=>t.eql(N, t.ZERO);
                return P(y) && P(A) ? v.ZERO : new v(y, A, t.ONE);
            }
            get x() {
                return this.toAffine().x;
            }
            get y() {
                return this.toAffine().y;
            }
            static normalizeZ(S) {
                const y = j0(t, S.map((A)=>A.pz));
                return S.map((A, P)=>A.toAffine(y[P])).map(v.fromAffine);
            }
            static fromHex(S) {
                const y = v.fromAffine(i(mr("pointHex", S)));
                return y.assertValidity(), y;
            }
            static fromPrivateKey(S) {
                return v.BASE.multiply(f(S));
            }
            static msm(S, y) {
                return eb(v, n, S, y);
            }
            _setWindowSize(S) {
                E.setWindowSize(this, S);
            }
            assertValidity() {
                g(this);
            }
            hasEvenY() {
                const { y: S } = this.toAffine();
                if (t.isOdd) return !t.isOdd(S);
                throw new Error("Field doesn't support isOdd");
            }
            equals(S) {
                c(S);
                const { px: y, py: A, pz: P } = this, { px: N, py: k, pz: D } = S, V = t.eql(t.mul(y, D), t.mul(N, P)), K = t.eql(t.mul(A, D), t.mul(k, P));
                return V && K;
            }
            negate() {
                return new v(this.px, t.neg(this.py), this.pz);
            }
            double() {
                const { a: S, b: y } = e, A = t.mul(y, Sc), { px: P, py: N, pz: k } = this;
                let D = t.ZERO, V = t.ZERO, K = t.ZERO, j = t.mul(P, P), H = t.mul(N, N), O = t.mul(k, k), d = t.mul(P, N);
                return d = t.add(d, d), K = t.mul(P, k), K = t.add(K, K), D = t.mul(S, K), V = t.mul(A, O), V = t.add(D, V), D = t.sub(H, V), V = t.add(H, V), V = t.mul(D, V), D = t.mul(d, D), K = t.mul(A, K), O = t.mul(S, O), d = t.sub(j, O), d = t.mul(S, d), d = t.add(d, K), K = t.add(j, j), j = t.add(K, j), j = t.add(j, O), j = t.mul(j, d), V = t.add(V, j), O = t.mul(N, k), O = t.add(O, O), j = t.mul(O, d), D = t.sub(D, j), K = t.mul(O, H), K = t.add(K, K), K = t.add(K, K), new v(D, V, K);
            }
            add(S) {
                c(S);
                const { px: y, py: A, pz: P } = this, { px: N, py: k, pz: D } = S;
                let V = t.ZERO, K = t.ZERO, j = t.ZERO;
                const H = e.a, O = t.mul(e.b, Sc);
                let d = t.mul(y, N), l = t.mul(A, k), b = t.mul(P, D), m = t.add(y, A), _ = t.add(N, k);
                m = t.mul(m, _), _ = t.add(d, l), m = t.sub(m, _), _ = t.add(y, P);
                let B = t.add(N, D);
                return _ = t.mul(_, B), B = t.add(d, b), _ = t.sub(_, B), B = t.add(A, P), V = t.add(k, D), B = t.mul(B, V), V = t.add(l, b), B = t.sub(B, V), j = t.mul(H, _), V = t.mul(O, b), j = t.add(V, j), V = t.sub(l, j), j = t.add(l, j), K = t.mul(V, j), l = t.add(d, d), l = t.add(l, d), b = t.mul(H, b), _ = t.mul(O, _), l = t.add(l, b), b = t.sub(d, b), b = t.mul(H, b), _ = t.add(_, b), d = t.mul(l, _), K = t.add(K, d), d = t.mul(B, _), V = t.mul(m, V), V = t.sub(V, d), d = t.mul(m, l), j = t.mul(B, j), j = t.add(j, d), new v(V, K, j);
            }
            subtract(S) {
                return this.add(S.negate());
            }
            is0() {
                return this.equals(v.ZERO);
            }
            wNAF(S) {
                return E.wNAFCached(this, S, v.normalizeZ);
            }
            multiplyUnsafe(S) {
                const { endo: y, n: A } = e;
                On("scalar", S, Kr, A);
                const P = v.ZERO;
                if (S === Kr) return P;
                if (this.is0() || S === Wt) return this;
                if (!y || E.hasPrecomputes(this)) return E.wNAFCachedUnsafe(this, S, v.normalizeZ);
                let { k1neg: N, k1: k, k2neg: D, k2: V } = y.splitScalar(S), K = P, j = P, H = this;
                for(; k > Kr || V > Kr;)k & Wt && (K = K.add(H)), V & Wt && (j = j.add(H)), H = H.double(), k >>= Wt, V >>= Wt;
                return N && (K = K.negate()), D && (j = j.negate()), j = new v(t.mul(j.px, y.beta), j.py, j.pz), K.add(j);
            }
            multiply(S) {
                const { endo: y, n: A } = e;
                On("scalar", S, Wt, A);
                let P, N;
                if (y) {
                    const { k1neg: k, k1: D, k2neg: V, k2: K } = y.splitScalar(S);
                    let { p: j, f: H } = this.wNAF(D), { p: O, f: d } = this.wNAF(K);
                    j = E.constTimeNegate(k, j), O = E.constTimeNegate(V, O), O = new v(t.mul(O.px, y.beta), O.py, O.pz), P = j.add(O), N = H.add(d);
                } else {
                    const { p: k, f: D } = this.wNAF(S);
                    P = k, N = D;
                }
                return v.normalizeZ([
                    P,
                    N
                ])[0];
            }
            multiplyAndAddUnsafe(S, y, A) {
                const P = v.BASE, N = (D, V)=>V === Kr || V === Wt || !D.equals(P) ? D.multiplyUnsafe(V) : D.multiply(V), k = N(this, y).add(N(S, A));
                return k.is0() ? void 0 : k;
            }
            toAffine(S) {
                return h(this, S);
            }
            isTorsionFree() {
                const { h: S, isTorsionFree: y } = e;
                if (S === Wt) return !0;
                if (y) return y(v, this);
                throw new Error("isTorsionFree() has not been declared for the elliptic curve");
            }
            clearCofactor() {
                const { h: S, clearCofactor: y } = e;
                return S === Wt ? this : y ? y(v, this) : this.multiplyUnsafe(e.h);
            }
            toRawBytes(S = !0) {
                return oi("isCompressed", S), this.assertValidity(), a(v, this, S);
            }
            toHex(S = !0) {
                return oi("isCompressed", S), fi(this.toRawBytes(S));
            }
        }
        v.BASE = new v(e.Gx, e.Gy, t.ONE), v.ZERO = new v(t.ZERO, t.ONE, t.ZERO);
        const w = e.nBitLength, E = Qh(v, e.endo ? Math.ceil(w / 2) : w);
        return {
            CURVE: e,
            ProjectivePoint: v,
            normPrivateKeyToScalar: f,
            weierstrassEquation: s,
            isWithinCurveOrder: o
        };
    }
    function ib(r) {
        const e = G0(r);
        return xa(e, {
            hash: "hash",
            hmac: "function",
            randomBytes: "function"
        }, {
            bits2int: "function",
            bits2int_modN: "function",
            lowS: "boolean"
        }), Object.freeze({
            lowS: !0,
            ...e
        });
    }
    function ab(r) {
        const e = ib(r), { Fp: t, n } = e, a = t.BYTES + 1, i = 2 * t.BYTES + 1;
        function s(b) {
            return tr(b, n);
        }
        function o(b) {
            return To(b, n);
        }
        const { ProjectivePoint: f, normPrivateKeyToScalar: c, weierstrassEquation: h, isWithinCurveOrder: g } = nb({
            ...e,
            toBytes (b, m, _) {
                const B = m.toAffine(), T = t.toBytes(B.x), R = na;
                return oi("isCompressed", _), _ ? R(Uint8Array.from([
                    m.hasEvenY() ? 2 : 3
                ]), T) : R(Uint8Array.from([
                    4
                ]), T, t.toBytes(B.y));
            },
            fromBytes (b) {
                const m = b.length, _ = b[0], B = b.subarray(1);
                if (m === a && (_ === 2 || _ === 3)) {
                    const T = _n(B);
                    if (!bf(T, Wt, t.ORDER)) throw new Error("Point is not on curve");
                    const R = h(T);
                    let u;
                    try {
                        u = t.sqrt(R);
                    } catch ($) {
                        const te = $ instanceof Error ? ": " + $.message : "";
                        throw new Error("Point is not on curve" + te);
                    }
                    const I = (u & Wt) === Wt;
                    return (_ & 1) === 1 !== I && (u = t.neg(u)), {
                        x: T,
                        y: u
                    };
                } else if (m === i && _ === 4) {
                    const T = t.fromBytes(B.subarray(0, t.BYTES)), R = t.fromBytes(B.subarray(t.BYTES, 2 * t.BYTES));
                    return {
                        x: T,
                        y: R
                    };
                } else {
                    const T = a, R = i;
                    throw new Error("invalid Point, expected length of " + T + ", or uncompressed " + R + ", got " + m);
                }
            }
        }), v = (b)=>fi(ci(b, e.nByteLength));
        function w(b) {
            const m = n >> Wt;
            return b > m;
        }
        function E(b) {
            return w(b) ? s(-b) : b;
        }
        const x = (b, m, _)=>_n(b.slice(m, _));
        class S {
            constructor(m, _, B){
                On("r", m, Wt, n), On("s", _, Wt, n), this.r = m, this.s = _, B != null && (this.recovery = B), Object.freeze(this);
            }
            static fromCompact(m) {
                const _ = e.nByteLength;
                return m = mr("compactSignature", m, _ * 2), new S(x(m, 0, _), x(m, _, 2 * _));
            }
            static fromDER(m) {
                const { r: _, s: B } = $r.toSig(mr("DER", m));
                return new S(_, B);
            }
            assertValidity() {}
            addRecoveryBit(m) {
                return new S(this.r, this.s, m);
            }
            recoverPublicKey(m) {
                const { r: _, s: B, recovery: T } = this, R = D(mr("msgHash", m));
                if (T == null || ![
                    0,
                    1,
                    2,
                    3
                ].includes(T)) throw new Error("recovery id invalid");
                const u = T === 2 || T === 3 ? _ + e.n : _;
                if (u >= t.ORDER) throw new Error("recovery id 2 or 3 invalid");
                const I = (T & 1) === 0 ? "02" : "03", G = f.fromHex(I + v(u)), $ = o(u), te = s(-R * $), Z = s(B * $), fe = f.BASE.multiplyAndAddUnsafe(G, te, Z);
                if (!fe) throw new Error("point at infinify");
                return fe.assertValidity(), fe;
            }
            hasHighS() {
                return w(this.s);
            }
            normalizeS() {
                return this.hasHighS() ? new S(this.r, s(-this.s), this.recovery) : this;
            }
            toDERRawBytes() {
                return ra(this.toDERHex());
            }
            toDERHex() {
                return $r.hexFromSig(this);
            }
            toCompactRawBytes() {
                return ra(this.toCompactHex());
            }
            toCompactHex() {
                return v(this.r) + v(this.s);
            }
        }
        const y = {
            isValidPrivateKey (b) {
                try {
                    return c(b), !0;
                } catch  {
                    return !1;
                }
            },
            normPrivateKeyToScalar: c,
            randomPrivateKey: ()=>{
                const b = W0(e.n);
                return Jh(e.randomBytes(b), e.n);
            },
            precompute (b = 8, m = f.BASE) {
                return m._setWindowSize(b), m.multiply(BigInt(3)), m;
            }
        };
        function A(b, m = !0) {
            return f.fromPrivateKey(b).toRawBytes(m);
        }
        function P(b) {
            const m = Ln(b), _ = typeof b == "string", B = (m || _) && b.length;
            return m ? B === a || B === i : _ ? B === 2 * a || B === 2 * i : b instanceof f;
        }
        function N(b, m, _ = !0) {
            if (P(b)) throw new Error("first arg must be private key");
            if (!P(m)) throw new Error("second arg must be public key");
            return f.fromHex(m).multiply(c(b)).toRawBytes(_);
        }
        const k = e.bits2int || function(b) {
            if (b.length > 8192) throw new Error("input is too large");
            const m = _n(b), _ = b.length * 8 - e.nBitLength;
            return _ > 0 ? m >> BigInt(_) : m;
        }, D = e.bits2int_modN || function(b) {
            return s(k(b));
        }, V = wa(e.nBitLength);
        function K(b) {
            return On("num < 2^" + e.nBitLength, b, Kr, V), ci(b, e.nByteLength);
        }
        function j(b, m, _ = H) {
            if ([
                "recovered",
                "canonical"
            ].some((ee)=>ee in _)) throw new Error("sign() legacy options not supported");
            const { hash: B, randomBytes: T } = e;
            let { lowS: R, prehash: u, extraEntropy: I } = _;
            R == null && (R = !0), b = mr("msgHash", b), _c(_), u && (b = mr("prehashed msgHash", B(b)));
            const G = D(b), $ = c(m), te = [
                K($),
                K(G)
            ];
            if (I != null && I !== !1) {
                const ee = I === !0 ? T(t.BYTES) : I;
                te.push(mr("extraEntropy", ee));
            }
            const Z = na(...te), fe = G;
            function pe(ee) {
                const J = k(ee);
                if (!g(J)) return;
                const oe = o(J), Me = f.BASE.multiply(J).toAffine(), xe = s(Me.x);
                if (xe === Kr) return;
                const z = s(oe * s(fe + xe * $));
                if (z === Kr) return;
                let X = (Me.x === xe ? 0 : 2) | Number(Me.y & Wt), re = z;
                return R && w(z) && (re = E(z), X ^= 1), new S(xe, re, X);
            }
            return {
                seed: Z,
                k2sig: pe
            };
        }
        const H = {
            lowS: e.lowS,
            prehash: !1
        }, O = {
            lowS: e.lowS,
            prehash: !1
        };
        function d(b, m, _ = H) {
            const { seed: B, k2sig: T } = j(b, m, _), R = e;
            return $h(R.hash.outputLen, R.nByteLength, R.hmac)(B, T);
        }
        f.BASE._setWindowSize(8);
        function l(b, m, _, B = O) {
            const T = b;
            m = mr("msgHash", m), _ = mr("publicKey", _);
            const { lowS: R, prehash: u, format: I } = B;
            if (_c(B), "strict" in B) throw new Error("options.strict was renamed to lowS");
            if (I !== void 0 && I !== "compact" && I !== "der") throw new Error("format must be compact or der");
            const G = typeof T == "string" || Ln(T), $ = !G && !I && typeof T == "object" && T !== null && typeof T.r == "bigint" && typeof T.s == "bigint";
            if (!G && !$) throw new Error("invalid signature, expected Uint8Array, hex string or Signature instance");
            let te, Z;
            try {
                if ($ && (te = new S(T.r, T.s)), G) {
                    try {
                        I !== "compact" && (te = S.fromDER(T));
                    } catch (X) {
                        if (!(X instanceof $r.Err)) throw X;
                    }
                    !te && I !== "der" && (te = S.fromCompact(T));
                }
                Z = f.fromHex(_);
            } catch  {
                return !1;
            }
            if (!te || R && te.hasHighS()) return !1;
            u && (m = e.hash(m));
            const { r: fe, s: pe } = te, ee = D(m), J = o(pe), oe = s(ee * J), Me = s(fe * J), xe = f.BASE.multiplyAndAddUnsafe(Z, oe, Me)?.toAffine();
            return xe ? s(xe.x) === fe : !1;
        }
        return {
            CURVE: e,
            getPublicKey: A,
            getSharedSecret: N,
            sign: d,
            verify: l,
            ProjectivePoint: f,
            Signature: S,
            utils: y
        };
    }
    function sb(r) {
        return {
            hash: r,
            hmac: (e, ...t)=>Ao(r, e, Zn(...t)),
            randomBytes: U0
        };
    }
    function ob(r, e) {
        const t = (n)=>ab({
                ...r,
                ...sb(n)
            });
        return {
            ...t(e),
            create: t
        };
    }
    const J0 = BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"), Ec = BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"), fb = BigInt(1), Bo = BigInt(2), Ac = (r, e)=>(r + e / Bo) / e;
    function cb(r) {
        const e = J0, t = BigInt(3), n = BigInt(6), a = BigInt(11), i = BigInt(22), s = BigInt(23), o = BigInt(44), f = BigInt(88), c = r * r * r % e, h = c * c * r % e, g = hr(h, t, e) * h % e, v = hr(g, t, e) * h % e, w = hr(v, Bo, e) * c % e, E = hr(w, a, e) * w % e, x = hr(E, i, e) * E % e, S = hr(x, o, e) * x % e, y = hr(S, f, e) * S % e, A = hr(y, o, e) * x % e, P = hr(A, t, e) * h % e, N = hr(P, s, e) * E % e, k = hr(N, n, e) * c % e, D = hr(k, Bo, e);
        if (!Oo.eql(Oo.sqr(D), r)) throw new Error("Cannot find square root");
        return D;
    }
    const Oo = pf(J0, void 0, void 0, {
        sqrt: cb
    }), Rr = ob({
        a: BigInt(0),
        b: BigInt(7),
        Fp: Oo,
        n: Ec,
        Gx: BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),
        Gy: BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),
        h: BigInt(1),
        lowS: !0,
        endo: {
            beta: BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),
            splitScalar: (r)=>{
                const e = Ec, t = BigInt("0x3086d221a7d46bcde86c90e49284eb15"), n = -fb * BigInt("0xe4437ed6010e88286f547fa90abfe4c3"), a = BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"), i = t, s = BigInt("0x100000000000000000000000000000000"), o = Ac(i * r, e), f = Ac(-n * r, e);
                let c = tr(r - o * t - f * a, e), h = tr(-o * n - f * i, e);
                const g = c > s, v = h > s;
                if (g && (c = e - c), v && (h = e - h), c > s || h > s) throw new Error("splitScalar: Endomorphism failed, k=" + r);
                return {
                    k1neg: g,
                    k1: c,
                    k2neg: v,
                    k2: h
                };
            }
        }
    }, df);
    BigInt(0);
    Rr.ProjectivePoint;
    const db = Uint8Array.from([
        7,
        4,
        13,
        1,
        10,
        6,
        15,
        3,
        12,
        0,
        9,
        5,
        2,
        14,
        11,
        8
    ]), X0 = Uint8Array.from(new Array(16).fill(0).map((r, e)=>e)), ub = X0.map((r)=>(9 * r + 5) % 16), Z0 = (()=>{
        const t = [
            [
                X0
            ],
            [
                ub
            ]
        ];
        for(let n = 0; n < 4; n++)for (let a of t)a.push(a[n].map((i)=>db[i]));
        return t;
    })(), Q0 = Z0[0], eu = Z0[1], tu = [
        [
            11,
            14,
            15,
            12,
            5,
            8,
            7,
            9,
            11,
            13,
            14,
            15,
            6,
            7,
            9,
            8
        ],
        [
            12,
            13,
            11,
            15,
            6,
            9,
            9,
            7,
            12,
            15,
            11,
            13,
            7,
            8,
            7,
            7
        ],
        [
            13,
            15,
            14,
            11,
            7,
            7,
            6,
            8,
            13,
            14,
            13,
            12,
            5,
            5,
            6,
            9
        ],
        [
            14,
            11,
            12,
            14,
            8,
            6,
            5,
            5,
            15,
            12,
            15,
            14,
            9,
            9,
            8,
            6
        ],
        [
            15,
            12,
            13,
            13,
            9,
            5,
            8,
            6,
            14,
            11,
            12,
            11,
            8,
            6,
            5,
            5
        ]
    ].map((r)=>Uint8Array.from(r)), lb = Q0.map((r, e)=>r.map((t)=>tu[e][t])), hb = eu.map((r, e)=>r.map((t)=>tu[e][t])), bb = Uint32Array.from([
        0,
        1518500249,
        1859775393,
        2400959708,
        2840853838
    ]), pb = Uint32Array.from([
        1352829926,
        1548603684,
        1836072691,
        2053994217,
        0
    ]);
    function Ic(r, e, t, n) {
        return r === 0 ? e ^ t ^ n : r === 1 ? e & t | ~e & n : r === 2 ? (e | ~t) ^ n : r === 3 ? e & n | t & ~n : e ^ (t | ~n);
    }
    const Ii = new Uint32Array(16);
    class gb extends Oh {
        constructor(){
            super(64, 20, 8, !0), this.h0 = 1732584193, this.h1 = -271733879, this.h2 = -1732584194, this.h3 = 271733878, this.h4 = -1009589776;
        }
        get() {
            const { h0: e, h1: t, h2: n, h3: a, h4: i } = this;
            return [
                e,
                t,
                n,
                a,
                i
            ];
        }
        set(e, t, n, a, i) {
            this.h0 = e | 0, this.h1 = t | 0, this.h2 = n | 0, this.h3 = a | 0, this.h4 = i | 0;
        }
        process(e, t) {
            for(let w = 0; w < 16; w++, t += 4)Ii[w] = e.getUint32(t, !0);
            let n = this.h0 | 0, a = n, i = this.h1 | 0, s = i, o = this.h2 | 0, f = o, c = this.h3 | 0, h = c, g = this.h4 | 0, v = g;
            for(let w = 0; w < 5; w++){
                const E = 4 - w, x = bb[w], S = pb[w], y = Q0[w], A = eu[w], P = lb[w], N = hb[w];
                for(let k = 0; k < 16; k++){
                    const D = Ei(n + Ic(w, i, o, c) + Ii[y[k]] + x, P[k]) + g | 0;
                    n = g, g = c, c = Ei(o, 10) | 0, o = i, i = D;
                }
                for(let k = 0; k < 16; k++){
                    const D = Ei(a + Ic(E, s, f, h) + Ii[A[k]] + S, N[k]) + v | 0;
                    a = v, v = h, h = Ei(f, 10) | 0, f = s, s = D;
                }
            }
            this.set(this.h1 + o + h | 0, this.h2 + c + v | 0, this.h3 + g + a | 0, this.h4 + n + s | 0, this.h0 + i + f | 0);
        }
        roundClean() {
            dc(Ii);
        }
        destroy() {
            this.destroyed = !0, dc(this.buffer), this.set(0, 0, 0, 0, 0);
        }
    }
    const yb = Bh(()=>new gb);
    function ko(r) {
        return r instanceof Uint8Array || ArrayBuffer.isView(r) && r.constructor.name === "Uint8Array";
    }
    function ru(r, e) {
        return Array.isArray(e) ? e.length === 0 ? !0 : r ? e.every((t)=>typeof t == "string") : e.every((t)=>Number.isSafeInteger(t)) : !1;
    }
    function vb(r) {
        if (typeof r != "function") throw new Error("function expected");
        return !0;
    }
    function No(r, e) {
        if (typeof e != "string") throw new Error(`${r}: string expected`);
        return !0;
    }
    function gf(r) {
        if (!Number.isSafeInteger(r)) throw new Error(`invalid integer: ${r}`);
    }
    function Co(r) {
        if (!Array.isArray(r)) throw new Error("array expected");
    }
    function nu(r, e) {
        if (!ru(!0, e)) throw new Error(`${r}: array of strings expected`);
    }
    function mb(r, e) {
        if (!ru(!1, e)) throw new Error(`${r}: array of numbers expected`);
    }
    function iu(...r) {
        const e = (i)=>i, t = (i, s)=>(o)=>i(s(o)), n = r.map((i)=>i.encode).reduceRight(t, e), a = r.map((i)=>i.decode).reduce(t, e);
        return {
            encode: n,
            decode: a
        };
    }
    function wb(r) {
        const e = typeof r == "string" ? r.split("") : r, t = e.length;
        nu("alphabet", e);
        const n = new Map(e.map((a, i)=>[
                a,
                i
            ]));
        return {
            encode: (a)=>(Co(a), a.map((i)=>{
                    if (!Number.isSafeInteger(i) || i < 0 || i >= t) throw new Error(`alphabet.encode: digit index outside alphabet "${i}". Allowed: ${r}`);
                    return e[i];
                })),
            decode: (a)=>(Co(a), a.map((i)=>{
                    No("alphabet.decode", i);
                    const s = n.get(i);
                    if (s === void 0) throw new Error(`Unknown letter: "${i}". Allowed: ${r}`);
                    return s;
                }))
        };
    }
    function xb(r = "") {
        return No("join", r), {
            encode: (e)=>(nu("join.decode", e), e.join(r)),
            decode: (e)=>(No("join.decode", e), e.split(r))
        };
    }
    function Mc(r, e, t) {
        if (e < 2) throw new Error(`convertRadix: invalid from=${e}, base cannot be less than 2`);
        if (t < 2) throw new Error(`convertRadix: invalid to=${t}, base cannot be less than 2`);
        if (Co(r), !r.length) return [];
        let n = 0;
        const a = [], i = Array.from(r, (o)=>{
            if (gf(o), o < 0 || o >= e) throw new Error(`invalid integer: ${o}`);
            return o;
        }), s = i.length;
        for(;;){
            let o = 0, f = !0;
            for(let c = n; c < s; c++){
                const h = i[c], g = e * o, v = g + h;
                if (!Number.isSafeInteger(v) || g / e !== o || v - h !== g) throw new Error("convertRadix: carry overflow");
                const w = v / t;
                o = v % t;
                const E = Math.floor(w);
                if (i[c] = E, !Number.isSafeInteger(E) || E * t + o !== v) throw new Error("convertRadix: carry overflow");
                if (f) E ? f = !1 : n = c;
                else continue;
            }
            if (a.push(o), f) break;
        }
        for(let o = 0; o < r.length - 1 && r[o] === 0; o++)a.push(0);
        return a.reverse();
    }
    function _b(r) {
        gf(r);
        const e = 2 ** 8;
        return {
            encode: (t)=>{
                if (!ko(t)) throw new Error("radix.encode input should be Uint8Array");
                return Mc(Array.from(t), e, r);
            },
            decode: (t)=>(mb("radix.decode", t), Uint8Array.from(Mc(t, r, e)))
        };
    }
    function Sb(r, e) {
        return gf(r), vb(e), {
            encode (t) {
                if (!ko(t)) throw new Error("checksum.encode: input should be Uint8Array");
                const n = e(t).slice(0, r), a = new Uint8Array(t.length + r);
                return a.set(t), a.set(n, t.length), a;
            },
            decode (t) {
                if (!ko(t)) throw new Error("checksum.decode: input should be Uint8Array");
                const n = t.slice(0, -r), a = t.slice(-r), i = e(n).slice(0, r);
                for(let s = 0; s < r; s++)if (i[s] !== a[s]) throw new Error("Invalid checksum");
                return n;
            }
        };
    }
    const Eb = (r)=>iu(_b(58), wb(r), xb("")), Ab = Eb("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"), Ib = (r)=>iu(Sb(4, (e)=>r(r(e))), Ab);
    const Mi = Rr.ProjectivePoint, Qa = Ib(df);
    function Rc(r) {
        yn(r);
        const e = r.length === 0 ? "0" : Nh(r);
        return BigInt("0x" + e);
    }
    function Mb(r) {
        if (typeof r != "bigint") throw new Error("bigint expected");
        return Ch(r.toString(16).padStart(64, "0"));
    }
    const Rb = kh("Bitcoin seed"), es = {
        private: 76066276,
        public: 76067358
    }, ts = 2147483648, Tb = (r)=>yb(df(r)), Pb = (r)=>uf(r).getUint32(0, !1), Ri = (r)=>{
        if (!Number.isSafeInteger(r) || r < 0 || r > 2 ** 32 - 1) throw new Error("invalid number, should be from 0 to 2**32-1, got " + r);
        const e = new Uint8Array(4);
        return uf(e).setUint32(0, r, !1), e;
    };
    class vn {
        get fingerprint() {
            if (!this.pubHash) throw new Error("No publicKey set!");
            return Pb(this.pubHash);
        }
        get identifier() {
            return this.pubHash;
        }
        get pubKeyHash() {
            return this.pubHash;
        }
        get privateKey() {
            return this.privKeyBytes || null;
        }
        get publicKey() {
            return this.pubKey || null;
        }
        get privateExtendedKey() {
            const e = this.privateKey;
            if (!e) throw new Error("No private key");
            return Qa.encode(this.serialize(this.versions.private, Zn(new Uint8Array([
                0
            ]), e)));
        }
        get publicExtendedKey() {
            if (!this.pubKey) throw new Error("No public key");
            return Qa.encode(this.serialize(this.versions.public, this.pubKey));
        }
        static fromMasterSeed(e, t = es) {
            if (yn(e), 8 * e.length < 128 || 8 * e.length > 512) throw new Error("HDKey: seed length must be between 128 and 512 bits; 256 bits is advised, got " + e.length);
            const n = Ao(Io, Rb, e);
            return new vn({
                versions: t,
                chainCode: n.slice(32),
                privateKey: n.slice(0, 32)
            });
        }
        static fromExtendedKey(e, t = es) {
            const n = Qa.decode(e), a = uf(n), i = a.getUint32(0, !1), s = {
                versions: t,
                depth: n[4],
                parentFingerprint: a.getUint32(5, !1),
                index: a.getUint32(9, !1),
                chainCode: n.slice(13, 45)
            }, o = n.slice(45), f = o[0] === 0;
            if (i !== t[f ? "private" : "public"]) throw new Error("Version mismatch");
            return f ? new vn({
                ...s,
                privateKey: o.slice(1)
            }) : new vn({
                ...s,
                publicKey: o
            });
        }
        static fromJSON(e) {
            return vn.fromExtendedKey(e.xpriv);
        }
        constructor(e){
            if (this.depth = 0, this.index = 0, this.chainCode = null, this.parentFingerprint = 0, !e || typeof e != "object") throw new Error("HDKey.constructor must not be called directly");
            if (this.versions = e.versions || es, this.depth = e.depth || 0, this.chainCode = e.chainCode || null, this.index = e.index || 0, this.parentFingerprint = e.parentFingerprint || 0, !this.depth && (this.parentFingerprint || this.index)) throw new Error("HDKey: zero depth with non-zero index/parent fingerprint");
            if (e.publicKey && e.privateKey) throw new Error("HDKey: publicKey and privateKey at same time.");
            if (e.privateKey) {
                if (!Rr.utils.isValidPrivateKey(e.privateKey)) throw new Error("Invalid private key");
                this.privKey = typeof e.privateKey == "bigint" ? e.privateKey : Rc(e.privateKey), this.privKeyBytes = Mb(this.privKey), this.pubKey = Rr.getPublicKey(e.privateKey, !0);
            } else if (e.publicKey) this.pubKey = Mi.fromHex(e.publicKey).toRawBytes(!0);
            else throw new Error("HDKey: no public or private key provided");
            this.pubHash = Tb(this.pubKey);
        }
        derive(e) {
            if (!/^[mM]'?/.test(e)) throw new Error('Path must start with "m" or "M"');
            if (/^[mM]'?$/.test(e)) return this;
            const t = e.replace(/^[mM]'?\//, "").split("/");
            let n = this;
            for (const a of t){
                const i = /^(\d+)('?)$/.exec(a), s = i && i[1];
                if (!i || i.length !== 3 || typeof s != "string") throw new Error("invalid child index: " + a);
                let o = +s;
                if (!Number.isSafeInteger(o) || o >= ts) throw new Error("Invalid index");
                i[2] === "'" && (o += ts), n = n.deriveChild(o);
            }
            return n;
        }
        deriveChild(e) {
            if (!this.pubKey || !this.chainCode) throw new Error("No publicKey or chainCode set");
            let t = Ri(e);
            if (e >= ts) {
                const o = this.privateKey;
                if (!o) throw new Error("Could not derive hardened child key");
                t = Zn(new Uint8Array([
                    0
                ]), o, t);
            } else t = Zn(this.pubKey, t);
            const n = Ao(Io, this.chainCode, t), a = Rc(n.slice(0, 32)), i = n.slice(32);
            if (!Rr.utils.isValidPrivateKey(a)) throw new Error("Tweak bigger than curve order");
            const s = {
                versions: this.versions,
                chainCode: i,
                depth: this.depth + 1,
                parentFingerprint: this.fingerprint,
                index: e
            };
            try {
                if (this.privateKey) {
                    const o = tr(this.privKey + a, Rr.CURVE.n);
                    if (!Rr.utils.isValidPrivateKey(o)) throw new Error("The tweak was out of range or the resulted private key is invalid");
                    s.privateKey = o;
                } else {
                    const o = Mi.fromHex(this.pubKey).add(Mi.fromPrivateKey(a));
                    if (o.equals(Mi.ZERO)) throw new Error("The tweak was equal to negative P, which made the result key invalid");
                    s.publicKey = o.toRawBytes(!0);
                }
                return new vn(s);
            } catch  {
                return this.deriveChild(e + 1);
            }
        }
        sign(e) {
            if (!this.privateKey) throw new Error("No privateKey set!");
            return yn(e, 32), Rr.sign(e, this.privKey).toCompactRawBytes();
        }
        verify(e, t) {
            if (yn(e, 32), yn(t, 64), !this.publicKey) throw new Error("No publicKey set!");
            let n;
            try {
                n = Rr.Signature.fromCompact(t);
            } catch  {
                return !1;
            }
            return Rr.verify(n, e, this.publicKey);
        }
        wipePrivateData() {
            return this.privKey = void 0, this.privKeyBytes && (this.privKeyBytes.fill(0), this.privKeyBytes = void 0), this;
        }
        toJSON() {
            return {
                xpriv: this.privateExtendedKey,
                xpub: this.publicExtendedKey
            };
        }
        serialize(e, t) {
            if (!this.chainCode) throw new Error("No chainCode set");
            return yn(t, 33), Zn(Ri(e), new Uint8Array([
                this.depth
            ]), Ri(this.parentFingerprint), Ri(this.index), this.chainCode, t);
        }
    }
    var rs = {}, Tt = {}, ns, Tc;
    function Mn() {
        if (Tc) return ns;
        Tc = 1, ns = r;
        function r(e, t) {
            if (!e) throw new Error(t || "Assertion failed");
        }
        return r.equal = function(t, n, a) {
            if (t != n) throw new Error(a || "Assertion failed: " + t + " != " + n);
        }, ns;
    }
    var Pc;
    function Ur() {
        if (Pc) return Tt;
        Pc = 1;
        var r = Mn(), e = ma();
        Tt.inherits = e;
        function t(d, l) {
            return (d.charCodeAt(l) & 64512) !== 55296 || l < 0 || l + 1 >= d.length ? !1 : (d.charCodeAt(l + 1) & 64512) === 56320;
        }
        function n(d, l) {
            if (Array.isArray(d)) return d.slice();
            if (!d) return [];
            var b = [];
            if (typeof d == "string") if (l) {
                if (l === "hex") for(d = d.replace(/[^a-z0-9]+/ig, ""), d.length % 2 !== 0 && (d = "0" + d), _ = 0; _ < d.length; _ += 2)b.push(parseInt(d[_] + d[_ + 1], 16));
            } else for(var m = 0, _ = 0; _ < d.length; _++){
                var B = d.charCodeAt(_);
                B < 128 ? b[m++] = B : B < 2048 ? (b[m++] = B >> 6 | 192, b[m++] = B & 63 | 128) : t(d, _) ? (B = 65536 + ((B & 1023) << 10) + (d.charCodeAt(++_) & 1023), b[m++] = B >> 18 | 240, b[m++] = B >> 12 & 63 | 128, b[m++] = B >> 6 & 63 | 128, b[m++] = B & 63 | 128) : (b[m++] = B >> 12 | 224, b[m++] = B >> 6 & 63 | 128, b[m++] = B & 63 | 128);
            }
            else for(_ = 0; _ < d.length; _++)b[_] = d[_] | 0;
            return b;
        }
        Tt.toArray = n;
        function a(d) {
            for(var l = "", b = 0; b < d.length; b++)l += o(d[b].toString(16));
            return l;
        }
        Tt.toHex = a;
        function i(d) {
            var l = d >>> 24 | d >>> 8 & 65280 | d << 8 & 16711680 | (d & 255) << 24;
            return l >>> 0;
        }
        Tt.htonl = i;
        function s(d, l) {
            for(var b = "", m = 0; m < d.length; m++){
                var _ = d[m];
                l === "little" && (_ = i(_)), b += f(_.toString(16));
            }
            return b;
        }
        Tt.toHex32 = s;
        function o(d) {
            return d.length === 1 ? "0" + d : d;
        }
        Tt.zero2 = o;
        function f(d) {
            return d.length === 7 ? "0" + d : d.length === 6 ? "00" + d : d.length === 5 ? "000" + d : d.length === 4 ? "0000" + d : d.length === 3 ? "00000" + d : d.length === 2 ? "000000" + d : d.length === 1 ? "0000000" + d : d;
        }
        Tt.zero8 = f;
        function c(d, l, b, m) {
            var _ = b - l;
            r(_ % 4 === 0);
            for(var B = new Array(_ / 4), T = 0, R = l; T < B.length; T++, R += 4){
                var u;
                m === "big" ? u = d[R] << 24 | d[R + 1] << 16 | d[R + 2] << 8 | d[R + 3] : u = d[R + 3] << 24 | d[R + 2] << 16 | d[R + 1] << 8 | d[R], B[T] = u >>> 0;
            }
            return B;
        }
        Tt.join32 = c;
        function h(d, l) {
            for(var b = new Array(d.length * 4), m = 0, _ = 0; m < d.length; m++, _ += 4){
                var B = d[m];
                l === "big" ? (b[_] = B >>> 24, b[_ + 1] = B >>> 16 & 255, b[_ + 2] = B >>> 8 & 255, b[_ + 3] = B & 255) : (b[_ + 3] = B >>> 24, b[_ + 2] = B >>> 16 & 255, b[_ + 1] = B >>> 8 & 255, b[_] = B & 255);
            }
            return b;
        }
        Tt.split32 = h;
        function g(d, l) {
            return d >>> l | d << 32 - l;
        }
        Tt.rotr32 = g;
        function v(d, l) {
            return d << l | d >>> 32 - l;
        }
        Tt.rotl32 = v;
        function w(d, l) {
            return d + l >>> 0;
        }
        Tt.sum32 = w;
        function E(d, l, b) {
            return d + l + b >>> 0;
        }
        Tt.sum32_3 = E;
        function x(d, l, b, m) {
            return d + l + b + m >>> 0;
        }
        Tt.sum32_4 = x;
        function S(d, l, b, m, _) {
            return d + l + b + m + _ >>> 0;
        }
        Tt.sum32_5 = S;
        function y(d, l, b, m) {
            var _ = d[l], B = d[l + 1], T = m + B >>> 0, R = (T < m ? 1 : 0) + b + _;
            d[l] = R >>> 0, d[l + 1] = T;
        }
        Tt.sum64 = y;
        function A(d, l, b, m) {
            var _ = l + m >>> 0, B = (_ < l ? 1 : 0) + d + b;
            return B >>> 0;
        }
        Tt.sum64_hi = A;
        function P(d, l, b, m) {
            var _ = l + m;
            return _ >>> 0;
        }
        Tt.sum64_lo = P;
        function N(d, l, b, m, _, B, T, R) {
            var u = 0, I = l;
            I = I + m >>> 0, u += I < l ? 1 : 0, I = I + B >>> 0, u += I < B ? 1 : 0, I = I + R >>> 0, u += I < R ? 1 : 0;
            var G = d + b + _ + T + u;
            return G >>> 0;
        }
        Tt.sum64_4_hi = N;
        function k(d, l, b, m, _, B, T, R) {
            var u = l + m + B + R;
            return u >>> 0;
        }
        Tt.sum64_4_lo = k;
        function D(d, l, b, m, _, B, T, R, u, I) {
            var G = 0, $ = l;
            $ = $ + m >>> 0, G += $ < l ? 1 : 0, $ = $ + B >>> 0, G += $ < B ? 1 : 0, $ = $ + R >>> 0, G += $ < R ? 1 : 0, $ = $ + I >>> 0, G += $ < I ? 1 : 0;
            var te = d + b + _ + T + u + G;
            return te >>> 0;
        }
        Tt.sum64_5_hi = D;
        function V(d, l, b, m, _, B, T, R, u, I) {
            var G = l + m + B + R + I;
            return G >>> 0;
        }
        Tt.sum64_5_lo = V;
        function K(d, l, b) {
            var m = l << 32 - b | d >>> b;
            return m >>> 0;
        }
        Tt.rotr64_hi = K;
        function j(d, l, b) {
            var m = d << 32 - b | l >>> b;
            return m >>> 0;
        }
        Tt.rotr64_lo = j;
        function H(d, l, b) {
            return d >>> b;
        }
        Tt.shr64_hi = H;
        function O(d, l, b) {
            var m = d << 32 - b | l >>> b;
            return m >>> 0;
        }
        return Tt.shr64_lo = O, Tt;
    }
    var is = {}, Bc;
    function yi() {
        if (Bc) return is;
        Bc = 1;
        var r = Ur(), e = Mn();
        function t() {
            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;
        }
        return is.BlockHash = t, t.prototype.update = function(a, i) {
            if (a = r.toArray(a, i), this.pending ? this.pending = this.pending.concat(a) : this.pending = a, this.pendingTotal += a.length, this.pending.length >= this._delta8) {
                a = this.pending;
                var s = a.length % this._delta8;
                this.pending = a.slice(a.length - s, a.length), this.pending.length === 0 && (this.pending = null), a = r.join32(a, 0, a.length - s, this.endian);
                for(var o = 0; o < a.length; o += this._delta32)this._update(a, o, o + this._delta32);
            }
            return this;
        }, t.prototype.digest = function(a) {
            return this.update(this._pad()), e(this.pending === null), this._digest(a);
        }, t.prototype._pad = function() {
            var a = this.pendingTotal, i = this._delta8, s = i - (a + this.padLength) % i, o = new Array(s + this.padLength);
            o[0] = 128;
            for(var f = 1; f < s; f++)o[f] = 0;
            if (a <<= 3, this.endian === "big") {
                for(var c = 8; c < this.padLength; c++)o[f++] = 0;
                o[f++] = 0, o[f++] = 0, o[f++] = 0, o[f++] = 0, o[f++] = a >>> 24 & 255, o[f++] = a >>> 16 & 255, o[f++] = a >>> 8 & 255, o[f++] = a & 255;
            } else for(o[f++] = a & 255, o[f++] = a >>> 8 & 255, o[f++] = a >>> 16 & 255, o[f++] = a >>> 24 & 255, o[f++] = 0, o[f++] = 0, o[f++] = 0, o[f++] = 0, c = 8; c < this.padLength; c++)o[f++] = 0;
            return o;
        }, is;
    }
    var hn = {}, Ar = {}, Oc;
    function au() {
        if (Oc) return Ar;
        Oc = 1;
        var r = Ur(), e = r.rotr32;
        function t(h, g, v, w) {
            if (h === 0) return n(g, v, w);
            if (h === 1 || h === 3) return i(g, v, w);
            if (h === 2) return a(g, v, w);
        }
        Ar.ft_1 = t;
        function n(h, g, v) {
            return h & g ^ ~h & v;
        }
        Ar.ch32 = n;
        function a(h, g, v) {
            return h & g ^ h & v ^ g & v;
        }
        Ar.maj32 = a;
        function i(h, g, v) {
            return h ^ g ^ v;
        }
        Ar.p32 = i;
        function s(h) {
            return e(h, 2) ^ e(h, 13) ^ e(h, 22);
        }
        Ar.s0_256 = s;
        function o(h) {
            return e(h, 6) ^ e(h, 11) ^ e(h, 25);
        }
        Ar.s1_256 = o;
        function f(h) {
            return e(h, 7) ^ e(h, 18) ^ h >>> 3;
        }
        Ar.g0_256 = f;
        function c(h) {
            return e(h, 17) ^ e(h, 19) ^ h >>> 10;
        }
        return Ar.g1_256 = c, Ar;
    }
    var as, kc;
    function Bb() {
        if (kc) return as;
        kc = 1;
        var r = Ur(), e = yi(), t = au(), n = r.rotl32, a = r.sum32, i = r.sum32_5, s = t.ft_1, o = e.BlockHash, f = [
            1518500249,
            1859775393,
            2400959708,
            3395469782
        ];
        function c() {
            if (!(this instanceof c)) return new c;
            o.call(this), this.h = [
                1732584193,
                4023233417,
                2562383102,
                271733878,
                3285377520
            ], this.W = new Array(80);
        }
        return r.inherits(c, o), as = c, c.blockSize = 512, c.outSize = 160, c.hmacStrength = 80, c.padLength = 64, c.prototype._update = function(g, v) {
            for(var w = this.W, E = 0; E < 16; E++)w[E] = g[v + E];
            for(; E < w.length; E++)w[E] = n(w[E - 3] ^ w[E - 8] ^ w[E - 14] ^ w[E - 16], 1);
            var x = this.h[0], S = this.h[1], y = this.h[2], A = this.h[3], P = this.h[4];
            for(E = 0; E < w.length; E++){
                var N = ~~(E / 20), k = i(n(x, 5), s(N, S, y, A), P, w[E], f[N]);
                P = A, A = y, y = n(S, 30), S = x, x = k;
            }
            this.h[0] = a(this.h[0], x), this.h[1] = a(this.h[1], S), this.h[2] = a(this.h[2], y), this.h[3] = a(this.h[3], A), this.h[4] = a(this.h[4], P);
        }, c.prototype._digest = function(g) {
            return g === "hex" ? r.toHex32(this.h, "big") : r.split32(this.h, "big");
        }, as;
    }
    var ss, Nc;
    function su() {
        if (Nc) return ss;
        Nc = 1;
        var r = Ur(), e = yi(), t = au(), n = Mn(), a = r.sum32, i = r.sum32_4, s = r.sum32_5, o = t.ch32, f = t.maj32, c = t.s0_256, h = t.s1_256, g = t.g0_256, v = t.g1_256, w = e.BlockHash, E = [
            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
        ];
        function x() {
            if (!(this instanceof x)) return new x;
            w.call(this), this.h = [
                1779033703,
                3144134277,
                1013904242,
                2773480762,
                1359893119,
                2600822924,
                528734635,
                1541459225
            ], this.k = E, this.W = new Array(64);
        }
        return r.inherits(x, w), ss = x, x.blockSize = 512, x.outSize = 256, x.hmacStrength = 192, x.padLength = 64, x.prototype._update = function(y, A) {
            for(var P = this.W, N = 0; N < 16; N++)P[N] = y[A + N];
            for(; N < P.length; N++)P[N] = i(v(P[N - 2]), P[N - 7], g(P[N - 15]), P[N - 16]);
            var k = this.h[0], D = this.h[1], V = this.h[2], K = this.h[3], j = this.h[4], H = this.h[5], O = this.h[6], d = this.h[7];
            for(n(this.k.length === P.length), N = 0; N < P.length; N++){
                var l = s(d, h(j), o(j, H, O), this.k[N], P[N]), b = a(c(k), f(k, D, V));
                d = O, O = H, H = j, j = a(K, l), K = V, V = D, D = k, k = a(l, b);
            }
            this.h[0] = a(this.h[0], k), this.h[1] = a(this.h[1], D), this.h[2] = a(this.h[2], V), this.h[3] = a(this.h[3], K), this.h[4] = a(this.h[4], j), this.h[5] = a(this.h[5], H), this.h[6] = a(this.h[6], O), this.h[7] = a(this.h[7], d);
        }, x.prototype._digest = function(y) {
            return y === "hex" ? r.toHex32(this.h, "big") : r.split32(this.h, "big");
        }, ss;
    }
    var os, Cc;
    function Ob() {
        if (Cc) return os;
        Cc = 1;
        var r = Ur(), e = su();
        function t() {
            if (!(this instanceof t)) return new t;
            e.call(this), this.h = [
                3238371032,
                914150663,
                812702999,
                4144912697,
                4290775857,
                1750603025,
                1694076839,
                3204075428
            ];
        }
        return r.inherits(t, e), os = t, t.blockSize = 512, t.outSize = 224, t.hmacStrength = 192, t.padLength = 64, t.prototype._digest = function(a) {
            return a === "hex" ? r.toHex32(this.h.slice(0, 7), "big") : r.split32(this.h.slice(0, 7), "big");
        }, os;
    }
    var fs, Lc;
    function ou() {
        if (Lc) return fs;
        Lc = 1;
        var r = Ur(), e = yi(), t = Mn(), n = r.rotr64_hi, a = r.rotr64_lo, i = r.shr64_hi, s = r.shr64_lo, o = r.sum64, f = r.sum64_hi, c = r.sum64_lo, h = r.sum64_4_hi, g = r.sum64_4_lo, v = r.sum64_5_hi, w = r.sum64_5_lo, E = e.BlockHash, x = [
            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
        ];
        function S() {
            if (!(this instanceof S)) return new S;
            E.call(this), this.h = [
                1779033703,
                4089235720,
                3144134277,
                2227873595,
                1013904242,
                4271175723,
                2773480762,
                1595750129,
                1359893119,
                2917565137,
                2600822924,
                725511199,
                528734635,
                4215389547,
                1541459225,
                327033209
            ], this.k = x, this.W = new Array(160);
        }
        r.inherits(S, E), fs = S, S.blockSize = 1024, S.outSize = 512, S.hmacStrength = 192, S.padLength = 128, S.prototype._prepareBlock = function(b, m) {
            for(var _ = this.W, B = 0; B < 32; B++)_[B] = b[m + B];
            for(; B < _.length; B += 2){
                var T = O(_[B - 4], _[B - 3]), R = d(_[B - 4], _[B - 3]), u = _[B - 14], I = _[B - 13], G = j(_[B - 30], _[B - 29]), $ = H(_[B - 30], _[B - 29]), te = _[B - 32], Z = _[B - 31];
                _[B] = h(T, R, u, I, G, $, te, Z), _[B + 1] = g(T, R, u, I, G, $, te, Z);
            }
        }, S.prototype._update = function(b, m) {
            this._prepareBlock(b, m);
            var _ = this.W, B = this.h[0], T = this.h[1], R = this.h[2], u = this.h[3], I = this.h[4], G = this.h[5], $ = this.h[6], te = this.h[7], Z = this.h[8], fe = this.h[9], pe = this.h[10], ee = this.h[11], J = this.h[12], oe = this.h[13], Me = this.h[14], xe = this.h[15];
            t(this.k.length === _.length);
            for(var z = 0; z < _.length; z += 2){
                var X = Me, re = xe, ge = V(Z, fe), Se = K(Z, fe), ye = y(Z, fe, pe, ee, J), Y = A(Z, fe, pe, ee, J, oe), le = this.k[z], be = this.k[z + 1], se = _[z], De = _[z + 1], ze = v(X, re, ge, Se, ye, Y, le, be, se, De), $e = w(X, re, ge, Se, ye, Y, le, be, se, De);
                X = k(B, T), re = D(B, T), ge = P(B, T, R, u, I), Se = N(B, T, R, u, I, G);
                var Ze = f(X, re, ge, Se), je = c(X, re, ge, Se);
                Me = J, xe = oe, J = pe, oe = ee, pe = Z, ee = fe, Z = f($, te, ze, $e), fe = c(te, te, ze, $e), $ = I, te = G, I = R, G = u, R = B, u = T, B = f(ze, $e, Ze, je), T = c(ze, $e, Ze, je);
            }
            o(this.h, 0, B, T), o(this.h, 2, R, u), o(this.h, 4, I, G), o(this.h, 6, $, te), o(this.h, 8, Z, fe), o(this.h, 10, pe, ee), o(this.h, 12, J, oe), o(this.h, 14, Me, xe);
        }, S.prototype._digest = function(b) {
            return b === "hex" ? r.toHex32(this.h, "big") : r.split32(this.h, "big");
        };
        function y(l, b, m, _, B) {
            var T = l & m ^ ~l & B;
            return T < 0 && (T += 4294967296), T;
        }
        function A(l, b, m, _, B, T) {
            var R = b & _ ^ ~b & T;
            return R < 0 && (R += 4294967296), R;
        }
        function P(l, b, m, _, B) {
            var T = l & m ^ l & B ^ m & B;
            return T < 0 && (T += 4294967296), T;
        }
        function N(l, b, m, _, B, T) {
            var R = b & _ ^ b & T ^ _ & T;
            return R < 0 && (R += 4294967296), R;
        }
        function k(l, b) {
            var m = n(l, b, 28), _ = n(b, l, 2), B = n(b, l, 7), T = m ^ _ ^ B;
            return T < 0 && (T += 4294967296), T;
        }
        function D(l, b) {
            var m = a(l, b, 28), _ = a(b, l, 2), B = a(b, l, 7), T = m ^ _ ^ B;
            return T < 0 && (T += 4294967296), T;
        }
        function V(l, b) {
            var m = n(l, b, 14), _ = n(l, b, 18), B = n(b, l, 9), T = m ^ _ ^ B;
            return T < 0 && (T += 4294967296), T;
        }
        function K(l, b) {
            var m = a(l, b, 14), _ = a(l, b, 18), B = a(b, l, 9), T = m ^ _ ^ B;
            return T < 0 && (T += 4294967296), T;
        }
        function j(l, b) {
            var m = n(l, b, 1), _ = n(l, b, 8), B = i(l, b, 7), T = m ^ _ ^ B;
            return T < 0 && (T += 4294967296), T;
        }
        function H(l, b) {
            var m = a(l, b, 1), _ = a(l, b, 8), B = s(l, b, 7), T = m ^ _ ^ B;
            return T < 0 && (T += 4294967296), T;
        }
        function O(l, b) {
            var m = n(l, b, 19), _ = n(b, l, 29), B = i(l, b, 6), T = m ^ _ ^ B;
            return T < 0 && (T += 4294967296), T;
        }
        function d(l, b) {
            var m = a(l, b, 19), _ = a(b, l, 29), B = s(l, b, 6), T = m ^ _ ^ B;
            return T < 0 && (T += 4294967296), T;
        }
        return fs;
    }
    var cs, Uc;
    function kb() {
        if (Uc) return cs;
        Uc = 1;
        var r = Ur(), e = ou();
        function t() {
            if (!(this instanceof t)) return new t;
            e.call(this), this.h = [
                3418070365,
                3238371032,
                1654270250,
                914150663,
                2438529370,
                812702999,
                355462360,
                4144912697,
                1731405415,
                4290775857,
                2394180231,
                1750603025,
                3675008525,
                1694076839,
                1203062813,
                3204075428
            ];
        }
        return r.inherits(t, e), cs = t, t.blockSize = 1024, t.outSize = 384, t.hmacStrength = 192, t.padLength = 128, t.prototype._digest = function(a) {
            return a === "hex" ? r.toHex32(this.h.slice(0, 12), "big") : r.split32(this.h.slice(0, 12), "big");
        }, cs;
    }
    var qc;
    function Nb() {
        return qc || (qc = 1, hn.sha1 = Bb(), hn.sha224 = Ob(), hn.sha256 = su(), hn.sha384 = kb(), hn.sha512 = ou()), hn;
    }
    var ds = {}, Dc;
    function Cb() {
        if (Dc) return ds;
        Dc = 1;
        var r = Ur(), e = yi(), t = r.rotl32, n = r.sum32, a = r.sum32_3, i = r.sum32_4, s = e.BlockHash;
        function o() {
            if (!(this instanceof o)) return new o;
            s.call(this), this.h = [
                1732584193,
                4023233417,
                2562383102,
                271733878,
                3285377520
            ], this.endian = "little";
        }
        r.inherits(o, s), ds.ripemd160 = o, o.blockSize = 512, o.outSize = 160, o.hmacStrength = 192, o.padLength = 64, o.prototype._update = function(S, y) {
            for(var A = this.h[0], P = this.h[1], N = this.h[2], k = this.h[3], D = this.h[4], V = A, K = P, j = N, H = k, O = D, d = 0; d < 80; d++){
                var l = n(t(i(A, f(d, P, N, k), S[g[d] + y], c(d)), w[d]), D);
                A = D, D = k, k = t(N, 10), N = P, P = l, l = n(t(i(V, f(79 - d, K, j, H), S[v[d] + y], h(d)), E[d]), O), V = O, O = H, H = t(j, 10), j = K, K = l;
            }
            l = a(this.h[1], N, H), this.h[1] = a(this.h[2], k, O), this.h[2] = a(this.h[3], D, V), this.h[3] = a(this.h[4], A, K), this.h[4] = a(this.h[0], P, j), this.h[0] = l;
        }, o.prototype._digest = function(S) {
            return S === "hex" ? r.toHex32(this.h, "little") : r.split32(this.h, "little");
        };
        function f(x, S, y, A) {
            return x <= 15 ? S ^ y ^ A : x <= 31 ? S & y | ~S & A : x <= 47 ? (S | ~y) ^ A : x <= 63 ? S & A | y & ~A : S ^ (y | ~A);
        }
        function c(x) {
            return x <= 15 ? 0 : x <= 31 ? 1518500249 : x <= 47 ? 1859775393 : x <= 63 ? 2400959708 : 2840853838;
        }
        function h(x) {
            return x <= 15 ? 1352829926 : x <= 31 ? 1548603684 : x <= 47 ? 1836072691 : x <= 63 ? 2053994217 : 0;
        }
        var g = [
            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
        ], v = [
            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 = [
            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
        ], E = [
            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
        ];
        return ds;
    }
    var us, Fc;
    function Lb() {
        if (Fc) return us;
        Fc = 1;
        var r = Ur(), e = Mn();
        function t(n, a, i) {
            if (!(this instanceof t)) return new t(n, a, i);
            this.Hash = n, this.blockSize = n.blockSize / 8, this.outSize = n.outSize / 8, this.inner = null, this.outer = null, this._init(r.toArray(a, i));
        }
        return us = t, t.prototype._init = function(a) {
            a.length > this.blockSize && (a = new this.Hash().update(a).digest()), e(a.length <= this.blockSize);
            for(var i = a.length; i < this.blockSize; i++)a.push(0);
            for(i = 0; i < a.length; i++)a[i] ^= 54;
            for(this.inner = new this.Hash().update(a), i = 0; i < a.length; i++)a[i] ^= 106;
            this.outer = new this.Hash().update(a);
        }, t.prototype.update = function(a, i) {
            return this.inner.update(a, i), this;
        }, t.prototype.digest = function(a) {
            return this.outer.update(this.inner.digest()), this.outer.digest(a);
        }, us;
    }
    var $c;
    function _a() {
        return $c || ($c = 1, (function(r) {
            var e = r;
            e.utils = Ur(), e.common = yi(), e.sha = Nb(), e.ripemd = Cb(), e.hmac = Lb(), e.sha1 = e.sha.sha1, e.sha256 = e.sha.sha256, e.sha224 = e.sha.sha224, e.sha384 = e.sha.sha384, e.sha512 = e.sha.sha512, e.ripemd160 = e.ripemd.ripemd160;
        })(rs)), rs;
    }
    var Ub = _a();
    const fu = Lr(Ub);
    var qb = Ih();
    const ia = Lr(qb);
    var ls = {};
    const Db = "6.6.1", Fb = {
        version: Db
    };
    var hs = {}, Yi = {
        exports: {}
    }, $b = Yi.exports, Kc;
    function Yr() {
        return Kc || (Kc = 1, (function(r) {
            (function(e, t) {
                function n(O, d) {
                    if (!O) throw new Error(d || "Assertion failed");
                }
                function a(O, d) {
                    O.super_ = d;
                    var l = function() {};
                    l.prototype = d.prototype, O.prototype = new l, O.prototype.constructor = O;
                }
                function i(O, d, l) {
                    if (i.isBN(O)) return O;
                    this.negative = 0, this.words = null, this.length = 0, this.red = null, O !== null && ((d === "le" || d === "be") && (l = d, d = 10), this._init(O || 0, d || 10, l || "be"));
                }
                typeof e == "object" ? e.exports = i : t.BN = i, i.BN = i, i.wordSize = 26;
                var s;
                try {
                    typeof window < "u" && typeof window.Buffer < "u" ? s = window.Buffer : s = Wr().Buffer;
                } catch  {}
                i.isBN = function(d) {
                    return d instanceof i ? !0 : d !== null && typeof d == "object" && d.constructor.wordSize === i.wordSize && Array.isArray(d.words);
                }, i.max = function(d, l) {
                    return d.cmp(l) > 0 ? d : l;
                }, i.min = function(d, l) {
                    return d.cmp(l) < 0 ? d : l;
                }, i.prototype._init = function(d, l, b) {
                    if (typeof d == "number") return this._initNumber(d, l, b);
                    if (typeof d == "object") return this._initArray(d, l, b);
                    l === "hex" && (l = 16), n(l === (l | 0) && l >= 2 && l <= 36), d = d.toString().replace(/\s+/g, "");
                    var m = 0;
                    d[0] === "-" && (m++, this.negative = 1), m < d.length && (l === 16 ? this._parseHex(d, m, b) : (this._parseBase(d, l, m), b === "le" && this._initArray(this.toArray(), l, b)));
                }, i.prototype._initNumber = function(d, l, b) {
                    d < 0 && (this.negative = 1, d = -d), d < 67108864 ? (this.words = [
                        d & 67108863
                    ], this.length = 1) : d < 4503599627370496 ? (this.words = [
                        d & 67108863,
                        d / 67108864 & 67108863
                    ], this.length = 2) : (n(d < 9007199254740992), this.words = [
                        d & 67108863,
                        d / 67108864 & 67108863,
                        1
                    ], this.length = 3), b === "le" && this._initArray(this.toArray(), l, b);
                }, i.prototype._initArray = function(d, l, b) {
                    if (n(typeof d.length == "number"), d.length <= 0) return this.words = [
                        0
                    ], this.length = 1, this;
                    this.length = Math.ceil(d.length / 3), this.words = new Array(this.length);
                    for(var m = 0; m < this.length; m++)this.words[m] = 0;
                    var _, B, T = 0;
                    if (b === "be") for(m = d.length - 1, _ = 0; m >= 0; m -= 3)B = d[m] | d[m - 1] << 8 | d[m - 2] << 16, this.words[_] |= B << T & 67108863, this.words[_ + 1] = B >>> 26 - T & 67108863, T += 24, T >= 26 && (T -= 26, _++);
                    else if (b === "le") for(m = 0, _ = 0; m < d.length; m += 3)B = d[m] | d[m + 1] << 8 | d[m + 2] << 16, this.words[_] |= B << T & 67108863, this.words[_ + 1] = B >>> 26 - T & 67108863, T += 24, T >= 26 && (T -= 26, _++);
                    return this.strip();
                };
                function o(O, d) {
                    var l = O.charCodeAt(d);
                    return l >= 65 && l <= 70 ? l - 55 : l >= 97 && l <= 102 ? l - 87 : l - 48 & 15;
                }
                function f(O, d, l) {
                    var b = o(O, l);
                    return l - 1 >= d && (b |= o(O, l - 1) << 4), b;
                }
                i.prototype._parseHex = function(d, l, b) {
                    this.length = Math.ceil((d.length - l) / 6), this.words = new Array(this.length);
                    for(var m = 0; m < this.length; m++)this.words[m] = 0;
                    var _ = 0, B = 0, T;
                    if (b === "be") for(m = d.length - 1; m >= l; m -= 2)T = f(d, l, m) << _, this.words[B] |= T & 67108863, _ >= 18 ? (_ -= 18, B += 1, this.words[B] |= T >>> 26) : _ += 8;
                    else {
                        var R = d.length - l;
                        for(m = R % 2 === 0 ? l + 1 : l; m < d.length; m += 2)T = f(d, l, m) << _, this.words[B] |= T & 67108863, _ >= 18 ? (_ -= 18, B += 1, this.words[B] |= T >>> 26) : _ += 8;
                    }
                    this.strip();
                };
                function c(O, d, l, b) {
                    for(var m = 0, _ = Math.min(O.length, l), B = d; B < _; B++){
                        var T = O.charCodeAt(B) - 48;
                        m *= b, T >= 49 ? m += T - 49 + 10 : T >= 17 ? m += T - 17 + 10 : m += T;
                    }
                    return m;
                }
                i.prototype._parseBase = function(d, l, b) {
                    this.words = [
                        0
                    ], this.length = 1;
                    for(var m = 0, _ = 1; _ <= 67108863; _ *= l)m++;
                    m--, _ = _ / l | 0;
                    for(var B = d.length - b, T = B % m, R = Math.min(B, B - T) + b, u = 0, I = b; I < R; I += m)u = c(d, I, I + m, l), this.imuln(_), this.words[0] + u < 67108864 ? this.words[0] += u : this._iaddn(u);
                    if (T !== 0) {
                        var G = 1;
                        for(u = c(d, I, d.length, l), I = 0; I < T; I++)G *= l;
                        this.imuln(G), this.words[0] + u < 67108864 ? this.words[0] += u : this._iaddn(u);
                    }
                    this.strip();
                }, i.prototype.copy = function(d) {
                    d.words = new Array(this.length);
                    for(var l = 0; l < this.length; l++)d.words[l] = this.words[l];
                    d.length = this.length, d.negative = this.negative, d.red = this.red;
                }, i.prototype.clone = function() {
                    var d = new i(null);
                    return this.copy(d), d;
                }, i.prototype._expand = function(d) {
                    for(; this.length < d;)this.words[this.length++] = 0;
                    return this;
                }, i.prototype.strip = function() {
                    for(; this.length > 1 && this.words[this.length - 1] === 0;)this.length--;
                    return this._normSign();
                }, i.prototype._normSign = function() {
                    return this.length === 1 && this.words[0] === 0 && (this.negative = 0), this;
                }, i.prototype.inspect = function() {
                    return (this.red ? "<BN-R: " : "<BN: ") + this.toString(16) + ">";
                };
                var h = [
                    "",
                    "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"
                ], g = [
                    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
                ], v = [
                    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
                ];
                i.prototype.toString = function(d, l) {
                    d = d || 10, l = l | 0 || 1;
                    var b;
                    if (d === 16 || d === "hex") {
                        b = "";
                        for(var m = 0, _ = 0, B = 0; B < this.length; B++){
                            var T = this.words[B], R = ((T << m | _) & 16777215).toString(16);
                            _ = T >>> 24 - m & 16777215, m += 2, m >= 26 && (m -= 26, B--), _ !== 0 || B !== this.length - 1 ? b = h[6 - R.length] + R + b : b = R + b;
                        }
                        for(_ !== 0 && (b = _.toString(16) + b); b.length % l !== 0;)b = "0" + b;
                        return this.negative !== 0 && (b = "-" + b), b;
                    }
                    if (d === (d | 0) && d >= 2 && d <= 36) {
                        var u = g[d], I = v[d];
                        b = "";
                        var G = this.clone();
                        for(G.negative = 0; !G.isZero();){
                            var $ = G.modn(I).toString(d);
                            G = G.idivn(I), G.isZero() ? b = $ + b : b = h[u - $.length] + $ + b;
                        }
                        for(this.isZero() && (b = "0" + b); b.length % l !== 0;)b = "0" + b;
                        return this.negative !== 0 && (b = "-" + b), b;
                    }
                    n(!1, "Base should be between 2 and 36");
                }, i.prototype.toNumber = function() {
                    var d = this.words[0];
                    return this.length === 2 ? d += this.words[1] * 67108864 : this.length === 3 && this.words[2] === 1 ? d += 4503599627370496 + this.words[1] * 67108864 : this.length > 2 && n(!1, "Number can only safely store up to 53 bits"), this.negative !== 0 ? -d : d;
                }, i.prototype.toJSON = function() {
                    return this.toString(16);
                }, i.prototype.toBuffer = function(d, l) {
                    return n(typeof s < "u"), this.toArrayLike(s, d, l);
                }, i.prototype.toArray = function(d, l) {
                    return this.toArrayLike(Array, d, l);
                }, i.prototype.toArrayLike = function(d, l, b) {
                    var m = this.byteLength(), _ = b || Math.max(1, m);
                    n(m <= _, "byte array longer than desired length"), n(_ > 0, "Requested array length <= 0"), this.strip();
                    var B = l === "le", T = new d(_), R, u, I = this.clone();
                    if (B) {
                        for(u = 0; !I.isZero(); u++)R = I.andln(255), I.iushrn(8), T[u] = R;
                        for(; u < _; u++)T[u] = 0;
                    } else {
                        for(u = 0; u < _ - m; u++)T[u] = 0;
                        for(u = 0; !I.isZero(); u++)R = I.andln(255), I.iushrn(8), T[_ - u - 1] = R;
                    }
                    return T;
                }, Math.clz32 ? i.prototype._countBits = function(d) {
                    return 32 - Math.clz32(d);
                } : i.prototype._countBits = function(d) {
                    var l = d, b = 0;
                    return l >= 4096 && (b += 13, l >>>= 13), l >= 64 && (b += 7, l >>>= 7), l >= 8 && (b += 4, l >>>= 4), l >= 2 && (b += 2, l >>>= 2), b + l;
                }, i.prototype._zeroBits = function(d) {
                    if (d === 0) return 26;
                    var l = d, b = 0;
                    return (l & 8191) === 0 && (b += 13, l >>>= 13), (l & 127) === 0 && (b += 7, l >>>= 7), (l & 15) === 0 && (b += 4, l >>>= 4), (l & 3) === 0 && (b += 2, l >>>= 2), (l & 1) === 0 && b++, b;
                }, i.prototype.bitLength = function() {
                    var d = this.words[this.length - 1], l = this._countBits(d);
                    return (this.length - 1) * 26 + l;
                };
                function w(O) {
                    for(var d = new Array(O.bitLength()), l = 0; l < d.length; l++){
                        var b = l / 26 | 0, m = l % 26;
                        d[l] = (O.words[b] & 1 << m) >>> m;
                    }
                    return d;
                }
                i.prototype.zeroBits = function() {
                    if (this.isZero()) return 0;
                    for(var d = 0, l = 0; l < this.length; l++){
                        var b = this._zeroBits(this.words[l]);
                        if (d += b, b !== 26) break;
                    }
                    return d;
                }, i.prototype.byteLength = function() {
                    return Math.ceil(this.bitLength() / 8);
                }, i.prototype.toTwos = function(d) {
                    return this.negative !== 0 ? this.abs().inotn(d).iaddn(1) : this.clone();
                }, i.prototype.fromTwos = function(d) {
                    return this.testn(d - 1) ? this.notn(d).iaddn(1).ineg() : this.clone();
                }, i.prototype.isNeg = function() {
                    return this.negative !== 0;
                }, i.prototype.neg = function() {
                    return this.clone().ineg();
                }, i.prototype.ineg = function() {
                    return this.isZero() || (this.negative ^= 1), this;
                }, i.prototype.iuor = function(d) {
                    for(; this.length < d.length;)this.words[this.length++] = 0;
                    for(var l = 0; l < d.length; l++)this.words[l] = this.words[l] | d.words[l];
                    return this.strip();
                }, i.prototype.ior = function(d) {
                    return n((this.negative | d.negative) === 0), this.iuor(d);
                }, i.prototype.or = function(d) {
                    return this.length > d.length ? this.clone().ior(d) : d.clone().ior(this);
                }, i.prototype.uor = function(d) {
                    return this.length > d.length ? this.clone().iuor(d) : d.clone().iuor(this);
                }, i.prototype.iuand = function(d) {
                    var l;
                    this.length > d.length ? l = d : l = this;
                    for(var b = 0; b < l.length; b++)this.words[b] = this.words[b] & d.words[b];
                    return this.length = l.length, this.strip();
                }, i.prototype.iand = function(d) {
                    return n((this.negative | d.negative) === 0), this.iuand(d);
                }, i.prototype.and = function(d) {
                    return this.length > d.length ? this.clone().iand(d) : d.clone().iand(this);
                }, i.prototype.uand = function(d) {
                    return this.length > d.length ? this.clone().iuand(d) : d.clone().iuand(this);
                }, i.prototype.iuxor = function(d) {
                    var l, b;
                    this.length > d.length ? (l = this, b = d) : (l = d, b = this);
                    for(var m = 0; m < b.length; m++)this.words[m] = l.words[m] ^ b.words[m];
                    if (this !== l) for(; m < l.length; m++)this.words[m] = l.words[m];
                    return this.length = l.length, this.strip();
                }, i.prototype.ixor = function(d) {
                    return n((this.negative | d.negative) === 0), this.iuxor(d);
                }, i.prototype.xor = function(d) {
                    return this.length > d.length ? this.clone().ixor(d) : d.clone().ixor(this);
                }, i.prototype.uxor = function(d) {
                    return this.length > d.length ? this.clone().iuxor(d) : d.clone().iuxor(this);
                }, i.prototype.inotn = function(d) {
                    n(typeof d == "number" && d >= 0);
                    var l = Math.ceil(d / 26) | 0, b = d % 26;
                    this._expand(l), b > 0 && l--;
                    for(var m = 0; m < l; m++)this.words[m] = ~this.words[m] & 67108863;
                    return b > 0 && (this.words[m] = ~this.words[m] & 67108863 >> 26 - b), this.strip();
                }, i.prototype.notn = function(d) {
                    return this.clone().inotn(d);
                }, i.prototype.setn = function(d, l) {
                    n(typeof d == "number" && d >= 0);
                    var b = d / 26 | 0, m = d % 26;
                    return this._expand(b + 1), l ? this.words[b] = this.words[b] | 1 << m : this.words[b] = this.words[b] & ~(1 << m), this.strip();
                }, i.prototype.iadd = function(d) {
                    var l;
                    if (this.negative !== 0 && d.negative === 0) return this.negative = 0, l = this.isub(d), this.negative ^= 1, this._normSign();
                    if (this.negative === 0 && d.negative !== 0) return d.negative = 0, l = this.isub(d), d.negative = 1, l._normSign();
                    var b, m;
                    this.length > d.length ? (b = this, m = d) : (b = d, m = this);
                    for(var _ = 0, B = 0; B < m.length; B++)l = (b.words[B] | 0) + (m.words[B] | 0) + _, this.words[B] = l & 67108863, _ = l >>> 26;
                    for(; _ !== 0 && B < b.length; B++)l = (b.words[B] | 0) + _, this.words[B] = l & 67108863, _ = l >>> 26;
                    if (this.length = b.length, _ !== 0) this.words[this.length] = _, this.length++;
                    else if (b !== this) for(; B < b.length; B++)this.words[B] = b.words[B];
                    return this;
                }, i.prototype.add = function(d) {
                    var l;
                    return d.negative !== 0 && this.negative === 0 ? (d.negative = 0, l = this.sub(d), d.negative ^= 1, l) : d.negative === 0 && this.negative !== 0 ? (this.negative = 0, l = d.sub(this), this.negative = 1, l) : this.length > d.length ? this.clone().iadd(d) : d.clone().iadd(this);
                }, i.prototype.isub = function(d) {
                    if (d.negative !== 0) {
                        d.negative = 0;
                        var l = this.iadd(d);
                        return d.negative = 1, l._normSign();
                    } else if (this.negative !== 0) return this.negative = 0, this.iadd(d), this.negative = 1, this._normSign();
                    var b = this.cmp(d);
                    if (b === 0) return this.negative = 0, this.length = 1, this.words[0] = 0, this;
                    var m, _;
                    b > 0 ? (m = this, _ = d) : (m = d, _ = this);
                    for(var B = 0, T = 0; T < _.length; T++)l = (m.words[T] | 0) - (_.words[T] | 0) + B, B = l >> 26, this.words[T] = l & 67108863;
                    for(; B !== 0 && T < m.length; T++)l = (m.words[T] | 0) + B, B = l >> 26, this.words[T] = l & 67108863;
                    if (B === 0 && T < m.length && m !== this) for(; T < m.length; T++)this.words[T] = m.words[T];
                    return this.length = Math.max(this.length, T), m !== this && (this.negative = 1), this.strip();
                }, i.prototype.sub = function(d) {
                    return this.clone().isub(d);
                };
                function E(O, d, l) {
                    l.negative = d.negative ^ O.negative;
                    var b = O.length + d.length | 0;
                    l.length = b, b = b - 1 | 0;
                    var m = O.words[0] | 0, _ = d.words[0] | 0, B = m * _, T = B & 67108863, R = B / 67108864 | 0;
                    l.words[0] = T;
                    for(var u = 1; u < b; u++){
                        for(var I = R >>> 26, G = R & 67108863, $ = Math.min(u, d.length - 1), te = Math.max(0, u - O.length + 1); te <= $; te++){
                            var Z = u - te | 0;
                            m = O.words[Z] | 0, _ = d.words[te] | 0, B = m * _ + G, I += B / 67108864 | 0, G = B & 67108863;
                        }
                        l.words[u] = G | 0, R = I | 0;
                    }
                    return R !== 0 ? l.words[u] = R | 0 : l.length--, l.strip();
                }
                var x = function(d, l, b) {
                    var m = d.words, _ = l.words, B = b.words, T = 0, R, u, I, G = m[0] | 0, $ = G & 8191, te = G >>> 13, Z = m[1] | 0, fe = Z & 8191, pe = Z >>> 13, ee = m[2] | 0, J = ee & 8191, oe = ee >>> 13, Me = m[3] | 0, xe = Me & 8191, z = Me >>> 13, X = m[4] | 0, re = X & 8191, ge = X >>> 13, Se = m[5] | 0, ye = Se & 8191, Y = Se >>> 13, le = m[6] | 0, be = le & 8191, se = le >>> 13, De = m[7] | 0, ze = De & 8191, $e = De >>> 13, Ze = m[8] | 0, je = Ze & 8191, Qe = Ze >>> 13, qt = m[9] | 0, bt = qt & 8191, et = qt >>> 13, ne = _[0] | 0, Oe = ne & 8191, We = ne >>> 13, Pt = _[1] | 0, pt = Pt & 8191, St = Pt >>> 13, ar = _[2] | 0, It = ar & 8191, Bt = ar >>> 13, Xr = _[3] | 0, Ot = Xr & 8191, Nt = Xr >>> 13, sr = _[4] | 0, _t = sr & 8191, Et = sr >>> 13, q = _[5] | 0, F = q & 8191, _e = q >>> 13, Re = _[6] | 0, Ae = Re & 8191, ut = Re >>> 13, M = _[7] | 0, L = M & 8191, C = M >>> 13, p = _[8] | 0, U = p & 8191, Q = p >>> 13, ie = _[9] | 0, ue = ie & 8191, ve = ie >>> 13;
                    b.negative = d.negative ^ l.negative, b.length = 19, R = Math.imul($, Oe), u = Math.imul($, We), u = u + Math.imul(te, Oe) | 0, I = Math.imul(te, We);
                    var Ce = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (Ce >>> 26) | 0, Ce &= 67108863, R = Math.imul(fe, Oe), u = Math.imul(fe, We), u = u + Math.imul(pe, Oe) | 0, I = Math.imul(pe, We), R = R + Math.imul($, pt) | 0, u = u + Math.imul($, St) | 0, u = u + Math.imul(te, pt) | 0, I = I + Math.imul(te, St) | 0;
                    var Te = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (Te >>> 26) | 0, Te &= 67108863, R = Math.imul(J, Oe), u = Math.imul(J, We), u = u + Math.imul(oe, Oe) | 0, I = Math.imul(oe, We), R = R + Math.imul(fe, pt) | 0, u = u + Math.imul(fe, St) | 0, u = u + Math.imul(pe, pt) | 0, I = I + Math.imul(pe, St) | 0, R = R + Math.imul($, It) | 0, u = u + Math.imul($, Bt) | 0, u = u + Math.imul(te, It) | 0, I = I + Math.imul(te, Bt) | 0;
                    var st = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (st >>> 26) | 0, st &= 67108863, R = Math.imul(xe, Oe), u = Math.imul(xe, We), u = u + Math.imul(z, Oe) | 0, I = Math.imul(z, We), R = R + Math.imul(J, pt) | 0, u = u + Math.imul(J, St) | 0, u = u + Math.imul(oe, pt) | 0, I = I + Math.imul(oe, St) | 0, R = R + Math.imul(fe, It) | 0, u = u + Math.imul(fe, Bt) | 0, u = u + Math.imul(pe, It) | 0, I = I + Math.imul(pe, Bt) | 0, R = R + Math.imul($, Ot) | 0, u = u + Math.imul($, Nt) | 0, u = u + Math.imul(te, Ot) | 0, I = I + Math.imul(te, Nt) | 0;
                    var Pe = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (Pe >>> 26) | 0, Pe &= 67108863, R = Math.imul(re, Oe), u = Math.imul(re, We), u = u + Math.imul(ge, Oe) | 0, I = Math.imul(ge, We), R = R + Math.imul(xe, pt) | 0, u = u + Math.imul(xe, St) | 0, u = u + Math.imul(z, pt) | 0, I = I + Math.imul(z, St) | 0, R = R + Math.imul(J, It) | 0, u = u + Math.imul(J, Bt) | 0, u = u + Math.imul(oe, It) | 0, I = I + Math.imul(oe, Bt) | 0, R = R + Math.imul(fe, Ot) | 0, u = u + Math.imul(fe, Nt) | 0, u = u + Math.imul(pe, Ot) | 0, I = I + Math.imul(pe, Nt) | 0, R = R + Math.imul($, _t) | 0, u = u + Math.imul($, Et) | 0, u = u + Math.imul(te, _t) | 0, I = I + Math.imul(te, Et) | 0;
                    var Ve = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (Ve >>> 26) | 0, Ve &= 67108863, R = Math.imul(ye, Oe), u = Math.imul(ye, We), u = u + Math.imul(Y, Oe) | 0, I = Math.imul(Y, We), R = R + Math.imul(re, pt) | 0, u = u + Math.imul(re, St) | 0, u = u + Math.imul(ge, pt) | 0, I = I + Math.imul(ge, St) | 0, R = R + Math.imul(xe, It) | 0, u = u + Math.imul(xe, Bt) | 0, u = u + Math.imul(z, It) | 0, I = I + Math.imul(z, Bt) | 0, R = R + Math.imul(J, Ot) | 0, u = u + Math.imul(J, Nt) | 0, u = u + Math.imul(oe, Ot) | 0, I = I + Math.imul(oe, Nt) | 0, R = R + Math.imul(fe, _t) | 0, u = u + Math.imul(fe, Et) | 0, u = u + Math.imul(pe, _t) | 0, I = I + Math.imul(pe, Et) | 0, R = R + Math.imul($, F) | 0, u = u + Math.imul($, _e) | 0, u = u + Math.imul(te, F) | 0, I = I + Math.imul(te, _e) | 0;
                    var Ge = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (Ge >>> 26) | 0, Ge &= 67108863, R = Math.imul(be, Oe), u = Math.imul(be, We), u = u + Math.imul(se, Oe) | 0, I = Math.imul(se, We), R = R + Math.imul(ye, pt) | 0, u = u + Math.imul(ye, St) | 0, u = u + Math.imul(Y, pt) | 0, I = I + Math.imul(Y, St) | 0, R = R + Math.imul(re, It) | 0, u = u + Math.imul(re, Bt) | 0, u = u + Math.imul(ge, It) | 0, I = I + Math.imul(ge, Bt) | 0, R = R + Math.imul(xe, Ot) | 0, u = u + Math.imul(xe, Nt) | 0, u = u + Math.imul(z, Ot) | 0, I = I + Math.imul(z, Nt) | 0, R = R + Math.imul(J, _t) | 0, u = u + Math.imul(J, Et) | 0, u = u + Math.imul(oe, _t) | 0, I = I + Math.imul(oe, Et) | 0, R = R + Math.imul(fe, F) | 0, u = u + Math.imul(fe, _e) | 0, u = u + Math.imul(pe, F) | 0, I = I + Math.imul(pe, _e) | 0, R = R + Math.imul($, Ae) | 0, u = u + Math.imul($, ut) | 0, u = u + Math.imul(te, Ae) | 0, I = I + Math.imul(te, ut) | 0;
                    var at = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (at >>> 26) | 0, at &= 67108863, R = Math.imul(ze, Oe), u = Math.imul(ze, We), u = u + Math.imul($e, Oe) | 0, I = Math.imul($e, We), R = R + Math.imul(be, pt) | 0, u = u + Math.imul(be, St) | 0, u = u + Math.imul(se, pt) | 0, I = I + Math.imul(se, St) | 0, R = R + Math.imul(ye, It) | 0, u = u + Math.imul(ye, Bt) | 0, u = u + Math.imul(Y, It) | 0, I = I + Math.imul(Y, Bt) | 0, R = R + Math.imul(re, Ot) | 0, u = u + Math.imul(re, Nt) | 0, u = u + Math.imul(ge, Ot) | 0, I = I + Math.imul(ge, Nt) | 0, R = R + Math.imul(xe, _t) | 0, u = u + Math.imul(xe, Et) | 0, u = u + Math.imul(z, _t) | 0, I = I + Math.imul(z, Et) | 0, R = R + Math.imul(J, F) | 0, u = u + Math.imul(J, _e) | 0, u = u + Math.imul(oe, F) | 0, I = I + Math.imul(oe, _e) | 0, R = R + Math.imul(fe, Ae) | 0, u = u + Math.imul(fe, ut) | 0, u = u + Math.imul(pe, Ae) | 0, I = I + Math.imul(pe, ut) | 0, R = R + Math.imul($, L) | 0, u = u + Math.imul($, C) | 0, u = u + Math.imul(te, L) | 0, I = I + Math.imul(te, C) | 0;
                    var it = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (it >>> 26) | 0, it &= 67108863, R = Math.imul(je, Oe), u = Math.imul(je, We), u = u + Math.imul(Qe, Oe) | 0, I = Math.imul(Qe, We), R = R + Math.imul(ze, pt) | 0, u = u + Math.imul(ze, St) | 0, u = u + Math.imul($e, pt) | 0, I = I + Math.imul($e, St) | 0, R = R + Math.imul(be, It) | 0, u = u + Math.imul(be, Bt) | 0, u = u + Math.imul(se, It) | 0, I = I + Math.imul(se, Bt) | 0, R = R + Math.imul(ye, Ot) | 0, u = u + Math.imul(ye, Nt) | 0, u = u + Math.imul(Y, Ot) | 0, I = I + Math.imul(Y, Nt) | 0, R = R + Math.imul(re, _t) | 0, u = u + Math.imul(re, Et) | 0, u = u + Math.imul(ge, _t) | 0, I = I + Math.imul(ge, Et) | 0, R = R + Math.imul(xe, F) | 0, u = u + Math.imul(xe, _e) | 0, u = u + Math.imul(z, F) | 0, I = I + Math.imul(z, _e) | 0, R = R + Math.imul(J, Ae) | 0, u = u + Math.imul(J, ut) | 0, u = u + Math.imul(oe, Ae) | 0, I = I + Math.imul(oe, ut) | 0, R = R + Math.imul(fe, L) | 0, u = u + Math.imul(fe, C) | 0, u = u + Math.imul(pe, L) | 0, I = I + Math.imul(pe, C) | 0, R = R + Math.imul($, U) | 0, u = u + Math.imul($, Q) | 0, u = u + Math.imul(te, U) | 0, I = I + Math.imul(te, Q) | 0;
                    var Je = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (Je >>> 26) | 0, Je &= 67108863, R = Math.imul(bt, Oe), u = Math.imul(bt, We), u = u + Math.imul(et, Oe) | 0, I = Math.imul(et, We), R = R + Math.imul(je, pt) | 0, u = u + Math.imul(je, St) | 0, u = u + Math.imul(Qe, pt) | 0, I = I + Math.imul(Qe, St) | 0, R = R + Math.imul(ze, It) | 0, u = u + Math.imul(ze, Bt) | 0, u = u + Math.imul($e, It) | 0, I = I + Math.imul($e, Bt) | 0, R = R + Math.imul(be, Ot) | 0, u = u + Math.imul(be, Nt) | 0, u = u + Math.imul(se, Ot) | 0, I = I + Math.imul(se, Nt) | 0, R = R + Math.imul(ye, _t) | 0, u = u + Math.imul(ye, Et) | 0, u = u + Math.imul(Y, _t) | 0, I = I + Math.imul(Y, Et) | 0, R = R + Math.imul(re, F) | 0, u = u + Math.imul(re, _e) | 0, u = u + Math.imul(ge, F) | 0, I = I + Math.imul(ge, _e) | 0, R = R + Math.imul(xe, Ae) | 0, u = u + Math.imul(xe, ut) | 0, u = u + Math.imul(z, Ae) | 0, I = I + Math.imul(z, ut) | 0, R = R + Math.imul(J, L) | 0, u = u + Math.imul(J, C) | 0, u = u + Math.imul(oe, L) | 0, I = I + Math.imul(oe, C) | 0, R = R + Math.imul(fe, U) | 0, u = u + Math.imul(fe, Q) | 0, u = u + Math.imul(pe, U) | 0, I = I + Math.imul(pe, Q) | 0, R = R + Math.imul($, ue) | 0, u = u + Math.imul($, ve) | 0, u = u + Math.imul(te, ue) | 0, I = I + Math.imul(te, ve) | 0;
                    var tt = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (tt >>> 26) | 0, tt &= 67108863, R = Math.imul(bt, pt), u = Math.imul(bt, St), u = u + Math.imul(et, pt) | 0, I = Math.imul(et, St), R = R + Math.imul(je, It) | 0, u = u + Math.imul(je, Bt) | 0, u = u + Math.imul(Qe, It) | 0, I = I + Math.imul(Qe, Bt) | 0, R = R + Math.imul(ze, Ot) | 0, u = u + Math.imul(ze, Nt) | 0, u = u + Math.imul($e, Ot) | 0, I = I + Math.imul($e, Nt) | 0, R = R + Math.imul(be, _t) | 0, u = u + Math.imul(be, Et) | 0, u = u + Math.imul(se, _t) | 0, I = I + Math.imul(se, Et) | 0, R = R + Math.imul(ye, F) | 0, u = u + Math.imul(ye, _e) | 0, u = u + Math.imul(Y, F) | 0, I = I + Math.imul(Y, _e) | 0, R = R + Math.imul(re, Ae) | 0, u = u + Math.imul(re, ut) | 0, u = u + Math.imul(ge, Ae) | 0, I = I + Math.imul(ge, ut) | 0, R = R + Math.imul(xe, L) | 0, u = u + Math.imul(xe, C) | 0, u = u + Math.imul(z, L) | 0, I = I + Math.imul(z, C) | 0, R = R + Math.imul(J, U) | 0, u = u + Math.imul(J, Q) | 0, u = u + Math.imul(oe, U) | 0, I = I + Math.imul(oe, Q) | 0, R = R + Math.imul(fe, ue) | 0, u = u + Math.imul(fe, ve) | 0, u = u + Math.imul(pe, ue) | 0, I = I + Math.imul(pe, ve) | 0;
                    var Xe = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (Xe >>> 26) | 0, Xe &= 67108863, R = Math.imul(bt, It), u = Math.imul(bt, Bt), u = u + Math.imul(et, It) | 0, I = Math.imul(et, Bt), R = R + Math.imul(je, Ot) | 0, u = u + Math.imul(je, Nt) | 0, u = u + Math.imul(Qe, Ot) | 0, I = I + Math.imul(Qe, Nt) | 0, R = R + Math.imul(ze, _t) | 0, u = u + Math.imul(ze, Et) | 0, u = u + Math.imul($e, _t) | 0, I = I + Math.imul($e, Et) | 0, R = R + Math.imul(be, F) | 0, u = u + Math.imul(be, _e) | 0, u = u + Math.imul(se, F) | 0, I = I + Math.imul(se, _e) | 0, R = R + Math.imul(ye, Ae) | 0, u = u + Math.imul(ye, ut) | 0, u = u + Math.imul(Y, Ae) | 0, I = I + Math.imul(Y, ut) | 0, R = R + Math.imul(re, L) | 0, u = u + Math.imul(re, C) | 0, u = u + Math.imul(ge, L) | 0, I = I + Math.imul(ge, C) | 0, R = R + Math.imul(xe, U) | 0, u = u + Math.imul(xe, Q) | 0, u = u + Math.imul(z, U) | 0, I = I + Math.imul(z, Q) | 0, R = R + Math.imul(J, ue) | 0, u = u + Math.imul(J, ve) | 0, u = u + Math.imul(oe, ue) | 0, I = I + Math.imul(oe, ve) | 0;
                    var Le = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (Le >>> 26) | 0, Le &= 67108863, R = Math.imul(bt, Ot), u = Math.imul(bt, Nt), u = u + Math.imul(et, Ot) | 0, I = Math.imul(et, Nt), R = R + Math.imul(je, _t) | 0, u = u + Math.imul(je, Et) | 0, u = u + Math.imul(Qe, _t) | 0, I = I + Math.imul(Qe, Et) | 0, R = R + Math.imul(ze, F) | 0, u = u + Math.imul(ze, _e) | 0, u = u + Math.imul($e, F) | 0, I = I + Math.imul($e, _e) | 0, R = R + Math.imul(be, Ae) | 0, u = u + Math.imul(be, ut) | 0, u = u + Math.imul(se, Ae) | 0, I = I + Math.imul(se, ut) | 0, R = R + Math.imul(ye, L) | 0, u = u + Math.imul(ye, C) | 0, u = u + Math.imul(Y, L) | 0, I = I + Math.imul(Y, C) | 0, R = R + Math.imul(re, U) | 0, u = u + Math.imul(re, Q) | 0, u = u + Math.imul(ge, U) | 0, I = I + Math.imul(ge, Q) | 0, R = R + Math.imul(xe, ue) | 0, u = u + Math.imul(xe, ve) | 0, u = u + Math.imul(z, ue) | 0, I = I + Math.imul(z, ve) | 0;
                    var Ke = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (Ke >>> 26) | 0, Ke &= 67108863, R = Math.imul(bt, _t), u = Math.imul(bt, Et), u = u + Math.imul(et, _t) | 0, I = Math.imul(et, Et), R = R + Math.imul(je, F) | 0, u = u + Math.imul(je, _e) | 0, u = u + Math.imul(Qe, F) | 0, I = I + Math.imul(Qe, _e) | 0, R = R + Math.imul(ze, Ae) | 0, u = u + Math.imul(ze, ut) | 0, u = u + Math.imul($e, Ae) | 0, I = I + Math.imul($e, ut) | 0, R = R + Math.imul(be, L) | 0, u = u + Math.imul(be, C) | 0, u = u + Math.imul(se, L) | 0, I = I + Math.imul(se, C) | 0, R = R + Math.imul(ye, U) | 0, u = u + Math.imul(ye, Q) | 0, u = u + Math.imul(Y, U) | 0, I = I + Math.imul(Y, Q) | 0, R = R + Math.imul(re, ue) | 0, u = u + Math.imul(re, ve) | 0, u = u + Math.imul(ge, ue) | 0, I = I + Math.imul(ge, ve) | 0;
                    var Ne = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (Ne >>> 26) | 0, Ne &= 67108863, R = Math.imul(bt, F), u = Math.imul(bt, _e), u = u + Math.imul(et, F) | 0, I = Math.imul(et, _e), R = R + Math.imul(je, Ae) | 0, u = u + Math.imul(je, ut) | 0, u = u + Math.imul(Qe, Ae) | 0, I = I + Math.imul(Qe, ut) | 0, R = R + Math.imul(ze, L) | 0, u = u + Math.imul(ze, C) | 0, u = u + Math.imul($e, L) | 0, I = I + Math.imul($e, C) | 0, R = R + Math.imul(be, U) | 0, u = u + Math.imul(be, Q) | 0, u = u + Math.imul(se, U) | 0, I = I + Math.imul(se, Q) | 0, R = R + Math.imul(ye, ue) | 0, u = u + Math.imul(ye, ve) | 0, u = u + Math.imul(Y, ue) | 0, I = I + Math.imul(Y, ve) | 0;
                    var Ue = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (Ue >>> 26) | 0, Ue &= 67108863, R = Math.imul(bt, Ae), u = Math.imul(bt, ut), u = u + Math.imul(et, Ae) | 0, I = Math.imul(et, ut), R = R + Math.imul(je, L) | 0, u = u + Math.imul(je, C) | 0, u = u + Math.imul(Qe, L) | 0, I = I + Math.imul(Qe, C) | 0, R = R + Math.imul(ze, U) | 0, u = u + Math.imul(ze, Q) | 0, u = u + Math.imul($e, U) | 0, I = I + Math.imul($e, Q) | 0, R = R + Math.imul(be, ue) | 0, u = u + Math.imul(be, ve) | 0, u = u + Math.imul(se, ue) | 0, I = I + Math.imul(se, ve) | 0;
                    var qe = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (qe >>> 26) | 0, qe &= 67108863, R = Math.imul(bt, L), u = Math.imul(bt, C), u = u + Math.imul(et, L) | 0, I = Math.imul(et, C), R = R + Math.imul(je, U) | 0, u = u + Math.imul(je, Q) | 0, u = u + Math.imul(Qe, U) | 0, I = I + Math.imul(Qe, Q) | 0, R = R + Math.imul(ze, ue) | 0, u = u + Math.imul(ze, ve) | 0, u = u + Math.imul($e, ue) | 0, I = I + Math.imul($e, ve) | 0;
                    var ke = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (ke >>> 26) | 0, ke &= 67108863, R = Math.imul(bt, U), u = Math.imul(bt, Q), u = u + Math.imul(et, U) | 0, I = Math.imul(et, Q), R = R + Math.imul(je, ue) | 0, u = u + Math.imul(je, ve) | 0, u = u + Math.imul(Qe, ue) | 0, I = I + Math.imul(Qe, ve) | 0;
                    var ce = (T + R | 0) + ((u & 8191) << 13) | 0;
                    T = (I + (u >>> 13) | 0) + (ce >>> 26) | 0, ce &= 67108863, R = Math.imul(bt, ue), u = Math.imul(bt, ve), u = u + Math.imul(et, ue) | 0, I = Math.imul(et, ve);
                    var de = (T + R | 0) + ((u & 8191) << 13) | 0;
                    return T = (I + (u >>> 13) | 0) + (de >>> 26) | 0, de &= 67108863, B[0] = Ce, B[1] = Te, B[2] = st, B[3] = Pe, B[4] = Ve, B[5] = Ge, B[6] = at, B[7] = it, B[8] = Je, B[9] = tt, B[10] = Xe, B[11] = Le, B[12] = Ke, B[13] = Ne, B[14] = Ue, B[15] = qe, B[16] = ke, B[17] = ce, B[18] = de, T !== 0 && (B[19] = T, b.length++), b;
                };
                Math.imul || (x = E);
                function S(O, d, l) {
                    l.negative = d.negative ^ O.negative, l.length = O.length + d.length;
                    for(var b = 0, m = 0, _ = 0; _ < l.length - 1; _++){
                        var B = m;
                        m = 0;
                        for(var T = b & 67108863, R = Math.min(_, d.length - 1), u = Math.max(0, _ - O.length + 1); u <= R; u++){
                            var I = _ - u, G = O.words[I] | 0, $ = d.words[u] | 0, te = G * $, Z = te & 67108863;
                            B = B + (te / 67108864 | 0) | 0, Z = Z + T | 0, T = Z & 67108863, B = B + (Z >>> 26) | 0, m += B >>> 26, B &= 67108863;
                        }
                        l.words[_] = T, b = B, B = m;
                    }
                    return b !== 0 ? l.words[_] = b : l.length--, l.strip();
                }
                function y(O, d, l) {
                    var b = new A;
                    return b.mulp(O, d, l);
                }
                i.prototype.mulTo = function(d, l) {
                    var b, m = this.length + d.length;
                    return this.length === 10 && d.length === 10 ? b = x(this, d, l) : m < 63 ? b = E(this, d, l) : m < 1024 ? b = S(this, d, l) : b = y(this, d, l), b;
                };
                function A(O, d) {
                    this.x = O, this.y = d;
                }
                A.prototype.makeRBT = function(d) {
                    for(var l = new Array(d), b = i.prototype._countBits(d) - 1, m = 0; m < d; m++)l[m] = this.revBin(m, b, d);
                    return l;
                }, A.prototype.revBin = function(d, l, b) {
                    if (d === 0 || d === b - 1) return d;
                    for(var m = 0, _ = 0; _ < l; _++)m |= (d & 1) << l - _ - 1, d >>= 1;
                    return m;
                }, A.prototype.permute = function(d, l, b, m, _, B) {
                    for(var T = 0; T < B; T++)m[T] = l[d[T]], _[T] = b[d[T]];
                }, A.prototype.transform = function(d, l, b, m, _, B) {
                    this.permute(B, d, l, b, m, _);
                    for(var T = 1; T < _; T <<= 1)for(var R = T << 1, u = Math.cos(2 * Math.PI / R), I = Math.sin(2 * Math.PI / R), G = 0; G < _; G += R)for(var $ = u, te = I, Z = 0; Z < T; Z++){
                        var fe = b[G + Z], pe = m[G + Z], ee = b[G + Z + T], J = m[G + Z + T], oe = $ * ee - te * J;
                        J = $ * J + te * ee, ee = oe, b[G + Z] = fe + ee, m[G + Z] = pe + J, b[G + Z + T] = fe - ee, m[G + Z + T] = pe - J, Z !== R && (oe = u * $ - I * te, te = u * te + I * $, $ = oe);
                    }
                }, A.prototype.guessLen13b = function(d, l) {
                    var b = Math.max(l, d) | 1, m = b & 1, _ = 0;
                    for(b = b / 2 | 0; b; b = b >>> 1)_++;
                    return 1 << _ + 1 + m;
                }, A.prototype.conjugate = function(d, l, b) {
                    if (!(b <= 1)) for(var m = 0; m < b / 2; m++){
                        var _ = d[m];
                        d[m] = d[b - m - 1], d[b - m - 1] = _, _ = l[m], l[m] = -l[b - m - 1], l[b - m - 1] = -_;
                    }
                }, A.prototype.normalize13b = function(d, l) {
                    for(var b = 0, m = 0; m < l / 2; m++){
                        var _ = Math.round(d[2 * m + 1] / l) * 8192 + Math.round(d[2 * m] / l) + b;
                        d[m] = _ & 67108863, _ < 67108864 ? b = 0 : b = _ / 67108864 | 0;
                    }
                    return d;
                }, A.prototype.convert13b = function(d, l, b, m) {
                    for(var _ = 0, B = 0; B < l; B++)_ = _ + (d[B] | 0), b[2 * B] = _ & 8191, _ = _ >>> 13, b[2 * B + 1] = _ & 8191, _ = _ >>> 13;
                    for(B = 2 * l; B < m; ++B)b[B] = 0;
                    n(_ === 0), n((_ & -8192) === 0);
                }, A.prototype.stub = function(d) {
                    for(var l = new Array(d), b = 0; b < d; b++)l[b] = 0;
                    return l;
                }, A.prototype.mulp = function(d, l, b) {
                    var m = 2 * this.guessLen13b(d.length, l.length), _ = this.makeRBT(m), B = this.stub(m), T = new Array(m), R = new Array(m), u = new Array(m), I = new Array(m), G = new Array(m), $ = new Array(m), te = b.words;
                    te.length = m, this.convert13b(d.words, d.length, T, m), this.convert13b(l.words, l.length, I, m), this.transform(T, B, R, u, m, _), this.transform(I, B, G, $, m, _);
                    for(var Z = 0; Z < m; Z++){
                        var fe = R[Z] * G[Z] - u[Z] * $[Z];
                        u[Z] = R[Z] * $[Z] + u[Z] * G[Z], R[Z] = fe;
                    }
                    return this.conjugate(R, u, m), this.transform(R, u, te, B, m, _), this.conjugate(te, B, m), this.normalize13b(te, m), b.negative = d.negative ^ l.negative, b.length = d.length + l.length, b.strip();
                }, i.prototype.mul = function(d) {
                    var l = new i(null);
                    return l.words = new Array(this.length + d.length), this.mulTo(d, l);
                }, i.prototype.mulf = function(d) {
                    var l = new i(null);
                    return l.words = new Array(this.length + d.length), y(this, d, l);
                }, i.prototype.imul = function(d) {
                    return this.clone().mulTo(d, this);
                }, i.prototype.imuln = function(d) {
                    n(typeof d == "number"), n(d < 67108864);
                    for(var l = 0, b = 0; b < this.length; b++){
                        var m = (this.words[b] | 0) * d, _ = (m & 67108863) + (l & 67108863);
                        l >>= 26, l += m / 67108864 | 0, l += _ >>> 26, this.words[b] = _ & 67108863;
                    }
                    return l !== 0 && (this.words[b] = l, this.length++), this.length = d === 0 ? 1 : this.length, this;
                }, i.prototype.muln = function(d) {
                    return this.clone().imuln(d);
                }, i.prototype.sqr = function() {
                    return this.mul(this);
                }, i.prototype.isqr = function() {
                    return this.imul(this.clone());
                }, i.prototype.pow = function(d) {
                    var l = w(d);
                    if (l.length === 0) return new i(1);
                    for(var b = this, m = 0; m < l.length && l[m] === 0; m++, b = b.sqr());
                    if (++m < l.length) for(var _ = b.sqr(); m < l.length; m++, _ = _.sqr())l[m] !== 0 && (b = b.mul(_));
                    return b;
                }, i.prototype.iushln = function(d) {
                    n(typeof d == "number" && d >= 0);
                    var l = d % 26, b = (d - l) / 26, m = 67108863 >>> 26 - l << 26 - l, _;
                    if (l !== 0) {
                        var B = 0;
                        for(_ = 0; _ < this.length; _++){
                            var T = this.words[_] & m, R = (this.words[_] | 0) - T << l;
                            this.words[_] = R | B, B = T >>> 26 - l;
                        }
                        B && (this.words[_] = B, this.length++);
                    }
                    if (b !== 0) {
                        for(_ = this.length - 1; _ >= 0; _--)this.words[_ + b] = this.words[_];
                        for(_ = 0; _ < b; _++)this.words[_] = 0;
                        this.length += b;
                    }
                    return this.strip();
                }, i.prototype.ishln = function(d) {
                    return n(this.negative === 0), this.iushln(d);
                }, i.prototype.iushrn = function(d, l, b) {
                    n(typeof d == "number" && d >= 0);
                    var m;
                    l ? m = (l - l % 26) / 26 : m = 0;
                    var _ = d % 26, B = Math.min((d - _) / 26, this.length), T = 67108863 ^ 67108863 >>> _ << _, R = b;
                    if (m -= B, m = Math.max(0, m), R) {
                        for(var u = 0; u < B; u++)R.words[u] = this.words[u];
                        R.length = B;
                    }
                    if (B !== 0) if (this.length > B) for(this.length -= B, u = 0; u < this.length; u++)this.words[u] = this.words[u + B];
                    else this.words[0] = 0, this.length = 1;
                    var I = 0;
                    for(u = this.length - 1; u >= 0 && (I !== 0 || u >= m); u--){
                        var G = this.words[u] | 0;
                        this.words[u] = I << 26 - _ | G >>> _, I = G & T;
                    }
                    return R && I !== 0 && (R.words[R.length++] = I), this.length === 0 && (this.words[0] = 0, this.length = 1), this.strip();
                }, i.prototype.ishrn = function(d, l, b) {
                    return n(this.negative === 0), this.iushrn(d, l, b);
                }, i.prototype.shln = function(d) {
                    return this.clone().ishln(d);
                }, i.prototype.ushln = function(d) {
                    return this.clone().iushln(d);
                }, i.prototype.shrn = function(d) {
                    return this.clone().ishrn(d);
                }, i.prototype.ushrn = function(d) {
                    return this.clone().iushrn(d);
                }, i.prototype.testn = function(d) {
                    n(typeof d == "number" && d >= 0);
                    var l = d % 26, b = (d - l) / 26, m = 1 << l;
                    if (this.length <= b) return !1;
                    var _ = this.words[b];
                    return !!(_ & m);
                }, i.prototype.imaskn = function(d) {
                    n(typeof d == "number" && d >= 0);
                    var l = d % 26, b = (d - l) / 26;
                    if (n(this.negative === 0, "imaskn works only with positive numbers"), this.length <= b) return this;
                    if (l !== 0 && b++, this.length = Math.min(b, this.length), l !== 0) {
                        var m = 67108863 ^ 67108863 >>> l << l;
                        this.words[this.length - 1] &= m;
                    }
                    return this.length === 0 && (this.words[0] = 0, this.length = 1), this.strip();
                }, i.prototype.maskn = function(d) {
                    return this.clone().imaskn(d);
                }, i.prototype.iaddn = function(d) {
                    return n(typeof d == "number"), n(d < 67108864), d < 0 ? this.isubn(-d) : this.negative !== 0 ? this.length === 1 && (this.words[0] | 0) < d ? (this.words[0] = d - (this.words[0] | 0), this.negative = 0, this) : (this.negative = 0, this.isubn(d), this.negative = 1, this) : this._iaddn(d);
                }, i.prototype._iaddn = function(d) {
                    this.words[0] += d;
                    for(var l = 0; l < this.length && this.words[l] >= 67108864; l++)this.words[l] -= 67108864, l === this.length - 1 ? this.words[l + 1] = 1 : this.words[l + 1]++;
                    return this.length = Math.max(this.length, l + 1), this;
                }, i.prototype.isubn = function(d) {
                    if (n(typeof d == "number"), n(d < 67108864), d < 0) return this.iaddn(-d);
                    if (this.negative !== 0) return this.negative = 0, this.iaddn(d), this.negative = 1, this;
                    if (this.words[0] -= d, this.length === 1 && this.words[0] < 0) this.words[0] = -this.words[0], this.negative = 1;
                    else for(var l = 0; l < this.length && this.words[l] < 0; l++)this.words[l] += 67108864, this.words[l + 1] -= 1;
                    return this.strip();
                }, i.prototype.addn = function(d) {
                    return this.clone().iaddn(d);
                }, i.prototype.subn = function(d) {
                    return this.clone().isubn(d);
                }, i.prototype.iabs = function() {
                    return this.negative = 0, this;
                }, i.prototype.abs = function() {
                    return this.clone().iabs();
                }, i.prototype._ishlnsubmul = function(d, l, b) {
                    var m = d.length + b, _;
                    this._expand(m);
                    var B, T = 0;
                    for(_ = 0; _ < d.length; _++){
                        B = (this.words[_ + b] | 0) + T;
                        var R = (d.words[_] | 0) * l;
                        B -= R & 67108863, T = (B >> 26) - (R / 67108864 | 0), this.words[_ + b] = B & 67108863;
                    }
                    for(; _ < this.length - b; _++)B = (this.words[_ + b] | 0) + T, T = B >> 26, this.words[_ + b] = B & 67108863;
                    if (T === 0) return this.strip();
                    for(n(T === -1), T = 0, _ = 0; _ < this.length; _++)B = -(this.words[_] | 0) + T, T = B >> 26, this.words[_] = B & 67108863;
                    return this.negative = 1, this.strip();
                }, i.prototype._wordDiv = function(d, l) {
                    var b = this.length - d.length, m = this.clone(), _ = d, B = _.words[_.length - 1] | 0, T = this._countBits(B);
                    b = 26 - T, b !== 0 && (_ = _.ushln(b), m.iushln(b), B = _.words[_.length - 1] | 0);
                    var R = m.length - _.length, u;
                    if (l !== "mod") {
                        u = new i(null), u.length = R + 1, u.words = new Array(u.length);
                        for(var I = 0; I < u.length; I++)u.words[I] = 0;
                    }
                    var G = m.clone()._ishlnsubmul(_, 1, R);
                    G.negative === 0 && (m = G, u && (u.words[R] = 1));
                    for(var $ = R - 1; $ >= 0; $--){
                        var te = (m.words[_.length + $] | 0) * 67108864 + (m.words[_.length + $ - 1] | 0);
                        for(te = Math.min(te / B | 0, 67108863), m._ishlnsubmul(_, te, $); m.negative !== 0;)te--, m.negative = 0, m._ishlnsubmul(_, 1, $), m.isZero() || (m.negative ^= 1);
                        u && (u.words[$] = te);
                    }
                    return u && u.strip(), m.strip(), l !== "div" && b !== 0 && m.iushrn(b), {
                        div: u || null,
                        mod: m
                    };
                }, i.prototype.divmod = function(d, l, b) {
                    if (n(!d.isZero()), this.isZero()) return {
                        div: new i(0),
                        mod: new i(0)
                    };
                    var m, _, B;
                    return this.negative !== 0 && d.negative === 0 ? (B = this.neg().divmod(d, l), l !== "mod" && (m = B.div.neg()), l !== "div" && (_ = B.mod.neg(), b && _.negative !== 0 && _.iadd(d)), {
                        div: m,
                        mod: _
                    }) : this.negative === 0 && d.negative !== 0 ? (B = this.divmod(d.neg(), l), l !== "mod" && (m = B.div.neg()), {
                        div: m,
                        mod: B.mod
                    }) : (this.negative & d.negative) !== 0 ? (B = this.neg().divmod(d.neg(), l), l !== "div" && (_ = B.mod.neg(), b && _.negative !== 0 && _.isub(d)), {
                        div: B.div,
                        mod: _
                    }) : d.length > this.length || this.cmp(d) < 0 ? {
                        div: new i(0),
                        mod: this
                    } : d.length === 1 ? l === "div" ? {
                        div: this.divn(d.words[0]),
                        mod: null
                    } : l === "mod" ? {
                        div: null,
                        mod: new i(this.modn(d.words[0]))
                    } : {
                        div: this.divn(d.words[0]),
                        mod: new i(this.modn(d.words[0]))
                    } : this._wordDiv(d, l);
                }, i.prototype.div = function(d) {
                    return this.divmod(d, "div", !1).div;
                }, i.prototype.mod = function(d) {
                    return this.divmod(d, "mod", !1).mod;
                }, i.prototype.umod = function(d) {
                    return this.divmod(d, "mod", !0).mod;
                }, i.prototype.divRound = function(d) {
                    var l = this.divmod(d);
                    if (l.mod.isZero()) return l.div;
                    var b = l.div.negative !== 0 ? l.mod.isub(d) : l.mod, m = d.ushrn(1), _ = d.andln(1), B = b.cmp(m);
                    return B < 0 || _ === 1 && B === 0 ? l.div : l.div.negative !== 0 ? l.div.isubn(1) : l.div.iaddn(1);
                }, i.prototype.modn = function(d) {
                    n(d <= 67108863);
                    for(var l = (1 << 26) % d, b = 0, m = this.length - 1; m >= 0; m--)b = (l * b + (this.words[m] | 0)) % d;
                    return b;
                }, i.prototype.idivn = function(d) {
                    n(d <= 67108863);
                    for(var l = 0, b = this.length - 1; b >= 0; b--){
                        var m = (this.words[b] | 0) + l * 67108864;
                        this.words[b] = m / d | 0, l = m % d;
                    }
                    return this.strip();
                }, i.prototype.divn = function(d) {
                    return this.clone().idivn(d);
                }, i.prototype.egcd = function(d) {
                    n(d.negative === 0), n(!d.isZero());
                    var l = this, b = d.clone();
                    l.negative !== 0 ? l = l.umod(d) : l = l.clone();
                    for(var m = new i(1), _ = new i(0), B = new i(0), T = new i(1), R = 0; l.isEven() && b.isEven();)l.iushrn(1), b.iushrn(1), ++R;
                    for(var u = b.clone(), I = l.clone(); !l.isZero();){
                        for(var G = 0, $ = 1; (l.words[0] & $) === 0 && G < 26; ++G, $ <<= 1);
                        if (G > 0) for(l.iushrn(G); G-- > 0;)(m.isOdd() || _.isOdd()) && (m.iadd(u), _.isub(I)), m.iushrn(1), _.iushrn(1);
                        for(var te = 0, Z = 1; (b.words[0] & Z) === 0 && te < 26; ++te, Z <<= 1);
                        if (te > 0) for(b.iushrn(te); te-- > 0;)(B.isOdd() || T.isOdd()) && (B.iadd(u), T.isub(I)), B.iushrn(1), T.iushrn(1);
                        l.cmp(b) >= 0 ? (l.isub(b), m.isub(B), _.isub(T)) : (b.isub(l), B.isub(m), T.isub(_));
                    }
                    return {
                        a: B,
                        b: T,
                        gcd: b.iushln(R)
                    };
                }, i.prototype._invmp = function(d) {
                    n(d.negative === 0), n(!d.isZero());
                    var l = this, b = d.clone();
                    l.negative !== 0 ? l = l.umod(d) : l = l.clone();
                    for(var m = new i(1), _ = new i(0), B = b.clone(); l.cmpn(1) > 0 && b.cmpn(1) > 0;){
                        for(var T = 0, R = 1; (l.words[0] & R) === 0 && T < 26; ++T, R <<= 1);
                        if (T > 0) for(l.iushrn(T); T-- > 0;)m.isOdd() && m.iadd(B), m.iushrn(1);
                        for(var u = 0, I = 1; (b.words[0] & I) === 0 && u < 26; ++u, I <<= 1);
                        if (u > 0) for(b.iushrn(u); u-- > 0;)_.isOdd() && _.iadd(B), _.iushrn(1);
                        l.cmp(b) >= 0 ? (l.isub(b), m.isub(_)) : (b.isub(l), _.isub(m));
                    }
                    var G;
                    return l.cmpn(1) === 0 ? G = m : G = _, G.cmpn(0) < 0 && G.iadd(d), G;
                }, i.prototype.gcd = function(d) {
                    if (this.isZero()) return d.abs();
                    if (d.isZero()) return this.abs();
                    var l = this.clone(), b = d.clone();
                    l.negative = 0, b.negative = 0;
                    for(var m = 0; l.isEven() && b.isEven(); m++)l.iushrn(1), b.iushrn(1);
                    do {
                        for(; l.isEven();)l.iushrn(1);
                        for(; b.isEven();)b.iushrn(1);
                        var _ = l.cmp(b);
                        if (_ < 0) {
                            var B = l;
                            l = b, b = B;
                        } else if (_ === 0 || b.cmpn(1) === 0) break;
                        l.isub(b);
                    }while (!0);
                    return b.iushln(m);
                }, i.prototype.invm = function(d) {
                    return this.egcd(d).a.umod(d);
                }, i.prototype.isEven = function() {
                    return (this.words[0] & 1) === 0;
                }, i.prototype.isOdd = function() {
                    return (this.words[0] & 1) === 1;
                }, i.prototype.andln = function(d) {
                    return this.words[0] & d;
                }, i.prototype.bincn = function(d) {
                    n(typeof d == "number");
                    var l = d % 26, b = (d - l) / 26, m = 1 << l;
                    if (this.length <= b) return this._expand(b + 1), this.words[b] |= m, this;
                    for(var _ = m, B = b; _ !== 0 && B < this.length; B++){
                        var T = this.words[B] | 0;
                        T += _, _ = T >>> 26, T &= 67108863, this.words[B] = T;
                    }
                    return _ !== 0 && (this.words[B] = _, this.length++), this;
                }, i.prototype.isZero = function() {
                    return this.length === 1 && this.words[0] === 0;
                }, i.prototype.cmpn = function(d) {
                    var l = d < 0;
                    if (this.negative !== 0 && !l) return -1;
                    if (this.negative === 0 && l) return 1;
                    this.strip();
                    var b;
                    if (this.length > 1) b = 1;
                    else {
                        l && (d = -d), n(d <= 67108863, "Number is too big");
                        var m = this.words[0] | 0;
                        b = m === d ? 0 : m < d ? -1 : 1;
                    }
                    return this.negative !== 0 ? -b | 0 : b;
                }, i.prototype.cmp = function(d) {
                    if (this.negative !== 0 && d.negative === 0) return -1;
                    if (this.negative === 0 && d.negative !== 0) return 1;
                    var l = this.ucmp(d);
                    return this.negative !== 0 ? -l | 0 : l;
                }, i.prototype.ucmp = function(d) {
                    if (this.length > d.length) return 1;
                    if (this.length < d.length) return -1;
                    for(var l = 0, b = this.length - 1; b >= 0; b--){
                        var m = this.words[b] | 0, _ = d.words[b] | 0;
                        if (m !== _) {
                            m < _ ? l = -1 : m > _ && (l = 1);
                            break;
                        }
                    }
                    return l;
                }, i.prototype.gtn = function(d) {
                    return this.cmpn(d) === 1;
                }, i.prototype.gt = function(d) {
                    return this.cmp(d) === 1;
                }, i.prototype.gten = function(d) {
                    return this.cmpn(d) >= 0;
                }, i.prototype.gte = function(d) {
                    return this.cmp(d) >= 0;
                }, i.prototype.ltn = function(d) {
                    return this.cmpn(d) === -1;
                }, i.prototype.lt = function(d) {
                    return this.cmp(d) === -1;
                }, i.prototype.lten = function(d) {
                    return this.cmpn(d) <= 0;
                }, i.prototype.lte = function(d) {
                    return this.cmp(d) <= 0;
                }, i.prototype.eqn = function(d) {
                    return this.cmpn(d) === 0;
                }, i.prototype.eq = function(d) {
                    return this.cmp(d) === 0;
                }, i.red = function(d) {
                    return new j(d);
                }, i.prototype.toRed = function(d) {
                    return n(!this.red, "Already a number in reduction context"), n(this.negative === 0, "red works only with positives"), d.convertTo(this)._forceRed(d);
                }, i.prototype.fromRed = function() {
                    return n(this.red, "fromRed works only with numbers in reduction context"), this.red.convertFrom(this);
                }, i.prototype._forceRed = function(d) {
                    return this.red = d, this;
                }, i.prototype.forceRed = function(d) {
                    return n(!this.red, "Already a number in reduction context"), this._forceRed(d);
                }, i.prototype.redAdd = function(d) {
                    return n(this.red, "redAdd works only with red numbers"), this.red.add(this, d);
                }, i.prototype.redIAdd = function(d) {
                    return n(this.red, "redIAdd works only with red numbers"), this.red.iadd(this, d);
                }, i.prototype.redSub = function(d) {
                    return n(this.red, "redSub works only with red numbers"), this.red.sub(this, d);
                }, i.prototype.redISub = function(d) {
                    return n(this.red, "redISub works only with red numbers"), this.red.isub(this, d);
                }, i.prototype.redShl = function(d) {
                    return n(this.red, "redShl works only with red numbers"), this.red.shl(this, d);
                }, i.prototype.redMul = function(d) {
                    return n(this.red, "redMul works only with red numbers"), this.red._verify2(this, d), this.red.mul(this, d);
                }, i.prototype.redIMul = function(d) {
                    return n(this.red, "redMul works only with red numbers"), this.red._verify2(this, d), this.red.imul(this, d);
                }, i.prototype.redSqr = function() {
                    return n(this.red, "redSqr works only with red numbers"), this.red._verify1(this), this.red.sqr(this);
                }, i.prototype.redISqr = function() {
                    return n(this.red, "redISqr works only with red numbers"), this.red._verify1(this), this.red.isqr(this);
                }, i.prototype.redSqrt = function() {
                    return n(this.red, "redSqrt works only with red numbers"), this.red._verify1(this), this.red.sqrt(this);
                }, i.prototype.redInvm = function() {
                    return n(this.red, "redInvm works only with red numbers"), this.red._verify1(this), this.red.invm(this);
                }, i.prototype.redNeg = function() {
                    return n(this.red, "redNeg works only with red numbers"), this.red._verify1(this), this.red.neg(this);
                }, i.prototype.redPow = function(d) {
                    return n(this.red && !d.red, "redPow(normalNum)"), this.red._verify1(this), this.red.pow(this, d);
                };
                var P = {
                    k256: null,
                    p224: null,
                    p192: null,
                    p25519: null
                };
                function N(O, d) {
                    this.name = O, this.p = new i(d, 16), this.n = this.p.bitLength(), this.k = new i(1).iushln(this.n).isub(this.p), this.tmp = this._tmp();
                }
                N.prototype._tmp = function() {
                    var d = new i(null);
                    return d.words = new Array(Math.ceil(this.n / 13)), d;
                }, N.prototype.ireduce = function(d) {
                    var l = d, b;
                    do this.split(l, this.tmp), l = this.imulK(l), l = l.iadd(this.tmp), b = l.bitLength();
                    while (b > this.n);
                    var m = b < this.n ? -1 : l.ucmp(this.p);
                    return m === 0 ? (l.words[0] = 0, l.length = 1) : m > 0 ? l.isub(this.p) : l.strip !== void 0 ? l.strip() : l._strip(), l;
                }, N.prototype.split = function(d, l) {
                    d.iushrn(this.n, 0, l);
                }, N.prototype.imulK = function(d) {
                    return d.imul(this.k);
                };
                function k() {
                    N.call(this, "k256", "ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f");
                }
                a(k, N), k.prototype.split = function(d, l) {
                    for(var b = 4194303, m = Math.min(d.length, 9), _ = 0; _ < m; _++)l.words[_] = d.words[_];
                    if (l.length = m, d.length <= 9) {
                        d.words[0] = 0, d.length = 1;
                        return;
                    }
                    var B = d.words[9];
                    for(l.words[l.length++] = B & b, _ = 10; _ < d.length; _++){
                        var T = d.words[_] | 0;
                        d.words[_ - 10] = (T & b) << 4 | B >>> 22, B = T;
                    }
                    B >>>= 22, d.words[_ - 10] = B, B === 0 && d.length > 10 ? d.length -= 10 : d.length -= 9;
                }, k.prototype.imulK = function(d) {
                    d.words[d.length] = 0, d.words[d.length + 1] = 0, d.length += 2;
                    for(var l = 0, b = 0; b < d.length; b++){
                        var m = d.words[b] | 0;
                        l += m * 977, d.words[b] = l & 67108863, l = m * 64 + (l / 67108864 | 0);
                    }
                    return d.words[d.length - 1] === 0 && (d.length--, d.words[d.length - 1] === 0 && d.length--), d;
                };
                function D() {
                    N.call(this, "p224", "ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001");
                }
                a(D, N);
                function V() {
                    N.call(this, "p192", "ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff");
                }
                a(V, N);
                function K() {
                    N.call(this, "25519", "7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed");
                }
                a(K, N), K.prototype.imulK = function(d) {
                    for(var l = 0, b = 0; b < d.length; b++){
                        var m = (d.words[b] | 0) * 19 + l, _ = m & 67108863;
                        m >>>= 26, d.words[b] = _, l = m;
                    }
                    return l !== 0 && (d.words[d.length++] = l), d;
                }, i._prime = function(d) {
                    if (P[d]) return P[d];
                    var l;
                    if (d === "k256") l = new k;
                    else if (d === "p224") l = new D;
                    else if (d === "p192") l = new V;
                    else if (d === "p25519") l = new K;
                    else throw new Error("Unknown prime " + d);
                    return P[d] = l, l;
                };
                function j(O) {
                    if (typeof O == "string") {
                        var d = i._prime(O);
                        this.m = d.p, this.prime = d;
                    } else n(O.gtn(1), "modulus must be greater than 1"), this.m = O, this.prime = null;
                }
                j.prototype._verify1 = function(d) {
                    n(d.negative === 0, "red works only with positives"), n(d.red, "red works only with red numbers");
                }, j.prototype._verify2 = function(d, l) {
                    n((d.negative | l.negative) === 0, "red works only with positives"), n(d.red && d.red === l.red, "red works only with red numbers");
                }, j.prototype.imod = function(d) {
                    return this.prime ? this.prime.ireduce(d)._forceRed(this) : d.umod(this.m)._forceRed(this);
                }, j.prototype.neg = function(d) {
                    return d.isZero() ? d.clone() : this.m.sub(d)._forceRed(this);
                }, j.prototype.add = function(d, l) {
                    this._verify2(d, l);
                    var b = d.add(l);
                    return b.cmp(this.m) >= 0 && b.isub(this.m), b._forceRed(this);
                }, j.prototype.iadd = function(d, l) {
                    this._verify2(d, l);
                    var b = d.iadd(l);
                    return b.cmp(this.m) >= 0 && b.isub(this.m), b;
                }, j.prototype.sub = function(d, l) {
                    this._verify2(d, l);
                    var b = d.sub(l);
                    return b.cmpn(0) < 0 && b.iadd(this.m), b._forceRed(this);
                }, j.prototype.isub = function(d, l) {
                    this._verify2(d, l);
                    var b = d.isub(l);
                    return b.cmpn(0) < 0 && b.iadd(this.m), b;
                }, j.prototype.shl = function(d, l) {
                    return this._verify1(d), this.imod(d.ushln(l));
                }, j.prototype.imul = function(d, l) {
                    return this._verify2(d, l), this.imod(d.imul(l));
                }, j.prototype.mul = function(d, l) {
                    return this._verify2(d, l), this.imod(d.mul(l));
                }, j.prototype.isqr = function(d) {
                    return this.imul(d, d.clone());
                }, j.prototype.sqr = function(d) {
                    return this.mul(d, d);
                }, j.prototype.sqrt = function(d) {
                    if (d.isZero()) return d.clone();
                    var l = this.m.andln(3);
                    if (n(l % 2 === 1), l === 3) {
                        var b = this.m.add(new i(1)).iushrn(2);
                        return this.pow(d, b);
                    }
                    for(var m = this.m.subn(1), _ = 0; !m.isZero() && m.andln(1) === 0;)_++, m.iushrn(1);
                    n(!m.isZero());
                    var B = new i(1).toRed(this), T = B.redNeg(), R = this.m.subn(1).iushrn(1), u = this.m.bitLength();
                    for(u = new i(2 * u * u).toRed(this); this.pow(u, R).cmp(T) !== 0;)u.redIAdd(T);
                    for(var I = this.pow(u, m), G = this.pow(d, m.addn(1).iushrn(1)), $ = this.pow(d, m), te = _; $.cmp(B) !== 0;){
                        for(var Z = $, fe = 0; Z.cmp(B) !== 0; fe++)Z = Z.redSqr();
                        n(fe < te);
                        var pe = this.pow(I, new i(1).iushln(te - fe - 1));
                        G = G.redMul(pe), I = pe.redSqr(), $ = $.redMul(I), te = fe;
                    }
                    return G;
                }, j.prototype.invm = function(d) {
                    var l = d._invmp(this.m);
                    return l.negative !== 0 ? (l.negative = 0, this.imod(l).redNeg()) : this.imod(l);
                }, j.prototype.pow = function(d, l) {
                    if (l.isZero()) return new i(1).toRed(this);
                    if (l.cmpn(1) === 0) return d.clone();
                    var b = 4, m = new Array(1 << b);
                    m[0] = new i(1).toRed(this), m[1] = d;
                    for(var _ = 2; _ < m.length; _++)m[_] = this.mul(m[_ - 1], d);
                    var B = m[0], T = 0, R = 0, u = l.bitLength() % 26;
                    for(u === 0 && (u = 26), _ = l.length - 1; _ >= 0; _--){
                        for(var I = l.words[_], G = u - 1; G >= 0; G--){
                            var $ = I >> G & 1;
                            if (B !== m[0] && (B = this.sqr(B)), $ === 0 && T === 0) {
                                R = 0;
                                continue;
                            }
                            T <<= 1, T |= $, R++, !(R !== b && (_ !== 0 || G !== 0)) && (B = this.mul(B, m[T]), R = 0, T = 0);
                        }
                        u = 26;
                    }
                    return B;
                }, j.prototype.convertTo = function(d) {
                    var l = d.umod(this.m);
                    return l === d ? l.clone() : l;
                }, j.prototype.convertFrom = function(d) {
                    var l = d.clone();
                    return l.red = null, l;
                }, i.mont = function(d) {
                    return new H(d);
                };
                function H(O) {
                    j.call(this, O), this.shift = this.m.bitLength(), this.shift % 26 !== 0 && (this.shift += 26 - this.shift % 26), this.r = new i(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);
                }
                a(H, j), H.prototype.convertTo = function(d) {
                    return this.imod(d.ushln(this.shift));
                }, H.prototype.convertFrom = function(d) {
                    var l = this.imod(d.mul(this.rinv));
                    return l.red = null, l;
                }, H.prototype.imul = function(d, l) {
                    if (d.isZero() || l.isZero()) return d.words[0] = 0, d.length = 1, d;
                    var b = d.imul(l), m = b.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m), _ = b.isub(m).iushrn(this.shift), B = _;
                    return _.cmp(this.m) >= 0 ? B = _.isub(this.m) : _.cmpn(0) < 0 && (B = _.iadd(this.m)), B._forceRed(this);
                }, H.prototype.mul = function(d, l) {
                    if (d.isZero() || l.isZero()) return new i(0)._forceRed(this);
                    var b = d.mul(l), m = b.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m), _ = b.isub(m).iushrn(this.shift), B = _;
                    return _.cmp(this.m) >= 0 ? B = _.isub(this.m) : _.cmpn(0) < 0 && (B = _.iadd(this.m)), B._forceRed(this);
                }, H.prototype.invm = function(d) {
                    var l = this.imod(d._invmp(this.m).mul(this.r2));
                    return l._forceRed(this);
                };
            })(r, $b);
        })(Yi)), Yi.exports;
    }
    var bs = {}, jc;
    function cu() {
        return jc || (jc = 1, (function(r) {
            var e = r;
            function t(i, s) {
                if (Array.isArray(i)) return i.slice();
                if (!i) return [];
                var o = [];
                if (typeof i != "string") {
                    for(var f = 0; f < i.length; f++)o[f] = i[f] | 0;
                    return o;
                }
                if (s === "hex") {
                    i = i.replace(/[^a-z0-9]+/ig, ""), i.length % 2 !== 0 && (i = "0" + i);
                    for(var f = 0; f < i.length; f += 2)o.push(parseInt(i[f] + i[f + 1], 16));
                } else for(var f = 0; f < i.length; f++){
                    var c = i.charCodeAt(f), h = c >> 8, g = c & 255;
                    h ? o.push(h, g) : o.push(g);
                }
                return o;
            }
            e.toArray = t;
            function n(i) {
                return i.length === 1 ? "0" + i : i;
            }
            e.zero2 = n;
            function a(i) {
                for(var s = "", o = 0; o < i.length; o++)s += n(i[o].toString(16));
                return s;
            }
            e.toHex = a, e.encode = function(s, o) {
                return o === "hex" ? a(s) : s;
            };
        })(bs)), bs;
    }
    var Hc;
    function yr() {
        return Hc || (Hc = 1, (function(r) {
            var e = r, t = Yr(), n = Mn(), a = cu();
            e.assert = n, e.toArray = a.toArray, e.zero2 = a.zero2, e.toHex = a.toHex, e.encode = a.encode;
            function i(h, g, v) {
                var w = new Array(Math.max(h.bitLength(), v) + 1), E;
                for(E = 0; E < w.length; E += 1)w[E] = 0;
                var x = 1 << g + 1, S = h.clone();
                for(E = 0; E < w.length; E++){
                    var y, A = S.andln(x - 1);
                    S.isOdd() ? (A > (x >> 1) - 1 ? y = (x >> 1) - A : y = A, S.isubn(y)) : y = 0, w[E] = y, S.iushrn(1);
                }
                return w;
            }
            e.getNAF = i;
            function s(h, g) {
                var v = [
                    [],
                    []
                ];
                h = h.clone(), g = g.clone();
                for(var w = 0, E = 0, x; h.cmpn(-w) > 0 || g.cmpn(-E) > 0;){
                    var S = h.andln(3) + w & 3, y = g.andln(3) + E & 3;
                    S === 3 && (S = -1), y === 3 && (y = -1);
                    var A;
                    (S & 1) === 0 ? A = 0 : (x = h.andln(7) + w & 7, (x === 3 || x === 5) && y === 2 ? A = -S : A = S), v[0].push(A);
                    var P;
                    (y & 1) === 0 ? P = 0 : (x = g.andln(7) + E & 7, (x === 3 || x === 5) && S === 2 ? P = -y : P = y), v[1].push(P), 2 * w === A + 1 && (w = 1 - w), 2 * E === P + 1 && (E = 1 - E), h.iushrn(1), g.iushrn(1);
                }
                return v;
            }
            e.getJSF = s;
            function o(h, g, v) {
                var w = "_" + g;
                h.prototype[g] = function() {
                    return this[w] !== void 0 ? this[w] : this[w] = v.call(this);
                };
            }
            e.cachedProperty = o;
            function f(h) {
                return typeof h == "string" ? e.toArray(h, "hex") : h;
            }
            e.parseBytes = f;
            function c(h) {
                return new t(h, "hex", "le");
            }
            e.intFromLE = c;
        })(hs)), hs;
    }
    var Ti = {
        exports: {}
    }, zc;
    function du() {
        if (zc) return Ti.exports;
        zc = 1;
        var r;
        Ti.exports = function(a) {
            return r || (r = new e(null)), r.generate(a);
        };
        function e(n) {
            this.rand = n;
        }
        if (Ti.exports.Rand = e, e.prototype.generate = function(a) {
            return this._rand(a);
        }, e.prototype._rand = function(a) {
            if (this.rand.getBytes) return this.rand.getBytes(a);
            for(var i = new Uint8Array(a), s = 0; s < i.length; s++)i[s] = this.rand.getByte();
            return i;
        }, typeof self == "object") self.crypto && self.crypto.getRandomValues ? e.prototype._rand = function(a) {
            var i = new Uint8Array(a);
            return self.crypto.getRandomValues(i), i;
        } : self.msCrypto && self.msCrypto.getRandomValues ? e.prototype._rand = function(a) {
            var i = new Uint8Array(a);
            return self.msCrypto.getRandomValues(i), i;
        } : typeof window == "object" && (e.prototype._rand = function() {
            throw new Error("Not implemented yet");
        });
        else try {
            var t = cf;
            if (typeof t.randomBytes != "function") throw new Error("Not supported");
            e.prototype._rand = function(a) {
                return t.randomBytes(a);
            };
        } catch  {}
        return Ti.exports;
    }
    var ps = {}, gs, Wc;
    function Sa() {
        if (Wc) return gs;
        Wc = 1;
        var r = Yr(), e = yr(), t = e.getNAF, n = e.getJSF, a = e.assert;
        function i(o, f) {
            this.type = o, this.p = new r(f.p, 16), this.red = f.prime ? r.red(f.prime) : r.mont(this.p), this.zero = new r(0).toRed(this.red), this.one = new r(1).toRed(this.red), this.two = new r(2).toRed(this.red), this.n = f.n && new r(f.n, 16), this.g = f.g && this.pointFromJSON(f.g, f.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 c = this.n && this.p.div(this.n);
            !c || c.cmpn(100) > 0 ? this.redN = null : (this._maxwellTrick = !0, this.redN = this.n.toRed(this.red));
        }
        gs = i, i.prototype.point = function() {
            throw new Error("Not implemented");
        }, i.prototype.validate = function() {
            throw new Error("Not implemented");
        }, i.prototype._fixedNafMul = function(f, c) {
            a(f.precomputed);
            var h = f._getDoubles(), g = t(c, 1, this._bitLength), v = (1 << h.step + 1) - (h.step % 2 === 0 ? 2 : 1);
            v /= 3;
            var w = [], E, x;
            for(E = 0; E < g.length; E += h.step){
                x = 0;
                for(var S = E + h.step - 1; S >= E; S--)x = (x << 1) + g[S];
                w.push(x);
            }
            for(var y = this.jpoint(null, null, null), A = this.jpoint(null, null, null), P = v; P > 0; P--){
                for(E = 0; E < w.length; E++)x = w[E], x === P ? A = A.mixedAdd(h.points[E]) : x === -P && (A = A.mixedAdd(h.points[E].neg()));
                y = y.add(A);
            }
            return y.toP();
        }, i.prototype._wnafMul = function(f, c) {
            var h = 4, g = f._getNAFPoints(h);
            h = g.wnd;
            for(var v = g.points, w = t(c, h, this._bitLength), E = this.jpoint(null, null, null), x = w.length - 1; x >= 0; x--){
                for(var S = 0; x >= 0 && w[x] === 0; x--)S++;
                if (x >= 0 && S++, E = E.dblp(S), x < 0) break;
                var y = w[x];
                a(y !== 0), f.type === "affine" ? y > 0 ? E = E.mixedAdd(v[y - 1 >> 1]) : E = E.mixedAdd(v[-y - 1 >> 1].neg()) : y > 0 ? E = E.add(v[y - 1 >> 1]) : E = E.add(v[-y - 1 >> 1].neg());
            }
            return f.type === "affine" ? E.toP() : E;
        }, i.prototype._wnafMulAdd = function(f, c, h, g, v) {
            var w = this._wnafT1, E = this._wnafT2, x = this._wnafT3, S = 0, y, A, P;
            for(y = 0; y < g; y++){
                P = c[y];
                var N = P._getNAFPoints(f);
                w[y] = N.wnd, E[y] = N.points;
            }
            for(y = g - 1; y >= 1; y -= 2){
                var k = y - 1, D = y;
                if (w[k] !== 1 || w[D] !== 1) {
                    x[k] = t(h[k], w[k], this._bitLength), x[D] = t(h[D], w[D], this._bitLength), S = Math.max(x[k].length, S), S = Math.max(x[D].length, S);
                    continue;
                }
                var V = [
                    c[k],
                    null,
                    null,
                    c[D]
                ];
                c[k].y.cmp(c[D].y) === 0 ? (V[1] = c[k].add(c[D]), V[2] = c[k].toJ().mixedAdd(c[D].neg())) : c[k].y.cmp(c[D].y.redNeg()) === 0 ? (V[1] = c[k].toJ().mixedAdd(c[D]), V[2] = c[k].add(c[D].neg())) : (V[1] = c[k].toJ().mixedAdd(c[D]), V[2] = c[k].toJ().mixedAdd(c[D].neg()));
                var K = [
                    -3,
                    -1,
                    -5,
                    -7,
                    0,
                    7,
                    5,
                    1,
                    3
                ], j = n(h[k], h[D]);
                for(S = Math.max(j[0].length, S), x[k] = new Array(S), x[D] = new Array(S), A = 0; A < S; A++){
                    var H = j[0][A] | 0, O = j[1][A] | 0;
                    x[k][A] = K[(H + 1) * 3 + (O + 1)], x[D][A] = 0, E[k] = V;
                }
            }
            var d = this.jpoint(null, null, null), l = this._wnafT4;
            for(y = S; y >= 0; y--){
                for(var b = 0; y >= 0;){
                    var m = !0;
                    for(A = 0; A < g; A++)l[A] = x[A][y] | 0, l[A] !== 0 && (m = !1);
                    if (!m) break;
                    b++, y--;
                }
                if (y >= 0 && b++, d = d.dblp(b), y < 0) break;
                for(A = 0; A < g; A++){
                    var _ = l[A];
                    _ !== 0 && (_ > 0 ? P = E[A][_ - 1 >> 1] : _ < 0 && (P = E[A][-_ - 1 >> 1].neg()), P.type === "affine" ? d = d.mixedAdd(P) : d = d.add(P));
                }
            }
            for(y = 0; y < g; y++)E[y] = null;
            return v ? d : d.toP();
        };
        function s(o, f) {
            this.curve = o, this.type = f, this.precomputed = null;
        }
        return i.BasePoint = s, s.prototype.eq = function() {
            throw new Error("Not implemented");
        }, s.prototype.validate = function() {
            return this.curve.validate(this);
        }, i.prototype.decodePoint = function(f, c) {
            f = e.toArray(f, c);
            var h = this.p.byteLength();
            if ((f[0] === 4 || f[0] === 6 || f[0] === 7) && f.length - 1 === 2 * h) {
                f[0] === 6 ? a(f[f.length - 1] % 2 === 0) : f[0] === 7 && a(f[f.length - 1] % 2 === 1);
                var g = this.point(f.slice(1, 1 + h), f.slice(1 + h, 1 + 2 * h));
                return g;
            } else if ((f[0] === 2 || f[0] === 3) && f.length - 1 === h) return this.pointFromX(f.slice(1, 1 + h), f[0] === 3);
            throw new Error("Unknown point format");
        }, s.prototype.encodeCompressed = function(f) {
            return this.encode(f, !0);
        }, s.prototype._encode = function(f) {
            var c = this.curve.p.byteLength(), h = this.getX().toArray("be", c);
            return f ? [
                this.getY().isEven() ? 2 : 3
            ].concat(h) : [
                4
            ].concat(h, this.getY().toArray("be", c));
        }, s.prototype.encode = function(f, c) {
            return e.encode(this._encode(c), f);
        }, s.prototype.precompute = function(f) {
            if (this.precomputed) return this;
            var c = {
                doubles: null,
                naf: null,
                beta: null
            };
            return c.naf = this._getNAFPoints(8), c.doubles = this._getDoubles(4, f), c.beta = this._getBeta(), this.precomputed = c, this;
        }, s.prototype._hasDoubles = function(f) {
            if (!this.precomputed) return !1;
            var c = this.precomputed.doubles;
            return c ? c.points.length >= Math.ceil((f.bitLength() + 1) / c.step) : !1;
        }, s.prototype._getDoubles = function(f, c) {
            if (this.precomputed && this.precomputed.doubles) return this.precomputed.doubles;
            for(var h = [
                this
            ], g = this, v = 0; v < c; v += f){
                for(var w = 0; w < f; w++)g = g.dbl();
                h.push(g);
            }
            return {
                step: f,
                points: h
            };
        }, s.prototype._getNAFPoints = function(f) {
            if (this.precomputed && this.precomputed.naf) return this.precomputed.naf;
            for(var c = [
                this
            ], h = (1 << f) - 1, g = h === 1 ? null : this.dbl(), v = 1; v < h; v++)c[v] = c[v - 1].add(g);
            return {
                wnd: f,
                points: c
            };
        }, s.prototype._getBeta = function() {
            return null;
        }, s.prototype.dblp = function(f) {
            for(var c = this, h = 0; h < f; h++)c = c.dbl();
            return c;
        }, gs;
    }
    var ys, Yc;
    function Kb() {
        if (Yc) return ys;
        Yc = 1;
        var r = yr(), e = Yr(), t = ma(), n = Sa(), a = r.assert;
        function i(f) {
            n.call(this, "short", f), this.a = new e(f.a, 16).toRed(this.red), this.b = new e(f.b, 16).toRed(this.red), this.tinv = this.two.redInvm(), this.zeroA = this.a.fromRed().cmpn(0) === 0, this.threeA = this.a.fromRed().sub(this.p).cmpn(-3) === 0, this.endo = this._getEndomorphism(f), this._endoWnafT1 = new Array(4), this._endoWnafT2 = new Array(4);
        }
        t(i, n), ys = i, i.prototype._getEndomorphism = function(c) {
            if (!(!this.zeroA || !this.g || !this.n || this.p.modn(3) !== 1)) {
                var h, g;
                if (c.beta) h = new e(c.beta, 16).toRed(this.red);
                else {
                    var v = this._getEndoRoots(this.p);
                    h = v[0].cmp(v[1]) < 0 ? v[0] : v[1], h = h.toRed(this.red);
                }
                if (c.lambda) g = new e(c.lambda, 16);
                else {
                    var w = this._getEndoRoots(this.n);
                    this.g.mul(w[0]).x.cmp(this.g.x.redMul(h)) === 0 ? g = w[0] : (g = w[1], a(this.g.mul(g).x.cmp(this.g.x.redMul(h)) === 0));
                }
                var E;
                return c.basis ? E = c.basis.map(function(x) {
                    return {
                        a: new e(x.a, 16),
                        b: new e(x.b, 16)
                    };
                }) : E = this._getEndoBasis(g), {
                    beta: h,
                    lambda: g,
                    basis: E
                };
            }
        }, i.prototype._getEndoRoots = function(c) {
            var h = c === this.p ? this.red : e.mont(c), g = new e(2).toRed(h).redInvm(), v = g.redNeg(), w = new e(3).toRed(h).redNeg().redSqrt().redMul(g), E = v.redAdd(w).fromRed(), x = v.redSub(w).fromRed();
            return [
                E,
                x
            ];
        }, i.prototype._getEndoBasis = function(c) {
            for(var h = this.n.ushrn(Math.floor(this.n.bitLength() / 2)), g = c, v = this.n.clone(), w = new e(1), E = new e(0), x = new e(0), S = new e(1), y, A, P, N, k, D, V, K = 0, j, H; g.cmpn(0) !== 0;){
                var O = v.div(g);
                j = v.sub(O.mul(g)), H = x.sub(O.mul(w));
                var d = S.sub(O.mul(E));
                if (!P && j.cmp(h) < 0) y = V.neg(), A = w, P = j.neg(), N = H;
                else if (P && ++K === 2) break;
                V = j, v = g, g = j, x = w, w = H, S = E, E = d;
            }
            k = j.neg(), D = H;
            var l = P.sqr().add(N.sqr()), b = k.sqr().add(D.sqr());
            return b.cmp(l) >= 0 && (k = y, D = A), P.negative && (P = P.neg(), N = N.neg()), k.negative && (k = k.neg(), D = D.neg()), [
                {
                    a: P,
                    b: N
                },
                {
                    a: k,
                    b: D
                }
            ];
        }, i.prototype._endoSplit = function(c) {
            var h = this.endo.basis, g = h[0], v = h[1], w = v.b.mul(c).divRound(this.n), E = g.b.neg().mul(c).divRound(this.n), x = w.mul(g.a), S = E.mul(v.a), y = w.mul(g.b), A = E.mul(v.b), P = c.sub(x).sub(S), N = y.add(A).neg();
            return {
                k1: P,
                k2: N
            };
        }, i.prototype.pointFromX = function(c, h) {
            c = new e(c, 16), c.red || (c = c.toRed(this.red));
            var g = c.redSqr().redMul(c).redIAdd(c.redMul(this.a)).redIAdd(this.b), v = g.redSqrt();
            if (v.redSqr().redSub(g).cmp(this.zero) !== 0) throw new Error("invalid point");
            var w = v.fromRed().isOdd();
            return (h && !w || !h && w) && (v = v.redNeg()), this.point(c, v);
        }, i.prototype.validate = function(c) {
            if (c.inf) return !0;
            var h = c.x, g = c.y, v = this.a.redMul(h), w = h.redSqr().redMul(h).redIAdd(v).redIAdd(this.b);
            return g.redSqr().redISub(w).cmpn(0) === 0;
        }, i.prototype._endoWnafMulAdd = function(c, h, g) {
            for(var v = this._endoWnafT1, w = this._endoWnafT2, E = 0; E < c.length; E++){
                var x = this._endoSplit(h[E]), S = c[E], y = S._getBeta();
                x.k1.negative && (x.k1.ineg(), S = S.neg(!0)), x.k2.negative && (x.k2.ineg(), y = y.neg(!0)), v[E * 2] = S, v[E * 2 + 1] = y, w[E * 2] = x.k1, w[E * 2 + 1] = x.k2;
            }
            for(var A = this._wnafMulAdd(1, v, w, E * 2, g), P = 0; P < E * 2; P++)v[P] = null, w[P] = null;
            return A;
        };
        function s(f, c, h, g) {
            n.BasePoint.call(this, f, "affine"), c === null && h === null ? (this.x = null, this.y = null, this.inf = !0) : (this.x = new e(c, 16), this.y = new e(h, 16), g && (this.x.forceRed(this.curve.red), this.y.forceRed(this.curve.red)), this.x.red || (this.x = this.x.toRed(this.curve.red)), this.y.red || (this.y = this.y.toRed(this.curve.red)), this.inf = !1);
        }
        t(s, n.BasePoint), i.prototype.point = function(c, h, g) {
            return new s(this, c, h, g);
        }, i.prototype.pointFromJSON = function(c, h) {
            return s.fromJSON(this, c, h);
        }, s.prototype._getBeta = function() {
            if (this.curve.endo) {
                var c = this.precomputed;
                if (c && c.beta) return c.beta;
                var h = this.curve.point(this.x.redMul(this.curve.endo.beta), this.y);
                if (c) {
                    var g = this.curve, v = function(w) {
                        return g.point(w.x.redMul(g.endo.beta), w.y);
                    };
                    c.beta = h, h.precomputed = {
                        beta: null,
                        naf: c.naf && {
                            wnd: c.naf.wnd,
                            points: c.naf.points.map(v)
                        },
                        doubles: c.doubles && {
                            step: c.doubles.step,
                            points: c.doubles.points.map(v)
                        }
                    };
                }
                return h;
            }
        }, s.prototype.toJSON = function() {
            return this.precomputed ? [
                this.x,
                this.y,
                this.precomputed && {
                    doubles: this.precomputed.doubles && {
                        step: this.precomputed.doubles.step,
                        points: this.precomputed.doubles.points.slice(1)
                    },
                    naf: this.precomputed.naf && {
                        wnd: this.precomputed.naf.wnd,
                        points: this.precomputed.naf.points.slice(1)
                    }
                }
            ] : [
                this.x,
                this.y
            ];
        }, s.fromJSON = function(c, h, g) {
            typeof h == "string" && (h = JSON.parse(h));
            var v = c.point(h[0], h[1], g);
            if (!h[2]) return v;
            function w(x) {
                return c.point(x[0], x[1], g);
            }
            var E = h[2];
            return v.precomputed = {
                beta: null,
                doubles: E.doubles && {
                    step: E.doubles.step,
                    points: [
                        v
                    ].concat(E.doubles.points.map(w))
                },
                naf: E.naf && {
                    wnd: E.naf.wnd,
                    points: [
                        v
                    ].concat(E.naf.points.map(w))
                }
            }, v;
        }, s.prototype.inspect = function() {
            return this.isInfinity() ? "<EC Point Infinity>" : "<EC Point x: " + this.x.fromRed().toString(16, 2) + " y: " + this.y.fromRed().toString(16, 2) + ">";
        }, s.prototype.isInfinity = function() {
            return this.inf;
        }, s.prototype.add = function(c) {
            if (this.inf) return c;
            if (c.inf) return this;
            if (this.eq(c)) return this.dbl();
            if (this.neg().eq(c)) return this.curve.point(null, null);
            if (this.x.cmp(c.x) === 0) return this.curve.point(null, null);
            var h = this.y.redSub(c.y);
            h.cmpn(0) !== 0 && (h = h.redMul(this.x.redSub(c.x).redInvm()));
            var g = h.redSqr().redISub(this.x).redISub(c.x), v = h.redMul(this.x.redSub(g)).redISub(this.y);
            return this.curve.point(g, v);
        }, s.prototype.dbl = function() {
            if (this.inf) return this;
            var c = this.y.redAdd(this.y);
            if (c.cmpn(0) === 0) return this.curve.point(null, null);
            var h = this.curve.a, g = this.x.redSqr(), v = c.redInvm(), w = g.redAdd(g).redIAdd(g).redIAdd(h).redMul(v), E = w.redSqr().redISub(this.x.redAdd(this.x)), x = w.redMul(this.x.redSub(E)).redISub(this.y);
            return this.curve.point(E, x);
        }, s.prototype.getX = function() {
            return this.x.fromRed();
        }, s.prototype.getY = function() {
            return this.y.fromRed();
        }, s.prototype.mul = function(c) {
            return c = new e(c, 16), this.isInfinity() ? this : this._hasDoubles(c) ? this.curve._fixedNafMul(this, c) : this.curve.endo ? this.curve._endoWnafMulAdd([
                this
            ], [
                c
            ]) : this.curve._wnafMul(this, c);
        }, s.prototype.mulAdd = function(c, h, g) {
            var v = [
                this,
                h
            ], w = [
                c,
                g
            ];
            return this.curve.endo ? this.curve._endoWnafMulAdd(v, w) : this.curve._wnafMulAdd(1, v, w, 2);
        }, s.prototype.jmulAdd = function(c, h, g) {
            var v = [
                this,
                h
            ], w = [
                c,
                g
            ];
            return this.curve.endo ? this.curve._endoWnafMulAdd(v, w, !0) : this.curve._wnafMulAdd(1, v, w, 2, !0);
        }, s.prototype.eq = function(c) {
            return this === c || this.inf === c.inf && (this.inf || this.x.cmp(c.x) === 0 && this.y.cmp(c.y) === 0);
        }, s.prototype.neg = function(c) {
            if (this.inf) return this;
            var h = this.curve.point(this.x, this.y.redNeg());
            if (c && this.precomputed) {
                var g = this.precomputed, v = function(w) {
                    return w.neg();
                };
                h.precomputed = {
                    naf: g.naf && {
                        wnd: g.naf.wnd,
                        points: g.naf.points.map(v)
                    },
                    doubles: g.doubles && {
                        step: g.doubles.step,
                        points: g.doubles.points.map(v)
                    }
                };
            }
            return h;
        }, s.prototype.toJ = function() {
            if (this.inf) return this.curve.jpoint(null, null, null);
            var c = this.curve.jpoint(this.x, this.y, this.curve.one);
            return c;
        };
        function o(f, c, h, g) {
            n.BasePoint.call(this, f, "jacobian"), c === null && h === null && g === null ? (this.x = this.curve.one, this.y = this.curve.one, this.z = new e(0)) : (this.x = new e(c, 16), this.y = new e(h, 16), this.z = new e(g, 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;
        }
        return t(o, n.BasePoint), i.prototype.jpoint = function(c, h, g) {
            return new o(this, c, h, g);
        }, o.prototype.toP = function() {
            if (this.isInfinity()) return this.curve.point(null, null);
            var c = this.z.redInvm(), h = c.redSqr(), g = this.x.redMul(h), v = this.y.redMul(h).redMul(c);
            return this.curve.point(g, v);
        }, o.prototype.neg = function() {
            return this.curve.jpoint(this.x, this.y.redNeg(), this.z);
        }, o.prototype.add = function(c) {
            if (this.isInfinity()) return c;
            if (c.isInfinity()) return this;
            var h = c.z.redSqr(), g = this.z.redSqr(), v = this.x.redMul(h), w = c.x.redMul(g), E = this.y.redMul(h.redMul(c.z)), x = c.y.redMul(g.redMul(this.z)), S = v.redSub(w), y = E.redSub(x);
            if (S.cmpn(0) === 0) return y.cmpn(0) !== 0 ? this.curve.jpoint(null, null, null) : this.dbl();
            var A = S.redSqr(), P = A.redMul(S), N = v.redMul(A), k = y.redSqr().redIAdd(P).redISub(N).redISub(N), D = y.redMul(N.redISub(k)).redISub(E.redMul(P)), V = this.z.redMul(c.z).redMul(S);
            return this.curve.jpoint(k, D, V);
        }, o.prototype.mixedAdd = function(c) {
            if (this.isInfinity()) return c.toJ();
            if (c.isInfinity()) return this;
            var h = this.z.redSqr(), g = this.x, v = c.x.redMul(h), w = this.y, E = c.y.redMul(h).redMul(this.z), x = g.redSub(v), S = w.redSub(E);
            if (x.cmpn(0) === 0) return S.cmpn(0) !== 0 ? this.curve.jpoint(null, null, null) : this.dbl();
            var y = x.redSqr(), A = y.redMul(x), P = g.redMul(y), N = S.redSqr().redIAdd(A).redISub(P).redISub(P), k = S.redMul(P.redISub(N)).redISub(w.redMul(A)), D = this.z.redMul(x);
            return this.curve.jpoint(N, k, D);
        }, o.prototype.dblp = function(c) {
            if (c === 0) return this;
            if (this.isInfinity()) return this;
            if (!c) return this.dbl();
            var h;
            if (this.curve.zeroA || this.curve.threeA) {
                var g = this;
                for(h = 0; h < c; h++)g = g.dbl();
                return g;
            }
            var v = this.curve.a, w = this.curve.tinv, E = this.x, x = this.y, S = this.z, y = S.redSqr().redSqr(), A = x.redAdd(x);
            for(h = 0; h < c; h++){
                var P = E.redSqr(), N = A.redSqr(), k = N.redSqr(), D = P.redAdd(P).redIAdd(P).redIAdd(v.redMul(y)), V = E.redMul(N), K = D.redSqr().redISub(V.redAdd(V)), j = V.redISub(K), H = D.redMul(j);
                H = H.redIAdd(H).redISub(k);
                var O = A.redMul(S);
                h + 1 < c && (y = y.redMul(k)), E = K, S = O, A = H;
            }
            return this.curve.jpoint(E, A.redMul(w), S);
        }, o.prototype.dbl = function() {
            return this.isInfinity() ? this : this.curve.zeroA ? this._zeroDbl() : this.curve.threeA ? this._threeDbl() : this._dbl();
        }, o.prototype._zeroDbl = function() {
            var c, h, g;
            if (this.zOne) {
                var v = this.x.redSqr(), w = this.y.redSqr(), E = w.redSqr(), x = this.x.redAdd(w).redSqr().redISub(v).redISub(E);
                x = x.redIAdd(x);
                var S = v.redAdd(v).redIAdd(v), y = S.redSqr().redISub(x).redISub(x), A = E.redIAdd(E);
                A = A.redIAdd(A), A = A.redIAdd(A), c = y, h = S.redMul(x.redISub(y)).redISub(A), g = this.y.redAdd(this.y);
            } else {
                var P = this.x.redSqr(), N = this.y.redSqr(), k = N.redSqr(), D = this.x.redAdd(N).redSqr().redISub(P).redISub(k);
                D = D.redIAdd(D);
                var V = P.redAdd(P).redIAdd(P), K = V.redSqr(), j = k.redIAdd(k);
                j = j.redIAdd(j), j = j.redIAdd(j), c = K.redISub(D).redISub(D), h = V.redMul(D.redISub(c)).redISub(j), g = this.y.redMul(this.z), g = g.redIAdd(g);
            }
            return this.curve.jpoint(c, h, g);
        }, o.prototype._threeDbl = function() {
            var c, h, g;
            if (this.zOne) {
                var v = this.x.redSqr(), w = this.y.redSqr(), E = w.redSqr(), x = this.x.redAdd(w).redSqr().redISub(v).redISub(E);
                x = x.redIAdd(x);
                var S = v.redAdd(v).redIAdd(v).redIAdd(this.curve.a), y = S.redSqr().redISub(x).redISub(x);
                c = y;
                var A = E.redIAdd(E);
                A = A.redIAdd(A), A = A.redIAdd(A), h = S.redMul(x.redISub(y)).redISub(A), g = this.y.redAdd(this.y);
            } else {
                var P = this.z.redSqr(), N = this.y.redSqr(), k = this.x.redMul(N), D = this.x.redSub(P).redMul(this.x.redAdd(P));
                D = D.redAdd(D).redIAdd(D);
                var V = k.redIAdd(k);
                V = V.redIAdd(V);
                var K = V.redAdd(V);
                c = D.redSqr().redISub(K), g = this.y.redAdd(this.z).redSqr().redISub(N).redISub(P);
                var j = N.redSqr();
                j = j.redIAdd(j), j = j.redIAdd(j), j = j.redIAdd(j), h = D.redMul(V.redISub(c)).redISub(j);
            }
            return this.curve.jpoint(c, h, g);
        }, o.prototype._dbl = function() {
            var c = this.curve.a, h = this.x, g = this.y, v = this.z, w = v.redSqr().redSqr(), E = h.redSqr(), x = g.redSqr(), S = E.redAdd(E).redIAdd(E).redIAdd(c.redMul(w)), y = h.redAdd(h);
            y = y.redIAdd(y);
            var A = y.redMul(x), P = S.redSqr().redISub(A.redAdd(A)), N = A.redISub(P), k = x.redSqr();
            k = k.redIAdd(k), k = k.redIAdd(k), k = k.redIAdd(k);
            var D = S.redMul(N).redISub(k), V = g.redAdd(g).redMul(v);
            return this.curve.jpoint(P, D, V);
        }, o.prototype.trpl = function() {
            if (!this.curve.zeroA) return this.dbl().add(this);
            var c = this.x.redSqr(), h = this.y.redSqr(), g = this.z.redSqr(), v = h.redSqr(), w = c.redAdd(c).redIAdd(c), E = w.redSqr(), x = this.x.redAdd(h).redSqr().redISub(c).redISub(v);
            x = x.redIAdd(x), x = x.redAdd(x).redIAdd(x), x = x.redISub(E);
            var S = x.redSqr(), y = v.redIAdd(v);
            y = y.redIAdd(y), y = y.redIAdd(y), y = y.redIAdd(y);
            var A = w.redIAdd(x).redSqr().redISub(E).redISub(S).redISub(y), P = h.redMul(A);
            P = P.redIAdd(P), P = P.redIAdd(P);
            var N = this.x.redMul(S).redISub(P);
            N = N.redIAdd(N), N = N.redIAdd(N);
            var k = this.y.redMul(A.redMul(y.redISub(A)).redISub(x.redMul(S)));
            k = k.redIAdd(k), k = k.redIAdd(k), k = k.redIAdd(k);
            var D = this.z.redAdd(x).redSqr().redISub(g).redISub(S);
            return this.curve.jpoint(N, k, D);
        }, o.prototype.mul = function(c, h) {
            return c = new e(c, h), this.curve._wnafMul(this, c);
        }, o.prototype.eq = function(c) {
            if (c.type === "affine") return this.eq(c.toJ());
            if (this === c) return !0;
            var h = this.z.redSqr(), g = c.z.redSqr();
            if (this.x.redMul(g).redISub(c.x.redMul(h)).cmpn(0) !== 0) return !1;
            var v = h.redMul(this.z), w = g.redMul(c.z);
            return this.y.redMul(w).redISub(c.y.redMul(v)).cmpn(0) === 0;
        }, o.prototype.eqXToP = function(c) {
            var h = this.z.redSqr(), g = c.toRed(this.curve.red).redMul(h);
            if (this.x.cmp(g) === 0) return !0;
            for(var v = c.clone(), w = this.curve.redN.redMul(h);;){
                if (v.iadd(this.curve.n), v.cmp(this.curve.p) >= 0) return !1;
                if (g.redIAdd(w), this.x.cmp(g) === 0) return !0;
            }
        }, o.prototype.inspect = function() {
            return this.isInfinity() ? "<EC JPoint Infinity>" : "<EC JPoint x: " + this.x.toString(16, 2) + " y: " + this.y.toString(16, 2) + " z: " + this.z.toString(16, 2) + ">";
        }, o.prototype.isInfinity = function() {
            return this.z.cmpn(0) === 0;
        }, ys;
    }
    var vs, Vc;
    function jb() {
        if (Vc) return vs;
        Vc = 1;
        var r = Yr(), e = ma(), t = Sa(), n = yr();
        function a(s) {
            t.call(this, "mont", s), this.a = new r(s.a, 16).toRed(this.red), this.b = new r(s.b, 16).toRed(this.red), this.i4 = new r(4).toRed(this.red).redInvm(), this.two = new r(2).toRed(this.red), this.a24 = this.i4.redMul(this.a.redAdd(this.two));
        }
        e(a, t), vs = a, a.prototype.validate = function(o) {
            var f = o.normalize().x, c = f.redSqr(), h = c.redMul(f).redAdd(c.redMul(this.a)).redAdd(f), g = h.redSqrt();
            return g.redSqr().cmp(h) === 0;
        };
        function i(s, o, f) {
            t.BasePoint.call(this, s, "projective"), o === null && f === null ? (this.x = this.curve.one, this.z = this.curve.zero) : (this.x = new r(o, 16), this.z = new r(f, 16), this.x.red || (this.x = this.x.toRed(this.curve.red)), this.z.red || (this.z = this.z.toRed(this.curve.red)));
        }
        return e(i, t.BasePoint), a.prototype.decodePoint = function(o, f) {
            return this.point(n.toArray(o, f), 1);
        }, a.prototype.point = function(o, f) {
            return new i(this, o, f);
        }, a.prototype.pointFromJSON = function(o) {
            return i.fromJSON(this, o);
        }, i.prototype.precompute = function() {}, i.prototype._encode = function() {
            return this.getX().toArray("be", this.curve.p.byteLength());
        }, i.fromJSON = function(o, f) {
            return new i(o, f[0], f[1] || o.one);
        }, i.prototype.inspect = function() {
            return this.isInfinity() ? "<EC Point Infinity>" : "<EC Point x: " + this.x.fromRed().toString(16, 2) + " z: " + this.z.fromRed().toString(16, 2) + ">";
        }, i.prototype.isInfinity = function() {
            return this.z.cmpn(0) === 0;
        }, i.prototype.dbl = function() {
            var o = this.x.redAdd(this.z), f = o.redSqr(), c = this.x.redSub(this.z), h = c.redSqr(), g = f.redSub(h), v = f.redMul(h), w = g.redMul(h.redAdd(this.curve.a24.redMul(g)));
            return this.curve.point(v, w);
        }, i.prototype.add = function() {
            throw new Error("Not supported on Montgomery curve");
        }, i.prototype.diffAdd = function(o, f) {
            var c = this.x.redAdd(this.z), h = this.x.redSub(this.z), g = o.x.redAdd(o.z), v = o.x.redSub(o.z), w = v.redMul(c), E = g.redMul(h), x = f.z.redMul(w.redAdd(E).redSqr()), S = f.x.redMul(w.redISub(E).redSqr());
            return this.curve.point(x, S);
        }, i.prototype.mul = function(o) {
            for(var f = o.clone(), c = this, h = this.curve.point(null, null), g = this, v = []; f.cmpn(0) !== 0; f.iushrn(1))v.push(f.andln(1));
            for(var w = v.length - 1; w >= 0; w--)v[w] === 0 ? (c = c.diffAdd(h, g), h = h.dbl()) : (h = c.diffAdd(h, g), c = c.dbl());
            return h;
        }, i.prototype.mulAdd = function() {
            throw new Error("Not supported on Montgomery curve");
        }, i.prototype.jumlAdd = function() {
            throw new Error("Not supported on Montgomery curve");
        }, i.prototype.eq = function(o) {
            return this.getX().cmp(o.getX()) === 0;
        }, i.prototype.normalize = function() {
            return this.x = this.x.redMul(this.z.redInvm()), this.z = this.curve.one, this;
        }, i.prototype.getX = function() {
            return this.normalize(), this.x.fromRed();
        }, vs;
    }
    var ms, Gc;
    function Hb() {
        if (Gc) return ms;
        Gc = 1;
        var r = yr(), e = Yr(), t = ma(), n = Sa(), a = r.assert;
        function i(o) {
            this.twisted = (o.a | 0) !== 1, this.mOneA = this.twisted && (o.a | 0) === -1, this.extended = this.mOneA, n.call(this, "edwards", o), this.a = new e(o.a, 16).umod(this.red.m), this.a = this.a.toRed(this.red), this.c = new e(o.c, 16).toRed(this.red), this.c2 = this.c.redSqr(), this.d = new e(o.d, 16).toRed(this.red), this.dd = this.d.redAdd(this.d), a(!this.twisted || this.c.fromRed().cmpn(1) === 0), this.oneC = (o.c | 0) === 1;
        }
        t(i, n), ms = i, i.prototype._mulA = function(f) {
            return this.mOneA ? f.redNeg() : this.a.redMul(f);
        }, i.prototype._mulC = function(f) {
            return this.oneC ? f : this.c.redMul(f);
        }, i.prototype.jpoint = function(f, c, h, g) {
            return this.point(f, c, h, g);
        }, i.prototype.pointFromX = function(f, c) {
            f = new e(f, 16), f.red || (f = f.toRed(this.red));
            var h = f.redSqr(), g = this.c2.redSub(this.a.redMul(h)), v = this.one.redSub(this.c2.redMul(this.d).redMul(h)), w = g.redMul(v.redInvm()), E = w.redSqrt();
            if (E.redSqr().redSub(w).cmp(this.zero) !== 0) throw new Error("invalid point");
            var x = E.fromRed().isOdd();
            return (c && !x || !c && x) && (E = E.redNeg()), this.point(f, E);
        }, i.prototype.pointFromY = function(f, c) {
            f = new e(f, 16), f.red || (f = f.toRed(this.red));
            var h = f.redSqr(), g = h.redSub(this.c2), v = h.redMul(this.d).redMul(this.c2).redSub(this.a), w = g.redMul(v.redInvm());
            if (w.cmp(this.zero) === 0) {
                if (c) throw new Error("invalid point");
                return this.point(this.zero, f);
            }
            var E = w.redSqrt();
            if (E.redSqr().redSub(w).cmp(this.zero) !== 0) throw new Error("invalid point");
            return E.fromRed().isOdd() !== c && (E = E.redNeg()), this.point(E, f);
        }, i.prototype.validate = function(f) {
            if (f.isInfinity()) return !0;
            f.normalize();
            var c = f.x.redSqr(), h = f.y.redSqr(), g = c.redMul(this.a).redAdd(h), v = this.c2.redMul(this.one.redAdd(this.d.redMul(c).redMul(h)));
            return g.cmp(v) === 0;
        };
        function s(o, f, c, h, g) {
            n.BasePoint.call(this, o, "projective"), f === null && c === null && h === 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 e(f, 16), this.y = new e(c, 16), this.z = h ? new e(h, 16) : this.curve.one, this.t = g && new e(g, 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()))));
        }
        return t(s, n.BasePoint), i.prototype.pointFromJSON = function(f) {
            return s.fromJSON(this, f);
        }, i.prototype.point = function(f, c, h, g) {
            return new s(this, f, c, h, g);
        }, s.fromJSON = function(f, c) {
            return new s(f, c[0], c[1], c[2]);
        }, s.prototype.inspect = function() {
            return this.isInfinity() ? "<EC Point Infinity>" : "<EC Point x: " + this.x.fromRed().toString(16, 2) + " y: " + this.y.fromRed().toString(16, 2) + " z: " + this.z.fromRed().toString(16, 2) + ">";
        }, s.prototype.isInfinity = function() {
            return this.x.cmpn(0) === 0 && (this.y.cmp(this.z) === 0 || this.zOne && this.y.cmp(this.curve.c) === 0);
        }, s.prototype._extDbl = function() {
            var f = this.x.redSqr(), c = this.y.redSqr(), h = this.z.redSqr();
            h = h.redIAdd(h);
            var g = this.curve._mulA(f), v = this.x.redAdd(this.y).redSqr().redISub(f).redISub(c), w = g.redAdd(c), E = w.redSub(h), x = g.redSub(c), S = v.redMul(E), y = w.redMul(x), A = v.redMul(x), P = E.redMul(w);
            return this.curve.point(S, y, P, A);
        }, s.prototype._projDbl = function() {
            var f = this.x.redAdd(this.y).redSqr(), c = this.x.redSqr(), h = this.y.redSqr(), g, v, w, E, x, S;
            if (this.curve.twisted) {
                E = this.curve._mulA(c);
                var y = E.redAdd(h);
                this.zOne ? (g = f.redSub(c).redSub(h).redMul(y.redSub(this.curve.two)), v = y.redMul(E.redSub(h)), w = y.redSqr().redSub(y).redSub(y)) : (x = this.z.redSqr(), S = y.redSub(x).redISub(x), g = f.redSub(c).redISub(h).redMul(S), v = y.redMul(E.redSub(h)), w = y.redMul(S));
            } else E = c.redAdd(h), x = this.curve._mulC(this.z).redSqr(), S = E.redSub(x).redSub(x), g = this.curve._mulC(f.redISub(E)).redMul(S), v = this.curve._mulC(E).redMul(c.redISub(h)), w = E.redMul(S);
            return this.curve.point(g, v, w);
        }, s.prototype.dbl = function() {
            return this.isInfinity() ? this : this.curve.extended ? this._extDbl() : this._projDbl();
        }, s.prototype._extAdd = function(f) {
            var c = this.y.redSub(this.x).redMul(f.y.redSub(f.x)), h = this.y.redAdd(this.x).redMul(f.y.redAdd(f.x)), g = this.t.redMul(this.curve.dd).redMul(f.t), v = this.z.redMul(f.z.redAdd(f.z)), w = h.redSub(c), E = v.redSub(g), x = v.redAdd(g), S = h.redAdd(c), y = w.redMul(E), A = x.redMul(S), P = w.redMul(S), N = E.redMul(x);
            return this.curve.point(y, A, N, P);
        }, s.prototype._projAdd = function(f) {
            var c = this.z.redMul(f.z), h = c.redSqr(), g = this.x.redMul(f.x), v = this.y.redMul(f.y), w = this.curve.d.redMul(g).redMul(v), E = h.redSub(w), x = h.redAdd(w), S = this.x.redAdd(this.y).redMul(f.x.redAdd(f.y)).redISub(g).redISub(v), y = c.redMul(E).redMul(S), A, P;
            return this.curve.twisted ? (A = c.redMul(x).redMul(v.redSub(this.curve._mulA(g))), P = E.redMul(x)) : (A = c.redMul(x).redMul(v.redSub(g)), P = this.curve._mulC(E).redMul(x)), this.curve.point(y, A, P);
        }, s.prototype.add = function(f) {
            return this.isInfinity() ? f : f.isInfinity() ? this : this.curve.extended ? this._extAdd(f) : this._projAdd(f);
        }, s.prototype.mul = function(f) {
            return this._hasDoubles(f) ? this.curve._fixedNafMul(this, f) : this.curve._wnafMul(this, f);
        }, s.prototype.mulAdd = function(f, c, h) {
            return this.curve._wnafMulAdd(1, [
                this,
                c
            ], [
                f,
                h
            ], 2, !1);
        }, s.prototype.jmulAdd = function(f, c, h) {
            return this.curve._wnafMulAdd(1, [
                this,
                c
            ], [
                f,
                h
            ], 2, !0);
        }, s.prototype.normalize = function() {
            if (this.zOne) return this;
            var f = this.z.redInvm();
            return this.x = this.x.redMul(f), this.y = this.y.redMul(f), this.t && (this.t = this.t.redMul(f)), this.z = this.curve.one, this.zOne = !0, this;
        }, s.prototype.neg = function() {
            return this.curve.point(this.x.redNeg(), this.y, this.z, this.t && this.t.redNeg());
        }, s.prototype.getX = function() {
            return this.normalize(), this.x.fromRed();
        }, s.prototype.getY = function() {
            return this.normalize(), this.y.fromRed();
        }, s.prototype.eq = function(f) {
            return this === f || this.getX().cmp(f.getX()) === 0 && this.getY().cmp(f.getY()) === 0;
        }, s.prototype.eqXToP = function(f) {
            var c = f.toRed(this.curve.red).redMul(this.z);
            if (this.x.cmp(c) === 0) return !0;
            for(var h = f.clone(), g = this.curve.redN.redMul(this.z);;){
                if (h.iadd(this.curve.n), h.cmp(this.curve.p) >= 0) return !1;
                if (c.redIAdd(g), this.x.cmp(c) === 0) return !0;
            }
        }, s.prototype.toP = s.prototype.normalize, s.prototype.mixedAdd = s.prototype.add, ms;
    }
    var Jc;
    function uu() {
        return Jc || (Jc = 1, (function(r) {
            var e = r;
            e.base = Sa(), e.short = Kb(), e.mont = jb(), e.edwards = Hb();
        })(ps)), ps;
    }
    var ws = {}, xs, Xc;
    function zb() {
        return Xc || (Xc = 1, xs = {
            doubles: {
                step: 4,
                points: [
                    [
                        "e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a",
                        "f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"
                    ],
                    [
                        "8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508",
                        "11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"
                    ],
                    [
                        "175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739",
                        "d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"
                    ],
                    [
                        "363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640",
                        "4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"
                    ],
                    [
                        "8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c",
                        "4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"
                    ],
                    [
                        "723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda",
                        "96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"
                    ],
                    [
                        "eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa",
                        "5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"
                    ],
                    [
                        "100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0",
                        "cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"
                    ],
                    [
                        "e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d",
                        "9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"
                    ],
                    [
                        "feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d",
                        "e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"
                    ],
                    [
                        "da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1",
                        "9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"
                    ],
                    [
                        "53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0",
                        "5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"
                    ],
                    [
                        "8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047",
                        "10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"
                    ],
                    [
                        "385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862",
                        "283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"
                    ],
                    [
                        "6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7",
                        "7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"
                    ],
                    [
                        "3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd",
                        "56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"
                    ],
                    [
                        "85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83",
                        "7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"
                    ],
                    [
                        "948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a",
                        "53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"
                    ],
                    [
                        "6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8",
                        "bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"
                    ],
                    [
                        "e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d",
                        "4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"
                    ],
                    [
                        "e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725",
                        "7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"
                    ],
                    [
                        "213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754",
                        "4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"
                    ],
                    [
                        "4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c",
                        "17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"
                    ],
                    [
                        "fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6",
                        "6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"
                    ],
                    [
                        "76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39",
                        "c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"
                    ],
                    [
                        "c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891",
                        "893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"
                    ],
                    [
                        "d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b",
                        "febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"
                    ],
                    [
                        "b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03",
                        "2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"
                    ],
                    [
                        "e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d",
                        "eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"
                    ],
                    [
                        "a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070",
                        "7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"
                    ],
                    [
                        "90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4",
                        "e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"
                    ],
                    [
                        "8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da",
                        "662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"
                    ],
                    [
                        "e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11",
                        "1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"
                    ],
                    [
                        "8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e",
                        "efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"
                    ],
                    [
                        "e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41",
                        "2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"
                    ],
                    [
                        "b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef",
                        "67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"
                    ],
                    [
                        "d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8",
                        "db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"
                    ],
                    [
                        "324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d",
                        "648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"
                    ],
                    [
                        "4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96",
                        "35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"
                    ],
                    [
                        "9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd",
                        "ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"
                    ],
                    [
                        "6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5",
                        "9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"
                    ],
                    [
                        "a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266",
                        "40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"
                    ],
                    [
                        "7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71",
                        "34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"
                    ],
                    [
                        "928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac",
                        "c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"
                    ],
                    [
                        "85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751",
                        "1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"
                    ],
                    [
                        "ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e",
                        "493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"
                    ],
                    [
                        "827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241",
                        "c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"
                    ],
                    [
                        "eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3",
                        "be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"
                    ],
                    [
                        "e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f",
                        "4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"
                    ],
                    [
                        "1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19",
                        "aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"
                    ],
                    [
                        "146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be",
                        "b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"
                    ],
                    [
                        "fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9",
                        "6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"
                    ],
                    [
                        "da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2",
                        "8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"
                    ],
                    [
                        "a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13",
                        "7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"
                    ],
                    [
                        "174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c",
                        "ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"
                    ],
                    [
                        "959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba",
                        "2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"
                    ],
                    [
                        "d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151",
                        "e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"
                    ],
                    [
                        "64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073",
                        "d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"
                    ],
                    [
                        "8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458",
                        "38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"
                    ],
                    [
                        "13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b",
                        "69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"
                    ],
                    [
                        "bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366",
                        "d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"
                    ],
                    [
                        "8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa",
                        "40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"
                    ],
                    [
                        "8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0",
                        "620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"
                    ],
                    [
                        "dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787",
                        "7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"
                    ],
                    [
                        "f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e",
                        "ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"
                    ]
                ]
            },
            naf: {
                wnd: 7,
                points: [
                    [
                        "f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9",
                        "388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"
                    ],
                    [
                        "2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4",
                        "d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"
                    ],
                    [
                        "5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc",
                        "6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"
                    ],
                    [
                        "acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe",
                        "cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"
                    ],
                    [
                        "774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb",
                        "d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"
                    ],
                    [
                        "f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8",
                        "ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"
                    ],
                    [
                        "d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e",
                        "581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"
                    ],
                    [
                        "defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34",
                        "4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"
                    ],
                    [
                        "2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c",
                        "85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"
                    ],
                    [
                        "352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5",
                        "321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"
                    ],
                    [
                        "2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f",
                        "2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"
                    ],
                    [
                        "9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714",
                        "73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"
                    ],
                    [
                        "daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729",
                        "a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"
                    ],
                    [
                        "c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db",
                        "2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"
                    ],
                    [
                        "6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4",
                        "e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"
                    ],
                    [
                        "1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5",
                        "b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"
                    ],
                    [
                        "605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479",
                        "2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"
                    ],
                    [
                        "62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d",
                        "80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"
                    ],
                    [
                        "80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f",
                        "1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"
                    ],
                    [
                        "7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb",
                        "d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"
                    ],
                    [
                        "d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9",
                        "eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"
                    ],
                    [
                        "49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963",
                        "758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"
                    ],
                    [
                        "77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74",
                        "958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"
                    ],
                    [
                        "f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530",
                        "e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"
                    ],
                    [
                        "463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b",
                        "5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"
                    ],
                    [
                        "f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247",
                        "cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"
                    ],
                    [
                        "caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1",
                        "cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"
                    ],
                    [
                        "2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120",
                        "4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"
                    ],
                    [
                        "7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435",
                        "91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"
                    ],
                    [
                        "754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18",
                        "673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"
                    ],
                    [
                        "e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8",
                        "59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"
                    ],
                    [
                        "186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb",
                        "3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"
                    ],
                    [
                        "df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f",
                        "55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"
                    ],
                    [
                        "5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143",
                        "efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"
                    ],
                    [
                        "290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba",
                        "e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"
                    ],
                    [
                        "af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45",
                        "f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"
                    ],
                    [
                        "766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a",
                        "744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"
                    ],
                    [
                        "59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e",
                        "c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"
                    ],
                    [
                        "f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8",
                        "e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"
                    ],
                    [
                        "7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c",
                        "30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"
                    ],
                    [
                        "948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519",
                        "e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"
                    ],
                    [
                        "7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab",
                        "100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"
                    ],
                    [
                        "3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca",
                        "ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"
                    ],
                    [
                        "d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf",
                        "8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"
                    ],
                    [
                        "1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610",
                        "68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"
                    ],
                    [
                        "733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4",
                        "f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"
                    ],
                    [
                        "15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c",
                        "d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"
                    ],
                    [
                        "a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940",
                        "edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"
                    ],
                    [
                        "e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980",
                        "a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"
                    ],
                    [
                        "311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3",
                        "66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"
                    ],
                    [
                        "34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf",
                        "9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"
                    ],
                    [
                        "f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63",
                        "4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"
                    ],
                    [
                        "d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448",
                        "fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"
                    ],
                    [
                        "32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf",
                        "5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"
                    ],
                    [
                        "7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5",
                        "8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"
                    ],
                    [
                        "ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6",
                        "8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"
                    ],
                    [
                        "16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5",
                        "5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"
                    ],
                    [
                        "eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99",
                        "f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"
                    ],
                    [
                        "78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51",
                        "f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"
                    ],
                    [
                        "494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5",
                        "42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"
                    ],
                    [
                        "a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5",
                        "204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"
                    ],
                    [
                        "c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997",
                        "4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"
                    ],
                    [
                        "841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881",
                        "73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"
                    ],
                    [
                        "5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5",
                        "39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"
                    ],
                    [
                        "36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66",
                        "d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"
                    ],
                    [
                        "336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726",
                        "ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"
                    ],
                    [
                        "8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede",
                        "6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"
                    ],
                    [
                        "1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94",
                        "60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"
                    ],
                    [
                        "85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31",
                        "3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"
                    ],
                    [
                        "29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51",
                        "b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"
                    ],
                    [
                        "a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252",
                        "ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"
                    ],
                    [
                        "4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5",
                        "cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"
                    ],
                    [
                        "d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b",
                        "6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"
                    ],
                    [
                        "ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4",
                        "322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"
                    ],
                    [
                        "af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f",
                        "6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"
                    ],
                    [
                        "e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889",
                        "2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"
                    ],
                    [
                        "591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246",
                        "b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"
                    ],
                    [
                        "11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984",
                        "998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"
                    ],
                    [
                        "3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a",
                        "b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"
                    ],
                    [
                        "cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030",
                        "bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"
                    ],
                    [
                        "c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197",
                        "6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"
                    ],
                    [
                        "c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593",
                        "c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"
                    ],
                    [
                        "a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef",
                        "21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"
                    ],
                    [
                        "347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38",
                        "60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"
                    ],
                    [
                        "da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a",
                        "49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"
                    ],
                    [
                        "c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111",
                        "5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"
                    ],
                    [
                        "4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502",
                        "7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"
                    ],
                    [
                        "3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea",
                        "be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"
                    ],
                    [
                        "cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26",
                        "8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"
                    ],
                    [
                        "b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986",
                        "39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"
                    ],
                    [
                        "d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e",
                        "62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"
                    ],
                    [
                        "48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4",
                        "25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"
                    ],
                    [
                        "dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda",
                        "ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"
                    ],
                    [
                        "6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859",
                        "cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"
                    ],
                    [
                        "e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f",
                        "f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"
                    ],
                    [
                        "eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c",
                        "6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"
                    ],
                    [
                        "13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942",
                        "fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"
                    ],
                    [
                        "ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a",
                        "1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"
                    ],
                    [
                        "b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80",
                        "5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"
                    ],
                    [
                        "ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d",
                        "438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"
                    ],
                    [
                        "8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1",
                        "cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"
                    ],
                    [
                        "52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63",
                        "c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"
                    ],
                    [
                        "e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352",
                        "6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"
                    ],
                    [
                        "7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193",
                        "ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"
                    ],
                    [
                        "5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00",
                        "9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"
                    ],
                    [
                        "32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58",
                        "ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"
                    ],
                    [
                        "e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7",
                        "d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"
                    ],
                    [
                        "8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8",
                        "c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"
                    ],
                    [
                        "4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e",
                        "67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"
                    ],
                    [
                        "3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d",
                        "cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"
                    ],
                    [
                        "674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b",
                        "299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"
                    ],
                    [
                        "d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f",
                        "f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"
                    ],
                    [
                        "30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6",
                        "462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"
                    ],
                    [
                        "be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297",
                        "62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"
                    ],
                    [
                        "93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a",
                        "7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"
                    ],
                    [
                        "b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c",
                        "ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"
                    ],
                    [
                        "d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52",
                        "4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"
                    ],
                    [
                        "d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb",
                        "bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"
                    ],
                    [
                        "463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065",
                        "bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"
                    ],
                    [
                        "7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917",
                        "603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"
                    ],
                    [
                        "74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9",
                        "cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"
                    ],
                    [
                        "30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3",
                        "553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"
                    ],
                    [
                        "9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57",
                        "712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"
                    ],
                    [
                        "176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66",
                        "ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"
                    ],
                    [
                        "75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8",
                        "9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"
                    ],
                    [
                        "809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721",
                        "9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"
                    ],
                    [
                        "1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180",
                        "4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"
                    ]
                ]
            }
        }), xs;
    }
    var Zc;
    function yf() {
        return Zc || (Zc = 1, (function(r) {
            var e = r, t = _a(), n = uu(), a = yr(), i = a.assert;
            function s(c) {
                c.type === "short" ? this.curve = new n.short(c) : c.type === "edwards" ? this.curve = new n.edwards(c) : this.curve = new n.mont(c), this.g = this.curve.g, this.n = this.curve.n, this.hash = c.hash, i(this.g.validate(), "Invalid curve"), i(this.g.mul(this.n).isInfinity(), "Invalid curve, G*N != O");
            }
            e.PresetCurve = s;
            function o(c, h) {
                Object.defineProperty(e, c, {
                    configurable: !0,
                    enumerable: !0,
                    get: function() {
                        var g = new s(h);
                        return Object.defineProperty(e, c, {
                            configurable: !0,
                            enumerable: !0,
                            value: g
                        }), g;
                    }
                });
            }
            o("p192", {
                type: "short",
                prime: "p192",
                p: "ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",
                a: "ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",
                b: "64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",
                n: "ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",
                hash: t.sha256,
                gRed: !1,
                g: [
                    "188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012",
                    "07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"
                ]
            }), o("p224", {
                type: "short",
                prime: "p224",
                p: "ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",
                a: "ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",
                b: "b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",
                n: "ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",
                hash: t.sha256,
                gRed: !1,
                g: [
                    "b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21",
                    "bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"
                ]
            }), o("p256", {
                type: "short",
                prime: null,
                p: "ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",
                a: "ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",
                b: "5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",
                n: "ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",
                hash: t.sha256,
                gRed: !1,
                g: [
                    "6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296",
                    "4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"
                ]
            }), o("p384", {
                type: "short",
                prime: null,
                p: "ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",
                a: "ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",
                b: "b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",
                n: "ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",
                hash: t.sha384,
                gRed: !1,
                g: [
                    "aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7",
                    "3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"
                ]
            }), o("p521", {
                type: "short",
                prime: null,
                p: "000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",
                a: "000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",
                b: "00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",
                n: "000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",
                hash: t.sha512,
                gRed: !1,
                g: [
                    "000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66",
                    "00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"
                ]
            }), o("curve25519", {
                type: "mont",
                prime: "p25519",
                p: "7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",
                a: "76d06",
                b: "1",
                n: "1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",
                hash: t.sha256,
                gRed: !1,
                g: [
                    "9"
                ]
            }), o("ed25519", {
                type: "edwards",
                prime: "p25519",
                p: "7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",
                a: "-1",
                c: "1",
                d: "52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",
                n: "1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",
                hash: t.sha256,
                gRed: !1,
                g: [
                    "216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a",
                    "6666666666666666666666666666666666666666666666666666666666666658"
                ]
            });
            var f;
            try {
                f = zb();
            } catch  {
                f = void 0;
            }
            o("secp256k1", {
                type: "short",
                prime: "k256",
                p: "ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",
                a: "0",
                b: "7",
                n: "ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",
                h: "1",
                hash: t.sha256,
                beta: "7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",
                lambda: "5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",
                basis: [
                    {
                        a: "3086d221a7d46bcde86c90e49284eb15",
                        b: "-e4437ed6010e88286f547fa90abfe4c3"
                    },
                    {
                        a: "114ca50f7a8e2f3f657c1108d9d44cfd8",
                        b: "3086d221a7d46bcde86c90e49284eb15"
                    }
                ],
                gRed: !1,
                g: [
                    "79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798",
                    "483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",
                    f
                ]
            });
        })(ws)), ws;
    }
    var _s, Qc;
    function Wb() {
        if (Qc) return _s;
        Qc = 1;
        var r = _a(), e = cu(), t = Mn();
        function n(a) {
            if (!(this instanceof n)) return new n(a);
            this.hash = a.hash, this.predResist = !!a.predResist, this.outLen = this.hash.outSize, this.minEntropy = a.minEntropy || this.hash.hmacStrength, this._reseed = null, this.reseedInterval = null, this.K = null, this.V = null;
            var i = e.toArray(a.entropy, a.entropyEnc || "hex"), s = e.toArray(a.nonce, a.nonceEnc || "hex"), o = e.toArray(a.pers, a.persEnc || "hex");
            t(i.length >= this.minEntropy / 8, "Not enough entropy. Minimum is: " + this.minEntropy + " bits"), this._init(i, s, o);
        }
        return _s = n, n.prototype._init = function(i, s, o) {
            var f = i.concat(s).concat(o);
            this.K = new Array(this.outLen / 8), this.V = new Array(this.outLen / 8);
            for(var c = 0; c < this.V.length; c++)this.K[c] = 0, this.V[c] = 1;
            this._update(f), this._reseed = 1, this.reseedInterval = 281474976710656;
        }, n.prototype._hmac = function() {
            return new r.hmac(this.hash, this.K);
        }, n.prototype._update = function(i) {
            var s = this._hmac().update(this.V).update([
                0
            ]);
            i && (s = s.update(i)), this.K = s.digest(), this.V = this._hmac().update(this.V).digest(), i && (this.K = this._hmac().update(this.V).update([
                1
            ]).update(i).digest(), this.V = this._hmac().update(this.V).digest());
        }, n.prototype.reseed = function(i, s, o, f) {
            typeof s != "string" && (f = o, o = s, s = null), i = e.toArray(i, s), o = e.toArray(o, f), t(i.length >= this.minEntropy / 8, "Not enough entropy. Minimum is: " + this.minEntropy + " bits"), this._update(i.concat(o || [])), this._reseed = 1;
        }, n.prototype.generate = function(i, s, o, f) {
            if (this._reseed > this.reseedInterval) throw new Error("Reseed is required");
            typeof s != "string" && (f = o, o = s, s = null), o && (o = e.toArray(o, f || "hex"), this._update(o));
            for(var c = []; c.length < i;)this.V = this._hmac().update(this.V).digest(), c = c.concat(this.V);
            var h = c.slice(0, i);
            return this._update(o), this._reseed++, e.encode(h, s);
        }, _s;
    }
    var Ss, ed;
    function Yb() {
        if (ed) return Ss;
        ed = 1;
        var r = Yr(), e = yr(), t = e.assert;
        function n(a, i) {
            this.ec = a, this.priv = null, this.pub = null, i.priv && this._importPrivate(i.priv, i.privEnc), i.pub && this._importPublic(i.pub, i.pubEnc);
        }
        return Ss = n, n.fromPublic = function(i, s, o) {
            return s instanceof n ? s : new n(i, {
                pub: s,
                pubEnc: o
            });
        }, n.fromPrivate = function(i, s, o) {
            return s instanceof n ? s : new n(i, {
                priv: s,
                privEnc: o
            });
        }, n.prototype.validate = function() {
            var i = this.getPublic();
            return i.isInfinity() ? {
                result: !1,
                reason: "Invalid public key"
            } : i.validate() ? i.mul(this.ec.curve.n).isInfinity() ? {
                result: !0,
                reason: null
            } : {
                result: !1,
                reason: "Public key * N != O"
            } : {
                result: !1,
                reason: "Public key is not a point"
            };
        }, n.prototype.getPublic = function(i, s) {
            return typeof i == "string" && (s = i, i = null), this.pub || (this.pub = this.ec.g.mul(this.priv)), s ? this.pub.encode(s, i) : this.pub;
        }, n.prototype.getPrivate = function(i) {
            return i === "hex" ? this.priv.toString(16, 2) : this.priv;
        }, n.prototype._importPrivate = function(i, s) {
            this.priv = new r(i, s || 16), this.priv = this.priv.umod(this.ec.curve.n);
        }, n.prototype._importPublic = function(i, s) {
            if (i.x || i.y) {
                this.ec.curve.type === "mont" ? t(i.x, "Need x coordinate") : (this.ec.curve.type === "short" || this.ec.curve.type === "edwards") && t(i.x && i.y, "Need both x and y coordinate"), this.pub = this.ec.curve.point(i.x, i.y);
                return;
            }
            this.pub = this.ec.curve.decodePoint(i, s);
        }, n.prototype.derive = function(i) {
            return i.validate() || t(i.validate(), "public point not validated"), i.mul(this.priv).getX();
        }, n.prototype.sign = function(i, s, o) {
            return this.ec.sign(i, this, s, o);
        }, n.prototype.verify = function(i, s, o) {
            return this.ec.verify(i, s, this, void 0, o);
        }, n.prototype.inspect = function() {
            return "<Key priv: " + (this.priv && this.priv.toString(16, 2)) + " pub: " + (this.pub && this.pub.inspect()) + " >";
        }, Ss;
    }
    var Es, td;
    function Vb() {
        if (td) return Es;
        td = 1;
        var r = Yr(), e = yr(), t = e.assert;
        function n(f, c) {
            if (f instanceof n) return f;
            this._importDER(f, c) || (t(f.r && f.s, "Signature without r or s"), this.r = new r(f.r, 16), this.s = new r(f.s, 16), f.recoveryParam === void 0 ? this.recoveryParam = null : this.recoveryParam = f.recoveryParam);
        }
        Es = n;
        function a() {
            this.place = 0;
        }
        function i(f, c) {
            var h = f[c.place++];
            if (!(h & 128)) return h;
            var g = h & 15;
            if (g === 0 || g > 4 || f[c.place] === 0) return !1;
            for(var v = 0, w = 0, E = c.place; w < g; w++, E++)v <<= 8, v |= f[E], v >>>= 0;
            return v <= 127 ? !1 : (c.place = E, v);
        }
        function s(f) {
            for(var c = 0, h = f.length - 1; !f[c] && !(f[c + 1] & 128) && c < h;)c++;
            return c === 0 ? f : f.slice(c);
        }
        n.prototype._importDER = function(c, h) {
            c = e.toArray(c, h);
            var g = new a;
            if (c[g.place++] !== 48) return !1;
            var v = i(c, g);
            if (v === !1 || v + g.place !== c.length || c[g.place++] !== 2) return !1;
            var w = i(c, g);
            if (w === !1 || (c[g.place] & 128) !== 0) return !1;
            var E = c.slice(g.place, w + g.place);
            if (g.place += w, c[g.place++] !== 2) return !1;
            var x = i(c, g);
            if (x === !1 || c.length !== x + g.place || (c[g.place] & 128) !== 0) return !1;
            var S = c.slice(g.place, x + g.place);
            if (E[0] === 0) if (E[1] & 128) E = E.slice(1);
            else return !1;
            if (S[0] === 0) if (S[1] & 128) S = S.slice(1);
            else return !1;
            return this.r = new r(E), this.s = new r(S), this.recoveryParam = null, !0;
        };
        function o(f, c) {
            if (c < 128) {
                f.push(c);
                return;
            }
            var h = 1 + (Math.log(c) / Math.LN2 >>> 3);
            for(f.push(h | 128); --h;)f.push(c >>> (h << 3) & 255);
            f.push(c);
        }
        return n.prototype.toDER = function(c) {
            var h = this.r.toArray(), g = this.s.toArray();
            for(h[0] & 128 && (h = [
                0
            ].concat(h)), g[0] & 128 && (g = [
                0
            ].concat(g)), h = s(h), g = s(g); !g[0] && !(g[1] & 128);)g = g.slice(1);
            var v = [
                2
            ];
            o(v, h.length), v = v.concat(h), v.push(2), o(v, g.length);
            var w = v.concat(g), E = [
                48
            ];
            return o(E, w.length), E = E.concat(w), e.encode(E, c);
        }, Es;
    }
    var As, rd;
    function Gb() {
        if (rd) return As;
        rd = 1;
        var r = Yr(), e = Wb(), t = yr(), n = yf(), a = du(), i = t.assert, s = Yb(), o = Vb();
        function f(c) {
            if (!(this instanceof f)) return new f(c);
            typeof c == "string" && (i(Object.prototype.hasOwnProperty.call(n, c), "Unknown curve " + c), c = n[c]), c instanceof n.PresetCurve && (c = {
                curve: c
            }), this.curve = c.curve.curve, this.n = this.curve.n, this.nh = this.n.ushrn(1), this.g = this.curve.g, this.g = c.curve.g, this.g.precompute(c.curve.n.bitLength() + 1), this.hash = c.hash || c.curve.hash;
        }
        return As = f, f.prototype.keyPair = function(h) {
            return new s(this, h);
        }, f.prototype.keyFromPrivate = function(h, g) {
            return s.fromPrivate(this, h, g);
        }, f.prototype.keyFromPublic = function(h, g) {
            return s.fromPublic(this, h, g);
        }, f.prototype.genKeyPair = function(h) {
            h || (h = {});
            for(var g = new e({
                hash: this.hash,
                pers: h.pers,
                persEnc: h.persEnc || "utf8",
                entropy: h.entropy || a(this.hash.hmacStrength),
                entropyEnc: h.entropy && h.entropyEnc || "utf8",
                nonce: this.n.toArray()
            }), v = this.n.byteLength(), w = this.n.sub(new r(2));;){
                var E = new r(g.generate(v));
                if (!(E.cmp(w) > 0)) return E.iaddn(1), this.keyFromPrivate(E);
            }
        }, f.prototype._truncateToN = function(h, g, v) {
            var w;
            if (r.isBN(h) || typeof h == "number") h = new r(h, 16), w = h.byteLength();
            else if (typeof h == "object") w = h.length, h = new r(h, 16);
            else {
                var E = h.toString();
                w = E.length + 1 >>> 1, h = new r(E, 16);
            }
            typeof v != "number" && (v = w * 8);
            var x = v - this.n.bitLength();
            return x > 0 && (h = h.ushrn(x)), !g && h.cmp(this.n) >= 0 ? h.sub(this.n) : h;
        }, f.prototype.sign = function(h, g, v, w) {
            if (typeof v == "object" && (w = v, v = null), w || (w = {}), typeof h != "string" && typeof h != "number" && !r.isBN(h)) {
                i(typeof h == "object" && h && typeof h.length == "number", "Expected message to be an array-like, a hex string, or a BN instance"), i(h.length >>> 0 === h.length);
                for(var E = 0; E < h.length; E++)i((h[E] & 255) === h[E]);
            }
            g = this.keyFromPrivate(g, v), h = this._truncateToN(h, !1, w.msgBitLength), i(!h.isNeg(), "Can not sign a negative message");
            var x = this.n.byteLength(), S = g.getPrivate().toArray("be", x), y = h.toArray("be", x);
            i(new r(y).eq(h), "Can not sign message");
            for(var A = new e({
                hash: this.hash,
                entropy: S,
                nonce: y,
                pers: w.pers,
                persEnc: w.persEnc || "utf8"
            }), P = this.n.sub(new r(1)), N = 0;; N++){
                var k = w.k ? w.k(N) : new r(A.generate(this.n.byteLength()));
                if (k = this._truncateToN(k, !0), !(k.cmpn(1) <= 0 || k.cmp(P) >= 0)) {
                    var D = this.g.mul(k);
                    if (!D.isInfinity()) {
                        var V = D.getX(), K = V.umod(this.n);
                        if (K.cmpn(0) !== 0) {
                            var j = k.invm(this.n).mul(K.mul(g.getPrivate()).iadd(h));
                            if (j = j.umod(this.n), j.cmpn(0) !== 0) {
                                var H = (D.getY().isOdd() ? 1 : 0) | (V.cmp(K) !== 0 ? 2 : 0);
                                return w.canonical && j.cmp(this.nh) > 0 && (j = this.n.sub(j), H ^= 1), new o({
                                    r: K,
                                    s: j,
                                    recoveryParam: H
                                });
                            }
                        }
                    }
                }
            }
        }, f.prototype.verify = function(h, g, v, w, E) {
            E || (E = {}), h = this._truncateToN(h, !1, E.msgBitLength), v = this.keyFromPublic(v, w), g = new o(g, "hex");
            var x = g.r, S = g.s;
            if (x.cmpn(1) < 0 || x.cmp(this.n) >= 0 || S.cmpn(1) < 0 || S.cmp(this.n) >= 0) return !1;
            var y = S.invm(this.n), A = y.mul(h).umod(this.n), P = y.mul(x).umod(this.n), N;
            return this.curve._maxwellTrick ? (N = this.g.jmulAdd(A, v.getPublic(), P), N.isInfinity() ? !1 : N.eqXToP(x)) : (N = this.g.mulAdd(A, v.getPublic(), P), N.isInfinity() ? !1 : N.getX().umod(this.n).cmp(x) === 0);
        }, f.prototype.recoverPubKey = function(c, h, g, v) {
            i((3 & g) === g, "The recovery param is more than two bits"), h = new o(h, v);
            var w = this.n, E = new r(c), x = h.r, S = h.s, y = g & 1, A = g >> 1;
            if (x.cmp(this.curve.p.umod(this.curve.n)) >= 0 && A) throw new Error("Unable to find sencond key candinate");
            A ? x = this.curve.pointFromX(x.add(this.curve.n), y) : x = this.curve.pointFromX(x, y);
            var P = h.r.invm(w), N = w.sub(E).mul(P).umod(w), k = S.mul(P).umod(w);
            return this.g.mulAdd(N, x, k);
        }, f.prototype.getKeyRecoveryParam = function(c, h, g, v) {
            if (h = new o(h, v), h.recoveryParam !== null) return h.recoveryParam;
            for(var w = 0; w < 4; w++){
                var E;
                try {
                    E = this.recoverPubKey(c, h, w);
                } catch  {
                    continue;
                }
                if (E.eq(g)) return w;
            }
            throw new Error("Unable to find valid recovery factor");
        }, As;
    }
    var Is, nd;
    function Jb() {
        if (nd) return Is;
        nd = 1;
        var r = yr(), e = r.assert, t = r.parseBytes, n = r.cachedProperty;
        function a(i, s) {
            this.eddsa = i, this._secret = t(s.secret), i.isPoint(s.pub) ? this._pub = s.pub : this._pubBytes = t(s.pub);
        }
        return a.fromPublic = function(s, o) {
            return o instanceof a ? o : new a(s, {
                pub: o
            });
        }, a.fromSecret = function(s, o) {
            return o instanceof a ? o : new a(s, {
                secret: o
            });
        }, a.prototype.secret = function() {
            return this._secret;
        }, n(a, "pubBytes", function() {
            return this.eddsa.encodePoint(this.pub());
        }), n(a, "pub", function() {
            return this._pubBytes ? this.eddsa.decodePoint(this._pubBytes) : this.eddsa.g.mul(this.priv());
        }), n(a, "privBytes", function() {
            var s = this.eddsa, o = this.hash(), f = s.encodingLength - 1, c = o.slice(0, s.encodingLength);
            return c[0] &= 248, c[f] &= 127, c[f] |= 64, c;
        }), n(a, "priv", function() {
            return this.eddsa.decodeInt(this.privBytes());
        }), n(a, "hash", function() {
            return this.eddsa.hash().update(this.secret()).digest();
        }), n(a, "messagePrefix", function() {
            return this.hash().slice(this.eddsa.encodingLength);
        }), a.prototype.sign = function(s) {
            return e(this._secret, "KeyPair can only verify"), this.eddsa.sign(s, this);
        }, a.prototype.verify = function(s, o) {
            return this.eddsa.verify(s, o, this);
        }, a.prototype.getSecret = function(s) {
            return e(this._secret, "KeyPair is public only"), r.encode(this.secret(), s);
        }, a.prototype.getPublic = function(s) {
            return r.encode(this.pubBytes(), s);
        }, Is = a, Is;
    }
    var Ms, id;
    function Xb() {
        if (id) return Ms;
        id = 1;
        var r = Yr(), e = yr(), t = e.assert, n = e.cachedProperty, a = e.parseBytes;
        function i(s, o) {
            this.eddsa = s, typeof o != "object" && (o = a(o)), Array.isArray(o) && (t(o.length === s.encodingLength * 2, "Signature has invalid size"), o = {
                R: o.slice(0, s.encodingLength),
                S: o.slice(s.encodingLength)
            }), t(o.R && o.S, "Signature without R or S"), s.isPoint(o.R) && (this._R = o.R), o.S instanceof r && (this._S = o.S), this._Rencoded = Array.isArray(o.R) ? o.R : o.Rencoded, this._Sencoded = Array.isArray(o.S) ? o.S : o.Sencoded;
        }
        return n(i, "S", function() {
            return this.eddsa.decodeInt(this.Sencoded());
        }), n(i, "R", function() {
            return this.eddsa.decodePoint(this.Rencoded());
        }), n(i, "Rencoded", function() {
            return this.eddsa.encodePoint(this.R());
        }), n(i, "Sencoded", function() {
            return this.eddsa.encodeInt(this.S());
        }), i.prototype.toBytes = function() {
            return this.Rencoded().concat(this.Sencoded());
        }, i.prototype.toHex = function() {
            return e.encode(this.toBytes(), "hex").toUpperCase();
        }, Ms = i, Ms;
    }
    var Rs, ad;
    function Zb() {
        if (ad) return Rs;
        ad = 1;
        var r = _a(), e = yf(), t = yr(), n = t.assert, a = t.parseBytes, i = Jb(), s = Xb();
        function o(f) {
            if (n(f === "ed25519", "only tested with ed25519 so far"), !(this instanceof o)) return new o(f);
            f = e[f].curve, this.curve = f, this.g = f.g, this.g.precompute(f.n.bitLength() + 1), this.pointClass = f.point().constructor, this.encodingLength = Math.ceil(f.n.bitLength() / 8), this.hash = r.sha512;
        }
        return Rs = o, o.prototype.sign = function(c, h) {
            c = a(c);
            var g = this.keyFromSecret(h), v = this.hashInt(g.messagePrefix(), c), w = this.g.mul(v), E = this.encodePoint(w), x = this.hashInt(E, g.pubBytes(), c).mul(g.priv()), S = v.add(x).umod(this.curve.n);
            return this.makeSignature({
                R: w,
                S,
                Rencoded: E
            });
        }, o.prototype.verify = function(c, h, g) {
            if (c = a(c), h = this.makeSignature(h), h.S().gte(h.eddsa.curve.n) || h.S().isNeg()) return !1;
            var v = this.keyFromPublic(g), w = this.hashInt(h.Rencoded(), v.pubBytes(), c), E = this.g.mul(h.S()), x = h.R().add(v.pub().mul(w));
            return x.eq(E);
        }, o.prototype.hashInt = function() {
            for(var c = this.hash(), h = 0; h < arguments.length; h++)c.update(arguments[h]);
            return t.intFromLE(c.digest()).umod(this.curve.n);
        }, o.prototype.keyFromPublic = function(c) {
            return i.fromPublic(this, c);
        }, o.prototype.keyFromSecret = function(c) {
            return i.fromSecret(this, c);
        }, o.prototype.makeSignature = function(c) {
            return c instanceof s ? c : new s(this, c);
        }, o.prototype.encodePoint = function(c) {
            var h = c.getY().toArray("le", this.encodingLength);
            return h[this.encodingLength - 1] |= c.getX().isOdd() ? 128 : 0, h;
        }, o.prototype.decodePoint = function(c) {
            c = t.parseBytes(c);
            var h = c.length - 1, g = c.slice(0, h).concat(c[h] & -129), v = (c[h] & 128) !== 0, w = t.intFromLE(g);
            return this.curve.pointFromY(w, v);
        }, o.prototype.encodeInt = function(c) {
            return c.toArray("le", this.encodingLength);
        }, o.prototype.decodeInt = function(c) {
            return t.intFromLE(c);
        }, o.prototype.isPoint = function(c) {
            return c instanceof this.pointClass;
        }, Rs;
    }
    var sd;
    function Qb() {
        return sd || (sd = 1, (function(r) {
            var e = r;
            e.version = Fb.version, e.utils = yr(), e.rand = du(), e.curve = uu(), e.curves = yf(), e.ec = Gb(), e.eddsa = Zb();
        })(ls)), ls;
    }
    var un = Qb();
    const lu = [
        [
            "49ee3eba8c1600700ee1b87eb599f16716b0b1022947733551fde4050ca6804",
            "3ca0cfe4b3bc6ddf346d49d06ea0ed34e621062c0e056c1d0405d266e10268a"
        ],
        [
            "1ef15c18599971b7beced415a40f0c7deacfd9b0d1819e03d723d8bc943cfca",
            "5668060aa49730b7be4801df46ec62de53ecd11abe43a32873000c36e8dc1f"
        ],
        [
            "234287dcbaffe7f969c748655fca9e58fa8120b6d56eb0c1080d17957ebe47b",
            "3b056f100f96fb21e889527d41f4e39940135dd7a6c94cc6ed0268ee89e5615"
        ],
        [
            "3909690e1123c80678a7ba0fde0e8447f6f02b3f6b960034d1e93524f8b476",
            "7122e9063d239d89d4e336753845b76f2b33ca0d7f0c1acd4b9fe974994cc19"
        ],
        [
            "40fd002e38ea01a01b2702eb7c643e9decc2894cbf31765922e281939ab542c",
            "109f720a79e2a41471f054ca885efd90c8cfbbec37991d1b6343991e0a3e740"
        ],
        [
            "2f52066635c139fc2f64eb0bd5e3fd7a705f576854ec4f00aa60361fddb981b",
            "6d78a24d8a5f97fc600318ce16b3c840315979c3273078ec1a285f217ee6a26"
        ],
        [
            "6a0767a1fd60d5b9027a35af1b68e57a1c366ebcde2006cdd07af27043ef674",
            "606b72c0ca0498b8c1817ed7922d550894c324f5efdfc85a19a1ae382411ca2"
        ],
        [
            "7fa463ee2a2d6a585d5c3358918270f6c28c66df1f86803374d1edf3819cc62",
            "a996edf01598832e644e1cae9a37288865ad80e2787f9bf958aceccc99afae"
        ],
        [
            "3d4da70d1540da597dbae1651d28487604a4e66a4a1823b97e8e9639393dbec",
            "45cdef70c35d3b6f0a2273a9886ccb6306d813e8204bdfd30b4efee63c8a3f9"
        ],
        [
            "1e448fdbcd9896c6fbf5f36cb7e7fcb77a751ff2d942593cae023363cc7750e",
            "30c81da0f3a8cb64468eaa491c7ae7b4842b62cb4148820da211afc4caffb3a"
        ],
        [
            "6531acf1a7cb90a4eb27de0b7f915e387a3b0fd063ba6e1289b91f48411be26",
            "31330f5daa091889981a3ea782ae997f5f171336ed0487a03f051551a2cafa2"
        ],
        [
            "54be016394d5662d67d7e82f5e889ed2f97ccf95d911f57dd2362c4040ed4f4",
            "c6cb184053f054d6a59c1bf0986d17090d25089b3fdcdaf185edc87ef113e5"
        ],
        [
            "35b9ecd0499ca1d5d42dcbb0c6b4042b3733c64b607ca711e706e786ef2afc6",
            "5624b476a5b21c3a544f0712d4817b06ad380a5a6529d323bf64da8ef862d8d"
        ],
        [
            "4ce0378e3ee8f77ed58f2ddbd8bb7676c8a38bfb1d3694c275254bd8ca38e23",
            "5a16fcbff0769c9cf2b02c31621878ec819fff4b8231bff82c6183db2746820"
        ],
        [
            "648d5c6f98680a1b926bfeb01c00224c56fdcf751b251c4449c8a94f425cfcf",
            "72c05ac793cd1620a833fbe2214d36900ebe446e095c62fcb740937f98cca8c"
        ],
        [
            "bd09be3e4e1af8a14189977e334f097c18e4a8bf42577ef5aafa0f807bd89b",
            "6e0e72ed7eb65c86cee29c411fb4761122558ee81013344ba8509c49de9f9b6"
        ],
        [
            "35ea4e339b44ae7724419bdfbe07022253137a4afb7cbaffad341ea61249357",
            "3665d676a026a174f367bb4417780e53a7803cb02d0db32eb4545c267c42f14"
        ],
        [
            "36457bc744f42e697b825c2d1afd8f4029d696a4514710f81da52d88e178643",
            "7c93715896735492a68c7969a024b3a8fd538bffc1521538107de1a5f13ce9c"
        ],
        [
            "5b3a08ebcf9c109cc9082f70d9df2b9c11b5428ee23917b4e790c4c10f6e661",
            "9d7b42ab0c20f5510df7ea5e196eec99342739077e9a168198c89da859753"
        ],
        [
            "21883ef8580fc06e59481955d52ece3aca6e82c8c9fc58e216dcf46f96990c6",
            "51a6423543e6e8a43e71da34cd90f5b520b8d33b67c4bf857573ab9e301aa4c"
        ],
        [
            "19e86b77f9b581e81092b305c852faf53940a8f15f0a6990c414f04c0fa7ef9",
            "515630e35d4398c9c79fc4ee08e1023fa47d8e03c6e7819c6d2ccef45398fa"
        ],
        [
            "888ab8eb4c31bb2ac5b54aa320dbe1a69c96b864e8a5f54d89c1d1a6b86c24",
            "730e148467f6a55ce22c5296f5380df88f38de76ef0b2de844cd3094aaaf3ea"
        ],
        [
            "75e79ff13a894e7120dac17b7429c0c32ce7828f726c9973728c0977a5f5977",
            "4960526e59c1c736561a201bc56f7d762641b39f609d273cc996f5d9197cfb8"
        ],
        [
            "640fe009249115d7254f72ecafb3006139e4bed7e9041af51458c737282d1d5",
            "3cc6c978a575246e2ce4f7ef1fcc7f63085db9ff98a1b1f3fe374087c0332c"
        ],
        [
            "6d6fd09ccab7c26de9b3906191235deb5c34685580c488275356a05e209ca96",
            "7157f81a34213dd8f91dea4f6df1bcfabc4ee091a3049eeeb3b7923d39b8645"
        ],
        [
            "5531ca1d00f151d71da820918f74caf2985b24dca20e124721fff507b5a5876",
            "518529643d3f25e47f72c322223ba60a63d6bfe78cf3f612215d9c19bf29200"
        ],
        [
            "6192d454e4f8fe212bdfccd5b15dd5056d7622ffe456c6c67e5a7265aea49c4",
            "2377a45dc630017ae863cb968ddb38333a70c7946d8684e6d7a6213f634b7bc"
        ],
        [
            "542fb44b4ef3640a64fdb22a2560fb26668065c069cf31d1df424819a39ff18",
            "5dbae9b0948e0361aea443503840341c322aa1a1366ce5390e71bf161f78f8c"
        ],
        [
            "299ff3e3412a7eb4cb4a3051b07b1be2e7b1c4b789f39ffb52cba3d048b71de",
            "1951d3175c02761b291d86b6c0a08387ad5e2a2130ccc33c852530572cb3958"
        ],
        [
            "628ce3f5367dadc1411133e55eb25e2e3c2880d6e28754a5cb1c5d109627e73",
            "ae3e9b7d50964e28bd15380400b7659b87affdef5d2586cbefcd9be7d67c0d"
        ],
        [
            "6ea54aff064895eccf9db2283225d62044ae67621192b3346338948382f5933",
            "6431507e51aadacfaf39f102a8ff387756e9b5e1bc8323d44acae55130d93db"
        ],
        [
            "28097d50d175a6235320fe8cfe138dd9e46895d189582e472c38ad7a67d923a",
            "7f9eab4133d7d09a7ff63368d6135c26262b62336eca1b5ca33f2096ce388ba"
        ],
        [
            "619fd09cdd6ff4323973f256c2cbdcb224f7f25b8aef623af2d4a0105e62e02",
            "2c95f0ae11d47eeae1bc7f1350f75f9185c5bc840382ceb38a797cae9c40308"
        ],
        [
            "641c18982ced304512a3f2395942a38add0d6a7156229c2a7c8b8dfbe9beb96",
            "6f6288c9c659b6af5ac975f4180deffe53d516399b2cc62f31732e9d4ba9837"
        ],
        [
            "58ab546e51fe49fc5a382e4064a2bd6cfc268904412f86c26de14f28a71d0f2",
            "124b7217943e7e328408e8afdfa7da00dcbc94a2bb85fd8e01fb162d2c2c0a9"
        ],
        [
            "a82c2fdedbb26c3c762a12f7e86b0e01e65320e0a25a8399d665f6e266bf74",
            "1a1de28e253f3e10f44d0111e8074f882d7f42e5900780ccbdc31da372d3fd8"
        ],
        [
            "744c725a7455a992e3cf5bd007bc234dd4668dba285f553f38350ad94c1615b",
            "7f721a87f48798bdc4a9c0eb88559e2ad7a74112fd901e70ea159e67a9c33f"
        ],
        [
            "434df142ddaa60f7881b6348d91687de40457de7ccfb07f0304b9e820705d0c",
            "7fae425e3b53f97dd1f5b20e49ed9fe24ff1efc341ba5e017ac89cf8df0cc39"
        ],
        [
            "7a1e2b809dff46277021cbc376f79c37e1b683bbd6bca5317014f0dc0e1ae73",
            "56790278a231912c334eff05281e08af1558e85516b4411ef64647c13bea431"
        ],
        [
            "4931b7990348d41cf8907be79f45bb7991fd18f8a57868351c92fa7a34cbcd7",
            "ca35091815cdf0837d396e25aad6052ad32d497a33b123256cffdc008bc50e"
        ],
        [
            "250b815d352fd89f8210b624b147ea7d0a4f47bcac49f3ac9b777840da93ebe",
            "1173f10e9691948b7da7632f328520455aadcba46e017f891e0a1d7da2bef04"
        ],
        [
            "2223b85032fa67292f6e1f822628e6756e5c3cc08fc252ab88d63d624e4dfb2",
            "55619ba96a7dcec77832fcb22cd5c21c7dcebc0280d730cba0002b67e0a8c63"
        ],
        [
            "249b131e04de73af9820d3e22492d9ec51bdc0c4c4f34d95352fa44dd61f245",
            "7576d3b5d136368ff01170a77d8286d0d1c7c40688862fb40813b4af3c6065e"
        ],
        [
            "6777915d9b4769027eb7e04733f8a2d669c84fe06080f55e8a55674dfbf9efb",
            "640d0ff384c9635e1af364760f104e058e3c86209fa9d2320aeac887b2e02d8"
        ],
        [
            "2abe3f237681052f002414399111cf07f8421535af41251edc427a36b5b19c9",
            "636ce4deaf468a503ab20ccb2f7e5bdc98551656ebf53e9c7786b11dd9090be"
        ],
        [
            "4d5cc5414758ea1be55be779bd7da296c7e11f1564d9e8797ceea347c16f8ea",
            "1a680c4c410cf5ddc74e95ff2897c193edaaecce5b2cde4e96bbae5c0054eff"
        ],
        [
            "46c375c684b30adf4d51de81e92afee52b1a3847e177403372c82109373edca",
            "1eaadc5783c90a0261306423d52009e991126b3f620e9cb6cffca41ca096f4f"
        ],
        [
            "2ddfb71f51205888118cbabba8fd07d460a810289bfdeeb7118707e310cb152",
            "1fd905d07b3933be886f2518246bdafa6f33259a174668808223cd7c28183c7"
        ],
        [
            "386f3879960713d41fdb3b1e41bbebf26b1c0e27a9a75bb1adcc1a0d3e8547b",
            "2b21498c0f34ec6f17c720334dc0f36021c2f87afbbbc8847d0bd536eb265e5"
        ],
        [
            "407eae62c6c4de3b942195afec3f45efec71ddb5e6edee3d427631bcdbf9b90",
            "436e7f2d78268ef62c4172d2ff1469028bad1f1d0f97ab007064418e61caa8f"
        ],
        [
            "1b881175e21201d17e095e9b3966b354f47de8c1acee5177f5909e0fd72328f",
            "69954b1a9b8bfccf8ec384d32924518a935758f3d3662ef754bcc88f1f6f3ec"
        ],
        [
            "7d545a82bff003b8115be32a0c437f7c0a98f776bcf7fddb0392822844f3c5e",
            "34b6e53a9565a7daa010711f5bf72254a4e61da3e6a562210a9abc9e8b66d69"
        ],
        [
            "299b9fcd4fadfc4b6141457a3036aaa68501c23df579de26df69d4def89b913",
            "b95bf2c2bb303c38bb396382edc798ca6a4847e573ce19b7b08533d1912675"
        ],
        [
            "551f5a4dae4a341a3e20336a7d2f365ddd45849351ec6dd4fcbedfe4806d5d5",
            "5865c977a0ecf13ce85ae14c5c316872080bd36f0f614f56b6dfc7ece83792e"
        ],
        [
            "7a1d69c08e68c80ad8b310736e6247a53bcba0183b9b8798833bc696a0fb6e2",
            "3ce803a20ebb3b120d5eaf0ad64bed0522fad1a0f2ce39a5c5cbae98c4438f6"
        ],
        [
            "28acacc0bc41d84e83663f02b36981a2c8272ecd72d3901164be2affb09c504",
            "7a5aee0b160eaff5b5968ab1a0304ce58c3d5ae0148d9191c39e87668229e5b"
        ],
        [
            "1f78cfdbcc767b68e69a224a077468cdfcb0afd6952b85bccbdb96d1fb8500b",
            "4772ba173c6b583284eb001cfc2a124104833f464ff9df096443e10ef3e9dd4"
        ],
        [
            "2774108962ca9897e7f22c064d2ccedac4fef5fc9569331c27cdc336c95774b",
            "9e13d79b68e8dc8091c019618f5b07283a710ddf1733dc674a99fc32c12911"
        ],
        [
            "770d116415cd2c4ace0d8b721dd77e4a2ef766591f9ec9fa0b61304548994ed",
            "42165d93c82f687635aa2b68492b3adffd516beb4baa94520efa11467a209fd"
        ],
        [
            "5e6e4ece6621e2275415e1fda1e7c4f496de498b77c0b913073c6a6099394b9",
            "3d92ce044fc77fa227adc31f6fc17ef8b4ec1c5aafc44630c0d9195075bf56d"
        ],
        [
            "6e69c717b5d98807ff1e404a5187a9ceaf0110b83aa15a84f930928b1171825",
            "1ee7cfc3a9744d7fa380ba28604af9df33ac077724374c04588bd71fa16b177"
        ],
        [
            "404318f2d2ceb44f549c80f9d7de9879d8f7da4b81e7350c00e974ebf2daef1",
            "3934831b5af70d17a3f1da9d2931bd757e6acf2893236264fc7e0d92ff1a1cb"
        ],
        [
            "20dcb6f394fea6d549b2e75748f61b7ec03b6e52319cb14163373a9c22bb9dc",
            "106a8c96cfb95a331618b7416d1498554730499e194a58fbf63019890480fc7"
        ],
        [
            "119000f277ccee013e6bb121194ec1ab5460fb6a96eb702a14079865f4170aa",
            "1737a32f5415e8720a5606ec1dd4756f02e7c6817e3723b453d091f2d192773"
        ],
        [
            "45d0fb5cd95db76d05dec3faa12e467a308eabaad363a062353db3cd2d9b749",
            "ae08691b5b0cdd19ec499132421638f470f493320e4003d123ab1da761b965"
        ],
        [
            "1257b3e65cdfb6367c6d0942327e799bc66eb221e70c6573a9862889eb51c38",
            "593309fd45755dd2cc4afd2b9316bc4638b0c5ddb3009694fcb7b250d0c8a2f"
        ],
        [
            "186dcf9950f72e868014a8accf14aa36e82a7a2a29f86ba37f6632da4189db3",
            "55684c9f7a043fc523ed78f756f834b4db823d5e4161bd79602c17d55a5cd8c"
        ],
        [
            "58791d5569f282f5c3b01ecdc9388df7ba3ca223a2dc1eed5edaf2a1d302fb9",
            "6298d7dd51561a045bb4089deda9f40b2865589ed433e56d54554f8b45e79f0"
        ],
        [
            "13fd87144aa5aa4b24d5a7bf907d8280d15937fed262d41084898cb688fc28b",
            "3fa54367770cc4479a857411ddcabe86627b405ce1cd14ad3b2863bde13abe4"
        ],
        [
            "48118139445415f0c1879224e2dee744ed35280ff00537260402a1741ec3676",
            "4dfa39dadaabecfc54ecb7a25319444f8e952782d863790e42a9887064fc0c1"
        ],
        [
            "4ad031bb9eda84f2fe5d354c7948d41558ca657a04508654721810ee72ef158",
            "620ebd5d0086b92c6009a42777b946a351c2c7ba852b57d3c9905fc337459ef"
        ],
        [
            "4a34abb016ad8cb4575ea5bd28385d2348e5bcc0cbba90059f90f9c71f86e8b",
            "4f781829ad83f9ed1e1b6de0e5f4ac60dfdfe7f23cb4411e815817e705e52c8"
        ],
        [
            "7fc632d7512aab5356b7915dca854c8b12b369ab54f524fbce352f00eb9b9f9",
            "2ce80b944fc9158005f630b34385d50c3ad84450a9e1e529925b3211dd2a1de"
        ],
        [
            "65ed10347503cbc0216ca03f7536cca16b6abd18d332a9258685907f2e5c23f",
            "3be1a18c6bfa6f2f4898ebefad5a8e844c74626d5baa04a820d407fe28bbca6"
        ],
        [
            "1a8abba1be2e276cdd1f28c912280833a5ede1ec121738fcca47dc070dcc71d",
            "21b724378bc029a5199799df005922590d4e59cae52976f8e437bf6693eec4a"
        ],
        [
            "3a99c22dafcfe9004ebb674805736a26aeed7ed5d465ae37226dcbe270a972b",
            "5bf67552af08e1e6e2a24bf562c23225e89869cab9bef8becb3669175a3c94f"
        ],
        [
            "4a6a5e4b3501f2b7bbdd8da73ea81ffca347170bdfb6776a037cdd74c560fb4",
            "5af167ebb259c2da88740ec559ee04052bb66480b836cadd0e2590c32d7111b"
        ],
        [
            "6890d95308525f0bac9dc25cc1189eb92d29d4b3fe61bc8aee1c716ac17b1e8",
            "e6f23f78e882026b53ea4fac6950e56e3da461e52339eb43d2fdb2dade7ca9"
        ],
        [
            "748f4cf4f027efdeaed7c7f91ef3730ff2f2bb0bfc2db8f27aadde947f7d4d5",
            "3a1cbc550699411052c76293b8c41a3a8a1ecf12cbbc029a1b2b6ea986fca93"
        ],
        [
            "7321f3f581690922cd0dec40c9c352aae412ec2ccdf718f137f7786ab452cd3",
            "5be5130c9277cdb76d7409452438ec15d246b211dd1e276ee58e82a81c98fd4"
        ],
        [
            "6c4d6cb7e7ae70955224b8a912ff57ca218635a2436b36cee25dce8a5cdf51f",
            "32f8c03c6db3246946e432e4148e69f5628b200c6d7d72449df6eeac0998039"
        ],
        [
            "1dad5f2e795ea6fa5177f110989516eacf8fb37bd6a091c7c93f1d73a2fe309",
            "56b2298c538180e99dea3e171dbb5c6fba0bd0a9ed40537277c0c2373a8e2c4"
        ],
        [
            "1610605baacc9bc62c4cc923dc943347cfece7ae241e746fbe6c2c878221dbd",
            "431a82d657e0d109d00dea88cf3fa9b999845221b7b5590a20c40fc71368c1c"
        ],
        [
            "6a4f5c787fb09a5be2b04d2eafa1e6f3d3c863ee22960eb0b64f6eaf6659162",
            "14dbc3eaea6146ee7eaace5a91ed9430dad3a47e9ca2f68b455171f8fe6a7b3"
        ],
        [
            "738415b73e55412b0e582e45ff0d7bf4b1bf2922db581783fdcc75559f40e",
            "33825aeb3fd8459999eb418d15102ba5864b069c6ea517f0c6e9eab8d9aca47"
        ],
        [
            "2603e72ce53985c70782774057a17944f7b4ce224a809be4e2b5af3606aa1d8",
            "92822921809c42318f42dac4d773325f41c43069e990adac7818a45e2554dc"
        ],
        [
            "181cd967ab4615357cc96c82eae9152ce7598c1a1dfdd91a458bddb016ae9fe",
            "5d562fdaeb0e12647e230e50eaf216bed52fa73c6b7378821a3bfc4cd66d4ff"
        ],
        [
            "1121726069b9ef5954ba6490100b226e0be53fef3e071b7c58a1286174b789a",
            "4b25594cf4e9eb2d14b3f52f2661a9992234fc222c0a0d44517cb77deb9c16f"
        ],
        [
            "e543663969b915337f105f80995a77b356f1a51d8b4a4fb12d44364130e873",
            "34b2e3c009fdab4cb7349a580df2e64c0098a123280078e5da6623a9ec6b44f"
        ],
        [
            "4e2f8909bb62de5ef65600e61bbf969293815296b6e23702875e049b3ce5c45",
            "3cb81f2c21f22a7add26fa38a9ce5d9cce1bb251bd2698f90c34ff0a84f7af"
        ],
        [
            "37b546e403a1ba970c17b67c2f1361ab9c803f8d2b5cd93803014faa08861ed",
            "37079184ea46272f5809b523d060686633f7995167897a153be1772fd6566f6"
        ],
        [
            "27bddca77f7bd7f66b3693567a4238f2e6751d95b0bcb409f6b24d08f84798c",
            "6417a85cbfd6fc02df560d3963a241a986baacdfa423f65d7227ce49a96c57d"
        ],
        [
            "2de71a39aa043057d1bc66e45f804542acddf18f7a6d88c0d7fb0ca240debdf",
            "306c1ce39ab46300f7cca0f3a2fbfa77296a27e24bc66b0b8044968ec0ee413"
        ],
        [
            "307c877154364c0c03534e7327d5a88e1380ceef6481567ade37a14ee7c1a72",
            "3404bc7dbfb33b95d922d0693aaf9358f77888d7d95e773c38d83dbe2e5f995"
        ],
        [
            "79f09ff7c60850e5f5ea020722659a1ed27db4c95dca131f99552f785c8afbc",
            "40429528c099349b426ddbf129497176951a64a53db5f9d8bd2be0252cb22b2"
        ],
        [
            "4027dc6b56d446e5972f35464eeac85c5254ef377c902d9fe37aea841bb5292",
            "7c3ea37689ef679fa2f5c7e031a78e23d484a8317990fd34d44d95cc1db3717"
        ],
        [
            "645dbf78a3c228c4b7151450b5e65edb58e71f37e1e4bc5f471e0f1abd6d9c2",
            "15cfe7850f327b256e23b00627451560c5c6ab60db78d45b7ab286afb6f13ab"
        ],
        [
            "1503ca373757677ad1d911a2b599d01c46eb879d1ce21ae171c7e439846a85f",
            "583eb269b7030da6a0c324026919de3f9489d2ff6ae0e6320c36f05469ad66c"
        ],
        [
            "66e1819ba3ec4ad4ae9f7d7588d23baa004e29d3aad2393d52af204a81626ca",
            "505249980cbe6273b82ad5038fe04a981896f4117345ac1abcc67e2525c0ee4"
        ],
        [
            "5ec20dbb290254545f9292c0a8e4fbbfb80ad9aab0a0e0e9e9923f784d70ed1",
            "bdb1ca3a859227cf5d00eaae1f22584e826ed83b7ccdb65483ed5213dc4323"
        ],
        [
            "a5c1a5011f4b81c5c01ef0b07c0fbf0a166de77280f0ae241f2db6cba15194",
            "4444521fb9b33d7dfeb1247d0ee1a2b854ad166cb663d9dd2e686909362a689"
        ],
        [
            "1f35335de40e00c62642dac2fda8b30f071986ce4f11db849df11bc45ad4e0c",
            "7801a2c761b90fd4477ba0be9a775003d5dfcd959b1ed198b4681f15e7acbf"
        ],
        [
            "48db4798cf6821c1ffb8178b1d3bb6020e04186c96aaf4670972d367f4ed5f",
            "781019494df95b888f1578f1b4a3f8e125ea60eca47ef9207a10630671217a3"
        ],
        [
            "17f653d904210148a8e74d8e719a3061683c164aa6d79c902a19f185ab437bd",
            "6780e97985932c3860d810af1e065d454b1cb4be0e7ffe2d8cea7d52526e223"
        ],
        [
            "5c4d0c7432f9b0070436240f9855adae1467cdc9826952ae01b68cd52a3ad89",
            "1c5747f968ed91261b7ae9bf1023c999da9816e37de602d6a1a50d397752bff"
        ],
        [
            "6fedd7639fdaa2f7bad4ca0b391710f6f8a7e890250ae8ae4252bb8b39a1e58",
            "436a215f655a3fd3778b2335ffdc9aca6b98474e43d764c1f8362830b084f0e"
        ],
        [
            "7fbd45a889c5e9d127bb4f8474d6be7cb9796bbfff923b75e42a1ad4cae37d6",
            "484bd12622a6ba81cd53049c550d9ed682a8e765b656b1cbff9bbea637bd1f4"
        ],
        [
            "17d984d47937263f7966a3e7b1eea04071e678494bd749c9e02b48b3234f06d",
            "7b341ff08722c4e161005d0037204a7a2001fdda7af2cc1a0b04a027f115a0f"
        ],
        [
            "7f1822045db45ea07e1519c3ee1f7705915f35fe4dd8db1e8921b5d1c740edf",
            "33d41e06b93320ad1b3d9580380ec797a05dac3f1cc8008899110ebefde2f78"
        ],
        [
            "7b19453ecb74b7d0e2a66b9890ff73bfbbcd61a266abd6d82dbe665bf32f34d",
            "6dba2355420dac582b1f349609ea1c89b89bba2d1a68a0642f1dd12d86e73cb"
        ],
        [
            "273e82a15f395ddf2489a95685bec8bac62c4b459d1b28987d3cb27e4bc9128",
            "653375b48a4cf5d5b101c9ef533039bedce5dbeef3f59e8f168bdc99b06ca5f"
        ],
        [
            "3006c9e7fc6a553d8eb4e8a47ce9f10d1a39576ac255ae9e0a4ce3869e76212",
            "65fe9e2ef2aae608be309332d464f57e28f1df5de1a6a519751b056971f932e"
        ],
        [
            "5e8f384c8a4607fbe9789fcc52d54249d304d698562597d114c1d81452d3dee",
            "3c8bc78066b5d947dc1e405e326ee55ea606c7988f666748d259850fa259a22"
        ],
        [
            "7841b2102e9aa103fb53a642b3e167b21113ea44751ab38e0b5ef8312654db9",
            "71bf5c8308fcf9c4a7847494cd9bdd946fddf7d3a37e8bb0b201ff2343deb8e"
        ],
        [
            "40f68027420c11e3ade9aae041978dc18081c4f94943463aac92d887f922a62",
            "499c6062594a6c7e21a3cb91ea451813393bff365a27a08f1a515439b83cf42"
        ],
        [
            "6ce77a50d038b222634e87948df0590b79d66087b01e42b9b6d8fa30ebb1465",
            "35f5c46bb1be8555a93f155a174d54ec048c2ac8676e7c743054ddc52709d37"
        ],
        [
            "604f8b9f2dacb13d569262864063c2d4bb2b2cd716db6eeb2b1eeabc57746f6",
            "68c6799e24f3b44eec3049973445174727a66970f1614a782efa2b91ab1e457"
        ],
        [
            "73d620f3bfe77f672943d448d7dc05327adf64b8e7af50039c469d7f7c994c4",
            "4859deb36eaf0c802f0d1514602368143a33ec6ce8fd55248b59025debc6afb"
        ],
        [
            "3fd2bcd1c89d706a3647fbd354097f09c76636e93ae504973f944d8fc3bcc1",
            "677ef842cf5eb2444941f527abec567725e469469192354ad509a26ebb3d0e0"
        ],
        [
            "39222ea924ac17b533c72ffb2c47ffdc11d6a7f7c70fbde3a10fb0b8f35eb2f",
            "20dc4bd1089019bc1d7379b4feb3eae6eb5af59e9f253845da9fd633057e952"
        ],
        [
            "326f58994e1347f62e4102183215b5db956378d2f61f14aba4dec94577f53c",
            "7a03284c296003bbe05178a1d82efdb7b8125511d63e20e50aed789c2e52e1"
        ],
        [
            "53aa8939c74d4ee58f03bc88bace5a45c7bfcf27466201da05dc6723a5f5632",
            "2e32535ca7732904a048183247b04b426ecf9b39fc393a9cebe92fb1dc7a7f1"
        ],
        [
            "6cee1a03145e93b3e826e6067005f09c06099c98198c91c222407ba5c8c132e",
            "beaecad1274e7c6e5476a100c271aa1a6f86ee5a9fa5c2f26124d5886fa63"
        ],
        [
            "3ec659b8175e1be1bd5a252108714776b813e330393f587814f5f1f32a73332",
            "529a5cf9f8c237ae69a94217d173c8d19c156952041f5c980da557990863fa7"
        ],
        [
            "3d66ec5963d0c534d4139c8cef2e1ac48b3e7965fafabf58be26f903318af4e",
            "3d3f2de7a95f59b683725ee6283cbaf31f97c4b600df9a4621413223a468740"
        ],
        [
            "7fb38ace8e0932fac2ea0d3eb676db8d684db1817e2e4d59da7996ce398b4a",
            "68f92bd5768cdd4710249f9d49ef1d5654e497b9a4ba10bd2971366d83fb400"
        ],
        [
            "1c4a49314d6b4969cdd142c76ceb7682bfb868ace7f7568b0fc8635bda5a9fb",
            "5fc0519f1f4cc10b5771312458748c036313b87707ed0540026ac64a5955aa9"
        ],
        [
            "3073c95d08d3b97caea5f0be16b2789bee766f76b7e5499f8ce8f96abb0f344",
            "52a8974b4eb9a1f6a0ae2c83cb4715bf18d73f057255fcb3f63b74f7e78f590"
        ],
        [
            "44485b16d597a5de3604df6f7ed7e00b8aeef9e7e8dea8688255153b8bb16aa",
            "6cccb0ba170123266f24b5d93a744397dc2c44820edc4f8f5b9a0f5c9b3b940"
        ],
        [
            "7618f77b7b32d512688dd62e0b48231d9574c6361e8be353a7dc04f7c3a115e",
            "78ffcd16d80636381ca231aae70d99c9e20298b4f5388fd823ea9fa2b8ddfd9"
        ],
        [
            "7dc82fee1ef95cf5b3720fcc07f63246654bfe39762627839da40e51c75654d",
            "4c0ccdd70955da74558de20c88352df8a02aa97e4d5971c500e884740a8cb62"
        ],
        [
            "7fa5d460dc10cbb418b444d9bde97e92c70a99a222b99f244dccee7e62cc04c",
            "636163901baa5b7576c38c43407af578b8c4607e01e86011ae2dde587a89f84"
        ],
        [
            "758930d46006623a756c89bd0cc378f6a3c1f43c9a0edbb42274c35e75c16d2",
            "1d74dd9f81c2fec811b8cbd6168a745b0a111932b2a345265ef2853b50b6245"
        ],
        [
            "7332ee0626b044d664ef228f8cb84df7c643e52f6a2591ae1c9007ad61ec16e",
            "229bd8e630572cbdee54283234cf3e9f060e6382f99943bf234119d47b54470"
        ],
        [
            "78a16ef803aa20a075bb2f66c61bb2dae5698bebb94a0995fa74c3d53de1614",
            "246d588b68edb6fed96c128349908c42dcd64c46341b205e79f4aed9b5d3675"
        ],
        [
            "6e1933939bd03b67bba753cc0cbe7d2f25bad68c993887ef8c9e2fcd59b0647",
            "599413f7c204a11a5ce315eab11299ab7326603412bb00bc1c59ff75a37d6b4"
        ],
        [
            "4a79957a5a1888ad063b51c69565a2b48e8eb917183e220a1c8d3374526d30e",
            "1f092de0e069bba7fc5386e2e9a114c1618f88c4b95e220cd35ffe96f99fcad"
        ],
        [
            "3148aa3df9ece39aca84f59489f2710522216f14be6055ee0027529d1d55e2d",
            "617e9a52a92975db0ba1977f71116f7058a0d31b869ac7f3ee2fd80b0c5100c"
        ],
        [
            "5c1188e72384160ae39d07328346cda4f6c12d227448e6236f04dc971625287",
            "1643006eb3a3bc6aafd5f685cf054f2a572e6ca58c0118bcec0b833741f116d"
        ],
        [
            "3f72efc93c9b71adc4c51d8fc69d3940b20d08733af2b7d05140fdb1d1c1004",
            "7399259987c8f4ebfab46e522380707e58427d3962ee0c2a91760813f76d232"
        ],
        [
            "3129b34c03c51aa8f611e91d5cfcc9bd3ef108ee66e6d3ee35a0e0e50055bb",
            "563b18b5650085efb4cf179a029e6afff27b1d3091cd28eaa68d24fa1f801c6"
        ],
        [
            "16eac0f9fb4c67cf89a7fa4ee615bbe731d8edcb709a1b9b50c7d873a530f52",
            "7ff8288b6e199ca8f316192881424a37fb080c29daa76b1f0edaccaf580a80e"
        ],
        [
            "75f6b6028c43ce832f65d7e8e620d43b16cba215b4b94df5b60fc24e9655ee4",
            "35e9ccfaed2293a8b94b28de03bcb13eb64a26c831e26cc61a39b97969a2ff0"
        ],
        [
            "3c6152fe093bd6316897917ec56a218640ec1b2148f21db9b14fc7a5ff362e8",
            "6eef2df27ae7d63a28856b07b73e7aad7ca94f317201a1e675ffc6f9a1710dd"
        ],
        [
            "54e01b5fe4fd96052aad55b3f26b1d254dfc7e2525fffb9ae0a77eb8cc5579",
            "7c3d39232ab333675b219abc766ed9b4782c840e6b046614dedb8a619696eb0"
        ],
        [
            "d1e63f8ea8a76429cf254a6d3b668761f0dc572d4bfac4fd56d9eaf58fb6c0",
            "2bd0a84d3908a63085824c9329a0983913006ba155b56a58eb3f9becab29c45"
        ],
        [
            "2d6122f2a702edd4da7385b1580796a71d13bd72be94cfb3fec01149c006c2d",
            "70eb282fae992efa6f5915e578b640653549f23385ef3a29ab29b1b9b8ad63b"
        ],
        [
            "752fec14beaadb5ddbba6b3a17fcb86579fa588ef407fad0ea07dbb22a640d3",
            "3feb6728eca21a1e84e8f9f23010387a53a96a1cb62d86fb37996150a1299ef"
        ],
        [
            "63f94a92f27acde8f5ed949b459506f51d70c85bcc61a34d647264ecc53c65e",
            "37e5dce0646ee66f4fdb93b82d54d83a054948fa7d7fa74ab6b36246fc7383e"
        ],
        [
            "d6aa909287a2f05b9528690c741702c4c5f4d486c19a46c38215f52ef79c7b",
            "5ebe1128dd81093df4aca0df365d58adab848d1be1a94b95eeb649afd66a018"
        ],
        [
            "12866812b3053e2f7a9572bdaf5ef2b48c6fb62a0eed9ff0356df50e7d05557",
            "6785f7eb2cd1c120e4c7167b46861d10117040a2e9f2ca86a71e9d67df90613"
        ],
        [
            "46a730d05330b1b13673cb8a1b8f45460035e4a9f1a1751cfba099c4355c1c",
            "76fb0ec6cd16a8141cdcd875c8b2de9fce42d296072643d148ac7e7fa7472df"
        ],
        [
            "4bd4380a22900bd34835e0a908eacf4b6edb61eda0cf483f9212453b37e7516",
            "5e9551cd20d8d7ddbf4366880b7d5267385afa1966ff30da4baaf273b009d29"
        ],
        [
            "71f1994ad40baa2922424ae222663a64f93d8b67929e9a10f9e4c1ab19f3833",
            "85320fe68ec0d37cc19fdfd03589d66906ffa4046c80e1b094a85f27676346"
        ],
        [
            "5a63b1bf5232f28f808765c6be7ce1f81c52145b39f01c879fae0f4303bee61",
            "3bc5d6df68bb6d0577bf9ae2ae59ec0e9b2dc7dd56ea179fb38a41e853db950"
        ],
        [
            "161ded55ff1087032381e6c1449704f63ad2d88df82dfc44a71890fa09b3941",
            "78a52e0013842037274ea75daaf8eb4afc04ccc4b07bfaf3f5ee47d165e01b"
        ],
        [
            "1bfce5229c5fbff5c0f452a22317fcfcd9262f23df41840f84fe7d44cfba1a1",
            "66b387872c00e63c73006a955d42cf49c46c5708fc9d1579b9ae38341b24a3d"
        ],
        [
            "56d47dadc9cbd1dcb2ee3efcd5d4af5e6aea71df10815c68b54a14e81d11b44",
            "47e966ba54df48e9b612a903685e0060a67e4725402e8cb4cf654e54e813a3e"
        ],
        [
            "4b1c44438afd4ddf20a2cf612df2ee494ce84c7274c5529e857693e73018491",
            "430403bd31d8f0677e06abff7159384560f27b9622943fea1a3192f14bf40d4"
        ],
        [
            "7f7281728fc2214aa1dbf13176a4624b53814734abd570eb6ef7c7e32379606",
            "312da47be347fb3fa2c9089b38df372560dcace2effeeacab4d96ab11567295"
        ],
        [
            "16a28884a1be8183e0d3fc0db84a9afbf47126fd3be548c2a584aaafbfa7dfe",
            "7c3f57b3b895564ba562c1cd80b71fda6d2e611665c6ab87744f5390858fe24"
        ],
        [
            "323339f37b327a731232a9580e79952063c7c232bd1380146d8a83c285f4b8b",
            "4f16be1d983c7232f92cce6b9690695978d42cecc8eeb8c206e125d1098a265"
        ],
        [
            "624d26cbaa197e104eb83cebf2adeed09a5cdad359993fe5e3529d4d0def21d",
            "261b7da3cfb55c788977e0d8d640e3e93ae5a325d962ce85c816d7d32cfc430"
        ],
        [
            "f24ecb7ee83a3e28dab54a330dc93d0429a7aea36412e922dce8fbff40d60d",
            "b043e36a258d1df1d21b0cc7be9c4dcae1bd4ed326c110e668ac23d86805a6"
        ],
        [
            "686cea46b710bde1231483bfdbc700cfa3da6ecd5841c0e0c782f9ea24328ec",
            "7eb7407aa58edd6911c7c7e8d1e03bb52ead4a2415a0c33325872ff3a521dd6"
        ],
        [
            "3866ee1186264549df3dfcdf8705c0380c9372eef6d4081c2454d3aded1720e",
            "634c6d3e8eb8af652a4be73e3b613452c2213104ca875b66b4b15ee5b1716af"
        ],
        [
            "484c687cd2969a1d20a58cdfb9a60f280a473284503b1ecff5de514aaf8206b",
            "34d44d26b7427e51a646d1b924084762f5b461685450f21d6a472de565bebd8"
        ],
        [
            "203561333771fa0fe22c4033349f7b877d15b0542a5598e81e067968768247a",
            "2b6a533aff6e2163a36a2a89cb7415848bef48db40f952ffd380f47676707c2"
        ],
        [
            "2ffa6cca6233695760251206fc5e34c8d3692498589478cdd3d5b09f0b7c05d",
            "6c57d605478fa9626c4ed769554d075daa53e1a1d0bd4d94174d3bfeeb11ad6"
        ],
        [
            "5dccf0fa46a5571f204d0b033b45f299cbb3d9f80fded57253ea4f1c64faaef",
            "30a38e131ee8756ee5ea2a3e16618a5dbc28b5b9311308bf037ecc2039dfc7d"
        ],
        [
            "57b0a2eaebeafd950221facdd24790d7d1ab8883e5c5d55635f0d14a1ee4741",
            "7b41cc478fa6be38417271db8ed12efc0da6982552c1496025d2df0576bf4ad"
        ],
        [
            "611b5725101f611c387ccaa13889ecf3bb5595071a179ce350029bfca4ad7f1",
            "3129755977abc8995fec7eec1123a1561e429fde37ff36af002d3211831ecf4"
        ],
        [
            "1c06bbd0c52fdab9fcaf680c7a93fb821e538a2ed79f00f3c34d5afb9ea6b31",
            "3873d3bdfe0be0157bbc141198dc95497823cc222986d24c594b87bd48dc527"
        ],
        [
            "275cdbabc989c615130d36dabfa55ca9d539ed5f67c187444b0a9a12e5b7234",
            "2b7f723e68e579e551115d56f0ae71a3b787b843cc04a35b9f11084b006521"
        ],
        [
            "6cc702eb20f8b5940c7da71f8b1801f55c8c2d8e2e4a3c6c983f00bc1ffdd95",
            "5d15b3727bc66f3aba6d589acdd139fae115232eb845abe61fbdfc51341352e"
        ],
        [
            "44defb418700cee8c9bd696b872adb005490512d8bba081f8f99a9f15cc981c",
            "3b2072cdb1d919b2b65b5cb3557f0a3381d7ca293c267ca4a38f83e77bcc96e"
        ],
        [
            "fd83ce77b1578b3a9b8c3cbeaddb1504d2fd4a19c901c21ac65961224e4966",
            "110cbe64fc10c6b9c66f15ca406a35f50b723b35d83c5eb9797a57f8395f4f9"
        ],
        [
            "9dc6ff90e341875e113bbfb507724dc7095a280d2f32cb6ba61a1e0c2d2aef",
            "4aeb622896c852c2747454e8f172c9482955a42ecbe522d6ce07ecde79d0a51"
        ],
        [
            "71c58b0e47b9dd9107ebd8a8c8fa9f0534e78231bac612c1ddc7a94edf33eb7",
            "7f90edaf4792bf8334adbaa0f4ee7c654312725af188682d75f34874c4eccb9"
        ],
        [
            "1f6de1f14988778ceb2dfe844f92394f1f1e72fd1581ceb3bf336c95ce50345",
            "4f6007ed4e022d2ee9fe4ca8207c5f6c766c4f3b85260e941fb24ad0dcbf0bc"
        ],
        [
            "3ddc3ac25ede4a67a97547ed27dc920239b585fb3624177e2e8d59eba678115",
            "a9afd8f8bb759cbd1dff2addc63f47da4ba1291ea34229c09c0637dc5c8d24"
        ],
        [
            "c56b0269d8431556e471cab9d70edda3a37b391696f107b2dc370631de51d",
            "729c52f6b134f733eb750c14bd9f95c077f0f6f6ff4005701e5bedc6544599d"
        ],
        [
            "44d32ce19ac6807cb22e4f25fe1486a36a13926f147fbfa054b63ff0446177d",
            "212a21e8c124c9cd37c80d2dd66913ceaa6b6f666522f115c39382b2d5925e8"
        ],
        [
            "35dfc16f3ae6ccc06a267bf6d931601e52f3e45359ffc513570b65b96adc4f",
            "74311d10f4bece01b5ae65a6affe5c931463aa1b73a3320eeb41bbb7bb1ff62"
        ],
        [
            "e0acd9d2d907031b319b80121dc90699d003d220ea785d50e5033cdb3b1a03",
            "3911ba78d6e507485d6374b0f7d2e6198f6462a7d6d3cf046404a07af690357"
        ],
        [
            "3c57918ca254c0cb7dac251ef4e10c7d82327969552eae15d26c4c52660922a",
            "5fd5f5ff3f14e671548074114c72c48409df8a2e71fc8aa3c8acb506e2a88df"
        ],
        [
            "222ad8b61e219ba2b581f606b7c996516850a46a3db72fe1f72b5a9be6c324c",
            "72015a5e2db648112abd284fd867b59fc5606645177d26cf6e9a655c9912d42"
        ],
        [
            "3c86d5d774bc614469768ad38f7be9a53e9a233942c5c553b82e49aae684764",
            "480febea8229e130dedffff89c11f3c43e11724e6bd89d5566d78752859d41c"
        ],
        [
            "adb73bb8352d0c10175df371f7868ef2c9e0c79ac788430c480c0f7d85c187",
            "60b564785248111502e6f39c4994d6293fac22bc25f4d764b2fb1957d3c9bd8"
        ],
        [
            "3836ab8b46cf4f453a22532c886940b982029b29c42adca90ded5bf77e6bcb9",
            "7b15e91d6355f147b171a90b064a9d8b2d7bf3699bbf4987664c61c950d8996"
        ],
        [
            "12ed96af1a97c45ec31f1531e96f6fb28a03ba52ab8484545fbe0dddc97bb32",
            "6d1f522b6c6cad0940cff8e23decc72bb8d4164696af031415508b025aa8be1"
        ],
        [
            "27382994ae5878223ef802e9b4882f481a1b4008f1eec8484483471f7aa742b",
            "c31750d242b3975b0026a0e86ccdd17d0f680a8c6f53f197fc25eb1f777917"
        ],
        [
            "431677eba3715455bc235557518a74f3b111a88844ef13e159ad44bc16de3e6",
            "30000e1eb6a17d9df776981e65c6e500fded1ac12003adc9446b269812c9197"
        ],
        [
            "4b563e6f42589671579eabfa2cda5502b361c46a5ac8d45c8ed44741a925b33",
            "627bdb41678443fdd1aa607709e9699b652308615f4bea760a3b79ee0d9ab5c"
        ],
        [
            "2932fd3f81fc973ca9def6b7f1bb50f980fe589187cfe9e9f52ba4d356cf2c8",
            "1e6bfd00fa976c4770263a227048214c38850fe0f059e7b3d2c7871ef07d68f"
        ],
        [
            "e44e4f3d96d9dec775b996be57e57fdc28e7c68023109b221c414a244a0dbc",
            "58b1e52fa274812e5184e00e9ad812bec2463140adfb4bea3b2d665867dcc9"
        ],
        [
            "7fcb89be1f4bec745887bb891e53fefd665c53d00a9e74de16b8a7e1f7adfb5",
            "74af0b06633f779897e199609c71cc5649bbb65bc2c0abd4c678f0480c198d1"
        ],
        [
            "62a381ffb904ea3ff4d451d4c8459457cdbc3dc2fd2da646a95d8c1e90c0b7b",
            "1ba058658e09db9e319fa73de8ab4a992b71e4efc22c273725bdcab84e2a315"
        ],
        [
            "1b0fbb7a84c67e668450a54449c7a46261a2d355589f8b84ebfbaf9a77ee938",
            "44f8fffa33dd33a6146c35d196595e22cc4a215f61ee9197cd751400970a1b"
        ],
        [
            "78fe920bd96a356d4d95ee34adafe8fecf071d3107c36f047b4024ddc4b3eea",
            "6162f29607fdbec10181fbac6e57d5cb41b922c5791fb24bd28bcdd75d16c41"
        ],
        [
            "5629b849e026e65d119ac11821d7ab7efd9c52226f75c7427505d6818bb0c8d",
            "1539c0f90970ee8b490e45bbe5568170e5708521a0e59f976be680595906feb"
        ],
        [
            "62bc853f349bac8c6e5921d27ba85dbd9ba20a375d70a7bc008928f3e123b04",
            "6acfeb1de05ba43c3ef1a9110a983a320e77b3ca294abbc04aeca19b194f26f"
        ],
        [
            "4cf4bed663464418285cbae359b5d84ec76b5997d24f3640984c7663421190f",
            "941f818e3e3e8fb1568da85217d17f9250ebc948379014d900a7b1a848494"
        ],
        [
            "52ff3d9ffe9a302f6dfaaf74bab57c08027d5cb699a69b30830540c0a2d47a1",
            "987dd8876873778d933fbfed37aab2f7d6f669c37024f926b1edcb2ca55782"
        ],
        [
            "1109ee32f0bc53de6bfa457060b366e909d7c18061ec9845f46ac715496897f",
            "38f36f172bdfd454b9285f86e6bdece8fdffc95182c7d801b03c671cc55139b"
        ],
        [
            "4b4482f1d84efe23dadf3bb10df3dcaa251312dcdd604f616f1eb540e1f3232",
            "7c9c149dcae9135f940fb54482f9c3cd8193721643a6e23157b8020410d439c"
        ],
        [
            "69cb459b9e415b7581ca163611c470d875971d5d7949de732d1f0f200544a73",
            "a7136fa9dd00c0469863b7def3f83a5611ed628810d7e807e7a873da5a9897"
        ],
        [
            "b66a4e32ac9a4baa8f64780acd94ed3628b2b0ea874ba4dece629af65f9e62",
            "24328ba9996a24389658e3467b8b90dc3927ef8419fe28b3f55b1c1aaa51915"
        ],
        [
            "5ecc3080062dd451236de0e4eb91c5c75100733364bc5469f5fa76f79021ecb",
            "6da4abb9031a27b5be94529324fad8026e7d871570780081b0f424d4fe543c9"
        ],
        [
            "1e3146f00880bb22486d5bc73e54367d54251f4002bcf342d0393b05a4b9ce0",
            "23b6fb8e945d3205f633ba724202db5a99305f807137edf942cd60eef867699"
        ],
        [
            "2e1da8013285598b899f026c6974185db12c97b4c63509769d3d4ad1d18a4e5",
            "1e7e7b668674d1593c39d58bc7bccbf568208732b3519bc2cdf93db34366862"
        ],
        [
            "d26c3f389d81709506f184b53871497c8d36c5c9eee8e3737358204c1acba3",
            "34649c3d39f3b825947fedbca215ae30c5a5995e93b1c8efca4944cf85a082a"
        ],
        [
            "91300478a83595d548f32f259033291fc7d083953b0b8bde88c7559660c563",
            "e5d2bff57fc6551e9b80c06ac7314a71907cdcc66ce82f2cce721a670df10a"
        ],
        [
            "1f7abcb9d462c63ffe92aa56619ae8590089cca4d93ee3e5f34a63882452cc7",
            "7e9f85c7b7ca6e9a4f3a026d1048adbeef69ea9d876c6f647c257b879a81bdd"
        ],
        [
            "4d2caa1323012e4c83b0ad387308b8aef5637bc35ddd882e7f5e41cf2ca410f",
            "47150e808c81a540b6f8864e9d6636589cacaa516f82caaa96506edfbd6f0e"
        ],
        [
            "3c10a6083c38351deb3e6d1b386827d0acf48979b66b95249eb8700ec26b069",
            "47e34bfe561d903cffdd1d849b85aa3cbd31cb4a9bbd8cc2e5fd2f95016cabc"
        ],
        [
            "758bd54868eec045d0b4d3d2bc415d24bce13fee47cefdfda46425c109b657",
            "3392a7c66ea3bd7b044680bbe9f78ae86752097404c067e9d2572f55330df83"
        ],
        [
            "19e718e0ca1d2d6fadbc6006ee7dda7a385430e29f5e239cdd4bb7c3fdcb2f8",
            "5c68249b7fe03ea2e13481a63b6cd4bf74ce42009a89fee0b3f8f968b3ec709"
        ],
        [
            "28077f57ea62401806367e6d54fe45d02de5b072db787ffdcc3854e12a3e855",
            "14f3762689072f5fb41d03e94b01808c739f6d42b7b785b0e464100b150efd2"
        ],
        [
            "3b8a8cefd017363ce867265af3293cec081fa589fe561830f0078778cbd338f",
            "69ccf2383cb7b4f9c806d72535812483e7c5e9a1a5928529d64ca7e085e758d"
        ],
        [
            "77878f388d22161a2953e5aca6bac1ea480e102f329574b4b201640d44a296b",
            "7eb35706a90a03aff7c2fecca72659136547cee98038746db5aba16fd7178df"
        ],
        [
            "97332e6da70961f2ef31b7b628f1018d21db8db015922a301fca7d6fc6a8e6",
            "2e37b06f639fc7a82601b744570a2619e543cbfaf60e474107fcaf4686d3223"
        ],
        [
            "a81518d452d3aac48bf0386c3ff170ef4e684a4def242c964e129c64f4d647",
            "37506e44c85908ec7b7adda9547fbdcc2e3605151fefa77fbf127ce3bc938f2"
        ],
        [
            "e80336b2220b1d666074f6b0dac85353d0e4c2e8bd0f37055a2236a6a9fadc",
            "1cae76d73eda7a5964c5d9d3ad6748aff51f5543c56441d2fdb7b444a39846a"
        ],
        [
            "2c01fd8430ecb44e066f352c4f697fc9fda177dbe162f82862d7b9ea8c918de",
            "6e1dfa99640fdf5b30603d34c7c97c1aa6e6b7f3a2c52a21fc64b0fcac7d591"
        ],
        [
            "744e37b511cd0ddcfe15f3581947014c159de81ed055d15a13c7a2d1fa39f0f",
            "685caa8ff6979a6c63640ac638a3f9c75737f2031bd55322a47384357af164d"
        ],
        [
            "40e627ff84e1a7a9068b4368770f5956128a4d9e9e33e9cf5e24d9a242149fd",
            "2465bd6cb20bbdf810e2bc5c3c458cecf4f3aa163a7ac99c2579e5f33417f2e"
        ],
        [
            "5f635af7f554a17bceb6ccb6e637abf89ab6dadd399189b0a0390e87b1896bc",
            "2aa6238a69f89665646c0e3ca2ba5f709cc6e14351cf71e1b00ec45201417a2"
        ],
        [
            "5edad3063c9fa8305978d7e6a4e037c9fa519b8023c7608dfc3b66e5c1e8985",
            "49f405d07d7d01919da51159ecdad1031a5ac208c026fdfc14d38f633d92183"
        ],
        [
            "2fdf2e8a45858c12926a1f25a62255fb2d02d0149a15ef669f859806683e649",
            "61cfb686bb31e2524470d4ad2ae09e3cc91b16305a21d748098feb1d8ce3b3d"
        ],
        [
            "ecdbd7c37f1dffa3943977278da3bb429afdf948b4ea6cdebace3d3be82381",
            "190b67fb34f7f3ad6afd3d6b6427aa327547d8ac0fb4deeb0feeba1f63d6c60"
        ],
        [
            "233021b483f578dfa5222f8cccba5766ceee0ac65f6d4a3b1673b302a21fb3c",
            "7d4b6d44d175d4b593f06f5a6dcba2cdbc4eaa2097abaf613123546866cf4ef"
        ],
        [
            "42db4e953c2a7a743de9fe20c5798f2247f51db4eabc6f40e86c13909a310ce",
            "12c1a0764a0b9f3666e431923ce15e7fcd0ded5ab153f0b48d362cca1604e65"
        ],
        [
            "30d539e2b545fb957e40e2255f6463b52d227c9808472cee6a3d521aa283a44",
            "5f9eccf747fe6313570f99e845db32b40070acee9ce9e34da7f3c29ca53a07a"
        ],
        [
            "4bd64e5ade3e2733580a6116b4af328751198e7128f9acfe3a3496b545efb5a",
            "4d584768900dabfc0dbaa086632b8051bb3905ef79b84d96c01514441d0cc93"
        ],
        [
            "62d6e771f02e591557197d13c3e77dfa2d1794ac1808407bd8227c4be31b466",
            "5c6f5607c1808e899ba36a425911fa8566b7ea9cc80de8a80538c0fceb837c0"
        ],
        [
            "5ce406218cb2852b1d2fe1836b19462f664631785216e87ffbce26030e2101f",
            "5225f107743c255ab50e7be4a090fe39478d1ef4ff558468559d8cfa87bb94"
        ],
        [
            "670286486e8dda3dc66b0ed3149be7697d3e06c8279844079daa7e42d5af728",
            "26becabe7430380c56e320f5ae3329569cae7b0af06fd5327ee23979d200eb0"
        ],
        [
            "3ef448df33a4394c43e93e5850cd0c5a6dcb18ae1cd865d00fe8ede9336a9f5",
            "56711f6ab7e0e4f7365ac34e284ac2879f40208c46f6febcc1dcf7146ecf015"
        ],
        [
            "4b63fc130288e92f2d6ba238caa7a6364804e29829ac037c57df32fbf762bc3",
            "1eb8c80af55278b4113286c038fff2bfad2da62763bb03426506b869139da0e"
        ],
        [
            "4e7e998557b29a95f805a6e2e26efc1e970108272d4755738c04f28572295c0",
            "97cfcc2f447bde61bde71049d8200a74a3028b21703bc139143d81a3623f09"
        ],
        [
            "574b67898f02964c408f68e9470e7b615be037e40b824e6617f89cb56c21219",
            "49392d5f8e6740a1b0b7444f56d7a17363f8656c6e4c628678c86223f2e46c8"
        ],
        [
            "7e8cb50ea5d5c1b09e219e7305bcb601d99b6d7185b1c388aa8e36fe1e56554",
            "47fefa308645455c12ccb5817da338f0c4f423b341aff4a9d158891a4fd69ba"
        ],
        [
            "67266dea9e71b4ed2bf24a597a823dd048cf31e725db511edceac72998c9ef6",
            "39babd65850befde1f7c28e41dbdbb4caf82bbcf3bcb5b33161f1c2960b2d8"
        ],
        [
            "63e99c2cb9c74eb9227d48065e27abb8f606df8fc83b2c44e4ea38b046bad2b",
            "60494a53dd13ecf34e08079d343c88fb655d6d810785af81f08d5aa9bcdcf9"
        ],
        [
            "3cf0600b0f5a2a4eb78c487cd385350e8c7848e3f6983231881d7f1bbe28543",
            "56dee4288528de609976ef6b903b652127c37b0590e91a2fdbebc3f11df2628"
        ],
        [
            "758f09245fa4b8b23d290ee2b3bfcede199b4fdb11f3cf2502a8ceedd61b129",
            "622d9baadfde781e985d9722e0a04715666769a4cc7a9bea0b96d6386be1746"
        ],
        [
            "38e1a45b81492aa95d7abea2b08b8c14dc0b8a41108b036871fb737910ae18c",
            "145c611262656385e5ed6243568cd3f9f59dbfed7a01ba11e22bb8bb272e08e"
        ],
        [
            "206e54ca53a2f155bd4fc45bf2edb77798ae6623defd4cf22f2dd4a7d119dad",
            "6c94e7f0825ad81680e4cdbcaaaf4df806d57a0d1fb2331926c3fe2b79d22e8"
        ],
        [
            "56e98d2862893caebf66180e84badf19ffc8b53041eaaa313ae7286a8fac3d",
            "526306f9c01afd6e0c1198ea5de17630f5a39c4ecd02d8e6f0d613c355995c6"
        ],
        [
            "4fa56f376c83db33f9dab2656558f3399099ec1de5e3018b7a6932dba8aa378",
            "3fa0984c931c9e38113e0c0e47e4401562761f92a7a23b45168f4e80ff5b54d"
        ],
        [
            "450cfaadfecdb8a2fbd4b95c44cb1db723ee5ac9677c9c188b3d7c8eff4ca58",
            "1a552bdfc0c81be734f1f6ca9a6dd3ab4daa61c11fb53ebb7046eee25d617c7"
        ],
        [
            "6fe20e5c8a8004e33eafc84d16ef770f2f0b7bace19adaaa150f987d295a34d",
            "28a35040a2ebe9a14a162d3208d5eabc6e2f3a8310f926bd80be65aa71775e2"
        ],
        [
            "1bd65f45a35bf62ae8f9ffcbd7de2976b90518b6820c219f039c50043bb1edf",
            "fb5f0f8659f9b6ed7cb0ddd7999506d0c20b26bbe69d1915a31842cfac41eb"
        ],
        [
            "4ba4cc166be8dec764910f75b45f74b40c690c74709e90f3aa372f0bd2d6997",
            "40301cf5c1751f4b971e46c4ede85fcac5c59a5ce5ae7c48151f27b24b219c"
        ],
        [
            "21cfbc678f5a279ebb6ed124273c8df37eaf12a2d04180403ae6b5ec0b1e1ef",
            "4478ed6a346d899ad7b0b10350270aad39ddd5b68529297e4c91a54357f0a7f"
        ],
        [
            "350bfefbe3d864eaadac9cc1195c14159bb736be743aed7380d2384cadd2046",
            "5e2a4b3ad0e1d7b9b8ef72b10d68a80e5ee691d7db591fcfbaad6240d41da8b"
        ],
        [
            "529acd569127f73c8d34345f87e96cebfb48ee12a00a3861cda209337ed94e6",
            "3120671a89b705e5bfd99b0e7fd2118b4914a3ac309b3d74527cacb5ad7491"
        ],
        [
            "55d3d7956a97d10e65a4d8ffeba40deaf0db0b57f8e022cdb3df6df613f5c6d",
            "159e59a6f92f48fcf85aa96c1a03749a4c4e2cf9e2bc94dd36796daebd9b8b9"
        ],
        [
            "405f019ee8f2e972a005c549b0884b5051f63d1e78480b73208dc07d8c65a1f",
            "4301a3d0c285ad309ff24a12c100ead7f48ba1368143712f32ac141ab4d9e8d"
        ],
        [
            "376d59b298d982f02dccad0edd5bbd4e5e8fad7898750675ed0856850a7babe",
            "5233b12bbc50564eb61cc098a17d3d97f06ec7a230380e4c5d3b725cc318eba"
        ],
        [
            "2f55624af6109ef04b2ed035a44a904ace8627f55889f011f768aabf4de9a38",
            "7f64209ce7dfb63337ccf3d8c14f4093295f86996cabfee23b1655549aca089"
        ],
        [
            "3b8965e942bed2714bc2e685fb103496e1e3595ac6a343d6df45fb5ef6979ed",
            "5b7cac7a165cb69ae103dd9052fb39c00ed0aad47989005aee53972d82d45b5"
        ],
        [
            "7abfe3accdec1eae1a50049efdd9a8eb7c2921a08e8bf1fe606e9d5a4039ec4",
            "3af178e7e831f8148244d2d2b284a32991852db6212ad0a9d77540ef648a5fe"
        ],
        [
            "4983196df6ad7d6f0a8d76f86af3863ad8611374a03fc0fd00793181dbde9d",
            "204c1f91b70f975a21d24a8face664e496f00f602daaafa69a3b56098a4cf89"
        ],
        [
            "79e2b91c1531a3b16dbd53e72d94e16bf265cbec261658151acfaea3718ea72",
            "3d9bdb47e8b148c1c5e9e694ffbc2cf71aac74ae1a85e8d8c3f77e580f962eb"
        ],
        [
            "297efceec61b3be17565843cae465c52524b4ecd9331a4170f54f7de8c4556c",
            "6ccef1733624cc8b973ac63dd54e7a53604929affe81c3439525ae5ed6af993"
        ],
        [
            "44f04b1966264a23ccdc870c8563ad2efcd4c8087b5469b90e792287a5581c7",
            "1c417f0e9829fa3d3cbb7c3cf4dc7aac04c5bf66ff3f86b833a42c533aed1fc"
        ],
        [
            "6ff83f5d8b51db3be0bda80eed2e2adb7037f2f58f705e88f0f98197431ac26",
            "64f59b8428894c2b7afd740866065ded42e716c7d48accd3f117f22768ed9fd"
        ],
        [
            "14aa8187c9559f77cd1cf96b2dfc949182529936f2b0b4050ea56e134073b24",
            "5f36508c68b1dc586f3fd3f4e2bd29c6d8258491b8a6aa19ede811ce0d3d0a1"
        ],
        [
            "95e8882a68c5000d1c2be7c0b43e7f2a6f8de906485241f0285a5c73a27a83",
            "1e4cb67207ab73bc1e5d19fa2146fde6d03021393b77a55df4ddda1fd28f5b1"
        ],
        [
            "2ae0704dacb3da47d564514b4c3543505b403ba09a248c6e74593cba1867ff5",
            "5a4b5818088dc9ef4066b90a8893ae80fc89584f987ec1928ef9d72cea2bd67"
        ],
        [
            "61a10898a76fb99989e51c0e823cb60b95ec7ccccb917c42b2b28014f5fd94d",
            "23d8ec1de45366d3b86c64c2da05a2ce3d171adf52ca5522e652ffd0eeee795"
        ],
        [
            "79884133c879cf07734976fd64de220c5a972e04c2a3afb74c362d6c3beecbf",
            "2aaa0e6d4891b792b5643fdf09873343cd0e3fbba3cbd0601b481a4083f32b6"
        ],
        [
            "45f73d2fa82be6c5ccd0f62d2237efe8727c479967d27cce28e42b9a44bad5b",
            "2fa4932215f72d56d8be5205c5851c9b3e5f2a14468e4a7acace5437c6b27dd"
        ],
        [
            "37f53f771850f52f9c8f87b53c6bf0c93c2bed76f5fd1d5697356d0b2325007",
            "50f1a052b79b446fbc7b93ffa1a4515f6c3be3a76a2b0bc5eb8ff327549960c"
        ],
        [
            "71bd6d23e0d2f312d47582efa609101f15b9ccc571fca8ac4fe3457c67fbc9b",
            "3b3fdf86bd4c7fc26d60540a6439b4d179dcbf7b91efb0ddc60dfbff9a148c6"
        ],
        [
            "78219ba049438385b829c13a4993874a4a326c4143de0dd581c7b9956f99b06",
            "5505f1268dcdd4ee01b77abac3bfdcbf3f0513ab097c69ff777b4a631aaf256"
        ],
        [
            "b81e924a86536dcf68bc5a2ca2065a61103ba6c9eb0ae4cf8cce9dbe286f15",
            "653a6dfb51acfe8a844fb8362795e5549d424aed88d3a090366a44f840b5b83"
        ],
        [
            "441c0d7b7aa705046dc0e07ba5f33a7d9df23f694a05192ff8c2d7be2aa3fdc",
            "4c06568c0902bb99d428bfa0a946ed0f0ca0a51fbf07cad88e06e9c78e38a59"
        ],
        [
            "2569c8c78b6d6b92533f29f767c95720d377fa63ad5a3b9827ee0a74b0488aa",
            "4b59c81d3cfe08834f946d9d57614f5366e0bcd9349475aaaebe01341196fe0"
        ],
        [
            "3f2fa285a0471647b214eac652bbad9d58a9f2dd2e812aff0210d0d8a6eb32f",
            "4cdb18e1c2848c2b52c1a6557165bd1a8f55c2f7562f5cc0b326f73c25b696c"
        ],
        [
            "5bb5141ab4fcc5290ae9151b8045a2cd8391547ce7b3b33cbbb10f8fb538092",
            "5a36bfd52acc6a83a9913b937ec086cc27fed030b5fa70dbc5d3c12c9515f56"
        ],
        [
            "3f3fed272edf91aa7f8ca5d70005d390fbc67830ffc69c5fa3ae17582d2771",
            "459057e0883c44d8776fa217405f443e5954f08c4a5db68e437becaa664a999"
        ],
        [
            "5237ca6656237a717a739a4509f70db1b9dedbb6cd232f60c9bd8c4563a6b1f",
            "56c7799dd02896dbe7d69dd8bb9718270549592099569d107b7b49c34bf5a49"
        ],
        [
            "1cf6b8499ac881e0b2fc7def9bc1a28937033b2fc52de99e75909a620c7a281",
            "5769cf4f735366fa386b6858043dc99a100f86fbc77b16d57d77766197ba27a"
        ],
        [
            "1b74b8a6b86dbf9638cdb0601e1a332b8d880753423d38c3394902c57f15e40",
            "6bb2dc10d2ecbb913219d0ebdc8d3337d644ed8b6c4e70637ef4c7e50887488"
        ],
        [
            "61e4da415661bba52a4737e2bcde1a837787c4796b2e1854778534f1582c29b",
            "27c43e632cb7652e8508c9c38e3b4ad0d3dd6ba748d42dc84ec2685e64b9aad"
        ],
        [
            "7c460a204d23f20ce86596dae6ac9b36734e4a9f7c5b43262c97a36c6a41c6e",
            "481a11f9300ab4c4bf6924c5ca884728cc361247377065920966785d043fbbf"
        ],
        [
            "124ff5e55e4effa40daa5b9618d75c49c8b6fad95cbe8c0bfdd83cb9bed8316",
            "33a2ea15d0f71f58a00de71acd7f22ccf9002115e49dd1f7631faa0d32f9987"
        ],
        [
            "61c9f8fc86715e95ff43583a865c5a6515f93381839d557ef884a68637eaf4c",
            "5877daaa42bbab9083b571e12648a9d62ced4470d71653092b6546f4a5acceb"
        ],
        [
            "70a6b9a9e5d1fcc07dd9ebef6d8f5fcf04c6cb34932d0fe2335330ac6dc8d3d",
            "3f0cbd332ac56922e886656bee74f6e9bb4bb88f7af7bba9098678af1f38fc"
        ],
        [
            "41db8a0f1ea78443a39e08a54323743c8897eed1ddc28f41aec6f2655040d9f",
            "7d4bf32f8f4719c2e4af8b7889f3b65cfdd033dc2f971798a12170f2b26efce"
        ],
        [
            "62f035e01acdfe841104942d6c8c07f0fbd618cb85998ea24bcc24cfac1f8",
            "1caa886104b7d753fda93645a746989794cd825c62473b526ea34b3d51b5771"
        ],
        [
            "441c6f016d270e86c19843727b83b864cec060cafc813b23d7e41e5abb1a60a",
            "29fece4e40400f3acae0586f4fc8ed535e805e472123ec38d662d8a0b01c086"
        ],
        [
            "2c791ba0fb0b66177815c98191fa6188dba9c795e34a7c3c8a19086215e3cee",
            "11123151389d4b330db6a665a560407e7cd8c3807c749e2b0cffd9c3074ba77"
        ],
        [
            "5292da4ca71ae75ed0554c267747e39c7a129b3b863e1af3ebb3e368439c4ea",
            "63af6a5016deea8cc674c44f16c63c1db31f09af4fb4d2ea7917c28116661fc"
        ],
        [
            "3367388d5d1b7758dc3d92e244f227bb8a54e3d9909e7b7dd62ab5965e3efc7",
            "7ffb4833071e4b03ea755ccb9938487a478248fe9b1158a08f1ac298801c092"
        ],
        [
            "95c863314b7f18090f8eee602403be823a367a1b416d54c32e5f914e67d922",
            "159c2824f899171deee23e0ed520d4825bd667983df0a8d45d3a1f7156d91f9"
        ],
        [
            "621c6e08b3c57404644ad49ac7629832c141273fa1f323781b3395393fe985c",
            "65d1eb0140652958c4371ebec791e03317d6b2e689d90e304666f1b610783dd"
        ],
        [
            "54313129bf13993952cd2b31ed06013aba85e74c1b8a00e062031f32188a84e",
            "680129efc9eb8ec07fc180e8f6877e5f0f9f44e3000a2c586ed4ce49d12a313"
        ],
        [
            "21ea57a1c8286bb45872e78617853c47b89091670ba51c124afa3362e7260d",
            "7087e5c1536df233ec9bfe2f983e8d7622892b9bf64c450c9823898e2cc2fc8"
        ],
        [
            "3793b05b99e7a57d88db4ed0dbc3b771285abcd9052da50f88595354409f3f3",
            "12164105041c056f127e737c7cd63981e05f246bd2b6b65d1f427019c7c3801"
        ],
        [
            "befd345cef5fcae22ac37dacd6b9128cc58cbba3e3fd774e11b421c2ba392",
            "6209d25f24f88f7876ca604db23d05f78e6b3b67fb033f2f1bee221f352b8c8"
        ],
        [
            "15fa536045fda4c65ff74f10b4e669ce88b9996c6772288289d3ad725987fa6",
            "30e0c2124a35e265e931ccc66ce5ac3697d982814beb407144ff6762cb691df"
        ],
        [
            "38b795bd77ac573576dc204857a488cac2cce19809882631ca2069598c577c8",
            "786ba555d55ebef688b068bb9186a34a08cb00bdfef51619bbf911890ae9a13"
        ],
        [
            "6c66853592196c3eb8d9526dc155205e2c64097adf8684bb0e15eb460ce1c72",
            "1bb4ebf654f4250c8dd1061a4e1b464b31a8a9999ac9960446ef8108a66871a"
        ],
        [
            "5b08dfbc87ad9c00b88e78816973ad2f9c10c70f2156908892cc7b7a2a1fd30",
            "1151f407a77e2556073173d8f5c9ff561d8a23742121ca15f7d0ac391af50ea"
        ],
        [
            "309190eba106aa6ead54b5ca5817969aa68b4b4c627700799a49fc6bdd32ba1",
            "505b6a2bc7b0d78ca6ce2abe7dfb7312369918a4599cccf8a615f6701cfd851"
        ],
        [
            "89cc205966af08acc8910d563af7443d5dfbb5d88dae79c013c678c65dcecc",
            "1f8cf955694b246a423ac725791231257b88936e00347ecaa1e17045c0ab540"
        ],
        [
            "480086b61a80c36cf1e1a350baf554e58ee8d9333186b70c9c512fb9e9d5a84",
            "511edfe58f8d36a6170df743731da1ff525cfd5108be20e30ac4183d1281570"
        ],
        [
            "3caf14fb1d2e90a13ad4eb091250fe37133aabf6029633e905e5a93ead41dbb",
            "49122aff6059dfda19e4b973aba5ebe3804c91728936c6381c1ed1ea9380920"
        ],
        [
            "66d1b8fb2cabc46cd79741ce1cb7326077ad8ea3227a6427244bdd3806bdadd",
            "4a52eb74f4d5371ba3265dffd61c844f9e68d4ff0b44dc4936182f9280bb66b"
        ],
        [
            "373330c5afd53c31257fcc9050fef873e15ea9f81d9810f30744309b04e02b3",
            "5889806607b3dc97a9c5b0c8a2f16d1792099a22866b879ca480cb89a11ef5c"
        ],
        [
            "26840d0ec69a22c6818ff64b8b14633b531508c866e21d1dc9239778ae9e8c7",
            "157971f9a6e3a24d3b307be0e7c8cd352e2eb5cad33cf276270c0f309ee63fc"
        ],
        [
            "ebb84848f1c38c19a754d1b5d9460e39624dadbb30800987c9419c0f933b9f",
            "517b297cf32f4064e6d6c8e761ba8db89809604a701c7b3aa1a9c6beb370ea7"
        ],
        [
            "25780380bc0795ed0dca727c55240f1d63593e552d224adb40df2d3721c0f66",
            "10215fb5a893e0275e9f1f66b217dde35addee91ed0e8f7d79531a2ff57b8c8"
        ],
        [
            "243e1581cd1abfbf18c31c19a4c3d1cedfe69a40bb57b607c9af2717eefc742",
            "1296c27929f14535718c3a4ebe045f00afdc60afc74c7d398d8ce1b6609dc0f"
        ],
        [
            "48babb8649e054bc8e0b902c89e6940c265f48464520649502ef1064eb94562",
            "3235be7852b0526d1a16f6969ec0e5b0e09cedaadc65863dea4e47f4f398264"
        ],
        [
            "592db7c27e63489ef4bcef2eafce89f40067cd9a1ba48bc3dc76b5fc62ad9ca",
            "48b7711b570cd9ac65910e75e752f4b751fdbfb4091a28f59b8c046d3d9f8bc"
        ],
        [
            "31d133456222586ae42a9ec7ce8539ee04afbe0b2ed00a2564dab0798d9b55d",
            "a77c52fa1fd718db5c83e7fda6d7d4d9aafef9ad95cad621470f2b753729e5"
        ],
        [
            "4651668379883521e7983aafcb93811b4a72ef2975b3277773746708ef3e3fc",
            "512507f3f544d80ba5d47f73b571881e8d70d7b1d305b9704bdad036b7abc47"
        ],
        [
            "26069e359b2e847affaef604f772f36224608b7642245d0e643889ed231bddc",
            "75ae1ec379f074ebc91270077c74b4d34347ce183b676b4dbe100bfff143b9e"
        ],
        [
            "3196d01d1fa11dc3803b4813c4bbc6326869f61410f2bd14bc0f570d875aebe",
            "20313217cac79875bd2a503db1e86d1e5559911667a02524759344468d9561d"
        ],
        [
            "483256607f75f06fb126addc60cadddd602154cc4782bcc08351a48745d0b97",
            "2950a7e500ebbe9775f08be37cc2e62ccf9030de18948d1bab07a4a9173f75d"
        ],
        [
            "65f07b6050a2fc6eebe2c29ffa62f764060f7f9d3c82d2cb5e4e368aaa442c9",
            "562c9654b646cb84a213b41de203c871b3eae0a05c9c105a66a53c319c06373"
        ],
        [
            "284870f6181c43f3b01d94baa9c5b6ada0deb861145523ad9169580eb7bed35",
            "5e03e6c40c1cfa3cafb01fd0622349871832a9d35499d06408a83edc1b76d02"
        ],
        [
            "32229810a52137f0e6c3d37595c46f6132822d4b05f42674b48d7a7ac3ad85",
            "7babde959a0cf2c53ee59fc52c77c3adf899453f077f441965629f9aead30cd"
        ],
        [
            "1ea8b98a6b85e74e0a2fbc18b206e290f3ed94ce99ca665e8e2351dfade990a",
            "478e93c4724115fb1648c8d5347422adbc1a0bbf962b2312e14aec80e1be742"
        ],
        [
            "270cbaa08c79140c85b864475a0bf569cc03ac785e57f543dc444f37ce746cf",
            "3a9b8d894016680ae9d1bf3deb931d8987d4d8d8bfed45b81ccc595ec79046b"
        ],
        [
            "6943922708b8ae5b40dd7031ef2e487abc4ac39a3591368285e83d6c9c51f4d",
            "5f157c37d09634e8cbfbef90ea50af59815d011e419a691c67ca3402b5efc33"
        ],
        [
            "48ac6a80979fab4912cf0cb557d917a0bd68825d8658ec100496eaae6ff62e1",
            "2b6931350ab183402e39476340eb1177b7006f7a552915581e29a79bd7203a0"
        ],
        [
            "e3adf9517d92ef22d1e2a787740a292ba32d5ca69faa9e8675f63ed816dce5",
            "36bccf69bb12dadd610145a3399213248d193660d8dc90a2e206f23bf2c7997"
        ],
        [
            "5e6c8ae5afb2fa470f767581f3d578cf6a49547e4b78665edfd45776948bef8",
            "6cbfc11953dd7e195d2ce74e52a60df524767b44c4608bdd755be4bc85eb74c"
        ],
        [
            "15a576a1242d39300f0db3ad770983825988da0457718ecd596c63a0a0eb4a6",
            "69a42e5f6f5a63349b57683a4609bba90f556a1680fa1ec3b02ee7d3211f903"
        ],
        [
            "274cd14e4fbf2ed07402e8ad8075b320c5f76b7ea45ea36af523e95ed63ab50",
            "6ca640f9557c5f2d8b27f6ce95b108880ff4e4816b26b70b6506114389ce656"
        ],
        [
            "4d8284e132e2fe81c5f71be1e3c79ab51b229e2c56c323e207cda179999d123",
            "116cfc00e9fbee1cf16af6282123cdf20eed13021c2037ef4c86f94eb6e6cba"
        ],
        [
            "4056194fb5643e97991942ef5b63cadd89080bf57a01489c4398aca03f0980a",
            "2e2cddb434fa6f6da7859c3d518f0ced8795eea043a6c9613fb3e020103339f"
        ],
        [
            "5d119d5c5ce532afc0875e0ee9b026d878c8773d34237f90a0d0670da6f01b3",
            "4a79fc025ce076b6a4742fbcc8cad313d0a8220c58024a41a5a674c0947e64b"
        ],
        [
            "11800ce4061d99b9d53fd4138802335258f7798c5a935c9979f5a949ce1d483",
            "36745a4741a5c7290eaa8f2a3f9ec955ccb7ca323272e5d35d35c2a724ffac8"
        ],
        [
            "4302525bceb97fa642fd5560a4a39fba3d2c06f68e6aff3332ff1854439ebb3",
            "e31edfd081ce82f8177b2d7d96e69851d09e908c2517114ffb37ee12c0ac64"
        ],
        [
            "2f5fcbb96f0a66fd3bdfbcc78bda361cb812570f50e7c476533d56eee01c0e3",
            "527428a34855b5695c479d8fb7e831a299f7897f36682a74169cc60d160df2d"
        ],
        [
            "52167df045ad0dc999b98de3d035aced9da4434211149b8cf4bf20e774580cf",
            "19051d2a1ad3fab190c5dfaf45188b49b4e90cca22aae54f0a785562d3d3f41"
        ],
        [
            "541b5332491dbdb2b6f6bccceb7634970c046963891fae936dd950f4432b961",
            "78fa54da996a51e3a9c06091d58c2405a806649da2bb1f323807c4eec50eda2"
        ],
        [
            "5f11e973da659b7738f87ca5bd4f3bd02207dd3c8d978f0d3e83fe81030febd",
            "137aba7027069f62d25caed416e13537687bb1428e71e5f0a0c52d52f2e65bc"
        ],
        [
            "15ec941ee6c2110b819b5541be52981c09d83484c9dc735c43f39f5778718b4",
            "4561826142dc5b56acfcf605a78a4090472bb61235bcd605a765e05d0a7e549"
        ],
        [
            "68ba398736d659522f484406110b43c68158bf4992094acf797a38979c587a4",
            "7c1d9e1702e28afddf22fed7a7a79df4315c174d0c6c4f4c75bc77d9b56777f"
        ],
        [
            "67889cea31c81a429fbae643a4fce0ecd690a5c32b99397e39ed6d7a08702df",
            "7ea277c80b671146c9e455b98f42f45b941ac95ca2d15c8fa9ea82ee9b45e01"
        ],
        [
            "596f2c68390ac26505d3c2eca5c77d46f8f3acbed192a2649d8c525a58d2334",
            "49f3bd8c62c610d5c19c52d970bde24b270c4ff7ae900453b909e72483974a0"
        ],
        [
            "567779fb8b0afe592cea284629e3621ccfae3c4d7d3dc559c9fed750591a395",
            "6010bdc33f1cdb374facefff537e7910b72a1120502f312a7ce41df0d552ddd"
        ],
        [
            "cebed0233e810aa6a29a8b0829d28f1c92f303d14dd73d6b12da98117dfc7",
            "4bdd51e1192a00df23aa8d0673e4915877ca41ddb8c9eaf21d39dd167fde7b7"
        ],
        [
            "4c7085f066adeb6781596771972b188177e63f2e2b3788d03e033cdd5af1f06",
            "2929ee89f525862b0cedb3ab9b5166e1680cb77fb4668f10a6a3d76b5434566"
        ],
        [
            "760e341bd836899c226176f47685f69438270c150c6fe7744cd723cd1e72359",
            "1bf09f2f1aac1a10ce8bdf20d5d178db747f01a4aa0aa8a5e4bfeef562cd94e"
        ],
        [
            "6016b94c00b54920027ef64902c61478244b1936337d2ad41d9a8d43dd6a4b2",
            "3bf3dd9bce7f6d6f120de87fcbce6219340b59c2c1d75ee0d45105d33aab1cd"
        ],
        [
            "4929e44ff692eb944d1045bee96e750219cda3bda0500029f0df49a1db30b5b",
            "2e138dcbd092242699004b4ce98764ffe4e892841f56830af298581cd1e523f"
        ],
        [
            "5972d0e526311bacb70a04e88969b6c63c7399b578f0dc28bbd00d65ef01da7",
            "76b22bca9ac12d26530e7b0757e646beb3bbc5680d0f3f82fb8ee57ed4b5e39"
        ],
        [
            "2ca0a42a26e26934ca2d48db960b4719113d87c5e57fb437d557c5eb4e03ac7",
            "62778c02561d4ec5d83a132afd7763a8349207c6b5d01fba70b56ba660cba2e"
        ],
        [
            "5137ee53f076e21a2c23da09f63c0d275408c31e4634a6b6373be5cf13e6c00",
            "14fb446c077beb78e04de3282a63bfde12f9af85caaca4ddfab506cee31c0c1"
        ],
        [
            "7d944853d1627b63f560aeda33acf640d35a4ee4d23a744957a2dae9d5b7c6c",
            "bcb411a210710acbcb9ea12680d89e3e4e652228b6786d3886e95f4d9e6970"
        ],
        [
            "37d412c2ffb173a728477446b60b2b702d07a5243cb5fc8963e623a5ee75843",
            "672c79968908f92cd0cb0b4c65ba86e8f359b015623a89441e1bf859bba84cb"
        ],
        [
            "5b37f472aa80398bff12cc74c8ee784c4fc89757292580d3a498bff17e9f114",
            "7d79da1aab9cfef58a5f3d1c9ec466956a45f8d2af0c1da6dd4c93f720fae6e"
        ],
        [
            "25c09b3f1188c562571536202eb0f5fc4b9a7590417b8ea58b4343685d88a63",
            "3d5b817c73b37e9a1d24ca923351359b42ced2f3cafbcac8c2d6322dc767bb"
        ],
        [
            "32e60904e73f9756f71e0a918d302aeca17cad4acacc81bab15702ab5ff78f0",
            "bcf4c0204f8275072f98a65b09ac58b87cdc9c70c4edfe99fe18870a3a5459"
        ],
        [
            "49c35575996c1517d2daed90d2fe4a58e674d6b4aaa7288d0642c8bf59e562f",
            "57eeee00adea4ca80eeabab57852cbf03f1a57e21872cd44221e0550b9193b8"
        ],
        [
            "10e1776b4c2a867bf1b028c6edec224cc6616c747e272f49e69b67b02a893dd",
            "8d45d62ec8e627b56950f2f7622a0438647f9e9f28e723e4a37cebc039a1b0"
        ],
        [
            "79a93a75ecbe943acc964fd39ecfc971dc6555b2bc335e7b53f52f4eb16cd36",
            "146132a68ce2ca8b48363612226771ac547eb3cf52b6eb7981718faac08aa3c"
        ],
        [
            "6b22d32e0590e169504e7f19864fd646d0994e7ed3e578a5b88f6e095913439",
            "68c3b22d859fb85e5c8fa0a8aea932285945b230957e603394333e9ad5acd82"
        ],
        [
            "71ce5ec8286eb8c93b8481c6d19cf0a288ef4da4397e9c80f65023e516bc097",
            "54470babc742780cd8a05499026e738ccbf81d4170d1731734de68a8e5b402c"
        ],
        [
            "27beb13a43bc6a1f6ce046da438b0beac5899ff4d57962dcfb6476b563f74b",
            "14074e9e93ee45394dfbe833998b9d1691961f8ba3166224b36404448c61bb3"
        ],
        [
            "6b1de6c8f161aa6509a1dcacf2c0aa1bcf6ee9d9b40e032a9d72f77a6fa298c",
            "5e9312eb5b59d6cbadd7d3dcbc39f1b5bd9a8346fdcfdf1107bada6f9cc048"
        ],
        [
            "32670fc3fa43bf39974ba72ea51f0d045d92d084a81fe5282dfc8309aa900b9",
            "518fee521bf1af62356aac3b7e53fdbf57121e030c6e9572b3de69912ca4eb4"
        ],
        [
            "4b9ca363eabed9c66091a347375f7065cd28f49f914447de7cc1461f1375f1e",
            "3a1a3a2e5e7e72476befe2571ece708052d740d02cbe6fed58740968ae609c4"
        ],
        [
            "4cc6da42863a3deca62fa218b7a3b50e034eb4bafd393eccba3f4cbe192ef10",
            "20bfa683c884f203713953b26d2821287ecd305fa2cb70570474533fc07f918"
        ],
        [
            "87705353c44a5ccec8de65cf5433be6b3d9bd21eea49b60e6c907cf1a67a6a",
            "112804b13eee56e3b01aff75fa08fa8374c44fc461aed8a30ad54acd09c24eb"
        ],
        [
            "6cf6eeeb9d339c0a05f72fd5af73fc7588e6d957100ee8999109437bc126cae",
            "54fa257cea22032eac272fcd034dadf2e00d602ef9e519cf7072023c130aad1"
        ],
        [
            "19b32925048c5519d929650c833661b452ef7be7963fab0b6b328ab7dd7a28a",
            "1bd0c14a10bf9b88ea61011c0b2e64d07da151c6203800d5a5d12063838a510"
        ],
        [
            "12a5fc5559428bc3b4eff97b21b63668b866e0722807f1db1f19696bacd9b0d",
            "4c2eb07f0c24047a3d73b560144f3fd32c99d6dbd9fc7cd2fd2a72a6e4b24c7"
        ],
        [
            "13662b7a7d390aa76eb86a7c3bff6d9913eb28db6bd1a7c42de5cdad2e35ce2",
            "40626aded7f56f82cc431ae30527b096f57fbfbc04d3e12a5abae3edf301cf1"
        ],
        [
            "255825bd49b8a2cce114360bd9c8fe8c641af64c8e7710107213cfcb006f43d",
            "3619cce4482335232f9e76a1460be9d296f2d468d26e4f95a78c71524fe59cc"
        ],
        [
            "7f83009eeed4f12f54d341bbf06066480cfcdf51dda103ac54d4bcecf6b3b31",
            "4269519d28faafd7fd68bebfd8404d71ba05d62c4bb6d65d24aa6802fb84ab6"
        ],
        [
            "2f325650eb316646b4eec903fe44828fcb11054f1bd42ca3a77f7e734110b35",
            "44f976082271016f9048e22c507d97d628722bb431f8d5cc1890524e6c386bf"
        ],
        [
            "750b166bb6edc0ee80fae39c7c106879036738df2d79fb2294e1c21e9a24d6b",
            "54f8aa297a1afafe2a17a3254f45861167414327e918d17003c6aad01d0b24c"
        ],
        [
            "3aedb10db9cf3285cdeee375879396fac1fb50dd259e1716f8c01e66f67ca72",
            "7feb9400f621f58c21601f23b7ec7c94a9b6b193c1cd74a8a60846aedadd359"
        ],
        [
            "4ab7151702de76faa493e7a0b1ac20ee4d10c33b83fec9477547cb1236973eb",
            "63f1f122e3ef3acc46b0915ac69c3f5772879799cad889a817f55f5853d1235"
        ],
        [
            "1675ead0d20e5bc3a7a7331999a87ac4c916ae29669e54197bb02aa6364520f",
            "4d1122da90d49e491922d9b533a6a668e2f65a2737ebb391ebb29fb7c1f8a9d"
        ],
        [
            "2f7148111ef53c613157aeec12e16a20f13481da4390b6ce18a85d1d8547087",
            "2eeda779ab395597651d2a0b833ccf53b10280750139916ae2baf4ec57c633d"
        ],
        [
            "4439c7810e7b2ba772b701ec3acdca0b80c9df23047710b87f7dc3f13b337d3",
            "5029cfe704c602a8a4662af0a5860ec03fb88f046d0e3400f2ce7638014c621"
        ],
        [
            "2248eec40b5732a6a488b681f093643af7937071bc73118acae295a32b51b05",
            "1577e4aec30a97b648de4d0b19cf8891151b4eb11f8de9c6d7312f091552e19"
        ],
        [
            "4738424e558d4e0d87a3124ca02ea24f0adc6b7a9768b0d3945ed2a6104857c",
            "33576f92aca3f0c8ae689c3c274c2de6b918940d86a6852e02fc99e35d1614"
        ],
        [
            "7829edd8b866ebf7baaf604ed13d19a9797578f44bbc51b1cd67ca53803e96b",
            "5559040a6083f2af1f9133ccaf5bc2ce06e56ddfc7dd410e9635c0116b62722"
        ],
        [
            "7f927b881f2cdc05e1a69e40bb714af47b630d1425f08ab5d574ee698f33d51",
            "26a465288e96572de303203bd38f4a03031e8158da0591cb037c0a5111d1056"
        ],
        [
            "36a65598552f8753580d1655417d645a140966e10a1e1663015f9fdfae44881",
            "33d5bbfaebf59eae72b89b1aea12ab2ba3c9617f8c3baed1ec16bdf668381b5"
        ],
        [
            "403becfa545c826782026ff409cc16c9d4fe428f1b5b6e630c92439d2fa5fd",
            "47bd6f2bf5d74f710ecb479c79b01fb774fbdad590e683a415cdedf33f71dc5"
        ],
        [
            "3a747826d241b877d3d56b16e0b810cf088eda4fd6048da174c9991a942a5eb",
            "2c7ba19b0a3486a2cdb84d4a388d34beb077a0e467ba44590166f93f6a09d2e"
        ],
        [
            "3d60cd375842714b37bda89dd1f13a7e0f3ff133b522209617d031bce05a537",
            "f77f216451ab01ad5226844d2162a7f32744688bcb4325445539e2ce5cec4"
        ],
        [
            "235bf66f67c9100e7f0e22bb299cdfaa603644b240e0770aec7e7fd163e2a65",
            "37110b3fa83ece3990afca2bea8d5ebb3c7aace60a0147f8e6ab733e2f2b4d5"
        ],
        [
            "3b796d4eb69a55471fa86108f787b3604874e92b6887a7667a6c2bfbbd9a42b",
            "4912d6dc0419732ef82cb3278415851d4e2d7ca89e0f4d7128cc9de51b810fe"
        ],
        [
            "48d53516dd51e49faa7ab46c8c10db1befd10f23c6a9d9bc3640a2f0da44518",
            "73a2fb3d064adadf21aa1362c04affc660598f38a9e069b3afb74d0a99ae9ee"
        ],
        [
            "48c32cff161ed145da0d5b73084897647abb777adf65738559ceab6939cf3e0",
            "3d99308978e828f857c382df32b472bda81e8ec8e30c8844077ba6d6d2ba903"
        ],
        [
            "2947ff091a8ec9684affbc9a62e09e598841c4a6dc638088492aa47dea57097",
            "19a2cc97975e547f97a4d02e42f89e6ced6f5a953cfccdec347867d26926541"
        ],
        [
            "1960d85f30475615f82484eba0bdafb7ea7cac3809f0518a757d66f02b01676",
            "36c8f77baabf0cc8805d993bbe62041fcf4e3239cf9d53278a4fbd91e75eeb7"
        ],
        [
            "2765f28074d21d5a055340b6d40092d2bbef807e02009fabfa08ec0b9bdf38b",
            "7fb189e0553d5df52b6843661814824b3f3cbebbd54988f042fb256c6bf30b"
        ],
        [
            "348836cb2aaa00212f4b1a4e2d7fc5417f246bf2fe5c9a16ebabda449e2e08a",
            "3f7276fd7d69e0d55ce5ee1d2d830534a27227fe0b6d8a36c93f9a78b872969"
        ],
        [
            "7afb9d34b6a42ea8c6d870e4b8191c274201dc1f93a1a2219a2392b7e345a31",
            "42bbc20dc7115e0758b364a110227b16b64ec58fc535ce5ff1a9ad8b8a09fdd"
        ],
        [
            "2cae0c2afee1767fd4c66f52e1f176d217e92e89cc19eb36d5a6c1715f641a",
            "5335efe2d9bc3667d25ea88bf76438a4d6ab9ba5c512f9da7d0529b79b62d83"
        ],
        [
            "1cc5fde334707723c3a06f00c106db88664284a2df47bb6b144d9f960aea3e2",
            "dbbf610d100316938bcd8bcd078513512ecb50d4579690dbefaa419c05980d"
        ],
        [
            "54e90cb8f3a2998d2675c5780679e06c0556b1e618f8fdf07f9a4b2466fbf1e",
            "16248676b6f06ec5e34994bc3115f85c8147b54f34d8500928f2fdc051e2089"
        ],
        [
            "525c70a2ba0dbdd68d75640f47f13d0d415ea595f7030f533f4625c2a46523b",
            "58292c8675e5e1a438f49e0c05648d9a7aa997f2f1fd77d5de1944afe5d7eea"
        ],
        [
            "54726d78d099007393348787a03107ab492e59690a46c87fb02ec554f2353bd",
            "53b54b77184ba75a3391e0ebfa6d6974db028f3f8e34bbd5460759a5848dd76"
        ],
        [
            "4ac81a66903537769d3aac6c483ccc08535cb767b6b5e1ec8017a7393ab70ae",
            "2cb22b77a8a05d26f11a4dec80eff292633aa05553a889c5ab16b6ac6e2ab17"
        ],
        [
            "21d0175349e21114988a2930b9a607d43245783cb4a0c984ce27f4c4206708",
            "59f1f49342cc5496213d3329bf4ca7fb0044337449c579bf53147a1dac9e67c"
        ],
        [
            "167f821b381f4c8adcc39789475fb55ba639e5124fe75f26dd61be396dd5e66",
            "22002c87d4cafb47ac9d27286d5cf5ff7a6715d69814118269b0729be9e4b3a"
        ],
        [
            "31010666c6db83a9f9e4db4c48173afd405783ac53852a6e38a8ff925528843",
            "1f466dc9b5d9094107c741dbf380f9fd98d8549cd50f67169901516f8cce74c"
        ],
        [
            "1ad3875769a5053388a86edc85dd80fdffbbda6a456aea497ff81a0f1f6707b",
            "2de7cdec5e2bad56a71bd2f33a4ae4c874e1ad4210a6ac32b443cfa34e85b1b"
        ],
        [
            "c489650fb7f459ce09cd05a456fc5a46b849b38a671298ed645bcdaab168b0",
            "45610d092b8af1c43ceed474cd17f7bbee65120aa6fa4d37f949e7e41f25327"
        ],
        [
            "394256a5ef4d7af5459587a0bd2edb8acaf5ecfef2563c9a04daf34a4abe4c6",
            "1ebee390dae1403c0c53994e1d064fa64e20fcb45392e209b2b99486a559ffd"
        ],
        [
            "410a1511fead6151e9bedb089b9832d0fe01fab76d3f8459929f767525aeb27",
            "361f0a5ffe09fcc3ad4eff3f5e89508ac247af80267100b69de3c59df561cfa"
        ],
        [
            "38cd437c9f659e110a869605c182ee9fdc26de36baf559d9229e258267bb734",
            "624b1128ea7739bf1cbd0e423af92a4884323c868d2ba0ee9d362946edee2d1"
        ],
        [
            "78b126e50b7042d2a019f95cb87a3213c664ca1bafe345999b1e9e2dac1e608",
            "19e398196b22f4488cbe854c614ad8c353839abc5ab3a4f3f5c03c16ba8a198"
        ],
        [
            "6d3a5ce91132f385a91823c5c8046c4b638f5fe63357424410d901457cdb867",
            "7b80bae16d2d487e122495174f7a70992bc5dafbed72bf84127ead7c57302bb"
        ],
        [
            "32d053a904dc4d88fbe7d0b96e0cbeca22a00aa5c79c753d52b0b60abf31602",
            "3af6a02e5cae6d6490354ae51185149e3fdb6d0d9caab90e95ff58aa0c40377"
        ],
        [
            "49b1fbff5bdb0aa6938b066dde0ed772c0d81f9eff52e7fe038b0ccbd78adb5",
            "1c6e57834eb14d507eed8b36c81ddf92fa91c242467061927a742fafa82b43d"
        ],
        [
            "2f28b8994ca6f234d9293d26196b43b9d1d5306844348c4a638102c05de85f5",
            "759cfb172eab065d477248b3569f4ff5791055f01e95fe71b94b8e615d73c96"
        ],
        [
            "3c2ee954ff534f856f59188fa0f29ed8a022aee0cac52d634f6dc58cd514d70",
            "22bd162e74925f0a876bd8a206b8767dfdd7c898576a73a490f138d9a7f99c6"
        ],
        [
            "5763a7cab001e1aaeabf9ab5b9b2fffe6cc2b299ab04ec4933da74d960e1ab",
            "715ee4f8ee93ab5a1dba00f0a6abc4eec47d49b61254cc27fc36a031e32f0f8"
        ],
        [
            "19976ad8d7b7f47c785408243a227401996b36e47c7a78a7bc7d4256233ba9a",
            "896b713c5d7777b0703821a73c1d9a4c3755501042120534ff13990975e1f5"
        ],
        [
            "61674b992c29827186cab5ff454758dbbed8e89bc23d0bd33193afccc3a04bc",
            "38e1020744c13903809ea30a0662fdb5226ae760cdcf10800faabec452e00f8"
        ],
        [
            "2ea2d48bcb83c0c9cda4efe11f07165cfcbc9ccd26526e5fb12556316d4b1df",
            "1d2d68b74ad384c5c4a9c85453104216357bfcdf635680b40215f0f800974cb"
        ],
        [
            "7881212050264c40c336ed3a15dd2cd868ec9a558f5b728869eab66e8b8ed54",
            "21aaefcc8ad8a161b8971d6880321781dbd939570c540da4c330922b8c81e9b"
        ],
        [
            "b6be88ce0461d20f59c5199573cda0170b61decf6e8e69a6d32f1695adc4ed",
            "5536e4808370716f2bb3423a9a49a38ddbfe91faf3b7a35eb53d3519238b6cf"
        ],
        [
            "e5972af1655eb6dde2e8c77cc58044299922441b5ee41ceaf5cafedc765bcc",
            "550282f37a4783dd60801c237045992d6fbe82a5902e7d837ea25f6f98c7b3a"
        ],
        [
            "7efc1aad1f580d8f50274f1c114c40056be19a8c96fa8c4cb5bf85e1e7f3e4",
            "2689f1c3898b114d668be6413643ee9f879913d40c262541fd0316264c60a4f"
        ],
        [
            "7939db98037f59b0113e9d60051f75ac9c3cfd1a3eb535c73e2d945068c6c5c",
            "410914ca8bbf3c65cdf3e9772ca790c19131c50068d34b7346c10260a578a8e"
        ],
        [
            "225b77ad00a2b83d26690190b74867326eca4f55bfbc3a13be036225ca3b1b5",
            "411faafef89042ce6beb64309fdaff70fa53e9d32d79a21e7f82f80e79ff05e"
        ],
        [
            "1501e64c99c8b6658b0479f2c05c9142d246eaabfccf2fcec8dc4399539d8e1",
            "3bab1e3339e42c9ee66c65b0b20236fdd9362d3ce786ad3a9779ab578af50a8"
        ],
        [
            "59b907b941f24fb8ea2458153e55f07534b388e835af7b69f3c9f54392a335",
            "1d5438c4f2f68a417f3d56f916d899a6ffe910f5f2989ca31687f1b10f60db8"
        ],
        [
            "2887d08a26f484546f360e33abbf7a998b7170a5b30070938b84f072c676bf3",
            "62a78e8d00e5d3a59e2fc424ffa08961567ba1ef24c8531cd7bceee6074a535"
        ],
        [
            "6e3cc8076b3d45377929033af35aab0c6d19ae4fd47c0daf844079ca04c46eb",
            "7b90f338e4d848aa8f19d0b5c3bca916a2a9024acbf14bddb278bca2aa39e5f"
        ],
        [
            "34844dacdd3ec54a3af328bb9d67715ab33425e194ac9977ca02ef22e8f7a88",
            "3c1affc6372f32a1634748124f9e1a03c4f0c993971da0dc28888b0801279d"
        ],
        [
            "436b192e03a49796cf9bc5e93c88268b71c9c24f9c3a85322bba634ebea309d",
            "67a8091ef69d62abcb28ce5df4dc7d53f8dc2b9690344f75ecd03a6d9386044"
        ],
        [
            "592d25b68baff87a6d7fd41ff0dadbddc1bd1316683de3b2d677501c0eb14e4",
            "27ad1e1099683f54589010faeefb19e38569ace43653be8787a42b0591e7bc5"
        ],
        [
            "89a5111ae911512ba62e87b97f643c0219702f235c70f62c6678a129302009",
            "557fa3d98e9ce7b83b47545013a4498f3de43787fb66b1a54521222242f7c1b"
        ],
        [
            "1c9b5e53377e72da5066cb08566bbf9ec31ec1877f455d932cd9b1aa375d34e",
            "72f79555a8bc207863f32d482fca54692825449fd8963fcea3de3a8183a739a"
        ],
        [
            "574a6e05eb14591729515be239ea8c1fa9e12d4049d42876f76c8ff37bca03",
            "5f99b3af43ca68c1c73e8190d5f73c8de162ba643d7d5f0cd73cfa8135db6d3"
        ],
        [
            "513fc5c2e16505b2b25a2f284e167d5401194bcac0dc3ecf8b7c9acb560daa1",
            "687ee7a1a8954d08d3856e1a16ded808e419e789736d3f55f79f7693bad69f5"
        ],
        [
            "53d48bd1205274b1c2b0a0ceb3d21c5fcd7c8892a784931603240b288a598b9",
            "35387abd7ea59c9b956de44d36533cad1f6668c438d666651695ff3862159be"
        ],
        [
            "213eb1ea99e08825110dd61094eb6e8145119dc1c507636f068730b1e086d44",
            "744f6853f4f02f4f042468d0739e0c9f64df720b87ed77d1979547084ef7a89"
        ],
        [
            "735ef017d091ca23264ad0aa7bb9b2be3309b4539605e79ed4a652ccb2fbe3c",
            "7f0ccc7a5747c4e921fff97d431169f690763427e2cfd1ad74d7a0308d7faa9"
        ],
        [
            "3f36babc5a30070b610ed97db44997e6d9115c9c0579ad8f75d295a17130001",
            "79047908a2474e32d5c712a07bf5c4ad522590bb5d6cefda410d30528e12ca8"
        ],
        [
            "51c04907ae88a5926b242fb2862cb1f2c651a94e6caad5bff8601c079fded74",
            "10a585a269f460aed43f54c7de13cdf623fc8de5957526997278be939ef32ad"
        ],
        [
            "c1e1bd626a735aa2c065831317217ecce68e377eb1f67e54ce2e97bc2ef2dc",
            "53c5af23a9b482f420be6dfd37b6886154cfd130794098e1f51c1885ac2556a"
        ],
        [
            "5aff3b30775ae4758e604a4a6262803a545f5ef4e7855fa245ac6a6431a9ece",
            "39a4799e5519047f29333bee9c86c99bfa8056d4aa381c396c4a44331fe795f"
        ],
        [
            "3d753e9723701a8e9d99b91bb93dee2eda7ffa5072fb2cd5c5fd99aebcdb299",
            "15798bf5c17d6d5880fed1553af32dd8d8baf2888c715a886575448a24c7975"
        ],
        [
            "6593e5078466b07a4222d2e544da826d2c583c9cc5f2eaea148b129b00d4aa0",
            "11b352b08a0a61d3cd67d1dc08069dec3bde907b3da0f56de5011b956bf8744"
        ],
        [
            "7a6eb353c5be9ff03fe4a06c01fb71aad2b38144179a291ebcbb2c2417cca65",
            "3de3ecb12f2fa699b46a9d399abf77ca17bebc3e491bfb2542dd0fba991e2bb"
        ],
        [
            "2c7ead583d6c32162091034a9eddfa775b4e84b8bdbea939edb2a80dcf64f6",
            "461790ce40d9c276d962b2a1e9a74d66e9d7335962e234e8a2fc6963d31722d"
        ],
        [
            "34285af023d9b4c2c2b88e8704bf2c05a9b553b00b2e70ff05f8c2970cb134f",
            "33fe678e7671760a83836107428dbade68c3593fbe568f3f8f1b2c568099c44"
        ],
        [
            "6222f720a24466263db6a11842f117fc4bb78da6705f140e48869db3e087441",
            "6eff5b9bf3aeedc962bc5a24b66e7bdad2153450ed53a058bf2c8dbf2907693"
        ],
        [
            "17c6ec5ea206eb97cbf53851e37ce391080e0d2bf1e5395610f79ab0503f7ce",
            "3adb71ca3523d88ceb1e365f12dfb24895453c14daf0046b2626cddadfdf5f7"
        ],
        [
            "70859f9771a713e54974ce11cdaf44b0dcc3e9befa0c0834908d877eeaafd27",
            "d18f794bf0cc0623b711e7450030424e52326c45ba9b03341883ae4828a5f8"
        ],
        [
            "2a820cfd0fd4ab0871e7b303cd545a3086caf8fa818c087a4017197da74efbf",
            "5f992683ff37f6c041b84bfc01503d333ac9763505cc8f69473da01812969d1"
        ],
        [
            "5b0526de2c07fe7cd73e3884f642d57a0ac5e13c68590ed03a14e530616e8c1",
            "eec69d0cbd92c9fca31ec967dba848bec368e792d6678797946a5e34fe3487"
        ],
        [
            "6cf6b3efee707210cb3a72f1e885c3d0953aefb43e5e148c740aa1641725c61",
            "911cb630b898e2c1a9115f9e45bafe3b819edfb1eab6e15612d14289939984"
        ],
        [
            "74e913de55f1e46143cb2ecfc580f8d3d3908f200281322b84e21c989cda293",
            "761d2736c9ac7670ba905bc2629c6c0dbe988820a4454ff415ba68710f7df92"
        ],
        [
            "44084305e0c911a40b7cbefe5f13cffe9a99375d1a584c4a2200958050af7a9",
            "249c83877371564708ea525b64b1e7e12785460d83364446531c9adcacba5f0"
        ],
        [
            "2bf71ad4d1bee1a67fb300477029f54bdb0e09f78bf2ac2e8afc7465a7adbcc",
            "6244dd6cad282539049be57487bfd9900bb0d5da805d02b535096368fcb4cd5"
        ],
        [
            "3a62d8f763b62def36e4089458046a49c5ecb91b861549530773e0548ff2bb",
            "6a10a03ba61e6ac657270465c09aa9526cf1ebe96bdecdf0e7000476a47b9eb"
        ],
        [
            "284eed3a17c51e0677d4fe897f056abe9def8af07a4630e6ca5723e2aa6677",
            "516a06ac1d5626ed03d2eee9de6f60f0311eca703a99b0fb31b9c66b01c27c7"
        ],
        [
            "2a2c63b16cccd685f731d06fe93ce2cffb358d34d03dda9a7368185c1eb0c32",
            "7180baca0ba81284809f92eca1654cd76b925a9242e5d5e0f18d0a55d13c6ec"
        ],
        [
            "5f9466017ec09769611389ea5370ad68dda936d3f5816c9e928ff9574abf9a7",
            "6619b5b145bb5f4f29deb7a4cd68ef4da3995312fa6537f0d01684da4267ece"
        ],
        [
            "74f229babe01b4962b3307589c1a13019134b1db6822698388bebb55d21c30f",
            "156ae857ab3279f754facba0db36398dffec8c31e5e160473198f2f891b7531"
        ],
        [
            "334b9fe3a5fd99bc966ddd1309698fd32afd1f235062f2c275b6616a185de45",
            "221a60053583cc0607f6f2e6966b62fc9dac00538bb7eb1148e007a92116d2"
        ],
        [
            "7ad710ba002a67c731efbaba2149d16fec5d2f7aa3d126fd9886172e9f4ea30",
            "3a10f8e902a7a13aec94d66415347e1314f9bac83a7db176096b809b25ffb86"
        ],
        [
            "4306dd0a184a3283c3097ff8f7434cec80912e9dc04b7df21ba73fda9f8e6d8",
            "6d42bd3d1a8dbddafd09e872e2aa3891ae79ec939dc1b382196bc21c4ab749"
        ],
        [
            "1c3f2124e1135c32a426d1d14e471edd9e0f2c7bd703ee123cbbd608e8c4be7",
            "3cc607a3c3f1ab68dd5fa56c65996002721b8ad8ad4b0dd9e5b1467d316583"
        ],
        [
            "294af33272ffcee0b56a436de1b73759cbddebef4c07888b42c2f92b0b68e1",
            "d837164311d5dca8d37b99ef9eb22708643c83d1cbdfe852f63ea07b06fbad"
        ],
        [
            "753bdb5439a19bbffdfa02b1dc24e8368f22d0a8276b109c11e6feb26f56f39",
            "6ed396231af93647633eab467f1a034f38e76823eb85baf97cae56e2dcd9f75"
        ],
        [
            "5674f0cb892b733fc0b50e121d8679afed0a925c32594cc65ffe83bebe7748e",
            "7fbf0325dd38dd94905adab2c52758552292a6a103d9edfcb11938828e828c8"
        ],
        [
            "4a8f053573a0a74251059d0229d89b6660407ba0b491779fd10f87a5117c81f",
            "21b70112485398bf67ec9d733df24a1df30dea718a93b786f41ed04e3ae3c5e"
        ],
        [
            "726c01ec4a08df8fc8de173311f50d4f3b97c5a9cf68c1536146f827db95ae8",
            "15013cafadefa7f1c4e4dfdd70bd4d3979dd18bd7f0332572ce2a3fd8773d12"
        ],
        [
            "38ac0fbfa98937257460db7e6645d7e5112b6fce7234813fc8a704e8ade8da2",
            "73c0109f86048aad08c443f781ae60ad13b99f7b9cfdf3128fe6d6eeb799a7b"
        ],
        [
            "6f6d3a38621582ace092eb50ecfe9eff265df141ebdcab8653299116fcea291",
            "4a1bf3f39bc919c8f1b720a0b1ce952cad17f2ba98308ee6b76dd9b6f3d7b75"
        ],
        [
            "6a307fc28e1df8d9ad01766419e097797d65cb674436fa1c8f012d3de2c2a1f",
            "26911a635ba824db004875d79dd84834a97ac12643e42829015bf88c1fd6f05"
        ],
        [
            "2a74860e3336d6db916555894cc8028f41508812925db1925457afe40257155",
            "5f8da573f4c39816ce2dba8a20224223a7cfec53117ec78973930c0e9b60244"
        ],
        [
            "4d2b49e1ed0799f719b8269f092cb489a466a645bc0ccabafdc678864c176d7",
            "5410083df7d256f18cbf5697ae5e52c31e075d8a3b27e21d6f5177ca882f6c1"
        ],
        [
            "110ecb9fbf6c333d168cee473cc5ad98809b6cb9eb5d1f6cd28ab5fab504fd3",
            "7e3c54d7533d9f8c3310f219dab0cc3ea4d39b418a748eeffd6bae2b8637a43"
        ],
        [
            "5be4d711b80da70e6d3ac493250bbfd16f20b25f31919b3a91cf14ffbac1096",
            "7f55a0919f082e8885f1515e83c5b39b6022404503507498e1b4422d79c43e2"
        ],
        [
            "2605125b95ca4ba93a21cbbba5762898a7cf9e988f07ab9e64cb3868e3b139d",
            "62f0ccf55b9fc0eaf9736fc8ee484e2acdbe259813af9803cf815829a5e9d3b"
        ],
        [
            "1092bbbf206f2a3068167c3dd99a72de31e206f6c504c071c8214d105ff814d",
            "309f489f68a62089f53b96df5d4fbc3ecc5a1a42eb7ece0e49bad17ad490ff4"
        ],
        [
            "2abdee9409d9c92559ca3f4e6bddd649c31aa09b90bfcb4a612af491241e18d",
            "3ffa8eac180a29de3f8a69efca84bac046f921f5725e96a6ff0530be1436aaf"
        ],
        [
            "376313f27d00bb1aae7ec991745efe6ee28c6b50de0c6cd9845cc4bb4f83543",
            "6a8e0a9389ba528b156fa94ac090a895d7b795818d4941c29415d9e2984c547"
        ],
        [
            "a80380c71bd466a696b3f0fbf02817c9459d9798f4f3899cf32edf647fe066",
            "6a09805e814e7cdfc76eba4b79f1df5ae559e0f0aba9f728d3cba4ea5c57471"
        ],
        [
            "223694b921d247d989a79b9b2b2f07496036c40cb043eab074a9d6a2cd2ffed",
            "c247217f1b1df35e30d9e15fdaadf42d6fb0edd3a5a7e265d4cdc426c120aa"
        ],
        [
            "102333620df278c6714bbc880fc087db58c1b9b4d77ed4d61b32a74bfc7c3e2",
            "6a77d37727ccf71c2caeb151faf4404d4b94e9047f9f0a7c3966367f3b53c65"
        ],
        [
            "891626f466536929ee7eadcd18b41925706dedab7528ed5f0f7abf039eb9d2",
            "5f73d11c141c933a35b2d0d06e5cbae614a20d17dc3b439f8bcdc3413c5ea37"
        ],
        [
            "215c23fd3f073f870e5e80303967391bf173f8adcdbeec72d131c557babc203",
            "10634332e9d9439a321597dc5b0fac9ff478834c3d6e281735f21a4a5e13266"
        ],
        [
            "21ea0bdc1332bc36e6aeb43be9071651c27e4ea2eadec636c8d818d4af72a36",
            "3a523d9643dccc6bb9c7c58413312caa3e60ba9c7c7f0177e0f3f469a3241e3"
        ],
        [
            "60deaed1bffb6190beed40caaf2bfab5e43d3707aff7ad3f278d571aa247eae",
            "e41f71ff254c1418e6a66992af307789fe04d6606fb2670900bb1a089fd879"
        ],
        [
            "1e1fac4a1646253fb1332fadc21fbdd3e3a24a840d129400f520ae4116a4cf5",
            "69c406f9f46576afad68808de0ab7e8922b6226af748e721d9097e21f1800f3"
        ],
        [
            "5db0ddcdf79ffe74d6454c12d2bc60b06776db03c75dc413f5be42ea9a91b5e",
            "134c3d6c699841f17306835bb193785228ffe7ab212a01a861c56b086a18cec"
        ],
        [
            "626814e320fb5bea505b248fd1c1389ad586c1cfe04923fe2f83173e915f4f8",
            "7ae407a926e887206a8b85cf485f1f327c9bb8ccbb6897024e2d122877d8ee0"
        ],
        [
            "23186237dc7d3b570cea645282ad4c359731bbfa54e7f036426bf6493812cd",
            "7d1fbab7e61a22d3b00993290d9f4cd5d820061573e787f66c2cff9a18e1eaf"
        ],
        [
            "54302dcb0e6cc1c6e44cca8f61a63bb2ca65048d53fb325d36ff12c49a58202",
            "1b77b3e37d13504b348046268d8ae25ce98ad783c25561a879dcc77e99c2426"
        ],
        [
            "13961b56b9fc0e412e468c385c22bd0680a25624ec211ffbb6bc877b2a6926c",
            "62f7f7792c77cd981fad13cb6863fe099c4d971c1374109185eae99943f16e9"
        ],
        [
            "47abd7308c70659af3f00fafe6837298af3cb530b6c2ba710ffd07a6bc1ae98",
            "75d0c8a7377aa9f0663d0c124a5659750847afabc29e39893fd27534a4a03cb"
        ],
        [
            "2c6276b764fb398fa555857dbe0ce0ec18fab7a233bf23851295739801f0585",
            "5d8f4897ce44007ec5bfcb9aeb78b8f6e1d40a514f72d213c9300d2770d2b8c"
        ]
    ], hu = new Fe("800000000000011000000000000000000000000000000000000000000000001", 16), kn = new Fe("800000000000000000000000000000000000000000000000000000000000000", 16), vf = new Fe("0", 16), Sn = new Fe("1", 16);
    new Fe("2", 16);
    new Fe("400000", 16);
    new Fe("80000000", 16);
    new Fe("8000000000000000", 16);
    const Un = new un.ec(new un.curves.PresetCurve({
        type: "short",
        prime: null,
        p: hu.toString("hex"),
        a: "00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000001",
        b: "06f21413 efbe40de 150e596d 72f7a8c5 609ad26c 15c915c1 f4cdfcb9 9cee9e89",
        n: "08000000 00000010 ffffffff ffffffff b781126d cae7b232 1e66a241 adc64d2f",
        hash: fu.sha256,
        gRed: !1,
        g: lu[1]
    })), bu = lu.map((r)=>Un.curve.point(new Fe(r[0], 16), new Fe(r[1], 16))), e1 = bu[0];
    function on(r, e, t, n = "") {
        const a = n === "" ? "invalid length" : `invalid ${n} length`;
        ia(r.gte(e) && r.lt(t), `Message not signable, ${a}.`);
    }
    function t1(r) {
        let e = e1;
        for(let t = 0; t < r.length; t++){
            let n = new Fe(r[t], 16);
            ia(n.gte(vf) && n.lt(hu), `Invalid input: ${r[t]}`);
            for(let a = 0; a < 252; a++){
                const i = bu[2 + t * 252 + a];
                ia(!e.getX().eq(i.getX())), n.and(Sn).toNumber() !== 0 && (e = e.add(i)), n = n.shrn(1);
            }
        }
        return e.getX().toString(16);
    }
    function pu(r) {
        return r = new Fe(r, 16).toString(16), r.length <= 62 ? r : (ia(r.length === 63), `${r}0`);
    }
    function r1(r, e) {
        const t = new Fe(e, 16);
        on(t, vf, kn, "msgHash");
        const n = r.sign(pu(e)), { r: a, s: i } = n, s = i.invm(Un.n);
        return on(a, Sn, kn, "r"), on(i, Sn, Un.n, "s"), on(s, Sn, kn, "w"), n;
    }
    function n1(r, e, t) {
        const n = new Fe(e, 16);
        on(n, vf, kn, "msgHash");
        const { r: a, s: i } = t, s = i.invm(Un.n);
        return on(a, Sn, kn, "r"), on(i, Sn, Un.n, "s"), on(s, Sn, kn, "w"), r.verify(pu(e), t);
    }
    const aa = Un;
    function od(r, e) {
        return new Fe(fu.sha256().update(Bn.hexToBuffer(Bn.removeHexPrefix(r) + Bn.sanitizeBytes(Bn.numberToHex(e), 2))).digest("hex"), 16);
    }
    function gu(r, e) {
        const t = new Fe("1 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000", 16), n = t.sub(t.mod(e));
        let a = 0, i = od(r, a);
        for(a++; !i.lt(n);)i = od(r.toString(), a), a++;
        return i.umod(e).toString("hex");
    }
    function i1(r, e) {
        const t = L0.mnemonicToSeedSync(r), n = Buffer.from(vn.fromMasterSeed(t).derive(e).privateKey).toString("hex"), a = aa.n;
        return aa.keyFromPrivate(gu(n, a), "hex");
    }
    aa.n;
    const a1 = aa, s1 = gu, o1 = t1, f1 = r1, c1 = n1, ot = {
        GOOGLE: "google",
        TWITTER: "twitter",
        FACEBOOK: "facebook",
        DISCORD: "discord",
        FARCASTER: "farcaster",
        APPLE: "apple",
        GITHUB: "github",
        REDDIT: "reddit",
        LINE: "line",
        KAKAO: "kakao",
        LINKEDIN: "linkedin",
        TWITCH: "twitch",
        TELEGRAM: "telegram",
        WECHAT: "wechat",
        EMAIL_PASSWORDLESS: "email_passwordless",
        SMS_PASSWORDLESS: "sms_passwordless",
        CUSTOM: "custom",
        PASSKEYS: "passkeys",
        AUTHENTICATOR: "authenticator"
    }, Zt = {
        POPUP: "popup",
        REDIRECT: "redirect"
    }, Qn = {
        LOCAL_STORAGE: "localStorage",
        SESSION_STORAGE: "sessionStorage",
        SERVER: "server"
    }, Lo = {
        FETCH_NODE_DETAILS: "fetchNodeDetails",
        PUB_ADDRESS_LOOKUP: "pubAddressLookup",
        FETCH_SHARES: "fetchShares"
    };
    function di(r) {
        "@babel/helpers - typeof";
        return di = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(e) {
            return typeof e;
        } : function(e) {
            return e && typeof Symbol == "function" && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
        }, di(r);
    }
    function d1(r, e) {
        if (di(r) != "object" || !r) return r;
        var t = r[Symbol.toPrimitive];
        if (t !== void 0) {
            var n = t.call(r, e);
            if (di(n) != "object") return n;
            throw new TypeError("@@toPrimitive must return a primitive value.");
        }
        return (e === "string" ? String : Number)(r);
    }
    function u1(r) {
        var e = d1(r, "string");
        return di(e) == "symbol" ? e : e + "";
    }
    he = function(r, e, t) {
        return (e = u1(e)) in r ? Object.defineProperty(r, e, {
            value: t,
            enumerable: !0,
            configurable: !0,
            writable: !0
        }) : r[e] = t, r;
    };
    function fd(r, e) {
        var t = Object.keys(r);
        if (Object.getOwnPropertySymbols) {
            var n = Object.getOwnPropertySymbols(r);
            e && (n = n.filter(function(a) {
                return Object.getOwnPropertyDescriptor(r, a).enumerable;
            })), t.push.apply(t, n);
        }
        return t;
    }
    Be = function(r) {
        for(var e = 1; e < arguments.length; e++){
            var t = arguments[e] != null ? arguments[e] : {};
            e % 2 ? fd(Object(t), !0).forEach(function(n) {
                he(r, n, t[n]);
            }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(r, Object.getOwnPropertyDescriptors(t)) : fd(Object(t)).forEach(function(n) {
                Object.defineProperty(r, n, Object.getOwnPropertyDescriptor(t, n));
            });
        }
        return r;
    };
    var Ts, cd;
    function l1() {
        if (cd) return Ts;
        cd = 1;
        var r = function(A) {
            return e(A) && !t(A);
        };
        function e(y) {
            return !!y && typeof y == "object";
        }
        function t(y) {
            var A = Object.prototype.toString.call(y);
            return A === "[object RegExp]" || A === "[object Date]" || i(y);
        }
        var n = typeof Symbol == "function" && Symbol.for, a = n ? Symbol.for("react.element") : 60103;
        function i(y) {
            return y.$$typeof === a;
        }
        function s(y) {
            return Array.isArray(y) ? [] : {};
        }
        function o(y, A) {
            return A.clone !== !1 && A.isMergeableObject(y) ? x(s(y), y, A) : y;
        }
        function f(y, A, P) {
            return y.concat(A).map(function(N) {
                return o(N, P);
            });
        }
        function c(y, A) {
            if (!A.customMerge) return x;
            var P = A.customMerge(y);
            return typeof P == "function" ? P : x;
        }
        function h(y) {
            return Object.getOwnPropertySymbols ? Object.getOwnPropertySymbols(y).filter(function(A) {
                return Object.propertyIsEnumerable.call(y, A);
            }) : [];
        }
        function g(y) {
            return Object.keys(y).concat(h(y));
        }
        function v(y, A) {
            try {
                return A in y;
            } catch  {
                return !1;
            }
        }
        function w(y, A) {
            return v(y, A) && !(Object.hasOwnProperty.call(y, A) && Object.propertyIsEnumerable.call(y, A));
        }
        function E(y, A, P) {
            var N = {};
            return P.isMergeableObject(y) && g(y).forEach(function(k) {
                N[k] = o(y[k], P);
            }), g(A).forEach(function(k) {
                w(y, k) || (v(y, k) && P.isMergeableObject(A[k]) ? N[k] = c(k, P)(y[k], A[k], P) : N[k] = o(A[k], P));
            }), N;
        }
        function x(y, A, P) {
            P = P || {}, P.arrayMerge = P.arrayMerge || f, P.isMergeableObject = P.isMergeableObject || r, P.cloneUnlessOtherwiseSpecified = o;
            var N = Array.isArray(A), k = Array.isArray(y), D = N === k;
            return D ? N ? P.arrayMerge(y, A, P) : E(y, A, P) : o(A, P);
        }
        x.all = function(A, P) {
            if (!Array.isArray(A)) throw new Error("first argument should be an array");
            return A.reduce(function(N, k) {
                return x(N, k, P);
            }, {});
        };
        var S = x;
        return Ts = S, Ts;
    }
    var h1 = l1();
    const lr = Lr(h1);
    var Vi = {
        exports: {}
    }, b1 = Vi.exports, dd;
    function p1() {
        return dd || (dd = 1, (function(r) {
            (function(e, t) {
                r.exports ? r.exports = t() : e.log = t();
            })(b1, function() {
                var e = function() {}, t = "undefined", n = typeof window !== t && typeof window.navigator !== t && /Trident\/|MSIE /.test(window.navigator.userAgent), a = [
                    "trace",
                    "debug",
                    "info",
                    "warn",
                    "error"
                ], i = {}, s = null;
                function o(x, S) {
                    var y = x[S];
                    if (typeof y.bind == "function") return y.bind(x);
                    try {
                        return Function.prototype.bind.call(y, x);
                    } catch  {
                        return function() {
                            return Function.prototype.apply.apply(y, [
                                x,
                                arguments
                            ]);
                        };
                    }
                }
                function f() {
                    console.log && (console.log.apply ? console.log.apply(console, arguments) : Function.prototype.apply.apply(console.log, [
                        console,
                        arguments
                    ])), console.trace && console.trace();
                }
                function c(x) {
                    return x === "debug" && (x = "log"), typeof console === t ? !1 : x === "trace" && n ? f : console[x] !== void 0 ? o(console, x) : console.log !== void 0 ? o(console, "log") : e;
                }
                function h() {
                    for(var x = this.getLevel(), S = 0; S < a.length; S++){
                        var y = a[S];
                        this[y] = S < x ? e : this.methodFactory(y, x, this.name);
                    }
                    if (this.log = this.debug, typeof console === t && x < this.levels.SILENT) return "No console available for logging";
                }
                function g(x) {
                    return function() {
                        typeof console !== t && (h.call(this), this[x].apply(this, arguments));
                    };
                }
                function v(x, S, y) {
                    return c(x) || g.apply(this, arguments);
                }
                function w(x, S) {
                    var y = this, A, P, N, k = "loglevel";
                    typeof x == "string" ? k += ":" + x : typeof x == "symbol" && (k = void 0);
                    function D(O) {
                        var d = (a[O] || "silent").toUpperCase();
                        if (!(typeof window === t || !k)) {
                            try {
                                window.localStorage[k] = d;
                                return;
                            } catch  {}
                            try {
                                window.document.cookie = encodeURIComponent(k) + "=" + d + ";";
                            } catch  {}
                        }
                    }
                    function V() {
                        var O;
                        if (!(typeof window === t || !k)) {
                            try {
                                O = window.localStorage[k];
                            } catch  {}
                            if (typeof O === t) try {
                                var d = window.document.cookie, l = encodeURIComponent(k), b = d.indexOf(l + "=");
                                b !== -1 && (O = /^([^;]+)/.exec(d.slice(b + l.length + 1))[1]);
                            } catch  {}
                            return y.levels[O] === void 0 && (O = void 0), O;
                        }
                    }
                    function K() {
                        if (!(typeof window === t || !k)) {
                            try {
                                window.localStorage.removeItem(k);
                            } catch  {}
                            try {
                                window.document.cookie = encodeURIComponent(k) + "=; expires=Thu, 01 Jan 1970 00:00:00 UTC";
                            } catch  {}
                        }
                    }
                    function j(O) {
                        var d = O;
                        if (typeof d == "string" && y.levels[d.toUpperCase()] !== void 0 && (d = y.levels[d.toUpperCase()]), typeof d == "number" && d >= 0 && d <= y.levels.SILENT) return d;
                        throw new TypeError("log.setLevel() called with invalid level: " + O);
                    }
                    y.name = x, y.levels = {
                        TRACE: 0,
                        DEBUG: 1,
                        INFO: 2,
                        WARN: 3,
                        ERROR: 4,
                        SILENT: 5
                    }, y.methodFactory = S || v, y.getLevel = function() {
                        return N ?? P ?? A;
                    }, y.setLevel = function(O, d) {
                        return N = j(O), d !== !1 && D(N), h.call(y);
                    }, y.setDefaultLevel = function(O) {
                        P = j(O), V() || y.setLevel(O, !1);
                    }, y.resetLevel = function() {
                        N = null, K(), h.call(y);
                    }, y.enableAll = function(O) {
                        y.setLevel(y.levels.TRACE, O);
                    }, y.disableAll = function(O) {
                        y.setLevel(y.levels.SILENT, O);
                    }, y.rebuild = function() {
                        if (s !== y && (A = j(s.getLevel())), h.call(y), s === y) for(var O in i)i[O].rebuild();
                    }, A = j(s ? s.getLevel() : "WARN");
                    var H = V();
                    H != null && (N = j(H)), h.call(y);
                }
                s = new w, s.getLogger = function(S) {
                    if (typeof S != "symbol" && typeof S != "string" || S === "") throw new TypeError("You must supply a name when creating a logger.");
                    var y = i[S];
                    return y || (y = i[S] = new w(S, s.methodFactory)), y;
                };
                var E = typeof window !== t ? window.log : void 0;
                return s.noConflict = function() {
                    return typeof window !== t && window.log === s && (window.log = E), s;
                }, s.getLoggers = function() {
                    return i;
                }, s.default = s, s;
            });
        })(Vi)), Vi.exports;
    }
    var yu = p1();
    let ui;
    vr = Lr(yu);
    ui = vr.getLogger("http-helpers");
    ui.setLevel(yu.levels.INFO);
    let Uo = "torus-default", qo = "";
    const g1 = "x-api-key", y1 = "x-embed-host";
    function v1(r) {
        qo = r;
    }
    function m1(r) {
        Uo = r;
    }
    function w1(r) {
        ui.setLevel(r);
    }
    async function Ea(r, e) {
        let t = null;
        try {
            t = new URL(r);
        } catch  {}
        return fetch(r, e);
    }
    function Aa() {
        const r = {};
        return Uo && (r[g1] = Uo), qo && (r[y1] = qo), r;
    }
    function Ia(r) {
        ui.info(`Response: ${r.status} ${r.statusText}`), ui.info(`Url: ${r.url}`);
    }
    function x1(r) {
        const e = r.headers.get("x-web3-correlation-id");
        e && ui.info(`Request tracing with traceID = ${e}`);
    }
    const _1 = async (r, e)=>{
        let t = null;
        try {
            const n = new Promise((i, s)=>{
                t = setTimeout(()=>{
                    s(new Error(`Timed out in ${r}ms`));
                }, r);
            }), a = await Promise.race([
                e,
                n
            ]);
            return t != null && clearTimeout(t), a;
        } catch (n) {
            throw t != null && clearTimeout(t), n;
        }
    }, Vr = async (r, e = {}, t = {})=>{
        const n = {
            mode: "cors",
            headers: {}
        };
        t.useAPIKey && (n.headers = Be(Be({}, n.headers), Aa())), e.method = "GET";
        const a = lr(n, e), i = await Ea(r, a);
        if (i.ok) {
            const s = i.headers.get("content-type");
            return s != null && s.includes("application/json") ? i.json() : i.text();
        }
        throw Ia(i), i;
    }, cr = (r, e = {}, t = {}, n = {})=>{
        const a = {
            mode: "cors",
            headers: {
                "Content-Type": "application/json; charset=utf-8"
            }
        };
        n.useAPIKey && (a.headers = Be(Be({}, a.headers), Aa())), t.method = "POST";
        const i = lr(a, t);
        return n.isUrlEncodedData ? (i.body = e, i.headers["Content-Type"] === "application/json; charset=utf-8" && delete i.headers["Content-Type"]) : i.body = JSON.stringify(e), _1(n.timeout || 6e4, Ea(r, i).then((s)=>{
            if (n.logTracingHeader && x1(s), s.ok) {
                const o = s.headers.get("content-type");
                return o != null && o.includes("application/json") ? s.json() : s.text();
            }
            throw Ia(s), s;
        }));
    }, S1 = async (r, e = {}, t = {}, n = {})=>{
        const a = {
            mode: "cors",
            headers: {
                "Content-Type": "application/json; charset=utf-8"
            }
        };
        n.useAPIKey && (a.headers = Be(Be({}, a.headers), Aa())), t.method = "PATCH";
        const i = lr(a, t);
        n.isUrlEncodedData ? (i.body = e, i.headers["Content-Type"] === "application/json; charset=utf-8" && delete i.headers["Content-Type"]) : i.body = JSON.stringify(e);
        const s = await Ea(r, i);
        if (s.ok) {
            const o = s.headers.get("content-type");
            return o != null && o.includes("application/json") ? s.json() : s.text();
        }
        throw Ia(s), s;
    }, E1 = async (r, e = {}, t = {}, n = {})=>{
        const a = {
            mode: "cors",
            headers: {
                "Content-Type": "application/json; charset=utf-8"
            }
        };
        n.useAPIKey && (a.headers = Be(Be({}, a.headers), Aa())), t.method = "PUT";
        const i = lr(a, t);
        n.isUrlEncodedData ? (i.body = e, i.headers["Content-Type"] === "application/json; charset=utf-8" && delete i.headers["Content-Type"]) : i.body = JSON.stringify(e);
        const s = await Ea(r, i);
        if (s.ok) {
            const o = s.headers.get("content-type");
            return o != null && o.includes("application/json") ? s.json() : s.text();
        }
        throw Ia(s), s;
    }, li = (r, e)=>({
            jsonrpc: "2.0",
            method: r,
            id: 10,
            params: e
        });
    function A1(r, e) {
        if (r == null) return {};
        var t = {};
        for(var n in r)if ({}.hasOwnProperty.call(r, n)) {
            if (e.indexOf(n) !== -1) continue;
            t[n] = r[n];
        }
        return t;
    }
    function sa(r, e) {
        if (r == null) return {};
        var t, n, a = A1(r, e);
        if (Object.getOwnPropertySymbols) {
            var i = Object.getOwnPropertySymbols(r);
            for(n = 0; n < i.length; n++)t = i[n], e.indexOf(t) === -1 && {}.propertyIsEnumerable.call(r, t) && (a[t] = r[t]);
        }
        return a;
    }
    var Ps = {
        exports: {}
    }, Pi = {}, Bi = {}, ud;
    function I1() {
        if (ud) return Bi;
        ud = 1, Object.defineProperty(Bi, "__esModule", {
            value: !0
        });
        function r(e) {
            var t = 4, n = e.length, a = n % t;
            if (!a) return e;
            var i = n, s = t - a, o = n + s, f = Buffer.alloc(o);
            for(f.write(e); s--;)f.write("=", i++);
            return f.toString();
        }
        return Bi.default = r, Bi;
    }
    var ld;
    function M1() {
        if (ld) return Pi;
        ld = 1, Object.defineProperty(Pi, "__esModule", {
            value: !0
        });
        var r = I1();
        function e(o, f) {
            return f === void 0 && (f = "utf8"), Buffer.isBuffer(o) ? a(o.toString("base64")) : a(Buffer.from(o, f).toString("base64"));
        }
        function t(o, f) {
            return f === void 0 && (f = "utf8"), Buffer.from(n(o), "base64").toString(f);
        }
        function n(o) {
            return o = o.toString(), r.default(o).replace(/\-/g, "+").replace(/_/g, "/");
        }
        function a(o) {
            return o.replace(/=/g, "").replace(/\+/g, "-").replace(/\//g, "_");
        }
        function i(o) {
            return Buffer.from(n(o), "base64");
        }
        var s = e;
        return s.encode = e, s.decode = t, s.toBase64 = n, s.fromBase64 = a, s.toBuffer = i, Pi.default = s, Pi;
    }
    var hd;
    function R1() {
        return hd || (hd = 1, (function(r) {
            r.exports = M1().default, r.exports.default = r.exports;
        })(Ps)), Ps.exports;
    }
    var T1 = R1();
    const kr = Lr(T1), P1 = {
        AmazonBot: "amazonbot",
        "Amazon Silk": "amazon_silk",
        "Android Browser": "android",
        BaiduSpider: "baiduspider",
        Bada: "bada",
        BingCrawler: "bingcrawler",
        Brave: "brave",
        BlackBerry: "blackberry",
        "ChatGPT-User": "chatgpt_user",
        Chrome: "chrome",
        ClaudeBot: "claudebot",
        Chromium: "chromium",
        Diffbot: "diffbot",
        DuckDuckBot: "duckduckbot",
        DuckDuckGo: "duckduckgo",
        Electron: "electron",
        Epiphany: "epiphany",
        FacebookExternalHit: "facebookexternalhit",
        Firefox: "firefox",
        Focus: "focus",
        Generic: "generic",
        "Google Search": "google_search",
        Googlebot: "googlebot",
        GPTBot: "gptbot",
        "Internet Explorer": "ie",
        InternetArchiveCrawler: "internetarchivecrawler",
        "K-Meleon": "k_meleon",
        LibreWolf: "librewolf",
        Linespider: "linespider",
        Maxthon: "maxthon",
        "Meta-ExternalAds": "meta_externalads",
        "Meta-ExternalAgent": "meta_externalagent",
        "Meta-ExternalFetcher": "meta_externalfetcher",
        "Meta-WebIndexer": "meta_webindexer",
        "Microsoft Edge": "edge",
        "MZ Browser": "mz",
        "NAVER Whale Browser": "naver",
        "OAI-SearchBot": "oai_searchbot",
        Omgilibot: "omgilibot",
        Opera: "opera",
        "Opera Coast": "opera_coast",
        "Pale Moon": "pale_moon",
        PerplexityBot: "perplexitybot",
        "Perplexity-User": "perplexity_user",
        PhantomJS: "phantomjs",
        PingdomBot: "pingdombot",
        Puffin: "puffin",
        QQ: "qq",
        QQLite: "qqlite",
        QupZilla: "qupzilla",
        Roku: "roku",
        Safari: "safari",
        Sailfish: "sailfish",
        "Samsung Internet for Android": "samsung_internet",
        SlackBot: "slackbot",
        SeaMonkey: "seamonkey",
        Sleipnir: "sleipnir",
        "Sogou Browser": "sogou",
        Swing: "swing",
        Tizen: "tizen",
        "UC Browser": "uc",
        Vivaldi: "vivaldi",
        "WebOS Browser": "webos",
        WeChat: "wechat",
        YahooSlurp: "yahooslurp",
        "Yandex Browser": "yandex",
        YandexBot: "yandexbot",
        YouBot: "youbot"
    }, vu = {
        amazonbot: "AmazonBot",
        amazon_silk: "Amazon Silk",
        android: "Android Browser",
        baiduspider: "BaiduSpider",
        bada: "Bada",
        bingcrawler: "BingCrawler",
        blackberry: "BlackBerry",
        brave: "Brave",
        chatgpt_user: "ChatGPT-User",
        chrome: "Chrome",
        claudebot: "ClaudeBot",
        chromium: "Chromium",
        diffbot: "Diffbot",
        duckduckbot: "DuckDuckBot",
        duckduckgo: "DuckDuckGo",
        edge: "Microsoft Edge",
        electron: "Electron",
        epiphany: "Epiphany",
        facebookexternalhit: "FacebookExternalHit",
        firefox: "Firefox",
        focus: "Focus",
        generic: "Generic",
        google_search: "Google Search",
        googlebot: "Googlebot",
        gptbot: "GPTBot",
        ie: "Internet Explorer",
        internetarchivecrawler: "InternetArchiveCrawler",
        k_meleon: "K-Meleon",
        librewolf: "LibreWolf",
        linespider: "Linespider",
        maxthon: "Maxthon",
        meta_externalads: "Meta-ExternalAds",
        meta_externalagent: "Meta-ExternalAgent",
        meta_externalfetcher: "Meta-ExternalFetcher",
        meta_webindexer: "Meta-WebIndexer",
        mz: "MZ Browser",
        naver: "NAVER Whale Browser",
        oai_searchbot: "OAI-SearchBot",
        omgilibot: "Omgilibot",
        opera: "Opera",
        opera_coast: "Opera Coast",
        pale_moon: "Pale Moon",
        perplexitybot: "PerplexityBot",
        perplexity_user: "Perplexity-User",
        phantomjs: "PhantomJS",
        pingdombot: "PingdomBot",
        puffin: "Puffin",
        qq: "QQ Browser",
        qqlite: "QQ Browser Lite",
        qupzilla: "QupZilla",
        roku: "Roku",
        safari: "Safari",
        sailfish: "Sailfish",
        samsung_internet: "Samsung Internet for Android",
        seamonkey: "SeaMonkey",
        slackbot: "SlackBot",
        sleipnir: "Sleipnir",
        sogou: "Sogou Browser",
        swing: "Swing",
        tizen: "Tizen",
        uc: "UC Browser",
        vivaldi: "Vivaldi",
        webos: "WebOS Browser",
        wechat: "WeChat",
        yahooslurp: "YahooSlurp",
        yandex: "Yandex Browser",
        yandexbot: "YandexBot",
        youbot: "YouBot"
    }, rt = {
        bot: "bot",
        desktop: "desktop",
        mobile: "mobile",
        tablet: "tablet",
        tv: "tv"
    }, Xt = {
        Android: "Android",
        Bada: "Bada",
        BlackBerry: "BlackBerry",
        ChromeOS: "Chrome OS",
        HarmonyOS: "HarmonyOS",
        iOS: "iOS",
        Linux: "Linux",
        MacOS: "macOS",
        PlayStation4: "PlayStation 4",
        Roku: "Roku",
        Tizen: "Tizen",
        WebOS: "WebOS",
        Windows: "Windows",
        WindowsPhone: "Windows Phone"
    }, en = {
        Blink: "Blink",
        EdgeHTML: "EdgeHTML",
        Gecko: "Gecko",
        Presto: "Presto",
        Trident: "Trident",
        WebKit: "WebKit"
    };
    class ae {
        static getFirstMatch(e, t) {
            const n = t.match(e);
            return n && n.length > 0 && n[1] || "";
        }
        static getSecondMatch(e, t) {
            const n = t.match(e);
            return n && n.length > 1 && n[2] || "";
        }
        static matchAndReturnConst(e, t, n) {
            if (e.test(t)) return n;
        }
        static getWindowsVersionName(e) {
            switch(e){
                case "NT":
                    return "NT";
                case "XP":
                    return "XP";
                case "NT 5.0":
                    return "2000";
                case "NT 5.1":
                    return "XP";
                case "NT 5.2":
                    return "2003";
                case "NT 6.0":
                    return "Vista";
                case "NT 6.1":
                    return "7";
                case "NT 6.2":
                    return "8";
                case "NT 6.3":
                    return "8.1";
                case "NT 10.0":
                    return "10";
                default:
                    return;
            }
        }
        static getMacOSVersionName(e) {
            const t = e.split(".").splice(0, 2).map((i)=>parseInt(i, 10) || 0);
            t.push(0);
            const n = t[0], a = t[1];
            if (n === 10) switch(a){
                case 5:
                    return "Leopard";
                case 6:
                    return "Snow Leopard";
                case 7:
                    return "Lion";
                case 8:
                    return "Mountain Lion";
                case 9:
                    return "Mavericks";
                case 10:
                    return "Yosemite";
                case 11:
                    return "El Capitan";
                case 12:
                    return "Sierra";
                case 13:
                    return "High Sierra";
                case 14:
                    return "Mojave";
                case 15:
                    return "Catalina";
                default:
                    return;
            }
            switch(n){
                case 11:
                    return "Big Sur";
                case 12:
                    return "Monterey";
                case 13:
                    return "Ventura";
                case 14:
                    return "Sonoma";
                case 15:
                    return "Sequoia";
                default:
                    return;
            }
        }
        static getAndroidVersionName(e) {
            const t = e.split(".").splice(0, 2).map((n)=>parseInt(n, 10) || 0);
            if (t.push(0), !(t[0] === 1 && t[1] < 5)) {
                if (t[0] === 1 && t[1] < 6) return "Cupcake";
                if (t[0] === 1 && t[1] >= 6) return "Donut";
                if (t[0] === 2 && t[1] < 2) return "Eclair";
                if (t[0] === 2 && t[1] === 2) return "Froyo";
                if (t[0] === 2 && t[1] > 2) return "Gingerbread";
                if (t[0] === 3) return "Honeycomb";
                if (t[0] === 4 && t[1] < 1) return "Ice Cream Sandwich";
                if (t[0] === 4 && t[1] < 4) return "Jelly Bean";
                if (t[0] === 4 && t[1] >= 4) return "KitKat";
                if (t[0] === 5) return "Lollipop";
                if (t[0] === 6) return "Marshmallow";
                if (t[0] === 7) return "Nougat";
                if (t[0] === 8) return "Oreo";
                if (t[0] === 9) return "Pie";
            }
        }
        static getVersionPrecision(e) {
            return e.split(".").length;
        }
        static compareVersions(e, t, n = !1) {
            const a = ae.getVersionPrecision(e), i = ae.getVersionPrecision(t);
            let s = Math.max(a, i), o = 0;
            const f = ae.map([
                e,
                t
            ], (c)=>{
                const h = s - ae.getVersionPrecision(c), g = c + new Array(h + 1).join(".0");
                return ae.map(g.split("."), (v)=>new Array(20 - v.length).join("0") + v).reverse();
            });
            for(n && (o = s - Math.min(a, i)), s -= 1; s >= o;){
                if (f[0][s] > f[1][s]) return 1;
                if (f[0][s] === f[1][s]) {
                    if (s === o) return 0;
                    s -= 1;
                } else if (f[0][s] < f[1][s]) return -1;
            }
        }
        static map(e, t) {
            const n = [];
            let a;
            if (Array.prototype.map) return Array.prototype.map.call(e, t);
            for(a = 0; a < e.length; a += 1)n.push(t(e[a]));
            return n;
        }
        static find(e, t) {
            let n, a;
            if (Array.prototype.find) return Array.prototype.find.call(e, t);
            for(n = 0, a = e.length; n < a; n += 1){
                const i = e[n];
                if (t(i, n)) return i;
            }
        }
        static assign(e, ...t) {
            const n = e;
            let a, i;
            if (Object.assign) return Object.assign(e, ...t);
            for(a = 0, i = t.length; a < i; a += 1){
                const s = t[a];
                typeof s == "object" && s !== null && Object.keys(s).forEach((f)=>{
                    n[f] = s[f];
                });
            }
            return e;
        }
        static getBrowserAlias(e) {
            return P1[e];
        }
        static getBrowserTypeByAlias(e) {
            return vu[e] || "";
        }
    }
    const nt = /version\/(\d+(\.?_?\d+)+)/i, B1 = [
        {
            test: [
                /gptbot/i
            ],
            describe (r) {
                const e = {
                    name: "GPTBot"
                }, t = ae.getFirstMatch(/gptbot\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /chatgpt-user/i
            ],
            describe (r) {
                const e = {
                    name: "ChatGPT-User"
                }, t = ae.getFirstMatch(/chatgpt-user\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /oai-searchbot/i
            ],
            describe (r) {
                const e = {
                    name: "OAI-SearchBot"
                }, t = ae.getFirstMatch(/oai-searchbot\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /claudebot/i,
                /claude-web/i,
                /claude-user/i,
                /claude-searchbot/i
            ],
            describe (r) {
                const e = {
                    name: "ClaudeBot"
                }, t = ae.getFirstMatch(/(?:claudebot|claude-web|claude-user|claude-searchbot)\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /omgilibot/i,
                /webzio-extended/i
            ],
            describe (r) {
                const e = {
                    name: "Omgilibot"
                }, t = ae.getFirstMatch(/(?:omgilibot|webzio-extended)\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /diffbot/i
            ],
            describe (r) {
                const e = {
                    name: "Diffbot"
                }, t = ae.getFirstMatch(/diffbot\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /perplexitybot/i
            ],
            describe (r) {
                const e = {
                    name: "PerplexityBot"
                }, t = ae.getFirstMatch(/perplexitybot\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /perplexity-user/i
            ],
            describe (r) {
                const e = {
                    name: "Perplexity-User"
                }, t = ae.getFirstMatch(/perplexity-user\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /youbot/i
            ],
            describe (r) {
                const e = {
                    name: "YouBot"
                }, t = ae.getFirstMatch(/youbot\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /meta-webindexer/i
            ],
            describe (r) {
                const e = {
                    name: "Meta-WebIndexer"
                }, t = ae.getFirstMatch(/meta-webindexer\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /meta-externalads/i
            ],
            describe (r) {
                const e = {
                    name: "Meta-ExternalAds"
                }, t = ae.getFirstMatch(/meta-externalads\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /meta-externalagent/i
            ],
            describe (r) {
                const e = {
                    name: "Meta-ExternalAgent"
                }, t = ae.getFirstMatch(/meta-externalagent\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /meta-externalfetcher/i
            ],
            describe (r) {
                const e = {
                    name: "Meta-ExternalFetcher"
                }, t = ae.getFirstMatch(/meta-externalfetcher\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /googlebot/i
            ],
            describe (r) {
                const e = {
                    name: "Googlebot"
                }, t = ae.getFirstMatch(/googlebot\/(\d+(\.\d+))/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /linespider/i
            ],
            describe (r) {
                const e = {
                    name: "Linespider"
                }, t = ae.getFirstMatch(/(?:linespider)(?:-[-\w]+)?[\s/](\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /amazonbot/i
            ],
            describe (r) {
                const e = {
                    name: "AmazonBot"
                }, t = ae.getFirstMatch(/amazonbot\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /bingbot/i
            ],
            describe (r) {
                const e = {
                    name: "BingCrawler"
                }, t = ae.getFirstMatch(/bingbot\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /baiduspider/i
            ],
            describe (r) {
                const e = {
                    name: "BaiduSpider"
                }, t = ae.getFirstMatch(/baiduspider\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /duckduckbot/i
            ],
            describe (r) {
                const e = {
                    name: "DuckDuckBot"
                }, t = ae.getFirstMatch(/duckduckbot\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /ia_archiver/i
            ],
            describe (r) {
                const e = {
                    name: "InternetArchiveCrawler"
                }, t = ae.getFirstMatch(/ia_archiver\/(\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /facebookexternalhit/i,
                /facebookcatalog/i
            ],
            describe () {
                return {
                    name: "FacebookExternalHit"
                };
            }
        },
        {
            test: [
                /slackbot/i,
                /slack-imgProxy/i
            ],
            describe (r) {
                const e = {
                    name: "SlackBot"
                }, t = ae.getFirstMatch(/(?:slackbot|slack-imgproxy)(?:-[-\w]+)?[\s/](\d+(\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /yahoo!?[\s/]*slurp/i
            ],
            describe () {
                return {
                    name: "YahooSlurp"
                };
            }
        },
        {
            test: [
                /yandexbot/i,
                /yandexmobilebot/i
            ],
            describe () {
                return {
                    name: "YandexBot"
                };
            }
        },
        {
            test: [
                /pingdom/i
            ],
            describe () {
                return {
                    name: "PingdomBot"
                };
            }
        },
        {
            test: [
                /opera/i
            ],
            describe (r) {
                const e = {
                    name: "Opera"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/(?:opera)[\s/](\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /opr\/|opios/i
            ],
            describe (r) {
                const e = {
                    name: "Opera"
                }, t = ae.getFirstMatch(/(?:opr|opios)[\s/](\S+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /SamsungBrowser/i
            ],
            describe (r) {
                const e = {
                    name: "Samsung Internet for Android"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/(?:SamsungBrowser)[\s/](\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /Whale/i
            ],
            describe (r) {
                const e = {
                    name: "NAVER Whale Browser"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/(?:whale)[\s/](\d+(?:\.\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /PaleMoon/i
            ],
            describe (r) {
                const e = {
                    name: "Pale Moon"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/(?:PaleMoon)[\s/](\d+(?:\.\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /MZBrowser/i
            ],
            describe (r) {
                const e = {
                    name: "MZ Browser"
                }, t = ae.getFirstMatch(/(?:MZBrowser)[\s/](\d+(?:\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /focus/i
            ],
            describe (r) {
                const e = {
                    name: "Focus"
                }, t = ae.getFirstMatch(/(?:focus)[\s/](\d+(?:\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /swing/i
            ],
            describe (r) {
                const e = {
                    name: "Swing"
                }, t = ae.getFirstMatch(/(?:swing)[\s/](\d+(?:\.\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /coast/i
            ],
            describe (r) {
                const e = {
                    name: "Opera Coast"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/(?:coast)[\s/](\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /opt\/\d+(?:.?_?\d+)+/i
            ],
            describe (r) {
                const e = {
                    name: "Opera Touch"
                }, t = ae.getFirstMatch(/(?:opt)[\s/](\d+(\.?_?\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /yabrowser/i
            ],
            describe (r) {
                const e = {
                    name: "Yandex Browser"
                }, t = ae.getFirstMatch(/(?:yabrowser)[\s/](\d+(\.?_?\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /ucbrowser/i
            ],
            describe (r) {
                const e = {
                    name: "UC Browser"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/(?:ucbrowser)[\s/](\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /Maxthon|mxios/i
            ],
            describe (r) {
                const e = {
                    name: "Maxthon"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/(?:Maxthon|mxios)[\s/](\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /epiphany/i
            ],
            describe (r) {
                const e = {
                    name: "Epiphany"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/(?:epiphany)[\s/](\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /puffin/i
            ],
            describe (r) {
                const e = {
                    name: "Puffin"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/(?:puffin)[\s/](\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /sleipnir/i
            ],
            describe (r) {
                const e = {
                    name: "Sleipnir"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/(?:sleipnir)[\s/](\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /k-meleon/i
            ],
            describe (r) {
                const e = {
                    name: "K-Meleon"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/(?:k-meleon)[\s/](\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /micromessenger/i
            ],
            describe (r) {
                const e = {
                    name: "WeChat"
                }, t = ae.getFirstMatch(/(?:micromessenger)[\s/](\d+(\.?_?\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /qqbrowser/i
            ],
            describe (r) {
                const e = {
                    name: /qqbrowserlite/i.test(r) ? "QQ Browser Lite" : "QQ Browser"
                }, t = ae.getFirstMatch(/(?:qqbrowserlite|qqbrowser)[/](\d+(\.?_?\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /msie|trident/i
            ],
            describe (r) {
                const e = {
                    name: "Internet Explorer"
                }, t = ae.getFirstMatch(/(?:msie |rv:)(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /\sedg\//i
            ],
            describe (r) {
                const e = {
                    name: "Microsoft Edge"
                }, t = ae.getFirstMatch(/\sedg\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /edg([ea]|ios)/i
            ],
            describe (r) {
                const e = {
                    name: "Microsoft Edge"
                }, t = ae.getSecondMatch(/edg([ea]|ios)\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /vivaldi/i
            ],
            describe (r) {
                const e = {
                    name: "Vivaldi"
                }, t = ae.getFirstMatch(/vivaldi\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /seamonkey/i
            ],
            describe (r) {
                const e = {
                    name: "SeaMonkey"
                }, t = ae.getFirstMatch(/seamonkey\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /sailfish/i
            ],
            describe (r) {
                const e = {
                    name: "Sailfish"
                }, t = ae.getFirstMatch(/sailfish\s?browser\/(\d+(\.\d+)?)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /silk/i
            ],
            describe (r) {
                const e = {
                    name: "Amazon Silk"
                }, t = ae.getFirstMatch(/silk\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /phantom/i
            ],
            describe (r) {
                const e = {
                    name: "PhantomJS"
                }, t = ae.getFirstMatch(/phantomjs\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /slimerjs/i
            ],
            describe (r) {
                const e = {
                    name: "SlimerJS"
                }, t = ae.getFirstMatch(/slimerjs\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /blackberry|\bbb\d+/i,
                /rim\stablet/i
            ],
            describe (r) {
                const e = {
                    name: "BlackBerry"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/blackberry[\d]+\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /(web|hpw)[o0]s/i
            ],
            describe (r) {
                const e = {
                    name: "WebOS Browser"
                }, t = ae.getFirstMatch(nt, r) || ae.getFirstMatch(/w(?:eb)?[o0]sbrowser\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /bada/i
            ],
            describe (r) {
                const e = {
                    name: "Bada"
                }, t = ae.getFirstMatch(/dolfin\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /tizen/i
            ],
            describe (r) {
                const e = {
                    name: "Tizen"
                }, t = ae.getFirstMatch(/(?:tizen\s?)?browser\/(\d+(\.?_?\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /qupzilla/i
            ],
            describe (r) {
                const e = {
                    name: "QupZilla"
                }, t = ae.getFirstMatch(/(?:qupzilla)[\s/](\d+(\.?_?\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /librewolf/i
            ],
            describe (r) {
                const e = {
                    name: "LibreWolf"
                }, t = ae.getFirstMatch(/(?:librewolf)[\s/](\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /firefox|iceweasel|fxios/i
            ],
            describe (r) {
                const e = {
                    name: "Firefox"
                }, t = ae.getFirstMatch(/(?:firefox|iceweasel|fxios)[\s/](\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /electron/i
            ],
            describe (r) {
                const e = {
                    name: "Electron"
                }, t = ae.getFirstMatch(/(?:electron)\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /sogoumobilebrowser/i,
                /metasr/i,
                /se 2\.[x]/i
            ],
            describe (r) {
                const e = {
                    name: "Sogou Browser"
                }, t = ae.getFirstMatch(/(?:sogoumobilebrowser)[\s/](\d+(\.?_?\d+)+)/i, r), n = ae.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i, r), a = ae.getFirstMatch(/se ([\d.]+)x/i, r), i = t || n || a;
                return i && (e.version = i), e;
            }
        },
        {
            test: [
                /MiuiBrowser/i
            ],
            describe (r) {
                const e = {
                    name: "Miui"
                }, t = ae.getFirstMatch(/(?:MiuiBrowser)[\s/](\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test (r) {
                return r.hasBrand("DuckDuckGo") ? !0 : r.test(/\sDdg\/[\d.]+$/i);
            },
            describe (r, e) {
                const t = {
                    name: "DuckDuckGo"
                };
                if (e) {
                    const a = e.getBrandVersion("DuckDuckGo");
                    if (a) return t.version = a, t;
                }
                const n = ae.getFirstMatch(/\sDdg\/([\d.]+)$/i, r);
                return n && (t.version = n), t;
            }
        },
        {
            test (r) {
                return r.hasBrand("Brave");
            },
            describe (r, e) {
                const t = {
                    name: "Brave"
                };
                if (e) {
                    const n = e.getBrandVersion("Brave");
                    if (n) return t.version = n, t;
                }
                return t;
            }
        },
        {
            test: [
                /chromium/i
            ],
            describe (r) {
                const e = {
                    name: "Chromium"
                }, t = ae.getFirstMatch(/(?:chromium)[\s/](\d+(\.?_?\d+)+)/i, r) || ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /chrome|crios|crmo/i
            ],
            describe (r) {
                const e = {
                    name: "Chrome"
                }, t = ae.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /GSA/i
            ],
            describe (r) {
                const e = {
                    name: "Google Search"
                }, t = ae.getFirstMatch(/(?:GSA)\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test (r) {
                const e = !r.test(/like android/i), t = r.test(/android/i);
                return e && t;
            },
            describe (r) {
                const e = {
                    name: "Android Browser"
                }, t = ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /playstation 4/i
            ],
            describe (r) {
                const e = {
                    name: "PlayStation 4"
                }, t = ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /safari|applewebkit/i
            ],
            describe (r) {
                const e = {
                    name: "Safari"
                }, t = ae.getFirstMatch(nt, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /.*/i
            ],
            describe (r) {
                const e = /^(.*)\/(.*) /, t = /^(.*)\/(.*)[ \t]\((.*)/, a = r.search("\\(") !== -1 ? t : e;
                return {
                    name: ae.getFirstMatch(a, r),
                    version: ae.getSecondMatch(a, r)
                };
            }
        }
    ], O1 = [
        {
            test: [
                /Roku\/DVP/
            ],
            describe (r) {
                const e = ae.getFirstMatch(/Roku\/DVP-(\d+\.\d+)/i, r);
                return {
                    name: Xt.Roku,
                    version: e
                };
            }
        },
        {
            test: [
                /windows phone/i
            ],
            describe (r) {
                const e = ae.getFirstMatch(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i, r);
                return {
                    name: Xt.WindowsPhone,
                    version: e
                };
            }
        },
        {
            test: [
                /windows /i
            ],
            describe (r) {
                const e = ae.getFirstMatch(/Windows ((NT|XP)( \d\d?.\d)?)/i, r), t = ae.getWindowsVersionName(e);
                return {
                    name: Xt.Windows,
                    version: e,
                    versionName: t
                };
            }
        },
        {
            test: [
                /Macintosh(.*?) FxiOS(.*?)\//
            ],
            describe (r) {
                const e = {
                    name: Xt.iOS
                }, t = ae.getSecondMatch(/(Version\/)(\d[\d.]+)/, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /macintosh/i
            ],
            describe (r) {
                const e = ae.getFirstMatch(/mac os x (\d+(\.?_?\d+)+)/i, r).replace(/[_\s]/g, "."), t = ae.getMacOSVersionName(e), n = {
                    name: Xt.MacOS,
                    version: e
                };
                return t && (n.versionName = t), n;
            }
        },
        {
            test: [
                /(ipod|iphone|ipad)/i
            ],
            describe (r) {
                const e = ae.getFirstMatch(/os (\d+([_\s]\d+)*) like mac os x/i, r).replace(/[_\s]/g, ".");
                return {
                    name: Xt.iOS,
                    version: e
                };
            }
        },
        {
            test: [
                /OpenHarmony/i
            ],
            describe (r) {
                const e = ae.getFirstMatch(/OpenHarmony\s+(\d+(\.\d+)*)/i, r);
                return {
                    name: Xt.HarmonyOS,
                    version: e
                };
            }
        },
        {
            test (r) {
                const e = !r.test(/like android/i), t = r.test(/android/i);
                return e && t;
            },
            describe (r) {
                const e = ae.getFirstMatch(/android[\s/-](\d+(\.\d+)*)/i, r), t = ae.getAndroidVersionName(e), n = {
                    name: Xt.Android,
                    version: e
                };
                return t && (n.versionName = t), n;
            }
        },
        {
            test: [
                /(web|hpw)[o0]s/i
            ],
            describe (r) {
                const e = ae.getFirstMatch(/(?:web|hpw)[o0]s\/(\d+(\.\d+)*)/i, r), t = {
                    name: Xt.WebOS
                };
                return e && e.length && (t.version = e), t;
            }
        },
        {
            test: [
                /blackberry|\bbb\d+/i,
                /rim\stablet/i
            ],
            describe (r) {
                const e = ae.getFirstMatch(/rim\stablet\sos\s(\d+(\.\d+)*)/i, r) || ae.getFirstMatch(/blackberry\d+\/(\d+([_\s]\d+)*)/i, r) || ae.getFirstMatch(/\bbb(\d+)/i, r);
                return {
                    name: Xt.BlackBerry,
                    version: e
                };
            }
        },
        {
            test: [
                /bada/i
            ],
            describe (r) {
                const e = ae.getFirstMatch(/bada\/(\d+(\.\d+)*)/i, r);
                return {
                    name: Xt.Bada,
                    version: e
                };
            }
        },
        {
            test: [
                /tizen/i
            ],
            describe (r) {
                const e = ae.getFirstMatch(/tizen[/\s](\d+(\.\d+)*)/i, r);
                return {
                    name: Xt.Tizen,
                    version: e
                };
            }
        },
        {
            test: [
                /linux/i
            ],
            describe () {
                return {
                    name: Xt.Linux
                };
            }
        },
        {
            test: [
                /CrOS/
            ],
            describe () {
                return {
                    name: Xt.ChromeOS
                };
            }
        },
        {
            test: [
                /PlayStation 4/
            ],
            describe (r) {
                const e = ae.getFirstMatch(/PlayStation 4[/\s](\d+(\.\d+)*)/i, r);
                return {
                    name: Xt.PlayStation4,
                    version: e
                };
            }
        }
    ], k1 = [
        {
            test: [
                /googlebot/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Google"
                };
            }
        },
        {
            test: [
                /linespider/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Line"
                };
            }
        },
        {
            test: [
                /amazonbot/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Amazon"
                };
            }
        },
        {
            test: [
                /gptbot/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "OpenAI"
                };
            }
        },
        {
            test: [
                /chatgpt-user/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "OpenAI"
                };
            }
        },
        {
            test: [
                /oai-searchbot/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "OpenAI"
                };
            }
        },
        {
            test: [
                /baiduspider/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Baidu"
                };
            }
        },
        {
            test: [
                /bingbot/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Bing"
                };
            }
        },
        {
            test: [
                /duckduckbot/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "DuckDuckGo"
                };
            }
        },
        {
            test: [
                /claudebot/i,
                /claude-web/i,
                /claude-user/i,
                /claude-searchbot/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Anthropic"
                };
            }
        },
        {
            test: [
                /omgilibot/i,
                /webzio-extended/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Webz.io"
                };
            }
        },
        {
            test: [
                /diffbot/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Diffbot"
                };
            }
        },
        {
            test: [
                /perplexitybot/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Perplexity AI"
                };
            }
        },
        {
            test: [
                /perplexity-user/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Perplexity AI"
                };
            }
        },
        {
            test: [
                /youbot/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "You.com"
                };
            }
        },
        {
            test: [
                /ia_archiver/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Internet Archive"
                };
            }
        },
        {
            test: [
                /meta-webindexer/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Meta"
                };
            }
        },
        {
            test: [
                /meta-externalads/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Meta"
                };
            }
        },
        {
            test: [
                /meta-externalagent/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Meta"
                };
            }
        },
        {
            test: [
                /meta-externalfetcher/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Meta"
                };
            }
        },
        {
            test: [
                /facebookexternalhit/i,
                /facebookcatalog/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Meta"
                };
            }
        },
        {
            test: [
                /slackbot/i,
                /slack-imgProxy/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Slack"
                };
            }
        },
        {
            test: [
                /yahoo/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Yahoo"
                };
            }
        },
        {
            test: [
                /yandexbot/i,
                /yandexmobilebot/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Yandex"
                };
            }
        },
        {
            test: [
                /pingdom/i
            ],
            describe () {
                return {
                    type: rt.bot,
                    vendor: "Pingdom"
                };
            }
        },
        {
            test: [
                /huawei/i
            ],
            describe (r) {
                const e = ae.getFirstMatch(/(can-l01)/i, r) && "Nova", t = {
                    type: rt.mobile,
                    vendor: "Huawei"
                };
                return e && (t.model = e), t;
            }
        },
        {
            test: [
                /nexus\s*(?:7|8|9|10).*/i
            ],
            describe () {
                return {
                    type: rt.tablet,
                    vendor: "Nexus"
                };
            }
        },
        {
            test: [
                /ipad/i
            ],
            describe () {
                return {
                    type: rt.tablet,
                    vendor: "Apple",
                    model: "iPad"
                };
            }
        },
        {
            test: [
                /Macintosh(.*?) FxiOS(.*?)\//
            ],
            describe () {
                return {
                    type: rt.tablet,
                    vendor: "Apple",
                    model: "iPad"
                };
            }
        },
        {
            test: [
                /kftt build/i
            ],
            describe () {
                return {
                    type: rt.tablet,
                    vendor: "Amazon",
                    model: "Kindle Fire HD 7"
                };
            }
        },
        {
            test: [
                /silk/i
            ],
            describe () {
                return {
                    type: rt.tablet,
                    vendor: "Amazon"
                };
            }
        },
        {
            test: [
                /tablet(?! pc)/i
            ],
            describe () {
                return {
                    type: rt.tablet
                };
            }
        },
        {
            test (r) {
                const e = r.test(/ipod|iphone/i), t = r.test(/like (ipod|iphone)/i);
                return e && !t;
            },
            describe (r) {
                const e = ae.getFirstMatch(/(ipod|iphone)/i, r);
                return {
                    type: rt.mobile,
                    vendor: "Apple",
                    model: e
                };
            }
        },
        {
            test: [
                /nexus\s*[0-6].*/i,
                /galaxy nexus/i
            ],
            describe () {
                return {
                    type: rt.mobile,
                    vendor: "Nexus"
                };
            }
        },
        {
            test: [
                /Nokia/i
            ],
            describe (r) {
                const e = ae.getFirstMatch(/Nokia\s+([0-9]+(\.[0-9]+)?)/i, r), t = {
                    type: rt.mobile,
                    vendor: "Nokia"
                };
                return e && (t.model = e), t;
            }
        },
        {
            test: [
                /[^-]mobi/i
            ],
            describe () {
                return {
                    type: rt.mobile
                };
            }
        },
        {
            test (r) {
                return r.getBrowserName(!0) === "blackberry";
            },
            describe () {
                return {
                    type: rt.mobile,
                    vendor: "BlackBerry"
                };
            }
        },
        {
            test (r) {
                return r.getBrowserName(!0) === "bada";
            },
            describe () {
                return {
                    type: rt.mobile
                };
            }
        },
        {
            test (r) {
                return r.getBrowserName() === "windows phone";
            },
            describe () {
                return {
                    type: rt.mobile,
                    vendor: "Microsoft"
                };
            }
        },
        {
            test (r) {
                const e = Number(String(r.getOSVersion()).split(".")[0]);
                return r.getOSName(!0) === "android" && e >= 3;
            },
            describe () {
                return {
                    type: rt.tablet
                };
            }
        },
        {
            test (r) {
                return r.getOSName(!0) === "android";
            },
            describe () {
                return {
                    type: rt.mobile
                };
            }
        },
        {
            test: [
                /smart-?tv|smarttv/i
            ],
            describe () {
                return {
                    type: rt.tv
                };
            }
        },
        {
            test: [
                /netcast/i
            ],
            describe () {
                return {
                    type: rt.tv
                };
            }
        },
        {
            test (r) {
                return r.getOSName(!0) === "macos";
            },
            describe () {
                return {
                    type: rt.desktop,
                    vendor: "Apple"
                };
            }
        },
        {
            test (r) {
                return r.getOSName(!0) === "windows";
            },
            describe () {
                return {
                    type: rt.desktop
                };
            }
        },
        {
            test (r) {
                return r.getOSName(!0) === "linux";
            },
            describe () {
                return {
                    type: rt.desktop
                };
            }
        },
        {
            test (r) {
                return r.getOSName(!0) === "playstation 4";
            },
            describe () {
                return {
                    type: rt.tv
                };
            }
        },
        {
            test (r) {
                return r.getOSName(!0) === "roku";
            },
            describe () {
                return {
                    type: rt.tv
                };
            }
        }
    ], N1 = [
        {
            test (r) {
                return r.getBrowserName(!0) === "microsoft edge";
            },
            describe (r) {
                if (/\sedg\//i.test(r)) return {
                    name: en.Blink
                };
                const t = ae.getFirstMatch(/edge\/(\d+(\.?_?\d+)+)/i, r);
                return {
                    name: en.EdgeHTML,
                    version: t
                };
            }
        },
        {
            test: [
                /trident/i
            ],
            describe (r) {
                const e = {
                    name: en.Trident
                }, t = ae.getFirstMatch(/trident\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test (r) {
                return r.test(/presto/i);
            },
            describe (r) {
                const e = {
                    name: en.Presto
                }, t = ae.getFirstMatch(/presto\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test (r) {
                const e = r.test(/gecko/i), t = r.test(/like gecko/i);
                return e && !t;
            },
            describe (r) {
                const e = {
                    name: en.Gecko
                }, t = ae.getFirstMatch(/gecko\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        },
        {
            test: [
                /(apple)?webkit\/537\.36/i
            ],
            describe () {
                return {
                    name: en.Blink
                };
            }
        },
        {
            test: [
                /(apple)?webkit/i
            ],
            describe (r) {
                const e = {
                    name: en.WebKit
                }, t = ae.getFirstMatch(/webkit\/(\d+(\.?_?\d+)+)/i, r);
                return t && (e.version = t), e;
            }
        }
    ];
    class bd {
        constructor(e, t = !1, n = null){
            if (e == null || e === "") throw new Error("UserAgent parameter can't be empty");
            this._ua = e;
            let a = !1;
            typeof t == "boolean" ? (a = t, this._hints = n) : t != null && typeof t == "object" ? this._hints = t : this._hints = null, this.parsedResult = {}, a !== !0 && this.parse();
        }
        getHints() {
            return this._hints;
        }
        hasBrand(e) {
            if (!this._hints || !Array.isArray(this._hints.brands)) return !1;
            const t = e.toLowerCase();
            return this._hints.brands.some((n)=>n.brand && n.brand.toLowerCase() === t);
        }
        getBrandVersion(e) {
            if (!this._hints || !Array.isArray(this._hints.brands)) return;
            const t = e.toLowerCase(), n = this._hints.brands.find((a)=>a.brand && a.brand.toLowerCase() === t);
            return n ? n.version : void 0;
        }
        getUA() {
            return this._ua;
        }
        test(e) {
            return e.test(this._ua);
        }
        parseBrowser() {
            this.parsedResult.browser = {};
            const e = ae.find(B1, (t)=>{
                if (typeof t.test == "function") return t.test(this);
                if (Array.isArray(t.test)) return t.test.some((n)=>this.test(n));
                throw new Error("Browser's test function is not valid");
            });
            return e && (this.parsedResult.browser = e.describe(this.getUA(), this)), this.parsedResult.browser;
        }
        getBrowser() {
            return this.parsedResult.browser ? this.parsedResult.browser : this.parseBrowser();
        }
        getBrowserName(e) {
            return e ? String(this.getBrowser().name).toLowerCase() || "" : this.getBrowser().name || "";
        }
        getBrowserVersion() {
            return this.getBrowser().version;
        }
        getOS() {
            return this.parsedResult.os ? this.parsedResult.os : this.parseOS();
        }
        parseOS() {
            this.parsedResult.os = {};
            const e = ae.find(O1, (t)=>{
                if (typeof t.test == "function") return t.test(this);
                if (Array.isArray(t.test)) return t.test.some((n)=>this.test(n));
                throw new Error("Browser's test function is not valid");
            });
            return e && (this.parsedResult.os = e.describe(this.getUA())), this.parsedResult.os;
        }
        getOSName(e) {
            const { name: t } = this.getOS();
            return e ? String(t).toLowerCase() || "" : t || "";
        }
        getOSVersion() {
            return this.getOS().version;
        }
        getPlatform() {
            return this.parsedResult.platform ? this.parsedResult.platform : this.parsePlatform();
        }
        getPlatformType(e = !1) {
            const { type: t } = this.getPlatform();
            return e ? String(t).toLowerCase() || "" : t || "";
        }
        parsePlatform() {
            this.parsedResult.platform = {};
            const e = ae.find(k1, (t)=>{
                if (typeof t.test == "function") return t.test(this);
                if (Array.isArray(t.test)) return t.test.some((n)=>this.test(n));
                throw new Error("Browser's test function is not valid");
            });
            return e && (this.parsedResult.platform = e.describe(this.getUA())), this.parsedResult.platform;
        }
        getEngine() {
            return this.parsedResult.engine ? this.parsedResult.engine : this.parseEngine();
        }
        getEngineName(e) {
            return e ? String(this.getEngine().name).toLowerCase() || "" : this.getEngine().name || "";
        }
        parseEngine() {
            this.parsedResult.engine = {};
            const e = ae.find(N1, (t)=>{
                if (typeof t.test == "function") return t.test(this);
                if (Array.isArray(t.test)) return t.test.some((n)=>this.test(n));
                throw new Error("Browser's test function is not valid");
            });
            return e && (this.parsedResult.engine = e.describe(this.getUA())), this.parsedResult.engine;
        }
        parse() {
            return this.parseBrowser(), this.parseOS(), this.parsePlatform(), this.parseEngine(), this;
        }
        getResult() {
            return ae.assign({}, this.parsedResult);
        }
        satisfies(e) {
            const t = {};
            let n = 0;
            const a = {};
            let i = 0;
            if (Object.keys(e).forEach((o)=>{
                const f = e[o];
                typeof f == "string" ? (a[o] = f, i += 1) : typeof f == "object" && (t[o] = f, n += 1);
            }), n > 0) {
                const o = Object.keys(t), f = ae.find(o, (h)=>this.isOS(h));
                if (f) {
                    const h = this.satisfies(t[f]);
                    if (h !== void 0) return h;
                }
                const c = ae.find(o, (h)=>this.isPlatform(h));
                if (c) {
                    const h = this.satisfies(t[c]);
                    if (h !== void 0) return h;
                }
            }
            if (i > 0) {
                const o = Object.keys(a), f = ae.find(o, (c)=>this.isBrowser(c, !0));
                if (f !== void 0) return this.compareVersion(a[f]);
            }
        }
        isBrowser(e, t = !1) {
            const n = this.getBrowserName().toLowerCase();
            let a = e.toLowerCase();
            const i = ae.getBrowserTypeByAlias(a);
            return t && i && (a = i.toLowerCase()), a === n;
        }
        compareVersion(e) {
            let t = [
                0
            ], n = e, a = !1;
            const i = this.getBrowserVersion();
            if (typeof i == "string") return e[0] === ">" || e[0] === "<" ? (n = e.substr(1), e[1] === "=" ? (a = !0, n = e.substr(2)) : t = [], e[0] === ">" ? t.push(1) : t.push(-1)) : e[0] === "=" ? n = e.substr(1) : e[0] === "~" && (a = !0, n = e.substr(1)), t.indexOf(ae.compareVersions(i, n, a)) > -1;
        }
        isOS(e) {
            return this.getOSName(!0) === String(e).toLowerCase();
        }
        isPlatform(e) {
            return this.getPlatformType(!0) === String(e).toLowerCase();
        }
        isEngine(e) {
            return this.getEngineName(!0) === String(e).toLowerCase();
        }
        is(e, t = !1) {
            return this.isBrowser(e, t) || this.isOS(e) || this.isPlatform(e);
        }
        some(e = []) {
            return e.some((t)=>this.is(t));
        }
    }
    class Bs {
        static getParser(e, t = !1, n = null) {
            if (typeof e != "string") throw new Error("UserAgent should be a string");
            return new bd(e, t, n);
        }
        static parse(e, t = null) {
            return new bd(e, t).getResult();
        }
        static get BROWSER_MAP() {
            return vu;
        }
        static get ENGINE_MAP() {
            return en;
        }
        static get OS_MAP() {
            return Xt;
        }
        static get PLATFORMS_MAP() {
            return rt;
        }
    }
    var Ct = vr.getLogger("customauth");
    function C1(r) {
        return new Promise((e, t)=>{
            const n = (a)=>{
                const { error: i = "", data: s } = a;
                return r.removeEventListener("message", n), i ? t(new Error(i)) : e(s);
            };
            r.addEventListener("message", n);
        });
    }
    const mf = {
        [ot.APPLE]: "apple",
        [ot.GITHUB]: "github",
        [ot.LINKEDIN]: "linkedin",
        [ot.TWITTER]: "twitter",
        [ot.LINE]: "line",
        [ot.EMAIL_PASSWORDLESS]: "email",
        [ot.SMS_PASSWORDLESS]: "sms"
    }, Ma = (r)=>r.href.endsWith("/") ? r.href : `${r.href}/`, wf = ()=>Math.random().toString(36).slice(2), mu = {
        webWorkerSupport: !1
    };
    function Os(r, e) {
        return e ? r : r.toLowerCase();
    }
    const hi = (r, e, t, n = !0)=>{
        const { name: a, sub: i } = r;
        if (t) return Os(r[t], n);
        switch(e){
            case ot.EMAIL_PASSWORDLESS:
            case ot.SMS_PASSWORDLESS:
            case ot.AUTHENTICATOR:
                return Os(a, n);
            case ot.GITHUB:
            case ot.TWITTER:
            case ot.APPLE:
            case ot.LINKEDIN:
            case ot.LINE:
            case ot.WECHAT:
            case ot.KAKAO:
            case ot.FARCASTER:
            case ot.CUSTOM:
                return Os(i, n);
            default:
                throw new Error("Invalid login type to get auth connection id");
        }
    }, Do = (r, e)=>{
        const t = r.split("&").reduce((i, s)=>{
            const [o, f] = s.split("=");
            return i[o] = f, i;
        }, {});
        Ct.info(t, e);
        let n = {}, a = "";
        return Object.keys(t).length > 0 && t.state ? (n = JSON.parse(kr.decode(decodeURIComponent(decodeURIComponent(t.state)))) || {}, a = t.error_description || t.error || a) : Object.keys(e).length > 0 && e.state && (n = JSON.parse(kr.decode(decodeURIComponent(decodeURIComponent(e.state)))) || {}, e.error && (a = e.error)), {
            error: a,
            instanceParameters: n,
            hashParameters: t
        };
    };
    function oa(r) {
        let e;
        try {
            e = window[r];
            const t = "__storage_test__";
            return e.setItem(t, t), e.removeItem(t), !0;
        } catch (t) {
            const n = t;
            return n && (n.code === 22 || n.code === 1014 || n.name === "QuotaExceededError" || n.name === "NS_ERROR_DOM_QUOTA_REACHED") && e && e.length !== 0;
        }
    }
    function xf() {
        const r = window.screenLeft !== void 0 ? window.screenLeft : window.screenX, e = window.screenTop !== void 0 ? window.screenTop : window.screenY, t = 1200, n = 700, a = window.innerWidth ? window.innerWidth : document.documentElement.clientWidth ? document.documentElement.clientWidth : window.screen.width, i = window.innerHeight ? window.innerHeight : document.documentElement.clientHeight ? document.documentElement.clientHeight : window.screen.height, s = 1, o = Math.abs((a - t) / 2 / s + r), f = Math.abs((i - n) / 2 / s + e);
        return `titlebar=0,toolbar=0,status=0,location=0,menubar=0,height=${n / s},width=${t / s},top=${f},left=${o}`;
    }
    const wu = ()=>{
        var r;
        return ((r = window) === null || r === void 0 || (r = r.navigator) === null || r === void 0 ? void 0 : r.userAgent.toLowerCase().indexOf("firefox")) > -1 || !1;
    };
    function Nn(r) {
        const { baseURL: e, query: t, hash: n } = r, a = new URL(e);
        if (t && Object.keys(t).forEach((i)=>{
            a.searchParams.append(i, t[i]);
        }), n) {
            const i = new URL(Nn({
                baseURL: e,
                query: n
            })).searchParams.toString();
            a.hash = i;
        }
        return a.toString();
    }
    const Ra = (r)=>{
        try {
            return new URL(decodeURIComponent(r));
        } catch (e) {
            throw new Error(`${e?.message || ""}, Note: Your jwt domain: (i.e ${r}) must have http:// or https:// prefix`);
        }
    }, xu = (r)=>JSON.parse(kr.decode(r));
    function _u() {
        const e = Bs.getParser(navigator.userAgent).getPlatform();
        return e.type === Bs.PLATFORMS_MAP.tablet || e.type === Bs.PLATFORMS_MAP.mobile;
    }
    function Ta(r) {
        return (r === ot.FACEBOOK || r === ot.LINE) && _u() ? 1e3 * 30 : 1e3 * 1;
    }
    function Pa(r) {
        const [e, t] = r.split(".");
        return {
            header: JSON.parse(kr.decode(e)),
            payload: JSON.parse(kr.decode(t))
        };
    }
    var Oi = {
        exports: {}
    }, pd;
    function vi() {
        if (pd) return Oi.exports;
        pd = 1;
        var r = typeof Reflect == "object" ? Reflect : null, e = r && typeof r.apply == "function" ? r.apply : function(k, D, V) {
            return Function.prototype.apply.call(k, D, V);
        }, t;
        r && typeof r.ownKeys == "function" ? t = r.ownKeys : Object.getOwnPropertySymbols ? t = function(k) {
            return Object.getOwnPropertyNames(k).concat(Object.getOwnPropertySymbols(k));
        } : t = function(k) {
            return Object.getOwnPropertyNames(k);
        };
        function n(N) {
            console && console.warn && console.warn(N);
        }
        var a = Number.isNaN || function(k) {
            return k !== k;
        };
        function i() {
            i.init.call(this);
        }
        Oi.exports = i, Oi.exports.once = y, i.EventEmitter = i, i.prototype._events = void 0, i.prototype._eventsCount = 0, i.prototype._maxListeners = void 0;
        var s = 10;
        function o(N) {
            if (typeof N != "function") throw new TypeError('The "listener" argument must be of type Function. Received type ' + typeof N);
        }
        Object.defineProperty(i, "defaultMaxListeners", {
            enumerable: !0,
            get: function() {
                return s;
            },
            set: function(N) {
                if (typeof N != "number" || N < 0 || a(N)) throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received ' + N + ".");
                s = N;
            }
        }), i.init = function() {
            (this._events === void 0 || this._events === Object.getPrototypeOf(this)._events) && (this._events = Object.create(null), this._eventsCount = 0), this._maxListeners = this._maxListeners || void 0;
        }, i.prototype.setMaxListeners = function(k) {
            if (typeof k != "number" || k < 0 || a(k)) throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received ' + k + ".");
            return this._maxListeners = k, this;
        };
        function f(N) {
            return N._maxListeners === void 0 ? i.defaultMaxListeners : N._maxListeners;
        }
        i.prototype.getMaxListeners = function() {
            return f(this);
        }, i.prototype.emit = function(k) {
            for(var D = [], V = 1; V < arguments.length; V++)D.push(arguments[V]);
            var K = k === "error", j = this._events;
            if (j !== void 0) K = K && j.error === void 0;
            else if (!K) return !1;
            if (K) {
                var H;
                if (D.length > 0 && (H = D[0]), H instanceof Error) throw H;
                var O = new Error("Unhandled error." + (H ? " (" + H.message + ")" : ""));
                throw O.context = H, O;
            }
            var d = j[k];
            if (d === void 0) return !1;
            if (typeof d == "function") e(d, this, D);
            else for(var l = d.length, b = E(d, l), V = 0; V < l; ++V)e(b[V], this, D);
            return !0;
        };
        function c(N, k, D, V) {
            var K, j, H;
            if (o(D), j = N._events, j === void 0 ? (j = N._events = Object.create(null), N._eventsCount = 0) : (j.newListener !== void 0 && (N.emit("newListener", k, D.listener ? D.listener : D), j = N._events), H = j[k]), H === void 0) H = j[k] = D, ++N._eventsCount;
            else if (typeof H == "function" ? H = j[k] = V ? [
                D,
                H
            ] : [
                H,
                D
            ] : V ? H.unshift(D) : H.push(D), K = f(N), K > 0 && H.length > K && !H.warned) {
                H.warned = !0;
                var O = new Error("Possible EventEmitter memory leak detected. " + H.length + " " + String(k) + " listeners added. Use emitter.setMaxListeners() to increase limit");
                O.name = "MaxListenersExceededWarning", O.emitter = N, O.type = k, O.count = H.length, n(O);
            }
            return N;
        }
        i.prototype.addListener = function(k, D) {
            return c(this, k, D, !1);
        }, i.prototype.on = i.prototype.addListener, i.prototype.prependListener = function(k, D) {
            return c(this, k, D, !0);
        };
        function h() {
            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 g(N, k, D) {
            var V = {
                fired: !1,
                wrapFn: void 0,
                target: N,
                type: k,
                listener: D
            }, K = h.bind(V);
            return K.listener = D, V.wrapFn = K, K;
        }
        i.prototype.once = function(k, D) {
            return o(D), this.on(k, g(this, k, D)), this;
        }, i.prototype.prependOnceListener = function(k, D) {
            return o(D), this.prependListener(k, g(this, k, D)), this;
        }, i.prototype.removeListener = function(k, D) {
            var V, K, j, H, O;
            if (o(D), K = this._events, K === void 0) return this;
            if (V = K[k], V === void 0) return this;
            if (V === D || V.listener === D) --this._eventsCount === 0 ? this._events = Object.create(null) : (delete K[k], K.removeListener && this.emit("removeListener", k, V.listener || D));
            else if (typeof V != "function") {
                for(j = -1, H = V.length - 1; H >= 0; H--)if (V[H] === D || V[H].listener === D) {
                    O = V[H].listener, j = H;
                    break;
                }
                if (j < 0) return this;
                j === 0 ? V.shift() : x(V, j), V.length === 1 && (K[k] = V[0]), K.removeListener !== void 0 && this.emit("removeListener", k, O || D);
            }
            return this;
        }, i.prototype.off = i.prototype.removeListener, i.prototype.removeAllListeners = function(k) {
            var D, V, K;
            if (V = this._events, V === void 0) return this;
            if (V.removeListener === void 0) return arguments.length === 0 ? (this._events = Object.create(null), this._eventsCount = 0) : V[k] !== void 0 && (--this._eventsCount === 0 ? this._events = Object.create(null) : delete V[k]), this;
            if (arguments.length === 0) {
                var j = Object.keys(V), H;
                for(K = 0; K < j.length; ++K)H = j[K], H !== "removeListener" && this.removeAllListeners(H);
                return this.removeAllListeners("removeListener"), this._events = Object.create(null), this._eventsCount = 0, this;
            }
            if (D = V[k], typeof D == "function") this.removeListener(k, D);
            else if (D !== void 0) for(K = D.length - 1; K >= 0; K--)this.removeListener(k, D[K]);
            return this;
        };
        function v(N, k, D) {
            var V = N._events;
            if (V === void 0) return [];
            var K = V[k];
            return K === void 0 ? [] : typeof K == "function" ? D ? [
                K.listener || K
            ] : [
                K
            ] : D ? S(K) : E(K, K.length);
        }
        i.prototype.listeners = function(k) {
            return v(this, k, !0);
        }, i.prototype.rawListeners = function(k) {
            return v(this, k, !1);
        }, i.listenerCount = function(N, k) {
            return typeof N.listenerCount == "function" ? N.listenerCount(k) : w.call(N, k);
        }, i.prototype.listenerCount = w;
        function w(N) {
            var k = this._events;
            if (k !== void 0) {
                var D = k[N];
                if (typeof D == "function") return 1;
                if (D !== void 0) return D.length;
            }
            return 0;
        }
        i.prototype.eventNames = function() {
            return this._eventsCount > 0 ? t(this._events) : [];
        };
        function E(N, k) {
            for(var D = new Array(k), V = 0; V < k; ++V)D[V] = N[V];
            return D;
        }
        function x(N, k) {
            for(; k + 1 < N.length; k++)N[k] = N[k + 1];
            N.pop();
        }
        function S(N) {
            for(var k = new Array(N.length), D = 0; D < k.length; ++D)k[D] = N[D].listener || N[D];
            return k;
        }
        function y(N, k) {
            return new Promise(function(D, V) {
                function K(H) {
                    N.removeListener(k, j), V(H);
                }
                function j() {
                    typeof N.removeListener == "function" && N.removeListener("error", K), D([].slice.call(arguments));
                }
                P(N, k, j, {
                    once: !0
                }), k !== "error" && A(N, K, {
                    once: !0
                });
            });
        }
        function A(N, k, D) {
            typeof N.on == "function" && P(N, "error", k, D);
        }
        function P(N, k, D, V) {
            if (typeof N.on == "function") V.once ? N.once(k, D) : N.on(k, D);
            else if (typeof N.addEventListener == "function") N.addEventListener(k, function K(j) {
                V.once && N.removeEventListener(k, K), D(j);
            });
            else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type ' + typeof N);
        }
        return Oi.exports;
    }
    var _f = vi();
    let Ba = class extends _f.EventEmitter {
        constructor({ url: e, target: t, features: n, timeout: a = 3e4 }){
            super(), he(this, "url", void 0), he(this, "target", void 0), he(this, "features", void 0), he(this, "window", void 0), he(this, "windowTimer", void 0), he(this, "iClosedWindow", void 0), he(this, "timeout", void 0), this.url = e, this.target = t || "_blank", this.features = n || xf(), this.window = void 0, this.windowTimer = void 0, this.iClosedWindow = !1, this.timeout = a, this._setupTimer();
        }
        _setupTimer() {
            this.windowTimer = Number(setInterval(()=>{
                this.window && this.window.closed && (clearInterval(this.windowTimer), setTimeout(()=>{
                    this.iClosedWindow || this.emit("close"), this.iClosedWindow = !1, this.window = void 0;
                }, this.timeout)), this.window === void 0 && clearInterval(this.windowTimer);
            }, 500));
        }
        open() {
            var e;
            if (this.window = window.open(this.url.href, this.target, this.features), !this.window) throw new Error("popup window is blocked");
            return (e = this.window) !== null && e !== void 0 && e.focus && this.window.focus(), Promise.resolve();
        }
        close() {
            this.iClosedWindow = !0, this.window && this.window.close();
        }
        redirect(e) {
            e ? window.location.replace(this.url.href) : window.location.href = this.url.href;
        }
    };
    const L1 = [
        "access_token",
        "id_token"
    ];
    class Gr {
        constructor(e){
            he(this, "nonce", wf()), he(this, "finalURL", void 0), he(this, "params", void 0), this.params = e;
        }
        get state() {
            return encodeURIComponent(kr.encode(JSON.stringify(Be(Be({}, this.params.customState || {}), {}, {
                instanceId: this.nonce,
                authConnectionId: this.params.authConnectionId,
                authConnection: this.params.authConnection,
                groupedAuthConnectionId: this.params.groupedAuthConnectionId,
                redirectToOpener: this.params.redirectToOpener || !1
            }))));
        }
        async handleLoginWindow(e) {
            const t = new Ba({
                url: this.finalURL,
                features: e.popupFeatures,
                timeout: Ta(this.params.authConnection)
            });
            if (this.params.uxMode === Zt.REDIRECT) t.redirect(e.locationReplaceOnRedirect);
            else {
                const { RedundantAdaptiveBroadcastChannel: n } = await Lh(async ()=>{
                    const { RedundantAdaptiveBroadcastChannel: a } = await import("./index-D5n26yMc.js").then(async (m)=>{
                        await m.__tla;
                        return m;
                    });
                    return {
                        RedundantAdaptiveBroadcastChannel: a
                    };
                }, __vite__mapDeps([0,1,2,3,4,5,6,7,8]));
                return new Promise((a, i)=>{
                    let s;
                    const o = async (f)=>{
                        try {
                            const { error: c, data: h } = f, g = h || {}, { instanceParams: v, hashParams: { access_token: w, id_token: E } } = g, x = sa(g.hashParams, L1);
                            if (c) {
                                Ct.error(f), i(new Error(`Error: ${c}. Info: ${JSON.stringify(f.data || {})}`));
                                return;
                            }
                            f.data && v.authConnectionId === this.params.authConnectionId && (Ct.info(f.data), !this.params.redirectToOpener && s && await s.postMessage({
                                success: !0
                            }), a(Be(Be({
                                accessToken: w,
                                idToken: E || ""
                            }, x), {}, {
                                state: v
                            })));
                        } catch (c) {
                            Ct.error(c), i(c);
                        }
                    };
                    if (!this.params.redirectToOpener) s = new n(`redirect_channel_${this.nonce}`, mu), s.addEventListener("message", async (f)=>{
                        await o(f), s.close(), t.close();
                    });
                    else {
                        const f = async (c)=>{
                            if (!c.data) return;
                            const h = c.data;
                            h.channel === `redirect_channel_${this.nonce}` && (window.removeEventListener("message", f), o(h), t.close());
                        };
                        window.addEventListener("message", f);
                    }
                    try {
                        t.open();
                    } catch (f) {
                        Ct.error(f), i(f);
                        return;
                    }
                    t.once("close", ()=>{
                        s && s.close(), i(new Error("user closed popup"));
                    });
                });
            }
            return null;
        }
    }
    class U1 extends Gr {
        constructor(e){
            super(e), he(this, "RESPONSE_TYPE", "token"), he(this, "SCOPE", "identify email"), this.setFinalUrl();
        }
        setFinalUrl() {
            const e = new URL("https://discord.com/api/oauth2/authorize"), t = JSON.parse(JSON.stringify(this.params.jwtParams || {})), n = lr({
                state: this.state,
                response_type: this.RESPONSE_TYPE,
                client_id: this.params.clientId,
                redirect_uri: this.params.redirect_uri,
                scope: this.SCOPE
            }, t);
            Object.keys(n).forEach((a)=>{
                const i = a;
                n[i] && e.searchParams.append(i, n[i]);
            }), this.finalURL = e;
        }
        async getUserInfo(e) {
            const { accessToken: t } = e, n = await Vr("https://discord.com/api/users/@me", {
                headers: {
                    Authorization: `Bearer ${t}`
                }
            }), { id: a, avatar: i, email: s = "", username: o = "", discriminator: f = "" } = n;
            return {
                profileImage: i === null ? `https://cdn.discordapp.com/embed/avatars/${Number(f) % 5}.png` : `https://cdn.discordapp.com/avatars/${a}/${i}.png?size=2048`,
                name: `${o}#${f}`,
                email: s,
                userId: a,
                authConnectionId: this.params.authConnectionId,
                authConnection: this.params.authConnection,
                groupedAuthConnectionId: this.params.groupedAuthConnectionId
            };
        }
    }
    class q1 extends Gr {
        constructor(e){
            super(e), he(this, "RESPONSE_TYPE", "token"), he(this, "SCOPE", "public_profile email"), this.setFinalUrl();
        }
        setFinalUrl() {
            const e = new URL("https://www.facebook.com/v20.0/dialog/oauth"), t = JSON.parse(JSON.stringify(this.params.jwtParams || {})), n = lr({
                state: this.state,
                response_type: this.RESPONSE_TYPE,
                client_id: this.params.clientId,
                redirect_uri: this.params.redirect_uri,
                scope: this.SCOPE
            }, t);
            Object.keys(n).forEach((a)=>{
                const i = a;
                n[i] && e.searchParams.append(i, n[i]);
            }), this.finalURL = e;
        }
        async getUserInfo(e) {
            const { accessToken: t } = e, n = await Vr("https://graph.facebook.com/me?fields=name,email,picture.type(large)", {
                headers: {
                    Authorization: `Bearer ${t}`
                }
            }), { name: a = "", id: i, picture: s, email: o = "" } = n;
            return {
                email: o,
                name: a,
                profileImage: s.data.url || "",
                authConnectionId: this.params.authConnectionId,
                authConnection: this.params.authConnection,
                groupedAuthConnectionId: this.params.groupedAuthConnectionId,
                userId: i
            };
        }
    }
    class D1 extends Gr {
        constructor(e){
            super(e), he(this, "RESPONSE_TYPE", "token id_token"), he(this, "SCOPE", "profile email openid"), he(this, "PROMPT", "select_account"), this.setFinalUrl();
        }
        setFinalUrl() {
            const e = new URL("https://accounts.google.com/o/oauth2/v2/auth"), t = JSON.parse(JSON.stringify(this.params.jwtParams || {})), n = lr({
                state: this.state,
                response_type: this.RESPONSE_TYPE,
                client_id: this.params.clientId,
                prompt: this.PROMPT,
                redirect_uri: this.params.redirect_uri,
                scope: this.SCOPE,
                nonce: this.nonce
            }, t);
            Object.keys(n).forEach((a)=>{
                const i = a;
                n[i] && e.searchParams.append(i, n[i]);
            }), this.finalURL = e;
        }
        async getUserInfo(e) {
            const { accessToken: t } = e, n = await Vr("https://www.googleapis.com/userinfo/v2/me", {
                headers: {
                    Authorization: `Bearer ${t}`
                }
            }), { picture: a = "", email: i = "", name: s = "" } = n;
            return {
                email: i,
                name: s,
                profileImage: a,
                authConnectionId: this.params.authConnectionId,
                authConnection: this.params.authConnection,
                groupedAuthConnectionId: this.params.groupedAuthConnectionId,
                userId: i.toLowerCase()
            };
        }
    }
    class F1 extends Gr {
        constructor(e){
            super(e), he(this, "SCOPE", "openid profile email"), he(this, "RESPONSE_TYPE", "token id_token"), he(this, "PROMPT", "login"), this.setFinalUrl();
        }
        setFinalUrl() {
            const { domain: e } = this.params.jwtParams, t = Ra(e);
            t.pathname += t.pathname.endsWith("/") ? "authorize" : "/authorize";
            const n = JSON.parse(JSON.stringify(this.params.jwtParams));
            delete n.domain;
            const a = lr({
                state: this.state,
                response_type: this.RESPONSE_TYPE,
                client_id: this.params.clientId,
                prompt: this.PROMPT,
                redirect_uri: this.params.redirect_uri,
                scope: this.SCOPE,
                connection: mf[this.params.authConnection],
                nonce: this.nonce
            }, n);
            Object.keys(a).forEach((i)=>{
                const s = i;
                a[s] && t.searchParams.append(s, a[s]);
            }), this.finalURL = t;
        }
        async getUserInfo(e) {
            const { idToken: t, accessToken: n } = e, { domain: a, userIdField: i, isUserIdCaseSensitive: s, user_info_route: o = "userinfo" } = this.params.jwtParams;
            if (t) {
                const f = Pa(t).payload, { name: c, email: h, picture: g } = f;
                return {
                    profileImage: g,
                    name: c,
                    email: h,
                    userId: hi(f, this.params.authConnection, i, s),
                    authConnectionId: this.params.authConnectionId,
                    authConnection: this.params.authConnection,
                    groupedAuthConnectionId: this.params.groupedAuthConnectionId
                };
            }
            if (n) try {
                const f = new URL(a), c = await Vr(`${Ma(f)}${o}`, {
                    headers: {
                        Authorization: `Bearer ${n}`
                    }
                }), { picture: h, name: g, email: v } = c;
                return {
                    email: v,
                    name: g,
                    profileImage: h,
                    userId: hi(c, this.params.authConnection, i, s),
                    authConnectionId: this.params.authConnectionId,
                    authConnection: this.params.authConnection,
                    groupedAuthConnectionId: this.params.groupedAuthConnectionId
                };
            } catch (f) {
                vr.warn(f, "Unable to get userinfo from endpoint");
            }
            throw new Error("Access/id token not available");
        }
    }
    class $1 extends Gr {
        constructor(e){
            super(e), this.setFinalUrl();
        }
        setFinalUrl() {
            const e = JSON.parse(JSON.stringify(this.params.jwtParams));
            delete e.domain;
            const t = lr({
                state: this.state,
                client_id: this.params.clientId,
                nonce: this.nonce
            }, e);
            this.finalURL = new URL(Nn({
                baseURL: this.params.redirect_uri,
                query: null,
                hash: t
            }));
        }
        async getUserInfo(e) {
            const { idToken: t, accessToken: n } = e, { domain: a, userIdField: i, isUserIdCaseSensitive: s, user_info_route: o = "userinfo" } = this.params.jwtParams;
            if (t) {
                const f = Pa(t).payload, { name: c, email: h, picture: g } = f;
                return {
                    profileImage: g,
                    name: c,
                    email: h,
                    userId: hi(f, this.params.authConnection, i, s),
                    authConnectionId: this.params.authConnectionId,
                    authConnection: this.params.authConnection,
                    groupedAuthConnectionId: this.params.groupedAuthConnectionId
                };
            }
            if (n) try {
                const f = new URL(a), c = await Vr(`${Ma(f)}${o}`, {
                    headers: {
                        Authorization: `Bearer ${n}`
                    }
                }), { picture: h, name: g, email: v } = c;
                return {
                    email: v,
                    name: g,
                    profileImage: h,
                    userId: hi(c, this.params.authConnection, i, s),
                    authConnectionId: this.params.authConnectionId,
                    authConnection: this.params.authConnection,
                    groupedAuthConnectionId: this.params.groupedAuthConnectionId
                };
            } catch (f) {
                vr.warn(f, "Unable to get userinfo from endpoint");
            }
            throw new Error("Access/id token not available");
        }
        handleLoginWindow(e) {
            const { id_token: t, access_token: n } = this.params.jwtParams, a = new Ba({
                url: this.finalURL,
                features: e.popupFeatures
            });
            if (this.params.uxMode === Zt.REDIRECT) a.redirect(e.locationReplaceOnRedirect);
            else return Promise.resolve({
                state: {},
                idToken: t,
                accessToken: n
            });
            return null;
        }
    }
    const Fo = (r)=>r.padStart(64, "0").slice(0, 64);
    class K1 {
        constructor(){
            he(this, "sessionId", void 0);
        }
        checkSessionParams() {
            if (!this.sessionId) throw new Error("Session id is required");
            this.sessionId = Fo(this.sessionId);
        }
        request({ method: e = "GET", url: t, data: n = {}, headers: a = {} }) {
            const i = {
                headers: a
            };
            switch(e){
                case "GET":
                    return Vr(t, i);
                case "POST":
                    return cr(t, n, i);
                case "PUT":
                    return E1(t, n, i);
                case "PATCH":
                    return S1(t, n, i);
            }
            throw new Error("Invalid method type");
        }
    }
    const j1 = "https://api.web3auth.io/session-service", fa = new un.ec("secp256k1"), ur = globalThis.crypto || globalThis.msCrypto || {}, an = ur.subtle || ur.webkitSubtle, H1 = Buffer.from("fffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141", "hex"), z1 = Buffer.alloc(32, 0);
    function cn(r, e) {
        if (!r) throw new Error(e || "Assertion failed");
    }
    function W1(r) {
        return Buffer.isBuffer(r) && r.length === 32;
    }
    function Sf(r) {
        return W1(r) ? r.compare(z1) > 0 && r.compare(H1) < 0 : !1;
    }
    function Y1(r, e) {
        if (r.length !== e.length) return !1;
        let t = 0;
        for(let n = 0; n < r.length; n++)t |= r[n] ^ e[n];
        return t === 0;
    }
    function ii(r) {
        if (typeof ur.getRandomValues > "u") return Buffer.from(ur.randomBytes(r));
        const e = new Uint8Array(r);
        return ur.getRandomValues(e), Buffer.from(e);
    }
    async function Su(r) {
        if (!ur.createHash) {
            const n = await an.digest("SHA-512", r);
            return new Uint8Array(n);
        }
        const t = ur.createHash("sha512").update(r).digest();
        return new Uint8Array(t);
    }
    function Eu(r) {
        return async function(e, t, n) {
            if (an && an[r] && an.importKey) {
                const a = {
                    name: "AES-CBC"
                }, i = await an.importKey("raw", t, a, !1, [
                    r
                ]), s = {
                    name: "AES-CBC",
                    iv: e
                }, o = await an[r](s, i, n);
                return Buffer.from(new Uint8Array(o));
            } else if (r === "encrypt" && ur.createCipheriv) {
                const a = ur.createCipheriv("aes-256-cbc", t, e), i = a.update(n), s = a.final();
                return Buffer.concat([
                    i,
                    s
                ]);
            } else if (r === "decrypt" && ur.createDecipheriv) {
                const a = ur.createDecipheriv("aes-256-cbc", t, e), i = a.update(n), s = a.final();
                return Buffer.concat([
                    i,
                    s
                ]);
            }
            throw new Error(`Unsupported operation: ${r}`);
        };
    }
    const V1 = Eu("encrypt"), G1 = Eu("decrypt");
    async function Au(r, e) {
        if (!ur.createHmac) {
            const a = {
                name: "HMAC",
                hash: {
                    name: "SHA-256"
                }
            }, i = await an.importKey("raw", new Uint8Array(r), a, !1, [
                "sign",
                "verify"
            ]), s = await an.sign("HMAC", i, e);
            return Buffer.from(new Uint8Array(s));
        }
        const t = ur.createHmac("sha256", Buffer.from(r));
        return t.update(e), t.digest();
    }
    async function J1(r, e, t) {
        const n = await Au(r, e);
        return Y1(n, t);
    }
    let Iu, X1, Ef, Mu, Af, qn;
    Iu = function() {
        let r = ii(32);
        for(; !Sf(r);)r = ii(32);
        return r;
    };
    Sr = function(r) {
        return Ef(r), Buffer.from(fa.keyFromPrivate(r).getPublic("array"));
    };
    ai = async function(r, e) {
        return Ef(r), cn(e.length > 0, "Message should not be empty"), cn(e.length <= 32, "Message is too long"), Buffer.from(fa.sign(e, r, {
            canonical: !0
        }).toDER());
    };
    X1 = function(r) {
        cn(r.length === 65 || r.length === 33, "Bad public key: expected 65 or 33 bytes, got " + r.length), r.length === 65 && cn(r[0] === 4, "Bad public key: expected first byte 4, got " + r[0]), r.length === 33 && cn(r[0] === 2 || r[0] === 3, "Bad public key: expected first byte 2 or 3, got " + r[0]);
    };
    Ef = function(r) {
        cn(Buffer.isBuffer(r), "Bad private key: expected Buffer"), cn(r.length === 32, "Bad private key: expected 32 bytes, got " + r.length), cn(Sf(r), "Bad private key: out of range");
    };
    Mu = async function(r, e, t) {
        Ef(r), X1(e);
        const n = fa.keyFromPrivate(r), a = fa.keyFromPublic(e), i = n.derive(a.getPublic());
        return t ? Buffer.from(i.toString(16, 64), "hex") : Buffer.from(i.toArray());
    };
    Af = async function(r, e, t) {
        t = t || {};
        let n = t.ephemPrivateKey || ii(32);
        for(; !Sf(n);)n = t.ephemPrivateKey || ii(32);
        const a = Sr(n), i = await Mu(n, r, t.padding), s = await Su(i), o = t.iv || ii(16), f = s.slice(0, 32), c = s.slice(32), g = await V1(o, Buffer.from(f), e), v = Buffer.concat([
            o,
            a,
            g
        ]), w = await Au(Buffer.from(c), v);
        return {
            iv: o,
            ephemPublicKey: a,
            ciphertext: g,
            mac: w
        };
    };
    qn = async function(r, e, t) {
        const n = await Mu(r, e.ephemPublicKey, t), a = await Su(n), i = a.slice(0, 32), s = a.slice(32), o = Buffer.concat([
            e.iv,
            e.ephemPublicKey,
            e.ciphertext
        ]), f = await J1(Buffer.from(s), o, e.mac);
        if (!f && !t) return qn(r, e, !0);
        if (!f && t === !0) throw new Error("bad MAC after trying padded");
        const c = await G1(e.iv, Buffer.from(i), e.ciphertext);
        return Buffer.from(new Uint8Array(c));
    };
    var ki = {}, ks, gd;
    function Z1() {
        if (gd) return ks;
        gd = 1;
        var r, e, t = {
            '"': '"',
            "\\": "\\",
            "/": "/",
            b: "\b",
            f: "\f",
            n: `
`,
            r: "\r",
            t: "	"
        }, n;
        function a(w) {
            throw {
                name: "SyntaxError",
                message: w,
                at: r,
                text: n
            };
        }
        function i(w) {
            return w && w !== e && a("Expected '" + w + "' instead of '" + e + "'"), e = n.charAt(r), r += 1, e;
        }
        function s() {
            var w, E = "";
            for(e === "-" && (E = "-", i("-")); e >= "0" && e <= "9";)E += e, i();
            if (e === ".") for(E += "."; i() && e >= "0" && e <= "9";)E += e;
            if (e === "e" || e === "E") for(E += e, i(), (e === "-" || e === "+") && (E += e, i()); e >= "0" && e <= "9";)E += e, i();
            return w = Number(E), isFinite(w) || a("Bad number"), w;
        }
        function o() {
            var w, E, x = "", S;
            if (e === '"') for(; i();){
                if (e === '"') return i(), x;
                if (e === "\\") if (i(), e === "u") {
                    for(S = 0, E = 0; E < 4 && (w = parseInt(i(), 16), !!isFinite(w)); E += 1)S = S * 16 + w;
                    x += String.fromCharCode(S);
                } else if (typeof t[e] == "string") x += t[e];
                else break;
                else x += e;
            }
            a("Bad string");
        }
        function f() {
            for(; e && e <= " ";)i();
        }
        function c() {
            switch(e){
                case "t":
                    return i("t"), i("r"), i("u"), i("e"), !0;
                case "f":
                    return i("f"), i("a"), i("l"), i("s"), i("e"), !1;
                case "n":
                    return i("n"), i("u"), i("l"), i("l"), null;
                default:
                    a("Unexpected '" + e + "'");
            }
        }
        function h() {
            var w = [];
            if (e === "[") {
                if (i("["), f(), e === "]") return i("]"), w;
                for(; e;){
                    if (w.push(v()), f(), e === "]") return i("]"), w;
                    i(","), f();
                }
            }
            a("Bad array");
        }
        function g() {
            var w, E = {};
            if (e === "{") {
                if (i("{"), f(), e === "}") return i("}"), E;
                for(; e;){
                    if (w = o(), f(), i(":"), Object.prototype.hasOwnProperty.call(E, w) && a('Duplicate key "' + w + '"'), E[w] = v(), f(), e === "}") return i("}"), E;
                    i(","), f();
                }
            }
            a("Bad object");
        }
        function v() {
            switch(f(), e){
                case "{":
                    return g();
                case "[":
                    return h();
                case '"':
                    return o();
                case "-":
                    return s();
                default:
                    return e >= "0" && e <= "9" ? s() : c();
            }
        }
        return ks = function(w, E) {
            var x;
            return n = w, r = 0, e = " ", x = v(), f(), e && a("Syntax error"), typeof E == "function" ? (function S(y, A) {
                var P, N, k = y[A];
                if (k && typeof k == "object") for(P in v)Object.prototype.hasOwnProperty.call(k, P) && (N = S(k, P), typeof N > "u" ? delete k[P] : k[P] = N);
                return E.call(y, A, k);
            })({
                "": x
            }, "") : x;
        }, ks;
    }
    var Ns, yd;
    function Q1() {
        if (yd) return Ns;
        yd = 1;
        var r = /[\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g, e, t, n = {
            "\b": "\\b",
            "	": "\\t",
            "\n": "\\n",
            "\f": "\\f",
            "\r": "\\r",
            '"': '\\"',
            "\\": "\\\\"
        }, a;
        function i(o) {
            return r.lastIndex = 0, r.test(o) ? '"' + o.replace(r, function(f) {
                var c = n[f];
                return typeof c == "string" ? c : "\\u" + ("0000" + f.charCodeAt(0).toString(16)).slice(-4);
            }) + '"' : '"' + o + '"';
        }
        function s(o, f) {
            var c, h, g, v, w = e, E, x = f[o];
            switch(x && typeof x == "object" && typeof x.toJSON == "function" && (x = x.toJSON(o)), typeof a == "function" && (x = a.call(f, o, x)), typeof x){
                case "string":
                    return i(x);
                case "number":
                    return isFinite(x) ? String(x) : "null";
                case "boolean":
                case "null":
                    return String(x);
                case "object":
                    if (!x) return "null";
                    if (e += t, E = [], Object.prototype.toString.apply(x) === "[object Array]") {
                        for(v = x.length, c = 0; c < v; c += 1)E[c] = s(c, x) || "null";
                        return g = E.length === 0 ? "[]" : e ? `[
` + e + E.join(`,
` + e) + `
` + w + "]" : "[" + E.join(",") + "]", e = w, g;
                    }
                    if (a && typeof a == "object") for(v = a.length, c = 0; c < v; c += 1)h = a[c], typeof h == "string" && (g = s(h, x), g && E.push(i(h) + (e ? ": " : ":") + g));
                    else for(h in x)Object.prototype.hasOwnProperty.call(x, h) && (g = s(h, x), g && E.push(i(h) + (e ? ": " : ":") + g));
                    return g = E.length === 0 ? "{}" : e ? `{
` + e + E.join(`,
` + e) + `
` + w + "}" : "{" + E.join(",") + "}", e = w, g;
            }
        }
        return Ns = function(o, f, c) {
            var h;
            if (e = "", t = "", typeof c == "number") for(h = 0; h < c; h += 1)t += " ";
            else typeof c == "string" && (t = c);
            if (a = f, f && typeof f != "function" && (typeof f != "object" || typeof f.length != "number")) throw new Error("JSON.stringify");
            return s("", {
                "": o
            });
        }, Ns;
    }
    var vd;
    function e2() {
        return vd || (vd = 1, ki.parse = Z1(), ki.stringify = Q1()), ki;
    }
    var Cs, md;
    function t2() {
        if (md) return Cs;
        md = 1;
        var r = {}.toString;
        return Cs = Array.isArray || function(e) {
            return r.call(e) == "[object Array]";
        }, Cs;
    }
    var Ls, wd;
    function r2() {
        if (wd) return Ls;
        wd = 1;
        var r = (typeof JSON < "u" ? JSON : e2()).stringify, e = t2(), t = Mh(), n = Rh(), a = Th(), i = a("Array.prototype.join"), s = a("Array.prototype.indexOf"), o = a("Array.prototype.splice"), f = a("Array.prototype.sort"), c = function(v, w) {
            for(var E = "", x = 0; x < v; x += 1)E += w;
            return E;
        }, h = function(g, v, w) {
            return w;
        };
        return Ls = function(v) {
            var w = arguments.length > 1 ? arguments[1] : void 0, E = w && w.space || "";
            typeof E == "number" && (E = c(E, " "));
            var x = !!w && typeof w.cycles == "boolean" && w.cycles, S = w && w.replacer ? n(w.replacer) : h;
            if (w && typeof w.collapseEmpty < "u" && typeof w.collapseEmpty != "boolean") throw new TypeError("`collapseEmpty` must be a boolean, if provided");
            var y = !!w && w.collapseEmpty, A = typeof w == "function" ? w : w && w.cmp, P = A && function(k) {
                var D = A.length > 2 && function(K) {
                    return k[K];
                };
                return function(V, K) {
                    return A({
                        key: V,
                        value: k[V]
                    }, {
                        key: K,
                        value: k[K]
                    }, D ? {
                        __proto__: null,
                        get: D
                    } : void 0);
                };
            }, N = [];
            return (function k(D, V, K, j) {
                var H = E ? `
` + c(j, E) : "", O = E ? ": " : ":";
                if (K && K.toJSON && typeof K.toJSON == "function" && (K = K.toJSON()), K = S(D, V, K), K !== void 0) {
                    if (typeof K != "object" || K === null) return r(K);
                    var d = function(R, u) {
                        return y && R.length === 0 ? u : (u === "[]" ? "[" : "{") + i(R, ",") + H + (u === "[]" ? "]" : "}");
                    };
                    if (e(K)) {
                        for(var _ = [], l = 0; l < K.length; l++){
                            var b = k(K, l, K[l], j + 1) || r(null);
                            _[_.length] = H + E + b;
                        }
                        return d(_, "[]");
                    }
                    if (s(N, K) !== -1) {
                        if (x) return r("__cycle__");
                        throw new TypeError("Converting circular structure to JSON");
                    } else N[N.length] = K;
                    for(var m = f(t(K), P && P(K)), _ = [], l = 0; l < m.length; l++){
                        var V = m[l], B = k(K, V, K[V], j + 1);
                        if (B) {
                            var T = r(V) + O + B;
                            _[_.length] = H + E + T;
                        }
                    }
                    return o(N, s(N, K), 1), d(_, "{}");
                }
            })({
                "": v
            }, "", v, 0);
        }, Ls;
    }
    var n2 = r2();
    const Rn = Lr(n2), i2 = yn;
    function Ru(r) {
        return (e)=>(i2(e), r(e));
    }
    const Oa = (()=>{
        const r = Ru(fc);
        return r.create = fc.create, r;
    })();
    Br = function(r) {
        return Buffer.from(Oa(r));
    };
    const a2 = new un.ec("secp256k1");
    function s2(r) {
        return {
            iv: Buffer.from(r.iv, "hex"),
            ephemPublicKey: Buffer.from(r.ephemPublicKey, "hex"),
            ciphertext: Buffer.from(r.ciphertext, "hex"),
            mac: Buffer.from(r.mac, "hex")
        };
    }
    function o2(r) {
        return {
            iv: Buffer.from(r.iv).toString("hex"),
            ephemPublicKey: Buffer.from(r.ephemPublicKey).toString("hex"),
            ciphertext: Buffer.from(r.ciphertext).toString("hex"),
            mac: Buffer.from(r.mac).toString("hex")
        };
    }
    si = async function(r, e) {
        const t = JSON.stringify(e), n = Buffer.from(t, "utf-8"), a = await Af(Sr(Buffer.from(r, "hex")), n), i = o2(a);
        return JSON.stringify(i);
    };
    If = async function(r, e) {
        const t = JSON.parse(e), n = s2(t), a = a2.keyFromPrivate(r), s = (await qn(Buffer.from(a.getPrivate().toString("hex", 64), "hex"), n)).toString("utf-8");
        return JSON.parse(s);
    };
    const f2 = 86400;
    class ei extends K1 {
        constructor({ sessionServerBaseUrl: e, sessionNamespace: t, sessionTime: n, sessionId: a, allowedOrigin: i } = {}){
            super(), he(this, "sessionServerBaseUrl", j1), he(this, "sessionNamespace", void 0), he(this, "allowedOrigin", void 0), he(this, "sessionTime", f2), he(this, "sessionId", ""), e && (this.sessionServerBaseUrl = e), t && (this.sessionNamespace = t), n && (this.sessionTime = n), a && (this.sessionId = Fo(a)), i ? this.allowedOrigin = i : this.allowedOrigin = "*";
        }
        static generateRandomSessionKey() {
            return Fo(Iu().toString("hex"));
        }
        async createSession(e, t = {}) {
            super.checkSessionParams();
            const n = Buffer.from(this.sessionId, "hex"), a = Sr(n).toString("hex"), i = await si(this.sessionId, e), s = (await ai(n, Br(Buffer.from(i, "utf8")))).toString("hex"), o = {
                key: a,
                data: i,
                signature: s,
                namespace: this.sessionNamespace,
                timeout: this.sessionTime,
                allowedOrigin: this.allowedOrigin
            };
            return await super.request({
                method: "POST",
                url: `${this.sessionServerBaseUrl}/v2/store/set`,
                data: o,
                headers: t
            }), this.sessionId;
        }
        async authorizeSession({ headers: e } = {
            headers: {}
        }) {
            super.checkSessionParams();
            const n = {
                key: Sr(Buffer.from(this.sessionId, "hex")).toString("hex"),
                namespace: this.sessionNamespace
            }, a = await super.request({
                method: "POST",
                url: `${this.sessionServerBaseUrl}/v2/store/get`,
                data: n,
                headers: e
            });
            if (!a.message) throw new Error("Session Expired or Invalid public key");
            const i = await If(this.sessionId, a.message);
            if (i.error) throw new Error("There was an error decrypting data.");
            return i;
        }
        async updateSession(e, t = {}) {
            super.checkSessionParams();
            const n = Buffer.from(this.sessionId, "hex"), a = Sr(n).toString("hex"), i = await si(this.sessionId, e), s = (await ai(n, Br(Buffer.from(i, "utf8")))).toString("hex"), o = {
                key: a,
                data: i,
                signature: s,
                namespace: this.sessionNamespace,
                allowedOrigin: this.allowedOrigin
            };
            await super.request({
                method: "PUT",
                url: `${this.sessionServerBaseUrl}/v2/store/update`,
                data: o,
                headers: t
            });
        }
        async invalidateSession(e = {}) {
            super.checkSessionParams();
            const t = Buffer.from(this.sessionId, "hex"), n = Sr(t).toString("hex"), a = await si(this.sessionId, {}), i = (await ai(t, Br(Buffer.from(a, "utf8")))).toString("hex"), s = {
                key: n,
                data: a,
                signature: i,
                namespace: this.sessionNamespace,
                timeout: 1
            };
            return await super.request({
                method: "POST",
                url: `${this.sessionServerBaseUrl}/v2/store/set`,
                data: s,
                headers: e
            }), this.sessionId = "", !0;
        }
    }
    async function c2(r, e) {
        try {
            return await new ei({
                sessionId: r,
                sessionServerBaseUrl: e,
                allowedOrigin: !0
            }).authorizeSession();
        } catch (t) {
            throw vr.error("fetch data from storage server error", t), new Error("Unable to retrieve data from storage server, invalid key or key expired.");
        }
    }
    class d2 extends Gr {
        constructor(e){
            super(e), this.setFinalUrl();
        }
        setFinalUrl() {
            const { passkeysHostUrl: e } = this.params.customState || {};
            if (!e) throw new Error("Invalid passkeys url.");
            const t = new URL(e), n = JSON.parse(JSON.stringify(this.params.jwtParams || {})), a = lr({
                state: this.state,
                client_id: this.params.clientId,
                redirect_uri: this.params.redirect_uri
            }, n);
            Object.keys(a).forEach((i)=>{
                const s = i;
                a[s] && t.searchParams.append(s, a[s]);
            }), this.finalURL = t;
        }
        async getUserInfo(e, t) {
            const { idToken: n, extraParams: a } = e, { sessionId: i } = JSON.parse(kr.decode(a)) || {};
            if (!i) throw new Error("sessionId not found");
            const { verifier_id: s, signature: o, clientDataJSON: f, authenticatorData: c, publicKey: h, challenge: g, rpOrigin: v, rpId: w, credId: E, transports: x, username: S } = await c2(i, t);
            if (o !== n) throw new Error("idtoken should be equal to signature");
            return {
                email: "",
                name: "Passkeys Login",
                profileImage: "",
                authConnectionId: this.params.authConnectionId,
                userId: s,
                authConnection: this.params.authConnection,
                groupedAuthConnectionId: this.params.groupedAuthConnectionId,
                extraConnectionParams: {
                    signature: o,
                    clientDataJSON: f,
                    authenticatorData: c,
                    publicKey: h,
                    challenge: g,
                    rpOrigin: v,
                    rpId: w,
                    credId: E,
                    transports: x,
                    username: S
                }
            };
        }
    }
    const u2 = [
        "event",
        "origin",
        "result"
    ];
    class l2 extends Gr {
        constructor(e){
            super(e), he(this, "RESPONSE_TYPE", "token"), he(this, "SCOPE", "profile"), he(this, "PROMPT", "select_account"), this.setFinalUrl();
        }
        setFinalUrl() {
            const { domain: e } = this.params.jwtParams, t = Ra(e || "https://oauth.telegram.org/auth"), n = JSON.parse(JSON.stringify(this.params.jwtParams || {}));
            n.origin = `${this.params.redirect_uri}?state=${this.state}&nonce=${this.nonce}`;
            const a = lr({
                state: this.state,
                response_type: this.RESPONSE_TYPE,
                bot_id: this.params.clientId,
                prompt: this.PROMPT,
                redirect_uri: `${this.params.redirect_uri}?state=${this.state}&nonce=${this.nonce}`,
                scope: this.SCOPE,
                nonce: this.nonce
            }, n);
            Object.keys(a).forEach((i)=>{
                const s = i;
                a[s] && t.searchParams.append(s, a[s]);
            }), this.finalURL = t;
        }
        async getUserInfo(e) {
            const { idToken: t } = e, n = xu(t), { photo_url: a = "", first_name: i = "", last_name: s = "", id: o } = n;
            return {
                email: "",
                name: `${i} ${s}`,
                profileImage: a,
                authConnectionId: this.params.authConnectionId,
                userId: o.toString(),
                authConnection: this.params.authConnection,
                groupedAuthConnectionId: this.params.groupedAuthConnectionId
            };
        }
        async handleLoginWindow(e) {
            const t = new Ba({
                url: this.finalURL,
                features: e.popupFeatures,
                timeout: Ta(this.params.authConnection)
            });
            if (this.params.uxMode === Zt.REDIRECT) t.redirect(e.locationReplaceOnRedirect);
            else return new Promise((n, a)=>{
                const i = async (o)=>{
                    try {
                        const f = JSON.parse(o) || {}, { event: c, origin: h, result: g } = f, v = sa(f, u2), E = new URL(h).searchParams.get("state");
                        c && c === "auth_result" && n(Be(Be({
                            accessToken: ""
                        }, v), {}, {
                            idToken: kr.encode(JSON.stringify(g)) || "",
                            state: kr.decode(E)
                        }));
                    } catch (f) {
                        Ct.error(f), a(f);
                    }
                }, s = async (o)=>{
                    if (!o.data) throw new Error("Invalid data received");
                    if (this.finalURL.origin !== o.origin) throw new Error("Invalid origin received");
                    const f = o.data;
                    if (typeof f != "string") throw new Error("Invalid data type received");
                    const { event: c } = JSON.parse(f) || {};
                    c && c !== "auth_result" && Ct.info("Invalid event received"), window.removeEventListener("message", s), i(f), t.close();
                };
                window.addEventListener("message", s);
                try {
                    t.open();
                } catch (o) {
                    Ct.error(o), a(o);
                    return;
                }
                t.once("close", ()=>{
                    a(new Error("user closed popup"));
                });
            });
            return null;
        }
    }
    class h2 extends Gr {
        constructor(e){
            super(e), he(this, "RESPONSE_TYPE", "token"), he(this, "SCOPE", "user:read:email"), this.setFinalUrl();
        }
        setFinalUrl() {
            const e = new URL("https://id.twitch.tv/oauth2/authorize"), t = JSON.parse(JSON.stringify(this.params.jwtParams || {})), n = lr({
                state: this.state,
                response_type: this.RESPONSE_TYPE,
                client_id: this.params.clientId,
                redirect_uri: this.params.redirect_uri,
                scope: this.SCOPE,
                force_verify: "true"
            }, t);
            Object.keys(n).forEach((a)=>{
                const i = a;
                n[i] && e.searchParams.append(i, n[i]);
            }), this.finalURL = e;
        }
        async getUserInfo(e) {
            const { accessToken: t } = e, n = await Vr("https://api.twitch.tv/helix/users", {
                headers: {
                    Authorization: `Bearer ${t}`,
                    "Client-ID": this.params.clientId
                }
            }), [{ profile_image_url: a = "", display_name: i = "", email: s = "", id: o }] = n.data || [];
            return {
                profileImage: a,
                name: i,
                email: s,
                userId: o,
                authConnectionId: this.params.authConnectionId,
                authConnection: this.params.authConnection,
                groupedAuthConnectionId: this.params.groupedAuthConnectionId
            };
        }
    }
    const Tu = {
        link: "link",
        code: "code"
    };
    class b2 extends Gr {
        constructor(e){
            super(e), he(this, "SCOPE", "openid profile email"), he(this, "RESPONSE_TYPE", "token id_token"), he(this, "PROMPT", "login"), this.setFinalUrl();
        }
        setFinalUrl() {
            const { domain: e } = this.params.jwtParams || {}, t = Ra(e || "https://passwordless.web3auth.io/v7");
            t.pathname += t.pathname.endsWith("/") ? "authorize" : "/authorize";
            const n = JSON.parse(JSON.stringify(this.params.jwtParams || {}));
            delete n.domain, this.params.customState = Be(Be({}, this.params.customState || {}), {}, {
                client: this.params.web3AuthClientId
            });
            const a = lr({
                state: this.state,
                client_id: this.params.clientId || this.params.web3AuthClientId,
                redirect_uri: this.params.redirect_uri,
                nonce: this.nonce,
                network: this.params.web3AuthNetwork,
                connection: mf[this.params.authConnection],
                scope: this.SCOPE,
                response_type: this.RESPONSE_TYPE,
                prompt: this.PROMPT,
                flow_type: n?.flow_type || Tu.code
            }, n);
            Object.keys(a).forEach((i)=>{
                const s = i;
                a[s] && t.searchParams.append(s, a[s]);
            }), this.finalURL = t;
        }
        async getUserInfo(e) {
            const { idToken: t } = e, n = Pa(t).payload, { name: a, email: i, picture: s } = n;
            return {
                profileImage: s,
                name: a,
                email: i,
                userId: a.toLowerCase(),
                authConnectionId: this.params.authConnectionId,
                authConnection: this.params.authConnection,
                groupedAuthConnectionId: this.params.groupedAuthConnectionId
            };
        }
    }
    const Pu = (r)=>{
        const { authConnectionId: e, authConnection: t, clientId: n, jwtParams: a } = r;
        if (!e || !t || !n) throw new Error("Invalid params. Missing authConnectionId, authConnection or clientId");
        const { domain: i, login_hint: s, id_token: o, access_token: f } = a || {};
        switch(t){
            case ot.GOOGLE:
                return new D1(r);
            case ot.TELEGRAM:
                return new l2(r);
            case ot.FACEBOOK:
                return new q1(r);
            case ot.TWITCH:
                return new h2(r);
            case ot.DISCORD:
                return new U1(r);
            case ot.EMAIL_PASSWORDLESS:
            case ot.SMS_PASSWORDLESS:
                if (!s) throw new Error("Invalid params. Missing login_hint for web3auth passwordless login");
                return new b2(r);
            case ot.APPLE:
            case ot.GITHUB:
            case ot.LINKEDIN:
            case ot.TWITTER:
            case ot.LINE:
            case ot.CUSTOM:
            case ot.REDDIT:
            case ot.WECHAT:
            case ot.KAKAO:
            case ot.FARCASTER:
            case ot.AUTHENTICATOR:
                if (o || f) return new $1(r);
                if (!i) throw new Error("Invalid params for jwt login. Missing domain");
                return new F1(r);
            case ot.PASSKEYS:
                return new d2(r);
            default:
                throw new Error("Unsupported login type");
        }
    }, Rt = {
        MAINNET: "mainnet",
        TESTNET: "testnet",
        CYAN: "cyan",
        AQUA: "aqua",
        CELESTE: "celeste"
    }, Qt = {
        SAPPHIRE_DEVNET: "sapphire_devnet",
        SAPPHIRE_MAINNET: "sapphire_mainnet"
    };
    Rt.MAINNET + "", Rt.TESTNET + "", Rt.CYAN + "", Rt.AQUA + "", Rt.CELESTE + "";
    const p2 = [], rr = {
        [Rt.AQUA]: {
            migrationCompleted: !0,
            networkIdentifier: "aqua",
            networkMigratedTo: Qt.SAPPHIRE_MAINNET
        },
        [Rt.CELESTE]: {
            migrationCompleted: !0,
            networkIdentifier: "celeste",
            networkMigratedTo: Qt.SAPPHIRE_MAINNET
        },
        [Rt.CYAN]: {
            migrationCompleted: !0,
            networkIdentifier: "cyan",
            networkMigratedTo: Qt.SAPPHIRE_MAINNET
        },
        [Rt.MAINNET]: {
            migrationCompleted: !0,
            networkIdentifier: "mainnet",
            networkMigratedTo: Qt.SAPPHIRE_MAINNET
        },
        [Rt.TESTNET]: {
            migrationCompleted: !0,
            networkIdentifier: "teal",
            networkMigratedTo: Qt.SAPPHIRE_DEVNET
        }
    };
    Rt.MAINNET + "", Rt.TESTNET + "", Rt.CYAN + "", Rt.AQUA + "", Rt.CELESTE + "";
    const g2 = {
        [Qt.SAPPHIRE_MAINNET]: "https://api.web3auth.io/signer-service",
        [Qt.SAPPHIRE_DEVNET]: "https://api.web3auth.io/signer-service",
        [Rt.MAINNET]: "https://api.web3auth.io/signer-service",
        [Rt.TESTNET]: "https://api.web3auth.io/signer-service",
        [Rt.CYAN]: "https://api.web3auth.io/signer-polygon-service",
        [Rt.AQUA]: "https://api.web3auth.io/signer-polygon-service",
        [Rt.CELESTE]: "https://api.web3auth.io/signer-polygon-service"
    }, Bu = {
        [Rt.MAINNET]: "https://api.web3auth.io/metadata-service",
        [Rt.TESTNET]: "https://api.web3auth.io/metadata-service",
        [Rt.CYAN]: "https://api.web3auth.io/metadata-service",
        [Rt.AQUA]: "https://api.web3auth.io/metadata-service",
        [Rt.CELESTE]: "https://api.web3auth.io/metadata-service"
    }, y2 = "https://api.web3auth.io/fnd-service", Mf = "https://api.web3auth.io/session-service", Ou = "https://session.web3auth.io", xt = {
        SECP256K1: "secp256k1",
        ED25519: "ed25519"
    }, Gi = {
        ECDSA_SECP256K1: "ecdsa-secp256k1",
        ED25519: "ed25519",
        BIP340: "bip340"
    }, Rf = {
        [Qt.SAPPHIRE_DEVNET]: [
            "https://node-1.dev-node.web3auth.io",
            "https://node-2.dev-node.web3auth.io",
            "https://node-3.dev-node.web3auth.io",
            "https://node-4.dev-node.web3auth.io",
            "https://node-5.dev-node.web3auth.io"
        ],
        [Qt.SAPPHIRE_MAINNET]: [
            "https://node-1.node.web3auth.io",
            "https://node-2.node.web3auth.io",
            "https://node-3.node.web3auth.io",
            "https://node-4.node.web3auth.io",
            "https://node-5.node.web3auth.io"
        ]
    }, xd = (r, e)=>{
        const t = Rf[r];
        if (!t || t.length === 0) throw new Error(`Unsupported network: ${r}`);
        const n = rr[e];
        return t.map((a)=>n && n.networkIdentifier ? `${a}/sss/${n.networkIdentifier}/jrpc` : `${a}/sss/jrpc`);
    }, v2 = (r, e)=>{
        const t = Rf[r];
        if (!t || t.length === 0) throw new Error(`Unsupported network: ${r}`);
        const n = rr[e];
        return t.map((a)=>n && n.networkIdentifier ? `${a}/rss/${n.networkIdentifier}` : `${a}/rss`);
    }, m2 = (r, e, t = xt.SECP256K1, n)=>{
        const a = Rf[r];
        if (!a || a.length === 0) throw new Error(`Unsupported network: ${r}`);
        const i = (()=>{
            const f = "tss-frost";
            if (n) {
                if (n === Gi.ECDSA_SECP256K1) {
                    if (t !== xt.SECP256K1) throw new Error("Invalid key type for ecdsa-secp256k1");
                    return "tss";
                } else if (n === Gi.ED25519) {
                    if (t !== xt.ED25519) throw new Error("Invalid key type for ed25519");
                    return f;
                } else if (n === Gi.BIP340) {
                    if (t !== xt.SECP256K1) throw new Error("Invalid key type for bip340");
                    return f;
                }
                throw new Error("Invalid sig type");
            } else {
                if (t === xt.SECP256K1) return "tss";
                if (t === xt.ED25519) return f;
            }
            throw new Error("Invalid key type");
        })(), s = rr[e];
        return a.map((o)=>s && s.networkIdentifier ? `${o}/${i}/${s.networkIdentifier}` : `${o}/${i}`);
    }, w2 = {
        [Qt.SAPPHIRE_MAINNET]: [
            {
                X: "e0925898fee0e9e941fdca7ee88deec99939ae9407e923535c4d4a3a3ff8b052",
                Y: "54b9fea924e3f3e40791f9987f4234ae4222412d65b74068032fa5d8b63375c1"
            },
            {
                X: "9124cf1e280aab32ba50dffd2de81cecabc13d82d2c1fe9de82f3b3523f9b637",
                Y: "fca939a1ceb42ce745c55b21ef094f543b457630cb63a94ef4f1afeee2b1f107"
            },
            {
                X: "555f681a63d469cc6c3a58a97e29ebd277425f0e6159708e7c7bf05f18f89476",
                Y: "606f2bcc0884fa5b64366fc3e8362e4939841b56acd60d5f4553cf36b891ac4e"
            },
            {
                X: "2b5f58d8e340f1ab922e89b3a69a68930edfe51364644a456335e179bc130128",
                Y: "4b4daa05939426e3cbe7d08f0e773d2bf36f64c00d04620ee6df2a7af4d2247"
            },
            {
                X: "3ecbb6a68afe72cf34ec6c0a12b5cb78a0d2e83ba402983b6adbc5f36219861a",
                Y: "dc1031c5cc8f0472bd521a62a64ebca9e163902c247bf05937daf4ae835091e4"
            }
        ],
        [Qt.SAPPHIRE_DEVNET]: [
            {
                X: "f74389b0a4c8d10d2a687ae575f69b20f412d41ab7f1fe6b358aa14871327247",
                Y: "54e3a73098ed9bced3ef8821736e9794f9264a1420c0c7ad15d2fa617ba35ef7"
            },
            {
                X: "bc38813a6873e526087918507c78fc3a61624670ee851ecfb4f3bef55d027b5a",
                Y: "ac4b21229f662a0aefdfdac21cf17c3261a392c74a8790db218b34e3e4c1d56a"
            },
            {
                X: "b56541684ea5fa40c8337b7688d502f0e9e092098962ad344c34e94f06d293fb",
                Y: "759a998cef79d389082f9a75061a29190eec0cac99b8c25ddcf6b58569dad55c"
            },
            {
                X: "7bcb058d4c6ffc6ba4bfdfd93d141af35a66338a62c7c27cdad2ae3f8289b767",
                Y: "336ab1935e41ed4719e162587f0ab55518db4207a1eb36cc72303f1b86689d2b"
            },
            {
                X: "bf12a136ef94399ea098f926f04e26a4ec4ac70f69cce274e8893704c4951773",
                Y: "bdd44828020f52ce510e026338216ada184a6867eb4e19fb4c2d495d4a7e15e4"
            }
        ]
    }, _d = (r, e, t, n)=>({
            currentEpoch: "1",
            torusNodeEndpoints: xd(r, e),
            torusNodeSSSEndpoints: xd(r, e),
            torusNodeRSSEndpoints: v2(r, e),
            torusNodeTSSEndpoints: m2(r, e, t, n),
            torusIndexes: [
                1,
                2,
                3,
                4,
                5
            ],
            torusNodePub: w2[r]
        });
    function x2(r, e, t) {
        if (Object.values(Qt).includes(r)) return _d(r, void 0, e, t);
        if (Object.values(Rt).includes(r)) {
            const n = rr[r];
            if (n.migrationCompleted) return _d(n.networkMigratedTo, r, e);
        }
    }
    const Ni = vr.getLogger("fnd");
    class _2 {
        constructor({ network: e = Qt.SAPPHIRE_MAINNET, keyType: t = xt.SECP256K1, sigType: n = Gi.ECDSA_SECP256K1, fndServerEndpoint: a, enableLogging: i = !1 } = {}){
            if (he(this, "fndServerEndpoint", `${y2}/node-details`), he(this, "_currentEpoch", "1"), he(this, "_keyType", void 0), he(this, "_sigType", void 0), he(this, "_torusNodeEndpoints", []), he(this, "_torusNodeRSSEndpoints", []), he(this, "_torusNodeSSSEndpoints", []), he(this, "_torusNodeTSSEndpoints", []), he(this, "_torusNodePub", []), he(this, "_torusIndexes", []), he(this, "updated", void 0), he(this, "network", void 0), e && !Object.values(Be(Be({}, Rt), Qt)).includes(e)) throw new Error("Invalid network");
            this.network = e, this._keyType = t, this._sigType = n, this.updated = !1, a && (this.fndServerEndpoint = a), i ? Ni.enableAll() : Ni.disableAll();
        }
        get _nodeDetails() {
            return {
                currentEpoch: this._currentEpoch,
                torusNodeEndpoints: this._torusNodeEndpoints,
                torusNodeSSSEndpoints: this._torusNodeSSSEndpoints,
                torusNodeRSSEndpoints: this._torusNodeRSSEndpoints,
                torusNodeTSSEndpoints: this._torusNodeTSSEndpoints,
                torusNodePub: this._torusNodePub,
                torusIndexes: this._torusIndexes,
                updated: this.updated
            };
        }
        async getNodeDetails({ verifier: e, verifierId: t }) {
            try {
                if (this.updated && !p2.includes(this.network)) return this._nodeDetails;
                try {
                    const { nodeDetails: a } = await Vr(`${this.fndServerEndpoint}?network=${this.network}&verifier=${e}&verifierId=${t}&keyType=${this._keyType}&sigType=${this._sigType}`);
                    return this.setNodeDetails(a), this._nodeDetails;
                } catch (a) {
                    Ni.error("Failed to fetch node details from server, using local.", a);
                }
                const n = x2(this.network, this._keyType, this._sigType);
                if (!n) throw new Error("Failed to fetch node details");
                return this.setNodeDetails(n), this._nodeDetails;
            } catch (n) {
                throw Ni.error("Failed to fetch node details", n), n;
            }
        }
        async getMetadataUrl() {
            return Object.values(Rt).includes(this.network) ? Bu[this.network] : (await this.getNodeDetails({
                verifier: "test-verifier",
                verifierId: "test-verifier-id"
            })).torusNodeEndpoints[0].replace("/sss/jrpc", "/metadata");
        }
        setNodeDetails(e) {
            const { currentEpoch: t, torusNodeEndpoints: n, torusNodeSSSEndpoints: a, torusNodeRSSEndpoints: i, torusNodeTSSEndpoints: s, torusNodePub: o, torusIndexes: f } = e;
            this._torusNodeEndpoints = n, this._torusNodeSSSEndpoints = a || [], this._torusNodeRSSEndpoints = i || [], this._torusNodeTSSEndpoints = s || [], this._torusNodePub = o, this._torusIndexes = f, this._currentEpoch = t, this.updated = !0;
        }
    }
    const An = {
        GET_OR_SET_KEY: "GetPubKeyOrKeyAssign",
        VERIFIER_LOOKUP: "VerifierLookupRequest",
        COMMITMENT_REQUEST: "CommitmentRequest",
        IMPORT_SHARES: "ImportShares",
        GET_SHARE_OR_KEY_ASSIGN: "GetShareOrKeyAssign"
    }, S2 = "https://node-1.node.web3auth.io/metadata", E2 = "https://node-1.dev-node.web3auth.io/metadata";
    class Tf {
        constructor(e, t){
            he(this, "share", void 0), he(this, "shareIndex", void 0), this.share = new Fe(t, "hex"), this.shareIndex = new Fe(e, "hex");
        }
        static fromJSON(e) {
            const { share: t, shareIndex: n } = e;
            return new Tf(n, t);
        }
        toJSON() {
            return {
                share: this.share.toString("hex", 64),
                shareIndex: this.shareIndex.toString("hex", 64)
            };
        }
    }
    class A2 {
        constructor(e, t){
            he(this, "polynomial", void 0), he(this, "ecCurve", void 0), this.polynomial = e, this.ecCurve = t;
        }
        getThreshold() {
            return this.polynomial.length;
        }
        polyEval(e) {
            const t = new Fe(e, "hex");
            let n = new Fe(t), a = new Fe(0);
            a = a.add(this.polynomial[0]);
            for(let i = 1; i < this.polynomial.length; i += 1){
                const s = n.mul(this.polynomial[i]);
                a = a.add(s), a = a.umod(this.ecCurve.n), n = n.mul(new Fe(t)), n = n.umod(this.ecCurve.n);
            }
            return a;
        }
        generateShares(e) {
            const t = e.map((a)=>typeof a == "number" ? new Fe(a) : a instanceof Fe ? a : typeof a == "string" ? new Fe(a, "hex") : a), n = {};
            for(let a = 0; a < t.length; a += 1)n[t[a].toString("hex", 64)] = new Tf(t[a], this.polyEval(t[a]));
            return n;
        }
    }
    const Dn = {
        logRequestTracing: !1
    }, Tr = vr.getLogger("torus.js");
    Tr.disableAll();
    class Us extends Error {
    }
    async function I2(r) {
        return U0(r);
    }
    function M2(r) {
        return r.charAt(0).toUpperCase() + r.slice(1);
    }
    class R2 extends Error {
        constructor({ errors: e, responses: t, predicate: n }){
            const a = `Unable to resolve enough promises. 
      errors: ${e.map((i)=>i?.message || i).join(", ")}, 
      predicate error: ${n},
      ${t.length} responses,
      responses: ${JSON.stringify(t)}`;
            super(a), he(this, "errors", void 0), he(this, "responses", void 0), he(this, "predicate", void 0), this.errors = e, this.responses = t, this.predicate = n;
        }
        get message() {
            return `${super.message}. errors: ${this.errors.map((e)=>e?.message || e).join(", ")} and ${this.responses.length} responses: ${JSON.stringify(this.responses)},
      predicate error: ${this.predicate}`;
        }
        toString() {
            return this.message;
        }
    }
    const ka = (r, e)=>new Promise((t, n)=>{
            let a = 0;
            const i = {
                resolved: !1
            }, s = new Array(r.length).fill(void 0), o = new Array(r.length).fill(void 0);
            let f;
            r.forEach((c, h)=>{
                c.then((g)=>{
                    o[h] = g;
                }).catch((g)=>{
                    s[h] = g;
                }).finally(()=>{
                    if (!i.resolved) return e(o.slice(0), i).then((g)=>{
                        i.resolved = !0, t(g);
                    }).catch((g)=>{
                        f = g;
                    }).finally(()=>{
                        if (a += 1, a === r.length) {
                            const v = Object.values(o.reduce((w, E)=>{
                                if (E) {
                                    var x;
                                    const { id: S, error: y } = E;
                                    (y == null || (x = y.data) === null || x === void 0 ? void 0 : x.length) > 0 && (y.data.startsWith("Error occurred while verifying params") ? w[S] = M2(y.data) : w[S] = y.data);
                                }
                                return w;
                            }, {}));
                            if (v.length > 0) {
                                const w = v.length > 1 ? `
${v.map((E)=>`• ${E}`).join(`
`)}` : v[0];
                                n(new Error(w));
                            } else {
                                var g;
                                n(new R2({
                                    errors: s,
                                    responses: o,
                                    predicate: ((g = f) === null || g === void 0 ? void 0 : g.message) || f
                                }));
                            }
                        }
                    });
                });
            });
        });
    function Tn(r) {
        return `0x${Buffer.from(Oa(r)).toString("hex")}`;
    }
    const Pf = (r, e)=>r.genKeyPair().getPrivate().toArrayLike(e);
    let qs, Ds;
    const Er = (r)=>{
        if (r === xt.SECP256K1) return qs || (qs = new un.ec("secp256k1")), qs;
        if (r === xt.ED25519) return Ds || (Ds = new un.ec("ed25519")), Ds;
        throw new Error(`Invalid keyType: ${r}`);
    }, T2 = (r)=>{
        const e = {
            keys: [],
            is_new_key: r.is_new_key
        };
        if (r && r.keys && r.keys.length > 0) {
            const t = r.keys[0];
            e.keys = [
                {
                    pub_key_X: t.pub_key_X,
                    pub_key_Y: t.pub_key_Y,
                    address: t.address
                }
            ];
        }
        return e;
    }, P2 = (r)=>{
        const e = {
            keys: []
        };
        if (r && r.keys && r.keys.length > 0) {
            const t = r.keys[0];
            e.keys = [
                {
                    pub_key_X: t.pub_key_X,
                    pub_key_Y: t.pub_key_Y,
                    address: t.address
                }
            ];
        }
        return e;
    }, ku = (r, e)=>{
        let t = r;
        if (typeof t == "number" && (t = Array.from({
            length: t
        }, (i, s)=>s)), e > t.length || e <= 0) return [];
        if (e === t.length) return [
            t
        ];
        if (e === 1) return t.reduce((i, s)=>[
                ...i,
                [
                    s
                ]
            ], []);
        const n = [];
        let a = [];
        for(let i = 0; i <= t.length - e + 1; i += 1){
            a = ku(t.slice(i + 1), e - 1);
            for(let s = 0; s < a.length; s += 1)n.push([
                t[i],
                ...a[s]
            ]);
        }
        return n;
    }, In = (r, e)=>{
        const t = {};
        for(let n = 0; n < r.length; n += 1){
            const a = Rn(r[n]);
            if (t[a] = t[a] ? t[a] + 1 : 1, t[a] === e) return r[n];
        }
    };
    function Nu(r) {
        return {
            iv: Buffer.from(r.iv).toString("hex"),
            ephemPublicKey: Buffer.from(r.ephemPublicKey).toString("hex"),
            ciphertext: Buffer.from(r.ciphertext).toString("hex"),
            mac: Buffer.from(r.mac).toString("hex"),
            mode: "AES256"
        };
    }
    function Bf(r) {
        return {
            ephemPublicKey: Buffer.from(r.ephemPublicKey, "hex"),
            iv: Buffer.from(r.iv, "hex"),
            mac: Buffer.from(r.mac, "hex")
        };
    }
    function Cu(r, e, t) {
        const n = `${e}${t}`, a = Tn(Buffer.from(n, "utf8")).slice(2);
        return new cc.BN(a, "hex").mod(new cc.BN(r.length)).toNumber();
    }
    function Of(r) {
        const e = r.length;
        if (e === 0) return 0;
        const t = r.sort(function(i, s) {
            return i - s;
        });
        if (e % 2 !== 0) return t[Math.floor(e / 2)];
        const n = t[e / 2 - 1], a = t[e / 2];
        return (n + a) / 2;
    }
    function B2(r) {
        return new Promise((e, t)=>{
            r > 0 ? setTimeout(e, r) : t(new Error("value of milliseconds must be greater than 0"));
        });
    }
    function O2(r, e) {
        async function t(n) {
            try {
                if (n > 0) {
                    const i = 2 ** n * 100;
                    await B2(i);
                }
                return await r();
            } catch (a) {
                const i = a.message, s = [
                    "Timed out",
                    "Failed to fetch",
                    "fetch failed",
                    "Load failed",
                    "cancelled",
                    "NetworkError when attempting to fetch resource.",
                    "TypeError: Failed to fetch",
                    "TypeError: cancelled",
                    "TypeError: NetworkError when attempting to fetch resource."
                ];
                if (n < e && (s.includes(i) || i && i.includes("reason: getaddrinfo EAI_AGAIN"))) return t(n + 1);
                throw a;
            }
        }
        return t(0);
    }
    const k2 = (r)=>{
        if (r.length >= 255) throw new TypeError("Alphabet too long");
        const e = new Uint8Array(256);
        for(let c = 0; c < e.length; c++)e[c] = 255;
        for(let c = 0; c < r.length; c++){
            const h = r.charAt(c), g = h.charCodeAt(0);
            if (e[g] !== 255) throw new TypeError(`${h} is ambiguous`);
            e[g] = c;
        }
        const t = r.length, n = r.charAt(0), a = Math.log(t) / Math.log(256), i = Math.log(256) / Math.log(t);
        function s(c) {
            if (c instanceof Uint8Array || (ArrayBuffer.isView(c) ? c = new Uint8Array(c.buffer, c.byteOffset, c.byteLength) : Array.isArray(c) && (c = Uint8Array.from(c))), !(c instanceof Uint8Array)) throw new TypeError("Expected Uint8Array");
            if (c.length === 0) return "";
            let h = 0, g = 0, v = 0;
            const w = c.length;
            for(; v !== w && c[v] === 0;)v++, h++;
            const E = (w - v) * i + 1 >>> 0, x = new Uint8Array(E);
            for(; v !== w;){
                let A = c[v], P = 0;
                for(let N = E - 1; (A !== 0 || P < g) && N !== -1; N--, P++)A += 256 * x[N] >>> 0, x[N] = A % t >>> 0, A = A / t >>> 0;
                if (A !== 0) throw new Error("Non-zero carry");
                g = P, v++;
            }
            let S = E - g;
            for(; S !== E && x[S] === 0;)S++;
            let y = n.repeat(h);
            for(; S < E; ++S)y += r.charAt(x[S]);
            return y;
        }
        function o(c) {
            if (typeof c != "string") throw new TypeError("Expected String");
            if (c.length === 0) return new Uint8Array;
            let h = 0, g = 0, v = 0;
            for(; c[h] === n;)g++, h++;
            const w = (c.length - h) * a + 1 >>> 0, E = new Uint8Array(w);
            for(; c[h];){
                let A = e[c.charCodeAt(h)];
                if (A === 255) return;
                let P = 0;
                for(let N = w - 1; (A !== 0 || P < v) && N !== -1; N--, P++)A += t * E[N] >>> 0, E[N] = A % 256 >>> 0, A = A / 256 >>> 0;
                if (A !== 0) throw new Error("Non-zero carry");
                v = P, h++;
            }
            let x = w - v;
            for(; x !== w && E[x] === 0;)x++;
            const S = new Uint8Array(g + (w - x));
            let y = g;
            for(; x !== w;)S[y++] = E[x++];
            return S;
        }
        function f(c) {
            const h = o(c);
            if (h) return h;
            throw new Error(`Non-base${t} character`);
        }
        return {
            encode: s,
            decodeUnsafe: o,
            decode: f
        };
    }, N2 = "123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz", C2 = k2(N2), L2 = Ru(Io);
    function $o(r, e) {
        const t = new Fe(Pf(e, Buffer));
        return r.find((n)=>n.eq(t)) ? $o(r, e) : t;
    }
    function U2(r, e, t) {
        if (e.length !== t.length) throw new Error("shares not equal to nodeIndex length in lagrangeInterpolation");
        let n = new Fe(0);
        for(let a = 0; a < e.length; a += 1){
            let i = new Fe(1), s = new Fe(1);
            for(let f = 0; f < e.length; f += 1)if (a !== f) {
                i = i.mul(t[f].neg()), i = i.umod(r.n);
                let c = t[a].sub(t[f]);
                c = c.umod(r.n), s = s.mul(c).umod(r.n);
            }
            let o = i.mul(s.invm(r.n)).umod(r.n);
            o = o.mul(e[a]).umod(r.n), n = n.add(o);
        }
        return n.umod(r.n);
    }
    function q2(r, e, t, n) {
        let a = t;
        t || (a = $o([
            new Fe(0)
        ], r));
        {
            const i = [
                a
            ];
            for(let s = 0; s < e; s += 1){
                const o = $o(i, r);
                i.push(o);
            }
            return new A2(i, r);
        }
    }
    const ca = (r)=>{
        const e = Er(xt.SECP256K1), t = r.toString("hex", 64), n = Oa(Buffer.from(t, "hex")), a = new Fe(n).umod(e.n).toString("hex", 64), i = Buffer.from(a, "hex"), s = e.keyFromPrivate(i);
        if (i.length !== 32) throw new Error(`Key length must be equal to 32. got ${i.length}`);
        return {
            scalar: s.getPrivate(),
            point: s.getPublic()
        };
    };
    async function Sd(r, e, t) {
        const n = Bf(r);
        return await qn(t, Be(Be({}, n), {}, {
            ciphertext: Buffer.from(e, "hex")
        }));
    }
    async function D2(r, e, t) {
        const n = Bf(r);
        try {
            return await qn(t, Be(Be({}, n), {}, {
                ciphertext: Buffer.from(e, "hex")
            }));
        } catch (a) {
            const i = e.padStart(64, "0");
            return vr.warn("Failed to decrypt padded share cipher", a), qn(t, Be(Be({}, n), {}, {
                ciphertext: Buffer.from(i, "hex")
            }));
        }
    }
    function F2(r, e, t, n) {
        const a = r.keyFromPrivate(n.toString("hex", 64), "hex"), i = {
            data: t,
            timestamp: new Fe(~~(e + Date.now() / 1e3)).toString(16)
        }, s = a.sign(Tn(Buffer.from(Rn(i), "utf8")).slice(2));
        return {
            pub_key_X: a.getPublic().getX().toString("hex"),
            pub_key_Y: a.getPublic().getY().toString("hex"),
            set_data: i,
            signature: Buffer.from(s.r.toString(16, 64) + s.s.toString(16, 64) + new Fe("").toString(16, 2), "hex").toString("base64")
        };
    }
    async function da(r, e, t = {}) {
        try {
            const n = await cr(`${r}/get`, e, t, {
                useAPIKey: !0
            });
            return !n || !n.message ? new Fe(0) : new Fe(n.message, 16);
        } catch (n) {
            return vr.error("get metadata error", n), new Fe(0);
        }
    }
    function Lu(r, e, t, n, a, i) {
        const s = Er(xt.SECP256K1).keyFromPrivate(t.toString("hex", 64), "hex"), o = {
            operation: e,
            timestamp: new Fe(~~(r + Date.now() / 1e3)).toString(16)
        };
        a && (o.data = a.toString("hex", 64)), i ? o.seed = i : o.seed = "";
        const f = s.sign(Tn(Buffer.from(Rn(o), "utf8")).slice(2));
        return {
            pub_key_X: s.getPublic().getX().toString("hex", 64),
            pub_key_Y: s.getPublic().getY().toString("hex", 64),
            set_data: o,
            key_type: n,
            signature: Buffer.from(f.r.toString(16, 64) + f.s.toString(16, 64) + new Fe("").toString(16, 2), "hex").toString("base64")
        };
    }
    async function Uu(r, e, t, n, a, i, s = !1, o = !0, f = new Fe(0), c = "secp256k1", h = "") {
        if (o) {
            let w;
            const E = s ? "getNonce" : "getOrSetNonce";
            return i ? w = F2(e, t, E, i) : w = {
                pub_key_X: n,
                pub_key_Y: a,
                set_data: {
                    data: E
                }
            }, cr(`${r}/get_or_set_nonce`, w, void 0, {
                useAPIKey: !0
            });
        }
        const g = s ? "getNonce" : "getOrSetNonce";
        if (g === "getOrSetNonce") {
            if (!i) throw new Error("privKey is required while `getOrSetNonce` for non legacy metadata");
            if (f.cmp(new Fe(0)) === 0) throw new Error("nonce is required while `getOrSetNonce` for non legacy metadata");
            if (c === xt.ED25519 && !h) throw new Error("seed is required while `getOrSetNonce` for non legacy metadata for ed25519 key type");
            const w = Lu(t, g, i, c, f, h);
            return cr(`${r}/get_or_set_nonce`, w, void 0, {
                useAPIKey: !0
            });
        }
        const v = {
            pub_key_X: n,
            pub_key_Y: a,
            set_data: {
                operation: g
            },
            key_type: c
        };
        return cr(`${r}/get_or_set_nonce`, v, void 0, {
            useAPIKey: !0
        });
    }
    const $2 = async (r, e)=>{
        const t = ca(e), n = Buffer.from(r, "base64").toString("utf-8"), a = JSON.parse(n), i = Be(Be({}, Bf(a.metadata)), {}, {
            mode: "AES256"
        }), s = t.scalar.toArrayLike(Buffer, "be", 32);
        return await qn(s, Be(Be({}, i), {}, {
            ciphertext: Buffer.from(a.enc_text, "hex")
        }));
    };
    async function qu(r, e, t, n, a) {
        if (rr[r]) throw new Error("getOrSetSapphireMetadataNonce should only be used for sapphire networks");
        let i = {
            pub_key_X: e,
            pub_key_Y: t,
            key_type: "secp256k1",
            set_data: {
                operation: "getOrSetNonce"
            }
        };
        if (a) {
            const o = Er(xt.SECP256K1).keyFromPrivate(a.toString("hex", 64), "hex"), f = {
                operation: "getOrSetNonce",
                timestamp: new Fe(~~(n + Date.now() / 1e3)).toString(16)
            }, c = o.sign(Tn(Buffer.from(Rn(f), "utf8")).slice(2));
            i = Be(Be({}, i), {}, {
                set_data: f,
                signature: Buffer.from(c.r.toString(16, 64) + c.s.toString(16, 64) + new Fe("").toString(16, 2), "hex").toString("base64")
            });
        }
        const s = r === Qt.SAPPHIRE_DEVNET ? E2 : S2;
        return cr(`${s}/get_or_set_nonce`, i, void 0, {
            useAPIKey: !0
        });
    }
    function K2(r) {
        return r.startsWith("0x") ? r.slice(2) : r;
    }
    function j2(r) {
        const e = K2(r).toLowerCase(), t = Buffer.from(e, "utf8"), n = Buffer.from(Oa(t)).toString("hex");
        let a = "0x";
        for(let i = 0; i < e.length; i++)parseInt(n[i], 16) >= 8 ? a += e[i].toUpperCase() : a += e[i];
        return a;
    }
    function H2(r) {
        return r[0] &= 248, r[31] &= 127, r[31] |= 64, r;
    }
    function Du(r) {
        const e = Er(xt.ED25519), t = 32, n = e.g, a = e.n;
        if (r.length !== 32) throw vr.error("Invalid seed for ed25519 key derivation", r.length), new Error("Invalid seed for ed25519 key derivation");
        const i = L2(r);
        if (i.length !== 64) throw new Error("Invalid hash length for ed25519 seed");
        const s = new Fe(H2(Buffer.from(i.slice(0, t))), "le"), o = new Fe(s.umod(a), "le"), f = n.mul(o);
        return {
            scalar: o,
            point: f
        };
    }
    function ua(r) {
        const e = Er(xt.ED25519), t = Math.ceil(e.n.bitLength() / 8), n = r.getY().toArrayLike(Buffer, "le", t);
        return n[t - 1] |= r.getX().isOdd() ? 128 : 0, n;
    }
    const z2 = async (r)=>{
        const e = Er(xt.ED25519), t = Du(r), n = ca(t.scalar), a = await Af(Buffer.from(n.point.encodeCompressed("hex"), "hex"), r), i = {
            enc_text: a.ciphertext.toString("hex"),
            metadata: Nu(a),
            public_key: ua(t.point).toString("hex")
        }, s = Buffer.from(JSON.stringify(i), "utf-8").toString("base64"), o = e.genKeyPair().getPrivate(), f = t.scalar.sub(o).umod(e.n), c = e.keyFromPrivate(f.toArrayLike(Buffer)), h = ca(c.getPrivate());
        return {
            oAuthKeyScalar: c.getPrivate(),
            oAuthPubX: c.getPublic().getX(),
            oAuthPubY: c.getPublic().getY(),
            SigningPubX: h.point.getX(),
            SigningPubY: h.point.getY(),
            metadataNonce: o,
            metadataSigningKey: h.scalar,
            encryptedSeed: s,
            finalUserPubKeyPoint: t.point
        };
    }, W2 = async (r)=>{
        const e = Er(xt.SECP256K1), t = new Fe(r), n = new Fe(Pf(e, Buffer)), a = t.sub(n).umod(e.n), i = e.keyFromPrivate(a.toArrayLike(Buffer)), s = i.getPublic(), o = e.keyFromPrivate(t.toString("hex", 64), "hex");
        return {
            oAuthKeyScalar: i.getPrivate(),
            oAuthPubX: s.getX(),
            oAuthPubY: s.getY(),
            SigningPubX: s.getX(),
            SigningPubY: s.getY(),
            metadataNonce: n,
            encryptedSeed: "",
            metadataSigningKey: i.getPrivate(),
            finalUserPubKeyPoint: o.getPublic()
        };
    };
    function Fu(r, e) {
        if (r === xt.SECP256K1) {
            const t = e.getPublic().encode("hex", !1).slice(2), n = `0x${Tn(Buffer.from(t, "hex")).slice(26)}`;
            return j2(n);
        } else if (r === xt.ED25519) {
            const t = ua(e.getPublic());
            return C2.encode(t);
        }
        throw new Error(`Invalid keyType: ${r}`);
    }
    function Y2(r, e) {
        const n = Er(r).keyFromPrivate(e.toString("hex", 64), "hex");
        return Fu(r, n);
    }
    function ti(r, e, t) {
        const a = Er(r).keyFromPublic({
            x: e.toString("hex", 64),
            y: t.toString("hex", 64)
        });
        return Fu(r, a);
    }
    function Ed(r, e) {
        const t = e.toString(16, 64);
        return r.keyFromPrivate(t, "hex").getPublic();
    }
    const V2 = ()=>new un.ec("secp256k1"), $u = async (r, e, t, n, a, i)=>{
        const s = e === xt.ED25519 ? await z2(i) : await W2(i), { metadataNonce: o, oAuthKeyScalar: f, encryptedSeed: c, metadataSigningKey: h } = s, v = ~~(a.length / 2) + 1 - 1, w = [];
        for (const D of n)w.push(new Fe(D));
        const E = r.keyFromPrivate(f.toString("hex", 64), "hex").getPublic(), S = q2(r, v, f).generateShares(w), y = Lu(t, "getOrSetNonce", h, e, o, c), A = Buffer.from(Rn(y.set_data), "utf8").toString("base64"), P = [], N = [];
        for(let D = 0; D < w.length; D++){
            const V = S[w[D].toString("hex", 64)].toJSON();
            if (!a[D]) throw new Error(`Missing node pub key for node index: ${w[D].toString("hex", 64)}`);
            const K = V2().keyFromPublic({
                x: a[D].X,
                y: a[D].Y
            });
            N.push(Af(Buffer.from(K.getPublic().encodeCompressed("hex"), "hex"), Buffer.from(V.share.padStart(64, "0"), "hex")));
        }
        const k = await Promise.all(N);
        for(let D = 0; D < w.length; D += 1){
            const V = S[w[D].toString("hex", 64)].toJSON(), K = k[D], j = Nu(K), H = {
                encrypted_seed: s.encryptedSeed,
                final_user_point: s.finalUserPubKeyPoint,
                oauth_pub_key_x: E.getX().toString("hex"),
                oauth_pub_key_y: E.getY().toString("hex"),
                signing_pub_key_x: s.SigningPubX.toString("hex"),
                signing_pub_key_y: s.SigningPubY.toString("hex"),
                encrypted_share: j.ciphertext,
                encrypted_share_metadata: j,
                node_index: Number.parseInt(V.shareIndex, 16),
                key_type: e,
                nonce_data: A,
                nonce_signature: y.signature
            };
            P.push(H);
        }
        return P;
    }, G2 = async (r)=>{
        const { endpoints: e, network: t, verifier: n, verifierId: a, extendedVerifierId: i, keyType: s } = r, o = ~~(e.length / 2) + 1, f = e.map((v)=>cr(v, li(An.GET_OR_SET_KEY, {
                distributed_metadata: !0,
                verifier: n,
                verifier_id: a.toString(),
                extended_verifier_id: i,
                one_key_flow: !0,
                key_type: s,
                fetch_node_index: !0,
                client_time: Math.floor(Date.now() / 1e3).toString()
            }), {}, {
                logTracingHeader: Dn.logRequestTracing
            }).catch((w)=>Tr.error(`${An.GET_OR_SET_KEY} request failed`, w)));
        let c;
        const h = [];
        return await ka(f, async (v)=>{
            const w = v.filter((A)=>A && !A.error ? A : !1), E = In(v.map((A)=>A && A.error), o), x = In(w.map((A)=>A && T2(A.result)), o);
            if (x && !c && !i && !rr[t]) {
                for(let A = 0; A < v.length; A++){
                    const P = v[A];
                    if (P && !P.error) {
                        var S;
                        const N = P.result.keys[0].pub_key_X.toLowerCase(), k = x.keys[0].pub_key_X.toLowerCase();
                        if (((S = P.result) === null || S === void 0 || (S = S.keys[0].nonce_data) === null || S === void 0 || (S = S.pubNonce) === null || S === void 0 ? void 0 : S.x) && N === k) {
                            c = P.result.keys[0].nonce_data;
                            break;
                        }
                    }
                }
                if (!c) {
                    const A = await qu(t, x.keys[0].pub_key_X, x.keys[0].pub_key_Y);
                    !c && A && (c = A, c.nonce && delete c.nonce);
                }
            }
            const y = [];
            if (x && (c || i || rr[t]) || E) {
                x && v.forEach((P)=>{
                    if (P && P.result) {
                        const N = P.result.keys[0].pub_key_X.toLowerCase(), k = x.keys[0].pub_key_X.toLowerCase();
                        if (N === k) {
                            const V = Number.parseInt(P.result.node_index);
                            V && h.push(V);
                        }
                        const D = P.result.server_time_offset ? Number.parseInt(P.result.server_time_offset, 10) : 0;
                        y.push(D);
                    }
                });
                const A = x ? Of(y) : 0;
                return Promise.resolve({
                    keyResult: x,
                    serverTimeOffset: A,
                    nodeIndexes: h,
                    errorResult: E,
                    nonceResult: c
                });
            }
            return Promise.reject(new Error(`invalid public key result: ${JSON.stringify(v)} and nonce result:${JSON.stringify(c || {})} for verifier: ${n}, verifierId: ${a} and extendedVerifierId: ${i} `));
        });
    }, J2 = async (r)=>{
        const { endpoints: e, verifier: t, verifierId: n, keyType: a } = r, i = ~~(e.length / 2) + 1, s = e.map((f)=>cr(f, li(An.VERIFIER_LOOKUP, {
                verifier: t,
                verifier_id: n.toString(),
                key_type: a,
                client_time: Math.floor(Date.now() / 1e3).toString()
            }), {}, {
                logTracingHeader: Dn.logRequestTracing
            }).catch((c)=>Tr.error(`${An.GET_OR_SET_KEY} request failed`, c)));
        return await ka(s, async (f)=>{
            const c = f.filter((w)=>w && !w.error ? w : !1), h = In(f.map((w)=>w && w.error), i), g = In(c.map((w)=>w && P2(w.result)), i), v = [];
            if (g || h) {
                const w = g ? Of(v) : 0;
                return Promise.resolve({
                    keyResult: g,
                    serverTimeOffset: w,
                    errorResult: h
                });
            }
            return Promise.reject(new Error(`invalid lookup result: ${JSON.stringify(f)}
        )} for verifier: ${t}, verifierId: ${n}`));
        });
    }, X2 = async (r)=>{
        const { idToken: e, endpoints: t, indexes: n, keyType: a, verifier: i, verifierParams: s, pubKeyX: o, pubKeyY: f, finalImportedShares: c, overrideExistingKey: h } = r, g = Tn(Buffer.from(e, "utf8")), v = ~~(t.length * 3 / 4) + 1, w = ~~(t.length / 2) + 1, E = [];
        for(let x = 0; x < t.length; x += 1){
            const y = O2(()=>cr(t[x], li(An.COMMITMENT_REQUEST, {
                    messageprefix: "mug00",
                    keytype: a,
                    tokencommitment: g.slice(2),
                    temppubx: o,
                    temppuby: f,
                    verifieridentifier: i,
                    verifier_id: s.verifier_id,
                    extended_verifier_id: s.extended_verifier_id,
                    is_import_key_flow: !0
                }), {}, {
                    logTracingHeader: Dn.logRequestTracing
                }), 4);
            E.push(y);
        }
        return new Promise((x, S)=>{
            ka(E, (y)=>{
                const A = y.filter((P)=>!(!P || typeof P != "object" || P.error));
                if (c.length > 0) {
                    if (h && A.length === t.length) {
                        if (A.find((N)=>!!N)) return Promise.resolve(y);
                    } else if (!h && A.length >= v) {
                        const P = [];
                        for(let V = 0; V < A.length; V += 1){
                            const K = A[V];
                            !K || typeof K != "object" || K.error || K && P.push(K.result);
                        }
                        const N = In(P.map((V)=>V && V.pub_key_x), w), k = Cu(t, i, s.verifier_id), D = n[k].toString(10);
                        if ((N || !N && A.length === t.length) && A.find((K)=>{
                            var j;
                            return !!(K && ((j = K.result) === null || j === void 0 ? void 0 : j.nodeindex) === D);
                        })) return Promise.resolve(y);
                    }
                } else if (A.length >= v && A.find((N)=>!!N)) return Promise.resolve(y);
                return Promise.reject(new Error(`invalid commitment results ${JSON.stringify(y)}`));
            }).then((y)=>x(y)).catch(S);
        });
    };
    async function Ad(r) {
        const { legacyMetadataHost: e, enableOneKey: t, ecCurve: n, keyType: a, allowHost: i, network: s, clientId: o, endpoints: f, nodePubkeys: c, indexes: h, verifier: g, verifierParams: v, idToken: w, overrideExistingKey: E, newImportedShares: x, extraParams: S, useDkg: y = !0, serverTimeOffset: A, checkCommitment: P = !0 } = r;
        await Vr(i, {
            headers: {
                verifier: g,
                verifierid: v.verifier_id,
                network: s,
                clientid: o,
                enablegating: "true"
            }
        }, {
            useAPIKey: !0
        });
        const N = Iu(), k = Sr(N).toString("hex"), D = k.slice(2, 66), V = k.slice(66);
        let K = [];
        const j = ~~(f.length / 2) + 1;
        if (x?.length > 0) {
            if (x.length !== f.length) throw new Error("Invalid imported shares length");
            K = x;
        } else if (!y) {
            const B = a === xt.SECP256K1 ? Pf(n, Buffer) : await I2(32), T = await $u(n, a, A, h, c, Buffer.from(B));
            K = [
                ...K,
                ...T
            ];
        }
        let H = [], O;
        const d = [];
        if (P) {
            H = await X2({
                idToken: w,
                endpoints: f,
                indexes: h,
                keyType: a,
                verifier: g,
                verifierParams: v,
                pubKeyX: D,
                pubKeyY: V,
                finalImportedShares: K,
                overrideExistingKey: E
            });
            for(let B = 0; B < H.length; B += 1){
                const T = H[B];
                !T || typeof T != "object" || T.error || T && d.push(T.result);
            }
            O = !!In(d.map((B)=>B && B.pub_key_x), j);
        } else if (!P && K.length > 0 && !E) {
            var l, b;
            const B = await J2({
                endpoints: f,
                verifier: g,
                verifierId: v.verifier_id,
                keyType: a
            });
            if (B.errorResult && !((l = B.errorResult) !== null && l !== void 0 && (l = l.data) !== null && l !== void 0 && l.includes("Verifier + VerifierID has not yet been assigned"))) throw new Error(`node results do not match at first lookup ${JSON.stringify(B.keyResult || {})}, ${JSON.stringify(B.errorResult || {})}`);
            ((b = B.keyResult) === null || b === void 0 || (b = b.keys) === null || b === void 0 ? void 0 : b.length) > 0 && (O = !!B.keyResult.keys[0]);
        }
        const m = [], _ = E || !y && !O;
        if (_) {
            const B = Cu(f, g, v.verifier_id), T = [];
            for(let u = 0; u < f.length; u += 1){
                const I = K[u];
                if (!I) throw new Error(`invalid imported share at index ${u}`);
                T.push(Be(Be({}, v), {}, {
                    idtoken: w,
                    nodesignatures: d,
                    verifieridentifier: g,
                    pub_key_x: I.oauth_pub_key_x,
                    pub_key_y: I.oauth_pub_key_y,
                    signing_pub_key_x: I.signing_pub_key_x,
                    signing_pub_key_y: I.signing_pub_key_y,
                    encrypted_share: I.encrypted_share,
                    encrypted_share_metadata: I.encrypted_share_metadata,
                    node_index: I.node_index,
                    key_type: I.key_type,
                    nonce_data: I.nonce_data,
                    nonce_signature: I.nonce_signature,
                    sss_endpoint: f[u]
                }, S));
            }
            const R = cr(f[B], li(An.IMPORT_SHARES, {
                encrypted: "yes",
                use_temp: !0,
                verifieridentifier: g,
                temppubx: d.length === 0 && !P ? D : "",
                temppuby: d.length === 0 && !P ? V : "",
                item: T,
                key_type: a,
                one_key_flow: !0
            }), {}, {
                logTracingHeader: Dn.logRequestTracing
            }).catch((u)=>Tr.error("share req", u));
            m.push(R);
        } else for(let B = 0; B < f.length; B += 1){
            const T = cr(f[B], li(An.GET_SHARE_OR_KEY_ASSIGN, {
                encrypted: "yes",
                use_temp: !0,
                key_type: a,
                distributed_metadata: !0,
                verifieridentifier: g,
                temppubx: d.length === 0 && !P ? D : "",
                temppuby: d.length === 0 && !P ? V : "",
                item: [
                    Be(Be({}, v), {}, {
                        idtoken: w,
                        key_type: a,
                        nodesignatures: d,
                        verifieridentifier: g
                    }, S)
                ],
                client_time: Math.floor(Date.now() / 1e3).toString(),
                one_key_flow: !0
            }), {}, {
                logTracingHeader: Dn.logRequestTracing
            });
            m.push(T);
        }
        return ka(m, async (B, T)=>{
            let R, u = [];
            if (B.length === 1 && B[0] && Array.isArray(B[0].result)) {
                const ee = B[0];
                B[0].result.forEach((J)=>{
                    u.push({
                        id: ee.id,
                        jsonrpc: "2.0",
                        result: J,
                        error: ee.error
                    });
                });
            } else u = B;
            const I = u.filter((ee)=>!(!ee || typeof ee != "object" || ee.error)), G = u.map((ee)=>{
                if (ee && ee.result && ee.result.keys[0].public_key) return ee.result.keys[0].public_key;
            }), $ = In(G, j);
            if (!$) throw new Error("invalid result from nodes, threshold number of public key results are not matching");
            u.forEach((ee)=>{
                const J = ee && ee.result && ee.result.keys[0].public_key && ee.result.keys[0];
                if (J && !R && !v.extended_verifier_id) {
                    var oe;
                    const Me = J.public_key;
                    ((oe = J.nonce_data) === null || oe === void 0 || (oe = oe.pubNonce) === null || oe === void 0 ? void 0 : oe.x) && Me.X === $.X && (R = J.nonce_data);
                }
            });
            const te = _ ? f.length : j;
            if (I.length >= te && $) {
                const ee = [], J = [], oe = [], Me = [], xe = [], z = [], X = [];
                for(let Ze = 0; Ze < I.length; Ze += 1){
                    var Z;
                    const je = I[Ze], { session_tokens: Qe, session_token_metadata: qt, session_token_sigs: bt, session_token_sig_metadata: et, keys: ne, is_new_key: Oe, server_time_offset: We } = je.result;
                    if (z.push({
                        isNewKey: Oe,
                        publicKey: ((Z = je.result) === null || Z === void 0 || (Z = Z.keys[0]) === null || Z === void 0 || (Z = Z.public_key) === null || Z === void 0 ? void 0 : Z.X) || ""
                    }), X.push(We || "0"), bt?.length > 0) {
                        var fe;
                        et && (fe = et[0]) !== null && fe !== void 0 && fe.ephemPublicKey ? J.push(Sd(et[0], bt[0], N).catch((Pt)=>Tr.error("session sig decryption", Pt))) : J.push(Promise.resolve(Buffer.from(bt[0], "hex")));
                    } else J.push(Promise.resolve(void 0));
                    if (Qe?.length > 0) {
                        var pe;
                        qt && (pe = qt[0]) !== null && pe !== void 0 && pe.ephemPublicKey ? oe.push(Sd(qt[0], Qe[0], N).catch((Pt)=>Tr.error("session token sig decryption", Pt))) : oe.push(Promise.resolve(Buffer.from(Qe[0], "base64")));
                    } else oe.push(Promise.resolve(void 0));
                    if (ne?.length > 0) {
                        const Pt = je.result.keys[0];
                        Me.push(new Fe(Pt.node_index)), Pt.share_metadata && ee.push(D2(Pt.share_metadata, Buffer.from(Pt.share, "base64").toString("binary"), N).catch((pt)=>Tr.error("share decryption", pt)));
                    } else Me.push(void 0), ee.push(Promise.resolve(void 0));
                }
                const re = await Promise.all(ee.concat(J).concat(oe)), ge = re.slice(0, ee.length), Se = re.slice(ee.length, ee.length + J.length), ye = re.slice(ee.length + J.length, re.length), Y = Se.filter((Ze)=>!!Ze);
                if (!v.extended_verifier_id && Y.length < j) throw new Error(`Insufficient number of signatures from nodes, required: ${j}, found: ${Y.length}`);
                const le = ye.filter((Ze)=>!!Ze);
                if (!v.extended_verifier_id && le.length < j) throw new Error(`Insufficient number of session tokens from nodes, required: ${j}, found: ${le.length}`);
                if (ye.forEach((Ze, je)=>{
                    !Ze || !Se[je] ? xe.push(void 0) : xe.push({
                        token: Ze.toString("base64"),
                        signature: Se[je].toString("hex"),
                        node_pubx: I[je].result.node_pubx,
                        node_puby: I[je].result.node_puby
                    });
                }), T.resolved) return;
                const be = ge.reduce((Ze, je, Qe)=>(je && Ze.push({
                        index: Me[Qe],
                        value: new Fe(je)
                    }), Ze), []), se = ku(be.length, j);
                let De = null;
                for(let Ze = 0; Ze < se.length; Ze += 1){
                    const je = se[Ze], Qe = be.filter((Pt, pt)=>je.includes(pt)), qt = Qe.map((Pt)=>Pt.value), bt = Qe.map((Pt)=>Pt.index), et = U2(n, qt, bt);
                    if (!et) continue;
                    const ne = Ed(n, et), Oe = ne.getX(), We = ne.getY();
                    if (Oe.cmp(new Fe($.X, 16)) === 0 && We.cmp(new Fe($.Y, 16)) === 0) {
                        De = et;
                        break;
                    }
                }
                if (De == null) throw new Error("could not derive private key");
                let ze = !1;
                z.forEach((Ze)=>{
                    Ze.isNewKey === "true" && Ze.publicKey.toLowerCase() === $.X.toLowerCase() && (ze = !0);
                });
                const $e = X.map((Ze)=>Number.parseInt(Ze, 10));
                return {
                    privateKey: De,
                    sessionTokenData: xe,
                    thresholdNonceData: R,
                    nodeIndexes: Me,
                    thresholdPubKey: $,
                    isNewKey: ze,
                    serverTimeOffsetResponse: A || Of($e)
                };
            }
            throw I.length < te ? new Error(`Waiting for results from more nodes, pending: ${te - I.length}`) : new Error(`Invalid results, threshold pub key: ${$}, nonce data found: ${!!R}, extended verifierId: ${v.extended_verifier_id}`);
        }).then(async (B)=>{
            var T;
            const { privateKey: R, thresholdPubKey: u, sessionTokenData: I, nodeIndexes: G, thresholdNonceData: $, isNewKey: te, serverTimeOffsetResponse: Z } = B;
            let fe = $;
            if (!R) throw new Error("Invalid private key returned");
            const pe = R, ee = Ed(n, pe), J = ee.getX().toString("hex", 64), oe = ee.getY().toString("hex", 64);
            if (!fe && !v.extended_verifier_id && !rr[s]) {
                const De = await qu(s, u.X, u.Y, A, pe);
                if (De && !$) fe = De;
                else throw new Error(`invalid metadata result from nodes, nonce metadata is empty for verifier: ${g} and verifierId: ${v.verifier_id}`);
            }
            let Me = new Fe((T = fe) !== null && T !== void 0 && T.nonce ? fe.nonce.padStart(64, "0") : "0", "hex"), xe, z, X = "v1";
            if (v.extended_verifier_id) X = "v2", xe = n.keyFromPublic({
                x: J,
                y: oe
            }).getPublic();
            else if (rr[s]) if (t) if (fe = await Uu(e, n, Z, J, oe, pe, !te), Me = new Fe(fe.nonce || "0", 16), X = fe.typeOfUser, X === "v2") z = {
                X: fe.pubNonce.x,
                Y: fe.pubNonce.y
            }, xe = n.keyFromPublic({
                x: J,
                y: oe
            }).getPublic().add(n.keyFromPublic({
                x: fe.pubNonce.x,
                y: fe.pubNonce.y
            }).getPublic());
            else {
                X = "v1", Me = await da(e, {
                    pub_key_X: J,
                    pub_key_Y: oe
                });
                const De = pe.add(Me).umod(n.n);
                xe = n.keyFromPrivate(De.toString(16, 64), "hex").getPublic();
            }
            else {
                X = "v1", Me = await da(e, {
                    pub_key_X: J,
                    pub_key_Y: oe
                });
                const De = pe.add(Me).umod(n.n);
                xe = n.keyFromPrivate(De.toString(16, 64), "hex").getPublic();
            }
            else X = "v2", xe = n.keyFromPublic({
                x: J,
                y: oe
            }).getPublic().add(n.keyFromPublic({
                x: fe.pubNonce.x,
                y: fe.pubNonce.y
            }).getPublic()), z = {
                X: fe.pubNonce.x,
                Y: fe.pubNonce.y
            };
            if (!xe) throw new Error("Invalid public key, this might be a bug, please report this to web3auth team");
            let re = "", ge = !1;
            const Se = Y2(a, pe), ye = ti(a, xe.getX(), xe.getY());
            let Y = "";
            if (X === "v1" ? ge = null : X === "v2" && (ge = Me.eq(new Fe("0"))), (X === "v1" || X === "v2" && Me.gt(new Fe(0))) && (Y = pe.add(Me).umod(n.n).toString("hex", 64)), a === xt.SECP256K1) re = Y;
            else if (a === xt.ED25519) {
                if (Y && !fe.seed) throw new Error("Invalid data, seed data is missing for ed25519 key, Please report this bug");
                Y && fe.seed && (re = (await $2(fe.seed, new Fe(Y, "hex"))).toString("hex"));
            } else throw new Error(`Invalid keyType: ${a}`);
            let le = pe, be = J, se = oe;
            if (a === xt.ED25519) {
                const { scalar: De, point: ze } = ca(R);
                if (le = De, be = ze.getX().toString(16, 64), se = ze.getY().toString(16, 64), u.SignerX.padStart(64, "0") !== be || u.SignerY.padStart(64, "0") !== se) throw new Error("Invalid postbox key");
            }
            return {
                finalKeyData: {
                    walletAddress: ye,
                    X: xe.getX().toString(16, 64),
                    Y: xe.getY().toString(16, 64),
                    privKey: re
                },
                oAuthKeyData: {
                    walletAddress: Se,
                    X: J,
                    Y: oe,
                    privKey: pe.toString("hex", 64)
                },
                postboxKeyData: {
                    privKey: le.toString("hex", 64),
                    X: be,
                    Y: se
                },
                sessionData: {
                    sessionTokenData: I,
                    sessionAuthKey: N.toString("hex").padStart(64, "0")
                },
                metadata: {
                    pubNonce: z,
                    nonce: Me,
                    typeOfUser: X,
                    upgraded: ge,
                    serverTimeOffset: Z
                },
                nodesData: {
                    nodeIndexes: G.map((De)=>De.toNumber())
                }
            };
        });
    }
    class En {
        constructor({ enableOneKey: e = !1, clientId: t, network: n, serverTimeOffset: a = 0, allowHost: i, legacyMetadataHost: s, keyType: o = xt.SECP256K1 }){
            if (he(this, "allowHost", void 0), he(this, "serverTimeOffset", void 0), he(this, "network", void 0), he(this, "clientId", void 0), he(this, "ec", void 0), he(this, "enableOneKey", void 0), he(this, "legacyMetadataHost", void 0), he(this, "keyType", xt.SECP256K1), !t) throw new Error("Please provide a valid clientId in constructor");
            if (!n) throw new Error("Please provide a valid network in constructor");
            if (o === xt.ED25519 && rr[n]) throw new Error(`keyType: ${o} is not supported by ${n} network`);
            this.keyType = o, this.ec = new un.ec(this.keyType), this.serverTimeOffset = a || 0, this.network = n, this.clientId = t, this.allowHost = i || `${g2[n]}/api/allow`, this.enableOneKey = e, this.legacyMetadataHost = s || Bu[n];
        }
        static enableLogging(e = !0) {
            e ? (Tr.enableAll(), Dn.logRequestTracing = !0) : Tr.disableAll();
        }
        static setAPIKey(e) {
            m1(e);
        }
        static setEmbedHost(e) {
            v1(e);
        }
        static setSessionTime(e) {
            En.sessionTime = e;
        }
        static isGetOrSetNonceError(e) {
            return e instanceof Us;
        }
        static getPostboxKey(e) {
            return e.metadata.typeOfUser === "v1" && e.finalKeyData.privKey || e.postboxKeyData.privKey;
        }
        async retrieveShares(e) {
            const { verifier: t, verifierParams: n, idToken: a, nodePubkeys: i, indexes: s, endpoints: o, useDkg: f, extraParams: c = {}, checkCommitment: h = !0 } = e;
            if (i.length === 0) throw new Error("nodePubkeys param is required");
            if (i.length !== s.length) throw new Error("nodePubkeys length must be same as indexes length");
            if (i.length !== o.length) throw new Error("nodePubkeys length must be same as endpoints length");
            let g;
            if (typeof f == "boolean") {
                if (f === !1 && rr[this.network]) throw new Error(`useDkg cannot be false for legacy network; ${this.network}`);
                g = this.keyType === xt.ED25519 ? !1 : f;
            } else this.keyType === xt.ED25519 ? g = !1 : g = !0;
            if (!g && i.length === 0) throw new Error("nodePubkeys param is required");
            return c.session_token_exp_second || (c.session_token_exp_second = En.sessionTime), Ad({
                legacyMetadataHost: this.legacyMetadataHost,
                serverTimeOffset: this.serverTimeOffset,
                enableOneKey: this.enableOneKey,
                ecCurve: this.ec,
                keyType: this.keyType,
                allowHost: this.allowHost,
                network: this.network,
                clientId: this.clientId,
                endpoints: o,
                indexes: s,
                verifier: t,
                verifierParams: n,
                idToken: a,
                useDkg: g,
                newImportedShares: [],
                overrideExistingKey: !1,
                nodePubkeys: i,
                extraParams: c,
                checkCommitment: h
            });
        }
        async getPublicAddress(e, t, { verifier: n, verifierId: a, extendedVerifierId: i, keyType: s }) {
            Tr.info(t, {
                verifier: n,
                verifierId: a,
                extendedVerifierId: i
            });
            const o = s ?? this.keyType;
            return this.getNewPublicAddress(e, {
                verifier: n,
                verifierId: a,
                extendedVerifierId: i,
                keyType: o
            }, this.enableOneKey);
        }
        async importPrivateKey(e) {
            const { nodeIndexes: t, newPrivateKey: n, verifier: a, verifierParams: i, idToken: s, nodePubkeys: o, endpoints: f, extraParams: c = {}, checkCommitment: h = !0 } = e;
            if (rr[this.network]) throw new Error(`importPrivateKey is not supported by legacy network; ${this.network}`);
            if (f.length !== t.length) throw new Error("length of endpoints array must be same as length of nodeIndexes array");
            c.session_token_exp_second || (c.session_token_exp_second = En.sessionTime);
            let g;
            if (this.keyType === xt.SECP256K1 && (g = Buffer.from(n.padStart(64, "0"), "hex"), g.length !== 32)) throw new Error("Invalid private key length for given secp256k1 key");
            if (this.keyType === xt.ED25519 && (g = Buffer.from(n.padStart(64, "0"), "hex"), g.length !== 32)) throw new Error("Invalid private key length for given ed25519 key");
            const v = await $u(this.ec, this.keyType, this.serverTimeOffset, t, o, g);
            if (this.keyType === xt.ED25519) {
                const w = Du(g), E = ua(w.point), x = ua(v[0].final_user_point), S = Buffer.from(E).toString("hex"), y = x.toString("hex");
                if (S !== y) throw new Error("invalid shares data for ed25519 key, public key is not matching after generating shares");
            }
            return Ad({
                legacyMetadataHost: this.legacyMetadataHost,
                serverTimeOffset: this.serverTimeOffset,
                enableOneKey: this.enableOneKey,
                ecCurve: this.ec,
                keyType: this.keyType,
                allowHost: this.allowHost,
                network: this.network,
                clientId: this.clientId,
                endpoints: f,
                indexes: t,
                verifier: a,
                verifierParams: i,
                idToken: s,
                useDkg: !1,
                overrideExistingKey: !0,
                newImportedShares: v,
                nodePubkeys: o,
                extraParams: c,
                checkCommitment: h
            });
        }
        async getUserTypeAndAddress(e, { verifier: t, verifierId: n, extendedVerifierId: a }) {
            return this.getNewPublicAddress(e, {
                verifier: t,
                verifierId: n,
                extendedVerifierId: a
            }, !0);
        }
        async getNewPublicAddress(e, { verifier: t, verifierId: n, extendedVerifierId: a, keyType: i }, s) {
            const o = i ?? this.keyType, f = Er(o);
            if (o === xt.ED25519 && rr[this.network]) throw new Error(`keyType: ${i} is not supported by ${this.network} network`);
            const c = await G2({
                endpoints: e,
                network: this.network,
                verifier: t,
                verifierId: n,
                keyType: o,
                extendedVerifierId: a
            }), { errorResult: h, keyResult: g, nodeIndexes: v = [], serverTimeOffset: w } = c, E = this.serverTimeOffset || w, { nonceResult: x } = c;
            if (h && JSON.stringify(h).toLowerCase().includes("verifier not supported")) throw new Error(`Verifier not supported. Check if you: 

      1. Are on the right network (Torus testnet/mainnet) 

      2. Have setup a verifier on dashboard.web3auth.io?`);
            if (h) throw new Error(`node results do not match at first lookup ${JSON.stringify(g || {})}, ${JSON.stringify(h || {})}`);
            if (!(g != null && g.keys)) throw new Error(`node results do not match at final lookup ${JSON.stringify(g || {})}, ${JSON.stringify(h || {})}`);
            if (!x && !a && !rr[this.network]) throw new Us("metadata nonce is missing in share response");
            const { pub_key_X: S, pub_key_Y: y } = g.keys[0];
            let A;
            const P = new Fe(x?.nonce || "0", 16);
            let N, k;
            if (a) k = f.keyFromPublic({
                x: S,
                y
            }).getPublic(), N = k;
            else {
                if (rr[this.network]) return this.formatLegacyPublicKeyData({
                    isNewKey: g.is_new_key,
                    enableOneKey: s,
                    finalKeyResult: {
                        keys: g.keys
                    },
                    serverTimeOffset: E
                });
                {
                    const d = x;
                    N = f.keyFromPublic({
                        x: S,
                        y
                    }).getPublic(), k = f.keyFromPublic({
                        x: S,
                        y
                    }).getPublic().add(f.keyFromPublic({
                        x: d.pubNonce.x,
                        y: d.pubNonce.y
                    }).getPublic()), A = {
                        X: d.pubNonce.x,
                        Y: d.pubNonce.y
                    };
                }
            }
            if (!N) throw new Error("Unable to derive oAuthPubKey");
            const D = N.getX().toString(16, 64), V = N.getY().toString(16, 64), K = ti(o, N.getX(), N.getY());
            if (!k) throw new Error("Unable to derive finalPubKey");
            const j = k ? k.getX().toString(16, 64) : "", H = k ? k.getY().toString(16, 64) : "", O = k ? ti(o, k.getX(), k.getY()) : "";
            return {
                oAuthKeyData: {
                    walletAddress: K,
                    X: D,
                    Y: V
                },
                finalKeyData: {
                    walletAddress: O,
                    X: j,
                    Y: H
                },
                metadata: {
                    pubNonce: A,
                    nonce: P,
                    upgraded: x?.upgraded || !1,
                    typeOfUser: "v2",
                    serverTimeOffset: E
                },
                nodesData: {
                    nodeIndexes: v
                }
            };
        }
        async formatLegacyPublicKeyData(e) {
            var t;
            const { finalKeyResult: n, enableOneKey: a, isNewKey: i, serverTimeOffset: s, keyType: o } = e, f = o ?? this.keyType, c = Er(f), { pub_key_X: h, pub_key_Y: g } = n.keys[0];
            let v, w, E, x, S;
            const y = c.keyFromPublic({
                x: h,
                y: g
            }).getPublic(), A = this.serverTimeOffset || s;
            if (a) {
                try {
                    v = await Uu(this.legacyMetadataHost, c, A, h, g, void 0, !i), w = new Fe(v.nonce || "0", 16), x = v.typeOfUser;
                } catch  {
                    throw new Us;
                }
                if (v.typeOfUser === "v1") w = await da(this.legacyMetadataHost, {
                    pub_key_X: h,
                    pub_key_Y: g
                }), E = c.keyFromPublic({
                    x: h,
                    y: g
                }).getPublic().add(c.keyFromPrivate(w.toString(16, 64), "hex").getPublic());
                else if (v.typeOfUser === "v2") E = c.keyFromPublic({
                    x: h,
                    y: g
                }).getPublic().add(c.keyFromPublic({
                    x: v.pubNonce.x,
                    y: v.pubNonce.y
                }).getPublic()), S = {
                    X: v.pubNonce.x,
                    Y: v.pubNonce.y
                };
                else throw new Error("getOrSetNonce should always return typeOfUser.");
            } else x = "v1", w = await da(this.legacyMetadataHost, {
                pub_key_X: h,
                pub_key_Y: g
            }), E = c.keyFromPublic({
                x: h,
                y: g
            }).getPublic().add(c.keyFromPrivate(w.toString(16, 64), "hex").getPublic());
            if (!y) throw new Error("Unable to derive oAuthPubKey");
            const P = y.getX().toString(16, 64), N = y.getY().toString(16, 64), k = ti(f, y.getX(), y.getY());
            if (x === "v2" && !E) throw new Error("Unable to derive finalPubKey");
            const D = E ? E.getX().toString(16, 64) : "", V = E ? E.getY().toString(16, 64) : "", K = E ? ti(f, E.getX(), E.getY()) : "";
            return {
                oAuthKeyData: {
                    walletAddress: k,
                    X: P,
                    Y: N
                },
                finalKeyData: {
                    walletAddress: K,
                    X: D,
                    Y: V
                },
                metadata: {
                    pubNonce: S,
                    nonce: w,
                    upgraded: ((t = v) === null || t === void 0 ? void 0 : t.upgraded) || !1,
                    typeOfUser: x,
                    serverTimeOffset: A
                },
                nodesData: {
                    nodeIndexes: []
                }
            };
        }
    }
    he(En, "sessionTime", 86400);
    var Ci = {}, Id;
    function Z2() {
        if (Id) return Ci;
        Id = 1;
        var r = function() {
            return !!(window.location.hostname === "localhost" || window.location.hostname === "[::1]" || window.location.hostname.match(/^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/));
        }, e;
        typeof window < "u" && (typeof document < "u" && (document.readyState === "interactive" || document.readyState === "complete") ? e = Promise.resolve() : typeof Promise < "u" ? e = new Promise(function(i) {
            return window.addEventListener("load", i);
        }) : e = {
            then: function(i) {
                return window.addEventListener("load", i);
            }
        }), Ci.register = function(s, o) {
            o === void 0 && (o = {});
            var f = o.registrationOptions;
            f === void 0 && (f = {}), delete o.registrationOptions;
            var c = function(h) {
                for(var g = [], v = arguments.length - 1; v-- > 0;)g[v] = arguments[v + 1];
                o && o[h] && o[h].apply(o, g);
            };
            "serviceWorker" in navigator && e.then(function() {
                r() ? (a(s, c, f), navigator.serviceWorker.ready.then(function(h) {
                    c("ready", h);
                }).catch(function(h) {
                    return t(c, h);
                })) : (n(s, c, f), navigator.serviceWorker.ready.then(function(h) {
                    c("ready", h);
                }).catch(function(h) {
                    return t(c, h);
                }));
            });
        };
        function t(i, s) {
            navigator.onLine || i("offline"), i("error", s);
        }
        function n(i, s, o) {
            navigator.serviceWorker.register(i, o).then(function(f) {
                if (s("registered", f), f.waiting) {
                    s("updated", f);
                    return;
                }
                f.onupdatefound = function() {
                    s("updatefound", f);
                    var c = f.installing;
                    c.onstatechange = function() {
                        c.state === "installed" && (navigator.serviceWorker.controller ? s("updated", f) : s("cached", f));
                    };
                };
            }).catch(function(f) {
                return t(s, f);
            });
        }
        function a(i, s, o) {
            fetch(i).then(function(f) {
                f.status === 404 ? (s("error", new Error("Service worker not found at " + i)), unregister()) : f.headers.get("content-type").indexOf("javascript") === -1 ? (s("error", new Error("Expected " + i + " to have javascript content-type, but received " + f.headers.get("content-type"))), unregister()) : n(i, s, o);
            }).catch(function(f) {
                return t(s, f);
            });
        }
        return Ci.unregister = function() {
            "serviceWorker" in navigator && navigator.serviceWorker.ready.then(function(s) {
                s.unregister();
            }).catch(function(s) {
                return t(emit, s);
            });
        }, Ci;
    }
    var Q2 = Z2();
    const e6 = (r)=>new Promise((e, t)=>{
            const n = `${r}sw.js`;
            "serviceWorker" in window.navigator ? Q2.register(n, {
                ready () {
                    Ct.info(`App is being served from cache by a service worker.
 For more details, visit https://goo.gl/AFskqB`), e(void 0);
                },
                registered () {
                    Ct.info("Service worker has been registered."), e(void 0);
                },
                cached () {
                    Ct.info("Content has been cached for offline use."), e(void 0);
                },
                updatefound () {
                    Ct.info("New content is downloading.");
                },
                updated () {
                    Ct.info("New content is available; please refresh.");
                },
                offline () {
                    Ct.info("No internet connection found. App is running in offline mode."), t(new Error("App is offline"));
                },
                error (a) {
                    Ct.error("Error during service worker registration:", a), t(a);
                }
            }) : t(new Error("Service workers are not supported"));
        });
    class t6 {
        constructor(e){
            he(this, "sentry", null), this.sentry = e;
        }
        startSpan(e, t) {
            return this.sentry ? this.sentry.startSpan(e, t) : t(null);
        }
    }
    const Ku = async (r)=>{
        const e = r instanceof Error, t = typeof r == "string", n = r && typeof r == "object" && "status" in r && "type" in r;
        let a;
        if (n) {
            const i = r, s = i.headers.get("content-type");
            if (s.includes("application/json")) {
                const o = await i.json();
                a = new Error(o?.error || o?.message || JSON.stringify(o));
            } else s.includes("text/plain") ? a = new Error(await i.text()) : a = new Error(`${i.status} ${i.type.toString()} ${i.statusText}`);
        } else t ? a = new Error(r) : e ? a = r : a = new Error("Unknown error");
        return a;
    };
    class ju {
        constructor(e){
            he(this, "currentStorageMethod", Qn.LOCAL_STORAGE), he(this, "isInitialized", !1), he(this, "storageServerUrl", Mf), he(this, "localStorageAvailable", !0), this.storageServerUrl = e;
        }
        get storageMethodUsed() {
            return this.currentStorageMethod;
        }
        init() {
            const e = oa(Qn.LOCAL_STORAGE);
            this.localStorageAvailable = e, this.isInitialized = !0;
        }
        async storeData(e, t) {
            if (!this.isInitialized) throw new Error("StorageHelper is not initialized");
            this.localStorageAvailable && window.localStorage.setItem(e, JSON.stringify(t));
            const n = Br(Buffer.from(e, "utf8")), a = n.toString("hex"), i = Sr(n).toString("hex"), s = await si(a, t), o = (await ai(n, Br(Buffer.from(s, "utf8")))).toString("hex");
            await cr(`${this.storageServerUrl}/v2/store/set`, {
                key: i,
                data: s,
                signature: o,
                allowedOrigin: !0
            });
        }
        async retrieveData(e) {
            if (!this.isInitialized) throw new Error("StorageHelper is not initialized");
            if (this.localStorageAvailable) {
                const i = window.localStorage.getItem(e);
                if (i) return this.currentStorageMethod = Qn.LOCAL_STORAGE, JSON.parse(i || "{}");
            }
            this.currentStorageMethod = Qn.SERVER;
            const t = Br(Buffer.from(e, "utf8")), n = t.toString("hex"), a = Sr(t).toString("hex");
            try {
                const i = await cr(`${this.storageServerUrl}/v2/store/get`, {
                    key: a
                });
                if (i.message) return await If(n, i.message);
            } catch (i) {
                if (i.status === 404) Ct.warn(i, "Session likely expired");
                else throw i;
            }
        }
        clearStorage(e) {
            if (!this.isInitialized) throw new Error("StorageHelper is not initialized");
            this.localStorageAvailable && window.localStorage.removeItem(e);
        }
        clearOrphanedData(e) {
            if (!this.isInitialized) throw new Error("StorageHelper is not initialized");
            if (!this.localStorageAvailable) return;
            Object.keys(window.localStorage).forEach((n)=>{
                n.startsWith(e) && window.localStorage.removeItem(n);
            });
        }
    }
    const r6 = [
        "access_token",
        "id_token",
        "tgAuthResult"
    ], n6 = [
        "args"
    ];
    class i6 {
        constructor({ baseUrl: e, network: t, enableLogging: n = !1, redirectToOpener: a = !1, redirectPathName: i = "redirect", apiKey: s = "torus-default", uxMode: o = Zt.POPUP, locationReplaceOnRedirect: f = !1, popupFeatures: c, storageServerUrl: h = "https://session.web3auth.io", sentry: g, enableOneKey: v = !1, web3AuthClientId: w, useDkg: E, metadataUrl: x = "https://metadata.tor.us", keyType: S = "secp256k1", serverTimeOffset: y = 0, nodeDetails: A, checkCommitment: P = !0 }){
            if (he(this, "isInitialized", void 0), he(this, "config", void 0), he(this, "torus", void 0), he(this, "nodeDetailManager", void 0), he(this, "storageHelper", void 0), he(this, "sentryHandler", void 0), !w) throw new Error("Please provide a valid web3AuthClientId in constructor");
            if (!t) throw new Error("Please provide a valid network in constructor");
            this.isInitialized = !1;
            const N = new URL(e);
            this.config = {
                baseUrl: Ma(N),
                get redirect_uri () {
                    return `${this.baseUrl}${i}`;
                },
                redirectToOpener: a,
                uxMode: o,
                locationReplaceOnRedirect: f,
                popupFeatures: c,
                useDkg: E,
                web3AuthClientId: w,
                web3AuthNetwork: t,
                keyType: S,
                nodeDetails: A,
                checkCommitment: P
            };
            const k = new En({
                network: t,
                enableOneKey: v,
                serverTimeOffset: y,
                clientId: w,
                legacyMetadataHost: x,
                keyType: S
            });
            En.setAPIKey(s), this.torus = k, this.nodeDetailManager = new _2({
                network: t
            }), n ? Ct.enableAll() : Ct.disableAll(), this.storageHelper = new ju(h), this.sentryHandler = new t6(g);
        }
        async init({ skipSw: e = !1, skipInit: t = !1, skipPrefetch: n = !1 } = {}) {
            if (this.storageHelper.init(), t) {
                this.isInitialized = !0;
                return;
            }
            if (!e) if ((await fetch(`${this.config.baseUrl}sw.js`, {
                cache: "reload"
            })).ok) try {
                await e6(this.config.baseUrl), this.isInitialized = !0;
                return;
            } catch (i) {
                Ct.warn(i);
            }
            else throw new Error("Service worker is not being served. Please serve it");
            if (!n) {
                if (wu()) {
                    this.isInitialized = !0;
                    return;
                }
                await this.handlePrefetchRedirectUri();
                return;
            }
            this.isInitialized = !0;
        }
        async triggerLogin(e) {
            const { authConnectionId: t, authConnection: n, clientId: a, jwtParams: i, hash: s, queryParameters: o, customState: f, groupedAuthConnectionId: c } = e;
            if (!this.isInitialized) throw new Error("Not initialized yet");
            const h = Pu({
                authConnection: n,
                clientId: a,
                authConnectionId: t,
                groupedAuthConnectionId: c,
                redirect_uri: this.config.redirect_uri,
                redirectToOpener: this.config.redirectToOpener,
                jwtParams: i,
                uxMode: this.config.uxMode,
                customState: f,
                web3AuthClientId: this.config.web3AuthClientId,
                web3AuthNetwork: this.config.web3AuthNetwork
            });
            let g;
            if (s && o) {
                const { error: E, hashParameters: x, instanceParameters: S } = Do(s, o);
                if (E) throw new Error(E);
                const { access_token: y, id_token: A, tgAuthResult: P } = x, N = sa(x, r6);
                g = Be(Be({
                    accessToken: y,
                    idToken: A || P || ""
                }, N), {}, {
                    state: S
                });
            } else if (this.storageHelper.clearOrphanedData("torus_login_"), this.config.uxMode === Zt.REDIRECT && await this.storageHelper.storeData(`torus_login_${h.nonce}`, {
                args: e
            }), g = await h.handleLoginWindow({
                locationReplaceOnRedirect: this.config.locationReplaceOnRedirect,
                popupFeatures: this.config.popupFeatures
            }), this.config.uxMode === Zt.REDIRECT) return null;
            const v = await h.getUserInfo(g), w = await this.getTorusKey({
                authConnectionId: t,
                userId: v.userId,
                idToken: g.idToken || g.accessToken,
                additionalParams: v.extraConnectionParams,
                groupedAuthConnectionId: c
            });
            return Be(Be({}, w), {}, {
                userInfo: Be(Be({}, v), g)
            });
        }
        async getTorusKey(e) {
            const { authConnectionId: t, userId: n, idToken: a, additionalParams: i, groupedAuthConnectionId: s } = e, o = s || t, f = n, c = {
                verifier_id: n
            };
            let h = "";
            const g = a;
            s && (c.verify_params = [
                {
                    verifier_id: n,
                    idtoken: g
                }
            ], c.sub_verifier_ids = [
                t
            ], h = Tn(Buffer.from(g, "utf8")).slice(2));
            const v = await this.sentryHandler.startSpan({
                name: Lo.FETCH_NODE_DETAILS
            }, async ()=>this.config.nodeDetails ? this.config.nodeDetails : this.nodeDetailManager.getNodeDetails({
                    verifier: o,
                    verifierId: f
                }));
            Ct.debug("torus-direct/getTorusKey", {
                torusNodeEndpoints: v.torusNodeEndpoints
            });
            const w = await this.sentryHandler.startSpan({
                name: Lo.FETCH_SHARES
            }, async ()=>this.torus.retrieveShares({
                    endpoints: v.torusNodeEndpoints,
                    indexes: v.torusIndexes,
                    verifier: o,
                    verifierParams: c,
                    idToken: h || g,
                    nodePubkeys: v.torusNodePub,
                    extraParams: Be({}, i),
                    useDkg: this.config.useDkg,
                    checkCommitment: this.config.checkCommitment
                }));
            return Ct.debug("torus-direct/getTorusKey", {
                retrieveShares: w
            }), w;
        }
        async getRedirectResult({ replaceUrl: e = !0, clearLoginDetails: t = !0, storageData: n = void 0 } = {}) {
            await this.init({
                skipInit: !0
            });
            const a = new URL(window.location.href), i = a.hash.substring(1), s = {};
            if (a.searchParams.forEach((S, y)=>{
                s[y] = S;
            }), !i && Object.keys(s).length === 0) throw new Error("Found Empty hash and query parameters. This can happen if user reloads the page");
            const { error: o, instanceParameters: f, hashParameters: c } = Do(i, s), { instanceId: h } = f;
            Ct.info(h, "instanceId");
            const v = n || await this.storageHelper.retrieveData(`torus_login_${h}`) || {}, { args: w } = v, E = sa(v, n6);
            Ct.info(w, "args", this.storageHelper.storageMethodUsed);
            let x;
            if (o) return {
                error: o,
                state: f || {},
                result: {},
                hashParameters: c,
                args: w
            };
            try {
                w.hash = i, w.queryParameters = s, x = await this.triggerLogin(w);
            } catch (S) {
                const y = await Ku(S);
                return Ct.error(y), t && this.storageHelper.clearStorage(`torus_login_${h}`), Be({
                    error: `${y.message || ""}`,
                    state: f || {},
                    result: {},
                    hashParameters: c,
                    args: w
                }, E);
            }
            if (!x) return Be({
                error: `Init parameters not found. It might be because storage is not available. Please retry the login in a different browser. Used storage method: ${this.storageHelper.storageMethodUsed}`,
                state: f || {},
                result: {},
                hashParameters: c,
                args: w
            }, E);
            if (e) {
                const S = window.location.origin + window.location.pathname;
                window.history.replaceState(Be(Be({}, window.history.state), {}, {
                    as: S,
                    url: S
                }), "", S);
            }
            return t && this.storageHelper.clearStorage(`torus_login_${h}`), Be({
                result: x,
                state: f || {},
                hashParameters: c,
                args: w
            }, E);
        }
        async handlePrefetchRedirectUri() {
            return document ? new Promise((e, t)=>{
                const n = document.createElement("link");
                n.href = this.config.redirect_uri, window.location.origin !== new URL(this.config.redirect_uri).origin && (n.crossOrigin = "anonymous"), n.type = "text/html", n.rel = "prefetch";
                const a = ()=>{
                    this.isInitialized = !0, e();
                };
                try {
                    n.relList && n.relList.supports && n.relList.supports("prefetch") ? (n.onload = a, n.onerror = ()=>{
                        t(new Error(`Please serve redirect.html present in serviceworker folder of this package on ${this.config.redirect_uri}`));
                    }, document.head.appendChild(n)) : a();
                } catch  {
                    a();
                }
            }) : Promise.resolve();
        }
    }
    const Nr = vr.getLogger("auth");
    Nr.setLevel("error");
    const a6 = "auth_store", Hu = Rt, zu = Qt, Ji = Be(Be({}, zu), Hu), s6 = {
        SECP256K1: "secp256k1",
        ED25519: "ed25519",
        OTHER: "other"
    }, o6 = {
        DEFAULT: "default",
        OPTIONAL: "optional",
        MANDATORY: "mandatory",
        NONE: "none"
    }, pn = {
        LOGIN: "login",
        ENABLE_MFA: "enable_mfa",
        MANAGE_MFA: "manage_mfa",
        ADD_SOCIAL_FACTOR: "add_social_factor",
        MODIFY_SOCIAL_FACTOR: "modify_social_factor",
        ADD_AUTHENTICATOR_FACTOR: "add_authenticator_factor",
        ADD_PASSKEY_FACTOR: "add_passkey_factor"
    }, tn = {
        PRODUCTION: "production",
        DEVELOPMENT: "development",
        STAGING: "staging",
        TESTING: "testing"
    }, Mr = {
        DEFAULT: "default",
        IFRAME: "iframe"
    }, Fr = {
        SETUP_COMPLETE: "setup_complete",
        INIT_DAPP: "init_dapp",
        LOGIN_INITIATED: "login_initiated",
        LOGIN_CANCELLED: "login_cancelled",
        LOGIN_FAILED: "login_failed",
        LOGIN_SUCCESS: "login_success",
        DISPLAY_IFRAME: "display_iframe",
        HIDE_IFRAME: "hide_iframe"
    }, Ko = "auth-iframe", Wu = "http://localhost:3000", Yu = "https://staging-auth.web3auth.io", Vu = "https://develop-auth.web3auth.io", Gu = "https://auth.web3auth.io", Ju = "http://localhost:5173", Xu = "https://staging-account.web3auth.io", Zu = "https://develop-account.web3auth.io", Qu = "https://account.web3auth.io", el = 1e3 * 10, f6 = {
        en: "en",
        ja: "ja",
        ko: "ko",
        de: "de",
        zh: "zh",
        es: "es",
        fr: "fr",
        pt: "pt",
        nl: "nl",
        tr: "tr",
        am: "am"
    }, c6 = {
        en: "english",
        ja: "japanese",
        ko: "korean",
        de: "german",
        zh: "mandarin",
        es: "spanish",
        fr: "french",
        pt: "portuguese",
        nl: "dutch",
        tr: "turkish",
        am: "amharic"
    }, la = {
        light: "light",
        dark: "dark",
        auto: "auto"
    }, d6 = {
        DEVICE: "deviceShareFactor",
        BACKUP_SHARE: "backUpShareFactor",
        SOCIAL_BACKUP: "socialBackupFactor",
        PASSWORD: "passwordFactor",
        PASSKEYS: "passkeysFactor",
        AUTHENTICATOR: "authenticatorFactor"
    }, mi = kr;
    function u6(r) {
        return mi.encode(r);
    }
    function jo(r) {
        return mi.decode(r);
    }
    function l6(r) {
        return JSON.parse(mi.decode(r));
    }
    function ri(r) {
        return mi.encode(JSON.stringify(r));
    }
    const tl = (r)=>{
        const e = window.document.createElement("template"), t = r.trim();
        return e.innerHTML = t, e.content.firstChild;
    };
    function h6(r) {
        try {
            return structuredClone(r);
        } catch  {
            return JSON.parse(JSON.stringify(r));
        }
    }
    const Li = new Map;
    function b6(r) {
        return r === la.light ? "light" : r === la.dark || window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
    }
    class p6 {
        constructor({ sdkUrl: e, whiteLabel: t }){
            he(this, "sdkUrl", void 0), he(this, "whiteLabel", void 0), he(this, "initialized", !1), he(this, "loginCallbackSuccess", null), he(this, "loginCallbackFailed", null), he(this, "embedNonce", wf()), this.sdkUrl = e, this.whiteLabel = t;
        }
        get targetOrigin() {
            return new URL(this.sdkUrl).origin;
        }
        getAuthServiceIframe() {
            return Li.get(this.embedNonce);
        }
        registerAuthServiceIframe(e) {
            Li.set(this.embedNonce, e);
        }
        cleanup() {
            const e = Li.get(this.embedNonce);
            e && e.parentNode && (e.parentNode.removeChild(e), Li.delete(this.embedNonce));
        }
        async init({ network: e, clientId: t }) {
            if (typeof window > "u" || typeof document > "u") throw new Error("window or document is not available");
            if (this.initialized) throw new Error("AuthProvider already initialized");
            const n = new URL(this.sdkUrl);
            n.pathname.endsWith("/") ? n.pathname += "frame" : n.pathname += "/frame";
            const a = new URLSearchParams;
            a.append("origin", window.location.origin), a.append("nonce", this.embedNonce), n.hash = a.toString();
            const i = b6(this.whiteLabel.mode || la.light), s = tl(`<iframe
        id="${Ko}-${this.embedNonce}"
        class="${Ko}-${this.embedNonce}"
        sandbox="allow-popups allow-scripts allow-same-origin allow-forms allow-modals allow-downloads"
        src="${n.href}"
        style="display: none; position: fixed; top: 0; right: 0; width: 100%; z-index: 10000000;
        height: 100%; border: none; border-radius: 0; color-scheme: ${i};"
        allow="clipboard-write"
      ></iframe>`);
            return this.registerAuthServiceIframe(s), new Promise((o, f)=>{
                try {
                    window.document.body.appendChild(s);
                    const c = (h)=>{
                        var g, v, w;
                        if (h.origin !== this.targetOrigin) return;
                        const { data: E } = h, { type: x, nonce: S } = E;
                        if (S !== this.embedNonce) return;
                        const y = E.data;
                        switch(x){
                            case Fr.SETUP_COMPLETE:
                                (g = this.getAuthServiceIframe()) === null || g === void 0 || (g = g.contentWindow) === null || g === void 0 || g.postMessage({
                                    type: Fr.INIT_DAPP,
                                    data: {
                                        network: e,
                                        clientId: t
                                    }
                                }, this.targetOrigin), this.initialized = !0, o();
                                break;
                            case Fr.LOGIN_FAILED:
                                (v = this.loginCallbackFailed) === null || v === void 0 || v.call(this, y?.error || "Login failed, reason: unknown");
                                break;
                            case Fr.DISPLAY_IFRAME:
                                this.getAuthServiceIframe().style.display = "block";
                                break;
                            case Fr.HIDE_IFRAME:
                                this.getAuthServiceIframe().style.display = "none";
                                break;
                            case Fr.LOGIN_SUCCESS:
                                Nr.info("LOGIN_SUCCESS", y), this.getAuthServiceIframe().style.display = "none", y != null && y.sessionId && ((w = this.loginCallbackSuccess) === null || w === void 0 || w.call(this, y));
                                break;
                            default:
                                Nr.warn(`Unknown message type: ${x}`);
                                break;
                        }
                    };
                    window.addEventListener("message", c);
                } catch (c) {
                    f(c);
                }
            });
        }
        postLoginInitiatedMessage(e, t) {
            var n;
            if (!this.initialized) throw new Error("Iframe not initialized");
            return (n = this.getAuthServiceIframe().contentWindow) === null || n === void 0 || n.postMessage({
                type: Fr.LOGIN_INITIATED,
                data: {
                    loginConfig: e,
                    nonce: t
                }
            }, this.targetOrigin), new Promise((a, i)=>{
                this.loginCallbackSuccess = a, this.loginCallbackFailed = i;
            });
        }
        postLoginCancelledMessage(e) {
            var t;
            if (!this.initialized) throw new Error("Iframe not initialized");
            (t = this.getAuthServiceIframe().contentWindow) === null || t === void 0 || t.postMessage({
                type: Fr.LOGIN_CANCELLED,
                data: {
                    nonce: e
                }
            }, this.targetOrigin);
        }
    }
    function g6(r, e) {
        var t = Object.setPrototypeOf;
        t ? t(r, e) : r.__proto__ = e;
    }
    function y6(r, e) {
        e === void 0 && (e = r.constructor);
        var t = Error.captureStackTrace;
        t && t(r, e);
    }
    var v6 = (function() {
        var r = function(t, n) {
            return r = Object.setPrototypeOf || {
                __proto__: []
            } instanceof Array && function(a, i) {
                a.__proto__ = i;
            } || function(a, i) {
                for(var s in i)Object.prototype.hasOwnProperty.call(i, s) && (a[s] = i[s]);
            }, r(t, n);
        };
        return function(e, t) {
            if (typeof t != "function" && t !== null) throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
            r(e, t);
            function n() {
                this.constructor = e;
            }
            e.prototype = t === null ? Object.create(t) : (n.prototype = t.prototype, new n);
        };
    })(), m6 = (function(r) {
        v6(e, r);
        function e(t, n) {
            var a = this.constructor, i = r.call(this, t, n) || this;
            return Object.defineProperty(i, "name", {
                value: a.name,
                enumerable: !1,
                configurable: !0
            }), g6(i, a.prototype), y6(i), i;
        }
        return e;
    })(Error);
    class kf extends m6 {
        constructor(e, t){
            super(t), he(this, "code", void 0), he(this, "message", void 0), this.code = e, this.message = t || "", Object.defineProperty(this, "name", {
                value: "AuthError"
            });
        }
        toJSON() {
            return {
                name: this.name,
                code: this.code,
                message: this.message
            };
        }
        toString() {
            return JSON.stringify(this.toJSON());
        }
    }
    class Pr extends kf {
        constructor(e, t){
            super(e, t), Object.defineProperty(this, "name", {
                value: "InitializationError"
            });
        }
        static fromCode(e, t = "") {
            return new Pr(e, `${Pr.messages[e]}, ${t}`);
        }
        static invalidParams(e = "") {
            return Pr.fromCode(5001, e);
        }
        static notInitialized(e = "") {
            return Pr.fromCode(5002, e);
        }
    }
    he(Pr, "messages", {
        5e3: "Custom",
        5001: "Invalid constructor params",
        5002: "SDK not initialized. please call init first"
    });
    class At extends kf {
        constructor(e, t){
            super(e, t), Object.defineProperty(this, "name", {
                value: "LoginError"
            });
        }
        static fromCode(e, t = "") {
            return new At(e, `${At.messages[e]}, ${t}`);
        }
        static invalidLoginParams(e = "") {
            return At.fromCode(5111, e);
        }
        static userNotLoggedIn(e = "") {
            return At.fromCode(5112, e);
        }
        static popupClosed(e = "") {
            return At.fromCode(5113, e);
        }
        static loginFailed(e = "") {
            return At.fromCode(5114, e);
        }
        static popupBlocked(e = "") {
            return At.fromCode(5115, e);
        }
        static mfaAlreadyEnabled(e = "") {
            return At.fromCode(5116, e);
        }
        static mfaNotEnabled(e = "") {
            return At.fromCode(5117, e);
        }
    }
    he(At, "messages", {
        5e3: "Custom",
        5111: "Invalid login params",
        5112: "User not logged in.",
        5113: "login popup has been closed by the user",
        5114: "Login failed",
        5115: "Popup was blocked. Please call this function as soon as user clicks button or use redirect mode",
        5116: "MFA already enabled",
        5117: "MFA not yet enabled. Please call `enableMFA` first"
    });
    const w6 = "https://api.web3auth.io/session-service", x6 = "https://session.web3auth.io", Cr = Object.create(null);
    Cr.open = "0";
    Cr.close = "1";
    Cr.ping = "2";
    Cr.pong = "3";
    Cr.message = "4";
    Cr.upgrade = "5";
    Cr.noop = "6";
    const Xi = Object.create(null);
    Object.keys(Cr).forEach((r)=>{
        Xi[Cr[r]] = r;
    });
    const Ho = {
        type: "error",
        data: "parser error"
    }, rl = typeof Blob == "function" || typeof Blob < "u" && Object.prototype.toString.call(Blob) === "[object BlobConstructor]", nl = typeof ArrayBuffer == "function", il = (r)=>typeof ArrayBuffer.isView == "function" ? ArrayBuffer.isView(r) : r && r.buffer instanceof ArrayBuffer, Nf = ({ type: r, data: e }, t, n)=>rl && e instanceof Blob ? t ? n(e) : Md(e, n) : nl && (e instanceof ArrayBuffer || il(e)) ? t ? n(e) : Md(new Blob([
            e
        ]), n) : n(Cr[r] + (e || "")), Md = (r, e)=>{
        const t = new FileReader;
        return t.onload = function() {
            const n = t.result.split(",")[1];
            e("b" + (n || ""));
        }, t.readAsDataURL(r);
    };
    function Rd(r) {
        return r instanceof Uint8Array ? r : r instanceof ArrayBuffer ? new Uint8Array(r) : new Uint8Array(r.buffer, r.byteOffset, r.byteLength);
    }
    let Fs;
    function _6(r, e) {
        if (rl && r.data instanceof Blob) return r.data.arrayBuffer().then(Rd).then(e);
        if (nl && (r.data instanceof ArrayBuffer || il(r.data))) return e(Rd(r.data));
        Nf(r, !1, (t)=>{
            Fs || (Fs = new TextEncoder), e(Fs.encode(t));
        });
    }
    const Td = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", ni = typeof Uint8Array > "u" ? [] : new Uint8Array(256);
    for(let r = 0; r < Td.length; r++)ni[Td.charCodeAt(r)] = r;
    const S6 = (r)=>{
        let e = r.length * .75, t = r.length, n, a = 0, i, s, o, f;
        r[r.length - 1] === "=" && (e--, r[r.length - 2] === "=" && e--);
        const c = new ArrayBuffer(e), h = new Uint8Array(c);
        for(n = 0; n < t; n += 4)i = ni[r.charCodeAt(n)], s = ni[r.charCodeAt(n + 1)], o = ni[r.charCodeAt(n + 2)], f = ni[r.charCodeAt(n + 3)], h[a++] = i << 2 | s >> 4, h[a++] = (s & 15) << 4 | o >> 2, h[a++] = (o & 3) << 6 | f & 63;
        return c;
    }, E6 = typeof ArrayBuffer == "function", Cf = (r, e)=>{
        if (typeof r != "string") return {
            type: "message",
            data: al(r, e)
        };
        const t = r.charAt(0);
        return t === "b" ? {
            type: "message",
            data: A6(r.substring(1), e)
        } : Xi[t] ? r.length > 1 ? {
            type: Xi[t],
            data: r.substring(1)
        } : {
            type: Xi[t]
        } : Ho;
    }, A6 = (r, e)=>{
        if (E6) {
            const t = S6(r);
            return al(t, e);
        } else return {
            base64: !0,
            data: r
        };
    }, al = (r, e)=>{
        switch(e){
            case "blob":
                return r instanceof Blob ? r : new Blob([
                    r
                ]);
            case "arraybuffer":
            default:
                return r instanceof ArrayBuffer ? r : r.buffer;
        }
    }, sl = "", I6 = (r, e)=>{
        const t = r.length, n = new Array(t);
        let a = 0;
        r.forEach((i, s)=>{
            Nf(i, !1, (o)=>{
                n[s] = o, ++a === t && e(n.join(sl));
            });
        });
    }, M6 = (r, e)=>{
        const t = r.split(sl), n = [];
        for(let a = 0; a < t.length; a++){
            const i = Cf(t[a], e);
            if (n.push(i), i.type === "error") break;
        }
        return n;
    };
    function R6() {
        return new TransformStream({
            transform (r, e) {
                _6(r, (t)=>{
                    const n = t.length;
                    let a;
                    if (n < 126) a = new Uint8Array(1), new DataView(a.buffer).setUint8(0, n);
                    else if (n < 65536) {
                        a = new Uint8Array(3);
                        const i = new DataView(a.buffer);
                        i.setUint8(0, 126), i.setUint16(1, n);
                    } else {
                        a = new Uint8Array(9);
                        const i = new DataView(a.buffer);
                        i.setUint8(0, 127), i.setBigUint64(1, BigInt(n));
                    }
                    r.data && typeof r.data != "string" && (a[0] |= 128), e.enqueue(a), e.enqueue(t);
                });
            }
        });
    }
    let $s;
    function Ui(r) {
        return r.reduce((e, t)=>e + t.length, 0);
    }
    function qi(r, e) {
        if (r[0].length === e) return r.shift();
        const t = new Uint8Array(e);
        let n = 0;
        for(let a = 0; a < e; a++)t[a] = r[0][n++], n === r[0].length && (r.shift(), n = 0);
        return r.length && n < r[0].length && (r[0] = r[0].slice(n)), t;
    }
    function T6(r, e) {
        $s || ($s = new TextDecoder);
        const t = [];
        let n = 0, a = -1, i = !1;
        return new TransformStream({
            transform (s, o) {
                for(t.push(s);;){
                    if (n === 0) {
                        if (Ui(t) < 1) break;
                        const f = qi(t, 1);
                        i = (f[0] & 128) === 128, a = f[0] & 127, a < 126 ? n = 3 : a === 126 ? n = 1 : n = 2;
                    } else if (n === 1) {
                        if (Ui(t) < 2) break;
                        const f = qi(t, 2);
                        a = new DataView(f.buffer, f.byteOffset, f.length).getUint16(0), n = 3;
                    } else if (n === 2) {
                        if (Ui(t) < 8) break;
                        const f = qi(t, 8), c = new DataView(f.buffer, f.byteOffset, f.length), h = c.getUint32(0);
                        if (h > Math.pow(2, 21) - 1) {
                            o.enqueue(Ho);
                            break;
                        }
                        a = h * Math.pow(2, 32) + c.getUint32(4), n = 3;
                    } else {
                        if (Ui(t) < a) break;
                        const f = qi(t, a);
                        o.enqueue(Cf(i ? f : $s.decode(f), e)), n = 0;
                    }
                    if (a === 0 || a > r) {
                        o.enqueue(Ho);
                        break;
                    }
                }
            }
        });
    }
    const ol = 4;
    function jt(r) {
        if (r) return P6(r);
    }
    function P6(r) {
        for(var e in jt.prototype)r[e] = jt.prototype[e];
        return r;
    }
    jt.prototype.on = jt.prototype.addEventListener = function(r, e) {
        return this._callbacks = this._callbacks || {}, (this._callbacks["$" + r] = this._callbacks["$" + r] || []).push(e), this;
    };
    jt.prototype.once = function(r, e) {
        function t() {
            this.off(r, t), e.apply(this, arguments);
        }
        return t.fn = e, this.on(r, t), this;
    };
    jt.prototype.off = jt.prototype.removeListener = jt.prototype.removeAllListeners = jt.prototype.removeEventListener = function(r, e) {
        if (this._callbacks = this._callbacks || {}, arguments.length == 0) return this._callbacks = {}, this;
        var t = this._callbacks["$" + r];
        if (!t) return this;
        if (arguments.length == 1) return delete this._callbacks["$" + r], this;
        for(var n, a = 0; a < t.length; a++)if (n = t[a], n === e || n.fn === e) {
            t.splice(a, 1);
            break;
        }
        return t.length === 0 && delete this._callbacks["$" + r], this;
    };
    jt.prototype.emit = function(r) {
        this._callbacks = this._callbacks || {};
        for(var e = new Array(arguments.length - 1), t = this._callbacks["$" + r], n = 1; n < arguments.length; n++)e[n - 1] = arguments[n];
        if (t) {
            t = t.slice(0);
            for(var n = 0, a = t.length; n < a; ++n)t[n].apply(this, e);
        }
        return this;
    };
    jt.prototype.emitReserved = jt.prototype.emit;
    jt.prototype.listeners = function(r) {
        return this._callbacks = this._callbacks || {}, this._callbacks["$" + r] || [];
    };
    jt.prototype.hasListeners = function(r) {
        return !!this.listeners(r).length;
    };
    const Na = typeof Promise == "function" && typeof Promise.resolve == "function" ? (e)=>Promise.resolve().then(e) : (e, t)=>t(e, 0), gr = typeof self < "u" ? self : typeof window < "u" ? window : Function("return this")(), B6 = "arraybuffer";
    function fl(r, ...e) {
        return e.reduce((t, n)=>(r.hasOwnProperty(n) && (t[n] = r[n]), t), {});
    }
    const O6 = gr.setTimeout, k6 = gr.clearTimeout;
    function Ca(r, e) {
        e.useNativeTimers ? (r.setTimeoutFn = O6.bind(gr), r.clearTimeoutFn = k6.bind(gr)) : (r.setTimeoutFn = gr.setTimeout.bind(gr), r.clearTimeoutFn = gr.clearTimeout.bind(gr));
    }
    const N6 = 1.33;
    function C6(r) {
        return typeof r == "string" ? L6(r) : Math.ceil((r.byteLength || r.size) * N6);
    }
    function L6(r) {
        let e = 0, t = 0;
        for(let n = 0, a = r.length; n < a; n++)e = r.charCodeAt(n), e < 128 ? t += 1 : e < 2048 ? t += 2 : e < 55296 || e >= 57344 ? t += 3 : (n++, t += 4);
        return t;
    }
    function cl() {
        return Date.now().toString(36).substring(3) + Math.random().toString(36).substring(2, 5);
    }
    function U6(r) {
        let e = "";
        for(let t in r)r.hasOwnProperty(t) && (e.length && (e += "&"), e += encodeURIComponent(t) + "=" + encodeURIComponent(r[t]));
        return e;
    }
    function q6(r) {
        let e = {}, t = r.split("&");
        for(let n = 0, a = t.length; n < a; n++){
            let i = t[n].split("=");
            e[decodeURIComponent(i[0])] = decodeURIComponent(i[1]);
        }
        return e;
    }
    class D6 extends Error {
        constructor(e, t, n){
            super(e), this.description = t, this.context = n, this.type = "TransportError";
        }
    }
    class Lf extends jt {
        constructor(e){
            super(), this.writable = !1, Ca(this, e), this.opts = e, this.query = e.query, this.socket = e.socket, this.supportsBinary = !e.forceBase64;
        }
        onError(e, t, n) {
            return super.emitReserved("error", new D6(e, t, n)), this;
        }
        open() {
            return this.readyState = "opening", this.doOpen(), this;
        }
        close() {
            return (this.readyState === "opening" || this.readyState === "open") && (this.doClose(), this.onClose()), this;
        }
        send(e) {
            this.readyState === "open" && this.write(e);
        }
        onOpen() {
            this.readyState = "open", this.writable = !0, super.emitReserved("open");
        }
        onData(e) {
            const t = Cf(e, this.socket.binaryType);
            this.onPacket(t);
        }
        onPacket(e) {
            super.emitReserved("packet", e);
        }
        onClose(e) {
            this.readyState = "closed", super.emitReserved("close", e);
        }
        pause(e) {}
        createUri(e, t = {}) {
            return e + "://" + this._hostname() + this._port() + this.opts.path + this._query(t);
        }
        _hostname() {
            const e = this.opts.hostname;
            return e.indexOf(":") === -1 ? e : "[" + e + "]";
        }
        _port() {
            return this.opts.port && (this.opts.secure && Number(this.opts.port) !== 443 || !this.opts.secure && Number(this.opts.port) !== 80) ? ":" + this.opts.port : "";
        }
        _query(e) {
            const t = U6(e);
            return t.length ? "?" + t : "";
        }
    }
    class F6 extends Lf {
        constructor(){
            super(...arguments), this._polling = !1;
        }
        get name() {
            return "polling";
        }
        doOpen() {
            this._poll();
        }
        pause(e) {
            this.readyState = "pausing";
            const t = ()=>{
                this.readyState = "paused", e();
            };
            if (this._polling || !this.writable) {
                let n = 0;
                this._polling && (n++, this.once("pollComplete", function() {
                    --n || t();
                })), this.writable || (n++, this.once("drain", function() {
                    --n || t();
                }));
            } else t();
        }
        _poll() {
            this._polling = !0, this.doPoll(), this.emitReserved("poll");
        }
        onData(e) {
            const t = (n)=>{
                if (this.readyState === "opening" && n.type === "open" && this.onOpen(), n.type === "close") return this.onClose({
                    description: "transport closed by the server"
                }), !1;
                this.onPacket(n);
            };
            M6(e, this.socket.binaryType).forEach(t), this.readyState !== "closed" && (this._polling = !1, this.emitReserved("pollComplete"), this.readyState === "open" && this._poll());
        }
        doClose() {
            const e = ()=>{
                this.write([
                    {
                        type: "close"
                    }
                ]);
            };
            this.readyState === "open" ? e() : this.once("open", e);
        }
        write(e) {
            this.writable = !1, I6(e, (t)=>{
                this.doWrite(t, ()=>{
                    this.writable = !0, this.emitReserved("drain");
                });
            });
        }
        uri() {
            const e = this.opts.secure ? "https" : "http", t = this.query || {};
            return this.opts.timestampRequests !== !1 && (t[this.opts.timestampParam] = cl()), !this.supportsBinary && !t.sid && (t.b64 = 1), this.createUri(e, t);
        }
    }
    let dl = !1;
    try {
        dl = typeof XMLHttpRequest < "u" && "withCredentials" in new XMLHttpRequest;
    } catch  {}
    const $6 = dl;
    function K6() {}
    class j6 extends F6 {
        constructor(e){
            if (super(e), typeof location < "u") {
                const t = location.protocol === "https:";
                let n = location.port;
                n || (n = t ? "443" : "80"), this.xd = typeof location < "u" && e.hostname !== location.hostname || n !== e.port;
            }
        }
        doWrite(e, t) {
            const n = this.request({
                method: "POST",
                data: e
            });
            n.on("success", t), n.on("error", (a, i)=>{
                this.onError("xhr post error", a, i);
            });
        }
        doPoll() {
            const e = this.request();
            e.on("data", this.onData.bind(this)), e.on("error", (t, n)=>{
                this.onError("xhr poll error", t, n);
            }), this.pollXhr = e;
        }
    }
    class Or extends jt {
        constructor(e, t, n){
            super(), this.createRequest = e, Ca(this, n), this._opts = n, this._method = n.method || "GET", this._uri = t, this._data = n.data !== void 0 ? n.data : null, this._create();
        }
        _create() {
            var e;
            const t = fl(this._opts, "agent", "pfx", "key", "passphrase", "cert", "ca", "ciphers", "rejectUnauthorized", "autoUnref");
            t.xdomain = !!this._opts.xd;
            const n = this._xhr = this.createRequest(t);
            try {
                n.open(this._method, this._uri, !0);
                try {
                    if (this._opts.extraHeaders) {
                        n.setDisableHeaderCheck && n.setDisableHeaderCheck(!0);
                        for(let a in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(a) && n.setRequestHeader(a, this._opts.extraHeaders[a]);
                    }
                } catch  {}
                if (this._method === "POST") try {
                    n.setRequestHeader("Content-type", "text/plain;charset=UTF-8");
                } catch  {}
                try {
                    n.setRequestHeader("Accept", "*/*");
                } catch  {}
                (e = this._opts.cookieJar) === null || e === void 0 || e.addCookies(n), "withCredentials" in n && (n.withCredentials = this._opts.withCredentials), this._opts.requestTimeout && (n.timeout = this._opts.requestTimeout), n.onreadystatechange = ()=>{
                    var a;
                    n.readyState === 3 && ((a = this._opts.cookieJar) === null || a === void 0 || a.parseCookies(n.getResponseHeader("set-cookie"))), n.readyState === 4 && (n.status === 200 || n.status === 1223 ? this._onLoad() : this.setTimeoutFn(()=>{
                        this._onError(typeof n.status == "number" ? n.status : 0);
                    }, 0));
                }, n.send(this._data);
            } catch (a) {
                this.setTimeoutFn(()=>{
                    this._onError(a);
                }, 0);
                return;
            }
            typeof document < "u" && (this._index = Or.requestsCount++, Or.requests[this._index] = this);
        }
        _onError(e) {
            this.emitReserved("error", e, this._xhr), this._cleanup(!0);
        }
        _cleanup(e) {
            if (!(typeof this._xhr > "u" || this._xhr === null)) {
                if (this._xhr.onreadystatechange = K6, e) try {
                    this._xhr.abort();
                } catch  {}
                typeof document < "u" && delete Or.requests[this._index], this._xhr = null;
            }
        }
        _onLoad() {
            const e = this._xhr.responseText;
            e !== null && (this.emitReserved("data", e), this.emitReserved("success"), this._cleanup());
        }
        abort() {
            this._cleanup();
        }
    }
    Or.requestsCount = 0;
    Or.requests = {};
    if (typeof document < "u") {
        if (typeof attachEvent == "function") attachEvent("onunload", Pd);
        else if (typeof addEventListener == "function") {
            const r = "onpagehide" in gr ? "pagehide" : "unload";
            addEventListener(r, Pd, !1);
        }
    }
    function Pd() {
        for(let r in Or.requests)Or.requests.hasOwnProperty(r) && Or.requests[r].abort();
    }
    const H6 = (function() {
        const r = ul({
            xdomain: !1
        });
        return r && r.responseType !== null;
    })();
    class z6 extends j6 {
        constructor(e){
            super(e);
            const t = e && e.forceBase64;
            this.supportsBinary = H6 && !t;
        }
        request(e = {}) {
            return Object.assign(e, {
                xd: this.xd
            }, this.opts), new Or(ul, this.uri(), e);
        }
    }
    function ul(r) {
        const e = r.xdomain;
        try {
            if (typeof XMLHttpRequest < "u" && (!e || $6)) return new XMLHttpRequest;
        } catch  {}
        if (!e) try {
            return new gr[[
                "Active"
            ].concat("Object").join("X")]("Microsoft.XMLHTTP");
        } catch  {}
    }
    const ll = typeof navigator < "u" && typeof navigator.product == "string" && navigator.product.toLowerCase() === "reactnative";
    class W6 extends Lf {
        get name() {
            return "websocket";
        }
        doOpen() {
            const e = this.uri(), t = this.opts.protocols, n = ll ? {} : fl(this.opts, "agent", "perMessageDeflate", "pfx", "key", "passphrase", "cert", "ca", "ciphers", "rejectUnauthorized", "localAddress", "protocolVersion", "origin", "maxPayload", "family", "checkServerIdentity");
            this.opts.extraHeaders && (n.headers = this.opts.extraHeaders);
            try {
                this.ws = this.createSocket(e, t, n);
            } catch (a) {
                return this.emitReserved("error", a);
            }
            this.ws.binaryType = this.socket.binaryType, this.addEventListeners();
        }
        addEventListeners() {
            this.ws.onopen = ()=>{
                this.opts.autoUnref && this.ws._socket.unref(), this.onOpen();
            }, this.ws.onclose = (e)=>this.onClose({
                    description: "websocket connection closed",
                    context: e
                }), this.ws.onmessage = (e)=>this.onData(e.data), this.ws.onerror = (e)=>this.onError("websocket error", e);
        }
        write(e) {
            this.writable = !1;
            for(let t = 0; t < e.length; t++){
                const n = e[t], a = t === e.length - 1;
                Nf(n, this.supportsBinary, (i)=>{
                    try {
                        this.doWrite(n, i);
                    } catch  {}
                    a && Na(()=>{
                        this.writable = !0, this.emitReserved("drain");
                    }, this.setTimeoutFn);
                });
            }
        }
        doClose() {
            typeof this.ws < "u" && (this.ws.onerror = ()=>{}, this.ws.close(), this.ws = null);
        }
        uri() {
            const e = this.opts.secure ? "wss" : "ws", t = this.query || {};
            return this.opts.timestampRequests && (t[this.opts.timestampParam] = cl()), this.supportsBinary || (t.b64 = 1), this.createUri(e, t);
        }
    }
    const Ks = gr.WebSocket || gr.MozWebSocket;
    class Y6 extends W6 {
        createSocket(e, t, n) {
            return ll ? new Ks(e, t, n) : t ? new Ks(e, t) : new Ks(e);
        }
        doWrite(e, t) {
            this.ws.send(t);
        }
    }
    class V6 extends Lf {
        get name() {
            return "webtransport";
        }
        doOpen() {
            try {
                this._transport = new WebTransport(this.createUri("https"), this.opts.transportOptions[this.name]);
            } catch (e) {
                return this.emitReserved("error", e);
            }
            this._transport.closed.then(()=>{
                this.onClose();
            }).catch((e)=>{
                this.onError("webtransport error", e);
            }), this._transport.ready.then(()=>{
                this._transport.createBidirectionalStream().then((e)=>{
                    const t = T6(Number.MAX_SAFE_INTEGER, this.socket.binaryType), n = e.readable.pipeThrough(t).getReader(), a = R6();
                    a.readable.pipeTo(e.writable), this._writer = a.writable.getWriter();
                    const i = ()=>{
                        n.read().then(({ done: o, value: f })=>{
                            o || (this.onPacket(f), i());
                        }).catch((o)=>{});
                    };
                    i();
                    const s = {
                        type: "open"
                    };
                    this.query.sid && (s.data = `{"sid":"${this.query.sid}"}`), this._writer.write(s).then(()=>this.onOpen());
                });
            });
        }
        write(e) {
            this.writable = !1;
            for(let t = 0; t < e.length; t++){
                const n = e[t], a = t === e.length - 1;
                this._writer.write(n).then(()=>{
                    a && Na(()=>{
                        this.writable = !0, this.emitReserved("drain");
                    }, this.setTimeoutFn);
                });
            }
        }
        doClose() {
            var e;
            (e = this._transport) === null || e === void 0 || e.close();
        }
    }
    const G6 = {
        websocket: Y6,
        webtransport: V6,
        polling: z6
    }, J6 = /^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/, X6 = [
        "source",
        "protocol",
        "authority",
        "userInfo",
        "user",
        "password",
        "host",
        "port",
        "relative",
        "path",
        "directory",
        "file",
        "query",
        "anchor"
    ];
    function zo(r) {
        if (r.length > 8e3) throw "URI too long";
        const e = r, t = r.indexOf("["), n = r.indexOf("]");
        t != -1 && n != -1 && (r = r.substring(0, t) + r.substring(t, n).replace(/:/g, ";") + r.substring(n, r.length));
        let a = J6.exec(r || ""), i = {}, s = 14;
        for(; s--;)i[X6[s]] = a[s] || "";
        return t != -1 && n != -1 && (i.source = e, i.host = i.host.substring(1, i.host.length - 1).replace(/;/g, ":"), i.authority = i.authority.replace("[", "").replace("]", "").replace(/;/g, ":"), i.ipv6uri = !0), i.pathNames = Z6(i, i.path), i.queryKey = Q6(i, i.query), i;
    }
    function Z6(r, e) {
        const t = /\/{2,9}/g, n = e.replace(t, "/").split("/");
        return (e.slice(0, 1) == "/" || e.length === 0) && n.splice(0, 1), e.slice(-1) == "/" && n.splice(n.length - 1, 1), n;
    }
    function Q6(r, e) {
        const t = {};
        return e.replace(/(?:^|&)([^&=]*)=?([^&]*)/g, function(n, a, i) {
            a && (t[a] = i);
        }), t;
    }
    const Wo = typeof addEventListener == "function" && typeof removeEventListener == "function", Zi = [];
    Wo && addEventListener("offline", ()=>{
        Zi.forEach((r)=>r());
    }, !1);
    class dn extends jt {
        constructor(e, t){
            if (super(), this.binaryType = B6, this.writeBuffer = [], this._prevBufferLen = 0, this._pingInterval = -1, this._pingTimeout = -1, this._maxPayload = -1, this._pingTimeoutTime = 1 / 0, e && typeof e == "object" && (t = e, e = null), e) {
                const n = zo(e);
                t.hostname = n.host, t.secure = n.protocol === "https" || n.protocol === "wss", t.port = n.port, n.query && (t.query = n.query);
            } else t.host && (t.hostname = zo(t.host).host);
            Ca(this, t), this.secure = t.secure != null ? t.secure : typeof location < "u" && location.protocol === "https:", t.hostname && !t.port && (t.port = this.secure ? "443" : "80"), this.hostname = t.hostname || (typeof location < "u" ? location.hostname : "localhost"), this.port = t.port || (typeof location < "u" && location.port ? location.port : this.secure ? "443" : "80"), this.transports = [], this._transportsByName = {}, t.transports.forEach((n)=>{
                const a = n.prototype.name;
                this.transports.push(a), this._transportsByName[a] = n;
            }), this.opts = Object.assign({
                path: "/engine.io",
                agent: !1,
                withCredentials: !1,
                upgrade: !0,
                timestampParam: "t",
                rememberUpgrade: !1,
                addTrailingSlash: !0,
                rejectUnauthorized: !0,
                perMessageDeflate: {
                    threshold: 1024
                },
                transportOptions: {},
                closeOnBeforeunload: !1
            }, t), this.opts.path = this.opts.path.replace(/\/$/, "") + (this.opts.addTrailingSlash ? "/" : ""), typeof this.opts.query == "string" && (this.opts.query = q6(this.opts.query)), Wo && (this.opts.closeOnBeforeunload && (this._beforeunloadEventListener = ()=>{
                this.transport && (this.transport.removeAllListeners(), this.transport.close());
            }, addEventListener("beforeunload", this._beforeunloadEventListener, !1)), this.hostname !== "localhost" && (this._offlineEventListener = ()=>{
                this._onClose("transport close", {
                    description: "network connection lost"
                });
            }, Zi.push(this._offlineEventListener))), this.opts.withCredentials && (this._cookieJar = void 0), this._open();
        }
        createTransport(e) {
            const t = Object.assign({}, this.opts.query);
            t.EIO = ol, t.transport = e, this.id && (t.sid = this.id);
            const n = Object.assign({}, this.opts, {
                query: t,
                socket: this,
                hostname: this.hostname,
                secure: this.secure,
                port: this.port
            }, this.opts.transportOptions[e]);
            return new this._transportsByName[e](n);
        }
        _open() {
            if (this.transports.length === 0) {
                this.setTimeoutFn(()=>{
                    this.emitReserved("error", "No transports available");
                }, 0);
                return;
            }
            const e = this.opts.rememberUpgrade && dn.priorWebsocketSuccess && this.transports.indexOf("websocket") !== -1 ? "websocket" : this.transports[0];
            this.readyState = "opening";
            const t = this.createTransport(e);
            t.open(), this.setTransport(t);
        }
        setTransport(e) {
            this.transport && this.transport.removeAllListeners(), this.transport = e, e.on("drain", this._onDrain.bind(this)).on("packet", this._onPacket.bind(this)).on("error", this._onError.bind(this)).on("close", (t)=>this._onClose("transport close", t));
        }
        onOpen() {
            this.readyState = "open", dn.priorWebsocketSuccess = this.transport.name === "websocket", this.emitReserved("open"), this.flush();
        }
        _onPacket(e) {
            if (this.readyState === "opening" || this.readyState === "open" || this.readyState === "closing") switch(this.emitReserved("packet", e), this.emitReserved("heartbeat"), e.type){
                case "open":
                    this.onHandshake(JSON.parse(e.data));
                    break;
                case "ping":
                    this._sendPacket("pong"), this.emitReserved("ping"), this.emitReserved("pong"), this._resetPingTimeout();
                    break;
                case "error":
                    const t = new Error("server error");
                    t.code = e.data, this._onError(t);
                    break;
                case "message":
                    this.emitReserved("data", e.data), this.emitReserved("message", e.data);
                    break;
            }
        }
        onHandshake(e) {
            this.emitReserved("handshake", e), this.id = e.sid, this.transport.query.sid = e.sid, this._pingInterval = e.pingInterval, this._pingTimeout = e.pingTimeout, this._maxPayload = e.maxPayload, this.onOpen(), this.readyState !== "closed" && this._resetPingTimeout();
        }
        _resetPingTimeout() {
            this.clearTimeoutFn(this._pingTimeoutTimer);
            const e = this._pingInterval + this._pingTimeout;
            this._pingTimeoutTime = Date.now() + e, this._pingTimeoutTimer = this.setTimeoutFn(()=>{
                this._onClose("ping timeout");
            }, e), this.opts.autoUnref && this._pingTimeoutTimer.unref();
        }
        _onDrain() {
            this.writeBuffer.splice(0, this._prevBufferLen), this._prevBufferLen = 0, this.writeBuffer.length === 0 ? this.emitReserved("drain") : this.flush();
        }
        flush() {
            if (this.readyState !== "closed" && this.transport.writable && !this.upgrading && this.writeBuffer.length) {
                const e = this._getWritablePackets();
                this.transport.send(e), this._prevBufferLen = e.length, this.emitReserved("flush");
            }
        }
        _getWritablePackets() {
            if (!(this._maxPayload && this.transport.name === "polling" && this.writeBuffer.length > 1)) return this.writeBuffer;
            let t = 1;
            for(let n = 0; n < this.writeBuffer.length; n++){
                const a = this.writeBuffer[n].data;
                if (a && (t += C6(a)), n > 0 && t > this._maxPayload) return this.writeBuffer.slice(0, n);
                t += 2;
            }
            return this.writeBuffer;
        }
        _hasPingExpired() {
            if (!this._pingTimeoutTime) return !0;
            const e = Date.now() > this._pingTimeoutTime;
            return e && (this._pingTimeoutTime = 0, Na(()=>{
                this._onClose("ping timeout");
            }, this.setTimeoutFn)), e;
        }
        write(e, t, n) {
            return this._sendPacket("message", e, t, n), this;
        }
        send(e, t, n) {
            return this._sendPacket("message", e, t, n), this;
        }
        _sendPacket(e, t, n, a) {
            if (typeof t == "function" && (a = t, t = void 0), typeof n == "function" && (a = n, n = null), this.readyState === "closing" || this.readyState === "closed") return;
            n = n || {}, n.compress = n.compress !== !1;
            const i = {
                type: e,
                data: t,
                options: n
            };
            this.emitReserved("packetCreate", i), this.writeBuffer.push(i), a && this.once("flush", a), this.flush();
        }
        close() {
            const e = ()=>{
                this._onClose("forced close"), this.transport.close();
            }, t = ()=>{
                this.off("upgrade", t), this.off("upgradeError", t), e();
            }, n = ()=>{
                this.once("upgrade", t), this.once("upgradeError", t);
            };
            return (this.readyState === "opening" || this.readyState === "open") && (this.readyState = "closing", this.writeBuffer.length ? this.once("drain", ()=>{
                this.upgrading ? n() : e();
            }) : this.upgrading ? n() : e()), this;
        }
        _onError(e) {
            if (dn.priorWebsocketSuccess = !1, this.opts.tryAllTransports && this.transports.length > 1 && this.readyState === "opening") return this.transports.shift(), this._open();
            this.emitReserved("error", e), this._onClose("transport error", e);
        }
        _onClose(e, t) {
            if (this.readyState === "opening" || this.readyState === "open" || this.readyState === "closing") {
                if (this.clearTimeoutFn(this._pingTimeoutTimer), this.transport.removeAllListeners("close"), this.transport.close(), this.transport.removeAllListeners(), Wo && (this._beforeunloadEventListener && removeEventListener("beforeunload", this._beforeunloadEventListener, !1), this._offlineEventListener)) {
                    const n = Zi.indexOf(this._offlineEventListener);
                    n !== -1 && Zi.splice(n, 1);
                }
                this.readyState = "closed", this.id = null, this.emitReserved("close", e, t), this.writeBuffer = [], this._prevBufferLen = 0;
            }
        }
    }
    dn.protocol = ol;
    class e3 extends dn {
        constructor(){
            super(...arguments), this._upgrades = [];
        }
        onOpen() {
            if (super.onOpen(), this.readyState === "open" && this.opts.upgrade) for(let e = 0; e < this._upgrades.length; e++)this._probe(this._upgrades[e]);
        }
        _probe(e) {
            let t = this.createTransport(e), n = !1;
            dn.priorWebsocketSuccess = !1;
            const a = ()=>{
                n || (t.send([
                    {
                        type: "ping",
                        data: "probe"
                    }
                ]), t.once("packet", (g)=>{
                    if (!n) if (g.type === "pong" && g.data === "probe") {
                        if (this.upgrading = !0, this.emitReserved("upgrading", t), !t) return;
                        dn.priorWebsocketSuccess = t.name === "websocket", this.transport.pause(()=>{
                            n || this.readyState !== "closed" && (h(), this.setTransport(t), t.send([
                                {
                                    type: "upgrade"
                                }
                            ]), this.emitReserved("upgrade", t), t = null, this.upgrading = !1, this.flush());
                        });
                    } else {
                        const v = new Error("probe error");
                        v.transport = t.name, this.emitReserved("upgradeError", v);
                    }
                }));
            };
            function i() {
                n || (n = !0, h(), t.close(), t = null);
            }
            const s = (g)=>{
                const v = new Error("probe error: " + g);
                v.transport = t.name, i(), this.emitReserved("upgradeError", v);
            };
            function o() {
                s("transport closed");
            }
            function f() {
                s("socket closed");
            }
            function c(g) {
                t && g.name !== t.name && i();
            }
            const h = ()=>{
                t.removeListener("open", a), t.removeListener("error", s), t.removeListener("close", o), this.off("close", f), this.off("upgrading", c);
            };
            t.once("open", a), t.once("error", s), t.once("close", o), this.once("close", f), this.once("upgrading", c), this._upgrades.indexOf("webtransport") !== -1 && e !== "webtransport" ? this.setTimeoutFn(()=>{
                n || t.open();
            }, 200) : t.open();
        }
        onHandshake(e) {
            this._upgrades = this._filterUpgrades(e.upgrades), super.onHandshake(e);
        }
        _filterUpgrades(e) {
            const t = [];
            for(let n = 0; n < e.length; n++)~this.transports.indexOf(e[n]) && t.push(e[n]);
            return t;
        }
    }
    let t3 = class extends e3 {
        constructor(e, t = {}){
            const n = typeof e == "object" ? e : t;
            (!n.transports || n.transports && typeof n.transports[0] == "string") && (n.transports = (n.transports || [
                "polling",
                "websocket",
                "webtransport"
            ]).map((a)=>G6[a]).filter((a)=>!!a)), super(e, n);
        }
    };
    function r3(r, e = "", t) {
        let n = r;
        t = t || typeof location < "u" && location, r == null && (r = t.protocol + "//" + t.host), typeof r == "string" && (r.charAt(0) === "/" && (r.charAt(1) === "/" ? r = t.protocol + r : r = t.host + r), /^(https?|wss?):\/\//.test(r) || (typeof t < "u" ? r = t.protocol + "//" + r : r = "https://" + r), n = zo(r)), n.port || (/^(http|ws)$/.test(n.protocol) ? n.port = "80" : /^(http|ws)s$/.test(n.protocol) && (n.port = "443")), n.path = n.path || "/";
        const i = n.host.indexOf(":") !== -1 ? "[" + n.host + "]" : n.host;
        return n.id = n.protocol + "://" + i + ":" + n.port + e, n.href = n.protocol + "://" + i + (t && t.port === n.port ? "" : ":" + n.port), n;
    }
    const n3 = typeof ArrayBuffer == "function", i3 = (r)=>typeof ArrayBuffer.isView == "function" ? ArrayBuffer.isView(r) : r.buffer instanceof ArrayBuffer, hl = Object.prototype.toString, a3 = typeof Blob == "function" || typeof Blob < "u" && hl.call(Blob) === "[object BlobConstructor]", s3 = typeof File == "function" || typeof File < "u" && hl.call(File) === "[object FileConstructor]";
    function Uf(r) {
        return n3 && (r instanceof ArrayBuffer || i3(r)) || a3 && r instanceof Blob || s3 && r instanceof File;
    }
    function Qi(r, e) {
        if (!r || typeof r != "object") return !1;
        if (Array.isArray(r)) {
            for(let t = 0, n = r.length; t < n; t++)if (Qi(r[t])) return !0;
            return !1;
        }
        if (Uf(r)) return !0;
        if (r.toJSON && typeof r.toJSON == "function" && arguments.length === 1) return Qi(r.toJSON(), !0);
        for(const t in r)if (Object.prototype.hasOwnProperty.call(r, t) && Qi(r[t])) return !0;
        return !1;
    }
    function o3(r) {
        const e = [], t = r.data, n = r;
        return n.data = Yo(t, e), n.attachments = e.length, {
            packet: n,
            buffers: e
        };
    }
    function Yo(r, e) {
        if (!r) return r;
        if (Uf(r)) {
            const t = {
                _placeholder: !0,
                num: e.length
            };
            return e.push(r), t;
        } else if (Array.isArray(r)) {
            const t = new Array(r.length);
            for(let n = 0; n < r.length; n++)t[n] = Yo(r[n], e);
            return t;
        } else if (typeof r == "object" && !(r instanceof Date)) {
            const t = {};
            for(const n in r)Object.prototype.hasOwnProperty.call(r, n) && (t[n] = Yo(r[n], e));
            return t;
        }
        return r;
    }
    function f3(r, e) {
        return r.data = Vo(r.data, e), delete r.attachments, r;
    }
    function Vo(r, e) {
        if (!r) return r;
        if (r && r._placeholder === !0) {
            if (typeof r.num == "number" && r.num >= 0 && r.num < e.length) return e[r.num];
            throw new Error("illegal attachments");
        } else if (Array.isArray(r)) for(let t = 0; t < r.length; t++)r[t] = Vo(r[t], e);
        else if (typeof r == "object") for(const t in r)Object.prototype.hasOwnProperty.call(r, t) && (r[t] = Vo(r[t], e));
        return r;
    }
    const c3 = [
        "connect",
        "connect_error",
        "disconnect",
        "disconnecting",
        "newListener",
        "removeListener"
    ];
    var gt;
    (function(r) {
        r[r.CONNECT = 0] = "CONNECT", r[r.DISCONNECT = 1] = "DISCONNECT", r[r.EVENT = 2] = "EVENT", r[r.ACK = 3] = "ACK", r[r.CONNECT_ERROR = 4] = "CONNECT_ERROR", r[r.BINARY_EVENT = 5] = "BINARY_EVENT", r[r.BINARY_ACK = 6] = "BINARY_ACK";
    })(gt || (gt = {}));
    class d3 {
        constructor(e){
            this.replacer = e;
        }
        encode(e) {
            return (e.type === gt.EVENT || e.type === gt.ACK) && Qi(e) ? this.encodeAsBinary({
                type: e.type === gt.EVENT ? gt.BINARY_EVENT : gt.BINARY_ACK,
                nsp: e.nsp,
                data: e.data,
                id: e.id
            }) : [
                this.encodeAsString(e)
            ];
        }
        encodeAsString(e) {
            let t = "" + e.type;
            return (e.type === gt.BINARY_EVENT || e.type === gt.BINARY_ACK) && (t += e.attachments + "-"), e.nsp && e.nsp !== "/" && (t += e.nsp + ","), e.id != null && (t += e.id), e.data != null && (t += JSON.stringify(e.data, this.replacer)), t;
        }
        encodeAsBinary(e) {
            const t = o3(e), n = this.encodeAsString(t.packet), a = t.buffers;
            return a.unshift(n), a;
        }
    }
    class qf extends jt {
        constructor(e){
            super(), this.opts = Object.assign({
                reviver: void 0,
                maxAttachments: 10
            }, typeof e == "function" ? {
                reviver: e
            } : e);
        }
        add(e) {
            let t;
            if (typeof e == "string") {
                if (this.reconstructor) throw new Error("got plaintext data when reconstructing a packet");
                t = this.decodeString(e);
                const n = t.type === gt.BINARY_EVENT;
                n || t.type === gt.BINARY_ACK ? (t.type = n ? gt.EVENT : gt.ACK, this.reconstructor = new u3(t), t.attachments === 0 && super.emitReserved("decoded", t)) : super.emitReserved("decoded", t);
            } else if (Uf(e) || e.base64) if (this.reconstructor) t = this.reconstructor.takeBinaryData(e), t && (this.reconstructor = null, super.emitReserved("decoded", t));
            else throw new Error("got binary data when not reconstructing a packet");
            else throw new Error("Unknown type: " + e);
        }
        decodeString(e) {
            let t = 0;
            const n = {
                type: Number(e.charAt(0))
            };
            if (gt[n.type] === void 0) throw new Error("unknown packet type " + n.type);
            if (n.type === gt.BINARY_EVENT || n.type === gt.BINARY_ACK) {
                const i = t + 1;
                for(; e.charAt(++t) !== "-" && t != e.length;);
                const s = e.substring(i, t);
                if (s != Number(s) || e.charAt(t) !== "-") throw new Error("Illegal attachments");
                const o = Number(s);
                if (!l3(o) || o < 0) throw new Error("Illegal attachments");
                if (o > this.opts.maxAttachments) throw new Error("too many attachments");
                n.attachments = o;
            }
            if (e.charAt(t + 1) === "/") {
                const i = t + 1;
                for(; ++t && !(e.charAt(t) === "," || t === e.length););
                n.nsp = e.substring(i, t);
            } else n.nsp = "/";
            const a = e.charAt(t + 1);
            if (a !== "" && Number(a) == a) {
                const i = t + 1;
                for(; ++t;){
                    const s = e.charAt(t);
                    if (s == null || Number(s) != s) {
                        --t;
                        break;
                    }
                    if (t === e.length) break;
                }
                n.id = Number(e.substring(i, t + 1));
            }
            if (e.charAt(++t)) {
                const i = this.tryParse(e.substr(t));
                if (qf.isPayloadValid(n.type, i)) n.data = i;
                else throw new Error("invalid payload");
            }
            return n;
        }
        tryParse(e) {
            try {
                return JSON.parse(e, this.opts.reviver);
            } catch  {
                return !1;
            }
        }
        static isPayloadValid(e, t) {
            switch(e){
                case gt.CONNECT:
                    return Bd(t);
                case gt.DISCONNECT:
                    return t === void 0;
                case gt.CONNECT_ERROR:
                    return typeof t == "string" || Bd(t);
                case gt.EVENT:
                case gt.BINARY_EVENT:
                    return Array.isArray(t) && (typeof t[0] == "number" || typeof t[0] == "string" && c3.indexOf(t[0]) === -1);
                case gt.ACK:
                case gt.BINARY_ACK:
                    return Array.isArray(t);
            }
        }
        destroy() {
            this.reconstructor && (this.reconstructor.finishedReconstruction(), this.reconstructor = null);
        }
    }
    class u3 {
        constructor(e){
            this.packet = e, this.buffers = [], this.reconPack = e;
        }
        takeBinaryData(e) {
            if (this.buffers.push(e), this.buffers.length === this.reconPack.attachments) {
                const t = f3(this.reconPack, this.buffers);
                return this.finishedReconstruction(), t;
            }
            return null;
        }
        finishedReconstruction() {
            this.reconPack = null, this.buffers = [];
        }
    }
    const l3 = Number.isInteger || function(r) {
        return typeof r == "number" && isFinite(r) && Math.floor(r) === r;
    };
    function Bd(r) {
        return Object.prototype.toString.call(r) === "[object Object]";
    }
    const h3 = Object.freeze(Object.defineProperty({
        __proto__: null,
        Decoder: qf,
        Encoder: d3,
        get PacketType () {
            return gt;
        }
    }, Symbol.toStringTag, {
        value: "Module"
    }));
    function xr(r, e, t) {
        return r.on(e, t), function() {
            r.off(e, t);
        };
    }
    const b3 = Object.freeze({
        connect: 1,
        connect_error: 1,
        disconnect: 1,
        disconnecting: 1,
        newListener: 1,
        removeListener: 1
    });
    class bl extends jt {
        constructor(e, t, n){
            super(), this.connected = !1, this.recovered = !1, this.receiveBuffer = [], this.sendBuffer = [], this._queue = [], this._queueSeq = 0, this.ids = 0, this.acks = {}, this.flags = {}, this.io = e, this.nsp = t, n && n.auth && (this.auth = n.auth), this._opts = Object.assign({}, n), this.io._autoConnect && this.open();
        }
        get disconnected() {
            return !this.connected;
        }
        subEvents() {
            if (this.subs) return;
            const e = this.io;
            this.subs = [
                xr(e, "open", this.onopen.bind(this)),
                xr(e, "packet", this.onpacket.bind(this)),
                xr(e, "error", this.onerror.bind(this)),
                xr(e, "close", this.onclose.bind(this))
            ];
        }
        get active() {
            return !!this.subs;
        }
        connect() {
            return this.connected ? this : (this.subEvents(), this.io._reconnecting || this.io.open(), this.io._readyState === "open" && this.onopen(), this);
        }
        open() {
            return this.connect();
        }
        send(...e) {
            return e.unshift("message"), this.emit.apply(this, e), this;
        }
        emit(e, ...t) {
            var n, a, i;
            if (b3.hasOwnProperty(e)) throw new Error('"' + e.toString() + '" is a reserved event name');
            if (t.unshift(e), this._opts.retries && !this.flags.fromQueue && !this.flags.volatile) return this._addToQueue(t), this;
            const s = {
                type: gt.EVENT,
                data: t
            };
            if (s.options = {}, s.options.compress = this.flags.compress !== !1, typeof t[t.length - 1] == "function") {
                const h = this.ids++, g = t.pop();
                this._registerAckCallback(h, g), s.id = h;
            }
            const o = (a = (n = this.io.engine) === null || n === void 0 ? void 0 : n.transport) === null || a === void 0 ? void 0 : a.writable, f = this.connected && !(!((i = this.io.engine) === null || i === void 0) && i._hasPingExpired());
            return this.flags.volatile && !o || (f ? (this.notifyOutgoingListeners(s), this.packet(s)) : this.sendBuffer.push(s)), this.flags = {}, this;
        }
        _registerAckCallback(e, t) {
            var n;
            const a = (n = this.flags.timeout) !== null && n !== void 0 ? n : this._opts.ackTimeout;
            if (a === void 0) {
                this.acks[e] = t;
                return;
            }
            const i = this.io.setTimeoutFn(()=>{
                delete this.acks[e];
                for(let o = 0; o < this.sendBuffer.length; o++)this.sendBuffer[o].id === e && this.sendBuffer.splice(o, 1);
                t.call(this, new Error("operation has timed out"));
            }, a), s = (...o)=>{
                this.io.clearTimeoutFn(i), t.apply(this, o);
            };
            s.withError = !0, this.acks[e] = s;
        }
        emitWithAck(e, ...t) {
            return new Promise((n, a)=>{
                const i = (s, o)=>s ? a(s) : n(o);
                i.withError = !0, t.push(i), this.emit(e, ...t);
            });
        }
        _addToQueue(e) {
            let t;
            typeof e[e.length - 1] == "function" && (t = e.pop());
            const n = {
                id: this._queueSeq++,
                tryCount: 0,
                pending: !1,
                args: e,
                flags: Object.assign({
                    fromQueue: !0
                }, this.flags)
            };
            e.push((a, ...i)=>(this._queue[0], a !== null ? n.tryCount > this._opts.retries && (this._queue.shift(), t && t(a)) : (this._queue.shift(), t && t(null, ...i)), n.pending = !1, this._drainQueue())), this._queue.push(n), this._drainQueue();
        }
        _drainQueue(e = !1) {
            if (!this.connected || this._queue.length === 0) return;
            const t = this._queue[0];
            t.pending && !e || (t.pending = !0, t.tryCount++, this.flags = t.flags, this.emit.apply(this, t.args));
        }
        packet(e) {
            e.nsp = this.nsp, this.io._packet(e);
        }
        onopen() {
            typeof this.auth == "function" ? this.auth((e)=>{
                this._sendConnectPacket(e);
            }) : this._sendConnectPacket(this.auth);
        }
        _sendConnectPacket(e) {
            this.packet({
                type: gt.CONNECT,
                data: this._pid ? Object.assign({
                    pid: this._pid,
                    offset: this._lastOffset
                }, e) : e
            });
        }
        onerror(e) {
            this.connected || this.emitReserved("connect_error", e);
        }
        onclose(e, t) {
            this.connected = !1, delete this.id, this.emitReserved("disconnect", e, t), this._clearAcks();
        }
        _clearAcks() {
            Object.keys(this.acks).forEach((e)=>{
                if (!this.sendBuffer.some((n)=>String(n.id) === e)) {
                    const n = this.acks[e];
                    delete this.acks[e], n.withError && n.call(this, new Error("socket has been disconnected"));
                }
            });
        }
        onpacket(e) {
            if (e.nsp === this.nsp) switch(e.type){
                case gt.CONNECT:
                    e.data && e.data.sid ? this.onconnect(e.data.sid, e.data.pid) : this.emitReserved("connect_error", new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));
                    break;
                case gt.EVENT:
                case gt.BINARY_EVENT:
                    this.onevent(e);
                    break;
                case gt.ACK:
                case gt.BINARY_ACK:
                    this.onack(e);
                    break;
                case gt.DISCONNECT:
                    this.ondisconnect();
                    break;
                case gt.CONNECT_ERROR:
                    this.destroy();
                    const n = new Error(e.data.message);
                    n.data = e.data.data, this.emitReserved("connect_error", n);
                    break;
            }
        }
        onevent(e) {
            const t = e.data || [];
            e.id != null && t.push(this.ack(e.id)), this.connected ? this.emitEvent(t) : this.receiveBuffer.push(Object.freeze(t));
        }
        emitEvent(e) {
            if (this._anyListeners && this._anyListeners.length) {
                const t = this._anyListeners.slice();
                for (const n of t)n.apply(this, e);
            }
            super.emit.apply(this, e), this._pid && e.length && typeof e[e.length - 1] == "string" && (this._lastOffset = e[e.length - 1]);
        }
        ack(e) {
            const t = this;
            let n = !1;
            return function(...a) {
                n || (n = !0, t.packet({
                    type: gt.ACK,
                    id: e,
                    data: a
                }));
            };
        }
        onack(e) {
            const t = this.acks[e.id];
            typeof t == "function" && (delete this.acks[e.id], t.withError && e.data.unshift(null), t.apply(this, e.data));
        }
        onconnect(e, t) {
            this.id = e, this.recovered = t && this._pid === t, this._pid = t, this.connected = !0, this.emitBuffered(), this._drainQueue(!0), this.emitReserved("connect");
        }
        emitBuffered() {
            this.receiveBuffer.forEach((e)=>this.emitEvent(e)), this.receiveBuffer = [], this.sendBuffer.forEach((e)=>{
                this.notifyOutgoingListeners(e), this.packet(e);
            }), this.sendBuffer = [];
        }
        ondisconnect() {
            this.destroy(), this.onclose("io server disconnect");
        }
        destroy() {
            this.subs && (this.subs.forEach((e)=>e()), this.subs = void 0), this.io._destroy(this);
        }
        disconnect() {
            return this.connected && this.packet({
                type: gt.DISCONNECT
            }), this.destroy(), this.connected && this.onclose("io client disconnect"), this;
        }
        close() {
            return this.disconnect();
        }
        compress(e) {
            return this.flags.compress = e, this;
        }
        get volatile() {
            return this.flags.volatile = !0, this;
        }
        timeout(e) {
            return this.flags.timeout = e, this;
        }
        onAny(e) {
            return this._anyListeners = this._anyListeners || [], this._anyListeners.push(e), this;
        }
        prependAny(e) {
            return this._anyListeners = this._anyListeners || [], this._anyListeners.unshift(e), this;
        }
        offAny(e) {
            if (!this._anyListeners) return this;
            if (e) {
                const t = this._anyListeners;
                for(let n = 0; n < t.length; n++)if (e === t[n]) return t.splice(n, 1), this;
            } else this._anyListeners = [];
            return this;
        }
        listenersAny() {
            return this._anyListeners || [];
        }
        onAnyOutgoing(e) {
            return this._anyOutgoingListeners = this._anyOutgoingListeners || [], this._anyOutgoingListeners.push(e), this;
        }
        prependAnyOutgoing(e) {
            return this._anyOutgoingListeners = this._anyOutgoingListeners || [], this._anyOutgoingListeners.unshift(e), this;
        }
        offAnyOutgoing(e) {
            if (!this._anyOutgoingListeners) return this;
            if (e) {
                const t = this._anyOutgoingListeners;
                for(let n = 0; n < t.length; n++)if (e === t[n]) return t.splice(n, 1), this;
            } else this._anyOutgoingListeners = [];
            return this;
        }
        listenersAnyOutgoing() {
            return this._anyOutgoingListeners || [];
        }
        notifyOutgoingListeners(e) {
            if (this._anyOutgoingListeners && this._anyOutgoingListeners.length) {
                const t = this._anyOutgoingListeners.slice();
                for (const n of t)n.apply(this, e.data);
            }
        }
    }
    function zn(r) {
        r = r || {}, this.ms = r.min || 100, this.max = r.max || 1e4, this.factor = r.factor || 2, this.jitter = r.jitter > 0 && r.jitter <= 1 ? r.jitter : 0, this.attempts = 0;
    }
    zn.prototype.duration = function() {
        var r = this.ms * Math.pow(this.factor, this.attempts++);
        if (this.jitter) {
            var e = Math.random(), t = Math.floor(e * this.jitter * r);
            r = (Math.floor(e * 10) & 1) == 0 ? r - t : r + t;
        }
        return Math.min(r, this.max) | 0;
    };
    zn.prototype.reset = function() {
        this.attempts = 0;
    };
    zn.prototype.setMin = function(r) {
        this.ms = r;
    };
    zn.prototype.setMax = function(r) {
        this.max = r;
    };
    zn.prototype.setJitter = function(r) {
        this.jitter = r;
    };
    class Go extends jt {
        constructor(e, t){
            var n;
            super(), this.nsps = {}, this.subs = [], e && typeof e == "object" && (t = e, e = void 0), t = t || {}, t.path = t.path || "/socket.io", this.opts = t, Ca(this, t), this.reconnection(t.reconnection !== !1), this.reconnectionAttempts(t.reconnectionAttempts || 1 / 0), this.reconnectionDelay(t.reconnectionDelay || 1e3), this.reconnectionDelayMax(t.reconnectionDelayMax || 5e3), this.randomizationFactor((n = t.randomizationFactor) !== null && n !== void 0 ? n : .5), this.backoff = new zn({
                min: this.reconnectionDelay(),
                max: this.reconnectionDelayMax(),
                jitter: this.randomizationFactor()
            }), this.timeout(t.timeout == null ? 2e4 : t.timeout), this._readyState = "closed", this.uri = e;
            const a = t.parser || h3;
            this.encoder = new a.Encoder, this.decoder = new a.Decoder, this._autoConnect = t.autoConnect !== !1, this._autoConnect && this.open();
        }
        reconnection(e) {
            return arguments.length ? (this._reconnection = !!e, e || (this.skipReconnect = !0), this) : this._reconnection;
        }
        reconnectionAttempts(e) {
            return e === void 0 ? this._reconnectionAttempts : (this._reconnectionAttempts = e, this);
        }
        reconnectionDelay(e) {
            var t;
            return e === void 0 ? this._reconnectionDelay : (this._reconnectionDelay = e, (t = this.backoff) === null || t === void 0 || t.setMin(e), this);
        }
        randomizationFactor(e) {
            var t;
            return e === void 0 ? this._randomizationFactor : (this._randomizationFactor = e, (t = this.backoff) === null || t === void 0 || t.setJitter(e), this);
        }
        reconnectionDelayMax(e) {
            var t;
            return e === void 0 ? this._reconnectionDelayMax : (this._reconnectionDelayMax = e, (t = this.backoff) === null || t === void 0 || t.setMax(e), this);
        }
        timeout(e) {
            return arguments.length ? (this._timeout = e, this) : this._timeout;
        }
        maybeReconnectOnOpen() {
            !this._reconnecting && this._reconnection && this.backoff.attempts === 0 && this.reconnect();
        }
        open(e) {
            if (~this._readyState.indexOf("open")) return this;
            this.engine = new t3(this.uri, this.opts);
            const t = this.engine, n = this;
            this._readyState = "opening", this.skipReconnect = !1;
            const a = xr(t, "open", function() {
                n.onopen(), e && e();
            }), i = (o)=>{
                this.cleanup(), this._readyState = "closed", this.emitReserved("error", o), e ? e(o) : this.maybeReconnectOnOpen();
            }, s = xr(t, "error", i);
            if (this._timeout !== !1) {
                const o = this._timeout, f = this.setTimeoutFn(()=>{
                    a(), i(new Error("timeout")), t.close();
                }, o);
                this.opts.autoUnref && f.unref(), this.subs.push(()=>{
                    this.clearTimeoutFn(f);
                });
            }
            return this.subs.push(a), this.subs.push(s), this;
        }
        connect(e) {
            return this.open(e);
        }
        onopen() {
            this.cleanup(), this._readyState = "open", this.emitReserved("open");
            const e = this.engine;
            this.subs.push(xr(e, "ping", this.onping.bind(this)), xr(e, "data", this.ondata.bind(this)), xr(e, "error", this.onerror.bind(this)), xr(e, "close", this.onclose.bind(this)), xr(this.decoder, "decoded", this.ondecoded.bind(this)));
        }
        onping() {
            this.emitReserved("ping");
        }
        ondata(e) {
            try {
                this.decoder.add(e);
            } catch (t) {
                this.onclose("parse error", t);
            }
        }
        ondecoded(e) {
            Na(()=>{
                this.emitReserved("packet", e);
            }, this.setTimeoutFn);
        }
        onerror(e) {
            this.emitReserved("error", e);
        }
        socket(e, t) {
            let n = this.nsps[e];
            return n ? this._autoConnect && !n.active && n.connect() : (n = new bl(this, e, t), this.nsps[e] = n), n;
        }
        _destroy(e) {
            const t = Object.keys(this.nsps);
            for (const n of t)if (this.nsps[n].active) return;
            this._close();
        }
        _packet(e) {
            const t = this.encoder.encode(e);
            for(let n = 0; n < t.length; n++)this.engine.write(t[n], e.options);
        }
        cleanup() {
            this.subs.forEach((e)=>e()), this.subs.length = 0, this.decoder.destroy();
        }
        _close() {
            this.skipReconnect = !0, this._reconnecting = !1, this.onclose("forced close");
        }
        disconnect() {
            return this._close();
        }
        onclose(e, t) {
            var n;
            this.cleanup(), (n = this.engine) === null || n === void 0 || n.close(), this.backoff.reset(), this._readyState = "closed", this.emitReserved("close", e, t), this._reconnection && !this.skipReconnect && this.reconnect();
        }
        reconnect() {
            if (this._reconnecting || this.skipReconnect) return this;
            const e = this;
            if (this.backoff.attempts >= this._reconnectionAttempts) this.backoff.reset(), this.emitReserved("reconnect_failed"), this._reconnecting = !1;
            else {
                const t = this.backoff.duration();
                this._reconnecting = !0;
                const n = this.setTimeoutFn(()=>{
                    e.skipReconnect || (this.emitReserved("reconnect_attempt", e.backoff.attempts), !e.skipReconnect && e.open((a)=>{
                        a ? (e._reconnecting = !1, e.reconnect(), this.emitReserved("reconnect_error", a)) : e.onreconnect();
                    }));
                }, t);
                this.opts.autoUnref && n.unref(), this.subs.push(()=>{
                    this.clearTimeoutFn(n);
                });
            }
        }
        onreconnect() {
            const e = this.backoff.attempts;
            this._reconnecting = !1, this.backoff.reset(), this.emitReserved("reconnect", e);
        }
    }
    const Vn = {};
    ea = function(r, e) {
        typeof r == "object" && (e = r, r = void 0), e = e || {};
        const t = r3(r, e.path || "/socket.io"), n = t.source, a = t.id, i = t.path, s = Vn[a] && i in Vn[a].nsps, o = e.forceNew || e["force new connection"] || e.multiplex === !1 || s;
        let f;
        return o ? f = new Go(n, e) : (Vn[a] || (Vn[a] = new Go(n, e)), f = Vn[a]), t.query && !e.query && (e.query = t.queryKey), f.socket(t.path, e);
    };
    Object.assign(ea, {
        Manager: Go,
        Socket: bl,
        io: ea,
        connect: ea
    });
    var Yt = vr.getLogger("SecurePubSub");
    class p3 {
        constructor(e = {}){
            he(this, "options", void 0), he(this, "SOCKET_CONN", null), this.options = e, this.options.timeout = e.timeout || 600, this.options.serverUrl = e.serverUrl || w6, this.options.socketUrl = e.socketUrl || x6, this.options.enableLogging = e.enableLogging || !1, this.options.namespace = e.namespace || "", this.options.sameIpCheck = e.sameIpCheck || !1, this.options.allowedOrigin = e.allowedOrigin || "*", this.options.enableLogging ? Yt.enableAll() : Yt.disableAll();
        }
        static setLogLevel(e) {
            Yt.setLevel(e), w1(e);
        }
        async publish(e, t) {
            if (!this.isValidTopic(e)) throw Yt.error("Invalid topic"), new Error("Invalid topic");
            const n = Br(Buffer.from(e, "utf8")), a = await si(n.toString("hex"), t), i = await ai(n, Br(Buffer.from(a, "utf8"))), s = {
                key: Sr(n).toString("hex"),
                data: a,
                signature: i.toString("hex"),
                timeout: this.options.timeout,
                namespace: this.options.namespace,
                sameIpCheck: this.options.sameIpCheck,
                allowedOrigin: this.options.allowedOrigin
            };
            return cr(`${this.options.serverUrl}/v2/channel/set`, s);
        }
        async subscribe(e) {
            let t = !0;
            const n = Br(Buffer.from(e, "utf8")), a = Sr(n).toString("hex"), i = this.getSocketConnection();
            i.connected ? (Yt.debug("already connected with socket"), i.emit("v2:check_auth_status", a, {
                namespace: this.options.namespace,
                sameIpCheck: this.options.sameIpCheck,
                allowedOrigin: this.options.allowedOrigin
            })) : i.once("connect", ()=>{
                Yt.debug("connected with socket"), i.emit("v2:check_auth_status", a, {
                    namespace: this.options.namespace,
                    sameIpCheck: this.options.sameIpCheck,
                    allowedOrigin: this.options.allowedOrigin
                });
            });
            const s = ()=>{
                i.once("connect", async ()=>{
                    Yt.debug("connected with socket using reconnect"), t && i.emit("v2:check_auth_status", a, {
                        namespace: this.options.namespace,
                        sameIpCheck: this.options.sameIpCheck,
                        allowedOrigin: this.options.allowedOrigin
                    });
                });
            }, o = ()=>{
                t || document.removeEventListener("visibilitychange", o), !i.connected && document.visibilityState === "visible" && s();
            }, f = ()=>{
                Yt.debug("socket disconnected", t), t ? (Yt.error("socket disconnected unexpectedly, reconnecting socket"), s()) : i.removeListener("disconnect", f);
            };
            i.on("disconnect", f);
            const c = new Promise((h, g)=>{
                const v = async (w)=>{
                    try {
                        const E = await If(n.toString("hex"), w);
                        Yt.info("got data", E), h(E);
                    } catch (E) {
                        Yt.error(E), g(E);
                    } finally{
                        t = !1, typeof document < "u" && document.removeEventListener("visibilitychange", o);
                    }
                };
                Yt.info("listening to", `${a}_success`), i.once(`${a}_success`, v);
            });
            return typeof document < "u" && document.addEventListener("visibilitychange", o), c;
        }
        cleanup() {
            this.SOCKET_CONN && (this.SOCKET_CONN.disconnect(), this.SOCKET_CONN = null);
        }
        getSocketConnection() {
            if (this.SOCKET_CONN) return this.SOCKET_CONN;
            const e = ea(this.options.socketUrl, {
                transports: [
                    "websocket",
                    "polling"
                ],
                withCredentials: !0,
                reconnectionDelayMax: 1e4,
                reconnectionAttempts: 10
            });
            return e.on("connect_error", (t)=>{
                e.io.opts.transports = [
                    "polling",
                    "websocket"
                ], Yt.error("connect error", t);
            }), e.on("connect", async ()=>{
                const { engine: t } = e.io;
                Yt.debug("initially connected to", t.transport.name), t.once("upgrade", ()=>{
                    Yt.debug("upgraded", t.transport.name);
                }), t.once("close", (n)=>{
                    Yt.debug("connection closed", n);
                });
            }), e.on("error", (t)=>{
                Yt.error("socket errored", t), e.disconnect();
            }), this.SOCKET_CONN = e, this.SOCKET_CONN;
        }
        isValidTopic(e) {
            return e && e.length > 0;
        }
    }
    class g3 extends _f.EventEmitter {
        constructor({ url: e, target: t, features: n, timeout: a = 3e4, sessionSocketUrl: i, sessionServerUrl: s }){
            super(), he(this, "url", void 0), he(this, "target", void 0), he(this, "features", void 0), he(this, "window", void 0), he(this, "windowTimer", void 0), he(this, "iClosedWindow", void 0), he(this, "timeout", void 0), he(this, "sessionSocketUrl", void 0), he(this, "sessionServerUrl", void 0), this.url = e, this.target = t || "_blank", this.features = n || xf(), this.window = void 0, this.windowTimer = void 0, this.iClosedWindow = !1, this.timeout = a, this.sessionServerUrl = s || Mf, this.sessionSocketUrl = i || Ou, this._setupTimer();
        }
        _setupTimer() {
            this.windowTimer = Number(setInterval(()=>{
                this.window && this.window.closed && (clearInterval(this.windowTimer), setTimeout(()=>{
                    this.iClosedWindow || this.emit("close"), this.iClosedWindow = !1, this.window = void 0;
                }, this.timeout)), this.window === void 0 && clearInterval(this.windowTimer);
            }, 500));
        }
        open() {
            var e;
            if (this.window = window.open(this.url, this.target, this.features), !this.window) throw At.popupBlocked();
            (e = this.window) !== null && e !== void 0 && e.focus && this.window.focus();
        }
        close() {
            this.iClosedWindow = !0, this.window && this.window.close();
        }
        redirect(e) {
            e ? window.location.replace(this.url) : window.location.href = this.url;
        }
        async listenOnChannel(e) {
            const t = new p3({
                serverUrl: this.sessionServerUrl,
                socketUrl: this.sessionSocketUrl,
                sameIpCheck: !0,
                allowedOrigin: !0
            }), n = await t.subscribe(e);
            this.close(), t.cleanup();
            const a = JSON.parse(n);
            return a.error ? {
                error: a.error,
                state: a.state
            } : a.data;
        }
    }
    const Jo = "10.8.0";
    function pl(r = !1) {
        const e = {}, t = new URLSearchParams(window.location.search.slice(1));
        t.forEach((s, o)=>{
            o !== "b64Params" && (e[o] = s);
        });
        const n = t.get("b64Params");
        if (n) try {
            const s = JSON.parse(jo(n));
            Object.keys(s).forEach((o)=>{
                e[o] = s[o];
            });
        } catch (s) {
            Nr.error(s);
        }
        const a = new URLSearchParams(window.location.hash.substring(1));
        a.forEach((s, o)=>{
            o !== "b64Params" && (e[o] = s);
        });
        const i = a.get("b64Params");
        if (i) try {
            const s = JSON.parse(jo(i));
            Object.keys(s).forEach((o)=>{
                e[o] = s[o];
            });
        } catch (s) {
            Nr.error(s);
        }
        if (r) {
            const s = new URL(window.location.origin + window.location.pathname);
            t.size !== 0 && (t.delete("error"), t.delete("state"), t.delete("b64Params"), t.delete("sessionNamespace"), s.search = t.toString()), a.size !== 0 && (a.delete("error"), a.delete("state"), a.delete("b64Params"), a.delete("sessionNamespace"), s.hash = a.toString()), window.history.replaceState(Be(Be({}, window.history.state), {}, {
                as: s.href,
                url: s.href
            }), "", s.href);
        }
        return e;
    }
    class gl {
        constructor(){
            he(this, "store", new Map);
        }
        getItem(e) {
            return this.store.get(e) || null;
        }
        setItem(e, t) {
            this.store.set(e, t);
        }
        removeItem(e) {
            this.store.delete(e);
        }
    }
    class Df {
        constructor(e, t){
            he(this, "storage", void 0), he(this, "_storeKey", void 0), this.storage = t, this._storeKey = e;
            try {
                t.getItem(e) || this.resetStore();
            } catch  {}
        }
        static getInstance(e, t = "local") {
            if (!this.instanceMap.has(e)) {
                let n;
                t === "local" && oa("localStorage") ? n = window.localStorage : t === "session" && oa("sessionStorage") ? n = window.sessionStorage : n = new gl, this.instanceMap.set(e, new this(e, n));
            }
            return this.instanceMap.get(e);
        }
        toJSON() {
            return this.storage.getItem(this._storeKey);
        }
        resetStore() {
            const e = this.getStore();
            return this.storage.removeItem(this._storeKey), e;
        }
        getStore() {
            return JSON.parse(this.storage.getItem(this._storeKey) || "{}");
        }
        get(e) {
            return JSON.parse(this.storage.getItem(this._storeKey) || "{}")[e];
        }
        set(e, t) {
            const n = JSON.parse(this.storage.getItem(this._storeKey) || "{}");
            n[e] = t, this.storage.setItem(this._storeKey, JSON.stringify(n));
        }
    }
    he(Df, "instanceMap", new Map);
    class y3 {
        constructor(e){
            if (he(this, "state", {}), he(this, "options", void 0), he(this, "sessionManager", void 0), he(this, "currentStorage", void 0), he(this, "_storageBaseKey", "auth_store"), he(this, "dappState", void 0), he(this, "addVersionInUrls", !0), he(this, "authProvider", void 0), he(this, "authProviderPromise", void 0), !e.clientId) throw Pr.invalidParams("clientId is required");
            e.network || (e.network = Ji.SAPPHIRE_MAINNET), e.buildEnv || (e.buildEnv = tn.PRODUCTION), e.sdkMode || (e.sdkMode = Mr.DEFAULT), (e.buildEnv === tn.DEVELOPMENT || e.buildEnv === tn.TESTING || e.sdkUrl) && (this.addVersionInUrls = !1), !e.sdkUrl && !e.useMpc && (e.buildEnv === tn.DEVELOPMENT ? (e.sdkUrl = Wu, e.dashboardUrl = Ju) : e.buildEnv === tn.STAGING ? (e.sdkUrl = Yu, e.dashboardUrl = Xu) : e.buildEnv === tn.TESTING ? (e.sdkUrl = Vu, e.dashboardUrl = Zu) : (e.sdkUrl = Gu, e.dashboardUrl = Qu)), !e.redirectUrl && typeof window < "u" && (e.redirectUrl = `${window.location.protocol}//${window.location.host}${window.location.pathname}`), e.uxMode || (e.uxMode = Zt.REDIRECT), typeof e.replaceUrlOnRedirect != "boolean" && (e.replaceUrlOnRedirect = !0), typeof e.includeUserDataInToken != "boolean" && (e.includeUserDataInToken = !0), e.originData || (e.originData = {}), e.whiteLabel || (e.whiteLabel = {}), e.authConnectionConfig || (e.authConnectionConfig = []), e.mfaSettings || (e.mfaSettings = {}), e.storageServerUrl || (e.storageServerUrl = Mf), e.sessionSocketUrl || (e.sessionSocketUrl = Ou), e.storage || (e.storage = "local"), e.sessionTime || (e.sessionTime = 86400), this.options = e;
        }
        get privKey() {
            return this.options.useMpc ? this.state.factorKey || "" : this.state.privKey ? this.state.privKey.padStart(64, "0") : "";
        }
        get coreKitKey() {
            return this.state.coreKitKey ? this.state.coreKitKey.padStart(64, "0") : "";
        }
        get ed25519PrivKey() {
            return this.state.ed25519PrivKey ? this.state.ed25519PrivKey.padStart(128, "0") : "";
        }
        get coreKitEd25519Key() {
            return this.state.coreKitEd25519PrivKey ? this.state.coreKitEd25519PrivKey.padStart(128, "0") : "";
        }
        get sessionId() {
            return this.state.sessionId || "";
        }
        get sessionNamespace() {
            return this.options.sessionNamespace || "";
        }
        get appState() {
            return this.state.userInfo.appState || this.dappState || "";
        }
        get baseUrl() {
            return this.addVersionInUrls ? `${this.options.sdkUrl}/v${Jo.split(".")[0]}` : `${this.options.sdkUrl}`;
        }
        get dashboardUrl() {
            return this.addVersionInUrls ? `${this.options.dashboardUrl}/v${Jo.split(".")[0]}` : `${this.options.dashboardUrl}`;
        }
        async init() {
            const e = pl(this.options.replaceUrlOnRedirect);
            e.sessionNamespace && (this.options.sessionNamespace = e.sessionNamespace);
            const t = this.options.sessionKey || (this.options.sessionNamespace ? `${this._storageBaseKey}_${this.options.sessionNamespace}` : this._storageBaseKey);
            this.currentStorage = Df.getInstance(t, this.options.storage);
            const n = this.currentStorage.get("sessionId");
            if (this.sessionManager = new ei({
                sessionServerBaseUrl: this.options.storageServerUrl,
                sessionNamespace: this.options.sessionNamespace,
                sessionTime: this.options.sessionTime,
                sessionId: n,
                allowedOrigin: this.options.sdkUrl
            }), (this.options.network === Ji.TESTNET || this.options.network === Ji.SAPPHIRE_DEVNET) && `${this.options.network}`, this.options.buildEnv !== tn.PRODUCTION && `${this.options.buildEnv}`, e.error) throw this.dappState = e.state, At.loginFailed(e.error);
            if (e.sessionId && (this.currentStorage.set("sessionId", e.sessionId), this.sessionManager.sessionId = e.sessionId), this.sessionManager.sessionId) {
                const a = await this._authorizeSession();
                this.updateState(a), Object.keys(a).length === 0 ? this.currentStorage.set("sessionId", "") : this.updateState({
                    sessionId: this.sessionManager.sessionId
                });
            }
            this.options.sdkMode === Mr.IFRAME && (this.authProvider = new p6({
                sdkUrl: this.baseUrl,
                whiteLabel: this.options.whiteLabel
            }), this.state.sessionId || (this.authProviderPromise = this.authProvider.init({
                network: this.options.network,
                clientId: this.options.clientId
            }), e.nonce && (await this.authProviderPromise, await this.postLoginInitiatedMessage(JSON.parse(e.loginParams), e.nonce))));
        }
        async login(e) {
            if (!e.authConnection && (!e.authConnectionId || !e.groupedAuthConnectionId)) throw At.invalidLoginParams("AuthConnection is required");
            const t = Be({}, e), n = {
                actionType: pn.LOGIN,
                options: this.options,
                params: t
            }, a = await this.authHandler(`${this.baseUrl}/start`, n, Ta(e.authConnection));
            if (this.options.uxMode === Zt.REDIRECT) return null;
            if (a.error) throw this.dappState = a.state, At.loginFailed(a.error);
            return this.sessionManager.sessionId = a.sessionId, this.options.sessionNamespace = a.sessionNamespace, this.currentStorage.set("sessionId", a.sessionId), await this.rehydrateSession(), {
                privKey: this.privKey
            };
        }
        async postLoginInitiatedMessage(e, t) {
            var n;
            if (this.options.sdkMode !== Mr.IFRAME) throw At.invalidLoginParams("Cannot perform this action in default mode.");
            this.authProviderPromise && await this.authProviderPromise, (n = this.authProvider) !== null && n !== void 0 && n.initialized || await this.authProvider.init({
                network: this.options.network,
                clientId: this.options.clientId
            });
            const a = await this.authProvider.postLoginInitiatedMessage({
                actionType: pn.LOGIN,
                params: e,
                options: this.options
            }, t);
            if (a.error) throw At.loginFailed(a.error);
            this.sessionManager.sessionId = a.sessionId, this.options.sessionNamespace = a.sessionNamespace, this.currentStorage.set("sessionId", a.sessionId), await this.rehydrateSession();
        }
        async postLoginCancelledMessage(e) {
            var t;
            if (this.options.sdkMode !== Mr.IFRAME) throw At.invalidLoginParams("Cannot perform this action in default mode.");
            if (this.authProviderPromise && await this.authProviderPromise, !((t = this.authProvider) !== null && t !== void 0 && t.initialized)) throw Pr.notInitialized();
            this.authProvider.postLoginCancelledMessage(e);
        }
        async logout() {
            if (!this.sessionManager.sessionId) throw At.userNotLoggedIn();
            await this.sessionManager.invalidateSession(), this.updateState({
                privKey: "",
                coreKitKey: "",
                coreKitEd25519PrivKey: "",
                ed25519PrivKey: "",
                walletKey: "",
                oAuthPrivateKey: "",
                tKey: "",
                metadataNonce: "",
                keyMode: void 0,
                userInfo: {
                    name: "",
                    profileImage: "",
                    dappShare: "",
                    idToken: "",
                    oAuthIdToken: "",
                    oAuthAccessToken: "",
                    appState: "",
                    email: "",
                    authConnectionId: "",
                    userId: "",
                    groupedAuthConnectionId: "",
                    authConnection: "",
                    isMfaEnabled: !1
                },
                authToken: "",
                sessionId: "",
                factorKey: "",
                signatures: [],
                tssShareIndex: -1,
                tssPubKey: "",
                tssShare: "",
                tssNonce: -1
            }), this.currentStorage.set("sessionId", "");
        }
        async enableMFA(e) {
            var t;
            if (!this.sessionId) throw At.userNotLoggedIn();
            if (this.state.userInfo.isMfaEnabled) throw At.mfaAlreadyEnabled();
            const n = {
                actionType: pn.ENABLE_MFA,
                options: Be(Be({}, this.options), {}, {
                    sdkMode: Mr.DEFAULT
                }),
                params: Be(Be({}, e), {}, {
                    authConnection: this.state.userInfo.authConnection,
                    authConnectionId: this.state.userInfo.authConnectionId,
                    groupedAuthConnectionId: this.state.userInfo.groupedAuthConnectionId,
                    extraLoginOptions: {
                        login_hint: this.state.userInfo.userId
                    },
                    mfaLevel: "mandatory"
                }),
                sessionId: this.sessionId
            }, a = await this.authHandler(`${this.baseUrl}/start`, n, el);
            if (this.options.uxMode === Zt.REDIRECT) return null;
            if (a.error) throw this.dappState = a.state, At.loginFailed(a.error);
            return this.sessionManager.sessionId = a.sessionId, this.options.sessionNamespace = a.sessionNamespace, this.currentStorage.set("sessionId", a.sessionId), await this.rehydrateSession(), !!(!((t = this.state.userInfo) === null || t === void 0) && t.isMfaEnabled);
        }
        async manageMFA(e) {
            if (!this.sessionId) throw At.userNotLoggedIn();
            if (!this.state.userInfo.isMfaEnabled) throw At.mfaNotEnabled();
            const t = {
                dappUrl: `${window.location.origin}${window.location.pathname}`
            }, n = ei.generateRandomSessionKey(), a = {
                actionType: pn.MANAGE_MFA,
                options: Be(Be({}, this.options), {}, {
                    uxMode: Zt.REDIRECT,
                    sdkMode: Mr.DEFAULT,
                    redirectUrl: `${this.dashboardUrl}/wallet/account`
                }),
                params: Be(Be(Be({}, t), e), {}, {
                    authConnection: this.state.userInfo.authConnection,
                    authConnectionId: this.state.userInfo.authConnectionId,
                    groupedAuthConnectionId: this.state.userInfo.groupedAuthConnectionId,
                    extraLoginOptions: {
                        login_hint: this.state.userInfo.userId
                    },
                    appState: ri({
                        loginId: n
                    })
                }),
                sessionId: this.sessionId
            };
            this.createLoginSession(n, a, a.options.sessionTime, !0);
            const i = {
                loginId: n,
                sessionNamespace: this.options.sessionNamespace,
                storageServerUrl: this.options.storageServerUrl
            }, s = Nn({
                baseURL: `${this.baseUrl}/start`,
                hash: {
                    b64Params: ri(i)
                }
            });
            window.open(s, "_blank");
        }
        async manageSocialFactor(e, t) {
            if (!this.sessionId) throw At.userNotLoggedIn();
            const n = {
                actionType: e,
                options: Be(Be({}, this.options), {}, {
                    sdkMode: Mr.DEFAULT
                }),
                params: Be({}, t),
                sessionId: this.sessionId
            }, a = await this.authHandler(`${this.baseUrl}/start`, n);
            if (this.options.uxMode !== Zt.REDIRECT) return !a.error;
        }
        async addAuthenticatorFactor(e) {
            if (!this.sessionId) throw At.userNotLoggedIn();
            const t = {
                actionType: pn.ADD_AUTHENTICATOR_FACTOR,
                options: Be(Be({}, this.options), {}, {
                    sdkMode: Mr.DEFAULT
                }),
                params: Be(Be({}, e), {}, {
                    authConnection: ot.AUTHENTICATOR
                }),
                sessionId: this.sessionId
            }, n = await this.authHandler(`${this.baseUrl}/start`, t);
            if (this.options.uxMode !== Zt.REDIRECT) return !n.error;
        }
        async addPasskeyFactor(e) {
            if (!this.sessionId) throw At.userNotLoggedIn();
            const t = {
                actionType: pn.ADD_PASSKEY_FACTOR,
                options: Be(Be({}, this.options), {}, {
                    sdkMode: Mr.DEFAULT
                }),
                params: Be(Be({}, e), {}, {
                    authConnection: ot.PASSKEYS
                }),
                sessionId: this.sessionId
            }, n = await this.authHandler(`${this.baseUrl}/start`, t);
            if (this.options.uxMode !== Zt.REDIRECT) return !n.error;
        }
        async cleanup() {
            this.authProvider && this.authProvider.cleanup();
        }
        getUserInfo() {
            if (!this.sessionManager.sessionId) throw At.userNotLoggedIn();
            return this.state.userInfo;
        }
        async createLoginSession(e, t, n = 600, a = !1) {
            if (!this.sessionManager) throw Pr.notInitialized();
            const s = new ei({
                sessionServerBaseUrl: t.options.storageServerUrl,
                sessionNamespace: t.options.sessionNamespace,
                sessionTime: n,
                sessionId: e,
                allowedOrigin: this.options.sdkUrl
            }).createSession(JSON.parse(JSON.stringify(t)));
            t.options.uxMode === Zt.REDIRECT && !a && await s;
        }
        async _authorizeSession() {
            try {
                return this.sessionManager.sessionId ? await this.sessionManager.authorizeSession() : {};
            } catch (e) {
                return Nr.error("authorization failed", e), {};
            }
        }
        updateState(e) {
            this.state = Be(Be({}, this.state), e);
        }
        async rehydrateSession() {
            const e = await this._authorizeSession();
            this.updateState(e);
        }
        async authHandler(e, t, n = 1e3 * 10) {
            const a = ei.generateRandomSessionKey();
            await this.createLoginSession(a, t);
            const i = {
                loginId: a,
                sessionNamespace: this.options.sessionNamespace,
                storageServerUrl: this.options.storageServerUrl
            };
            if (this.options.uxMode === Zt.REDIRECT) {
                const f = Nn({
                    baseURL: e,
                    hash: {
                        b64Params: ri(i)
                    }
                });
                window.location.href = f;
                return;
            }
            const s = Nn({
                baseURL: e,
                hash: {
                    b64Params: ri(i)
                }
            }), o = new g3({
                url: s,
                timeout: n,
                sessionServerUrl: this.options.storageServerUrl,
                sessionSocketUrl: this.options.sessionSocketUrl
            });
            return new Promise((f, c)=>{
                o.on("close", ()=>{
                    c(At.popupClosed());
                }), o.listenOnChannel(a).then(f).catch(c);
                try {
                    o.open();
                } catch (h) {
                    c(h);
                }
            });
        }
    }
    function v3(r) {
        throw new Error('Could not dynamically require "' + r + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
    }
    var js = {
        exports: {}
    }, Od;
    function m3() {
        return Od || (Od = 1, (function(r) {
            (function(e) {
                var t = function(M) {
                    var L, C = new Float64Array(16);
                    if (M) for(L = 0; L < M.length; L++)C[L] = M[L];
                    return C;
                }, n = function() {
                    throw new Error("no PRNG");
                }, a = new Uint8Array(16), i = new Uint8Array(32);
                i[0] = 9;
                var s = t(), o = t([
                    1
                ]), f = t([
                    56129,
                    1
                ]), c = t([
                    30883,
                    4953,
                    19914,
                    30187,
                    55467,
                    16705,
                    2637,
                    112,
                    59544,
                    30585,
                    16505,
                    36039,
                    65139,
                    11119,
                    27886,
                    20995
                ]), h = t([
                    61785,
                    9906,
                    39828,
                    60374,
                    45398,
                    33411,
                    5274,
                    224,
                    53552,
                    61171,
                    33010,
                    6542,
                    64743,
                    22239,
                    55772,
                    9222
                ]), g = t([
                    54554,
                    36645,
                    11616,
                    51542,
                    42930,
                    38181,
                    51040,
                    26924,
                    56412,
                    64982,
                    57905,
                    49316,
                    21502,
                    52590,
                    14035,
                    8553
                ]), v = t([
                    26200,
                    26214,
                    26214,
                    26214,
                    26214,
                    26214,
                    26214,
                    26214,
                    26214,
                    26214,
                    26214,
                    26214,
                    26214,
                    26214,
                    26214,
                    26214
                ]), w = t([
                    41136,
                    18958,
                    6951,
                    50414,
                    58488,
                    44335,
                    6150,
                    12099,
                    55207,
                    15867,
                    153,
                    11085,
                    57099,
                    20417,
                    9344,
                    11139
                ]);
                function E(M, L, C, p) {
                    M[L] = C >> 24 & 255, M[L + 1] = C >> 16 & 255, M[L + 2] = C >> 8 & 255, M[L + 3] = C & 255, M[L + 4] = p >> 24 & 255, M[L + 5] = p >> 16 & 255, M[L + 6] = p >> 8 & 255, M[L + 7] = p & 255;
                }
                function x(M, L, C, p, U) {
                    var Q, ie = 0;
                    for(Q = 0; Q < U; Q++)ie |= M[L + Q] ^ C[p + Q];
                    return (1 & ie - 1 >>> 8) - 1;
                }
                function S(M, L, C, p) {
                    return x(M, L, C, p, 16);
                }
                function y(M, L, C, p) {
                    return x(M, L, C, p, 32);
                }
                function A(M, L, C, p) {
                    for(var U = p[0] & 255 | (p[1] & 255) << 8 | (p[2] & 255) << 16 | (p[3] & 255) << 24, Q = C[0] & 255 | (C[1] & 255) << 8 | (C[2] & 255) << 16 | (C[3] & 255) << 24, ie = C[4] & 255 | (C[5] & 255) << 8 | (C[6] & 255) << 16 | (C[7] & 255) << 24, ue = C[8] & 255 | (C[9] & 255) << 8 | (C[10] & 255) << 16 | (C[11] & 255) << 24, ve = C[12] & 255 | (C[13] & 255) << 8 | (C[14] & 255) << 16 | (C[15] & 255) << 24, Ce = p[4] & 255 | (p[5] & 255) << 8 | (p[6] & 255) << 16 | (p[7] & 255) << 24, Te = L[0] & 255 | (L[1] & 255) << 8 | (L[2] & 255) << 16 | (L[3] & 255) << 24, st = L[4] & 255 | (L[5] & 255) << 8 | (L[6] & 255) << 16 | (L[7] & 255) << 24, Pe = L[8] & 255 | (L[9] & 255) << 8 | (L[10] & 255) << 16 | (L[11] & 255) << 24, Ve = L[12] & 255 | (L[13] & 255) << 8 | (L[14] & 255) << 16 | (L[15] & 255) << 24, Ge = p[8] & 255 | (p[9] & 255) << 8 | (p[10] & 255) << 16 | (p[11] & 255) << 24, at = C[16] & 255 | (C[17] & 255) << 8 | (C[18] & 255) << 16 | (C[19] & 255) << 24, it = C[20] & 255 | (C[21] & 255) << 8 | (C[22] & 255) << 16 | (C[23] & 255) << 24, Je = C[24] & 255 | (C[25] & 255) << 8 | (C[26] & 255) << 16 | (C[27] & 255) << 24, tt = C[28] & 255 | (C[29] & 255) << 8 | (C[30] & 255) << 16 | (C[31] & 255) << 24, Xe = p[12] & 255 | (p[13] & 255) << 8 | (p[14] & 255) << 16 | (p[15] & 255) << 24, Le = U, Ke = Q, Ne = ie, Ue = ue, qe = ve, ke = Ce, ce = Te, de = st, Ee = Pe, me = Ve, we = Ge, Ie = at, Ye = it, ft = Je, dt = tt, ct = Xe, W, ht = 0; ht < 20; ht += 2)W = Le + Ye | 0, qe ^= W << 7 | W >>> 25, W = qe + Le | 0, Ee ^= W << 9 | W >>> 23, W = Ee + qe | 0, Ye ^= W << 13 | W >>> 19, W = Ye + Ee | 0, Le ^= W << 18 | W >>> 14, W = ke + Ke | 0, me ^= W << 7 | W >>> 25, W = me + ke | 0, ft ^= W << 9 | W >>> 23, W = ft + me | 0, Ke ^= W << 13 | W >>> 19, W = Ke + ft | 0, ke ^= W << 18 | W >>> 14, W = we + ce | 0, dt ^= W << 7 | W >>> 25, W = dt + we | 0, Ne ^= W << 9 | W >>> 23, W = Ne + dt | 0, ce ^= W << 13 | W >>> 19, W = ce + Ne | 0, we ^= W << 18 | W >>> 14, W = ct + Ie | 0, Ue ^= W << 7 | W >>> 25, W = Ue + ct | 0, de ^= W << 9 | W >>> 23, W = de + Ue | 0, Ie ^= W << 13 | W >>> 19, W = Ie + de | 0, ct ^= W << 18 | W >>> 14, W = Le + Ue | 0, Ke ^= W << 7 | W >>> 25, W = Ke + Le | 0, Ne ^= W << 9 | W >>> 23, W = Ne + Ke | 0, Ue ^= W << 13 | W >>> 19, W = Ue + Ne | 0, Le ^= W << 18 | W >>> 14, W = ke + qe | 0, ce ^= W << 7 | W >>> 25, W = ce + ke | 0, de ^= W << 9 | W >>> 23, W = de + ce | 0, qe ^= W << 13 | W >>> 19, W = qe + de | 0, ke ^= W << 18 | W >>> 14, W = we + me | 0, Ie ^= W << 7 | W >>> 25, W = Ie + we | 0, Ee ^= W << 9 | W >>> 23, W = Ee + Ie | 0, me ^= W << 13 | W >>> 19, W = me + Ee | 0, we ^= W << 18 | W >>> 14, W = ct + dt | 0, Ye ^= W << 7 | W >>> 25, W = Ye + ct | 0, ft ^= W << 9 | W >>> 23, W = ft + Ye | 0, dt ^= W << 13 | W >>> 19, W = dt + ft | 0, ct ^= W << 18 | W >>> 14;
                    Le = Le + U | 0, Ke = Ke + Q | 0, Ne = Ne + ie | 0, Ue = Ue + ue | 0, qe = qe + ve | 0, ke = ke + Ce | 0, ce = ce + Te | 0, de = de + st | 0, Ee = Ee + Pe | 0, me = me + Ve | 0, we = we + Ge | 0, Ie = Ie + at | 0, Ye = Ye + it | 0, ft = ft + Je | 0, dt = dt + tt | 0, ct = ct + Xe | 0, M[0] = Le >>> 0 & 255, M[1] = Le >>> 8 & 255, M[2] = Le >>> 16 & 255, M[3] = Le >>> 24 & 255, M[4] = Ke >>> 0 & 255, M[5] = Ke >>> 8 & 255, M[6] = Ke >>> 16 & 255, M[7] = Ke >>> 24 & 255, M[8] = Ne >>> 0 & 255, M[9] = Ne >>> 8 & 255, M[10] = Ne >>> 16 & 255, M[11] = Ne >>> 24 & 255, M[12] = Ue >>> 0 & 255, M[13] = Ue >>> 8 & 255, M[14] = Ue >>> 16 & 255, M[15] = Ue >>> 24 & 255, M[16] = qe >>> 0 & 255, M[17] = qe >>> 8 & 255, M[18] = qe >>> 16 & 255, M[19] = qe >>> 24 & 255, M[20] = ke >>> 0 & 255, M[21] = ke >>> 8 & 255, M[22] = ke >>> 16 & 255, M[23] = ke >>> 24 & 255, M[24] = ce >>> 0 & 255, M[25] = ce >>> 8 & 255, M[26] = ce >>> 16 & 255, M[27] = ce >>> 24 & 255, M[28] = de >>> 0 & 255, M[29] = de >>> 8 & 255, M[30] = de >>> 16 & 255, M[31] = de >>> 24 & 255, M[32] = Ee >>> 0 & 255, M[33] = Ee >>> 8 & 255, M[34] = Ee >>> 16 & 255, M[35] = Ee >>> 24 & 255, M[36] = me >>> 0 & 255, M[37] = me >>> 8 & 255, M[38] = me >>> 16 & 255, M[39] = me >>> 24 & 255, M[40] = we >>> 0 & 255, M[41] = we >>> 8 & 255, M[42] = we >>> 16 & 255, M[43] = we >>> 24 & 255, M[44] = Ie >>> 0 & 255, M[45] = Ie >>> 8 & 255, M[46] = Ie >>> 16 & 255, M[47] = Ie >>> 24 & 255, M[48] = Ye >>> 0 & 255, M[49] = Ye >>> 8 & 255, M[50] = Ye >>> 16 & 255, M[51] = Ye >>> 24 & 255, M[52] = ft >>> 0 & 255, M[53] = ft >>> 8 & 255, M[54] = ft >>> 16 & 255, M[55] = ft >>> 24 & 255, M[56] = dt >>> 0 & 255, M[57] = dt >>> 8 & 255, M[58] = dt >>> 16 & 255, M[59] = dt >>> 24 & 255, M[60] = ct >>> 0 & 255, M[61] = ct >>> 8 & 255, M[62] = ct >>> 16 & 255, M[63] = ct >>> 24 & 255;
                }
                function P(M, L, C, p) {
                    for(var U = p[0] & 255 | (p[1] & 255) << 8 | (p[2] & 255) << 16 | (p[3] & 255) << 24, Q = C[0] & 255 | (C[1] & 255) << 8 | (C[2] & 255) << 16 | (C[3] & 255) << 24, ie = C[4] & 255 | (C[5] & 255) << 8 | (C[6] & 255) << 16 | (C[7] & 255) << 24, ue = C[8] & 255 | (C[9] & 255) << 8 | (C[10] & 255) << 16 | (C[11] & 255) << 24, ve = C[12] & 255 | (C[13] & 255) << 8 | (C[14] & 255) << 16 | (C[15] & 255) << 24, Ce = p[4] & 255 | (p[5] & 255) << 8 | (p[6] & 255) << 16 | (p[7] & 255) << 24, Te = L[0] & 255 | (L[1] & 255) << 8 | (L[2] & 255) << 16 | (L[3] & 255) << 24, st = L[4] & 255 | (L[5] & 255) << 8 | (L[6] & 255) << 16 | (L[7] & 255) << 24, Pe = L[8] & 255 | (L[9] & 255) << 8 | (L[10] & 255) << 16 | (L[11] & 255) << 24, Ve = L[12] & 255 | (L[13] & 255) << 8 | (L[14] & 255) << 16 | (L[15] & 255) << 24, Ge = p[8] & 255 | (p[9] & 255) << 8 | (p[10] & 255) << 16 | (p[11] & 255) << 24, at = C[16] & 255 | (C[17] & 255) << 8 | (C[18] & 255) << 16 | (C[19] & 255) << 24, it = C[20] & 255 | (C[21] & 255) << 8 | (C[22] & 255) << 16 | (C[23] & 255) << 24, Je = C[24] & 255 | (C[25] & 255) << 8 | (C[26] & 255) << 16 | (C[27] & 255) << 24, tt = C[28] & 255 | (C[29] & 255) << 8 | (C[30] & 255) << 16 | (C[31] & 255) << 24, Xe = p[12] & 255 | (p[13] & 255) << 8 | (p[14] & 255) << 16 | (p[15] & 255) << 24, Le = U, Ke = Q, Ne = ie, Ue = ue, qe = ve, ke = Ce, ce = Te, de = st, Ee = Pe, me = Ve, we = Ge, Ie = at, Ye = it, ft = Je, dt = tt, ct = Xe, W, ht = 0; ht < 20; ht += 2)W = Le + Ye | 0, qe ^= W << 7 | W >>> 25, W = qe + Le | 0, Ee ^= W << 9 | W >>> 23, W = Ee + qe | 0, Ye ^= W << 13 | W >>> 19, W = Ye + Ee | 0, Le ^= W << 18 | W >>> 14, W = ke + Ke | 0, me ^= W << 7 | W >>> 25, W = me + ke | 0, ft ^= W << 9 | W >>> 23, W = ft + me | 0, Ke ^= W << 13 | W >>> 19, W = Ke + ft | 0, ke ^= W << 18 | W >>> 14, W = we + ce | 0, dt ^= W << 7 | W >>> 25, W = dt + we | 0, Ne ^= W << 9 | W >>> 23, W = Ne + dt | 0, ce ^= W << 13 | W >>> 19, W = ce + Ne | 0, we ^= W << 18 | W >>> 14, W = ct + Ie | 0, Ue ^= W << 7 | W >>> 25, W = Ue + ct | 0, de ^= W << 9 | W >>> 23, W = de + Ue | 0, Ie ^= W << 13 | W >>> 19, W = Ie + de | 0, ct ^= W << 18 | W >>> 14, W = Le + Ue | 0, Ke ^= W << 7 | W >>> 25, W = Ke + Le | 0, Ne ^= W << 9 | W >>> 23, W = Ne + Ke | 0, Ue ^= W << 13 | W >>> 19, W = Ue + Ne | 0, Le ^= W << 18 | W >>> 14, W = ke + qe | 0, ce ^= W << 7 | W >>> 25, W = ce + ke | 0, de ^= W << 9 | W >>> 23, W = de + ce | 0, qe ^= W << 13 | W >>> 19, W = qe + de | 0, ke ^= W << 18 | W >>> 14, W = we + me | 0, Ie ^= W << 7 | W >>> 25, W = Ie + we | 0, Ee ^= W << 9 | W >>> 23, W = Ee + Ie | 0, me ^= W << 13 | W >>> 19, W = me + Ee | 0, we ^= W << 18 | W >>> 14, W = ct + dt | 0, Ye ^= W << 7 | W >>> 25, W = Ye + ct | 0, ft ^= W << 9 | W >>> 23, W = ft + Ye | 0, dt ^= W << 13 | W >>> 19, W = dt + ft | 0, ct ^= W << 18 | W >>> 14;
                    M[0] = Le >>> 0 & 255, M[1] = Le >>> 8 & 255, M[2] = Le >>> 16 & 255, M[3] = Le >>> 24 & 255, M[4] = ke >>> 0 & 255, M[5] = ke >>> 8 & 255, M[6] = ke >>> 16 & 255, M[7] = ke >>> 24 & 255, M[8] = we >>> 0 & 255, M[9] = we >>> 8 & 255, M[10] = we >>> 16 & 255, M[11] = we >>> 24 & 255, M[12] = ct >>> 0 & 255, M[13] = ct >>> 8 & 255, M[14] = ct >>> 16 & 255, M[15] = ct >>> 24 & 255, M[16] = ce >>> 0 & 255, M[17] = ce >>> 8 & 255, M[18] = ce >>> 16 & 255, M[19] = ce >>> 24 & 255, M[20] = de >>> 0 & 255, M[21] = de >>> 8 & 255, M[22] = de >>> 16 & 255, M[23] = de >>> 24 & 255, M[24] = Ee >>> 0 & 255, M[25] = Ee >>> 8 & 255, M[26] = Ee >>> 16 & 255, M[27] = Ee >>> 24 & 255, M[28] = me >>> 0 & 255, M[29] = me >>> 8 & 255, M[30] = me >>> 16 & 255, M[31] = me >>> 24 & 255;
                }
                function N(M, L, C, p) {
                    A(M, L, C, p);
                }
                function k(M, L, C, p) {
                    P(M, L, C, p);
                }
                var D = new Uint8Array([
                    101,
                    120,
                    112,
                    97,
                    110,
                    100,
                    32,
                    51,
                    50,
                    45,
                    98,
                    121,
                    116,
                    101,
                    32,
                    107
                ]);
                function V(M, L, C, p, U, Q, ie) {
                    var ue = new Uint8Array(16), ve = new Uint8Array(64), Ce, Te;
                    for(Te = 0; Te < 16; Te++)ue[Te] = 0;
                    for(Te = 0; Te < 8; Te++)ue[Te] = Q[Te];
                    for(; U >= 64;){
                        for(N(ve, ue, ie, D), Te = 0; Te < 64; Te++)M[L + Te] = C[p + Te] ^ ve[Te];
                        for(Ce = 1, Te = 8; Te < 16; Te++)Ce = Ce + (ue[Te] & 255) | 0, ue[Te] = Ce & 255, Ce >>>= 8;
                        U -= 64, L += 64, p += 64;
                    }
                    if (U > 0) for(N(ve, ue, ie, D), Te = 0; Te < U; Te++)M[L + Te] = C[p + Te] ^ ve[Te];
                    return 0;
                }
                function K(M, L, C, p, U) {
                    var Q = new Uint8Array(16), ie = new Uint8Array(64), ue, ve;
                    for(ve = 0; ve < 16; ve++)Q[ve] = 0;
                    for(ve = 0; ve < 8; ve++)Q[ve] = p[ve];
                    for(; C >= 64;){
                        for(N(ie, Q, U, D), ve = 0; ve < 64; ve++)M[L + ve] = ie[ve];
                        for(ue = 1, ve = 8; ve < 16; ve++)ue = ue + (Q[ve] & 255) | 0, Q[ve] = ue & 255, ue >>>= 8;
                        C -= 64, L += 64;
                    }
                    if (C > 0) for(N(ie, Q, U, D), ve = 0; ve < C; ve++)M[L + ve] = ie[ve];
                    return 0;
                }
                function j(M, L, C, p, U) {
                    var Q = new Uint8Array(32);
                    k(Q, p, U, D);
                    for(var ie = new Uint8Array(8), ue = 0; ue < 8; ue++)ie[ue] = p[ue + 16];
                    return K(M, L, C, ie, Q);
                }
                function H(M, L, C, p, U, Q, ie) {
                    var ue = new Uint8Array(32);
                    k(ue, Q, ie, D);
                    for(var ve = new Uint8Array(8), Ce = 0; Ce < 8; Ce++)ve[Ce] = Q[Ce + 16];
                    return V(M, L, C, p, U, ve, ue);
                }
                var O = function(M) {
                    this.buffer = new Uint8Array(16), this.r = new Uint16Array(10), this.h = new Uint16Array(10), this.pad = new Uint16Array(8), this.leftover = 0, this.fin = 0;
                    var L, C, p, U, Q, ie, ue, ve;
                    L = M[0] & 255 | (M[1] & 255) << 8, this.r[0] = L & 8191, C = M[2] & 255 | (M[3] & 255) << 8, this.r[1] = (L >>> 13 | C << 3) & 8191, p = M[4] & 255 | (M[5] & 255) << 8, this.r[2] = (C >>> 10 | p << 6) & 7939, U = M[6] & 255 | (M[7] & 255) << 8, this.r[3] = (p >>> 7 | U << 9) & 8191, Q = M[8] & 255 | (M[9] & 255) << 8, this.r[4] = (U >>> 4 | Q << 12) & 255, this.r[5] = Q >>> 1 & 8190, ie = M[10] & 255 | (M[11] & 255) << 8, this.r[6] = (Q >>> 14 | ie << 2) & 8191, ue = M[12] & 255 | (M[13] & 255) << 8, this.r[7] = (ie >>> 11 | ue << 5) & 8065, ve = M[14] & 255 | (M[15] & 255) << 8, this.r[8] = (ue >>> 8 | ve << 8) & 8191, this.r[9] = ve >>> 5 & 127, this.pad[0] = M[16] & 255 | (M[17] & 255) << 8, this.pad[1] = M[18] & 255 | (M[19] & 255) << 8, this.pad[2] = M[20] & 255 | (M[21] & 255) << 8, this.pad[3] = M[22] & 255 | (M[23] & 255) << 8, this.pad[4] = M[24] & 255 | (M[25] & 255) << 8, this.pad[5] = M[26] & 255 | (M[27] & 255) << 8, this.pad[6] = M[28] & 255 | (M[29] & 255) << 8, this.pad[7] = M[30] & 255 | (M[31] & 255) << 8;
                };
                O.prototype.blocks = function(M, L, C) {
                    for(var p = this.fin ? 0 : 2048, U, Q, ie, ue, ve, Ce, Te, st, Pe, Ve, Ge, at, it, Je, tt, Xe, Le, Ke, Ne, Ue = this.h[0], qe = this.h[1], ke = this.h[2], ce = this.h[3], de = this.h[4], Ee = this.h[5], me = this.h[6], we = this.h[7], Ie = this.h[8], Ye = this.h[9], ft = this.r[0], dt = this.r[1], ct = this.r[2], W = this.r[3], ht = this.r[4], mt = this.r[5], wt = this.r[6], lt = this.r[7], yt = this.r[8], vt = this.r[9]; C >= 16;)U = M[L + 0] & 255 | (M[L + 1] & 255) << 8, Ue += U & 8191, Q = M[L + 2] & 255 | (M[L + 3] & 255) << 8, qe += (U >>> 13 | Q << 3) & 8191, ie = M[L + 4] & 255 | (M[L + 5] & 255) << 8, ke += (Q >>> 10 | ie << 6) & 8191, ue = M[L + 6] & 255 | (M[L + 7] & 255) << 8, ce += (ie >>> 7 | ue << 9) & 8191, ve = M[L + 8] & 255 | (M[L + 9] & 255) << 8, de += (ue >>> 4 | ve << 12) & 8191, Ee += ve >>> 1 & 8191, Ce = M[L + 10] & 255 | (M[L + 11] & 255) << 8, me += (ve >>> 14 | Ce << 2) & 8191, Te = M[L + 12] & 255 | (M[L + 13] & 255) << 8, we += (Ce >>> 11 | Te << 5) & 8191, st = M[L + 14] & 255 | (M[L + 15] & 255) << 8, Ie += (Te >>> 8 | st << 8) & 8191, Ye += st >>> 5 | p, Pe = 0, Ve = Pe, Ve += Ue * ft, Ve += qe * (5 * vt), Ve += ke * (5 * yt), Ve += ce * (5 * lt), Ve += de * (5 * wt), Pe = Ve >>> 13, Ve &= 8191, Ve += Ee * (5 * mt), Ve += me * (5 * ht), Ve += we * (5 * W), Ve += Ie * (5 * ct), Ve += Ye * (5 * dt), Pe += Ve >>> 13, Ve &= 8191, Ge = Pe, Ge += Ue * dt, Ge += qe * ft, Ge += ke * (5 * vt), Ge += ce * (5 * yt), Ge += de * (5 * lt), Pe = Ge >>> 13, Ge &= 8191, Ge += Ee * (5 * wt), Ge += me * (5 * mt), Ge += we * (5 * ht), Ge += Ie * (5 * W), Ge += Ye * (5 * ct), Pe += Ge >>> 13, Ge &= 8191, at = Pe, at += Ue * ct, at += qe * dt, at += ke * ft, at += ce * (5 * vt), at += de * (5 * yt), Pe = at >>> 13, at &= 8191, at += Ee * (5 * lt), at += me * (5 * wt), at += we * (5 * mt), at += Ie * (5 * ht), at += Ye * (5 * W), Pe += at >>> 13, at &= 8191, it = Pe, it += Ue * W, it += qe * ct, it += ke * dt, it += ce * ft, it += de * (5 * vt), Pe = it >>> 13, it &= 8191, it += Ee * (5 * yt), it += me * (5 * lt), it += we * (5 * wt), it += Ie * (5 * mt), it += Ye * (5 * ht), Pe += it >>> 13, it &= 8191, Je = Pe, Je += Ue * ht, Je += qe * W, Je += ke * ct, Je += ce * dt, Je += de * ft, Pe = Je >>> 13, Je &= 8191, Je += Ee * (5 * vt), Je += me * (5 * yt), Je += we * (5 * lt), Je += Ie * (5 * wt), Je += Ye * (5 * mt), Pe += Je >>> 13, Je &= 8191, tt = Pe, tt += Ue * mt, tt += qe * ht, tt += ke * W, tt += ce * ct, tt += de * dt, Pe = tt >>> 13, tt &= 8191, tt += Ee * ft, tt += me * (5 * vt), tt += we * (5 * yt), tt += Ie * (5 * lt), tt += Ye * (5 * wt), Pe += tt >>> 13, tt &= 8191, Xe = Pe, Xe += Ue * wt, Xe += qe * mt, Xe += ke * ht, Xe += ce * W, Xe += de * ct, Pe = Xe >>> 13, Xe &= 8191, Xe += Ee * dt, Xe += me * ft, Xe += we * (5 * vt), Xe += Ie * (5 * yt), Xe += Ye * (5 * lt), Pe += Xe >>> 13, Xe &= 8191, Le = Pe, Le += Ue * lt, Le += qe * wt, Le += ke * mt, Le += ce * ht, Le += de * W, Pe = Le >>> 13, Le &= 8191, Le += Ee * ct, Le += me * dt, Le += we * ft, Le += Ie * (5 * vt), Le += Ye * (5 * yt), Pe += Le >>> 13, Le &= 8191, Ke = Pe, Ke += Ue * yt, Ke += qe * lt, Ke += ke * wt, Ke += ce * mt, Ke += de * ht, Pe = Ke >>> 13, Ke &= 8191, Ke += Ee * W, Ke += me * ct, Ke += we * dt, Ke += Ie * ft, Ke += Ye * (5 * vt), Pe += Ke >>> 13, Ke &= 8191, Ne = Pe, Ne += Ue * vt, Ne += qe * yt, Ne += ke * lt, Ne += ce * wt, Ne += de * mt, Pe = Ne >>> 13, Ne &= 8191, Ne += Ee * ht, Ne += me * W, Ne += we * ct, Ne += Ie * dt, Ne += Ye * ft, Pe += Ne >>> 13, Ne &= 8191, Pe = (Pe << 2) + Pe | 0, Pe = Pe + Ve | 0, Ve = Pe & 8191, Pe = Pe >>> 13, Ge += Pe, Ue = Ve, qe = Ge, ke = at, ce = it, de = Je, Ee = tt, me = Xe, we = Le, Ie = Ke, Ye = Ne, L += 16, C -= 16;
                    this.h[0] = Ue, this.h[1] = qe, this.h[2] = ke, this.h[3] = ce, this.h[4] = de, this.h[5] = Ee, this.h[6] = me, this.h[7] = we, this.h[8] = Ie, this.h[9] = Ye;
                }, O.prototype.finish = function(M, L) {
                    var C = new Uint16Array(10), p, U, Q, ie;
                    if (this.leftover) {
                        for(ie = this.leftover, this.buffer[ie++] = 1; ie < 16; ie++)this.buffer[ie] = 0;
                        this.fin = 1, this.blocks(this.buffer, 0, 16);
                    }
                    for(p = this.h[1] >>> 13, this.h[1] &= 8191, ie = 2; ie < 10; ie++)this.h[ie] += p, p = this.h[ie] >>> 13, this.h[ie] &= 8191;
                    for(this.h[0] += p * 5, p = this.h[0] >>> 13, this.h[0] &= 8191, this.h[1] += p, p = this.h[1] >>> 13, this.h[1] &= 8191, this.h[2] += p, C[0] = this.h[0] + 5, p = C[0] >>> 13, C[0] &= 8191, ie = 1; ie < 10; ie++)C[ie] = this.h[ie] + p, p = C[ie] >>> 13, C[ie] &= 8191;
                    for(C[9] -= 8192, U = (p ^ 1) - 1, ie = 0; ie < 10; ie++)C[ie] &= U;
                    for(U = ~U, ie = 0; ie < 10; ie++)this.h[ie] = this.h[ie] & U | C[ie];
                    for(this.h[0] = (this.h[0] | this.h[1] << 13) & 65535, this.h[1] = (this.h[1] >>> 3 | this.h[2] << 10) & 65535, this.h[2] = (this.h[2] >>> 6 | this.h[3] << 7) & 65535, this.h[3] = (this.h[3] >>> 9 | this.h[4] << 4) & 65535, this.h[4] = (this.h[4] >>> 12 | this.h[5] << 1 | this.h[6] << 14) & 65535, this.h[5] = (this.h[6] >>> 2 | this.h[7] << 11) & 65535, this.h[6] = (this.h[7] >>> 5 | this.h[8] << 8) & 65535, this.h[7] = (this.h[8] >>> 8 | this.h[9] << 5) & 65535, Q = this.h[0] + this.pad[0], this.h[0] = Q & 65535, ie = 1; ie < 8; ie++)Q = (this.h[ie] + this.pad[ie] | 0) + (Q >>> 16) | 0, this.h[ie] = Q & 65535;
                    M[L + 0] = this.h[0] >>> 0 & 255, M[L + 1] = this.h[0] >>> 8 & 255, M[L + 2] = this.h[1] >>> 0 & 255, M[L + 3] = this.h[1] >>> 8 & 255, M[L + 4] = this.h[2] >>> 0 & 255, M[L + 5] = this.h[2] >>> 8 & 255, M[L + 6] = this.h[3] >>> 0 & 255, M[L + 7] = this.h[3] >>> 8 & 255, M[L + 8] = this.h[4] >>> 0 & 255, M[L + 9] = this.h[4] >>> 8 & 255, M[L + 10] = this.h[5] >>> 0 & 255, M[L + 11] = this.h[5] >>> 8 & 255, M[L + 12] = this.h[6] >>> 0 & 255, M[L + 13] = this.h[6] >>> 8 & 255, M[L + 14] = this.h[7] >>> 0 & 255, M[L + 15] = this.h[7] >>> 8 & 255;
                }, O.prototype.update = function(M, L, C) {
                    var p, U;
                    if (this.leftover) {
                        for(U = 16 - this.leftover, U > C && (U = C), p = 0; p < U; p++)this.buffer[this.leftover + p] = M[L + p];
                        if (C -= U, L += U, this.leftover += U, this.leftover < 16) return;
                        this.blocks(this.buffer, 0, 16), this.leftover = 0;
                    }
                    if (C >= 16 && (U = C - C % 16, this.blocks(M, L, U), L += U, C -= U), C) {
                        for(p = 0; p < C; p++)this.buffer[this.leftover + p] = M[L + p];
                        this.leftover += C;
                    }
                };
                function d(M, L, C, p, U, Q) {
                    var ie = new O(Q);
                    return ie.update(C, p, U), ie.finish(M, L), 0;
                }
                function l(M, L, C, p, U, Q) {
                    var ie = new Uint8Array(16);
                    return d(ie, 0, C, p, U, Q), S(M, L, ie, 0);
                }
                function b(M, L, C, p, U) {
                    var Q;
                    if (C < 32) return -1;
                    for(H(M, 0, L, 0, C, p, U), d(M, 16, M, 32, C - 32, M), Q = 0; Q < 16; Q++)M[Q] = 0;
                    return 0;
                }
                function m(M, L, C, p, U) {
                    var Q, ie = new Uint8Array(32);
                    if (C < 32 || (j(ie, 0, 32, p, U), l(L, 16, L, 32, C - 32, ie) !== 0)) return -1;
                    for(H(M, 0, L, 0, C, p, U), Q = 0; Q < 32; Q++)M[Q] = 0;
                    return 0;
                }
                function _(M, L) {
                    var C;
                    for(C = 0; C < 16; C++)M[C] = L[C] | 0;
                }
                function B(M) {
                    var L, C, p = 1;
                    for(L = 0; L < 16; L++)C = M[L] + p + 65535, p = Math.floor(C / 65536), M[L] = C - p * 65536;
                    M[0] += p - 1 + 37 * (p - 1);
                }
                function T(M, L, C) {
                    for(var p, U = ~(C - 1), Q = 0; Q < 16; Q++)p = U & (M[Q] ^ L[Q]), M[Q] ^= p, L[Q] ^= p;
                }
                function R(M, L) {
                    var C, p, U, Q = t(), ie = t();
                    for(C = 0; C < 16; C++)ie[C] = L[C];
                    for(B(ie), B(ie), B(ie), p = 0; p < 2; p++){
                        for(Q[0] = ie[0] - 65517, C = 1; C < 15; C++)Q[C] = ie[C] - 65535 - (Q[C - 1] >> 16 & 1), Q[C - 1] &= 65535;
                        Q[15] = ie[15] - 32767 - (Q[14] >> 16 & 1), U = Q[15] >> 16 & 1, Q[14] &= 65535, T(ie, Q, 1 - U);
                    }
                    for(C = 0; C < 16; C++)M[2 * C] = ie[C] & 255, M[2 * C + 1] = ie[C] >> 8;
                }
                function u(M, L) {
                    var C = new Uint8Array(32), p = new Uint8Array(32);
                    return R(C, M), R(p, L), y(C, 0, p, 0);
                }
                function I(M) {
                    var L = new Uint8Array(32);
                    return R(L, M), L[0] & 1;
                }
                function G(M, L) {
                    var C;
                    for(C = 0; C < 16; C++)M[C] = L[2 * C] + (L[2 * C + 1] << 8);
                    M[15] &= 32767;
                }
                function $(M, L, C) {
                    for(var p = 0; p < 16; p++)M[p] = L[p] + C[p];
                }
                function te(M, L, C) {
                    for(var p = 0; p < 16; p++)M[p] = L[p] - C[p];
                }
                function Z(M, L, C) {
                    var p, U, Q = 0, ie = 0, ue = 0, ve = 0, Ce = 0, Te = 0, st = 0, Pe = 0, Ve = 0, Ge = 0, at = 0, it = 0, Je = 0, tt = 0, Xe = 0, Le = 0, Ke = 0, Ne = 0, Ue = 0, qe = 0, ke = 0, ce = 0, de = 0, Ee = 0, me = 0, we = 0, Ie = 0, Ye = 0, ft = 0, dt = 0, ct = 0, W = C[0], ht = C[1], mt = C[2], wt = C[3], lt = C[4], yt = C[5], vt = C[6], Kt = C[7], Mt = C[8], Dt = C[9], Ft = C[10], $t = C[11], Ht = C[12], Vt = C[13], Gt = C[14], Jt = C[15];
                    p = L[0], Q += p * W, ie += p * ht, ue += p * mt, ve += p * wt, Ce += p * lt, Te += p * yt, st += p * vt, Pe += p * Kt, Ve += p * Mt, Ge += p * Dt, at += p * Ft, it += p * $t, Je += p * Ht, tt += p * Vt, Xe += p * Gt, Le += p * Jt, p = L[1], ie += p * W, ue += p * ht, ve += p * mt, Ce += p * wt, Te += p * lt, st += p * yt, Pe += p * vt, Ve += p * Kt, Ge += p * Mt, at += p * Dt, it += p * Ft, Je += p * $t, tt += p * Ht, Xe += p * Vt, Le += p * Gt, Ke += p * Jt, p = L[2], ue += p * W, ve += p * ht, Ce += p * mt, Te += p * wt, st += p * lt, Pe += p * yt, Ve += p * vt, Ge += p * Kt, at += p * Mt, it += p * Dt, Je += p * Ft, tt += p * $t, Xe += p * Ht, Le += p * Vt, Ke += p * Gt, Ne += p * Jt, p = L[3], ve += p * W, Ce += p * ht, Te += p * mt, st += p * wt, Pe += p * lt, Ve += p * yt, Ge += p * vt, at += p * Kt, it += p * Mt, Je += p * Dt, tt += p * Ft, Xe += p * $t, Le += p * Ht, Ke += p * Vt, Ne += p * Gt, Ue += p * Jt, p = L[4], Ce += p * W, Te += p * ht, st += p * mt, Pe += p * wt, Ve += p * lt, Ge += p * yt, at += p * vt, it += p * Kt, Je += p * Mt, tt += p * Dt, Xe += p * Ft, Le += p * $t, Ke += p * Ht, Ne += p * Vt, Ue += p * Gt, qe += p * Jt, p = L[5], Te += p * W, st += p * ht, Pe += p * mt, Ve += p * wt, Ge += p * lt, at += p * yt, it += p * vt, Je += p * Kt, tt += p * Mt, Xe += p * Dt, Le += p * Ft, Ke += p * $t, Ne += p * Ht, Ue += p * Vt, qe += p * Gt, ke += p * Jt, p = L[6], st += p * W, Pe += p * ht, Ve += p * mt, Ge += p * wt, at += p * lt, it += p * yt, Je += p * vt, tt += p * Kt, Xe += p * Mt, Le += p * Dt, Ke += p * Ft, Ne += p * $t, Ue += p * Ht, qe += p * Vt, ke += p * Gt, ce += p * Jt, p = L[7], Pe += p * W, Ve += p * ht, Ge += p * mt, at += p * wt, it += p * lt, Je += p * yt, tt += p * vt, Xe += p * Kt, Le += p * Mt, Ke += p * Dt, Ne += p * Ft, Ue += p * $t, qe += p * Ht, ke += p * Vt, ce += p * Gt, de += p * Jt, p = L[8], Ve += p * W, Ge += p * ht, at += p * mt, it += p * wt, Je += p * lt, tt += p * yt, Xe += p * vt, Le += p * Kt, Ke += p * Mt, Ne += p * Dt, Ue += p * Ft, qe += p * $t, ke += p * Ht, ce += p * Vt, de += p * Gt, Ee += p * Jt, p = L[9], Ge += p * W, at += p * ht, it += p * mt, Je += p * wt, tt += p * lt, Xe += p * yt, Le += p * vt, Ke += p * Kt, Ne += p * Mt, Ue += p * Dt, qe += p * Ft, ke += p * $t, ce += p * Ht, de += p * Vt, Ee += p * Gt, me += p * Jt, p = L[10], at += p * W, it += p * ht, Je += p * mt, tt += p * wt, Xe += p * lt, Le += p * yt, Ke += p * vt, Ne += p * Kt, Ue += p * Mt, qe += p * Dt, ke += p * Ft, ce += p * $t, de += p * Ht, Ee += p * Vt, me += p * Gt, we += p * Jt, p = L[11], it += p * W, Je += p * ht, tt += p * mt, Xe += p * wt, Le += p * lt, Ke += p * yt, Ne += p * vt, Ue += p * Kt, qe += p * Mt, ke += p * Dt, ce += p * Ft, de += p * $t, Ee += p * Ht, me += p * Vt, we += p * Gt, Ie += p * Jt, p = L[12], Je += p * W, tt += p * ht, Xe += p * mt, Le += p * wt, Ke += p * lt, Ne += p * yt, Ue += p * vt, qe += p * Kt, ke += p * Mt, ce += p * Dt, de += p * Ft, Ee += p * $t, me += p * Ht, we += p * Vt, Ie += p * Gt, Ye += p * Jt, p = L[13], tt += p * W, Xe += p * ht, Le += p * mt, Ke += p * wt, Ne += p * lt, Ue += p * yt, qe += p * vt, ke += p * Kt, ce += p * Mt, de += p * Dt, Ee += p * Ft, me += p * $t, we += p * Ht, Ie += p * Vt, Ye += p * Gt, ft += p * Jt, p = L[14], Xe += p * W, Le += p * ht, Ke += p * mt, Ne += p * wt, Ue += p * lt, qe += p * yt, ke += p * vt, ce += p * Kt, de += p * Mt, Ee += p * Dt, me += p * Ft, we += p * $t, Ie += p * Ht, Ye += p * Vt, ft += p * Gt, dt += p * Jt, p = L[15], Le += p * W, Ke += p * ht, Ne += p * mt, Ue += p * wt, qe += p * lt, ke += p * yt, ce += p * vt, de += p * Kt, Ee += p * Mt, me += p * Dt, we += p * Ft, Ie += p * $t, Ye += p * Ht, ft += p * Vt, dt += p * Gt, ct += p * Jt, Q += 38 * Ke, ie += 38 * Ne, ue += 38 * Ue, ve += 38 * qe, Ce += 38 * ke, Te += 38 * ce, st += 38 * de, Pe += 38 * Ee, Ve += 38 * me, Ge += 38 * we, at += 38 * Ie, it += 38 * Ye, Je += 38 * ft, tt += 38 * dt, Xe += 38 * ct, U = 1, p = Q + U + 65535, U = Math.floor(p / 65536), Q = p - U * 65536, p = ie + U + 65535, U = Math.floor(p / 65536), ie = p - U * 65536, p = ue + U + 65535, U = Math.floor(p / 65536), ue = p - U * 65536, p = ve + U + 65535, U = Math.floor(p / 65536), ve = p - U * 65536, p = Ce + U + 65535, U = Math.floor(p / 65536), Ce = p - U * 65536, p = Te + U + 65535, U = Math.floor(p / 65536), Te = p - U * 65536, p = st + U + 65535, U = Math.floor(p / 65536), st = p - U * 65536, p = Pe + U + 65535, U = Math.floor(p / 65536), Pe = p - U * 65536, p = Ve + U + 65535, U = Math.floor(p / 65536), Ve = p - U * 65536, p = Ge + U + 65535, U = Math.floor(p / 65536), Ge = p - U * 65536, p = at + U + 65535, U = Math.floor(p / 65536), at = p - U * 65536, p = it + U + 65535, U = Math.floor(p / 65536), it = p - U * 65536, p = Je + U + 65535, U = Math.floor(p / 65536), Je = p - U * 65536, p = tt + U + 65535, U = Math.floor(p / 65536), tt = p - U * 65536, p = Xe + U + 65535, U = Math.floor(p / 65536), Xe = p - U * 65536, p = Le + U + 65535, U = Math.floor(p / 65536), Le = p - U * 65536, Q += U - 1 + 37 * (U - 1), U = 1, p = Q + U + 65535, U = Math.floor(p / 65536), Q = p - U * 65536, p = ie + U + 65535, U = Math.floor(p / 65536), ie = p - U * 65536, p = ue + U + 65535, U = Math.floor(p / 65536), ue = p - U * 65536, p = ve + U + 65535, U = Math.floor(p / 65536), ve = p - U * 65536, p = Ce + U + 65535, U = Math.floor(p / 65536), Ce = p - U * 65536, p = Te + U + 65535, U = Math.floor(p / 65536), Te = p - U * 65536, p = st + U + 65535, U = Math.floor(p / 65536), st = p - U * 65536, p = Pe + U + 65535, U = Math.floor(p / 65536), Pe = p - U * 65536, p = Ve + U + 65535, U = Math.floor(p / 65536), Ve = p - U * 65536, p = Ge + U + 65535, U = Math.floor(p / 65536), Ge = p - U * 65536, p = at + U + 65535, U = Math.floor(p / 65536), at = p - U * 65536, p = it + U + 65535, U = Math.floor(p / 65536), it = p - U * 65536, p = Je + U + 65535, U = Math.floor(p / 65536), Je = p - U * 65536, p = tt + U + 65535, U = Math.floor(p / 65536), tt = p - U * 65536, p = Xe + U + 65535, U = Math.floor(p / 65536), Xe = p - U * 65536, p = Le + U + 65535, U = Math.floor(p / 65536), Le = p - U * 65536, Q += U - 1 + 37 * (U - 1), M[0] = Q, M[1] = ie, M[2] = ue, M[3] = ve, M[4] = Ce, M[5] = Te, M[6] = st, M[7] = Pe, M[8] = Ve, M[9] = Ge, M[10] = at, M[11] = it, M[12] = Je, M[13] = tt, M[14] = Xe, M[15] = Le;
                }
                function fe(M, L) {
                    Z(M, L, L);
                }
                function pe(M, L) {
                    var C = t(), p;
                    for(p = 0; p < 16; p++)C[p] = L[p];
                    for(p = 253; p >= 0; p--)fe(C, C), p !== 2 && p !== 4 && Z(C, C, L);
                    for(p = 0; p < 16; p++)M[p] = C[p];
                }
                function ee(M, L) {
                    var C = t(), p;
                    for(p = 0; p < 16; p++)C[p] = L[p];
                    for(p = 250; p >= 0; p--)fe(C, C), p !== 1 && Z(C, C, L);
                    for(p = 0; p < 16; p++)M[p] = C[p];
                }
                function J(M, L, C) {
                    var p = new Uint8Array(32), U = new Float64Array(80), Q, ie, ue = t(), ve = t(), Ce = t(), Te = t(), st = t(), Pe = t();
                    for(ie = 0; ie < 31; ie++)p[ie] = L[ie];
                    for(p[31] = L[31] & 127 | 64, p[0] &= 248, G(U, C), ie = 0; ie < 16; ie++)ve[ie] = U[ie], Te[ie] = ue[ie] = Ce[ie] = 0;
                    for(ue[0] = Te[0] = 1, ie = 254; ie >= 0; --ie)Q = p[ie >>> 3] >>> (ie & 7) & 1, T(ue, ve, Q), T(Ce, Te, Q), $(st, ue, Ce), te(ue, ue, Ce), $(Ce, ve, Te), te(ve, ve, Te), fe(Te, st), fe(Pe, ue), Z(ue, Ce, ue), Z(Ce, ve, st), $(st, ue, Ce), te(ue, ue, Ce), fe(ve, ue), te(Ce, Te, Pe), Z(ue, Ce, f), $(ue, ue, Te), Z(Ce, Ce, ue), Z(ue, Te, Pe), Z(Te, ve, U), fe(ve, st), T(ue, ve, Q), T(Ce, Te, Q);
                    for(ie = 0; ie < 16; ie++)U[ie + 16] = ue[ie], U[ie + 32] = Ce[ie], U[ie + 48] = ve[ie], U[ie + 64] = Te[ie];
                    var Ve = U.subarray(32), Ge = U.subarray(16);
                    return pe(Ve, Ve), Z(Ge, Ge, Ve), R(M, Ge), 0;
                }
                function oe(M, L) {
                    return J(M, L, i);
                }
                function Me(M, L) {
                    return n(L, 32), oe(M, L);
                }
                function xe(M, L, C) {
                    var p = new Uint8Array(32);
                    return J(p, C, L), k(M, a, p, D);
                }
                var z = b, X = m;
                function re(M, L, C, p, U, Q) {
                    var ie = new Uint8Array(32);
                    return xe(ie, U, Q), z(M, L, C, p, ie);
                }
                function ge(M, L, C, p, U, Q) {
                    var ie = new Uint8Array(32);
                    return xe(ie, U, Q), X(M, L, C, p, ie);
                }
                var Se = [
                    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
                ];
                function ye(M, L, C, p) {
                    for(var U = new Int32Array(16), Q = new Int32Array(16), ie, ue, ve, Ce, Te, st, Pe, Ve, Ge, at, it, Je, tt, Xe, Le, Ke, Ne, Ue, qe, ke, ce, de, Ee, me, we, Ie, Ye = M[0], ft = M[1], dt = M[2], ct = M[3], W = M[4], ht = M[5], mt = M[6], wt = M[7], lt = L[0], yt = L[1], vt = L[2], Kt = L[3], Mt = L[4], Dt = L[5], Ft = L[6], $t = L[7], Ht = 0; p >= 128;){
                        for(qe = 0; qe < 16; qe++)ke = 8 * qe + Ht, U[qe] = C[ke + 0] << 24 | C[ke + 1] << 16 | C[ke + 2] << 8 | C[ke + 3], Q[qe] = C[ke + 4] << 24 | C[ke + 5] << 16 | C[ke + 6] << 8 | C[ke + 7];
                        for(qe = 0; qe < 80; qe++)if (ie = Ye, ue = ft, ve = dt, Ce = ct, Te = W, st = ht, Pe = mt, Ve = wt, Ge = lt, at = yt, it = vt, Je = Kt, tt = Mt, Xe = Dt, Le = Ft, Ke = $t, ce = wt, de = $t, Ee = de & 65535, me = de >>> 16, we = ce & 65535, Ie = ce >>> 16, ce = (W >>> 14 | Mt << 18) ^ (W >>> 18 | Mt << 14) ^ (Mt >>> 9 | W << 23), de = (Mt >>> 14 | W << 18) ^ (Mt >>> 18 | W << 14) ^ (W >>> 9 | Mt << 23), Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, ce = W & ht ^ ~W & mt, de = Mt & Dt ^ ~Mt & Ft, Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, ce = Se[qe * 2], de = Se[qe * 2 + 1], Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, ce = U[qe % 16], de = Q[qe % 16], Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, me += Ee >>> 16, we += me >>> 16, Ie += we >>> 16, Ne = we & 65535 | Ie << 16, Ue = Ee & 65535 | me << 16, ce = Ne, de = Ue, Ee = de & 65535, me = de >>> 16, we = ce & 65535, Ie = ce >>> 16, ce = (Ye >>> 28 | lt << 4) ^ (lt >>> 2 | Ye << 30) ^ (lt >>> 7 | Ye << 25), de = (lt >>> 28 | Ye << 4) ^ (Ye >>> 2 | lt << 30) ^ (Ye >>> 7 | lt << 25), Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, ce = Ye & ft ^ Ye & dt ^ ft & dt, de = lt & yt ^ lt & vt ^ yt & vt, Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, me += Ee >>> 16, we += me >>> 16, Ie += we >>> 16, Ve = we & 65535 | Ie << 16, Ke = Ee & 65535 | me << 16, ce = Ce, de = Je, Ee = de & 65535, me = de >>> 16, we = ce & 65535, Ie = ce >>> 16, ce = Ne, de = Ue, Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, me += Ee >>> 16, we += me >>> 16, Ie += we >>> 16, Ce = we & 65535 | Ie << 16, Je = Ee & 65535 | me << 16, ft = ie, dt = ue, ct = ve, W = Ce, ht = Te, mt = st, wt = Pe, Ye = Ve, yt = Ge, vt = at, Kt = it, Mt = Je, Dt = tt, Ft = Xe, $t = Le, lt = Ke, qe % 16 === 15) for(ke = 0; ke < 16; ke++)ce = U[ke], de = Q[ke], Ee = de & 65535, me = de >>> 16, we = ce & 65535, Ie = ce >>> 16, ce = U[(ke + 9) % 16], de = Q[(ke + 9) % 16], Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, Ne = U[(ke + 1) % 16], Ue = Q[(ke + 1) % 16], ce = (Ne >>> 1 | Ue << 31) ^ (Ne >>> 8 | Ue << 24) ^ Ne >>> 7, de = (Ue >>> 1 | Ne << 31) ^ (Ue >>> 8 | Ne << 24) ^ (Ue >>> 7 | Ne << 25), Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, Ne = U[(ke + 14) % 16], Ue = Q[(ke + 14) % 16], ce = (Ne >>> 19 | Ue << 13) ^ (Ue >>> 29 | Ne << 3) ^ Ne >>> 6, de = (Ue >>> 19 | Ne << 13) ^ (Ne >>> 29 | Ue << 3) ^ (Ue >>> 6 | Ne << 26), Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, me += Ee >>> 16, we += me >>> 16, Ie += we >>> 16, U[ke] = we & 65535 | Ie << 16, Q[ke] = Ee & 65535 | me << 16;
                        ce = Ye, de = lt, Ee = de & 65535, me = de >>> 16, we = ce & 65535, Ie = ce >>> 16, ce = M[0], de = L[0], Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, me += Ee >>> 16, we += me >>> 16, Ie += we >>> 16, M[0] = Ye = we & 65535 | Ie << 16, L[0] = lt = Ee & 65535 | me << 16, ce = ft, de = yt, Ee = de & 65535, me = de >>> 16, we = ce & 65535, Ie = ce >>> 16, ce = M[1], de = L[1], Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, me += Ee >>> 16, we += me >>> 16, Ie += we >>> 16, M[1] = ft = we & 65535 | Ie << 16, L[1] = yt = Ee & 65535 | me << 16, ce = dt, de = vt, Ee = de & 65535, me = de >>> 16, we = ce & 65535, Ie = ce >>> 16, ce = M[2], de = L[2], Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, me += Ee >>> 16, we += me >>> 16, Ie += we >>> 16, M[2] = dt = we & 65535 | Ie << 16, L[2] = vt = Ee & 65535 | me << 16, ce = ct, de = Kt, Ee = de & 65535, me = de >>> 16, we = ce & 65535, Ie = ce >>> 16, ce = M[3], de = L[3], Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, me += Ee >>> 16, we += me >>> 16, Ie += we >>> 16, M[3] = ct = we & 65535 | Ie << 16, L[3] = Kt = Ee & 65535 | me << 16, ce = W, de = Mt, Ee = de & 65535, me = de >>> 16, we = ce & 65535, Ie = ce >>> 16, ce = M[4], de = L[4], Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, me += Ee >>> 16, we += me >>> 16, Ie += we >>> 16, M[4] = W = we & 65535 | Ie << 16, L[4] = Mt = Ee & 65535 | me << 16, ce = ht, de = Dt, Ee = de & 65535, me = de >>> 16, we = ce & 65535, Ie = ce >>> 16, ce = M[5], de = L[5], Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, me += Ee >>> 16, we += me >>> 16, Ie += we >>> 16, M[5] = ht = we & 65535 | Ie << 16, L[5] = Dt = Ee & 65535 | me << 16, ce = mt, de = Ft, Ee = de & 65535, me = de >>> 16, we = ce & 65535, Ie = ce >>> 16, ce = M[6], de = L[6], Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, me += Ee >>> 16, we += me >>> 16, Ie += we >>> 16, M[6] = mt = we & 65535 | Ie << 16, L[6] = Ft = Ee & 65535 | me << 16, ce = wt, de = $t, Ee = de & 65535, me = de >>> 16, we = ce & 65535, Ie = ce >>> 16, ce = M[7], de = L[7], Ee += de & 65535, me += de >>> 16, we += ce & 65535, Ie += ce >>> 16, me += Ee >>> 16, we += me >>> 16, Ie += we >>> 16, M[7] = wt = we & 65535 | Ie << 16, L[7] = $t = Ee & 65535 | me << 16, Ht += 128, p -= 128;
                    }
                    return p;
                }
                function Y(M, L, C) {
                    var p = new Int32Array(8), U = new Int32Array(8), Q = new Uint8Array(256), ie, ue = C;
                    for(p[0] = 1779033703, p[1] = 3144134277, p[2] = 1013904242, p[3] = 2773480762, p[4] = 1359893119, p[5] = 2600822924, p[6] = 528734635, p[7] = 1541459225, U[0] = 4089235720, U[1] = 2227873595, U[2] = 4271175723, U[3] = 1595750129, U[4] = 2917565137, U[5] = 725511199, U[6] = 4215389547, U[7] = 327033209, ye(p, U, L, C), C %= 128, ie = 0; ie < C; ie++)Q[ie] = L[ue - C + ie];
                    for(Q[C] = 128, C = 256 - 128 * (C < 112 ? 1 : 0), Q[C - 9] = 0, E(Q, C - 8, ue / 536870912 | 0, ue << 3), ye(p, U, Q, C), ie = 0; ie < 8; ie++)E(M, 8 * ie, p[ie], U[ie]);
                    return 0;
                }
                function le(M, L) {
                    var C = t(), p = t(), U = t(), Q = t(), ie = t(), ue = t(), ve = t(), Ce = t(), Te = t();
                    te(C, M[1], M[0]), te(Te, L[1], L[0]), Z(C, C, Te), $(p, M[0], M[1]), $(Te, L[0], L[1]), Z(p, p, Te), Z(U, M[3], L[3]), Z(U, U, h), Z(Q, M[2], L[2]), $(Q, Q, Q), te(ie, p, C), te(ue, Q, U), $(ve, Q, U), $(Ce, p, C), Z(M[0], ie, ue), Z(M[1], Ce, ve), Z(M[2], ve, ue), Z(M[3], ie, Ce);
                }
                function be(M, L, C) {
                    var p;
                    for(p = 0; p < 4; p++)T(M[p], L[p], C);
                }
                function se(M, L) {
                    var C = t(), p = t(), U = t();
                    pe(U, L[2]), Z(C, L[0], U), Z(p, L[1], U), R(M, p), M[31] ^= I(C) << 7;
                }
                function De(M, L, C) {
                    var p, U;
                    for(_(M[0], s), _(M[1], o), _(M[2], o), _(M[3], s), U = 255; U >= 0; --U)p = C[U / 8 | 0] >> (U & 7) & 1, be(M, L, p), le(L, M), le(M, M), be(M, L, p);
                }
                function ze(M, L) {
                    var C = [
                        t(),
                        t(),
                        t(),
                        t()
                    ];
                    _(C[0], g), _(C[1], v), _(C[2], o), Z(C[3], g, v), De(M, C, L);
                }
                function $e(M, L, C) {
                    var p = new Uint8Array(64), U = [
                        t(),
                        t(),
                        t(),
                        t()
                    ], Q;
                    for(C || n(L, 32), Y(p, L, 32), p[0] &= 248, p[31] &= 127, p[31] |= 64, ze(U, p), se(M, U), Q = 0; Q < 32; Q++)L[Q + 32] = M[Q];
                    return 0;
                }
                var Ze = new Float64Array([
                    237,
                    211,
                    245,
                    92,
                    26,
                    99,
                    18,
                    88,
                    214,
                    156,
                    247,
                    162,
                    222,
                    249,
                    222,
                    20,
                    0,
                    0,
                    0,
                    0,
                    0,
                    0,
                    0,
                    0,
                    0,
                    0,
                    0,
                    0,
                    0,
                    0,
                    0,
                    16
                ]);
                function je(M, L) {
                    var C, p, U, Q;
                    for(p = 63; p >= 32; --p){
                        for(C = 0, U = p - 32, Q = p - 12; U < Q; ++U)L[U] += C - 16 * L[p] * Ze[U - (p - 32)], C = Math.floor((L[U] + 128) / 256), L[U] -= C * 256;
                        L[U] += C, L[p] = 0;
                    }
                    for(C = 0, U = 0; U < 32; U++)L[U] += C - (L[31] >> 4) * Ze[U], C = L[U] >> 8, L[U] &= 255;
                    for(U = 0; U < 32; U++)L[U] -= C * Ze[U];
                    for(p = 0; p < 32; p++)L[p + 1] += L[p] >> 8, M[p] = L[p] & 255;
                }
                function Qe(M) {
                    var L = new Float64Array(64), C;
                    for(C = 0; C < 64; C++)L[C] = M[C];
                    for(C = 0; C < 64; C++)M[C] = 0;
                    je(M, L);
                }
                function qt(M, L, C, p) {
                    var U = new Uint8Array(64), Q = new Uint8Array(64), ie = new Uint8Array(64), ue, ve, Ce = new Float64Array(64), Te = [
                        t(),
                        t(),
                        t(),
                        t()
                    ];
                    Y(U, p, 32), U[0] &= 248, U[31] &= 127, U[31] |= 64;
                    var st = C + 64;
                    for(ue = 0; ue < C; ue++)M[64 + ue] = L[ue];
                    for(ue = 0; ue < 32; ue++)M[32 + ue] = U[32 + ue];
                    for(Y(ie, M.subarray(32), C + 32), Qe(ie), ze(Te, ie), se(M, Te), ue = 32; ue < 64; ue++)M[ue] = p[ue];
                    for(Y(Q, M, C + 64), Qe(Q), ue = 0; ue < 64; ue++)Ce[ue] = 0;
                    for(ue = 0; ue < 32; ue++)Ce[ue] = ie[ue];
                    for(ue = 0; ue < 32; ue++)for(ve = 0; ve < 32; ve++)Ce[ue + ve] += Q[ue] * U[ve];
                    return je(M.subarray(32), Ce), st;
                }
                function bt(M, L) {
                    var C = t(), p = t(), U = t(), Q = t(), ie = t(), ue = t(), ve = t();
                    return _(M[2], o), G(M[1], L), fe(U, M[1]), Z(Q, U, c), te(U, U, M[2]), $(Q, M[2], Q), fe(ie, Q), fe(ue, ie), Z(ve, ue, ie), Z(C, ve, U), Z(C, C, Q), ee(C, C), Z(C, C, U), Z(C, C, Q), Z(C, C, Q), Z(M[0], C, Q), fe(p, M[0]), Z(p, p, Q), u(p, U) && Z(M[0], M[0], w), fe(p, M[0]), Z(p, p, Q), u(p, U) ? -1 : (I(M[0]) === L[31] >> 7 && te(M[0], s, M[0]), Z(M[3], M[0], M[1]), 0);
                }
                function et(M, L, C, p) {
                    var U, Q = new Uint8Array(32), ie = new Uint8Array(64), ue = [
                        t(),
                        t(),
                        t(),
                        t()
                    ], ve = [
                        t(),
                        t(),
                        t(),
                        t()
                    ];
                    if (C < 64 || bt(ve, p)) return -1;
                    for(U = 0; U < C; U++)M[U] = L[U];
                    for(U = 0; U < 32; U++)M[U + 32] = p[U];
                    if (Y(ie, M, C), Qe(ie), De(ue, ve, ie), ze(ve, L.subarray(32)), le(ue, ve), se(Q, ue), C -= 64, y(L, 0, Q, 0)) {
                        for(U = 0; U < C; U++)M[U] = 0;
                        return -1;
                    }
                    for(U = 0; U < C; U++)M[U] = L[U + 64];
                    return C;
                }
                var ne = 32, Oe = 24, We = 32, Pt = 16, pt = 32, St = 32, ar = 32, It = 32, Bt = 32, Xr = Oe, Ot = We, Nt = Pt, sr = 64, _t = 32, Et = 64, q = 32, F = 64;
                e.lowlevel = {
                    crypto_core_hsalsa20: k,
                    crypto_stream_xor: H,
                    crypto_stream: j,
                    crypto_stream_salsa20_xor: V,
                    crypto_stream_salsa20: K,
                    crypto_onetimeauth: d,
                    crypto_onetimeauth_verify: l,
                    crypto_verify_16: S,
                    crypto_verify_32: y,
                    crypto_secretbox: b,
                    crypto_secretbox_open: m,
                    crypto_scalarmult: J,
                    crypto_scalarmult_base: oe,
                    crypto_box_beforenm: xe,
                    crypto_box_afternm: z,
                    crypto_box: re,
                    crypto_box_open: ge,
                    crypto_box_keypair: Me,
                    crypto_hash: Y,
                    crypto_sign: qt,
                    crypto_sign_keypair: $e,
                    crypto_sign_open: et,
                    crypto_secretbox_KEYBYTES: ne,
                    crypto_secretbox_NONCEBYTES: Oe,
                    crypto_secretbox_ZEROBYTES: We,
                    crypto_secretbox_BOXZEROBYTES: Pt,
                    crypto_scalarmult_BYTES: pt,
                    crypto_scalarmult_SCALARBYTES: St,
                    crypto_box_PUBLICKEYBYTES: ar,
                    crypto_box_SECRETKEYBYTES: It,
                    crypto_box_BEFORENMBYTES: Bt,
                    crypto_box_NONCEBYTES: Xr,
                    crypto_box_ZEROBYTES: Ot,
                    crypto_box_BOXZEROBYTES: Nt,
                    crypto_sign_BYTES: sr,
                    crypto_sign_PUBLICKEYBYTES: _t,
                    crypto_sign_SECRETKEYBYTES: Et,
                    crypto_sign_SEEDBYTES: q,
                    crypto_hash_BYTES: F,
                    gf: t,
                    D: c,
                    L: Ze,
                    pack: se,
                    pack25519: R,
                    unpack25519: G,
                    M: Z,
                    A: $,
                    S: fe,
                    Z: te,
                    pow2523: ee,
                    add: le,
                    set25519: _,
                    modL: je,
                    scalarmult: De,
                    scalarbase: ze
                };
                function _e(M, L) {
                    if (M.length !== ne) throw new Error("bad key size");
                    if (L.length !== Oe) throw new Error("bad nonce size");
                }
                function Re(M, L) {
                    if (M.length !== ar) throw new Error("bad public key size");
                    if (L.length !== It) throw new Error("bad secret key size");
                }
                function Ae() {
                    for(var M = 0; M < arguments.length; M++)if (!(arguments[M] instanceof Uint8Array)) throw new TypeError("unexpected type, use Uint8Array");
                }
                function ut(M) {
                    for(var L = 0; L < M.length; L++)M[L] = 0;
                }
                e.randomBytes = function(M) {
                    var L = new Uint8Array(M);
                    return n(L, M), L;
                }, e.secretbox = function(M, L, C) {
                    Ae(M, L, C), _e(C, L);
                    for(var p = new Uint8Array(We + M.length), U = new Uint8Array(p.length), Q = 0; Q < M.length; Q++)p[Q + We] = M[Q];
                    return b(U, p, p.length, L, C), U.subarray(Pt);
                }, e.secretbox.open = function(M, L, C) {
                    Ae(M, L, C), _e(C, L);
                    for(var p = new Uint8Array(Pt + M.length), U = new Uint8Array(p.length), Q = 0; Q < M.length; Q++)p[Q + Pt] = M[Q];
                    return p.length < 32 || m(U, p, p.length, L, C) !== 0 ? null : U.subarray(We);
                }, e.secretbox.keyLength = ne, e.secretbox.nonceLength = Oe, e.secretbox.overheadLength = Pt, e.scalarMult = function(M, L) {
                    if (Ae(M, L), M.length !== St) throw new Error("bad n size");
                    if (L.length !== pt) throw new Error("bad p size");
                    var C = new Uint8Array(pt);
                    return J(C, M, L), C;
                }, e.scalarMult.base = function(M) {
                    if (Ae(M), M.length !== St) throw new Error("bad n size");
                    var L = new Uint8Array(pt);
                    return oe(L, M), L;
                }, e.scalarMult.scalarLength = St, e.scalarMult.groupElementLength = pt, e.box = function(M, L, C, p) {
                    var U = e.box.before(C, p);
                    return e.secretbox(M, L, U);
                }, e.box.before = function(M, L) {
                    Ae(M, L), Re(M, L);
                    var C = new Uint8Array(Bt);
                    return xe(C, M, L), C;
                }, e.box.after = e.secretbox, e.box.open = function(M, L, C, p) {
                    var U = e.box.before(C, p);
                    return e.secretbox.open(M, L, U);
                }, e.box.open.after = e.secretbox.open, e.box.keyPair = function() {
                    var M = new Uint8Array(ar), L = new Uint8Array(It);
                    return Me(M, L), {
                        publicKey: M,
                        secretKey: L
                    };
                }, e.box.keyPair.fromSecretKey = function(M) {
                    if (Ae(M), M.length !== It) throw new Error("bad secret key size");
                    var L = new Uint8Array(ar);
                    return oe(L, M), {
                        publicKey: L,
                        secretKey: new Uint8Array(M)
                    };
                }, e.box.publicKeyLength = ar, e.box.secretKeyLength = It, e.box.sharedKeyLength = Bt, e.box.nonceLength = Xr, e.box.overheadLength = e.secretbox.overheadLength, e.sign = function(M, L) {
                    if (Ae(M, L), L.length !== Et) throw new Error("bad secret key size");
                    var C = new Uint8Array(sr + M.length);
                    return qt(C, M, M.length, L), C;
                }, e.sign.open = function(M, L) {
                    if (Ae(M, L), L.length !== _t) throw new Error("bad public key size");
                    var C = new Uint8Array(M.length), p = et(C, M, M.length, L);
                    if (p < 0) return null;
                    for(var U = new Uint8Array(p), Q = 0; Q < U.length; Q++)U[Q] = C[Q];
                    return U;
                }, e.sign.detached = function(M, L) {
                    for(var C = e.sign(M, L), p = new Uint8Array(sr), U = 0; U < p.length; U++)p[U] = C[U];
                    return p;
                }, e.sign.detached.verify = function(M, L, C) {
                    if (Ae(M, L, C), L.length !== sr) throw new Error("bad signature size");
                    if (C.length !== _t) throw new Error("bad public key size");
                    var p = new Uint8Array(sr + M.length), U = new Uint8Array(sr + M.length), Q;
                    for(Q = 0; Q < sr; Q++)p[Q] = L[Q];
                    for(Q = 0; Q < M.length; Q++)p[Q + sr] = M[Q];
                    return et(U, p, p.length, C) >= 0;
                }, e.sign.keyPair = function() {
                    var M = new Uint8Array(_t), L = new Uint8Array(Et);
                    return $e(M, L), {
                        publicKey: M,
                        secretKey: L
                    };
                }, e.sign.keyPair.fromSecretKey = function(M) {
                    if (Ae(M), M.length !== Et) throw new Error("bad secret key size");
                    for(var L = new Uint8Array(_t), C = 0; C < L.length; C++)L[C] = M[32 + C];
                    return {
                        publicKey: L,
                        secretKey: new Uint8Array(M)
                    };
                }, e.sign.keyPair.fromSeed = function(M) {
                    if (Ae(M), M.length !== q) throw new Error("bad seed size");
                    for(var L = new Uint8Array(_t), C = new Uint8Array(Et), p = 0; p < 32; p++)C[p] = M[p];
                    return $e(L, C, !0), {
                        publicKey: L,
                        secretKey: C
                    };
                }, e.sign.publicKeyLength = _t, e.sign.secretKeyLength = Et, e.sign.seedLength = q, e.sign.signatureLength = sr, e.hash = function(M) {
                    Ae(M);
                    var L = new Uint8Array(F);
                    return Y(L, M, M.length), L;
                }, e.hash.hashLength = F, e.verify = function(M, L) {
                    return Ae(M, L), M.length === 0 || L.length === 0 || M.length !== L.length ? !1 : x(M, 0, L, 0, M.length) === 0;
                }, e.setPRNG = function(M) {
                    n = M;
                }, (function() {
                    var M = typeof self < "u" ? self.crypto || self.msCrypto : null;
                    if (M && M.getRandomValues) {
                        var L = 65536;
                        e.setPRNG(function(C, p) {
                            var U, Q = new Uint8Array(p);
                            for(U = 0; U < p; U += L)M.getRandomValues(Q.subarray(U, U + Math.min(p - U, L)));
                            for(U = 0; U < p; U++)C[U] = Q[U];
                            ut(Q);
                        });
                    } else typeof v3 < "u" && (M = cf, M && M.randomBytes && e.setPRNG(function(C, p) {
                        var U, Q = M.randomBytes(p);
                        for(U = 0; U < p; U++)C[U] = Q[U];
                        ut(Q);
                    }));
                })();
            })(r.exports ? r.exports : self.nacl = self.nacl || {});
        })(js)), js.exports;
    }
    var w3 = m3();
    const x3 = Lr(w3), bn = x3.lowlevel;
    function _3(r) {
        let e;
        typeof r == "string" ? e = Buffer.from(r, "hex") : e = r;
        const t = new Uint8Array(64), n = [
            bn.gf(),
            bn.gf(),
            bn.gf(),
            bn.gf()
        ], a = new Uint8Array([
            ...new Uint8Array(e),
            ...new Uint8Array(32)
        ]), i = new Uint8Array(32);
        bn.crypto_hash(t, a, 32), t[0] &= 248, t[31] &= 127, t[31] |= 64, bn.scalarbase(n, t), bn.pack(i, n);
        for(let s = 0; s < 32; s += 1)a[s + 32] = i[s];
        return {
            sk: Buffer.from(a),
            pk: Buffer.from(i)
        };
    }
    var Hs = {
        exports: {}
    }, zs = {
        exports: {}
    }, Ws, kd;
    function Ut() {
        if (kd) return Ws;
        kd = 1;
        class r extends Error {
            constructor(t){
                if (!Array.isArray(t)) throw new TypeError(`Expected input to be an Array, got ${typeof t}`);
                let n = "";
                for(let a = 0; a < t.length; a++)n += `    ${t[a].stack}
`;
                super(n), this.name = "AggregateError", this.errors = t;
            }
        }
        return Ws = {
            AggregateError: r,
            ArrayIsArray (e) {
                return Array.isArray(e);
            },
            ArrayPrototypeIncludes (e, t) {
                return e.includes(t);
            },
            ArrayPrototypeIndexOf (e, t) {
                return e.indexOf(t);
            },
            ArrayPrototypeJoin (e, t) {
                return e.join(t);
            },
            ArrayPrototypeMap (e, t) {
                return e.map(t);
            },
            ArrayPrototypePop (e, t) {
                return e.pop(t);
            },
            ArrayPrototypePush (e, t) {
                return e.push(t);
            },
            ArrayPrototypeSlice (e, t, n) {
                return e.slice(t, n);
            },
            Error,
            FunctionPrototypeCall (e, t, ...n) {
                return e.call(t, ...n);
            },
            FunctionPrototypeSymbolHasInstance (e, t) {
                return Function.prototype[Symbol.hasInstance].call(e, t);
            },
            MathFloor: Math.floor,
            Number,
            NumberIsInteger: Number.isInteger,
            NumberIsNaN: Number.isNaN,
            NumberMAX_SAFE_INTEGER: Number.MAX_SAFE_INTEGER,
            NumberMIN_SAFE_INTEGER: Number.MIN_SAFE_INTEGER,
            NumberParseInt: Number.parseInt,
            ObjectDefineProperties (e, t) {
                return Object.defineProperties(e, t);
            },
            ObjectDefineProperty (e, t, n) {
                return Object.defineProperty(e, t, n);
            },
            ObjectGetOwnPropertyDescriptor (e, t) {
                return Object.getOwnPropertyDescriptor(e, t);
            },
            ObjectKeys (e) {
                return Object.keys(e);
            },
            ObjectSetPrototypeOf (e, t) {
                return Object.setPrototypeOf(e, t);
            },
            Promise,
            PromisePrototypeCatch (e, t) {
                return e.catch(t);
            },
            PromisePrototypeThen (e, t, n) {
                return e.then(t, n);
            },
            PromiseReject (e) {
                return Promise.reject(e);
            },
            PromiseResolve (e) {
                return Promise.resolve(e);
            },
            ReflectApply: Reflect.apply,
            RegExpPrototypeTest (e, t) {
                return e.test(t);
            },
            SafeSet: Set,
            String,
            StringPrototypeSlice (e, t, n) {
                return e.slice(t, n);
            },
            StringPrototypeToLowerCase (e) {
                return e.toLowerCase();
            },
            StringPrototypeToUpperCase (e) {
                return e.toUpperCase();
            },
            StringPrototypeTrim (e) {
                return e.trim();
            },
            Symbol,
            SymbolFor: Symbol.for,
            SymbolAsyncIterator: Symbol.asyncIterator,
            SymbolHasInstance: Symbol.hasInstance,
            SymbolIterator: Symbol.iterator,
            SymbolDispose: Symbol.dispose || Symbol("Symbol.dispose"),
            SymbolAsyncDispose: Symbol.asyncDispose || Symbol("Symbol.asyncDispose"),
            TypedArrayPrototypeSet (e, t, n) {
                return e.set(t, n);
            },
            Boolean,
            Uint8Array
        }, Ws;
    }
    var Ys = {
        exports: {}
    }, Vs, Nd;
    function yl() {
        return Nd || (Nd = 1, Vs = {
            format (r, ...e) {
                return r.replace(/%([sdifj])/g, function(...[t, n]) {
                    const a = e.shift();
                    return n === "f" ? a.toFixed(6) : n === "j" ? JSON.stringify(a) : n === "s" && typeof a == "object" ? `${a.constructor !== Object ? a.constructor.name : ""} {}`.trim() : a.toString();
                });
            },
            inspect (r) {
                switch(typeof r){
                    case "string":
                        if (r.includes("'")) if (r.includes('"')) {
                            if (!r.includes("`") && !r.includes("${")) return `\`${r}\``;
                        } else return `"${r}"`;
                        return `'${r}'`;
                    case "number":
                        return isNaN(r) ? "NaN" : Object.is(r, -0) ? String(r) : r;
                    case "bigint":
                        return `${String(r)}n`;
                    case "boolean":
                    case "undefined":
                        return String(r);
                    case "object":
                        return "{}";
                }
            }
        }), Vs;
    }
    var Gs, Cd;
    function ir() {
        if (Cd) return Gs;
        Cd = 1;
        const { format: r, inspect: e } = yl(), { AggregateError: t } = Ut(), n = globalThis.AggregateError || t, a = Symbol("kIsNodeError"), i = [
            "string",
            "function",
            "number",
            "object",
            "Function",
            "Object",
            "boolean",
            "bigint",
            "symbol"
        ], s = /^([A-Z][a-z0-9]*)+$/, o = "__node_internal_", f = {};
        function c(S, y) {
            if (!S) throw new f.ERR_INTERNAL_ASSERTION(y);
        }
        function h(S) {
            let y = "", A = S.length;
            const P = S[0] === "-" ? 1 : 0;
            for(; A >= P + 4; A -= 3)y = `_${S.slice(A - 3, A)}${y}`;
            return `${S.slice(0, A)}${y}`;
        }
        function g(S, y, A) {
            if (typeof y == "function") return c(y.length <= A.length, `Code: ${S}; The provided arguments length (${A.length}) does not match the required ones (${y.length}).`), y(...A);
            const P = (y.match(/%[dfijoOs]/g) || []).length;
            return c(P === A.length, `Code: ${S}; The provided arguments length (${A.length}) does not match the required ones (${P}).`), A.length === 0 ? y : r(y, ...A);
        }
        function v(S, y, A) {
            A || (A = Error);
            class P extends A {
                constructor(...k){
                    super(g(S, y, k));
                }
                toString() {
                    return `${this.name} [${S}]: ${this.message}`;
                }
            }
            Object.defineProperties(P.prototype, {
                name: {
                    value: A.name,
                    writable: !0,
                    enumerable: !1,
                    configurable: !0
                },
                toString: {
                    value () {
                        return `${this.name} [${S}]: ${this.message}`;
                    },
                    writable: !0,
                    enumerable: !1,
                    configurable: !0
                }
            }), P.prototype.code = S, P.prototype[a] = !0, f[S] = P;
        }
        function w(S) {
            const y = o + S.name;
            return Object.defineProperty(S, "name", {
                value: y
            }), S;
        }
        function E(S, y) {
            if (S && y && S !== y) {
                if (Array.isArray(y.errors)) return y.errors.push(S), y;
                const A = new n([
                    y,
                    S
                ], y.message);
                return A.code = y.code, A;
            }
            return S || y;
        }
        class x extends Error {
            constructor(y = "The operation was aborted", A = void 0){
                if (A !== void 0 && typeof A != "object") throw new f.ERR_INVALID_ARG_TYPE("options", "Object", A);
                super(y, A), this.code = "ABORT_ERR", this.name = "AbortError";
            }
        }
        return v("ERR_ASSERTION", "%s", Error), v("ERR_INVALID_ARG_TYPE", (S, y, A)=>{
            c(typeof S == "string", "'name' must be a string"), Array.isArray(y) || (y = [
                y
            ]);
            let P = "The ";
            S.endsWith(" argument") ? P += `${S} ` : P += `"${S}" ${S.includes(".") ? "property" : "argument"} `, P += "must be ";
            const N = [], k = [], D = [];
            for (const K of y)c(typeof K == "string", "All expected entries have to be of type string"), i.includes(K) ? N.push(K.toLowerCase()) : s.test(K) ? k.push(K) : (c(K !== "object", 'The value "object" should be written as "Object"'), D.push(K));
            if (k.length > 0) {
                const K = N.indexOf("object");
                K !== -1 && (N.splice(N, K, 1), k.push("Object"));
            }
            if (N.length > 0) {
                switch(N.length){
                    case 1:
                        P += `of type ${N[0]}`;
                        break;
                    case 2:
                        P += `one of type ${N[0]} or ${N[1]}`;
                        break;
                    default:
                        {
                            const K = N.pop();
                            P += `one of type ${N.join(", ")}, or ${K}`;
                        }
                }
                (k.length > 0 || D.length > 0) && (P += " or ");
            }
            if (k.length > 0) {
                switch(k.length){
                    case 1:
                        P += `an instance of ${k[0]}`;
                        break;
                    case 2:
                        P += `an instance of ${k[0]} or ${k[1]}`;
                        break;
                    default:
                        {
                            const K = k.pop();
                            P += `an instance of ${k.join(", ")}, or ${K}`;
                        }
                }
                D.length > 0 && (P += " or ");
            }
            switch(D.length){
                case 0:
                    break;
                case 1:
                    D[0].toLowerCase() !== D[0] && (P += "an "), P += `${D[0]}`;
                    break;
                case 2:
                    P += `one of ${D[0]} or ${D[1]}`;
                    break;
                default:
                    {
                        const K = D.pop();
                        P += `one of ${D.join(", ")}, or ${K}`;
                    }
            }
            if (A == null) P += `. Received ${A}`;
            else if (typeof A == "function" && A.name) P += `. Received function ${A.name}`;
            else if (typeof A == "object") {
                var V;
                if ((V = A.constructor) !== null && V !== void 0 && V.name) P += `. Received an instance of ${A.constructor.name}`;
                else {
                    const K = e(A, {
                        depth: -1
                    });
                    P += `. Received ${K}`;
                }
            } else {
                let K = e(A, {
                    colors: !1
                });
                K.length > 25 && (K = `${K.slice(0, 25)}...`), P += `. Received type ${typeof A} (${K})`;
            }
            return P;
        }, TypeError), v("ERR_INVALID_ARG_VALUE", (S, y, A = "is invalid")=>{
            let P = e(y);
            return P.length > 128 && (P = P.slice(0, 128) + "..."), `The ${S.includes(".") ? "property" : "argument"} '${S}' ${A}. Received ${P}`;
        }, TypeError), v("ERR_INVALID_RETURN_VALUE", (S, y, A)=>{
            var P;
            const N = A != null && (P = A.constructor) !== null && P !== void 0 && P.name ? `instance of ${A.constructor.name}` : `type ${typeof A}`;
            return `Expected ${S} to be returned from the "${y}" function but got ${N}.`;
        }, TypeError), v("ERR_MISSING_ARGS", (...S)=>{
            c(S.length > 0, "At least one arg needs to be specified");
            let y;
            const A = S.length;
            switch(S = (Array.isArray(S) ? S : [
                S
            ]).map((P)=>`"${P}"`).join(" or "), A){
                case 1:
                    y += `The ${S[0]} argument`;
                    break;
                case 2:
                    y += `The ${S[0]} and ${S[1]} arguments`;
                    break;
                default:
                    {
                        const P = S.pop();
                        y += `The ${S.join(", ")}, and ${P} arguments`;
                    }
                    break;
            }
            return `${y} must be specified`;
        }, TypeError), v("ERR_OUT_OF_RANGE", (S, y, A)=>{
            c(y, 'Missing "range" argument');
            let P;
            if (Number.isInteger(A) && Math.abs(A) > 2 ** 32) P = h(String(A));
            else if (typeof A == "bigint") {
                P = String(A);
                const N = BigInt(2) ** BigInt(32);
                (A > N || A < -N) && (P = h(P)), P += "n";
            } else P = e(A);
            return `The value of "${S}" is out of range. It must be ${y}. Received ${P}`;
        }, RangeError), v("ERR_MULTIPLE_CALLBACK", "Callback called multiple times", Error), v("ERR_METHOD_NOT_IMPLEMENTED", "The %s method is not implemented", Error), v("ERR_STREAM_ALREADY_FINISHED", "Cannot call %s after a stream was finished", Error), v("ERR_STREAM_CANNOT_PIPE", "Cannot pipe, not readable", Error), v("ERR_STREAM_DESTROYED", "Cannot call %s after a stream was destroyed", Error), v("ERR_STREAM_NULL_VALUES", "May not write null values to stream", TypeError), v("ERR_STREAM_PREMATURE_CLOSE", "Premature close", Error), v("ERR_STREAM_PUSH_AFTER_EOF", "stream.push() after EOF", Error), v("ERR_STREAM_UNSHIFT_AFTER_END_EVENT", "stream.unshift() after end event", Error), v("ERR_STREAM_WRITE_AFTER_END", "write after end", Error), v("ERR_UNKNOWN_ENCODING", "Unknown encoding: %s", TypeError), Gs = {
            AbortError: x,
            aggregateTwoErrors: w(E),
            hideStackFrames: w,
            codes: f
        }, Gs;
    }
    var Gn = {
        exports: {}
    }, Ld;
    function bi() {
        if (Ld) return Gn.exports;
        Ld = 1;
        const { AbortController: r, AbortSignal: e } = typeof self < "u" ? self : typeof window < "u" ? window : void 0;
        return Gn.exports = r, Gn.exports.AbortSignal = e, Gn.exports.default = r, Gn.exports;
    }
    var Ud;
    function dr() {
        return Ud || (Ud = 1, (function(r) {
            const e = Wr(), { format: t, inspect: n } = yl(), { codes: { ERR_INVALID_ARG_TYPE: a } } = ir(), { kResistStopPropagation: i, AggregateError: s, SymbolDispose: o } = Ut(), f = globalThis.AbortSignal || bi().AbortSignal, c = globalThis.AbortController || bi().AbortController, h = Object.getPrototypeOf(async function() {}).constructor, g = globalThis.Blob || e.Blob, v = typeof g < "u" ? function(S) {
                return S instanceof g;
            } : function(S) {
                return !1;
            }, w = (x, S)=>{
                if (x !== void 0 && (x === null || typeof x != "object" || !("aborted" in x))) throw new a(S, "AbortSignal", x);
            }, E = (x, S)=>{
                if (typeof x != "function") throw new a(S, "Function", x);
            };
            r.exports = {
                AggregateError: s,
                kEmptyObject: Object.freeze({}),
                once (x) {
                    let S = !1;
                    return function(...y) {
                        S || (S = !0, x.apply(this, y));
                    };
                },
                createDeferredPromise: function() {
                    let x, S;
                    return {
                        promise: new Promise((A, P)=>{
                            x = A, S = P;
                        }),
                        resolve: x,
                        reject: S
                    };
                },
                promisify (x) {
                    return new Promise((S, y)=>{
                        x((A, ...P)=>A ? y(A) : S(...P));
                    });
                },
                debuglog () {
                    return function() {};
                },
                format: t,
                inspect: n,
                types: {
                    isAsyncFunction (x) {
                        return x instanceof h;
                    },
                    isArrayBufferView (x) {
                        return ArrayBuffer.isView(x);
                    }
                },
                isBlob: v,
                deprecate (x, S) {
                    return x;
                },
                addAbortListener: vi().addAbortListener || function(S, y) {
                    if (S === void 0) throw new a("signal", "AbortSignal", S);
                    w(S, "signal"), E(y, "listener");
                    let A;
                    return S.aborted ? queueMicrotask(()=>y()) : (S.addEventListener("abort", y, {
                        __proto__: null,
                        once: !0,
                        [i]: !0
                    }), A = ()=>{
                        S.removeEventListener("abort", y);
                    }), {
                        __proto__: null,
                        [o] () {
                            var P;
                            (P = A) === null || P === void 0 || P();
                        }
                    };
                },
                AbortSignalAny: f.any || function(S) {
                    if (S.length === 1) return S[0];
                    const y = new c, A = ()=>y.abort();
                    return S.forEach((P)=>{
                        w(P, "signals"), P.addEventListener("abort", A, {
                            once: !0
                        });
                    }), y.signal.addEventListener("abort", ()=>{
                        S.forEach((P)=>P.removeEventListener("abort", A));
                    }, {
                        once: !0
                    }), y.signal;
                }
            }, r.exports.promisify.custom = Symbol.for("nodejs.util.promisify.custom");
        })(Ys)), Ys.exports;
    }
    var Di = {}, Js, qd;
    function wi() {
        if (qd) return Js;
        qd = 1;
        const { ArrayIsArray: r, ArrayPrototypeIncludes: e, ArrayPrototypeJoin: t, ArrayPrototypeMap: n, NumberIsInteger: a, NumberIsNaN: i, NumberMAX_SAFE_INTEGER: s, NumberMIN_SAFE_INTEGER: o, NumberParseInt: f, ObjectPrototypeHasOwnProperty: c, RegExpPrototypeExec: h, String: g, StringPrototypeToUpperCase: v, StringPrototypeTrim: w } = Ut(), { hideStackFrames: E, codes: { ERR_SOCKET_BAD_PORT: x, ERR_INVALID_ARG_TYPE: S, ERR_INVALID_ARG_VALUE: y, ERR_OUT_OF_RANGE: A, ERR_UNKNOWN_SIGNAL: P } } = ir(), { normalizeEncoding: N } = dr(), { isAsyncFunction: k, isArrayBufferView: D } = dr().types, V = {};
        function K(Y) {
            return Y === (Y | 0);
        }
        function j(Y) {
            return Y === Y >>> 0;
        }
        const H = /^[0-7]+$/, O = "must be a 32-bit unsigned integer or an octal string";
        function d(Y, le, be) {
            if (typeof Y > "u" && (Y = be), typeof Y == "string") {
                if (h(H, Y) === null) throw new y(le, Y, O);
                Y = f(Y, 8);
            }
            return m(Y, le), Y;
        }
        const l = E((Y, le, be = o, se = s)=>{
            if (typeof Y != "number") throw new S(le, "number", Y);
            if (!a(Y)) throw new A(le, "an integer", Y);
            if (Y < be || Y > se) throw new A(le, `>= ${be} && <= ${se}`, Y);
        }), b = E((Y, le, be = -2147483648, se = 2147483647)=>{
            if (typeof Y != "number") throw new S(le, "number", Y);
            if (!a(Y)) throw new A(le, "an integer", Y);
            if (Y < be || Y > se) throw new A(le, `>= ${be} && <= ${se}`, Y);
        }), m = E((Y, le, be = !1)=>{
            if (typeof Y != "number") throw new S(le, "number", Y);
            if (!a(Y)) throw new A(le, "an integer", Y);
            const se = be ? 1 : 0, De = 4294967295;
            if (Y < se || Y > De) throw new A(le, `>= ${se} && <= ${De}`, Y);
        });
        function _(Y, le) {
            if (typeof Y != "string") throw new S(le, "string", Y);
        }
        function B(Y, le, be = void 0, se) {
            if (typeof Y != "number") throw new S(le, "number", Y);
            if (be != null && Y < be || se != null && Y > se || (be != null || se != null) && i(Y)) throw new A(le, `${be != null ? `>= ${be}` : ""}${be != null && se != null ? " && " : ""}${se != null ? `<= ${se}` : ""}`, Y);
        }
        const T = E((Y, le, be)=>{
            if (!e(be, Y)) {
                const De = "must be one of: " + t(n(be, (ze)=>typeof ze == "string" ? `'${ze}'` : g(ze)), ", ");
                throw new y(le, Y, De);
            }
        });
        function R(Y, le) {
            if (typeof Y != "boolean") throw new S(le, "boolean", Y);
        }
        function u(Y, le, be) {
            return Y == null || !c(Y, le) ? be : Y[le];
        }
        const I = E((Y, le, be = null)=>{
            const se = u(be, "allowArray", !1), De = u(be, "allowFunction", !1);
            if (!u(be, "nullable", !1) && Y === null || !se && r(Y) || typeof Y != "object" && (!De || typeof Y != "function")) throw new S(le, "Object", Y);
        }), G = E((Y, le)=>{
            if (Y != null && typeof Y != "object" && typeof Y != "function") throw new S(le, "a dictionary", Y);
        }), $ = E((Y, le, be = 0)=>{
            if (!r(Y)) throw new S(le, "Array", Y);
            if (Y.length < be) {
                const se = `must be longer than ${be}`;
                throw new y(le, Y, se);
            }
        });
        function te(Y, le) {
            $(Y, le);
            for(let be = 0; be < Y.length; be++)_(Y[be], `${le}[${be}]`);
        }
        function Z(Y, le) {
            $(Y, le);
            for(let be = 0; be < Y.length; be++)R(Y[be], `${le}[${be}]`);
        }
        function fe(Y, le) {
            $(Y, le);
            for(let be = 0; be < Y.length; be++){
                const se = Y[be], De = `${le}[${be}]`;
                if (se == null) throw new S(De, "AbortSignal", se);
                Me(se, De);
            }
        }
        function pe(Y, le = "signal") {
            if (_(Y, le), V[Y] === void 0) throw V[v(Y)] !== void 0 ? new P(Y + " (signals must use all capital letters)") : new P(Y);
        }
        const ee = E((Y, le = "buffer")=>{
            if (!D(Y)) throw new S(le, [
                "Buffer",
                "TypedArray",
                "DataView"
            ], Y);
        });
        function J(Y, le) {
            const be = N(le), se = Y.length;
            if (be === "hex" && se % 2 !== 0) throw new y("encoding", le, `is invalid for data of length ${se}`);
        }
        function oe(Y, le = "Port", be = !0) {
            if (typeof Y != "number" && typeof Y != "string" || typeof Y == "string" && w(Y).length === 0 || +Y !== +Y >>> 0 || Y > 65535 || Y === 0 && !be) throw new x(le, Y, be);
            return Y | 0;
        }
        const Me = E((Y, le)=>{
            if (Y !== void 0 && (Y === null || typeof Y != "object" || !("aborted" in Y))) throw new S(le, "AbortSignal", Y);
        }), xe = E((Y, le)=>{
            if (typeof Y != "function") throw new S(le, "Function", Y);
        }), z = E((Y, le)=>{
            if (typeof Y != "function" || k(Y)) throw new S(le, "Function", Y);
        }), X = E((Y, le)=>{
            if (Y !== void 0) throw new S(le, "undefined", Y);
        });
        function re(Y, le, be) {
            if (!e(be, Y)) throw new S(le, `('${t(be, "|")}')`, Y);
        }
        const ge = /^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;
        function Se(Y, le) {
            if (typeof Y > "u" || !h(ge, Y)) throw new y(le, Y, 'must be an array or string of format "</styles.css>; rel=preload; as=style"');
        }
        function ye(Y) {
            if (typeof Y == "string") return Se(Y, "hints"), Y;
            if (r(Y)) {
                const le = Y.length;
                let be = "";
                if (le === 0) return be;
                for(let se = 0; se < le; se++){
                    const De = Y[se];
                    Se(De, "hints"), be += De, se !== le - 1 && (be += ", ");
                }
                return be;
            }
            throw new y("hints", Y, 'must be an array or string of format "</styles.css>; rel=preload; as=style"');
        }
        return Js = {
            isInt32: K,
            isUint32: j,
            parseFileMode: d,
            validateArray: $,
            validateStringArray: te,
            validateBooleanArray: Z,
            validateAbortSignalArray: fe,
            validateBoolean: R,
            validateBuffer: ee,
            validateDictionary: G,
            validateEncoding: J,
            validateFunction: xe,
            validateInt32: b,
            validateInteger: l,
            validateNumber: B,
            validateObject: I,
            validateOneOf: T,
            validatePlainFunction: z,
            validatePort: oe,
            validateSignalName: pe,
            validateString: _,
            validateUint32: m,
            validateUndefined: X,
            validateUnion: re,
            validateAbortSignal: Me,
            validateLinkHeaderValue: ye
        }, Js;
    }
    var Fi = {
        exports: {}
    }, Xs = {
        exports: {}
    }, Dd;
    function Pn() {
        if (Dd) return Xs.exports;
        Dd = 1;
        var r = Xs.exports = {}, e, t;
        function n() {
            throw new Error("setTimeout has not been defined");
        }
        function a() {
            throw new Error("clearTimeout has not been defined");
        }
        (function() {
            try {
                typeof setTimeout == "function" ? e = setTimeout : e = n;
            } catch  {
                e = n;
            }
            try {
                typeof clearTimeout == "function" ? t = clearTimeout : t = a;
            } catch  {
                t = a;
            }
        })();
        function i(x) {
            if (e === setTimeout) return setTimeout(x, 0);
            if ((e === n || !e) && setTimeout) return e = setTimeout, setTimeout(x, 0);
            try {
                return e(x, 0);
            } catch  {
                try {
                    return e.call(null, x, 0);
                } catch  {
                    return e.call(this, x, 0);
                }
            }
        }
        function s(x) {
            if (t === clearTimeout) return clearTimeout(x);
            if ((t === a || !t) && clearTimeout) return t = clearTimeout, clearTimeout(x);
            try {
                return t(x);
            } catch  {
                try {
                    return t.call(null, x);
                } catch  {
                    return t.call(this, x);
                }
            }
        }
        var o = [], f = !1, c, h = -1;
        function g() {
            !f || !c || (f = !1, c.length ? o = c.concat(o) : h = -1, o.length && v());
        }
        function v() {
            if (!f) {
                var x = i(g);
                f = !0;
                for(var S = o.length; S;){
                    for(c = o, o = []; ++h < S;)c && c[h].run();
                    h = -1, S = o.length;
                }
                c = null, f = !1, s(x);
            }
        }
        r.nextTick = function(x) {
            var S = new Array(arguments.length - 1);
            if (arguments.length > 1) for(var y = 1; y < arguments.length; y++)S[y - 1] = arguments[y];
            o.push(new w(x, S)), o.length === 1 && !f && i(v);
        };
        function w(x, S) {
            this.fun = x, this.array = S;
        }
        w.prototype.run = function() {
            this.fun.apply(null, this.array);
        }, r.title = "browser", r.browser = !0, r.env = {}, r.argv = [], r.version = "", r.versions = {};
        function E() {}
        return r.on = E, r.addListener = E, r.once = E, r.off = E, r.removeListener = E, r.removeAllListeners = E, r.emit = E, r.prependListener = E, r.prependOnceListener = E, r.listeners = function(x) {
            return [];
        }, r.binding = function(x) {
            throw new Error("process.binding is not supported");
        }, r.cwd = function() {
            return "/";
        }, r.chdir = function(x) {
            throw new Error("process.chdir is not supported");
        }, r.umask = function() {
            return 0;
        }, Xs.exports;
    }
    var Zs, Fd;
    function Jr() {
        if (Fd) return Zs;
        Fd = 1;
        const { SymbolAsyncIterator: r, SymbolIterator: e, SymbolFor: t } = Ut(), n = t("nodejs.stream.destroyed"), a = t("nodejs.stream.errored"), i = t("nodejs.stream.readable"), s = t("nodejs.stream.writable"), o = t("nodejs.stream.disturbed"), f = t("nodejs.webstream.isClosedPromise"), c = t("nodejs.webstream.controllerErrorFunction");
        function h(u, I = !1) {
            var G;
            return !!(u && typeof u.pipe == "function" && typeof u.on == "function" && (!I || typeof u.pause == "function" && typeof u.resume == "function") && (!u._writableState || ((G = u._readableState) === null || G === void 0 ? void 0 : G.readable) !== !1) && (!u._writableState || u._readableState));
        }
        function g(u) {
            var I;
            return !!(u && typeof u.write == "function" && typeof u.on == "function" && (!u._readableState || ((I = u._writableState) === null || I === void 0 ? void 0 : I.writable) !== !1));
        }
        function v(u) {
            return !!(u && typeof u.pipe == "function" && u._readableState && typeof u.on == "function" && typeof u.write == "function");
        }
        function w(u) {
            return u && (u._readableState || u._writableState || typeof u.write == "function" && typeof u.on == "function" || typeof u.pipe == "function" && typeof u.on == "function");
        }
        function E(u) {
            return !!(u && !w(u) && typeof u.pipeThrough == "function" && typeof u.getReader == "function" && typeof u.cancel == "function");
        }
        function x(u) {
            return !!(u && !w(u) && typeof u.getWriter == "function" && typeof u.abort == "function");
        }
        function S(u) {
            return !!(u && !w(u) && typeof u.readable == "object" && typeof u.writable == "object");
        }
        function y(u) {
            return E(u) || x(u) || S(u);
        }
        function A(u, I) {
            return u == null ? !1 : I === !0 ? typeof u[r] == "function" : I === !1 ? typeof u[e] == "function" : typeof u[r] == "function" || typeof u[e] == "function";
        }
        function P(u) {
            if (!w(u)) return null;
            const I = u._writableState, G = u._readableState, $ = I || G;
            return !!(u.destroyed || u[n] || $ != null && $.destroyed);
        }
        function N(u) {
            if (!g(u)) return null;
            if (u.writableEnded === !0) return !0;
            const I = u._writableState;
            return I != null && I.errored ? !1 : typeof I?.ended != "boolean" ? null : I.ended;
        }
        function k(u, I) {
            if (!g(u)) return null;
            if (u.writableFinished === !0) return !0;
            const G = u._writableState;
            return G != null && G.errored ? !1 : typeof G?.finished != "boolean" ? null : !!(G.finished || I === !1 && G.ended === !0 && G.length === 0);
        }
        function D(u) {
            if (!h(u)) return null;
            if (u.readableEnded === !0) return !0;
            const I = u._readableState;
            return !I || I.errored ? !1 : typeof I?.ended != "boolean" ? null : I.ended;
        }
        function V(u, I) {
            if (!h(u)) return null;
            const G = u._readableState;
            return G != null && G.errored ? !1 : typeof G?.endEmitted != "boolean" ? null : !!(G.endEmitted || I === !1 && G.ended === !0 && G.length === 0);
        }
        function K(u) {
            return u && u[i] != null ? u[i] : typeof u?.readable != "boolean" ? null : P(u) ? !1 : h(u) && u.readable && !V(u);
        }
        function j(u) {
            return u && u[s] != null ? u[s] : typeof u?.writable != "boolean" ? null : P(u) ? !1 : g(u) && u.writable && !N(u);
        }
        function H(u, I) {
            return w(u) ? P(u) ? !0 : !(I?.readable !== !1 && K(u) || I?.writable !== !1 && j(u)) : null;
        }
        function O(u) {
            var I, G;
            return w(u) ? u.writableErrored ? u.writableErrored : (I = (G = u._writableState) === null || G === void 0 ? void 0 : G.errored) !== null && I !== void 0 ? I : null : null;
        }
        function d(u) {
            var I, G;
            return w(u) ? u.readableErrored ? u.readableErrored : (I = (G = u._readableState) === null || G === void 0 ? void 0 : G.errored) !== null && I !== void 0 ? I : null : null;
        }
        function l(u) {
            if (!w(u)) return null;
            if (typeof u.closed == "boolean") return u.closed;
            const I = u._writableState, G = u._readableState;
            return typeof I?.closed == "boolean" || typeof G?.closed == "boolean" ? I?.closed || G?.closed : typeof u._closed == "boolean" && b(u) ? u._closed : null;
        }
        function b(u) {
            return typeof u._closed == "boolean" && typeof u._defaultKeepAlive == "boolean" && typeof u._removedConnection == "boolean" && typeof u._removedContLen == "boolean";
        }
        function m(u) {
            return typeof u._sent100 == "boolean" && b(u);
        }
        function _(u) {
            var I;
            return typeof u._consuming == "boolean" && typeof u._dumped == "boolean" && ((I = u.req) === null || I === void 0 ? void 0 : I.upgradeOrConnect) === void 0;
        }
        function B(u) {
            if (!w(u)) return null;
            const I = u._writableState, G = u._readableState, $ = I || G;
            return !$ && m(u) || !!($ && $.autoDestroy && $.emitClose && $.closed === !1);
        }
        function T(u) {
            var I;
            return !!(u && ((I = u[o]) !== null && I !== void 0 ? I : u.readableDidRead || u.readableAborted));
        }
        function R(u) {
            var I, G, $, te, Z, fe, pe, ee, J, oe;
            return !!(u && ((I = (G = ($ = (te = (Z = (fe = u[a]) !== null && fe !== void 0 ? fe : u.readableErrored) !== null && Z !== void 0 ? Z : u.writableErrored) !== null && te !== void 0 ? te : (pe = u._readableState) === null || pe === void 0 ? void 0 : pe.errorEmitted) !== null && $ !== void 0 ? $ : (ee = u._writableState) === null || ee === void 0 ? void 0 : ee.errorEmitted) !== null && G !== void 0 ? G : (J = u._readableState) === null || J === void 0 ? void 0 : J.errored) !== null && I !== void 0 ? I : !((oe = u._writableState) === null || oe === void 0) && oe.errored));
        }
        return Zs = {
            isDestroyed: P,
            kIsDestroyed: n,
            isDisturbed: T,
            kIsDisturbed: o,
            isErrored: R,
            kIsErrored: a,
            isReadable: K,
            kIsReadable: i,
            kIsClosedPromise: f,
            kControllerErrorFunction: c,
            kIsWritable: s,
            isClosed: l,
            isDuplexNodeStream: v,
            isFinished: H,
            isIterable: A,
            isReadableNodeStream: h,
            isReadableStream: E,
            isReadableEnded: D,
            isReadableFinished: V,
            isReadableErrored: d,
            isNodeStream: w,
            isWebStream: y,
            isWritable: j,
            isWritableNodeStream: g,
            isWritableStream: x,
            isWritableEnded: N,
            isWritableFinished: k,
            isWritableErrored: O,
            isServerRequest: _,
            isServerResponse: m,
            willEmitClose: B,
            isTransformStream: S
        }, Zs;
    }
    var $d;
    function ln() {
        if ($d) return Fi.exports;
        $d = 1;
        const r = Pn(), { AbortError: e, codes: t } = ir(), { ERR_INVALID_ARG_TYPE: n, ERR_STREAM_PREMATURE_CLOSE: a } = t, { kEmptyObject: i, once: s } = dr(), { validateAbortSignal: o, validateFunction: f, validateObject: c, validateBoolean: h } = wi(), { Promise: g, PromisePrototypeThen: v, SymbolDispose: w } = Ut(), { isClosed: E, isReadable: x, isReadableNodeStream: S, isReadableStream: y, isReadableFinished: A, isReadableErrored: P, isWritable: N, isWritableNodeStream: k, isWritableStream: D, isWritableFinished: V, isWritableErrored: K, isNodeStream: j, willEmitClose: H, kIsClosedPromise: O } = Jr();
        let d;
        function l(T) {
            return T.setHeader && typeof T.abort == "function";
        }
        const b = ()=>{};
        function m(T, R, u) {
            var I, G;
            if (arguments.length === 2 ? (u = R, R = i) : R == null ? R = i : c(R, "options"), f(u, "callback"), o(R.signal, "options.signal"), u = s(u), y(T) || D(T)) return _(T, R, u);
            if (!j(T)) throw new n("stream", [
                "ReadableStream",
                "WritableStream",
                "Stream"
            ], T);
            const $ = (I = R.readable) !== null && I !== void 0 ? I : S(T), te = (G = R.writable) !== null && G !== void 0 ? G : k(T), Z = T._writableState, fe = T._readableState, pe = ()=>{
                T.writable || oe();
            };
            let ee = H(T) && S(T) === $ && k(T) === te, J = V(T, !1);
            const oe = ()=>{
                J = !0, T.destroyed && (ee = !1), !(ee && (!T.readable || $)) && (!$ || Me) && u.call(T);
            };
            let Me = A(T, !1);
            const xe = ()=>{
                Me = !0, T.destroyed && (ee = !1), !(ee && (!T.writable || te)) && (!te || J) && u.call(T);
            }, z = (Y)=>{
                u.call(T, Y);
            };
            let X = E(T);
            const re = ()=>{
                X = !0;
                const Y = K(T) || P(T);
                if (Y && typeof Y != "boolean") return u.call(T, Y);
                if ($ && !Me && S(T, !0) && !A(T, !1)) return u.call(T, new a);
                if (te && !J && !V(T, !1)) return u.call(T, new a);
                u.call(T);
            }, ge = ()=>{
                X = !0;
                const Y = K(T) || P(T);
                if (Y && typeof Y != "boolean") return u.call(T, Y);
                u.call(T);
            }, Se = ()=>{
                T.req.on("finish", oe);
            };
            l(T) ? (T.on("complete", oe), ee || T.on("abort", re), T.req ? Se() : T.on("request", Se)) : te && !Z && (T.on("end", pe), T.on("close", pe)), !ee && typeof T.aborted == "boolean" && T.on("aborted", re), T.on("end", xe), T.on("finish", oe), R.error !== !1 && T.on("error", z), T.on("close", re), X ? r.nextTick(re) : Z != null && Z.errorEmitted || fe != null && fe.errorEmitted ? ee || r.nextTick(ge) : (!$ && (!ee || x(T)) && (J || N(T) === !1) || !te && (!ee || N(T)) && (Me || x(T) === !1) || fe && T.req && T.aborted) && r.nextTick(ge);
            const ye = ()=>{
                u = b, T.removeListener("aborted", re), T.removeListener("complete", oe), T.removeListener("abort", re), T.removeListener("request", Se), T.req && T.req.removeListener("finish", oe), T.removeListener("end", pe), T.removeListener("close", pe), T.removeListener("finish", oe), T.removeListener("end", xe), T.removeListener("error", z), T.removeListener("close", re);
            };
            if (R.signal && !X) {
                const Y = ()=>{
                    const le = u;
                    ye(), le.call(T, new e(void 0, {
                        cause: R.signal.reason
                    }));
                };
                if (R.signal.aborted) r.nextTick(Y);
                else {
                    d = d || dr().addAbortListener;
                    const le = d(R.signal, Y), be = u;
                    u = s((...se)=>{
                        le[w](), be.apply(T, se);
                    });
                }
            }
            return ye;
        }
        function _(T, R, u) {
            let I = !1, G = b;
            if (R.signal) if (G = ()=>{
                I = !0, u.call(T, new e(void 0, {
                    cause: R.signal.reason
                }));
            }, R.signal.aborted) r.nextTick(G);
            else {
                d = d || dr().addAbortListener;
                const te = d(R.signal, G), Z = u;
                u = s((...fe)=>{
                    te[w](), Z.apply(T, fe);
                });
            }
            const $ = (...te)=>{
                I || r.nextTick(()=>u.apply(T, te));
            };
            return v(T[O].promise, $, $), b;
        }
        function B(T, R) {
            var u;
            let I = !1;
            return R === null && (R = i), (u = R) !== null && u !== void 0 && u.cleanup && (h(R.cleanup, "cleanup"), I = R.cleanup), new g((G, $)=>{
                const te = m(T, R, (Z)=>{
                    I && te(), Z ? $(Z) : G();
                });
            });
        }
        return Fi.exports = m, Fi.exports.finished = B, Fi.exports;
    }
    var Qs, Kd;
    function Wn() {
        if (Kd) return Qs;
        Kd = 1;
        const r = Pn(), { aggregateTwoErrors: e, codes: { ERR_MULTIPLE_CALLBACK: t }, AbortError: n } = ir(), { Symbol: a } = Ut(), { kIsDestroyed: i, isDestroyed: s, isFinished: o, isServerRequest: f } = Jr(), c = a("kDestroy"), h = a("kConstruct");
        function g(H, O, d) {
            H && (H.stack, O && !O.errored && (O.errored = H), d && !d.errored && (d.errored = H));
        }
        function v(H, O) {
            const d = this._readableState, l = this._writableState, b = l || d;
            return l != null && l.destroyed || d != null && d.destroyed ? (typeof O == "function" && O(), this) : (g(H, l, d), l && (l.destroyed = !0), d && (d.destroyed = !0), b.constructed ? w(this, H, O) : this.once(c, function(m) {
                w(this, e(m, H), O);
            }), this);
        }
        function w(H, O, d) {
            let l = !1;
            function b(m) {
                if (l) return;
                l = !0;
                const _ = H._readableState, B = H._writableState;
                g(m, B, _), B && (B.closed = !0), _ && (_.closed = !0), typeof d == "function" && d(m), m ? r.nextTick(E, H, m) : r.nextTick(x, H);
            }
            try {
                H._destroy(O || null, b);
            } catch (m) {
                b(m);
            }
        }
        function E(H, O) {
            S(H, O), x(H);
        }
        function x(H) {
            const O = H._readableState, d = H._writableState;
            d && (d.closeEmitted = !0), O && (O.closeEmitted = !0), (d != null && d.emitClose || O != null && O.emitClose) && H.emit("close");
        }
        function S(H, O) {
            const d = H._readableState, l = H._writableState;
            l != null && l.errorEmitted || d != null && d.errorEmitted || (l && (l.errorEmitted = !0), d && (d.errorEmitted = !0), H.emit("error", O));
        }
        function y() {
            const H = this._readableState, O = this._writableState;
            H && (H.constructed = !0, H.closed = !1, H.closeEmitted = !1, H.destroyed = !1, H.errored = null, H.errorEmitted = !1, H.reading = !1, H.ended = H.readable === !1, H.endEmitted = H.readable === !1), O && (O.constructed = !0, O.destroyed = !1, O.closed = !1, O.closeEmitted = !1, O.errored = null, O.errorEmitted = !1, O.finalCalled = !1, O.prefinished = !1, O.ended = O.writable === !1, O.ending = O.writable === !1, O.finished = O.writable === !1);
        }
        function A(H, O, d) {
            const l = H._readableState, b = H._writableState;
            if (b != null && b.destroyed || l != null && l.destroyed) return this;
            l != null && l.autoDestroy || b != null && b.autoDestroy ? H.destroy(O) : O && (O.stack, b && !b.errored && (b.errored = O), l && !l.errored && (l.errored = O), d ? r.nextTick(S, H, O) : S(H, O));
        }
        function P(H, O) {
            if (typeof H._construct != "function") return;
            const d = H._readableState, l = H._writableState;
            d && (d.constructed = !1), l && (l.constructed = !1), H.once(h, O), !(H.listenerCount(h) > 1) && r.nextTick(N, H);
        }
        function N(H) {
            let O = !1;
            function d(l) {
                if (O) {
                    A(H, l ?? new t);
                    return;
                }
                O = !0;
                const b = H._readableState, m = H._writableState, _ = m || b;
                b && (b.constructed = !0), m && (m.constructed = !0), _.destroyed ? H.emit(c, l) : l ? A(H, l, !0) : r.nextTick(k, H);
            }
            try {
                H._construct((l)=>{
                    r.nextTick(d, l);
                });
            } catch (l) {
                r.nextTick(d, l);
            }
        }
        function k(H) {
            H.emit(h);
        }
        function D(H) {
            return H?.setHeader && typeof H.abort == "function";
        }
        function V(H) {
            H.emit("close");
        }
        function K(H, O) {
            H.emit("error", O), r.nextTick(V, H);
        }
        function j(H, O) {
            !H || s(H) || (!O && !o(H) && (O = new n), f(H) ? (H.socket = null, H.destroy(O)) : D(H) ? H.abort() : D(H.req) ? H.req.abort() : typeof H.destroy == "function" ? H.destroy(O) : typeof H.close == "function" ? H.close() : O ? r.nextTick(K, H, O) : r.nextTick(V, H), H.destroyed || (H[i] = !0));
        }
        return Qs = {
            construct: P,
            destroyer: j,
            destroy: v,
            undestroy: y,
            errorOrDestroy: A
        }, Qs;
    }
    var eo, jd;
    function Ff() {
        if (jd) return eo;
        jd = 1;
        const { ArrayIsArray: r, ObjectSetPrototypeOf: e } = Ut(), { EventEmitter: t } = vi();
        function n(i) {
            t.call(this, i);
        }
        e(n.prototype, t.prototype), e(n, t), n.prototype.pipe = function(i, s) {
            const o = this;
            function f(x) {
                i.writable && i.write(x) === !1 && o.pause && o.pause();
            }
            o.on("data", f);
            function c() {
                o.readable && o.resume && o.resume();
            }
            i.on("drain", c), !i._isStdio && (!s || s.end !== !1) && (o.on("end", g), o.on("close", v));
            let h = !1;
            function g() {
                h || (h = !0, i.end());
            }
            function v() {
                h || (h = !0, typeof i.destroy == "function" && i.destroy());
            }
            function w(x) {
                E(), t.listenerCount(this, "error") === 0 && this.emit("error", x);
            }
            a(o, "error", w), a(i, "error", w);
            function E() {
                o.removeListener("data", f), i.removeListener("drain", c), o.removeListener("end", g), o.removeListener("close", v), o.removeListener("error", w), i.removeListener("error", w), o.removeListener("end", E), o.removeListener("close", E), i.removeListener("close", E);
            }
            return o.on("end", E), o.on("close", E), i.on("close", E), i.emit("pipe", o), i;
        };
        function a(i, s, o) {
            if (typeof i.prependListener == "function") return i.prependListener(s, o);
            !i._events || !i._events[s] ? i.on(s, o) : r(i._events[s]) ? i._events[s].unshift(o) : i._events[s] = [
                o,
                i._events[s]
            ];
        }
        return eo = {
            Stream: n,
            prependListener: a
        }, eo;
    }
    var to = {
        exports: {}
    }, Hd;
    function La() {
        return Hd || (Hd = 1, (function(r) {
            const { SymbolDispose: e } = Ut(), { AbortError: t, codes: n } = ir(), { isNodeStream: a, isWebStream: i, kControllerErrorFunction: s } = Jr(), o = ln(), { ERR_INVALID_ARG_TYPE: f } = n;
            let c;
            const h = (g, v)=>{
                if (typeof g != "object" || !("aborted" in g)) throw new f(v, "AbortSignal", g);
            };
            r.exports.addAbortSignal = function(v, w) {
                if (h(v, "signal"), !a(w) && !i(w)) throw new f("stream", [
                    "ReadableStream",
                    "WritableStream",
                    "Stream"
                ], w);
                return r.exports.addAbortSignalNoValidate(v, w);
            }, r.exports.addAbortSignalNoValidate = function(g, v) {
                if (typeof g != "object" || !("aborted" in g)) return v;
                const w = a(v) ? ()=>{
                    v.destroy(new t(void 0, {
                        cause: g.reason
                    }));
                } : ()=>{
                    v[s](new t(void 0, {
                        cause: g.reason
                    }));
                };
                if (g.aborted) w();
                else {
                    c = c || dr().addAbortListener;
                    const E = c(g, w);
                    o(v, E[e]);
                }
                return v;
            };
        })(to)), to.exports;
    }
    var ro, zd;
    function S3() {
        if (zd) return ro;
        zd = 1;
        const { StringPrototypeSlice: r, SymbolIterator: e, TypedArrayPrototypeSet: t, Uint8Array: n } = Ut(), { Buffer: a } = Wr(), { inspect: i } = dr();
        return ro = class {
            constructor(){
                this.head = null, this.tail = null, this.length = 0;
            }
            push(o) {
                const f = {
                    data: o,
                    next: null
                };
                this.length > 0 ? this.tail.next = f : this.head = f, this.tail = f, ++this.length;
            }
            unshift(o) {
                const f = {
                    data: o,
                    next: this.head
                };
                this.length === 0 && (this.tail = f), this.head = f, ++this.length;
            }
            shift() {
                if (this.length === 0) return;
                const o = this.head.data;
                return this.length === 1 ? this.head = this.tail = null : this.head = this.head.next, --this.length, o;
            }
            clear() {
                this.head = this.tail = null, this.length = 0;
            }
            join(o) {
                if (this.length === 0) return "";
                let f = this.head, c = "" + f.data;
                for(; (f = f.next) !== null;)c += o + f.data;
                return c;
            }
            concat(o) {
                if (this.length === 0) return a.alloc(0);
                const f = a.allocUnsafe(o >>> 0);
                let c = this.head, h = 0;
                for(; c;)t(f, c.data, h), h += c.data.length, c = c.next;
                return f;
            }
            consume(o, f) {
                const c = this.head.data;
                if (o < c.length) {
                    const h = c.slice(0, o);
                    return this.head.data = c.slice(o), h;
                }
                return o === c.length ? this.shift() : f ? this._getString(o) : this._getBuffer(o);
            }
            first() {
                return this.head.data;
            }
            *[e]() {
                for(let o = this.head; o; o = o.next)yield o.data;
            }
            _getString(o) {
                let f = "", c = this.head, h = 0;
                do {
                    const g = c.data;
                    if (o > g.length) f += g, o -= g.length;
                    else {
                        o === g.length ? (f += g, ++h, c.next ? this.head = c.next : this.head = this.tail = null) : (f += r(g, 0, o), this.head = c, c.data = r(g, o));
                        break;
                    }
                    ++h;
                }while ((c = c.next) !== null);
                return this.length -= h, f;
            }
            _getBuffer(o) {
                const f = a.allocUnsafe(o), c = o;
                let h = this.head, g = 0;
                do {
                    const v = h.data;
                    if (o > v.length) t(f, v, c - o), o -= v.length;
                    else {
                        o === v.length ? (t(f, v, c - o), ++g, h.next ? this.head = h.next : this.head = this.tail = null) : (t(f, new n(v.buffer, v.byteOffset, o), c - o), this.head = h, h.data = v.slice(o));
                        break;
                    }
                    ++g;
                }while ((h = h.next) !== null);
                return this.length -= g, f;
            }
            [Symbol.for("nodejs.util.inspect.custom")](o, f) {
                return i(this, {
                    ...f,
                    depth: 0,
                    customInspect: !1
                });
            }
        }, ro;
    }
    var no, Wd;
    function Ua() {
        if (Wd) return no;
        Wd = 1;
        const { MathFloor: r, NumberIsInteger: e } = Ut(), { validateInteger: t } = wi(), { ERR_INVALID_ARG_VALUE: n } = ir().codes;
        let a = 16 * 1024, i = 16;
        function s(h, g, v) {
            return h.highWaterMark != null ? h.highWaterMark : g ? h[v] : null;
        }
        function o(h) {
            return h ? i : a;
        }
        function f(h, g) {
            t(g, "value", 0), h ? i = g : a = g;
        }
        function c(h, g, v, w) {
            const E = s(g, w, v);
            if (E != null) {
                if (!e(E) || E < 0) {
                    const x = w ? `options.${v}` : "options.highWaterMark";
                    throw new n(x, E);
                }
                return r(E);
            }
            return o(h.objectMode);
        }
        return no = {
            getHighWaterMark: c,
            getDefaultHighWaterMark: o,
            setDefaultHighWaterMark: f
        }, no;
    }
    var io = {}, $i = {
        exports: {}
    };
    var Yd;
    function E3() {
        return Yd || (Yd = 1, (function(r, e) {
            var t = Wr(), n = t.Buffer;
            function a(s, o) {
                for(var f in s)o[f] = s[f];
            }
            n.from && n.alloc && n.allocUnsafe && n.allocUnsafeSlow ? r.exports = t : (a(t, e), e.Buffer = i);
            function i(s, o, f) {
                return n(s, o, f);
            }
            i.prototype = Object.create(n.prototype), a(n, i), i.from = function(s, o, f) {
                if (typeof s == "number") throw new TypeError("Argument must not be a number");
                return n(s, o, f);
            }, i.alloc = function(s, o, f) {
                if (typeof s != "number") throw new TypeError("Argument must be a number");
                var c = n(s);
                return o !== void 0 ? typeof f == "string" ? c.fill(o, f) : c.fill(o) : c.fill(0), c;
            }, i.allocUnsafe = function(s) {
                if (typeof s != "number") throw new TypeError("Argument must be a number");
                return n(s);
            }, i.allocUnsafeSlow = function(s) {
                if (typeof s != "number") throw new TypeError("Argument must be a number");
                return t.SlowBuffer(s);
            };
        })($i, $i.exports)), $i.exports;
    }
    var Vd;
    function A3() {
        if (Vd) return io;
        Vd = 1;
        var r = E3().Buffer, e = r.isEncoding || function(y) {
            switch(y = "" + y, y && y.toLowerCase()){
                case "hex":
                case "utf8":
                case "utf-8":
                case "ascii":
                case "binary":
                case "base64":
                case "ucs2":
                case "ucs-2":
                case "utf16le":
                case "utf-16le":
                case "raw":
                    return !0;
                default:
                    return !1;
            }
        };
        function t(y) {
            if (!y) return "utf8";
            for(var A;;)switch(y){
                case "utf8":
                case "utf-8":
                    return "utf8";
                case "ucs2":
                case "ucs-2":
                case "utf16le":
                case "utf-16le":
                    return "utf16le";
                case "latin1":
                case "binary":
                    return "latin1";
                case "base64":
                case "ascii":
                case "hex":
                    return y;
                default:
                    if (A) return;
                    y = ("" + y).toLowerCase(), A = !0;
            }
        }
        function n(y) {
            var A = t(y);
            if (typeof A != "string" && (r.isEncoding === e || !e(y))) throw new Error("Unknown encoding: " + y);
            return A || y;
        }
        io.StringDecoder = a;
        function a(y) {
            this.encoding = n(y);
            var A;
            switch(this.encoding){
                case "utf16le":
                    this.text = g, this.end = v, A = 4;
                    break;
                case "utf8":
                    this.fillLast = f, A = 4;
                    break;
                case "base64":
                    this.text = w, this.end = E, A = 3;
                    break;
                default:
                    this.write = x, this.end = S;
                    return;
            }
            this.lastNeed = 0, this.lastTotal = 0, this.lastChar = r.allocUnsafe(A);
        }
        a.prototype.write = function(y) {
            if (y.length === 0) return "";
            var A, P;
            if (this.lastNeed) {
                if (A = this.fillLast(y), A === void 0) return "";
                P = this.lastNeed, this.lastNeed = 0;
            } else P = 0;
            return P < y.length ? A ? A + this.text(y, P) : this.text(y, P) : A || "";
        }, a.prototype.end = h, a.prototype.text = c, a.prototype.fillLast = function(y) {
            if (this.lastNeed <= y.length) return y.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, this.lastNeed), this.lastChar.toString(this.encoding, 0, this.lastTotal);
            y.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, y.length), this.lastNeed -= y.length;
        };
        function i(y) {
            return y <= 127 ? 0 : y >> 5 === 6 ? 2 : y >> 4 === 14 ? 3 : y >> 3 === 30 ? 4 : y >> 6 === 2 ? -1 : -2;
        }
        function s(y, A, P) {
            var N = A.length - 1;
            if (N < P) return 0;
            var k = i(A[N]);
            return k >= 0 ? (k > 0 && (y.lastNeed = k - 1), k) : --N < P || k === -2 ? 0 : (k = i(A[N]), k >= 0 ? (k > 0 && (y.lastNeed = k - 2), k) : --N < P || k === -2 ? 0 : (k = i(A[N]), k >= 0 ? (k > 0 && (k === 2 ? k = 0 : y.lastNeed = k - 3), k) : 0));
        }
        function o(y, A, P) {
            if ((A[0] & 192) !== 128) return y.lastNeed = 0, "�";
            if (y.lastNeed > 1 && A.length > 1) {
                if ((A[1] & 192) !== 128) return y.lastNeed = 1, "�";
                if (y.lastNeed > 2 && A.length > 2 && (A[2] & 192) !== 128) return y.lastNeed = 2, "�";
            }
        }
        function f(y) {
            var A = this.lastTotal - this.lastNeed, P = o(this, y);
            if (P !== void 0) return P;
            if (this.lastNeed <= y.length) return y.copy(this.lastChar, A, 0, this.lastNeed), this.lastChar.toString(this.encoding, 0, this.lastTotal);
            y.copy(this.lastChar, A, 0, y.length), this.lastNeed -= y.length;
        }
        function c(y, A) {
            var P = s(this, y, A);
            if (!this.lastNeed) return y.toString("utf8", A);
            this.lastTotal = P;
            var N = y.length - (P - this.lastNeed);
            return y.copy(this.lastChar, 0, N), y.toString("utf8", A, N);
        }
        function h(y) {
            var A = y && y.length ? this.write(y) : "";
            return this.lastNeed ? A + "�" : A;
        }
        function g(y, A) {
            if ((y.length - A) % 2 === 0) {
                var P = y.toString("utf16le", A);
                if (P) {
                    var N = P.charCodeAt(P.length - 1);
                    if (N >= 55296 && N <= 56319) return this.lastNeed = 2, this.lastTotal = 4, this.lastChar[0] = y[y.length - 2], this.lastChar[1] = y[y.length - 1], P.slice(0, -1);
                }
                return P;
            }
            return this.lastNeed = 1, this.lastTotal = 2, this.lastChar[0] = y[y.length - 1], y.toString("utf16le", A, y.length - 1);
        }
        function v(y) {
            var A = y && y.length ? this.write(y) : "";
            if (this.lastNeed) {
                var P = this.lastTotal - this.lastNeed;
                return A + this.lastChar.toString("utf16le", 0, P);
            }
            return A;
        }
        function w(y, A) {
            var P = (y.length - A) % 3;
            return P === 0 ? y.toString("base64", A) : (this.lastNeed = 3 - P, this.lastTotal = 3, P === 1 ? this.lastChar[0] = y[y.length - 1] : (this.lastChar[0] = y[y.length - 2], this.lastChar[1] = y[y.length - 1]), y.toString("base64", A, y.length - P));
        }
        function E(y) {
            var A = y && y.length ? this.write(y) : "";
            return this.lastNeed ? A + this.lastChar.toString("base64", 0, 3 - this.lastNeed) : A;
        }
        function x(y) {
            return y.toString(this.encoding);
        }
        function S(y) {
            return y && y.length ? this.write(y) : "";
        }
        return io;
    }
    var ao, Gd;
    function vl() {
        if (Gd) return ao;
        Gd = 1;
        const r = Pn(), { PromisePrototypeThen: e, SymbolAsyncIterator: t, SymbolIterator: n } = Ut(), { Buffer: a } = Wr(), { ERR_INVALID_ARG_TYPE: i, ERR_STREAM_NULL_VALUES: s } = ir().codes;
        function o(f, c, h) {
            let g;
            if (typeof c == "string" || c instanceof a) return new f({
                objectMode: !0,
                ...h,
                read () {
                    this.push(c), this.push(null);
                }
            });
            let v;
            if (c && c[t]) v = !0, g = c[t]();
            else if (c && c[n]) v = !1, g = c[n]();
            else throw new i("iterable", [
                "Iterable"
            ], c);
            const w = new f({
                objectMode: !0,
                highWaterMark: 1,
                ...h
            });
            let E = !1;
            w._read = function() {
                E || (E = !0, S());
            }, w._destroy = function(y, A) {
                e(x(y), ()=>r.nextTick(A, y), (P)=>r.nextTick(A, P || y));
            };
            async function x(y) {
                const A = y != null, P = typeof g.throw == "function";
                if (A && P) {
                    const { value: N, done: k } = await g.throw(y);
                    if (await N, k) return;
                }
                if (typeof g.return == "function") {
                    const { value: N } = await g.return();
                    await N;
                }
            }
            async function S() {
                for(;;){
                    try {
                        const { value: y, done: A } = v ? await g.next() : g.next();
                        if (A) w.push(null);
                        else {
                            const P = y && typeof y.then == "function" ? await y : y;
                            if (P === null) throw E = !1, new s;
                            if (w.push(P)) continue;
                            E = !1;
                        }
                    } catch (y) {
                        w.destroy(y);
                    }
                    break;
                }
            }
            return w;
        }
        return ao = o, ao;
    }
    var so, Jd;
    function qa() {
        if (Jd) return so;
        Jd = 1;
        const r = Pn(), { ArrayPrototypeIndexOf: e, NumberIsInteger: t, NumberIsNaN: n, NumberParseInt: a, ObjectDefineProperties: i, ObjectKeys: s, ObjectSetPrototypeOf: o, Promise: f, SafeSet: c, SymbolAsyncDispose: h, SymbolAsyncIterator: g, Symbol: v } = Ut();
        so = se, se.ReadableState = be;
        const { EventEmitter: w } = vi(), { Stream: E, prependListener: x } = Ff(), { Buffer: S } = Wr(), { addAbortSignal: y } = La(), A = ln();
        let P = dr().debuglog("stream", (q)=>{
            P = q;
        });
        const N = S3(), k = Wn(), { getHighWaterMark: D, getDefaultHighWaterMark: V } = Ua(), { aggregateTwoErrors: K, codes: { ERR_INVALID_ARG_TYPE: j, ERR_METHOD_NOT_IMPLEMENTED: H, ERR_OUT_OF_RANGE: O, ERR_STREAM_PUSH_AFTER_EOF: d, ERR_STREAM_UNSHIFT_AFTER_END_EVENT: l }, AbortError: b } = ir(), { validateObject: m } = wi(), _ = v("kPaused"), { StringDecoder: B } = A3(), T = vl();
        o(se.prototype, E.prototype), o(se, E);
        const R = ()=>{}, { errorOrDestroy: u } = k, I = 1, G = 2, $ = 4, te = 8, Z = 16, fe = 32, pe = 64, ee = 128, J = 256, oe = 512, Me = 1024, xe = 2048, z = 4096, X = 8192, re = 16384, ge = 32768, Se = 65536, ye = 1 << 17, Y = 1 << 18;
        function le(q) {
            return {
                enumerable: !1,
                get () {
                    return (this.state & q) !== 0;
                },
                set (F) {
                    F ? this.state |= q : this.state &= ~q;
                }
            };
        }
        i(be.prototype, {
            objectMode: le(I),
            ended: le(G),
            endEmitted: le($),
            reading: le(te),
            constructed: le(Z),
            sync: le(fe),
            needReadable: le(pe),
            emittedReadable: le(ee),
            readableListening: le(J),
            resumeScheduled: le(oe),
            errorEmitted: le(Me),
            emitClose: le(xe),
            autoDestroy: le(z),
            destroyed: le(X),
            closed: le(re),
            closeEmitted: le(ge),
            multiAwaitDrain: le(Se),
            readingMore: le(ye),
            dataEmitted: le(Y)
        });
        function be(q, F, _e) {
            typeof _e != "boolean" && (_e = F instanceof Hr()), this.state = xe | z | Z | fe, q && q.objectMode && (this.state |= I), _e && q && q.readableObjectMode && (this.state |= I), this.highWaterMark = q ? D(this, q, "readableHighWaterMark", _e) : V(!1), this.buffer = new N, this.length = 0, this.pipes = [], this.flowing = null, this[_] = null, q && q.emitClose === !1 && (this.state &= ~xe), q && q.autoDestroy === !1 && (this.state &= ~z), this.errored = null, this.defaultEncoding = q && q.defaultEncoding || "utf8", this.awaitDrainWriters = null, this.decoder = null, this.encoding = null, q && q.encoding && (this.decoder = new B(q.encoding), this.encoding = q.encoding);
        }
        function se(q) {
            if (!(this instanceof se)) return new se(q);
            const F = this instanceof Hr();
            this._readableState = new be(q, this, F), q && (typeof q.read == "function" && (this._read = q.read), typeof q.destroy == "function" && (this._destroy = q.destroy), typeof q.construct == "function" && (this._construct = q.construct), q.signal && !F && y(q.signal, this)), E.call(this, q), k.construct(this, ()=>{
                this._readableState.needReadable && et(this, this._readableState);
            });
        }
        se.prototype.destroy = k.destroy, se.prototype._undestroy = k.undestroy, se.prototype._destroy = function(q, F) {
            F(q);
        }, se.prototype[w.captureRejectionSymbol] = function(q) {
            this.destroy(q);
        }, se.prototype[h] = function() {
            let q;
            return this.destroyed || (q = this.readableEnded ? null : new b, this.destroy(q)), new f((F, _e)=>A(this, (Re)=>Re && Re !== q ? _e(Re) : F(null)));
        }, se.prototype.push = function(q, F) {
            return De(this, q, F, !1);
        }, se.prototype.unshift = function(q, F) {
            return De(this, q, F, !0);
        };
        function De(q, F, _e, Re) {
            P("readableAddChunk", F);
            const Ae = q._readableState;
            let ut;
            if ((Ae.state & I) === 0 && (typeof F == "string" ? (_e = _e || Ae.defaultEncoding, Ae.encoding !== _e && (Re && Ae.encoding ? F = S.from(F, _e).toString(Ae.encoding) : (F = S.from(F, _e), _e = ""))) : F instanceof S ? _e = "" : E._isUint8Array(F) ? (F = E._uint8ArrayToBuffer(F), _e = "") : F != null && (ut = new j("chunk", [
                "string",
                "Buffer",
                "Uint8Array"
            ], F))), ut) u(q, ut);
            else if (F === null) Ae.state &= ~te, Qe(q, Ae);
            else if ((Ae.state & I) !== 0 || F && F.length > 0) if (Re) if ((Ae.state & $) !== 0) u(q, new l);
            else {
                if (Ae.destroyed || Ae.errored) return !1;
                ze(q, Ae, F, !0);
            }
            else if (Ae.ended) u(q, new d);
            else {
                if (Ae.destroyed || Ae.errored) return !1;
                Ae.state &= ~te, Ae.decoder && !_e ? (F = Ae.decoder.write(F), Ae.objectMode || F.length !== 0 ? ze(q, Ae, F, !1) : et(q, Ae)) : ze(q, Ae, F, !1);
            }
            else Re || (Ae.state &= ~te, et(q, Ae));
            return !Ae.ended && (Ae.length < Ae.highWaterMark || Ae.length === 0);
        }
        function ze(q, F, _e, Re) {
            F.flowing && F.length === 0 && !F.sync && q.listenerCount("data") > 0 ? ((F.state & Se) !== 0 ? F.awaitDrainWriters.clear() : F.awaitDrainWriters = null, F.dataEmitted = !0, q.emit("data", _e)) : (F.length += F.objectMode ? 1 : _e.length, Re ? F.buffer.unshift(_e) : F.buffer.push(_e), (F.state & pe) !== 0 && qt(q)), et(q, F);
        }
        se.prototype.isPaused = function() {
            const q = this._readableState;
            return q[_] === !0 || q.flowing === !1;
        }, se.prototype.setEncoding = function(q) {
            const F = new B(q);
            this._readableState.decoder = F, this._readableState.encoding = this._readableState.decoder.encoding;
            const _e = this._readableState.buffer;
            let Re = "";
            for (const Ae of _e)Re += F.write(Ae);
            return _e.clear(), Re !== "" && _e.push(Re), this._readableState.length = Re.length, this;
        };
        const $e = 1073741824;
        function Ze(q) {
            if (q > $e) throw new O("size", "<= 1GiB", q);
            return q--, q |= q >>> 1, q |= q >>> 2, q |= q >>> 4, q |= q >>> 8, q |= q >>> 16, q++, q;
        }
        function je(q, F) {
            return q <= 0 || F.length === 0 && F.ended ? 0 : (F.state & I) !== 0 ? 1 : n(q) ? F.flowing && F.length ? F.buffer.first().length : F.length : q <= F.length ? q : F.ended ? F.length : 0;
        }
        se.prototype.read = function(q) {
            P("read", q), q === void 0 ? q = NaN : t(q) || (q = a(q, 10));
            const F = this._readableState, _e = q;
            if (q > F.highWaterMark && (F.highWaterMark = Ze(q)), q !== 0 && (F.state &= ~ee), q === 0 && F.needReadable && ((F.highWaterMark !== 0 ? F.length >= F.highWaterMark : F.length > 0) || F.ended)) return P("read: emitReadable", F.length, F.ended), F.length === 0 && F.ended ? Ot(this) : qt(this), null;
            if (q = je(q, F), q === 0 && F.ended) return F.length === 0 && Ot(this), null;
            let Re = (F.state & pe) !== 0;
            if (P("need readable", Re), (F.length === 0 || F.length - q < F.highWaterMark) && (Re = !0, P("length less than watermark", Re)), F.ended || F.reading || F.destroyed || F.errored || !F.constructed) Re = !1, P("reading, ended or constructing", Re);
            else if (Re) {
                P("do read"), F.state |= te | fe, F.length === 0 && (F.state |= pe);
                try {
                    this._read(F.highWaterMark);
                } catch (ut) {
                    u(this, ut);
                }
                F.state &= ~fe, F.reading || (q = je(_e, F));
            }
            let Ae;
            return q > 0 ? Ae = Xr(q, F) : Ae = null, Ae === null ? (F.needReadable = F.length <= F.highWaterMark, q = 0) : (F.length -= q, F.multiAwaitDrain ? F.awaitDrainWriters.clear() : F.awaitDrainWriters = null), F.length === 0 && (F.ended || (F.needReadable = !0), _e !== q && F.ended && Ot(this)), Ae !== null && !F.errorEmitted && !F.closeEmitted && (F.dataEmitted = !0, this.emit("data", Ae)), Ae;
        };
        function Qe(q, F) {
            if (P("onEofChunk"), !F.ended) {
                if (F.decoder) {
                    const _e = F.decoder.end();
                    _e && _e.length && (F.buffer.push(_e), F.length += F.objectMode ? 1 : _e.length);
                }
                F.ended = !0, F.sync ? qt(q) : (F.needReadable = !1, F.emittedReadable = !0, bt(q));
            }
        }
        function qt(q) {
            const F = q._readableState;
            P("emitReadable", F.needReadable, F.emittedReadable), F.needReadable = !1, F.emittedReadable || (P("emitReadable", F.flowing), F.emittedReadable = !0, r.nextTick(bt, q));
        }
        function bt(q) {
            const F = q._readableState;
            P("emitReadable_", F.destroyed, F.length, F.ended), !F.destroyed && !F.errored && (F.length || F.ended) && (q.emit("readable"), F.emittedReadable = !1), F.needReadable = !F.flowing && !F.ended && F.length <= F.highWaterMark, ar(q);
        }
        function et(q, F) {
            !F.readingMore && F.constructed && (F.readingMore = !0, r.nextTick(ne, q, F));
        }
        function ne(q, F) {
            for(; !F.reading && !F.ended && (F.length < F.highWaterMark || F.flowing && F.length === 0);){
                const _e = F.length;
                if (P("maybeReadMore read 0"), q.read(0), _e === F.length) break;
            }
            F.readingMore = !1;
        }
        se.prototype._read = function(q) {
            throw new H("_read()");
        }, se.prototype.pipe = function(q, F) {
            const _e = this, Re = this._readableState;
            Re.pipes.length === 1 && (Re.multiAwaitDrain || (Re.multiAwaitDrain = !0, Re.awaitDrainWriters = new c(Re.awaitDrainWriters ? [
                Re.awaitDrainWriters
            ] : []))), Re.pipes.push(q), P("pipe count=%d opts=%j", Re.pipes.length, F);
            const ut = (!F || F.end !== !1) && q !== r.stdout && q !== r.stderr ? L : Te;
            Re.endEmitted ? r.nextTick(ut) : _e.once("end", ut), q.on("unpipe", M);
            function M(st, Pe) {
                P("onunpipe"), st === _e && Pe && Pe.hasUnpiped === !1 && (Pe.hasUnpiped = !0, U());
            }
            function L() {
                P("onend"), q.end();
            }
            let C, p = !1;
            function U() {
                P("cleanup"), q.removeListener("close", ve), q.removeListener("finish", Ce), C && q.removeListener("drain", C), q.removeListener("error", ue), q.removeListener("unpipe", M), _e.removeListener("end", L), _e.removeListener("end", Te), _e.removeListener("data", ie), p = !0, C && Re.awaitDrainWriters && (!q._writableState || q._writableState.needDrain) && C();
            }
            function Q() {
                p || (Re.pipes.length === 1 && Re.pipes[0] === q ? (P("false write response, pause", 0), Re.awaitDrainWriters = q, Re.multiAwaitDrain = !1) : Re.pipes.length > 1 && Re.pipes.includes(q) && (P("false write response, pause", Re.awaitDrainWriters.size), Re.awaitDrainWriters.add(q)), _e.pause()), C || (C = Oe(_e, q), q.on("drain", C));
            }
            _e.on("data", ie);
            function ie(st) {
                P("ondata");
                const Pe = q.write(st);
                P("dest.write", Pe), Pe === !1 && Q();
            }
            function ue(st) {
                if (P("onerror", st), Te(), q.removeListener("error", ue), q.listenerCount("error") === 0) {
                    const Pe = q._writableState || q._readableState;
                    Pe && !Pe.errorEmitted ? u(q, st) : q.emit("error", st);
                }
            }
            x(q, "error", ue);
            function ve() {
                q.removeListener("finish", Ce), Te();
            }
            q.once("close", ve);
            function Ce() {
                P("onfinish"), q.removeListener("close", ve), Te();
            }
            q.once("finish", Ce);
            function Te() {
                P("unpipe"), _e.unpipe(q);
            }
            return q.emit("pipe", _e), q.writableNeedDrain === !0 ? Q() : Re.flowing || (P("pipe resume"), _e.resume()), q;
        };
        function Oe(q, F) {
            return function() {
                const Re = q._readableState;
                Re.awaitDrainWriters === F ? (P("pipeOnDrain", 1), Re.awaitDrainWriters = null) : Re.multiAwaitDrain && (P("pipeOnDrain", Re.awaitDrainWriters.size), Re.awaitDrainWriters.delete(F)), (!Re.awaitDrainWriters || Re.awaitDrainWriters.size === 0) && q.listenerCount("data") && q.resume();
            };
        }
        se.prototype.unpipe = function(q) {
            const F = this._readableState, _e = {
                hasUnpiped: !1
            };
            if (F.pipes.length === 0) return this;
            if (!q) {
                const Ae = F.pipes;
                F.pipes = [], this.pause();
                for(let ut = 0; ut < Ae.length; ut++)Ae[ut].emit("unpipe", this, {
                    hasUnpiped: !1
                });
                return this;
            }
            const Re = e(F.pipes, q);
            return Re === -1 ? this : (F.pipes.splice(Re, 1), F.pipes.length === 0 && this.pause(), q.emit("unpipe", this, _e), this);
        }, se.prototype.on = function(q, F) {
            const _e = E.prototype.on.call(this, q, F), Re = this._readableState;
            return q === "data" ? (Re.readableListening = this.listenerCount("readable") > 0, Re.flowing !== !1 && this.resume()) : q === "readable" && !Re.endEmitted && !Re.readableListening && (Re.readableListening = Re.needReadable = !0, Re.flowing = !1, Re.emittedReadable = !1, P("on readable", Re.length, Re.reading), Re.length ? qt(this) : Re.reading || r.nextTick(Pt, this)), _e;
        }, se.prototype.addListener = se.prototype.on, se.prototype.removeListener = function(q, F) {
            const _e = E.prototype.removeListener.call(this, q, F);
            return q === "readable" && r.nextTick(We, this), _e;
        }, se.prototype.off = se.prototype.removeListener, se.prototype.removeAllListeners = function(q) {
            const F = E.prototype.removeAllListeners.apply(this, arguments);
            return (q === "readable" || q === void 0) && r.nextTick(We, this), F;
        };
        function We(q) {
            const F = q._readableState;
            F.readableListening = q.listenerCount("readable") > 0, F.resumeScheduled && F[_] === !1 ? F.flowing = !0 : q.listenerCount("data") > 0 ? q.resume() : F.readableListening || (F.flowing = null);
        }
        function Pt(q) {
            P("readable nexttick read 0"), q.read(0);
        }
        se.prototype.resume = function() {
            const q = this._readableState;
            return q.flowing || (P("resume"), q.flowing = !q.readableListening, pt(this, q)), q[_] = !1, this;
        };
        function pt(q, F) {
            F.resumeScheduled || (F.resumeScheduled = !0, r.nextTick(St, q, F));
        }
        function St(q, F) {
            P("resume", F.reading), F.reading || q.read(0), F.resumeScheduled = !1, q.emit("resume"), ar(q), F.flowing && !F.reading && q.read(0);
        }
        se.prototype.pause = function() {
            return P("call pause flowing=%j", this._readableState.flowing), this._readableState.flowing !== !1 && (P("pause"), this._readableState.flowing = !1, this.emit("pause")), this._readableState[_] = !0, this;
        };
        function ar(q) {
            const F = q._readableState;
            for(P("flow", F.flowing); F.flowing && q.read() !== null;);
        }
        se.prototype.wrap = function(q) {
            let F = !1;
            q.on("data", (Re)=>{
                !this.push(Re) && q.pause && (F = !0, q.pause());
            }), q.on("end", ()=>{
                this.push(null);
            }), q.on("error", (Re)=>{
                u(this, Re);
            }), q.on("close", ()=>{
                this.destroy();
            }), q.on("destroy", ()=>{
                this.destroy();
            }), this._read = ()=>{
                F && q.resume && (F = !1, q.resume());
            };
            const _e = s(q);
            for(let Re = 1; Re < _e.length; Re++){
                const Ae = _e[Re];
                this[Ae] === void 0 && typeof q[Ae] == "function" && (this[Ae] = q[Ae].bind(q));
            }
            return this;
        }, se.prototype[g] = function() {
            return It(this);
        }, se.prototype.iterator = function(q) {
            return q !== void 0 && m(q, "options"), It(this, q);
        };
        function It(q, F) {
            typeof q.read != "function" && (q = se.wrap(q, {
                objectMode: !0
            }));
            const _e = Bt(q, F);
            return _e.stream = q, _e;
        }
        async function* Bt(q, F) {
            let _e = R;
            function Re(M) {
                this === q ? (_e(), _e = R) : _e = M;
            }
            q.on("readable", Re);
            let Ae;
            const ut = A(q, {
                writable: !1
            }, (M)=>{
                Ae = M ? K(Ae, M) : null, _e(), _e = R;
            });
            try {
                for(;;){
                    const M = q.destroyed ? null : q.read();
                    if (M !== null) yield M;
                    else {
                        if (Ae) throw Ae;
                        if (Ae === null) return;
                        await new f(Re);
                    }
                }
            } catch (M) {
                throw Ae = K(Ae, M), Ae;
            } finally{
                (Ae || F?.destroyOnReturn !== !1) && (Ae === void 0 || q._readableState.autoDestroy) ? k.destroyer(q, null) : (q.off("readable", Re), ut());
            }
        }
        i(se.prototype, {
            readable: {
                __proto__: null,
                get () {
                    const q = this._readableState;
                    return !!q && q.readable !== !1 && !q.destroyed && !q.errorEmitted && !q.endEmitted;
                },
                set (q) {
                    this._readableState && (this._readableState.readable = !!q);
                }
            },
            readableDidRead: {
                __proto__: null,
                enumerable: !1,
                get: function() {
                    return this._readableState.dataEmitted;
                }
            },
            readableAborted: {
                __proto__: null,
                enumerable: !1,
                get: function() {
                    return !!(this._readableState.readable !== !1 && (this._readableState.destroyed || this._readableState.errored) && !this._readableState.endEmitted);
                }
            },
            readableHighWaterMark: {
                __proto__: null,
                enumerable: !1,
                get: function() {
                    return this._readableState.highWaterMark;
                }
            },
            readableBuffer: {
                __proto__: null,
                enumerable: !1,
                get: function() {
                    return this._readableState && this._readableState.buffer;
                }
            },
            readableFlowing: {
                __proto__: null,
                enumerable: !1,
                get: function() {
                    return this._readableState.flowing;
                },
                set: function(q) {
                    this._readableState && (this._readableState.flowing = q);
                }
            },
            readableLength: {
                __proto__: null,
                enumerable: !1,
                get () {
                    return this._readableState.length;
                }
            },
            readableObjectMode: {
                __proto__: null,
                enumerable: !1,
                get () {
                    return this._readableState ? this._readableState.objectMode : !1;
                }
            },
            readableEncoding: {
                __proto__: null,
                enumerable: !1,
                get () {
                    return this._readableState ? this._readableState.encoding : null;
                }
            },
            errored: {
                __proto__: null,
                enumerable: !1,
                get () {
                    return this._readableState ? this._readableState.errored : null;
                }
            },
            closed: {
                __proto__: null,
                get () {
                    return this._readableState ? this._readableState.closed : !1;
                }
            },
            destroyed: {
                __proto__: null,
                enumerable: !1,
                get () {
                    return this._readableState ? this._readableState.destroyed : !1;
                },
                set (q) {
                    this._readableState && (this._readableState.destroyed = q);
                }
            },
            readableEnded: {
                __proto__: null,
                enumerable: !1,
                get () {
                    return this._readableState ? this._readableState.endEmitted : !1;
                }
            }
        }), i(be.prototype, {
            pipesCount: {
                __proto__: null,
                get () {
                    return this.pipes.length;
                }
            },
            paused: {
                __proto__: null,
                get () {
                    return this[_] !== !1;
                },
                set (q) {
                    this[_] = !!q;
                }
            }
        }), se._fromList = Xr;
        function Xr(q, F) {
            if (F.length === 0) return null;
            let _e;
            return F.objectMode ? _e = F.buffer.shift() : !q || q >= F.length ? (F.decoder ? _e = F.buffer.join("") : F.buffer.length === 1 ? _e = F.buffer.first() : _e = F.buffer.concat(F.length), F.buffer.clear()) : _e = F.buffer.consume(q, F.decoder), _e;
        }
        function Ot(q) {
            const F = q._readableState;
            P("endReadable", F.endEmitted), F.endEmitted || (F.ended = !0, r.nextTick(Nt, F, q));
        }
        function Nt(q, F) {
            if (P("endReadableNT", q.endEmitted, q.length), !q.errored && !q.closeEmitted && !q.endEmitted && q.length === 0) {
                if (q.endEmitted = !0, F.emit("end"), F.writable && F.allowHalfOpen === !1) r.nextTick(sr, F);
                else if (q.autoDestroy) {
                    const _e = F._writableState;
                    (!_e || _e.autoDestroy && (_e.finished || _e.writable === !1)) && F.destroy();
                }
            }
        }
        function sr(q) {
            q.writable && !q.writableEnded && !q.destroyed && q.end();
        }
        se.from = function(q, F) {
            return T(se, q, F);
        };
        let _t;
        function Et() {
            return _t === void 0 && (_t = {}), _t;
        }
        return se.fromWeb = function(q, F) {
            return Et().newStreamReadableFromReadableStream(q, F);
        }, se.toWeb = function(q, F) {
            return Et().newReadableStreamFromStreamReadable(q, F);
        }, se.wrap = function(q, F) {
            var _e, Re;
            return new se({
                objectMode: (_e = (Re = q.readableObjectMode) !== null && Re !== void 0 ? Re : q.objectMode) !== null && _e !== void 0 ? _e : !0,
                ...F,
                destroy (Ae, ut) {
                    k.destroyer(q, Ae), ut(Ae);
                }
            }).wrap(q);
        }, so;
    }
    var oo, Xd;
    function $f() {
        if (Xd) return oo;
        Xd = 1;
        const r = Pn(), { ArrayPrototypeSlice: e, Error: t, FunctionPrototypeSymbolHasInstance: n, ObjectDefineProperty: a, ObjectDefineProperties: i, ObjectSetPrototypeOf: s, StringPrototypeToLowerCase: o, Symbol: f, SymbolHasInstance: c } = Ut();
        oo = m, m.WritableState = l;
        const { EventEmitter: h } = vi(), g = Ff().Stream, { Buffer: v } = Wr(), w = Wn(), { addAbortSignal: E } = La(), { getHighWaterMark: x, getDefaultHighWaterMark: S } = Ua(), { ERR_INVALID_ARG_TYPE: y, ERR_METHOD_NOT_IMPLEMENTED: A, ERR_MULTIPLE_CALLBACK: P, ERR_STREAM_CANNOT_PIPE: N, ERR_STREAM_DESTROYED: k, ERR_STREAM_ALREADY_FINISHED: D, ERR_STREAM_NULL_VALUES: V, ERR_STREAM_WRITE_AFTER_END: K, ERR_UNKNOWN_ENCODING: j } = ir().codes, { errorOrDestroy: H } = w;
        s(m.prototype, g.prototype), s(m, g);
        function O() {}
        const d = f("kOnFinished");
        function l(z, X, re) {
            typeof re != "boolean" && (re = X instanceof Hr()), this.objectMode = !!(z && z.objectMode), re && (this.objectMode = this.objectMode || !!(z && z.writableObjectMode)), this.highWaterMark = z ? x(this, z, "writableHighWaterMark", re) : S(!1), this.finalCalled = !1, this.needDrain = !1, this.ending = !1, this.ended = !1, this.finished = !1, this.destroyed = !1;
            const ge = !!(z && z.decodeStrings === !1);
            this.decodeStrings = !ge, this.defaultEncoding = z && z.defaultEncoding || "utf8", this.length = 0, this.writing = !1, this.corked = 0, this.sync = !0, this.bufferProcessing = !1, this.onwrite = u.bind(void 0, X), this.writecb = null, this.writelen = 0, this.afterWriteTickInfo = null, b(this), this.pendingcb = 0, this.constructed = !0, this.prefinished = !1, this.errorEmitted = !1, this.emitClose = !z || z.emitClose !== !1, this.autoDestroy = !z || z.autoDestroy !== !1, this.errored = null, this.closed = !1, this.closeEmitted = !1, this[d] = [];
        }
        function b(z) {
            z.buffered = [], z.bufferedIndex = 0, z.allBuffers = !0, z.allNoop = !0;
        }
        l.prototype.getBuffer = function() {
            return e(this.buffered, this.bufferedIndex);
        }, a(l.prototype, "bufferedRequestCount", {
            __proto__: null,
            get () {
                return this.buffered.length - this.bufferedIndex;
            }
        });
        function m(z) {
            const X = this instanceof Hr();
            if (!X && !n(m, this)) return new m(z);
            this._writableState = new l(z, this, X), z && (typeof z.write == "function" && (this._write = z.write), typeof z.writev == "function" && (this._writev = z.writev), typeof z.destroy == "function" && (this._destroy = z.destroy), typeof z.final == "function" && (this._final = z.final), typeof z.construct == "function" && (this._construct = z.construct), z.signal && E(z.signal, this)), g.call(this, z), w.construct(this, ()=>{
                const re = this._writableState;
                re.writing || te(this, re), ee(this, re);
            });
        }
        a(m, c, {
            __proto__: null,
            value: function(z) {
                return n(this, z) ? !0 : this !== m ? !1 : z && z._writableState instanceof l;
            }
        }), m.prototype.pipe = function() {
            H(this, new N);
        };
        function _(z, X, re, ge) {
            const Se = z._writableState;
            if (typeof re == "function") ge = re, re = Se.defaultEncoding;
            else {
                if (!re) re = Se.defaultEncoding;
                else if (re !== "buffer" && !v.isEncoding(re)) throw new j(re);
                typeof ge != "function" && (ge = O);
            }
            if (X === null) throw new V;
            if (!Se.objectMode) if (typeof X == "string") Se.decodeStrings !== !1 && (X = v.from(X, re), re = "buffer");
            else if (X instanceof v) re = "buffer";
            else if (g._isUint8Array(X)) X = g._uint8ArrayToBuffer(X), re = "buffer";
            else throw new y("chunk", [
                "string",
                "Buffer",
                "Uint8Array"
            ], X);
            let ye;
            return Se.ending ? ye = new K : Se.destroyed && (ye = new k("write")), ye ? (r.nextTick(ge, ye), H(z, ye, !0), ye) : (Se.pendingcb++, B(z, Se, X, re, ge));
        }
        m.prototype.write = function(z, X, re) {
            return _(this, z, X, re) === !0;
        }, m.prototype.cork = function() {
            this._writableState.corked++;
        }, m.prototype.uncork = function() {
            const z = this._writableState;
            z.corked && (z.corked--, z.writing || te(this, z));
        }, m.prototype.setDefaultEncoding = function(X) {
            if (typeof X == "string" && (X = o(X)), !v.isEncoding(X)) throw new j(X);
            return this._writableState.defaultEncoding = X, this;
        };
        function B(z, X, re, ge, Se) {
            const ye = X.objectMode ? 1 : re.length;
            X.length += ye;
            const Y = X.length < X.highWaterMark;
            return Y || (X.needDrain = !0), X.writing || X.corked || X.errored || !X.constructed ? (X.buffered.push({
                chunk: re,
                encoding: ge,
                callback: Se
            }), X.allBuffers && ge !== "buffer" && (X.allBuffers = !1), X.allNoop && Se !== O && (X.allNoop = !1)) : (X.writelen = ye, X.writecb = Se, X.writing = !0, X.sync = !0, z._write(re, ge, X.onwrite), X.sync = !1), Y && !X.errored && !X.destroyed;
        }
        function T(z, X, re, ge, Se, ye, Y) {
            X.writelen = ge, X.writecb = Y, X.writing = !0, X.sync = !0, X.destroyed ? X.onwrite(new k("write")) : re ? z._writev(Se, X.onwrite) : z._write(Se, ye, X.onwrite), X.sync = !1;
        }
        function R(z, X, re, ge) {
            --X.pendingcb, ge(re), $(X), H(z, re);
        }
        function u(z, X) {
            const re = z._writableState, ge = re.sync, Se = re.writecb;
            if (typeof Se != "function") {
                H(z, new P);
                return;
            }
            re.writing = !1, re.writecb = null, re.length -= re.writelen, re.writelen = 0, X ? (X.stack, re.errored || (re.errored = X), z._readableState && !z._readableState.errored && (z._readableState.errored = X), ge ? r.nextTick(R, z, re, X, Se) : R(z, re, X, Se)) : (re.buffered.length > re.bufferedIndex && te(z, re), ge ? re.afterWriteTickInfo !== null && re.afterWriteTickInfo.cb === Se ? re.afterWriteTickInfo.count++ : (re.afterWriteTickInfo = {
                count: 1,
                cb: Se,
                stream: z,
                state: re
            }, r.nextTick(I, re.afterWriteTickInfo)) : G(z, re, 1, Se));
        }
        function I({ stream: z, state: X, count: re, cb: ge }) {
            return X.afterWriteTickInfo = null, G(z, X, re, ge);
        }
        function G(z, X, re, ge) {
            for(!X.ending && !z.destroyed && X.length === 0 && X.needDrain && (X.needDrain = !1, z.emit("drain")); re-- > 0;)X.pendingcb--, ge();
            X.destroyed && $(X), ee(z, X);
        }
        function $(z) {
            if (z.writing) return;
            for(let Se = z.bufferedIndex; Se < z.buffered.length; ++Se){
                var X;
                const { chunk: ye, callback: Y } = z.buffered[Se], le = z.objectMode ? 1 : ye.length;
                z.length -= le, Y((X = z.errored) !== null && X !== void 0 ? X : new k("write"));
            }
            const re = z[d].splice(0);
            for(let Se = 0; Se < re.length; Se++){
                var ge;
                re[Se]((ge = z.errored) !== null && ge !== void 0 ? ge : new k("end"));
            }
            b(z);
        }
        function te(z, X) {
            if (X.corked || X.bufferProcessing || X.destroyed || !X.constructed) return;
            const { buffered: re, bufferedIndex: ge, objectMode: Se } = X, ye = re.length - ge;
            if (!ye) return;
            let Y = ge;
            if (X.bufferProcessing = !0, ye > 1 && z._writev) {
                X.pendingcb -= ye - 1;
                const le = X.allNoop ? O : (se)=>{
                    for(let De = Y; De < re.length; ++De)re[De].callback(se);
                }, be = X.allNoop && Y === 0 ? re : e(re, Y);
                be.allBuffers = X.allBuffers, T(z, X, !0, X.length, be, "", le), b(X);
            } else {
                do {
                    const { chunk: le, encoding: be, callback: se } = re[Y];
                    re[Y++] = null;
                    const De = Se ? 1 : le.length;
                    T(z, X, !1, De, le, be, se);
                }while (Y < re.length && !X.writing);
                Y === re.length ? b(X) : Y > 256 ? (re.splice(0, Y), X.bufferedIndex = 0) : X.bufferedIndex = Y;
            }
            X.bufferProcessing = !1;
        }
        m.prototype._write = function(z, X, re) {
            if (this._writev) this._writev([
                {
                    chunk: z,
                    encoding: X
                }
            ], re);
            else throw new A("_write()");
        }, m.prototype._writev = null, m.prototype.end = function(z, X, re) {
            const ge = this._writableState;
            typeof z == "function" ? (re = z, z = null, X = null) : typeof X == "function" && (re = X, X = null);
            let Se;
            if (z != null) {
                const ye = _(this, z, X);
                ye instanceof t && (Se = ye);
            }
            return ge.corked && (ge.corked = 1, this.uncork()), Se || (!ge.errored && !ge.ending ? (ge.ending = !0, ee(this, ge, !0), ge.ended = !0) : ge.finished ? Se = new D("end") : ge.destroyed && (Se = new k("end"))), typeof re == "function" && (Se || ge.finished ? r.nextTick(re, Se) : ge[d].push(re)), this;
        };
        function Z(z) {
            return z.ending && !z.destroyed && z.constructed && z.length === 0 && !z.errored && z.buffered.length === 0 && !z.finished && !z.writing && !z.errorEmitted && !z.closeEmitted;
        }
        function fe(z, X) {
            let re = !1;
            function ge(Se) {
                if (re) {
                    H(z, Se ?? P());
                    return;
                }
                if (re = !0, X.pendingcb--, Se) {
                    const ye = X[d].splice(0);
                    for(let Y = 0; Y < ye.length; Y++)ye[Y](Se);
                    H(z, Se, X.sync);
                } else Z(X) && (X.prefinished = !0, z.emit("prefinish"), X.pendingcb++, r.nextTick(J, z, X));
            }
            X.sync = !0, X.pendingcb++;
            try {
                z._final(ge);
            } catch (Se) {
                ge(Se);
            }
            X.sync = !1;
        }
        function pe(z, X) {
            !X.prefinished && !X.finalCalled && (typeof z._final == "function" && !X.destroyed ? (X.finalCalled = !0, fe(z, X)) : (X.prefinished = !0, z.emit("prefinish")));
        }
        function ee(z, X, re) {
            Z(X) && (pe(z, X), X.pendingcb === 0 && (re ? (X.pendingcb++, r.nextTick((ge, Se)=>{
                Z(Se) ? J(ge, Se) : Se.pendingcb--;
            }, z, X)) : Z(X) && (X.pendingcb++, J(z, X))));
        }
        function J(z, X) {
            X.pendingcb--, X.finished = !0;
            const re = X[d].splice(0);
            for(let ge = 0; ge < re.length; ge++)re[ge]();
            if (z.emit("finish"), X.autoDestroy) {
                const ge = z._readableState;
                (!ge || ge.autoDestroy && (ge.endEmitted || ge.readable === !1)) && z.destroy();
            }
        }
        i(m.prototype, {
            closed: {
                __proto__: null,
                get () {
                    return this._writableState ? this._writableState.closed : !1;
                }
            },
            destroyed: {
                __proto__: null,
                get () {
                    return this._writableState ? this._writableState.destroyed : !1;
                },
                set (z) {
                    this._writableState && (this._writableState.destroyed = z);
                }
            },
            writable: {
                __proto__: null,
                get () {
                    const z = this._writableState;
                    return !!z && z.writable !== !1 && !z.destroyed && !z.errored && !z.ending && !z.ended;
                },
                set (z) {
                    this._writableState && (this._writableState.writable = !!z);
                }
            },
            writableFinished: {
                __proto__: null,
                get () {
                    return this._writableState ? this._writableState.finished : !1;
                }
            },
            writableObjectMode: {
                __proto__: null,
                get () {
                    return this._writableState ? this._writableState.objectMode : !1;
                }
            },
            writableBuffer: {
                __proto__: null,
                get () {
                    return this._writableState && this._writableState.getBuffer();
                }
            },
            writableEnded: {
                __proto__: null,
                get () {
                    return this._writableState ? this._writableState.ending : !1;
                }
            },
            writableNeedDrain: {
                __proto__: null,
                get () {
                    const z = this._writableState;
                    return z ? !z.destroyed && !z.ending && z.needDrain : !1;
                }
            },
            writableHighWaterMark: {
                __proto__: null,
                get () {
                    return this._writableState && this._writableState.highWaterMark;
                }
            },
            writableCorked: {
                __proto__: null,
                get () {
                    return this._writableState ? this._writableState.corked : 0;
                }
            },
            writableLength: {
                __proto__: null,
                get () {
                    return this._writableState && this._writableState.length;
                }
            },
            errored: {
                __proto__: null,
                enumerable: !1,
                get () {
                    return this._writableState ? this._writableState.errored : null;
                }
            },
            writableAborted: {
                __proto__: null,
                enumerable: !1,
                get: function() {
                    return !!(this._writableState.writable !== !1 && (this._writableState.destroyed || this._writableState.errored) && !this._writableState.finished);
                }
            }
        });
        const oe = w.destroy;
        m.prototype.destroy = function(z, X) {
            const re = this._writableState;
            return !re.destroyed && (re.bufferedIndex < re.buffered.length || re[d].length) && r.nextTick($, re), oe.call(this, z, X), this;
        }, m.prototype._undestroy = w.undestroy, m.prototype._destroy = function(z, X) {
            X(z);
        }, m.prototype[h.captureRejectionSymbol] = function(z) {
            this.destroy(z);
        };
        let Me;
        function xe() {
            return Me === void 0 && (Me = {}), Me;
        }
        return m.fromWeb = function(z, X) {
            return xe().newStreamWritableFromWritableStream(z, X);
        }, m.toWeb = function(z) {
            return xe().newWritableStreamFromStreamWritable(z);
        }, oo;
    }
    var fo, Zd;
    function I3() {
        if (Zd) return fo;
        Zd = 1;
        const r = Pn(), e = Wr(), { isReadable: t, isWritable: n, isIterable: a, isNodeStream: i, isReadableNodeStream: s, isWritableNodeStream: o, isDuplexNodeStream: f, isReadableStream: c, isWritableStream: h } = Jr(), g = ln(), { AbortError: v, codes: { ERR_INVALID_ARG_TYPE: w, ERR_INVALID_RETURN_VALUE: E } } = ir(), { destroyer: x } = Wn(), S = Hr(), y = qa(), A = $f(), { createDeferredPromise: P } = dr(), N = vl(), k = globalThis.Blob || e.Blob, D = typeof k < "u" ? function(l) {
            return l instanceof k;
        } : function(l) {
            return !1;
        }, V = globalThis.AbortController || bi().AbortController, { FunctionPrototypeCall: K } = Ut();
        class j extends S {
            constructor(l){
                super(l), l?.readable === !1 && (this._readableState.readable = !1, this._readableState.ended = !0, this._readableState.endEmitted = !0), l?.writable === !1 && (this._writableState.writable = !1, this._writableState.ending = !0, this._writableState.ended = !0, this._writableState.finished = !0);
            }
        }
        fo = function d(l, b) {
            if (f(l)) return l;
            if (s(l)) return O({
                readable: l
            });
            if (o(l)) return O({
                writable: l
            });
            if (i(l)) return O({
                writable: !1,
                readable: !1
            });
            if (c(l)) return O({
                readable: y.fromWeb(l)
            });
            if (h(l)) return O({
                writable: A.fromWeb(l)
            });
            if (typeof l == "function") {
                const { value: _, write: B, final: T, destroy: R } = H(l);
                if (a(_)) return N(j, _, {
                    objectMode: !0,
                    write: B,
                    final: T,
                    destroy: R
                });
                const u = _?.then;
                if (typeof u == "function") {
                    let I;
                    const G = K(u, _, ($)=>{
                        if ($ != null) throw new E("nully", "body", $);
                    }, ($)=>{
                        x(I, $);
                    });
                    return I = new j({
                        objectMode: !0,
                        readable: !1,
                        write: B,
                        final ($) {
                            T(async ()=>{
                                try {
                                    await G, r.nextTick($, null);
                                } catch (te) {
                                    r.nextTick($, te);
                                }
                            });
                        },
                        destroy: R
                    });
                }
                throw new E("Iterable, AsyncIterable or AsyncFunction", b, _);
            }
            if (D(l)) return d(l.arrayBuffer());
            if (a(l)) return N(j, l, {
                objectMode: !0,
                writable: !1
            });
            if (c(l?.readable) && h(l?.writable)) return j.fromWeb(l);
            if (typeof l?.writable == "object" || typeof l?.readable == "object") {
                const _ = l != null && l.readable ? s(l?.readable) ? l?.readable : d(l.readable) : void 0, B = l != null && l.writable ? o(l?.writable) ? l?.writable : d(l.writable) : void 0;
                return O({
                    readable: _,
                    writable: B
                });
            }
            const m = l?.then;
            if (typeof m == "function") {
                let _;
                return K(m, l, (B)=>{
                    B != null && _.push(B), _.push(null);
                }, (B)=>{
                    x(_, B);
                }), _ = new j({
                    objectMode: !0,
                    writable: !1,
                    read () {}
                });
            }
            throw new w(b, [
                "Blob",
                "ReadableStream",
                "WritableStream",
                "Stream",
                "Iterable",
                "AsyncIterable",
                "Function",
                "{ readable, writable } pair",
                "Promise"
            ], l);
        };
        function H(d) {
            let { promise: l, resolve: b } = P();
            const m = new V, _ = m.signal;
            return {
                value: d((async function*() {
                    for(;;){
                        const T = l;
                        l = null;
                        const { chunk: R, done: u, cb: I } = await T;
                        if (r.nextTick(I), u) return;
                        if (_.aborted) throw new v(void 0, {
                            cause: _.reason
                        });
                        ({ promise: l, resolve: b } = P()), yield R;
                    }
                })(), {
                    signal: _
                }),
                write (T, R, u) {
                    const I = b;
                    b = null, I({
                        chunk: T,
                        done: !1,
                        cb: u
                    });
                },
                final (T) {
                    const R = b;
                    b = null, R({
                        done: !0,
                        cb: T
                    });
                },
                destroy (T, R) {
                    m.abort(), R(T);
                }
            };
        }
        function O(d) {
            const l = d.readable && typeof d.readable.read != "function" ? y.wrap(d.readable) : d.readable, b = d.writable;
            let m = !!t(l), _ = !!n(b), B, T, R, u, I;
            function G($) {
                const te = u;
                u = null, te ? te($) : $ && I.destroy($);
            }
            return I = new j({
                readableObjectMode: !!(l != null && l.readableObjectMode),
                writableObjectMode: !!(b != null && b.writableObjectMode),
                readable: m,
                writable: _
            }), _ && (g(b, ($)=>{
                _ = !1, $ && x(l, $), G($);
            }), I._write = function($, te, Z) {
                b.write($, te) ? Z() : B = Z;
            }, I._final = function($) {
                b.end(), T = $;
            }, b.on("drain", function() {
                if (B) {
                    const $ = B;
                    B = null, $();
                }
            }), b.on("finish", function() {
                if (T) {
                    const $ = T;
                    T = null, $();
                }
            })), m && (g(l, ($)=>{
                m = !1, $ && x(l, $), G($);
            }), l.on("readable", function() {
                if (R) {
                    const $ = R;
                    R = null, $();
                }
            }), l.on("end", function() {
                I.push(null);
            }), I._read = function() {
                for(;;){
                    const $ = l.read();
                    if ($ === null) {
                        R = I._read;
                        return;
                    }
                    if (!I.push($)) return;
                }
            }), I._destroy = function($, te) {
                !$ && u !== null && ($ = new v), R = null, B = null, T = null, u === null ? te($) : (u = te, x(b, $), x(l, $));
            }, I;
        }
        return fo;
    }
    var co, Qd;
    function Hr() {
        if (Qd) return co;
        Qd = 1;
        const { ObjectDefineProperties: r, ObjectGetOwnPropertyDescriptor: e, ObjectKeys: t, ObjectSetPrototypeOf: n } = Ut();
        co = s;
        const a = qa(), i = $f();
        n(s.prototype, a.prototype), n(s, a);
        {
            const h = t(i.prototype);
            for(let g = 0; g < h.length; g++){
                const v = h[g];
                s.prototype[v] || (s.prototype[v] = i.prototype[v]);
            }
        }
        function s(h) {
            if (!(this instanceof s)) return new s(h);
            a.call(this, h), i.call(this, h), h ? (this.allowHalfOpen = h.allowHalfOpen !== !1, h.readable === !1 && (this._readableState.readable = !1, this._readableState.ended = !0, this._readableState.endEmitted = !0), h.writable === !1 && (this._writableState.writable = !1, this._writableState.ending = !0, this._writableState.ended = !0, this._writableState.finished = !0)) : this.allowHalfOpen = !0;
        }
        r(s.prototype, {
            writable: {
                __proto__: null,
                ...e(i.prototype, "writable")
            },
            writableHighWaterMark: {
                __proto__: null,
                ...e(i.prototype, "writableHighWaterMark")
            },
            writableObjectMode: {
                __proto__: null,
                ...e(i.prototype, "writableObjectMode")
            },
            writableBuffer: {
                __proto__: null,
                ...e(i.prototype, "writableBuffer")
            },
            writableLength: {
                __proto__: null,
                ...e(i.prototype, "writableLength")
            },
            writableFinished: {
                __proto__: null,
                ...e(i.prototype, "writableFinished")
            },
            writableCorked: {
                __proto__: null,
                ...e(i.prototype, "writableCorked")
            },
            writableEnded: {
                __proto__: null,
                ...e(i.prototype, "writableEnded")
            },
            writableNeedDrain: {
                __proto__: null,
                ...e(i.prototype, "writableNeedDrain")
            },
            destroyed: {
                __proto__: null,
                get () {
                    return this._readableState === void 0 || this._writableState === void 0 ? !1 : this._readableState.destroyed && this._writableState.destroyed;
                },
                set (h) {
                    this._readableState && this._writableState && (this._readableState.destroyed = h, this._writableState.destroyed = h);
                }
            }
        });
        let o;
        function f() {
            return o === void 0 && (o = {}), o;
        }
        s.fromWeb = function(h, g) {
            return f().newStreamDuplexFromReadableWritablePair(h, g);
        }, s.toWeb = function(h) {
            return f().newReadableWritablePairFromDuplex(h);
        };
        let c;
        return s.from = function(h) {
            return c || (c = I3()), c(h, "body");
        }, co;
    }
    var uo, e0;
    function ml() {
        if (e0) return uo;
        e0 = 1;
        const { ObjectSetPrototypeOf: r, Symbol: e } = Ut();
        uo = s;
        const { ERR_METHOD_NOT_IMPLEMENTED: t } = ir().codes, n = Hr(), { getHighWaterMark: a } = Ua();
        r(s.prototype, n.prototype), r(s, n);
        const i = e("kCallback");
        function s(c) {
            if (!(this instanceof s)) return new s(c);
            const h = c ? a(this, c, "readableHighWaterMark", !0) : null;
            h === 0 && (c = {
                ...c,
                highWaterMark: null,
                readableHighWaterMark: h,
                writableHighWaterMark: c.writableHighWaterMark || 0
            }), n.call(this, c), this._readableState.sync = !1, this[i] = null, c && (typeof c.transform == "function" && (this._transform = c.transform), typeof c.flush == "function" && (this._flush = c.flush)), this.on("prefinish", f);
        }
        function o(c) {
            typeof this._flush == "function" && !this.destroyed ? this._flush((h, g)=>{
                if (h) {
                    c ? c(h) : this.destroy(h);
                    return;
                }
                g != null && this.push(g), this.push(null), c && c();
            }) : (this.push(null), c && c());
        }
        function f() {
            this._final !== o && o.call(this);
        }
        return s.prototype._final = o, s.prototype._transform = function(c, h, g) {
            throw new t("_transform()");
        }, s.prototype._write = function(c, h, g) {
            const v = this._readableState, w = this._writableState, E = v.length;
            this._transform(c, h, (x, S)=>{
                if (x) {
                    g(x);
                    return;
                }
                S != null && this.push(S), w.ended || E === v.length || v.length < v.highWaterMark ? g() : this[i] = g;
            });
        }, s.prototype._read = function() {
            if (this[i]) {
                const c = this[i];
                this[i] = null, c();
            }
        }, uo;
    }
    var lo, t0;
    function wl() {
        if (t0) return lo;
        t0 = 1;
        const { ObjectSetPrototypeOf: r } = Ut();
        lo = t;
        const e = ml();
        r(t.prototype, e.prototype), r(t, e);
        function t(n) {
            if (!(this instanceof t)) return new t(n);
            e.call(this, n);
        }
        return t.prototype._transform = function(n, a, i) {
            i(null, n);
        }, lo;
    }
    var ho, r0;
    function Kf() {
        if (r0) return ho;
        r0 = 1;
        const r = Pn(), { ArrayIsArray: e, Promise: t, SymbolAsyncIterator: n, SymbolDispose: a } = Ut(), i = ln(), { once: s } = dr(), o = Wn(), f = Hr(), { aggregateTwoErrors: c, codes: { ERR_INVALID_ARG_TYPE: h, ERR_INVALID_RETURN_VALUE: g, ERR_MISSING_ARGS: v, ERR_STREAM_DESTROYED: w, ERR_STREAM_PREMATURE_CLOSE: E }, AbortError: x } = ir(), { validateFunction: S, validateAbortSignal: y } = wi(), { isIterable: A, isReadable: P, isReadableNodeStream: N, isNodeStream: k, isTransformStream: D, isWebStream: V, isReadableStream: K, isReadableFinished: j } = Jr(), H = globalThis.AbortController || bi().AbortController;
        let O, d, l;
        function b($, te, Z) {
            let fe = !1;
            $.on("close", ()=>{
                fe = !0;
            });
            const pe = i($, {
                readable: te,
                writable: Z
            }, (ee)=>{
                fe = !ee;
            });
            return {
                destroy: (ee)=>{
                    fe || (fe = !0, o.destroyer($, ee || new w("pipe")));
                },
                cleanup: pe
            };
        }
        function m($) {
            return S($[$.length - 1], "streams[stream.length - 1]"), $.pop();
        }
        function _($) {
            if (A($)) return $;
            if (N($)) return B($);
            throw new h("val", [
                "Readable",
                "Iterable",
                "AsyncIterable"
            ], $);
        }
        async function* B($) {
            d || (d = qa()), yield* d.prototype[n].call($);
        }
        async function T($, te, Z, { end: fe }) {
            let pe, ee = null;
            const J = (xe)=>{
                if (xe && (pe = xe), ee) {
                    const z = ee;
                    ee = null, z();
                }
            }, oe = ()=>new t((xe, z)=>{
                    pe ? z(pe) : ee = ()=>{
                        pe ? z(pe) : xe();
                    };
                });
            te.on("drain", J);
            const Me = i(te, {
                readable: !1
            }, J);
            try {
                te.writableNeedDrain && await oe();
                for await (const xe of $)te.write(xe) || await oe();
                fe && (te.end(), await oe()), Z();
            } catch (xe) {
                Z(pe !== xe ? c(pe, xe) : xe);
            } finally{
                Me(), te.off("drain", J);
            }
        }
        async function R($, te, Z, { end: fe }) {
            D(te) && (te = te.writable);
            const pe = te.getWriter();
            try {
                for await (const ee of $)await pe.ready, pe.write(ee).catch(()=>{});
                await pe.ready, fe && await pe.close(), Z();
            } catch (ee) {
                try {
                    await pe.abort(ee), Z(ee);
                } catch (J) {
                    Z(J);
                }
            }
        }
        function u(...$) {
            return I($, s(m($)));
        }
        function I($, te, Z) {
            if ($.length === 1 && e($[0]) && ($ = $[0]), $.length < 2) throw new v("streams");
            const fe = new H, pe = fe.signal, ee = Z?.signal, J = [];
            y(ee, "options.signal");
            function oe() {
                Se(new x);
            }
            l = l || dr().addAbortListener;
            let Me;
            ee && (Me = l(ee, oe));
            let xe, z;
            const X = [];
            let re = 0;
            function ge(be) {
                Se(be, --re === 0);
            }
            function Se(be, se) {
                var De;
                if (be && (!xe || xe.code === "ERR_STREAM_PREMATURE_CLOSE") && (xe = be), !(!xe && !se)) {
                    for(; X.length;)X.shift()(xe);
                    (De = Me) === null || De === void 0 || De[a](), fe.abort(), se && (xe || J.forEach((ze)=>ze()), r.nextTick(te, xe, z));
                }
            }
            let ye;
            for(let be = 0; be < $.length; be++){
                const se = $[be], De = be < $.length - 1, ze = be > 0, $e = De || Z?.end !== !1, Ze = be === $.length - 1;
                if (k(se)) {
                    let je = function(Qe) {
                        Qe && Qe.name !== "AbortError" && Qe.code !== "ERR_STREAM_PREMATURE_CLOSE" && ge(Qe);
                    };
                    if ($e) {
                        const { destroy: Qe, cleanup: qt } = b(se, De, ze);
                        X.push(Qe), P(se) && Ze && J.push(qt);
                    }
                    se.on("error", je), P(se) && Ze && J.push(()=>{
                        se.removeListener("error", je);
                    });
                }
                if (be === 0) if (typeof se == "function") {
                    if (ye = se({
                        signal: pe
                    }), !A(ye)) throw new g("Iterable, AsyncIterable or Stream", "source", ye);
                } else A(se) || N(se) || D(se) ? ye = se : ye = f.from(se);
                else if (typeof se == "function") {
                    if (D(ye)) {
                        var Y;
                        ye = _((Y = ye) === null || Y === void 0 ? void 0 : Y.readable);
                    } else ye = _(ye);
                    if (ye = se(ye, {
                        signal: pe
                    }), De) {
                        if (!A(ye, !0)) throw new g("AsyncIterable", `transform[${be - 1}]`, ye);
                    } else {
                        var le;
                        O || (O = wl());
                        const je = new O({
                            objectMode: !0
                        }), Qe = (le = ye) === null || le === void 0 ? void 0 : le.then;
                        if (typeof Qe == "function") re++, Qe.call(ye, (et)=>{
                            z = et, et != null && je.write(et), $e && je.end(), r.nextTick(ge);
                        }, (et)=>{
                            je.destroy(et), r.nextTick(ge, et);
                        });
                        else if (A(ye, !0)) re++, T(ye, je, ge, {
                            end: $e
                        });
                        else if (K(ye) || D(ye)) {
                            const et = ye.readable || ye;
                            re++, T(et, je, ge, {
                                end: $e
                            });
                        } else throw new g("AsyncIterable or Promise", "destination", ye);
                        ye = je;
                        const { destroy: qt, cleanup: bt } = b(ye, !1, !0);
                        X.push(qt), Ze && J.push(bt);
                    }
                } else if (k(se)) {
                    if (N(ye)) {
                        re += 2;
                        const je = G(ye, se, ge, {
                            end: $e
                        });
                        P(se) && Ze && J.push(je);
                    } else if (D(ye) || K(ye)) {
                        const je = ye.readable || ye;
                        re++, T(je, se, ge, {
                            end: $e
                        });
                    } else if (A(ye)) re++, T(ye, se, ge, {
                        end: $e
                    });
                    else throw new h("val", [
                        "Readable",
                        "Iterable",
                        "AsyncIterable",
                        "ReadableStream",
                        "TransformStream"
                    ], ye);
                    ye = se;
                } else if (V(se)) {
                    if (N(ye)) re++, R(_(ye), se, ge, {
                        end: $e
                    });
                    else if (K(ye) || A(ye)) re++, R(ye, se, ge, {
                        end: $e
                    });
                    else if (D(ye)) re++, R(ye.readable, se, ge, {
                        end: $e
                    });
                    else throw new h("val", [
                        "Readable",
                        "Iterable",
                        "AsyncIterable",
                        "ReadableStream",
                        "TransformStream"
                    ], ye);
                    ye = se;
                } else ye = f.from(se);
            }
            return (pe != null && pe.aborted || ee != null && ee.aborted) && r.nextTick(oe), ye;
        }
        function G($, te, Z, { end: fe }) {
            let pe = !1;
            if (te.on("close", ()=>{
                pe || Z(new E);
            }), $.pipe(te, {
                end: !1
            }), fe) {
                let ee = function() {
                    pe = !0, te.end();
                };
                j($) ? r.nextTick(ee) : $.once("end", ee);
            } else Z();
            return i($, {
                readable: !0,
                writable: !1
            }, (ee)=>{
                const J = $._readableState;
                ee && ee.code === "ERR_STREAM_PREMATURE_CLOSE" && J && J.ended && !J.errored && !J.errorEmitted ? $.once("end", Z).once("error", Z) : Z(ee);
            }), i(te, {
                readable: !1,
                writable: !0
            }, Z);
        }
        return ho = {
            pipelineImpl: I,
            pipeline: u
        }, ho;
    }
    var bo, n0;
    function xl() {
        if (n0) return bo;
        n0 = 1;
        const { pipeline: r } = Kf(), e = Hr(), { destroyer: t } = Wn(), { isNodeStream: n, isReadable: a, isWritable: i, isWebStream: s, isTransformStream: o, isWritableStream: f, isReadableStream: c } = Jr(), { AbortError: h, codes: { ERR_INVALID_ARG_VALUE: g, ERR_MISSING_ARGS: v } } = ir(), w = ln();
        return bo = function(...x) {
            if (x.length === 0) throw new v("streams");
            if (x.length === 1) return e.from(x[0]);
            const S = [
                ...x
            ];
            if (typeof x[0] == "function" && (x[0] = e.from(x[0])), typeof x[x.length - 1] == "function") {
                const O = x.length - 1;
                x[O] = e.from(x[O]);
            }
            for(let O = 0; O < x.length; ++O)if (!(!n(x[O]) && !s(x[O]))) {
                if (O < x.length - 1 && !(a(x[O]) || c(x[O]) || o(x[O]))) throw new g(`streams[${O}]`, S[O], "must be readable");
                if (O > 0 && !(i(x[O]) || f(x[O]) || o(x[O]))) throw new g(`streams[${O}]`, S[O], "must be writable");
            }
            let y, A, P, N, k;
            function D(O) {
                const d = N;
                N = null, d ? d(O) : O ? k.destroy(O) : !H && !j && k.destroy();
            }
            const V = x[0], K = r(x, D), j = !!(i(V) || f(V) || o(V)), H = !!(a(K) || c(K) || o(K));
            if (k = new e({
                writableObjectMode: !!(V != null && V.writableObjectMode),
                readableObjectMode: !!(K != null && K.readableObjectMode),
                writable: j,
                readable: H
            }), j) {
                if (n(V)) k._write = function(d, l, b) {
                    V.write(d, l) ? b() : y = b;
                }, k._final = function(d) {
                    V.end(), A = d;
                }, V.on("drain", function() {
                    if (y) {
                        const d = y;
                        y = null, d();
                    }
                });
                else if (s(V)) {
                    const l = (o(V) ? V.writable : V).getWriter();
                    k._write = async function(b, m, _) {
                        try {
                            await l.ready, l.write(b).catch(()=>{}), _();
                        } catch (B) {
                            _(B);
                        }
                    }, k._final = async function(b) {
                        try {
                            await l.ready, l.close().catch(()=>{}), A = b;
                        } catch (m) {
                            b(m);
                        }
                    };
                }
                const O = o(K) ? K.readable : K;
                w(O, ()=>{
                    if (A) {
                        const d = A;
                        A = null, d();
                    }
                });
            }
            if (H) {
                if (n(K)) K.on("readable", function() {
                    if (P) {
                        const O = P;
                        P = null, O();
                    }
                }), K.on("end", function() {
                    k.push(null);
                }), k._read = function() {
                    for(;;){
                        const O = K.read();
                        if (O === null) {
                            P = k._read;
                            return;
                        }
                        if (!k.push(O)) return;
                    }
                };
                else if (s(K)) {
                    const d = (o(K) ? K.readable : K).getReader();
                    k._read = async function() {
                        for(;;)try {
                            const { value: l, done: b } = await d.read();
                            if (!k.push(l)) return;
                            if (b) {
                                k.push(null);
                                return;
                            }
                        } catch  {
                            return;
                        }
                    };
                }
            }
            return k._destroy = function(O, d) {
                !O && N !== null && (O = new h), P = null, y = null, A = null, N === null ? d(O) : (N = d, n(K) && t(K, O));
            }, k;
        }, bo;
    }
    var i0;
    function M3() {
        if (i0) return Di;
        i0 = 1;
        const r = globalThis.AbortController || bi().AbortController, { codes: { ERR_INVALID_ARG_VALUE: e, ERR_INVALID_ARG_TYPE: t, ERR_MISSING_ARGS: n, ERR_OUT_OF_RANGE: a }, AbortError: i } = ir(), { validateAbortSignal: s, validateInteger: o, validateObject: f } = wi(), c = Ut().Symbol("kWeak"), h = Ut().Symbol("kResistStopPropagation"), { finished: g } = ln(), v = xl(), { addAbortSignalNoValidate: w } = La(), { isWritable: E, isNodeStream: x } = Jr(), { deprecate: S } = dr(), { ArrayPrototypePush: y, Boolean: A, MathFloor: P, Number: N, NumberIsNaN: k, Promise: D, PromiseReject: V, PromiseResolve: K, PromisePrototypeThen: j, Symbol: H } = Ut(), O = H("kEmpty"), d = H("kEof");
        function l(ee, J) {
            if (J != null && f(J, "options"), J?.signal != null && s(J.signal, "options.signal"), x(ee) && !E(ee)) throw new e("stream", ee, "must be writable");
            const oe = v(this, ee);
            return J != null && J.signal && w(J.signal, oe), oe;
        }
        function b(ee, J) {
            if (typeof ee != "function") throw new t("fn", [
                "Function",
                "AsyncFunction"
            ], ee);
            J != null && f(J, "options"), J?.signal != null && s(J.signal, "options.signal");
            let oe = 1;
            J?.concurrency != null && (oe = P(J.concurrency));
            let Me = oe - 1;
            return J?.highWaterMark != null && (Me = P(J.highWaterMark)), o(oe, "options.concurrency", 1), o(Me, "options.highWaterMark", 0), Me += oe, async function*() {
                const z = dr().AbortSignalAny([
                    J?.signal
                ].filter(A)), X = this, re = [], ge = {
                    signal: z
                };
                let Se, ye, Y = !1, le = 0;
                function be() {
                    Y = !0, se();
                }
                function se() {
                    le -= 1, De();
                }
                function De() {
                    ye && !Y && le < oe && re.length < Me && (ye(), ye = null);
                }
                async function ze() {
                    try {
                        for await (let $e of X){
                            if (Y) return;
                            if (z.aborted) throw new i;
                            try {
                                if ($e = ee($e, ge), $e === O) continue;
                                $e = K($e);
                            } catch (Ze) {
                                $e = V(Ze);
                            }
                            le += 1, j($e, se, be), re.push($e), Se && (Se(), Se = null), !Y && (re.length >= Me || le >= oe) && await new D((Ze)=>{
                                ye = Ze;
                            });
                        }
                        re.push(d);
                    } catch ($e) {
                        const Ze = V($e);
                        j(Ze, se, be), re.push(Ze);
                    } finally{
                        Y = !0, Se && (Se(), Se = null);
                    }
                }
                ze();
                try {
                    for(;;){
                        for(; re.length > 0;){
                            const $e = await re[0];
                            if ($e === d) return;
                            if (z.aborted) throw new i;
                            $e !== O && (yield $e), re.shift(), De();
                        }
                        await new D(($e)=>{
                            Se = $e;
                        });
                    }
                } finally{
                    Y = !0, ye && (ye(), ye = null);
                }
            }.call(this);
        }
        function m(ee = void 0) {
            return ee != null && f(ee, "options"), ee?.signal != null && s(ee.signal, "options.signal"), async function*() {
                let oe = 0;
                for await (const xe of this){
                    var Me;
                    if (ee != null && (Me = ee.signal) !== null && Me !== void 0 && Me.aborted) throw new i({
                        cause: ee.signal.reason
                    });
                    yield [
                        oe++,
                        xe
                    ];
                }
            }.call(this);
        }
        async function _(ee, J = void 0) {
            for await (const oe of u.call(this, ee, J))return !0;
            return !1;
        }
        async function B(ee, J = void 0) {
            if (typeof ee != "function") throw new t("fn", [
                "Function",
                "AsyncFunction"
            ], ee);
            return !await _.call(this, async (...oe)=>!await ee(...oe), J);
        }
        async function T(ee, J) {
            for await (const oe of u.call(this, ee, J))return oe;
        }
        async function R(ee, J) {
            if (typeof ee != "function") throw new t("fn", [
                "Function",
                "AsyncFunction"
            ], ee);
            async function oe(Me, xe) {
                return await ee(Me, xe), O;
            }
            for await (const Me of b.call(this, oe, J));
        }
        function u(ee, J) {
            if (typeof ee != "function") throw new t("fn", [
                "Function",
                "AsyncFunction"
            ], ee);
            async function oe(Me, xe) {
                return await ee(Me, xe) ? Me : O;
            }
            return b.call(this, oe, J);
        }
        class I extends n {
            constructor(){
                super("reduce"), this.message = "Reduce of an empty stream requires an initial value";
            }
        }
        async function G(ee, J, oe) {
            var Me;
            if (typeof ee != "function") throw new t("reducer", [
                "Function",
                "AsyncFunction"
            ], ee);
            oe != null && f(oe, "options"), oe?.signal != null && s(oe.signal, "options.signal");
            let xe = arguments.length > 1;
            if (oe != null && (Me = oe.signal) !== null && Me !== void 0 && Me.aborted) {
                const Se = new i(void 0, {
                    cause: oe.signal.reason
                });
                throw this.once("error", ()=>{}), await g(this.destroy(Se)), Se;
            }
            const z = new r, X = z.signal;
            if (oe != null && oe.signal) {
                const Se = {
                    once: !0,
                    [c]: this,
                    [h]: !0
                };
                oe.signal.addEventListener("abort", ()=>z.abort(), Se);
            }
            let re = !1;
            try {
                for await (const Se of this){
                    var ge;
                    if (re = !0, oe != null && (ge = oe.signal) !== null && ge !== void 0 && ge.aborted) throw new i;
                    xe ? J = await ee(J, Se, {
                        signal: X
                    }) : (J = Se, xe = !0);
                }
                if (!re && !xe) throw new I;
            } finally{
                z.abort();
            }
            return J;
        }
        async function $(ee) {
            ee != null && f(ee, "options"), ee?.signal != null && s(ee.signal, "options.signal");
            const J = [];
            for await (const Me of this){
                var oe;
                if (ee != null && (oe = ee.signal) !== null && oe !== void 0 && oe.aborted) throw new i(void 0, {
                    cause: ee.signal.reason
                });
                y(J, Me);
            }
            return J;
        }
        function te(ee, J) {
            const oe = b.call(this, ee, J);
            return async function*() {
                for await (const xe of oe)yield* xe;
            }.call(this);
        }
        function Z(ee) {
            if (ee = N(ee), k(ee)) return 0;
            if (ee < 0) throw new a("number", ">= 0", ee);
            return ee;
        }
        function fe(ee, J = void 0) {
            return J != null && f(J, "options"), J?.signal != null && s(J.signal, "options.signal"), ee = Z(ee), async function*() {
                var Me;
                if (J != null && (Me = J.signal) !== null && Me !== void 0 && Me.aborted) throw new i;
                for await (const z of this){
                    var xe;
                    if (J != null && (xe = J.signal) !== null && xe !== void 0 && xe.aborted) throw new i;
                    ee-- <= 0 && (yield z);
                }
            }.call(this);
        }
        function pe(ee, J = void 0) {
            return J != null && f(J, "options"), J?.signal != null && s(J.signal, "options.signal"), ee = Z(ee), async function*() {
                var Me;
                if (J != null && (Me = J.signal) !== null && Me !== void 0 && Me.aborted) throw new i;
                for await (const z of this){
                    var xe;
                    if (J != null && (xe = J.signal) !== null && xe !== void 0 && xe.aborted) throw new i;
                    if (ee-- > 0 && (yield z), ee <= 0) return;
                }
            }.call(this);
        }
        return Di.streamReturningOperators = {
            asIndexedPairs: S(m, "readable.asIndexedPairs will be removed in a future version."),
            drop: fe,
            filter: u,
            flatMap: te,
            map: b,
            take: pe,
            compose: l
        }, Di.promiseReturningOperators = {
            every: B,
            forEach: R,
            reduce: G,
            toArray: $,
            some: _,
            find: T
        }, Di;
    }
    var po, a0;
    function _l() {
        if (a0) return po;
        a0 = 1;
        const { ArrayPrototypePop: r, Promise: e } = Ut(), { isIterable: t, isNodeStream: n, isWebStream: a } = Jr(), { pipelineImpl: i } = Kf(), { finished: s } = ln();
        Sl();
        function o(...f) {
            return new e((c, h)=>{
                let g, v;
                const w = f[f.length - 1];
                if (w && typeof w == "object" && !n(w) && !t(w) && !a(w)) {
                    const E = r(f);
                    g = E.signal, v = E.end;
                }
                i(f, (E, x)=>{
                    E ? h(E) : c(x);
                }, {
                    signal: g,
                    end: v
                });
            });
        }
        return po = {
            finished: s,
            pipeline: o
        }, po;
    }
    var s0;
    function Sl() {
        if (s0) return zs.exports;
        s0 = 1;
        const { Buffer: r } = Wr(), { ObjectDefineProperty: e, ObjectKeys: t, ReflectApply: n } = Ut(), { promisify: { custom: a } } = dr(), { streamReturningOperators: i, promiseReturningOperators: s } = M3(), { codes: { ERR_ILLEGAL_CONSTRUCTOR: o } } = ir(), f = xl(), { setDefaultHighWaterMark: c, getDefaultHighWaterMark: h } = Ua(), { pipeline: g } = Kf(), { destroyer: v } = Wn(), w = ln(), E = _l(), x = Jr(), S = zs.exports = Ff().Stream;
        S.isDestroyed = x.isDestroyed, S.isDisturbed = x.isDisturbed, S.isErrored = x.isErrored, S.isReadable = x.isReadable, S.isWritable = x.isWritable, S.Readable = qa();
        for (const A of t(i)){
            let N = function(...k) {
                if (new.target) throw o();
                return S.Readable.from(n(P, this, k));
            };
            const P = i[A];
            e(N, "name", {
                __proto__: null,
                value: P.name
            }), e(N, "length", {
                __proto__: null,
                value: P.length
            }), e(S.Readable.prototype, A, {
                __proto__: null,
                value: N,
                enumerable: !1,
                configurable: !0,
                writable: !0
            });
        }
        for (const A of t(s)){
            let N = function(...k) {
                if (new.target) throw o();
                return n(P, this, k);
            };
            const P = s[A];
            e(N, "name", {
                __proto__: null,
                value: P.name
            }), e(N, "length", {
                __proto__: null,
                value: P.length
            }), e(S.Readable.prototype, A, {
                __proto__: null,
                value: N,
                enumerable: !1,
                configurable: !0,
                writable: !0
            });
        }
        S.Writable = $f(), S.Duplex = Hr(), S.Transform = ml(), S.PassThrough = wl(), S.pipeline = g;
        const { addAbortSignal: y } = La();
        return S.addAbortSignal = y, S.finished = w, S.destroy = v, S.compose = f, S.setDefaultHighWaterMark = c, S.getDefaultHighWaterMark = h, e(S, "promises", {
            __proto__: null,
            configurable: !0,
            enumerable: !0,
            get () {
                return E;
            }
        }), e(g, a, {
            __proto__: null,
            enumerable: !0,
            get () {
                return E.pipeline;
            }
        }), e(w, a, {
            __proto__: null,
            enumerable: !0,
            get () {
                return E.finished;
            }
        }), S.Stream = S, S._isUint8Array = function(P) {
            return P instanceof Uint8Array;
        }, S._uint8ArrayToBuffer = function(P) {
            return r.from(P.buffer, P.byteOffset, P.byteLength);
        }, zs.exports;
    }
    var o0;
    function R3() {
        return o0 || (o0 = 1, (function(r) {
            const e = Sl(), t = _l(), n = e.Readable.destroy;
            r.exports = e.Readable, r.exports._uint8ArrayToBuffer = e._uint8ArrayToBuffer, r.exports._isUint8Array = e._isUint8Array, r.exports.isDisturbed = e.isDisturbed, r.exports.isErrored = e.isErrored, r.exports.isReadable = e.isReadable, r.exports.Readable = e.Readable, r.exports.Writable = e.Writable, r.exports.Duplex = e.Duplex, r.exports.Transform = e.Transform, r.exports.PassThrough = e.PassThrough, r.exports.addAbortSignal = e.addAbortSignal, r.exports.finished = e.finished, r.exports.destroy = e.destroy, r.exports.destroy = n, r.exports.pipeline = e.pipeline, r.exports.compose = e.compose, Object.defineProperty(e, "promises", {
                configurable: !0,
                enumerable: !0,
                get () {
                    return t;
                }
            }), r.exports.Stream = e.Stream, r.exports.default = r.exports;
        })(Hs)), Hs.exports;
    }
    var xi = R3();
    function Ki() {}
    const f0 = "SYN", go = "ACK", c0 = "BRK";
    class El extends xi.Duplex {
        constructor({ name: e, target: t, targetWindow: n = window, targetOrigin: a = "*" }){
            if (super({
                objectMode: !0
            }), he(this, "_init", void 0), he(this, "_haveSyn", void 0), he(this, "_name", void 0), he(this, "_target", void 0), he(this, "_targetWindow", void 0), he(this, "_targetOrigin", void 0), he(this, "_onMessage", void 0), he(this, "_synIntervalId", void 0), !e || !t) throw new Error("Invalid input.");
            this._init = !1, this._haveSyn = !1, this._name = e, this._target = t, this._targetWindow = n, this._targetOrigin = a, this._onMessage = this.onMessage.bind(this), this._synIntervalId = null, window.addEventListener("message", this._onMessage, !1), this._handShake();
        }
        _break() {
            this.cork(), this._write(c0, null, Ki), this._haveSyn = !1, this._init = !1;
        }
        _handShake() {
            this._write(f0, null, Ki), this.cork();
        }
        _onData(e) {
            if (!this._init) e === f0 ? (this._haveSyn = !0, this._write(go, null, Ki)) : e === go && (this._init = !0, this._haveSyn || this._write(go, null, Ki), this.uncork());
            else if (e === c0) this._break();
            else try {
                this.push(e);
            } catch (t) {
                this.emit("error", t);
            }
        }
        _postMessage(e) {
            const t = this._targetOrigin;
            this._targetWindow.postMessage({
                target: this._target,
                data: e
            }, t);
        }
        onMessage(e) {
            const t = e.data;
            this._targetOrigin !== "*" && e.origin !== this._targetOrigin || e.source !== this._targetWindow || typeof t != "object" || t.target !== this._name || !t.data || this._onData(t.data);
        }
        _read() {}
        _write(e, t, n) {
            this._postMessage(e), n();
        }
        _destroy() {
            window.removeEventListener("message", this._onMessage, !1);
        }
    }
    class T3 extends El {
        _postMessage(e) {
            let t = this._targetOrigin;
            if (typeof e == "object") {
                const n = e;
                if (typeof n.data == "object") {
                    const a = n.data;
                    if (Array.isArray(a.params) && a.params.length > 0) {
                        const i = a.params[0];
                        i._origin && (t = i._origin), i._origin = window.location.origin;
                    }
                }
            }
            this._targetWindow.postMessage({
                target: this._target,
                data: e
            }, t);
        }
    }
    function d0(r, e, t) {
        try {
            Reflect.apply(r, e, t);
        } catch (n) {
            setTimeout(()=>{
                throw n;
            });
        }
    }
    function P3(r) {
        const e = r.length, t = new Array(e);
        for(let n = 0; n < e; n += 1)t[n] = r[n];
        return t;
    }
    class Da extends _f.EventEmitter {
        emit(e, ...t) {
            let n = e === "error";
            const a = this._events;
            if (a !== void 0) n = n && a.error === void 0;
            else if (!n) return !1;
            if (n) {
                let s;
                if (t.length > 0 && ([s] = t), s instanceof Error) throw s;
                const o = new Error(`Unhandled error.${s ? ` (${s.message})` : ""}`);
                throw o.context = s, o;
            }
            const i = a[e];
            if (i === void 0) return !1;
            if (typeof i == "function") d0(i, this, t);
            else {
                const s = i.length, o = P3(i);
                for(let f = 0; f < s; f += 1)d0(o[f], this, t);
            }
            return !0;
        }
    }
    class sn extends Error {
        constructor({ code: e, message: t, data: n }){
            if (!Number.isInteger(e)) throw new Error("code must be an integer");
            if (!t || typeof t != "string") throw new Error("message must be string");
            super(t), he(this, "code", void 0), he(this, "data", void 0), this.code = e, n !== void 0 && (this.data = n);
        }
        toString() {
            return Rn({
                code: this.code,
                message: this.message,
                data: this.data,
                stack: this.stack
            });
        }
    }
    class Al extends xi.Duplex {
        constructor({ parent: e, name: t }){
            super({
                objectMode: !0
            }), he(this, "_parent", void 0), he(this, "_name", void 0), this._parent = e, this._name = t;
        }
        _read() {}
        _write(e, t, n) {
            this._parent.push({
                name: this._name,
                data: e
            }), n();
        }
    }
    const zt = {
        rpc: {
            invalidInput: -32e3,
            resourceNotFound: -32001,
            resourceUnavailable: -32002,
            transactionRejected: -32003,
            methodNotSupported: -32004,
            limitExceeded: -32005,
            parse: -32700,
            invalidRequest: -32600,
            methodNotFound: -32601,
            invalidParams: -32602,
            internal: -32603
        },
        provider: {
            userRejectedRequest: 4001,
            unauthorized: 4100,
            unsupportedMethod: 4200,
            disconnected: 4900,
            chainDisconnected: 4901
        }
    }, Xo = {
        "-32700": {
            standard: "JSON RPC 2.0",
            message: "Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."
        },
        "-32600": {
            standard: "JSON RPC 2.0",
            message: "The JSON sent is not a valid Request object."
        },
        "-32601": {
            standard: "JSON RPC 2.0",
            message: "The method does not exist / is not available."
        },
        "-32602": {
            standard: "JSON RPC 2.0",
            message: "Invalid method parameter(s)."
        },
        "-32603": {
            standard: "JSON RPC 2.0",
            message: "Internal JSON-RPC error."
        },
        "-32000": {
            standard: "EIP-1474",
            message: "Invalid input."
        },
        "-32001": {
            standard: "EIP-1474",
            message: "Resource not found."
        },
        "-32002": {
            standard: "EIP-1474",
            message: "Resource unavailable."
        },
        "-32003": {
            standard: "EIP-1474",
            message: "Transaction rejected."
        },
        "-32004": {
            standard: "EIP-1474",
            message: "Method not supported."
        },
        "-32005": {
            standard: "EIP-1474",
            message: "Request limit exceeded."
        },
        4001: {
            standard: "EIP-1193",
            message: "User rejected the request."
        },
        4100: {
            standard: "EIP-1193",
            message: "The requested account and/or method has not been authorized by the user."
        },
        4200: {
            standard: "EIP-1193",
            message: "The requested method is not supported by this Ethereum provider."
        },
        4900: {
            standard: "EIP-1193",
            message: "The provider is disconnected from all chains."
        },
        4901: {
            standard: "EIP-1193",
            message: "The provider is disconnected from the specified chain."
        }
    };
    var Il = function(r, e) {
        if (typeof r > "u" || r === null) throw new TypeError("Cannot convert undefined or null to object");
        return Object.prototype.hasOwnProperty.call(Object(r), e);
    };
    const u0 = zt.rpc.internal, B3 = "Unspecified error message. This is a bug, please report it.", Ml = "Unspecified server error.";
    function jf(r) {
        return Number.isInteger(r);
    }
    function Zo(r) {
        return typeof r == "string" && r.length > 0;
    }
    function pi(r) {
        return !!r && typeof r == "object" && !Array.isArray(r);
    }
    function Rl(r) {
        if (typeof r != "object" || r === null) return !1;
        try {
            let e = r;
            for(; Object.getPrototypeOf(e) !== null;)e = Object.getPrototypeOf(e);
            return Object.getPrototypeOf(r) === e;
        } catch  {
            return !1;
        }
    }
    function O3(r) {
        return r >= -32099 && r <= -32e3;
    }
    function Tl(r) {
        const e = r;
        return !(!e || !jf(e.code) || !Zo(e.message) || e.stack && !Zo(e.stack));
    }
    function Yn(r, e = B3) {
        if (jf(r)) {
            const t = r.toString();
            if (Il(Xo, t)) return Xo[t].message;
            if (O3(r)) return Ml;
        }
        return e;
    }
    const k3 = {
        code: u0,
        message: Yn(u0)
    };
    function Qo(r) {
        try {
            JSON.parse(JSON.stringify(r, (e, t)=>{
                if (e === "__proto__" || e === "constructor") throw new Error("Not valid json");
                if (typeof t == "function" || typeof t == "symbol") throw new Error("Not valid json");
                return t;
            }), (e, t)=>{
                if (!(e === "__proto__" || e === "constructor")) return t;
            });
        } catch  {
            return !1;
        }
        return !0;
    }
    function l0(r) {
        return Object.getOwnPropertyNames(r).reduce((e, t)=>{
            const n = r[t];
            return Qo(n) && (e[t] = n), e;
        }, {});
    }
    function Hf(r) {
        return Array.isArray(r) ? r.map((e)=>Qo(e) ? e : pi(e) ? l0(e) : null) : pi(r) ? l0(r) : Qo(r) ? r : null;
    }
    function N3(r, e) {
        if (r && typeof r == "object" && "serialize" in r && typeof r.serialize == "function") return r.serialize();
        if (Tl(r)) return r;
        const t = Hf(r);
        return Be(Be({}, e), {}, {
            data: {
                cause: t
            }
        });
    }
    function ha(r, { fallbackError: e = k3, shouldIncludeStack: t = !0 } = {}) {
        if (!Tl(e)) throw new Error("Must provide fallback error with integer number code and string message.");
        const n = N3(r, e);
        return t || delete n.stack, n;
    }
    function Pl(r) {
        return pi(r) && Il(r, "cause") && pi(r.cause);
    }
    var C3 = function(r, e) {
        if (typeof r > "u" || r === null) throw new TypeError("Cannot convert undefined or null to object");
        return Object.prototype.hasOwnProperty.call(Object(r), e);
    };
    function L3(r) {
        return Number.isInteger(r) && r >= 1e3 && r <= 4999;
    }
    function U3(r, e) {
        if (e !== "[Circular]") return e;
    }
    class Fa extends Error {
        constructor(e, t, n){
            if (!Number.isInteger(e)) throw new Error('"code" must be an integer.');
            if (!t || typeof t != "string") throw new Error('"message" must be a non-empty string.');
            Pl(n) ? (super(t, {
                cause: n.cause
            }), he(this, "cause", void 0), he(this, "code", void 0), he(this, "data", void 0), C3(this, "cause") || Object.assign(this, {
                cause: n.cause
            })) : (super(t), he(this, "cause", void 0), he(this, "code", void 0), he(this, "data", void 0)), n !== void 0 && (this.data = n), this.code = e, this.cause = n?.cause;
        }
        serialize() {
            const e = {
                code: this.code,
                message: this.message
            };
            return this.data !== void 0 && (e.data = this.data, Rl(this.data) && (e.data.cause = Hf(this.data.cause))), this.stack && (e.stack = this.stack), e;
        }
        toString() {
            return Rn(this.serialize(), {
                replacer: U3,
                space: 2
            });
        }
    }
    class zf extends Fa {
        constructor(e, t, n){
            if (!L3(e)) throw new Error('"code" must be an integer such that: 1000 <= code <= 4999');
            super(e, t, n);
        }
    }
    function Bl(r) {
        if (r) {
            if (typeof r == "string") return [
                r
            ];
            if (typeof r == "object" && !Array.isArray(r)) {
                const { message: e, data: t } = r;
                if (e && typeof e != "string") throw new Error("Must specify string message.");
                return [
                    e ?? void 0,
                    t
                ];
            }
        }
        return [];
    }
    function br(r, e) {
        const [t, n] = Bl(e);
        return new Fa(r, t ?? Yn(r), n);
    }
    function Jn(r, e) {
        const [t, n] = Bl(e);
        return new zf(r, t ?? Yn(r), n);
    }
    const q3 = {
        parse: (r)=>br(zt.rpc.parse, r),
        invalidRequest: (r)=>br(zt.rpc.invalidRequest, r),
        invalidParams: (r)=>br(zt.rpc.invalidParams, r),
        methodNotFound: (r)=>br(zt.rpc.methodNotFound, r),
        internal: (r)=>br(zt.rpc.internal, r),
        server: (r)=>{
            if (!r || typeof r != "object" || Array.isArray(r)) throw new Error("Ethereum RPC Server errors must provide single object argument.");
            const { code: e } = r;
            if (!Number.isInteger(e) || e > -32005 || e < -32099) throw new Error('"code" must be an integer such that: -32099 <= code <= -32005');
            return br(e, r);
        },
        invalidInput: (r)=>br(zt.rpc.invalidInput, r),
        resourceNotFound: (r)=>br(zt.rpc.resourceNotFound, r),
        resourceUnavailable: (r)=>br(zt.rpc.resourceUnavailable, r),
        transactionRejected: (r)=>br(zt.rpc.transactionRejected, r),
        methodNotSupported: (r)=>br(zt.rpc.methodNotSupported, r),
        limitExceeded: (r)=>br(zt.rpc.limitExceeded, r)
    }, D3 = {
        userRejectedRequest: (r)=>Jn(zt.provider.userRejectedRequest, r),
        unauthorized: (r)=>Jn(zt.provider.unauthorized, r),
        unsupportedMethod: (r)=>Jn(zt.provider.unsupportedMethod, r),
        disconnected: (r)=>Jn(zt.provider.disconnected, r),
        chainDisconnected: (r)=>Jn(zt.provider.chainDisconnected, r),
        custom: (r)=>{
            if (!r || typeof r != "object" || Array.isArray(r)) throw new Error("Ethereum Provider custom errors must provide single object argument.");
            const { code: e, message: t, data: n } = r;
            if (!t || typeof t != "string") throw new Error('"message" must be a nonempty string');
            return new zf(e, t, n);
        }
    }, F3 = (r, e, t = !0)=>(n, a)=>{
            n || a.error ? e(n || a.error) : !t || Array.isArray(a) ? r(a) : r(a.result);
        };
    function $3(r) {
        return (e, t, n, a)=>{
            try {
                if (typeof e.method != "string" || !e.method) {
                    t.error = new sn({
                        code: -32603,
                        message: "invalid method"
                    }), a();
                    return;
                }
                n((i)=>{
                    const { error: s } = t;
                    return s && r.error(`Auth - RPC Error: ${s.message}`, s), i();
                });
            } catch (i) {
                r.error(`Auth - RPC Error thrown: ${i.message}`, i), t.error = new sn({
                    code: -32603,
                    message: i.message
                }), a();
            }
        };
    }
    function K3() {
        const r = {};
        function e() {
            return !1;
        }
        const t = new Da;
        function n(f) {
            const c = r[f.id];
            if (!c) throw new Error(`StreamMiddleware - Unknown response id "${f.id}"`);
            delete r[f.id], Object.assign(c.res, f), setTimeout(c.end);
        }
        function a(f) {
            t.emit("notification", f);
        }
        function i(f, c, h) {
            let g;
            try {
                !f.id ? a(f) : n(f);
            } catch (v) {
                g = v;
            }
            h(g);
        }
        const s = new xi.Duplex({
            objectMode: !0,
            read: e,
            write: i
        });
        return {
            events: t,
            middleware: (f, c, h, g)=>{
                s.push(f), r[f.id] = {
                    req: f,
                    res: c,
                    next: h,
                    end: g
                };
            },
            stream: s
        };
    }
    function j3(r) {
        return (e, t, n, a)=>{
            const i = r[e.method];
            return i === void 0 ? n() : typeof i == "function" ? i(e, t, n, a) : (t.result = i, a());
        };
    }
    function H3() {
        return (r, e, t, n)=>{
            const a = r.id, i = Math.random().toString(36).slice(2);
            r.id = i, e.id = i, t((s)=>{
                r.id = a, e.id = a, s();
            });
        };
    }
    function z3(r) {
        return (e, t, n, a)=>{
            r.debug("REQ", e, "RES", t), n();
        };
    }
    function W3(r) {
        return async (e, t, n, a)=>{
            let i;
            const s = new Promise((h)=>{
                i = h;
            });
            let o = null, f = !1;
            const c = async ()=>{
                f = !0, n((h)=>{
                    o = h, i();
                }), await s;
            };
            try {
                await r(e, t, c), f ? (await s, o(null)) : a(null);
            } catch (h) {
                const g = h;
                o ? o(g) : a(g);
            }
        };
    }
    function ef(r) {
        const { message: e = "", code: t = -32603, stack: n = "Stack trace is not available.", data: a = "" } = r, i = parseInt(t?.toString() || "-32603");
        return {
            message: e || r?.toString() || Yn(i),
            code: i,
            stack: n,
            data: a || e || r?.toString()
        };
    }
    class _r extends Da {
        constructor(){
            super(), he(this, "_middleware", void 0), this._middleware = [];
        }
        static async _runAllMiddleware(e, t, n) {
            const a = [];
            let i = null, s = !1;
            for (const o of n)if ([i, s] = await _r._runMiddleware(e, t, o, a), s) break;
            return [
                i,
                s,
                a.reverse()
            ];
        }
        static _runMiddleware(e, t, n, a) {
            return new Promise((i)=>{
                const s = (f)=>{
                    const c = f || t.error;
                    c && (typeof c == "object" && Object.keys(c).includes("stack") === !1 && (c.stack = "Stack trace is not available."), Nr.error(c), t.error = ha(c, {
                        shouldIncludeStack: !0,
                        fallbackError: ef(c)
                    })), i([
                        c,
                        !0
                    ]);
                }, o = (f)=>{
                    t.error ? s(t.error) : (f && (typeof f != "function" && s(new sn({
                        code: -32603,
                        message: "JRPCEngine: 'next' return handlers must be functions"
                    })), a.push(f)), i([
                        null,
                        !1
                    ]));
                };
                try {
                    n(e, t, o, s);
                } catch (f) {
                    s(f);
                }
            });
        }
        static async _runReturnHandlers(e) {
            for (const t of e)await new Promise((n, a)=>{
                t((i)=>i ? a(i) : n());
            });
        }
        static _checkForCompletion(e, t, n) {
            if (!("result" in t) && !("error" in t)) throw new sn({
                code: -32603,
                message: "Response has no error or result for request"
            });
            if (!n) throw new sn({
                code: -32603,
                message: "Nothing ended request"
            });
        }
        push(e) {
            this._middleware.push(e);
        }
        handle(e, t) {
            if (t && typeof t != "function") throw new Error('"callback" must be a function if provided.');
            return Array.isArray(e) ? t ? this._handleBatch(e, t) : this._handleBatch(e) : t ? this._handle(e, t) : this._promiseHandle(e);
        }
        asMiddleware() {
            return async (e, t, n, a)=>{
                try {
                    const [i, s, o] = await _r._runAllMiddleware(e, t, this._middleware);
                    return s ? (await _r._runReturnHandlers(o), a(i)) : n(async (f)=>{
                        try {
                            await _r._runReturnHandlers(o);
                        } catch (c) {
                            return f(c);
                        }
                        return f();
                    });
                } catch (i) {
                    return a(i);
                }
            };
        }
        async _handleBatch(e, t) {
            try {
                const n = await Promise.all(e.map(this._promiseHandle.bind(this)));
                return t ? t(null, n) : n;
            } catch (n) {
                if (t) return t(n);
                throw n;
            }
        }
        _promiseHandle(e) {
            return new Promise((t, n)=>{
                this._handle(e, (a, i)=>{
                    a && i === void 0 ? n(a) : t(i);
                }).catch(n);
            });
        }
        async _handle(e, t) {
            if (!e || Array.isArray(e) || typeof e != "object") {
                const s = new sn({
                    code: -32603,
                    message: "request must be plain object"
                });
                return t(s, {
                    id: void 0,
                    jsonrpc: "2.0",
                    error: s
                });
            }
            if (typeof e.method != "string") {
                const s = new sn({
                    code: -32603,
                    message: "method must be string"
                });
                return t(s, {
                    id: e.id,
                    jsonrpc: "2.0",
                    error: s
                });
            }
            const n = Be({}, e), a = {
                id: n.id,
                jsonrpc: n.jsonrpc
            };
            let i = null;
            try {
                await this._processRequest(n, a);
            } catch (s) {
                i = s;
            }
            return i && (delete a.result, a.error || (typeof i == "object" && Object.keys(i).includes("stack") === !1 && (i.stack = "Stack trace is not available."), Nr.error(i), a.error = ha(i, {
                shouldIncludeStack: !0,
                fallbackError: ef(i)
            }))), t(i, a);
        }
        async _processRequest(e, t) {
            const [n, a, i] = await _r._runAllMiddleware(e, t, this._middleware);
            if (_r._checkForCompletion(e, t, a), await _r._runReturnHandlers(i), n) throw n;
        }
    }
    function Y3(r) {
        const e = new _r;
        return r.forEach((t)=>{
            e.push(t);
        }), e.asMiddleware();
    }
    function V3(r) {
        if (!r || !r.engine) throw new Error("Missing engine parameter!");
        const { engine: e } = r;
        let t;
        function n() {}
        function a(i, s, o) {
            e.handle(i, (f, c)=>{
                t.push(c);
            }), o();
        }
        return t = new xi.Duplex({
            objectMode: !0,
            read: n,
            write: a
        }), e.on && e.on("notification", (i)=>{
            t.push(i);
        }), t;
    }
    function Ol(r) {
        const e = new Da;
        return e.sendAsync = async (t)=>{
            const n = await r.handle(t);
            if (n.error) {
                var a, i;
                typeof n.error == "object" && Object.keys(n.error).includes("stack") === !1 && (n.error.stack = "Stack trace is not available."), Nr.error(n.error);
                const s = ha(n.error, {
                    fallbackError: ef(n.error),
                    shouldIncludeStack: !0
                }), o = (a = s?.code) !== null && a !== void 0 ? a : zt.rpc.internal;
                throw new Fa(o, (i = s?.message) !== null && i !== void 0 ? i : Yn(o), s?.data);
            }
            return n.result;
        }, e.send = (t, n)=>{
            if (typeof n != "function") throw new Error('Must provide callback to "send" method.');
            r.handle(t, n);
        }, r.on && r.on("notification", (t)=>{
            e.emit("data", null, t);
        }), e.request = async (t)=>{
            const n = Be(Be({}, t), {}, {
                id: Math.random().toString(36).slice(2),
                jsonrpc: "2.0"
            });
            return await e.sendAsync(n);
        }, e;
    }
    function G3(r) {
        const e = new _r;
        return e.push(r), Ol(e);
    }
    function J3(r) {
        return async (e, t, n, a)=>{
            try {
                const i = await r.sendAsync(e);
                return t.result = i, a();
            } catch (i) {
                return a(i);
            }
        };
    }
    var ji = {
        exports: {}
    }, yo, h0;
    function X3() {
        if (h0) return yo;
        h0 = 1, yo = r;
        function r(e, t) {
            if (e && t) return r(e)(t);
            if (typeof e != "function") throw new TypeError("need wrapper function");
            return Object.keys(e).forEach(function(a) {
                n[a] = e[a];
            }), n;
            function n() {
                for(var a = new Array(arguments.length), i = 0; i < a.length; i++)a[i] = arguments[i];
                var s = e.apply(this, a), o = a[a.length - 1];
                return typeof s == "function" && s !== o && Object.keys(o).forEach(function(f) {
                    s[f] = o[f];
                }), s;
            }
        }
        return yo;
    }
    var b0;
    function Wf() {
        if (b0) return ji.exports;
        b0 = 1;
        var r = X3();
        ji.exports = r(e), ji.exports.strict = r(t), e.proto = e(function() {
            Object.defineProperty(Function.prototype, "once", {
                value: function() {
                    return e(this);
                },
                configurable: !0
            }), Object.defineProperty(Function.prototype, "onceStrict", {
                value: function() {
                    return t(this);
                },
                configurable: !0
            });
        });
        function e(n) {
            var a = function() {
                return a.called ? a.value : (a.called = !0, a.value = n.apply(this, arguments));
            };
            return a.called = !1, a;
        }
        function t(n) {
            var a = function() {
                if (a.called) throw new Error(a.onceError);
                return a.called = !0, a.value = n.apply(this, arguments);
            }, i = n.name || "Function wrapped with `once`";
            return a.onceError = i + " shouldn't be called more than once", a.called = !1, a;
        }
        return ji.exports;
    }
    var vo, p0;
    function kl() {
        if (p0) return vo;
        p0 = 1;
        var r = Wf(), e = function() {}, t = globalThis.Bare ? queueMicrotask : typeof process < "u" && process && typeof process.nextTick == "function" ? process.nextTick.bind(process) : typeof queueMicrotask == "function" ? queueMicrotask : function(s) {
            Promise.resolve().then(s);
        }, n = function(s) {
            return s.setHeader && typeof s.abort == "function";
        }, a = function(s) {
            return s.stdio && Array.isArray(s.stdio) && s.stdio.length === 3;
        }, i = function(s, o, f) {
            if (typeof o == "function") return i(s, null, o);
            o || (o = {}), f = r(f || e);
            var c = s._writableState, h = s._readableState, g = o.readable || o.readable !== !1 && s.readable, v = o.writable || o.writable !== !1 && s.writable, w = !1, E = function() {
                s.writable || x();
            }, x = function() {
                v = !1, g || f.call(s);
            }, S = function() {
                g = !1, v || f.call(s);
            }, y = function(D) {
                f.call(s, D ? new Error("exited with error code: " + D) : null);
            }, A = function(D) {
                f.call(s, D);
            }, P = function() {
                t(N);
            }, N = function() {
                if (!w) {
                    if (g && !(h && h.ended && !h.destroyed)) return f.call(s, new Error("premature close"));
                    if (v && !(c && c.ended && !c.destroyed)) return f.call(s, new Error("premature close"));
                }
            }, k = function() {
                s.req.on("finish", x);
            };
            return n(s) ? (s.on("complete", x), s.on("abort", P), s.req ? k() : s.on("request", k)) : v && !c && (s.on("end", E), s.on("close", E)), a(s) && s.on("exit", y), s.on("end", S), s.on("finish", x), o.error !== !1 && s.on("error", A), s.on("close", P), function() {
                w = !0, s.removeListener("complete", x), s.removeListener("abort", P), s.removeListener("request", k), s.req && s.req.removeListener("finish", x), s.removeListener("end", E), s.removeListener("close", E), s.removeListener("finish", x), s.removeListener("exit", y), s.removeListener("end", S), s.removeListener("error", A), s.removeListener("close", P);
            };
        };
        return vo = i, vo;
    }
    var Z3 = kl();
    const g0 = Lr(Z3);
    var Q3 = Wf();
    const e4 = Lr(Q3);
    var mo, y0;
    function t4() {
        if (y0) return mo;
        y0 = 1;
        var r = Wf(), e = kl(), t;
        try {
            t = cf;
        } catch  {}
        var n = function() {}, a = typeof process > "u" ? !1 : /^v?\.0/.test(""), i = function(v) {
            return typeof v == "function";
        }, s = function(v) {
            return !a || !t ? !1 : (v instanceof (t.ReadStream || n) || v instanceof (t.WriteStream || n)) && i(v.close);
        }, o = function(v) {
            return v.setHeader && i(v.abort);
        }, f = function(v, w, E, x) {
            x = r(x);
            var S = !1;
            v.on("close", function() {
                S = !0;
            }), e(v, {
                readable: w,
                writable: E
            }, function(A) {
                if (A) return x(A);
                S = !0, x();
            });
            var y = !1;
            return function(A) {
                if (!S && !y) {
                    if (y = !0, s(v)) return v.close(n);
                    if (o(v)) return v.abort();
                    if (i(v.destroy)) return v.destroy();
                    x(A || new Error("stream was destroyed"));
                }
            };
        }, c = function(v) {
            v();
        }, h = function(v, w) {
            return v.pipe(w);
        }, g = function() {
            var v = Array.prototype.slice.call(arguments), w = i(v[v.length - 1] || n) && v.pop() || n;
            if (Array.isArray(v[0]) && (v = v[0]), v.length < 2) throw new Error("pump requires two streams per minimum");
            var E, x = v.map(function(S, y) {
                var A = y < v.length - 1, P = y > 0;
                return f(S, A, P, function(N) {
                    E || (E = N), N && x.forEach(c), !A && (x.forEach(c), w(E));
                });
            });
            return v.reduce(h);
        };
        return mo = g, mo;
    }
    var r4 = t4();
    const n4 = Lr(r4), tf = Symbol("IGNORE_SUBSTREAM");
    class Nl extends xi.Duplex {
        constructor(e = {}){
            super(Be(Be({}, e), {}, {
                objectMode: !0
            })), he(this, "_substreams", void 0), he(this, "getStream", void 0), this._substreams = {};
        }
        createStream(e) {
            if (!e) throw new Error("ObjectMultiplex - name must not be empty");
            if (this._substreams[e]) throw new Error(`ObjectMultiplex - Substream for name "${e}" already exists`);
            const t = new Al({
                parent: this,
                name: e
            });
            return this._substreams[e] = t, i4(this, (n)=>t.destroy(n || void 0)), t;
        }
        ignoreStream(e) {
            if (!e) throw new Error("ObjectMultiplex - name must not be empty");
            if (this._substreams[e]) throw new Error(`ObjectMultiplex - Substream for name "${e}" already exists`);
            this._substreams[e] = tf;
        }
        _read() {}
        _write(e, t, n) {
            const { name: a, data: i } = e;
            if (!a) return window.console.warn(`ObjectMultiplex - malformed chunk without name "${e}"`), n();
            const s = this._substreams[a];
            return s ? (s !== tf && s.push(i), n()) : (window.console.warn(`ObjectMultiplex - orphaned data for stream "${a}"`), n());
        }
    }
    function i4(r, e) {
        const t = e4(e);
        g0(r, {
            readable: !1
        }, t), g0(r, {
            writable: !1
        }, t);
    }
    function a4(r) {
        const e = new Nl;
        return e.getStream = function(n) {
            return this._substreams[n] ? this._substreams[n] : this.createStream(n);
        }, n4(r, e, r, (t)=>{
            t && window.console.error(t);
        }), e;
    }
    function Yf(r) {
        return r instanceof Uint8Array || ArrayBuffer.isView(r) && r.constructor.name === "Uint8Array";
    }
    function zr(r, e = "") {
        if (!Number.isSafeInteger(r) || r < 0) {
            const t = e && `"${e}" `;
            throw new Error(`${t}expected integer >= 0, got ${r}`);
        }
    }
    function Lt(r, e, t = "") {
        const n = Yf(r), a = r?.length, i = e !== void 0;
        if (!n || i && a !== e) {
            const s = t && `"${t}" `, o = i ? ` of length ${e}` : "", f = n ? `length=${a}` : `type=${typeof r}`;
            throw new Error(s + "expected Uint8Array" + o + ", got " + f);
        }
        return r;
    }
    function Cl(r) {
        if (typeof r != "function" || typeof r.create != "function") throw new Error("Hash must wrapped by utils.createHasher");
        zr(r.outputLen), zr(r.blockLen);
    }
    function Fn(r, e = !0) {
        if (r.destroyed) throw new Error("Hash instance has been destroyed");
        if (e && r.finished) throw new Error("Hash#digest() has already been called");
    }
    function Ll(r, e) {
        Lt(r, void 0, "digestInto() output");
        const t = e.outputLen;
        if (r.length < t) throw new Error('"digestInto() output" expected to be of length >=' + t);
    }
    function s4(r) {
        return new Uint32Array(r.buffer, r.byteOffset, Math.floor(r.byteLength / 4));
    }
    function $n(...r) {
        for(let e = 0; e < r.length; e++)r[e].fill(0);
    }
    function wo(r) {
        return new DataView(r.buffer, r.byteOffset, r.byteLength);
    }
    function Ir(r, e) {
        return r << 32 - e | r >>> e;
    }
    const o4 = new Uint8Array(new Uint32Array([
        287454020
    ]).buffer)[0] === 68;
    function f4(r) {
        return r << 24 & 4278190080 | r << 8 & 16711680 | r >>> 8 & 65280 | r >>> 24 & 255;
    }
    function c4(r) {
        for(let e = 0; e < r.length; e++)r[e] = f4(r[e]);
        return r;
    }
    const v0 = o4 ? (r)=>r : c4, Ul = typeof Uint8Array.from([]).toHex == "function" && typeof Uint8Array.fromHex == "function", d4 = Array.from({
        length: 256
    }, (r, e)=>e.toString(16).padStart(2, "0"));
    function $a(r) {
        if (Lt(r), Ul) return r.toHex();
        let e = "";
        for(let t = 0; t < r.length; t++)e += d4[r[t]];
        return e;
    }
    const Dr = {
        _0: 48,
        _9: 57,
        A: 65,
        F: 70,
        a: 97,
        f: 102
    };
    function m0(r) {
        if (r >= Dr._0 && r <= Dr._9) return r - Dr._0;
        if (r >= Dr.A && r <= Dr.F) return r - (Dr.A - 10);
        if (r >= Dr.a && r <= Dr.f) return r - (Dr.a - 10);
    }
    function gi(r) {
        if (typeof r != "string") throw new Error("hex string expected, got " + typeof r);
        if (Ul) return Uint8Array.fromHex(r);
        const e = r.length, t = e / 2;
        if (e % 2) throw new Error("hex string expected, got unpadded hex of length " + e);
        const n = new Uint8Array(t);
        for(let a = 0, i = 0; a < t; a++, i += 2){
            const s = m0(r.charCodeAt(i)), o = m0(r.charCodeAt(i + 1));
            if (s === void 0 || o === void 0) {
                const f = r[i] + r[i + 1];
                throw new Error('hex string expected, got non-hex character "' + f + '" at index ' + i);
            }
            n[a] = s * 16 + o;
        }
        return n;
    }
    function fn(...r) {
        let e = 0;
        for(let n = 0; n < r.length; n++){
            const a = r[n];
            Lt(a), e += a.length;
        }
        const t = new Uint8Array(e);
        for(let n = 0, a = 0; n < r.length; n++){
            const i = r[n];
            t.set(i, a), a += i.length;
        }
        return t;
    }
    function ql(r, e = {}) {
        const t = (a, i)=>r(i).update(a).digest(), n = r(void 0);
        return t.outputLen = n.outputLen, t.blockLen = n.blockLen, t.create = (a)=>r(a), Object.assign(t, e), Object.freeze(t);
    }
    function Dl(r = 32) {
        const e = typeof globalThis == "object" ? globalThis.crypto : null;
        if (typeof e?.getRandomValues != "function") throw new Error("crypto.getRandomValues must be defined");
        return e.getRandomValues(new Uint8Array(r));
    }
    const u4 = (r)=>({
            oid: Uint8Array.from([
                6,
                9,
                96,
                134,
                72,
                1,
                101,
                3,
                4,
                2,
                r
            ])
        });
    function l4(r, e, t) {
        return r & e ^ ~r & t;
    }
    function h4(r, e, t) {
        return r & e ^ r & t ^ e & t;
    }
    class b4 {
        blockLen;
        outputLen;
        padOffset;
        isLE;
        buffer;
        view;
        finished = !1;
        length = 0;
        pos = 0;
        destroyed = !1;
        constructor(e, t, n, a){
            this.blockLen = e, this.outputLen = t, this.padOffset = n, this.isLE = a, this.buffer = new Uint8Array(e), this.view = wo(this.buffer);
        }
        update(e) {
            Fn(this), Lt(e);
            const { view: t, buffer: n, blockLen: a } = this, i = e.length;
            for(let s = 0; s < i;){
                const o = Math.min(a - this.pos, i - s);
                if (o === a) {
                    const f = wo(e);
                    for(; a <= i - s; s += a)this.process(f, s);
                    continue;
                }
                n.set(e.subarray(s, s + o), this.pos), this.pos += o, s += o, this.pos === a && (this.process(t, 0), this.pos = 0);
            }
            return this.length += e.length, this.roundClean(), this;
        }
        digestInto(e) {
            Fn(this), Ll(e, this), this.finished = !0;
            const { buffer: t, view: n, blockLen: a, isLE: i } = this;
            let { pos: s } = this;
            t[s++] = 128, $n(this.buffer.subarray(s)), this.padOffset > a - s && (this.process(n, 0), s = 0);
            for(let g = s; g < a; g++)t[g] = 0;
            n.setBigUint64(a - 8, BigInt(this.length * 8), i), this.process(n, 0);
            const o = wo(e), f = this.outputLen;
            if (f % 4) throw new Error("_sha2: outputLen must be aligned to 32bit");
            const c = f / 4, h = this.get();
            if (c > h.length) throw new Error("_sha2: outputLen bigger than state");
            for(let g = 0; g < c; g++)o.setUint32(4 * g, h[g], i);
        }
        digest() {
            const { buffer: e, outputLen: t } = this;
            this.digestInto(e);
            const n = e.slice(0, t);
            return this.destroy(), n;
        }
        _cloneInto(e) {
            e ||= new this.constructor, e.set(...this.get());
            const { blockLen: t, buffer: n, length: a, finished: i, destroyed: s, pos: o } = this;
            return e.destroyed = s, e.finished = i, e.length = a, e.pos = o, a % t && e.buffer.set(n), e;
        }
        clone() {
            return this._cloneInto();
        }
    }
    const Zr = Uint32Array.from([
        1779033703,
        3144134277,
        1013904242,
        2773480762,
        1359893119,
        2600822924,
        528734635,
        1541459225
    ]), Hi = BigInt(2 ** 32 - 1), w0 = BigInt(32);
    function p4(r, e = !1) {
        return e ? {
            h: Number(r & Hi),
            l: Number(r >> w0 & Hi)
        } : {
            h: Number(r >> w0 & Hi) | 0,
            l: Number(r & Hi) | 0
        };
    }
    function g4(r, e = !1) {
        const t = r.length;
        let n = new Uint32Array(t), a = new Uint32Array(t);
        for(let i = 0; i < t; i++){
            const { h: s, l: o } = p4(r[i], e);
            [n[i], a[i]] = [
                s,
                o
            ];
        }
        return [
            n,
            a
        ];
    }
    const y4 = (r, e, t)=>r << t | e >>> 32 - t, v4 = (r, e, t)=>e << t | r >>> 32 - t, m4 = (r, e, t)=>e << t - 32 | r >>> 64 - t, w4 = (r, e, t)=>r << t - 32 | e >>> 64 - t, x4 = Uint32Array.from([
        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
    ]), Qr = new Uint32Array(64);
    class _4 extends b4 {
        constructor(e){
            super(64, e, 8, !1);
        }
        get() {
            const { A: e, B: t, C: n, D: a, E: i, F: s, G: o, H: f } = this;
            return [
                e,
                t,
                n,
                a,
                i,
                s,
                o,
                f
            ];
        }
        set(e, t, n, a, i, s, o, f) {
            this.A = e | 0, this.B = t | 0, this.C = n | 0, this.D = a | 0, this.E = i | 0, this.F = s | 0, this.G = o | 0, this.H = f | 0;
        }
        process(e, t) {
            for(let g = 0; g < 16; g++, t += 4)Qr[g] = e.getUint32(t, !1);
            for(let g = 16; g < 64; g++){
                const v = Qr[g - 15], w = Qr[g - 2], E = Ir(v, 7) ^ Ir(v, 18) ^ v >>> 3, x = Ir(w, 17) ^ Ir(w, 19) ^ w >>> 10;
                Qr[g] = x + Qr[g - 7] + E + Qr[g - 16] | 0;
            }
            let { A: n, B: a, C: i, D: s, E: o, F: f, G: c, H: h } = this;
            for(let g = 0; g < 64; g++){
                const v = Ir(o, 6) ^ Ir(o, 11) ^ Ir(o, 25), w = h + v + l4(o, f, c) + x4[g] + Qr[g] | 0, x = (Ir(n, 2) ^ Ir(n, 13) ^ Ir(n, 22)) + h4(n, a, i) | 0;
                h = c, c = f, f = o, o = s + w | 0, s = i, i = a, a = n, n = w + x | 0;
            }
            n = n + this.A | 0, a = a + this.B | 0, i = i + this.C | 0, s = s + this.D | 0, o = o + this.E | 0, f = f + this.F | 0, c = c + this.G | 0, h = h + this.H | 0, this.set(n, a, i, s, o, f, c, h);
        }
        roundClean() {
            $n(Qr);
        }
        destroy() {
            this.set(0, 0, 0, 0, 0, 0, 0, 0), $n(this.buffer);
        }
    }
    class S4 extends _4 {
        A = Zr[0] | 0;
        B = Zr[1] | 0;
        C = Zr[2] | 0;
        D = Zr[3] | 0;
        E = Zr[4] | 0;
        F = Zr[5] | 0;
        G = Zr[6] | 0;
        H = Zr[7] | 0;
        constructor(){
            super(32);
        }
    }
    const Fl = ql(()=>new S4, u4(1));
    const Vf = BigInt(0), rf = BigInt(1);
    function ba(r, e = "") {
        if (typeof r != "boolean") {
            const t = e && `"${e}" `;
            throw new Error(t + "expected boolean, got type=" + typeof r);
        }
        return r;
    }
    function $l(r) {
        if (typeof r == "bigint") {
            if (!ta(r)) throw new Error("positive bigint expected, got " + r);
        } else zr(r);
        return r;
    }
    function zi(r) {
        const e = $l(r).toString(16);
        return e.length & 1 ? "0" + e : e;
    }
    function Kl(r) {
        if (typeof r != "string") throw new Error("hex string expected, got " + typeof r);
        return r === "" ? Vf : BigInt("0x" + r);
    }
    function Ka(r) {
        return Kl($a(r));
    }
    function jl(r) {
        return Kl($a(E4(Lt(r)).reverse()));
    }
    function Gf(r, e) {
        zr(e), r = $l(r);
        const t = gi(r.toString(16).padStart(e * 2, "0"));
        if (t.length !== e) throw new Error("number too large");
        return t;
    }
    function Hl(r, e) {
        return Gf(r, e).reverse();
    }
    function E4(r) {
        return Uint8Array.from(r);
    }
    const ta = (r)=>typeof r == "bigint" && Vf <= r;
    function A4(r, e, t) {
        return ta(r) && ta(e) && ta(t) && e <= r && r < t;
    }
    function I4(r, e, t, n) {
        if (!A4(e, t, n)) throw new Error("expected valid " + r + ": " + t + " <= n < " + n + ", got " + e);
    }
    function M4(r) {
        let e;
        for(e = 0; r > Vf; r >>= rf, e += 1);
        return e;
    }
    const Jf = (r)=>(rf << BigInt(r)) - rf;
    function R4(r, e, t) {
        if (zr(r, "hashLen"), zr(e, "qByteLen"), typeof t != "function") throw new Error("hmacFn must be a function");
        const n = (S)=>new Uint8Array(S), a = Uint8Array.of(), i = Uint8Array.of(0), s = Uint8Array.of(1), o = 1e3;
        let f = n(r), c = n(r), h = 0;
        const g = ()=>{
            f.fill(1), c.fill(0), h = 0;
        }, v = (...S)=>t(c, fn(f, ...S)), w = (S = a)=>{
            c = v(i, S), f = v(), S.length !== 0 && (c = v(s, S), f = v());
        }, E = ()=>{
            if (h++ >= o) throw new Error("drbg: tried max amount of iterations");
            let S = 0;
            const y = [];
            for(; S < e;){
                f = v();
                const A = f.slice();
                y.push(A), S += f.length;
            }
            return fn(...y);
        };
        return (S, y)=>{
            g(), w(S);
            let A;
            for(; !(A = y(E()));)w();
            return g(), A;
        };
    }
    function Xf(r, e = {}, t = {}) {
        if (!r || typeof r != "object") throw new Error("expected valid options object");
        function n(i, s, o) {
            const f = r[i];
            if (o && f === void 0) return;
            const c = typeof f;
            if (c !== s || f === null) throw new Error(`param "${i}" is invalid: expected ${s}, got ${c}`);
        }
        const a = (i, s)=>Object.entries(i).forEach(([o, f])=>n(o, f, s));
        a(e, !1), a(t, !0);
    }
    function x0(r) {
        const e = new WeakMap;
        return (t, ...n)=>{
            const a = e.get(t);
            if (a !== void 0) return a;
            const i = r(t, ...n);
            return e.set(t, i), i;
        };
    }
    const fr = BigInt(0), nr = BigInt(1), wn = BigInt(2), zl = BigInt(3), Wl = BigInt(4), Yl = BigInt(5), T4 = BigInt(7), Vl = BigInt(8), P4 = BigInt(9), Gl = BigInt(16);
    function wr(r, e) {
        const t = r % e;
        return t >= fr ? t : e + t;
    }
    function pr(r, e, t) {
        let n = r;
        for(; e-- > fr;)n *= n, n %= t;
        return n;
    }
    function _0(r, e) {
        if (r === fr) throw new Error("invert: expected non-zero number");
        if (e <= fr) throw new Error("invert: expected positive modulus, got " + e);
        let t = wr(r, e), n = e, a = fr, i = nr;
        for(; t !== fr;){
            const o = n / t, f = n % t, c = a - i * o;
            n = t, t = f, a = i, i = c;
        }
        if (n !== nr) throw new Error("invert: does not exist");
        return wr(a, e);
    }
    function Zf(r, e, t) {
        if (!r.eql(r.sqr(e), t)) throw new Error("Cannot find square root");
    }
    function Jl(r, e) {
        const t = (r.ORDER + nr) / Wl, n = r.pow(e, t);
        return Zf(r, n, e), n;
    }
    function B4(r, e) {
        const t = (r.ORDER - Yl) / Vl, n = r.mul(e, wn), a = r.pow(n, t), i = r.mul(e, a), s = r.mul(r.mul(i, wn), a), o = r.mul(i, r.sub(s, r.ONE));
        return Zf(r, o, e), o;
    }
    function O4(r) {
        const e = ja(r), t = Xl(r), n = t(e, e.neg(e.ONE)), a = t(e, n), i = t(e, e.neg(n)), s = (r + T4) / Gl;
        return (o, f)=>{
            let c = o.pow(f, s), h = o.mul(c, n);
            const g = o.mul(c, a), v = o.mul(c, i), w = o.eql(o.sqr(h), f), E = o.eql(o.sqr(g), f);
            c = o.cmov(c, h, w), h = o.cmov(v, g, E);
            const x = o.eql(o.sqr(h), f), S = o.cmov(c, h, x);
            return Zf(o, S, f), S;
        };
    }
    function Xl(r) {
        if (r < zl) throw new Error("sqrt is not defined for small field");
        let e = r - nr, t = 0;
        for(; e % wn === fr;)e /= wn, t++;
        let n = wn;
        const a = ja(r);
        for(; S0(a, n) === 1;)if (n++ > 1e3) throw new Error("Cannot find square root: probably non-prime P");
        if (t === 1) return Jl;
        let i = a.pow(n, e);
        const s = (e + nr) / wn;
        return function(f, c) {
            if (f.is0(c)) return c;
            if (S0(f, c) !== 1) throw new Error("Cannot find square root");
            let h = t, g = f.mul(f.ONE, i), v = f.pow(c, e), w = f.pow(c, s);
            for(; !f.eql(v, f.ONE);){
                if (f.is0(v)) return f.ZERO;
                let E = 1, x = f.sqr(v);
                for(; !f.eql(x, f.ONE);)if (E++, x = f.sqr(x), E === h) throw new Error("Cannot find square root");
                const S = nr << BigInt(h - E - 1), y = f.pow(g, S);
                h = E, g = f.sqr(y), v = f.mul(v, g), w = f.mul(w, y);
            }
            return w;
        };
    }
    function k4(r) {
        return r % Wl === zl ? Jl : r % Vl === Yl ? B4 : r % Gl === P4 ? O4(r) : Xl(r);
    }
    const N4 = [
        "create",
        "isValid",
        "is0",
        "neg",
        "inv",
        "sqrt",
        "sqr",
        "eql",
        "add",
        "sub",
        "mul",
        "pow",
        "div",
        "addN",
        "subN",
        "mulN",
        "sqrN"
    ];
    function C4(r) {
        const e = {
            ORDER: "bigint",
            BYTES: "number",
            BITS: "number"
        }, t = N4.reduce((n, a)=>(n[a] = "function", n), e);
        return Xf(r, t), r;
    }
    function L4(r, e, t) {
        if (t < fr) throw new Error("invalid exponent, negatives unsupported");
        if (t === fr) return r.ONE;
        if (t === nr) return e;
        let n = r.ONE, a = e;
        for(; t > fr;)t & nr && (n = r.mul(n, a)), a = r.sqr(a), t >>= nr;
        return n;
    }
    function Zl(r, e, t = !1) {
        const n = new Array(e.length).fill(t ? r.ZERO : void 0), a = e.reduce((s, o, f)=>r.is0(o) ? s : (n[f] = s, r.mul(s, o)), r.ONE), i = r.inv(a);
        return e.reduceRight((s, o, f)=>r.is0(o) ? s : (n[f] = r.mul(s, n[f]), r.mul(s, o)), i), n;
    }
    function S0(r, e) {
        const t = (r.ORDER - nr) / wn, n = r.pow(e, t), a = r.eql(n, r.ONE), i = r.eql(n, r.ZERO), s = r.eql(n, r.neg(r.ONE));
        if (!a && !i && !s) throw new Error("invalid Legendre symbol result");
        return a ? 1 : i ? 0 : -1;
    }
    function U4(r, e) {
        e !== void 0 && zr(e);
        const t = e !== void 0 ? e : r.toString(2).length, n = Math.ceil(t / 8);
        return {
            nBitLength: t,
            nByteLength: n
        };
    }
    class q4 {
        ORDER;
        BITS;
        BYTES;
        isLE;
        ZERO = fr;
        ONE = nr;
        _lengths;
        _sqrt;
        _mod;
        constructor(e, t = {}){
            if (e <= fr) throw new Error("invalid field: expected ORDER > 0, got " + e);
            let n;
            this.isLE = !1, t != null && typeof t == "object" && (typeof t.BITS == "number" && (n = t.BITS), typeof t.sqrt == "function" && (this.sqrt = t.sqrt), typeof t.isLE == "boolean" && (this.isLE = t.isLE), t.allowedLengths && (this._lengths = t.allowedLengths?.slice()), typeof t.modFromBytes == "boolean" && (this._mod = t.modFromBytes));
            const { nBitLength: a, nByteLength: i } = U4(e, n);
            if (i > 2048) throw new Error("invalid field: expected ORDER of <= 2048 bytes");
            this.ORDER = e, this.BITS = a, this.BYTES = i, this._sqrt = void 0, Object.preventExtensions(this);
        }
        create(e) {
            return wr(e, this.ORDER);
        }
        isValid(e) {
            if (typeof e != "bigint") throw new Error("invalid field element: expected bigint, got " + typeof e);
            return fr <= e && e < this.ORDER;
        }
        is0(e) {
            return e === fr;
        }
        isValidNot0(e) {
            return !this.is0(e) && this.isValid(e);
        }
        isOdd(e) {
            return (e & nr) === nr;
        }
        neg(e) {
            return wr(-e, this.ORDER);
        }
        eql(e, t) {
            return e === t;
        }
        sqr(e) {
            return wr(e * e, this.ORDER);
        }
        add(e, t) {
            return wr(e + t, this.ORDER);
        }
        sub(e, t) {
            return wr(e - t, this.ORDER);
        }
        mul(e, t) {
            return wr(e * t, this.ORDER);
        }
        pow(e, t) {
            return L4(this, e, t);
        }
        div(e, t) {
            return wr(e * _0(t, this.ORDER), this.ORDER);
        }
        sqrN(e) {
            return e * e;
        }
        addN(e, t) {
            return e + t;
        }
        subN(e, t) {
            return e - t;
        }
        mulN(e, t) {
            return e * t;
        }
        inv(e) {
            return _0(e, this.ORDER);
        }
        sqrt(e) {
            return this._sqrt || (this._sqrt = k4(this.ORDER)), this._sqrt(this, e);
        }
        toBytes(e) {
            return this.isLE ? Hl(e, this.BYTES) : Gf(e, this.BYTES);
        }
        fromBytes(e, t = !1) {
            Lt(e);
            const { _lengths: n, BYTES: a, isLE: i, ORDER: s, _mod: o } = this;
            if (n) {
                if (!n.includes(e.length) || e.length > a) throw new Error("Field.fromBytes: expected " + n + " bytes, got " + e.length);
                const c = new Uint8Array(a);
                c.set(e, i ? 0 : c.length - e.length), e = c;
            }
            if (e.length !== a) throw new Error("Field.fromBytes: expected " + a + " bytes, got " + e.length);
            let f = i ? jl(e) : Ka(e);
            if (o && (f = wr(f, s)), !t && !this.isValid(f)) throw new Error("invalid field element: outside of range 0..ORDER");
            return f;
        }
        invertBatch(e) {
            return Zl(this, e);
        }
        cmov(e, t, n) {
            return n ? t : e;
        }
    }
    function ja(r, e = {}) {
        return new q4(r, e);
    }
    function Ql(r) {
        if (typeof r != "bigint") throw new Error("field order must be bigint");
        const e = r.toString(2).length;
        return Math.ceil(e / 8);
    }
    function eh(r) {
        const e = Ql(r);
        return e + Math.ceil(e / 2);
    }
    function D4(r, e, t = !1) {
        Lt(r);
        const n = r.length, a = Ql(e), i = eh(e);
        if (n < 16 || n < i || n > 1024) throw new Error("expected " + i + "-1024 bytes of input, got " + n);
        const s = t ? jl(r) : Ka(r), o = wr(s, e - nr) + nr;
        return t ? Hl(o, a) : Gf(o, a);
    }
    const Kn = BigInt(0), xn = BigInt(1);
    function pa(r, e) {
        const t = e.negate();
        return r ? t : e;
    }
    function E0(r, e) {
        const t = Zl(r.Fp, e.map((n)=>n.Z));
        return e.map((n, a)=>r.fromAffine(n.toAffine(t[a])));
    }
    function th(r, e) {
        if (!Number.isSafeInteger(r) || r <= 0 || r > e) throw new Error("invalid window size, expected [1.." + e + "], got W=" + r);
    }
    function xo(r, e) {
        th(r, e);
        const t = Math.ceil(e / r) + 1, n = 2 ** (r - 1), a = 2 ** r, i = Jf(r), s = BigInt(r);
        return {
            windows: t,
            windowSize: n,
            mask: i,
            maxNumber: a,
            shiftBy: s
        };
    }
    function A0(r, e, t) {
        const { windowSize: n, mask: a, maxNumber: i, shiftBy: s } = t;
        let o = Number(r & a), f = r >> s;
        o > n && (o -= i, f += xn);
        const c = e * n, h = c + Math.abs(o) - 1, g = o === 0, v = o < 0, w = e % 2 !== 0;
        return {
            nextN: f,
            offset: h,
            isZero: g,
            isNeg: v,
            isNegF: w,
            offsetF: c
        };
    }
    const _o = new WeakMap, rh = new WeakMap;
    function So(r) {
        return rh.get(r) || 1;
    }
    function I0(r) {
        if (r !== Kn) throw new Error("invalid wNAF");
    }
    class F4 {
        BASE;
        ZERO;
        Fn;
        bits;
        constructor(e, t){
            this.BASE = e.BASE, this.ZERO = e.ZERO, this.Fn = e.Fn, this.bits = t;
        }
        _unsafeLadder(e, t, n = this.ZERO) {
            let a = e;
            for(; t > Kn;)t & xn && (n = n.add(a)), a = a.double(), t >>= xn;
            return n;
        }
        precomputeWindow(e, t) {
            const { windows: n, windowSize: a } = xo(t, this.bits), i = [];
            let s = e, o = s;
            for(let f = 0; f < n; f++){
                o = s, i.push(o);
                for(let c = 1; c < a; c++)o = o.add(s), i.push(o);
                s = o.double();
            }
            return i;
        }
        wNAF(e, t, n) {
            if (!this.Fn.isValid(n)) throw new Error("invalid scalar");
            let a = this.ZERO, i = this.BASE;
            const s = xo(e, this.bits);
            for(let o = 0; o < s.windows; o++){
                const { nextN: f, offset: c, isZero: h, isNeg: g, isNegF: v, offsetF: w } = A0(n, o, s);
                n = f, h ? i = i.add(pa(v, t[w])) : a = a.add(pa(g, t[c]));
            }
            return I0(n), {
                p: a,
                f: i
            };
        }
        wNAFUnsafe(e, t, n, a = this.ZERO) {
            const i = xo(e, this.bits);
            for(let s = 0; s < i.windows && n !== Kn; s++){
                const { nextN: o, offset: f, isZero: c, isNeg: h } = A0(n, s, i);
                if (n = o, !c) {
                    const g = t[f];
                    a = a.add(h ? g.negate() : g);
                }
            }
            return I0(n), a;
        }
        getPrecomputes(e, t, n) {
            let a = _o.get(t);
            return a || (a = this.precomputeWindow(t, e), e !== 1 && (typeof n == "function" && (a = n(a)), _o.set(t, a))), a;
        }
        cached(e, t, n) {
            const a = So(e);
            return this.wNAF(a, this.getPrecomputes(a, e, n), t);
        }
        unsafe(e, t, n, a) {
            const i = So(e);
            return i === 1 ? this._unsafeLadder(e, t, a) : this.wNAFUnsafe(i, this.getPrecomputes(i, e, n), t, a);
        }
        createCache(e, t) {
            th(t, this.bits), rh.set(e, t), _o.delete(e);
        }
        hasCache(e) {
            return So(e) !== 1;
        }
    }
    function $4(r, e, t, n) {
        let a = e, i = r.ZERO, s = r.ZERO;
        for(; t > Kn || n > Kn;)t & xn && (i = i.add(a)), n & xn && (s = s.add(a)), a = a.double(), t >>= xn, n >>= xn;
        return {
            p1: i,
            p2: s
        };
    }
    function M0(r, e, t) {
        if (e) {
            if (e.ORDER !== r) throw new Error("Field.ORDER must match order: Fp == p, Fn == n");
            return C4(e), e;
        } else return ja(r, {
            isLE: t
        });
    }
    function K4(r, e, t = {}, n) {
        if (n === void 0 && (n = r === "edwards"), !e || typeof e != "object") throw new Error(`expected valid ${r} CURVE object`);
        for (const f of [
            "p",
            "n",
            "h"
        ]){
            const c = e[f];
            if (!(typeof c == "bigint" && c > Kn)) throw new Error(`CURVE.${f} must be positive bigint`);
        }
        const a = M0(e.p, t.Fp, n), i = M0(e.n, t.Fn, n), o = [
            "Gx",
            "Gy",
            "a",
            "b"
        ];
        for (const f of o)if (!a.isValid(e[f])) throw new Error(`CURVE.${f} must be valid field element of CURVE.Fp`);
        return e = Object.freeze(Object.assign({}, e)), {
            CURVE: e,
            Fp: a,
            Fn: i
        };
    }
    function j4(r, e) {
        return function(n) {
            const a = r(n);
            return {
                secretKey: a,
                publicKey: e(a)
            };
        };
    }
    class nh {
        oHash;
        iHash;
        blockLen;
        outputLen;
        finished = !1;
        destroyed = !1;
        constructor(e, t){
            if (Cl(e), Lt(t, void 0, "key"), this.iHash = e.create(), typeof this.iHash.update != "function") throw new Error("Expected instance of class which extends utils.Hash");
            this.blockLen = this.iHash.blockLen, this.outputLen = this.iHash.outputLen;
            const n = this.blockLen, a = new Uint8Array(n);
            a.set(t.length > n ? e.create().update(t).digest() : t);
            for(let i = 0; i < a.length; i++)a[i] ^= 54;
            this.iHash.update(a), this.oHash = e.create();
            for(let i = 0; i < a.length; i++)a[i] ^= 106;
            this.oHash.update(a), $n(a);
        }
        update(e) {
            return Fn(this), this.iHash.update(e), this;
        }
        digestInto(e) {
            Fn(this), Lt(e, this.outputLen, "output"), this.finished = !0, this.iHash.digestInto(e), this.oHash.update(e), this.oHash.digestInto(e), this.destroy();
        }
        digest() {
            const e = new Uint8Array(this.oHash.outputLen);
            return this.digestInto(e), e;
        }
        _cloneInto(e) {
            e ||= Object.create(Object.getPrototypeOf(this), {});
            const { oHash: t, iHash: n, finished: a, destroyed: i, blockLen: s, outputLen: o } = this;
            return e = e, e.finished = a, e.destroyed = i, e.blockLen = s, e.outputLen = o, e.oHash = t._cloneInto(e.oHash), e.iHash = n._cloneInto(e.iHash), e;
        }
        clone() {
            return this._cloneInto();
        }
        destroy() {
            this.destroyed = !0, this.oHash.destroy(), this.iHash.destroy();
        }
    }
    const ih = (r, e, t)=>new nh(r, e).update(t).digest();
    ih.create = (r, e)=>new nh(r, e);
    const R0 = (r, e)=>(r + (r >= 0 ? e : -e) / ah) / e;
    function H4(r, e, t) {
        const [[n, a], [i, s]] = e, o = R0(s * r, t), f = R0(-a * r, t);
        let c = r - o * n - f * i, h = -o * a - f * s;
        const g = c < jr, v = h < jr;
        g && (c = -c), v && (h = -h);
        const w = Jf(Math.ceil(M4(t) / 2)) + Cn;
        if (c < jr || c >= w || h < jr || h >= w) throw new Error("splitScalar (endomorphism): failed, k=" + r);
        return {
            k1neg: g,
            k1: c,
            k2neg: v,
            k2: h
        };
    }
    function nf(r) {
        if (![
            "compact",
            "recovered",
            "der"
        ].includes(r)) throw new Error('Signature format must be "compact", "recovered", or "der"');
        return r;
    }
    function Eo(r, e) {
        const t = {};
        for (let n of Object.keys(e))t[n] = r[n] === void 0 ? e[n] : r[n];
        return ba(t.lowS, "lowS"), ba(t.prehash, "prehash"), t.format !== void 0 && nf(t.format), t;
    }
    class z4 extends Error {
        constructor(e = ""){
            super(e);
        }
    }
    const nn = {
        Err: z4,
        _tlv: {
            encode: (r, e)=>{
                const { Err: t } = nn;
                if (r < 0 || r > 256) throw new t("tlv.encode: wrong tag");
                if (e.length & 1) throw new t("tlv.encode: unpadded data");
                const n = e.length / 2, a = zi(n);
                if (a.length / 2 & 128) throw new t("tlv.encode: long form length too big");
                const i = n > 127 ? zi(a.length / 2 | 128) : "";
                return zi(r) + i + a + e;
            },
            decode (r, e) {
                const { Err: t } = nn;
                let n = 0;
                if (r < 0 || r > 256) throw new t("tlv.encode: wrong tag");
                if (e.length < 2 || e[n++] !== r) throw new t("tlv.decode: wrong tlv");
                const a = e[n++], i = !!(a & 128);
                let s = 0;
                if (!i) s = a;
                else {
                    const f = a & 127;
                    if (!f) throw new t("tlv.decode(long): indefinite length not supported");
                    if (f > 4) throw new t("tlv.decode(long): byte length is too big");
                    const c = e.subarray(n, n + f);
                    if (c.length !== f) throw new t("tlv.decode: length bytes not complete");
                    if (c[0] === 0) throw new t("tlv.decode(long): zero leftmost byte");
                    for (const h of c)s = s << 8 | h;
                    if (n += f, s < 128) throw new t("tlv.decode(long): not minimal encoding");
                }
                const o = e.subarray(n, n + s);
                if (o.length !== s) throw new t("tlv.decode: wrong value length");
                return {
                    v: o,
                    l: e.subarray(n + s)
                };
            }
        },
        _int: {
            encode (r) {
                const { Err: e } = nn;
                if (r < jr) throw new e("integer: negative integers are not allowed");
                let t = zi(r);
                if (Number.parseInt(t[0], 16) & 8 && (t = "00" + t), t.length & 1) throw new e("unexpected DER parsing assertion: unpadded hex");
                return t;
            },
            decode (r) {
                const { Err: e } = nn;
                if (r[0] & 128) throw new e("invalid signature integer: negative");
                if (r[0] === 0 && !(r[1] & 128)) throw new e("invalid signature integer: unnecessary leading zero");
                return Ka(r);
            }
        },
        toSig (r) {
            const { Err: e, _int: t, _tlv: n } = nn, a = Lt(r, void 0, "signature"), { v: i, l: s } = n.decode(48, a);
            if (s.length) throw new e("invalid signature: left bytes after parsing");
            const { v: o, l: f } = n.decode(2, i), { v: c, l: h } = n.decode(2, f);
            if (h.length) throw new e("invalid signature: left bytes after parsing");
            return {
                r: t.decode(o),
                s: t.decode(c)
            };
        },
        hexFromSig (r) {
            const { _tlv: e, _int: t } = nn, n = e.encode(2, t.encode(r.r)), a = e.encode(2, t.encode(r.s)), i = n + a;
            return e.encode(48, i);
        }
    }, jr = BigInt(0), Cn = BigInt(1), ah = BigInt(2), Wi = BigInt(3), W4 = BigInt(4);
    function Y4(r, e = {}) {
        const t = K4("weierstrass", r, e), { Fp: n, Fn: a } = t;
        let i = t.CURVE;
        const { h: s, n: o } = i;
        Xf(e, {}, {
            allowInfinityPoint: "boolean",
            clearCofactor: "function",
            isTorsionFree: "function",
            fromBytes: "function",
            toBytes: "function",
            endo: "object"
        });
        const { endo: f } = e;
        if (f && (!n.is0(i.a) || typeof f.beta != "bigint" || !Array.isArray(f.basises))) throw new Error('invalid endo: expected "beta": bigint and "basises": array');
        const c = oh(n, a);
        function h() {
            if (!n.isOdd) throw new Error("compression is not supported: Field does not have .isOdd()");
        }
        function g(d, l, b) {
            const { x: m, y: _ } = l.toAffine(), B = n.toBytes(m);
            if (ba(b, "isCompressed"), b) {
                h();
                const T = !n.isOdd(_);
                return fn(sh(T), B);
            } else return fn(Uint8Array.of(4), B, n.toBytes(_));
        }
        function v(d) {
            Lt(d, void 0, "Point");
            const { publicKey: l, publicKeyUncompressed: b } = c, m = d.length, _ = d[0], B = d.subarray(1);
            if (m === l && (_ === 2 || _ === 3)) {
                const T = n.fromBytes(B);
                if (!n.isValid(T)) throw new Error("bad point: is not on curve, wrong x");
                const R = x(T);
                let u;
                try {
                    u = n.sqrt(R);
                } catch ($) {
                    const te = $ instanceof Error ? ": " + $.message : "";
                    throw new Error("bad point: is not on curve, sqrt error" + te);
                }
                h();
                const I = n.isOdd(u);
                return (_ & 1) === 1 !== I && (u = n.neg(u)), {
                    x: T,
                    y: u
                };
            } else if (m === b && _ === 4) {
                const T = n.BYTES, R = n.fromBytes(B.subarray(0, T)), u = n.fromBytes(B.subarray(T, T * 2));
                if (!S(R, u)) throw new Error("bad point: is not on curve");
                return {
                    x: R,
                    y: u
                };
            } else throw new Error(`bad point: got length ${m}, expected compressed=${l} or uncompressed=${b}`);
        }
        const w = e.toBytes || g, E = e.fromBytes || v;
        function x(d) {
            const l = n.sqr(d), b = n.mul(l, d);
            return n.add(n.add(b, n.mul(d, i.a)), i.b);
        }
        function S(d, l) {
            const b = n.sqr(l), m = x(d);
            return n.eql(b, m);
        }
        if (!S(i.Gx, i.Gy)) throw new Error("bad curve params: generator point");
        const y = n.mul(n.pow(i.a, Wi), W4), A = n.mul(n.sqr(i.b), BigInt(27));
        if (n.is0(n.add(y, A))) throw new Error("bad curve params: a or b");
        function P(d, l, b = !1) {
            if (!n.isValid(l) || b && n.is0(l)) throw new Error(`bad point coordinate ${d}`);
            return l;
        }
        function N(d) {
            if (!(d instanceof j)) throw new Error("Weierstrass Point expected");
        }
        function k(d) {
            if (!f || !f.basises) throw new Error("no endo");
            return H4(d, f.basises, a.ORDER);
        }
        const D = x0((d, l)=>{
            const { X: b, Y: m, Z: _ } = d;
            if (n.eql(_, n.ONE)) return {
                x: b,
                y: m
            };
            const B = d.is0();
            l == null && (l = B ? n.ONE : n.inv(_));
            const T = n.mul(b, l), R = n.mul(m, l), u = n.mul(_, l);
            if (B) return {
                x: n.ZERO,
                y: n.ZERO
            };
            if (!n.eql(u, n.ONE)) throw new Error("invZ was invalid");
            return {
                x: T,
                y: R
            };
        }), V = x0((d)=>{
            if (d.is0()) {
                if (e.allowInfinityPoint && !n.is0(d.Y)) return;
                throw new Error("bad point: ZERO");
            }
            const { x: l, y: b } = d.toAffine();
            if (!n.isValid(l) || !n.isValid(b)) throw new Error("bad point: x or y not field elements");
            if (!S(l, b)) throw new Error("bad point: equation left != right");
            if (!d.isTorsionFree()) throw new Error("bad point: not in prime-order subgroup");
            return !0;
        });
        function K(d, l, b, m, _) {
            return b = new j(n.mul(b.X, d), b.Y, b.Z), l = pa(m, l), b = pa(_, b), l.add(b);
        }
        class j {
            static BASE = new j(i.Gx, i.Gy, n.ONE);
            static ZERO = new j(n.ZERO, n.ONE, n.ZERO);
            static Fp = n;
            static Fn = a;
            X;
            Y;
            Z;
            constructor(l, b, m){
                this.X = P("x", l), this.Y = P("y", b, !0), this.Z = P("z", m), Object.freeze(this);
            }
            static CURVE() {
                return i;
            }
            static fromAffine(l) {
                const { x: b, y: m } = l || {};
                if (!l || !n.isValid(b) || !n.isValid(m)) throw new Error("invalid affine point");
                if (l instanceof j) throw new Error("projective point not allowed");
                return n.is0(b) && n.is0(m) ? j.ZERO : new j(b, m, n.ONE);
            }
            static fromBytes(l) {
                const b = j.fromAffine(E(Lt(l, void 0, "point")));
                return b.assertValidity(), b;
            }
            static fromHex(l) {
                return j.fromBytes(gi(l));
            }
            get x() {
                return this.toAffine().x;
            }
            get y() {
                return this.toAffine().y;
            }
            precompute(l = 8, b = !0) {
                return O.createCache(this, l), b || this.multiply(Wi), this;
            }
            assertValidity() {
                V(this);
            }
            hasEvenY() {
                const { y: l } = this.toAffine();
                if (!n.isOdd) throw new Error("Field doesn't support isOdd");
                return !n.isOdd(l);
            }
            equals(l) {
                N(l);
                const { X: b, Y: m, Z: _ } = this, { X: B, Y: T, Z: R } = l, u = n.eql(n.mul(b, R), n.mul(B, _)), I = n.eql(n.mul(m, R), n.mul(T, _));
                return u && I;
            }
            negate() {
                return new j(this.X, n.neg(this.Y), this.Z);
            }
            double() {
                const { a: l, b } = i, m = n.mul(b, Wi), { X: _, Y: B, Z: T } = this;
                let R = n.ZERO, u = n.ZERO, I = n.ZERO, G = n.mul(_, _), $ = n.mul(B, B), te = n.mul(T, T), Z = n.mul(_, B);
                return Z = n.add(Z, Z), I = n.mul(_, T), I = n.add(I, I), R = n.mul(l, I), u = n.mul(m, te), u = n.add(R, u), R = n.sub($, u), u = n.add($, u), u = n.mul(R, u), R = n.mul(Z, R), I = n.mul(m, I), te = n.mul(l, te), Z = n.sub(G, te), Z = n.mul(l, Z), Z = n.add(Z, I), I = n.add(G, G), G = n.add(I, G), G = n.add(G, te), G = n.mul(G, Z), u = n.add(u, G), te = n.mul(B, T), te = n.add(te, te), G = n.mul(te, Z), R = n.sub(R, G), I = n.mul(te, $), I = n.add(I, I), I = n.add(I, I), new j(R, u, I);
            }
            add(l) {
                N(l);
                const { X: b, Y: m, Z: _ } = this, { X: B, Y: T, Z: R } = l;
                let u = n.ZERO, I = n.ZERO, G = n.ZERO;
                const $ = i.a, te = n.mul(i.b, Wi);
                let Z = n.mul(b, B), fe = n.mul(m, T), pe = n.mul(_, R), ee = n.add(b, m), J = n.add(B, T);
                ee = n.mul(ee, J), J = n.add(Z, fe), ee = n.sub(ee, J), J = n.add(b, _);
                let oe = n.add(B, R);
                return J = n.mul(J, oe), oe = n.add(Z, pe), J = n.sub(J, oe), oe = n.add(m, _), u = n.add(T, R), oe = n.mul(oe, u), u = n.add(fe, pe), oe = n.sub(oe, u), G = n.mul($, J), u = n.mul(te, pe), G = n.add(u, G), u = n.sub(fe, G), G = n.add(fe, G), I = n.mul(u, G), fe = n.add(Z, Z), fe = n.add(fe, Z), pe = n.mul($, pe), J = n.mul(te, J), fe = n.add(fe, pe), pe = n.sub(Z, pe), pe = n.mul($, pe), J = n.add(J, pe), Z = n.mul(fe, J), I = n.add(I, Z), Z = n.mul(oe, J), u = n.mul(ee, u), u = n.sub(u, Z), Z = n.mul(ee, fe), G = n.mul(oe, G), G = n.add(G, Z), new j(u, I, G);
            }
            subtract(l) {
                return this.add(l.negate());
            }
            is0() {
                return this.equals(j.ZERO);
            }
            multiply(l) {
                const { endo: b } = e;
                if (!a.isValidNot0(l)) throw new Error("invalid scalar: out of range");
                let m, _;
                const B = (T)=>O.cached(this, T, (R)=>E0(j, R));
                if (b) {
                    const { k1neg: T, k1: R, k2neg: u, k2: I } = k(l), { p: G, f: $ } = B(R), { p: te, f: Z } = B(I);
                    _ = $.add(Z), m = K(b.beta, G, te, T, u);
                } else {
                    const { p: T, f: R } = B(l);
                    m = T, _ = R;
                }
                return E0(j, [
                    m,
                    _
                ])[0];
            }
            multiplyUnsafe(l) {
                const { endo: b } = e, m = this;
                if (!a.isValid(l)) throw new Error("invalid scalar: out of range");
                if (l === jr || m.is0()) return j.ZERO;
                if (l === Cn) return m;
                if (O.hasCache(this)) return this.multiply(l);
                if (b) {
                    const { k1neg: _, k1: B, k2neg: T, k2: R } = k(l), { p1: u, p2: I } = $4(j, m, B, R);
                    return K(b.beta, u, I, _, T);
                } else return O.unsafe(m, l);
            }
            toAffine(l) {
                return D(this, l);
            }
            isTorsionFree() {
                const { isTorsionFree: l } = e;
                return s === Cn ? !0 : l ? l(j, this) : O.unsafe(this, o).is0();
            }
            clearCofactor() {
                const { clearCofactor: l } = e;
                return s === Cn ? this : l ? l(j, this) : this.multiplyUnsafe(s);
            }
            isSmallOrder() {
                return this.multiplyUnsafe(s).is0();
            }
            toBytes(l = !0) {
                return ba(l, "isCompressed"), this.assertValidity(), w(j, this, l);
            }
            toHex(l = !0) {
                return $a(this.toBytes(l));
            }
            toString() {
                return `<Point ${this.is0() ? "ZERO" : this.toHex()}>`;
            }
        }
        const H = a.BITS, O = new F4(j, e.endo ? Math.ceil(H / 2) : H);
        return j.BASE.precompute(8), j;
    }
    function sh(r) {
        return Uint8Array.of(r ? 2 : 3);
    }
    function oh(r, e) {
        return {
            secretKey: e.BYTES,
            publicKey: 1 + r.BYTES,
            publicKeyUncompressed: 1 + 2 * r.BYTES,
            publicKeyHasPrefix: !0,
            signature: 2 * e.BYTES
        };
    }
    function V4(r, e = {}) {
        const { Fn: t } = r, n = e.randomBytes || Dl, a = Object.assign(oh(r.Fp, t), {
            seed: eh(t.ORDER)
        });
        function i(w) {
            try {
                const E = t.fromBytes(w);
                return t.isValidNot0(E);
            } catch  {
                return !1;
            }
        }
        function s(w, E) {
            const { publicKey: x, publicKeyUncompressed: S } = a;
            try {
                const y = w.length;
                return E === !0 && y !== x || E === !1 && y !== S ? !1 : !!r.fromBytes(w);
            } catch  {
                return !1;
            }
        }
        function o(w = n(a.seed)) {
            return D4(Lt(w, a.seed, "seed"), t.ORDER);
        }
        function f(w, E = !0) {
            return r.BASE.multiply(t.fromBytes(w)).toBytes(E);
        }
        function c(w) {
            const { secretKey: E, publicKey: x, publicKeyUncompressed: S } = a;
            if (!Yf(w) || "_lengths" in t && t._lengths || E === x) return;
            const y = Lt(w, void 0, "key").length;
            return y === x || y === S;
        }
        function h(w, E, x = !0) {
            if (c(w) === !0) throw new Error("first arg must be private key");
            if (c(E) === !1) throw new Error("second arg must be public key");
            const S = t.fromBytes(w);
            return r.fromBytes(E).multiply(S).toBytes(x);
        }
        const g = {
            isValidSecretKey: i,
            isValidPublicKey: s,
            randomSecretKey: o
        }, v = j4(o, f);
        return Object.freeze({
            getPublicKey: f,
            getSharedSecret: h,
            keygen: v,
            Point: r,
            utils: g,
            lengths: a
        });
    }
    function G4(r, e, t = {}) {
        Cl(e), Xf(t, {}, {
            hmac: "function",
            lowS: "boolean",
            randomBytes: "function",
            bits2int: "function",
            bits2int_modN: "function"
        }), t = Object.assign({}, t);
        const n = t.randomBytes || Dl, a = t.hmac || ((b, m)=>ih(e, b, m)), { Fp: i, Fn: s } = r, { ORDER: o, BITS: f } = s, { keygen: c, getPublicKey: h, getSharedSecret: g, utils: v, lengths: w } = V4(r, t), E = {
            prehash: !0,
            lowS: typeof t.lowS == "boolean" ? t.lowS : !0,
            format: "compact",
            extraEntropy: !1
        }, x = o * ah < i.ORDER;
        function S(b) {
            const m = o >> Cn;
            return b > m;
        }
        function y(b, m) {
            if (!s.isValidNot0(m)) throw new Error(`invalid signature ${b}: out of range 1..Point.Fn.ORDER`);
            return m;
        }
        function A() {
            if (x) throw new Error('"recovered" sig type is not supported for cofactor >2 curves');
        }
        function P(b, m) {
            nf(m);
            const _ = w.signature, B = m === "compact" ? _ : m === "recovered" ? _ + 1 : void 0;
            return Lt(b, B);
        }
        class N {
            r;
            s;
            recovery;
            constructor(m, _, B){
                if (this.r = y("r", m), this.s = y("s", _), B != null) {
                    if (A(), ![
                        0,
                        1,
                        2,
                        3
                    ].includes(B)) throw new Error("invalid recovery id");
                    this.recovery = B;
                }
                Object.freeze(this);
            }
            static fromBytes(m, _ = E.format) {
                P(m, _);
                let B;
                if (_ === "der") {
                    const { r: I, s: G } = nn.toSig(Lt(m));
                    return new N(I, G);
                }
                _ === "recovered" && (B = m[0], _ = "compact", m = m.subarray(1));
                const T = w.signature / 2, R = m.subarray(0, T), u = m.subarray(T, T * 2);
                return new N(s.fromBytes(R), s.fromBytes(u), B);
            }
            static fromHex(m, _) {
                return this.fromBytes(gi(m), _);
            }
            assertRecovery() {
                const { recovery: m } = this;
                if (m == null) throw new Error("invalid recovery id: must be present");
                return m;
            }
            addRecoveryBit(m) {
                return new N(this.r, this.s, m);
            }
            recoverPublicKey(m) {
                const { r: _, s: B } = this, T = this.assertRecovery(), R = T === 2 || T === 3 ? _ + o : _;
                if (!i.isValid(R)) throw new Error("invalid recovery id: sig.r+curve.n != R.x");
                const u = i.toBytes(R), I = r.fromBytes(fn(sh((T & 1) === 0), u)), G = s.inv(R), $ = D(Lt(m, void 0, "msgHash")), te = s.create(-$ * G), Z = s.create(B * G), fe = r.BASE.multiplyUnsafe(te).add(I.multiplyUnsafe(Z));
                if (fe.is0()) throw new Error("invalid recovery: point at infinify");
                return fe.assertValidity(), fe;
            }
            hasHighS() {
                return S(this.s);
            }
            toBytes(m = E.format) {
                if (nf(m), m === "der") return gi(nn.hexFromSig(this));
                const { r: _, s: B } = this, T = s.toBytes(_), R = s.toBytes(B);
                return m === "recovered" ? (A(), fn(Uint8Array.of(this.assertRecovery()), T, R)) : fn(T, R);
            }
            toHex(m) {
                return $a(this.toBytes(m));
            }
        }
        const k = t.bits2int || function(m) {
            if (m.length > 8192) throw new Error("input is too large");
            const _ = Ka(m), B = m.length * 8 - f;
            return B > 0 ? _ >> BigInt(B) : _;
        }, D = t.bits2int_modN || function(m) {
            return s.create(k(m));
        }, V = Jf(f);
        function K(b) {
            return I4("num < 2^" + f, b, jr, V), s.toBytes(b);
        }
        function j(b, m) {
            return Lt(b, void 0, "message"), m ? Lt(e(b), void 0, "prehashed message") : b;
        }
        function H(b, m, _) {
            const { lowS: B, prehash: T, extraEntropy: R } = Eo(_, E);
            b = j(b, T);
            const u = D(b), I = s.fromBytes(m);
            if (!s.isValidNot0(I)) throw new Error("invalid private key");
            const G = [
                K(I),
                K(u)
            ];
            if (R != null && R !== !1) {
                const fe = R === !0 ? n(w.secretKey) : R;
                G.push(Lt(fe, void 0, "extraEntropy"));
            }
            const $ = fn(...G), te = u;
            function Z(fe) {
                const pe = k(fe);
                if (!s.isValidNot0(pe)) return;
                const ee = s.inv(pe), J = r.BASE.multiply(pe).toAffine(), oe = s.create(J.x);
                if (oe === jr) return;
                const Me = s.create(ee * s.create(te + oe * I));
                if (Me === jr) return;
                let xe = (J.x === oe ? 0 : 2) | Number(J.y & Cn), z = Me;
                return B && S(Me) && (z = s.neg(Me), xe ^= 1), new N(oe, z, x ? void 0 : xe);
            }
            return {
                seed: $,
                k2sig: Z
            };
        }
        function O(b, m, _ = {}) {
            const { seed: B, k2sig: T } = H(b, m, _);
            return R4(e.outputLen, s.BYTES, a)(B, T).toBytes(_.format);
        }
        function d(b, m, _, B = {}) {
            const { lowS: T, prehash: R, format: u } = Eo(B, E);
            if (_ = Lt(_, void 0, "publicKey"), m = j(m, R), !Yf(b)) {
                const I = b instanceof N ? ", use sig.toBytes()" : "";
                throw new Error("verify expects Uint8Array signature" + I);
            }
            P(b, u);
            try {
                const I = N.fromBytes(b, u), G = r.fromBytes(_);
                if (T && I.hasHighS()) return !1;
                const { r: $, s: te } = I, Z = D(m), fe = s.inv(te), pe = s.create(Z * fe), ee = s.create($ * fe), J = r.BASE.multiplyUnsafe(pe).add(G.multiplyUnsafe(ee));
                return J.is0() ? !1 : s.create(J.x) === $;
            } catch  {
                return !1;
            }
        }
        function l(b, m, _ = {}) {
            const { prehash: B } = Eo(_, E);
            return m = j(m, B), N.fromBytes(b, "recovered").recoverPublicKey(m).toBytes();
        }
        return Object.freeze({
            keygen: c,
            getPublicKey: h,
            getSharedSecret: g,
            utils: v,
            lengths: w,
            Point: r,
            sign: O,
            verify: d,
            recoverPublicKey: l,
            Signature: N,
            hash: e
        });
    }
    const Qf = {
        p: BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),
        n: BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),
        h: BigInt(1),
        a: BigInt(0),
        b: BigInt(7),
        Gx: BigInt("0x79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798"),
        Gy: BigInt("0x483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8")
    }, J4 = {
        beta: BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),
        basises: [
            [
                BigInt("0x3086d221a7d46bcde86c90e49284eb15"),
                -BigInt("0xe4437ed6010e88286f547fa90abfe4c3")
            ],
            [
                BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),
                BigInt("0x3086d221a7d46bcde86c90e49284eb15")
            ]
        ]
    }, T0 = BigInt(2);
    function X4(r) {
        const e = Qf.p, t = BigInt(3), n = BigInt(6), a = BigInt(11), i = BigInt(22), s = BigInt(23), o = BigInt(44), f = BigInt(88), c = r * r * r % e, h = c * c * r % e, g = pr(h, t, e) * h % e, v = pr(g, t, e) * h % e, w = pr(v, T0, e) * c % e, E = pr(w, a, e) * w % e, x = pr(E, i, e) * E % e, S = pr(x, o, e) * x % e, y = pr(S, f, e) * S % e, A = pr(y, o, e) * x % e, P = pr(A, t, e) * h % e, N = pr(P, s, e) * E % e, k = pr(N, n, e) * c % e, D = pr(k, T0, e);
        if (!af.eql(af.sqr(D), r)) throw new Error("Cannot find square root");
        return D;
    }
    const af = ja(Qf.p, {
        sqrt: X4
    }), Z4 = Y4(Qf, {
        Fp: af,
        endo: J4
    }), ec = G4(Z4, Fl), Q4 = "ETHEREUMJS_DEFAULT_ERROR_CODE";
    class e5 extends Error {
        constructor(e, t, n){
            super(t ?? e.code), this.type = e, n !== void 0 && (this.stack = n);
        }
        getMetadata() {
            return this.type;
        }
        toObject() {
            return {
                type: this.getMetadata(),
                message: this.message ?? "",
                stack: this.stack ?? "",
                className: this.constructor.name
            };
        }
    }
    function _i(r, e) {
        return new e5({
            code: Q4
        }, r, e);
    }
    function t5(r, e) {
        return !(typeof r != "string" || !r.match(/^0x[0-9A-Fa-f]*$/));
    }
    const r5 = (r)=>{
        if (typeof r != "string") throw _i(`[stripHexPrefix] input must be type 'string', received ${typeof r}`);
        return t5(r) ? r.slice(2) : r;
    };
    function n5(r) {
        let e = r;
        if (typeof e != "string") throw _i(`[padToEven] value must be type 'string', received ${typeof e}`);
        return e.length % 2 && (e = `0${e}`), e;
    }
    const fh = function(r) {
        if (!(r instanceof Uint8Array)) {
            const e = `This method only supports Uint8Array but input was: ${r}`;
            throw _i(e);
        }
    };
    BigInt(0);
    const tc = (r)=>{
        if (!r.startsWith("0x")) throw _i("input string must be 0x prefixed");
        return gi(n5(r5(r)));
    };
    for(let r = 0; r <= 256 * 256 - 1; r++)BigInt(r);
    BigInt("0xffffffffffffffff");
    BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");
    BigInt("115792089237316195423570985008687907853269984665640564039457584007913129639935");
    const i5 = ec.Point.CURVE().n;
    i5 / BigInt(2);
    BigInt("0x10000000000000000000000000000000000000000000000000000000000000000");
    const a5 = "0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470";
    tc(a5);
    const s5 = "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347";
    tc(s5);
    const o5 = "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421";
    tc(o5);
    Fl(new Uint8Array);
    Uint8Array.from([
        128
    ]);
    BigInt(-1);
    BigInt(0);
    BigInt(1);
    BigInt(2);
    BigInt(3);
    BigInt(7);
    BigInt(8);
    BigInt(27);
    BigInt(28);
    BigInt(31);
    BigInt(32);
    BigInt(64);
    BigInt(128);
    BigInt(255);
    BigInt(256);
    BigInt(96);
    BigInt(100);
    BigInt(160);
    BigInt(224);
    BigInt(7922816251426434e13);
    BigInt(1461501637330903e33);
    BigInt(2695994666715064e52);
    const f5 = BigInt(0), Xn = BigInt(1), c5 = BigInt(2), d5 = BigInt(7), u5 = BigInt(256), l5 = BigInt(113), ch = [], dh = [], uh = [];
    for(let r = 0, e = Xn, t = 1, n = 0; r < 24; r++){
        [t, n] = [
            n,
            (2 * t + 3 * n) % 5
        ], ch.push(2 * (5 * n + t)), dh.push((r + 1) * (r + 2) / 2 % 64);
        let a = f5;
        for(let i = 0; i < 7; i++)e = (e << Xn ^ (e >> d5) * l5) % u5, e & c5 && (a ^= Xn << (Xn << BigInt(i)) - Xn);
        uh.push(a);
    }
    const lh = g4(uh, !0), h5 = lh[0], b5 = lh[1], P0 = (r, e, t)=>t > 32 ? m4(r, e, t) : y4(r, e, t), B0 = (r, e, t)=>t > 32 ? w4(r, e, t) : v4(r, e, t);
    function p5(r, e = 24) {
        const t = new Uint32Array(10);
        for(let n = 24 - e; n < 24; n++){
            for(let s = 0; s < 10; s++)t[s] = r[s] ^ r[s + 10] ^ r[s + 20] ^ r[s + 30] ^ r[s + 40];
            for(let s = 0; s < 10; s += 2){
                const o = (s + 8) % 10, f = (s + 2) % 10, c = t[f], h = t[f + 1], g = P0(c, h, 1) ^ t[o], v = B0(c, h, 1) ^ t[o + 1];
                for(let w = 0; w < 50; w += 10)r[s + w] ^= g, r[s + w + 1] ^= v;
            }
            let a = r[2], i = r[3];
            for(let s = 0; s < 24; s++){
                const o = dh[s], f = P0(a, i, o), c = B0(a, i, o), h = ch[s];
                a = r[h], i = r[h + 1], r[h] = f, r[h + 1] = c;
            }
            for(let s = 0; s < 50; s += 10){
                for(let o = 0; o < 10; o++)t[o] = r[s + o];
                for(let o = 0; o < 10; o++)r[s + o] ^= ~t[(o + 2) % 10] & t[(o + 4) % 10];
            }
            r[0] ^= h5[n], r[1] ^= b5[n];
        }
        $n(t);
    }
    class rc {
        state;
        pos = 0;
        posOut = 0;
        finished = !1;
        state32;
        destroyed = !1;
        blockLen;
        suffix;
        outputLen;
        enableXOF = !1;
        rounds;
        constructor(e, t, n, a = !1, i = 24){
            if (this.blockLen = e, this.suffix = t, this.outputLen = n, this.enableXOF = a, this.rounds = i, zr(n, "outputLen"), !(0 < e && e < 200)) throw new Error("only keccak-f1600 function is supported");
            this.state = new Uint8Array(200), this.state32 = s4(this.state);
        }
        clone() {
            return this._cloneInto();
        }
        keccak() {
            v0(this.state32), p5(this.state32, this.rounds), v0(this.state32), this.posOut = 0, this.pos = 0;
        }
        update(e) {
            Fn(this), Lt(e);
            const { blockLen: t, state: n } = this, a = e.length;
            for(let i = 0; i < a;){
                const s = Math.min(t - this.pos, a - i);
                for(let o = 0; o < s; o++)n[this.pos++] ^= e[i++];
                this.pos === t && this.keccak();
            }
            return this;
        }
        finish() {
            if (this.finished) return;
            this.finished = !0;
            const { state: e, suffix: t, pos: n, blockLen: a } = this;
            e[n] ^= t, (t & 128) !== 0 && n === a - 1 && this.keccak(), e[a - 1] ^= 128, this.keccak();
        }
        writeInto(e) {
            Fn(this, !1), Lt(e), this.finish();
            const t = this.state, { blockLen: n } = this;
            for(let a = 0, i = e.length; a < i;){
                this.posOut >= n && this.keccak();
                const s = Math.min(n - this.posOut, i - a);
                e.set(t.subarray(this.posOut, this.posOut + s), a), this.posOut += s, a += s;
            }
            return e;
        }
        xofInto(e) {
            if (!this.enableXOF) throw new Error("XOF is not possible for this instance");
            return this.writeInto(e);
        }
        xof(e) {
            return zr(e), this.xofInto(new Uint8Array(e));
        }
        digestInto(e) {
            if (Ll(e, this), this.finished) throw new Error("digest() was already called");
            return this.writeInto(e), this.destroy(), e;
        }
        digest() {
            return this.digestInto(new Uint8Array(this.outputLen));
        }
        destroy() {
            this.destroyed = !0, $n(this.state);
        }
        _cloneInto(e) {
            const { blockLen: t, suffix: n, outputLen: a, rounds: i, enableXOF: s } = this;
            return e ||= new rc(t, n, a, s, i), e.state32.set(this.state32), e.pos = this.pos, e.posOut = this.posOut, e.finished = this.finished, e.rounds = i, e.suffix = n, e.outputLen = a, e.enableXOF = s, e.destroyed = this.destroyed, e;
        }
    }
    const g5 = (r, e, t, n = {})=>ql(()=>new rc(e, r, t), n), y5 = g5(1, 136, 32), v5 = function(r, e = !1) {
        if (fh(r), e && r.length !== 64 && (r = ec.Point.fromBytes(r).toBytes(!1).slice(1)), r.length !== 64) throw _i("Expected pubKey to be of length 64");
        return y5(r).subarray(-20);
    }, m5 = v5, w5 = function(r) {
        return fh(r), ec.getPublicKey(r, !1).slice(1);
    }, x5 = function(r) {
        return m5(w5(r));
    }, sf = {
        mainnet: "mainnet",
        testnet: "testnet"
    }, O0 = {
        [sf.mainnet]: 0,
        [sf.testnet]: 100001
    };
    function _5(r) {
        return (r || "").substring(0, 2) === "0x";
    }
    function k0(r, e, t) {
        const a = Bn.hexToBinary(r).slice(e, t);
        return Bn.binaryToNumber(a);
    }
    function S5(r, e, t) {
        if (!O0[t]) throw new Error(`Invalid starknet network specified:- ${t}`);
        const n = Buffer.from(r, "hex");
        if (n.length !== 32) throw new Error("Invalid privKey size");
        const a = Buffer.from(x5(n)).toString("hex"), i = _5(a) ? a : `0x${a}`, s = L0.entropyToMnemonic(r), o = O0[t], f = k0(i, -31), c = k0(i, -62, -31), h = `m/2645'/1195502025'/${o}'/${f}'/${c}'/${e}`;
        return i1(s, h);
    }
    const E5 = [
        0,
        1,
        2,
        2,
        3,
        3,
        3,
        3,
        4,
        4,
        4,
        4,
        4,
        4,
        4,
        4
    ];
    function Ha(r, e) {
        if (!e || e == 10) return BigInt(r);
        if (e == 16) return r.slice(0, 2) == "0x" ? BigInt(r) : BigInt("0x" + r);
    }
    const nc = Ha;
    function A5(r, e) {
        let t = BigInt(0);
        e = BigInt(e);
        for(let n = 0; n < r.length; n++)t = t * e + BigInt(r[n]);
        return t;
    }
    function ic(r) {
        const e = r.toString(16);
        return (e.length - 1) * 4 + E5[parseInt(e[0], 16)];
    }
    function I5(r) {
        return BigInt(r) < BigInt(0);
    }
    function hh(r) {
        return !r;
    }
    function bh(r, e) {
        return BigInt(r) << BigInt(e);
    }
    function ac(r, e) {
        return BigInt(r) >> BigInt(e);
    }
    const M5 = bh, R5 = ac;
    function ph(r) {
        return (BigInt(r) & BigInt(1)) == BigInt(1);
    }
    function T5(r) {
        let e = BigInt(r);
        const t = [];
        for(; e;){
            if (e & BigInt(1)) {
                const n = 2 - Number(e % BigInt(4));
                t.push(n), e = e - BigInt(n);
            } else t.push(0);
            e = e >> BigInt(1);
        }
        return t;
    }
    function gh(r) {
        let e = BigInt(r);
        const t = [];
        for(; e;)e & BigInt(1) ? t.push(1) : t.push(0), e = e >> BigInt(1);
        return t;
    }
    function yh(r) {
        if (r > BigInt(Number.MAX_SAFE_INTEGER)) throw new Error("Number too big");
        return Number(r);
    }
    function P5(r, e) {
        const t = [];
        let n = BigInt(r);
        for(e = BigInt(e); n;)t.unshift(Number(n % e)), n = n / e;
        return t;
    }
    function B5(r, e) {
        return BigInt(r) + BigInt(e);
    }
    function jn(r, e) {
        return BigInt(r) - BigInt(e);
    }
    function O5(r) {
        return -BigInt(r);
    }
    function k5(r, e) {
        return BigInt(r) * BigInt(e);
    }
    function N5(r) {
        return BigInt(r) * BigInt(r);
    }
    function Si(r, e) {
        return BigInt(r) ** BigInt(e);
    }
    function C5(r, e) {
        return BigInt(r) ** BigInt(e);
    }
    function L5(r) {
        return BigInt(r) >= 0 ? BigInt(r) : -BigInt(r);
    }
    function Hn(r, e) {
        return BigInt(r) / BigInt(e);
    }
    function rn(r, e) {
        return BigInt(r) % BigInt(e);
    }
    function gn(r, e) {
        return BigInt(r) == BigInt(e);
    }
    function U5(r, e) {
        return BigInt(r) != BigInt(e);
    }
    function q5(r, e) {
        return BigInt(r) < BigInt(e);
    }
    function D5(r, e) {
        return BigInt(r) > BigInt(e);
    }
    function F5(r, e) {
        return BigInt(r) <= BigInt(e);
    }
    function $5(r, e) {
        return BigInt(r) >= BigInt(e);
    }
    function vh(r, e) {
        return BigInt(r) & BigInt(e);
    }
    function K5(r, e) {
        return BigInt(r) | BigInt(e);
    }
    function j5(r, e) {
        return BigInt(r) ^ BigInt(e);
    }
    function H5(r, e) {
        return BigInt(r) && BigInt(e);
    }
    function z5(r, e) {
        return BigInt(r) || BigInt(e);
    }
    function W5(r) {
        return !BigInt(r);
    }
    function sc(r, e, t, n) {
        const a = "0000000" + t.toString(16), i = new Uint32Array(r.buffer, e, n / 4), s = ((a.length - 7) * 4 - 1 >> 5) + 1;
        for(let o = 0; o < s; o++)i[o] = parseInt(a.substring(a.length - 8 * o - 8, a.length - 8 * o), 16);
        for(let o = s; o < i.length; o++)i[o] = 0;
        for(let o = i.length * 4; o < n; o++)r[o] = yh(vh(ac(t, o * 8), 255));
    }
    function mh(r, e, t, n) {
        const a = "0000000" + t.toString(16), i = new DataView(r.buffer, r.byteOffset + e, n), s = ((a.length - 7) * 4 - 1 >> 5) + 1;
        for(let o = 0; o < s; o++)i.setUint32(n - o * 4 - 4, parseInt(a.substring(a.length - 8 * o - 8, a.length - 8 * o), 16), !1);
        for(let o = 0; o < n / 4 - s; o++)i[o] = 0;
    }
    function wh(r, e, t) {
        t = t || r.byteLength, e = e || 0;
        const n = new Uint32Array(r.buffer, e, t / 4), a = new Array(t / 4);
        return n.forEach((i, s)=>a[a.length - s - 1] = i.toString(16).padStart(8, "0")), Ha(a.join(""), 16);
    }
    function xh(r, e, t) {
        t = t || r.byteLength, e = e || 0;
        const n = new DataView(r.buffer, r.byteOffset + e, t), a = new Array(t / 4);
        for(let i = 0; i < t / 4; i++)a[i] = n.getUint32(i * 4, !1).toString(16).padStart(8, "0");
        return Ha(a.join(""), 16);
    }
    function Y5(r, e) {
        return r.toString(e);
    }
    function V5(r) {
        const e = new Uint8Array(Math.floor((ic(r) - 1) / 8) + 1);
        return sc(e, 0, r, e.byteLength), e;
    }
    const G5 = nc(0), J5 = nc(1), X5 = Object.freeze(Object.defineProperty({
        __proto__: null,
        abs: L5,
        add: B5,
        band: vh,
        bitLength: ic,
        bits: gh,
        bor: K5,
        bxor: j5,
        div: Hn,
        e: nc,
        eq: gn,
        exp: C5,
        fromArray: A5,
        fromRprBE: xh,
        fromRprLE: wh,
        fromString: Ha,
        geq: $5,
        gt: D5,
        isNegative: I5,
        isOdd: ph,
        isZero: hh,
        land: H5,
        leq: F5,
        lnot: W5,
        lor: z5,
        lt: q5,
        mod: rn,
        mul: k5,
        naf: T5,
        neg: O5,
        neq: U5,
        one: J5,
        pow: Si,
        shiftLeft: bh,
        shiftRight: ac,
        shl: M5,
        shr: R5,
        square: N5,
        sub: jn,
        toArray: P5,
        toLEBuff: V5,
        toNumber: yh,
        toRprBE: mh,
        toRprLE: sc,
        toString: Y5,
        zero: G5
    }, Symbol.toStringTag, {
        value: "Module"
    }));
    class Z5 {
        constructor(e, t, n){
            this.F = t, this.G = e, this.opMulGF = n;
            let a = t.sqrt_t || t.t, i = t.sqrt_s || t.s, s = t.one;
            for(; t.eq(t.pow(s, t.half), t.one);)s = t.add(s, t.one);
            this.w = new Array(i + 1), this.wi = new Array(i + 1), this.w[i] = this.F.pow(s, a), this.wi[i] = this.F.inv(this.w[i]);
            let o = i - 1;
            for(; o >= 0;)this.w[o] = this.F.square(this.w[o + 1]), this.wi[o] = this.F.square(this.wi[o + 1]), o--;
            this.roots = [], this._setRoots(Math.min(i, 15));
        }
        _setRoots(e) {
            for(let t = e; t >= 0 && !this.roots[t]; t--){
                let n = this.F.one;
                const a = 1 << t, i = new Array(a);
                for(let s = 0; s < a; s++)i[s] = n, n = this.F.mul(n, this.w[t]);
                this.roots[t] = i;
            }
        }
        fft(e) {
            if (e.length <= 1) return e;
            const t = N0(e.length - 1) + 1;
            this._setRoots(t);
            const n = 1 << t;
            if (e.length != n) throw new Error("Size must be multiple of 2");
            return ga(this, e, t, 0, 1);
        }
        ifft(e) {
            if (e.length <= 1) return e;
            const t = N0(e.length - 1) + 1;
            this._setRoots(t);
            const n = 1 << t;
            if (e.length != n) throw new Error("Size must be multiple of 2");
            const a = ga(this, e, t, 0, 1), i = this.F.inv(this.F.mulScalar(this.F.one, n)), s = new Array(n);
            for(let o = 0; o < n; o++)s[o] = this.opMulGF(a[(n - o) % n], i);
            return s;
        }
    }
    function N0(r) {
        return ((r & 4294901760) !== 0 ? (r &= 4294901760, 16) : 0) | ((r & 4278255360) !== 0 ? (r &= 4278255360, 8) : 0) | ((r & 4042322160) !== 0 ? (r &= 4042322160, 4) : 0) | ((r & 3435973836) !== 0 ? (r &= 3435973836, 2) : 0) | (r & 2863311530) !== 0;
    }
    function ga(r, e, t, n, a) {
        const i = 1 << t;
        if (i == 1) return [
            e[n]
        ];
        if (i == 2) return [
            r.G.add(e[n], e[n + a]),
            r.G.sub(e[n], e[n + a])
        ];
        const s = i >> 1, o = ga(r, e, t - 1, n, a * 2), f = ga(r, e, t - 1, n + a, a * 2), c = new Array(i);
        for(let h = 0; h < s; h++)c[h] = r.G.add(o[h], r.opMulGF(f[h], r.roots[t][h])), c[h + s] = r.G.sub(o[h], r.opMulGF(f[h], r.roots[t][h]));
        return c;
    }
    function Q5(r) {
        if (r.m % 2 == 1) if (gn(rn(r.p, 4), 1)) if (gn(rn(r.p, 8), 1)) if (gn(rn(r.p, 16), 1)) e8(r);
        else if (gn(rn(r.p, 16), 9)) t8(r);
        else throw new Error("Field withot sqrt");
        else if (gn(rn(r.p, 8), 5)) r8(r);
        else throw new Error("Field withot sqrt");
        else gn(rn(r.p, 4), 3) && n8(r);
        else {
            const e = rn(Si(r.p, r.m / 2), 4);
            e == 1 ? i8(r) : e == 3 ? a8(r) : s8(r);
        }
    }
    function e8(r) {
        for(r.sqrt_q = Si(r.p, r.m), r.sqrt_s = 0, r.sqrt_t = jn(r.sqrt_q, 1); !ph(r.sqrt_t);)r.sqrt_s = r.sqrt_s + 1, r.sqrt_t = Hn(r.sqrt_t, 2);
        let e = r.one;
        for(; r.eq(e, r.one);){
            const t = r.random();
            r.sqrt_z = r.pow(t, r.sqrt_t), e = r.pow(r.sqrt_z, 2 ** (r.sqrt_s - 1));
        }
        r.sqrt_tm1d2 = Hn(jn(r.sqrt_t, 1), 2), r.sqrt = function(t) {
            const n = this;
            if (n.isZero(t)) return n.zero;
            let a = n.pow(t, n.sqrt_tm1d2);
            const i = n.pow(n.mul(n.square(a), t), 2 ** (n.sqrt_s - 1));
            if (n.eq(i, n.negone)) return null;
            let s = n.sqrt_s, o = n.mul(t, a), f = n.mul(o, a), c = n.sqrt_z;
            for(; !n.eq(f, n.one);){
                let h = n.square(f), g = 1;
                for(; !n.eq(h, n.one);)h = n.square(h), g++;
                a = c;
                for(let v = 0; v < s - g - 1; v++)a = n.square(a);
                c = n.square(a), f = n.mul(f, c), o = n.mul(o, a), s = g;
            }
            return n.geq(o, n.zero) ? o : n.neg(o);
        };
    }
    function t8(r) {
        r.sqrt = function() {
            throw new Error("Sqrt alg 4 not implemented");
        };
    }
    function r8(r) {
        r.sqrt = function() {
            throw new Error("Sqrt alg 3 not implemented");
        };
    }
    function n8(r) {
        r.sqrt_q = Si(r.p, r.m), r.sqrt_e1 = Hn(jn(r.sqrt_q, 3), 4), r.sqrt = function(e) {
            if (this.isZero(e)) return this.zero;
            const t = this.pow(e, this.sqrt_e1), n = this.mul(this.square(t), e);
            if (this.eq(n, this.negone)) return null;
            const a = this.mul(t, e);
            return r.geq(a, r.zero) ? a : r.neg(a);
        };
    }
    function i8(r) {
        r.sqrt = function() {
            throw new Error("Sqrt alg 10 not implemented");
        };
    }
    function a8(r) {
        r.sqrt_q = Si(r.p, r.m / 2), r.sqrt_e34 = Hn(jn(r.sqrt_q, 3), 4), r.sqrt_e12 = Hn(jn(r.sqrt_q, 1), 2), r.frobenius = function(e, t) {
            return e % 2 == 1 ? r.conjugate(t) : t;
        }, r.sqrt = function(e) {
            const t = this, n = t.pow(e, t.sqrt_e34), a = t.mul(t.square(n), e), i = t.mul(t.frobenius(1, a), a);
            if (t.eq(i, t.negone)) return null;
            const s = t.mul(n, e);
            let o;
            if (t.eq(a, t.negone)) o = t.mul(s, [
                t.F.zero,
                t.F.one
            ]);
            else {
                const f = t.pow(t.add(t.one, a), t.sqrt_e12);
                o = t.mul(f, s);
            }
            return t.geq(o, t.zero) ? o : t.neg(o);
        };
    }
    function s8(r) {
        r.sqrt = function() {
            throw new Error("Sqrt alg 8 not implemented");
        };
    }
    function C0(r, e, t) {
        if (hh(t)) return r.one;
        const n = gh(t);
        if (n.length == 0) return r.one;
        let a = e;
        for(let i = n.length - 2; i >= 0; i--)a = r.square(a), n[i] && (a = r.mul(a, e));
        return a;
    }
    function o8(r) {
        let e = new Uint8Array(r);
        if (typeof globalThis.crypto < "u") globalThis.crypto.getRandomValues(e);
        else for(let t = 0; t < r; t++)e[t] = Math.random() * 4294967296 >>> 0;
        return e;
    }
    class f8 {
        constructor(e){
            this.type = "F1", this.one = BigInt(1), this.zero = BigInt(0), this.p = BigInt(e), this.m = 1, this.negone = this.p - this.one, this.two = BigInt(2), this.half = this.p >> this.one, this.bitLength = ic(this.p), this.mask = (this.one << BigInt(this.bitLength)) - this.one, this.n64 = Math.floor((this.bitLength - 1) / 64) + 1, this.n32 = this.n64 * 2, this.n8 = this.n64 * 8, this.R = this.e(this.one << BigInt(this.n64 * 64)), this.Ri = this.inv(this.R);
            const t = this.negone >> this.one;
            this.nqr = this.two;
            let n = this.pow(this.nqr, t);
            for(; !this.eq(n, this.negone);)this.nqr = this.nqr + this.one, n = this.pow(this.nqr, t);
            for(this.s = 0, this.t = this.negone; (this.t & this.one) == this.zero;)this.s = this.s + 1, this.t = this.t >> this.one;
            this.nqr_to_t = this.pow(this.nqr, this.t), Q5(this), this.FFT = new Z5(this, this, this.mul.bind(this)), this.fft = this.FFT.fft.bind(this.FFT), this.ifft = this.FFT.ifft.bind(this.FFT), this.w = this.FFT.w, this.wi = this.FFT.wi, this.shift = this.square(this.nqr), this.k = this.exp(this.nqr, 2 ** this.s);
        }
        e(e, t) {
            let n;
            if (t ? t == 16 && (n = BigInt("0x" + e)) : n = BigInt(e), n < 0) {
                let a = -n;
                return a >= this.p && (a = a % this.p), this.p - a;
            } else return n >= this.p ? n % this.p : n;
        }
        add(e, t) {
            const n = e + t;
            return n >= this.p ? n - this.p : n;
        }
        sub(e, t) {
            return e >= t ? e - t : this.p - t + e;
        }
        neg(e) {
            return e && this.p - e;
        }
        mul(e, t) {
            return e * t % this.p;
        }
        mulScalar(e, t) {
            return e * this.e(t) % this.p;
        }
        square(e) {
            return e * e % this.p;
        }
        eq(e, t) {
            return e == t;
        }
        neq(e, t) {
            return e != t;
        }
        lt(e, t) {
            const n = e > this.half ? e - this.p : e, a = t > this.half ? t - this.p : t;
            return n < a;
        }
        gt(e, t) {
            const n = e > this.half ? e - this.p : e, a = t > this.half ? t - this.p : t;
            return n > a;
        }
        leq(e, t) {
            const n = e > this.half ? e - this.p : e, a = t > this.half ? t - this.p : t;
            return n <= a;
        }
        geq(e, t) {
            const n = e > this.half ? e - this.p : e, a = t > this.half ? t - this.p : t;
            return n >= a;
        }
        div(e, t) {
            return this.mul(e, this.inv(t));
        }
        idiv(e, t) {
            if (!t) throw new Error("Division by zero");
            return e / t;
        }
        inv(e) {
            if (!e) throw new Error("Division by zero");
            let t = this.zero, n = this.p, a = this.one, i = e % this.p;
            for(; i;){
                let s = n / i;
                [t, a] = [
                    a,
                    t - s * a
                ], [n, i] = [
                    i,
                    n - s * i
                ];
            }
            return t < this.zero && (t += this.p), t;
        }
        mod(e, t) {
            return e % t;
        }
        pow(e, t) {
            return C0(this, e, t);
        }
        exp(e, t) {
            return C0(this, e, t);
        }
        band(e, t) {
            const n = e & t & this.mask;
            return n >= this.p ? n - this.p : n;
        }
        bor(e, t) {
            const n = (e | t) & this.mask;
            return n >= this.p ? n - this.p : n;
        }
        bxor(e, t) {
            const n = (e ^ t) & this.mask;
            return n >= this.p ? n - this.p : n;
        }
        bnot(e) {
            const t = e ^ this.mask;
            return t >= this.p ? t - this.p : t;
        }
        shl(e, t) {
            if (Number(t) < this.bitLength) {
                const n = e << t & this.mask;
                return n >= this.p ? n - this.p : n;
            } else {
                const n = this.p - t;
                return Number(n) < this.bitLength ? e >> n : this.zero;
            }
        }
        shr(e, t) {
            if (Number(t) < this.bitLength) return e >> t;
            {
                const n = this.p - t;
                if (Number(n) < this.bitLength) {
                    const a = e << n & this.mask;
                    return a >= this.p ? a - this.p : a;
                } else return 0;
            }
        }
        land(e, t) {
            return e && t ? this.one : this.zero;
        }
        lor(e, t) {
            return e || t ? this.one : this.zero;
        }
        lnot(e) {
            return e ? this.zero : this.one;
        }
        sqrt_old(e) {
            if (e == this.zero) return this.zero;
            if (this.pow(e, this.negone >> this.one) != this.one) return null;
            let n = this.s, a = this.nqr_to_t, i = this.pow(e, this.t), s = this.pow(e, this.add(this.t, this.one) >> this.one);
            for(; i != this.one;){
                let o = this.square(i), f = 1;
                for(; o != this.one;)f++, o = this.square(o);
                let c = a;
                for(let h = 0; h < n - f - 1; h++)c = this.square(c);
                n = f, a = this.square(c), i = this.mul(i, a), s = this.mul(s, c);
            }
            return s > this.p >> this.one && (s = this.neg(s)), s;
        }
        normalize(e, t) {
            if (e = BigInt(e, t), e < 0) {
                let n = -e;
                return n >= this.p && (n = n % this.p), this.p - n;
            } else return e >= this.p ? e % this.p : e;
        }
        random() {
            const e = this.bitLength * 2 / 8;
            let t = this.zero;
            for(let n = 0; n < e; n++)t = (t << BigInt(8)) + BigInt(o8(1)[0]);
            return t % this.p;
        }
        toString(e, t) {
            t = t || 10;
            let n;
            return e > this.half && t == 10 ? n = "-" + (this.p - e).toString(t) : n = e.toString(t), n;
        }
        isZero(e) {
            return e == this.zero;
        }
        fromRng(e) {
            let t;
            do {
                t = this.zero;
                for(let n = 0; n < this.n64; n++)t += e.nextU64() << BigInt(64 * n);
                t &= this.mask;
            }while (t >= this.p);
            return t = t * this.Ri % this.p, t;
        }
        fft(e) {
            return this.FFT.fft(e);
        }
        ifft(e) {
            return this.FFT.ifft(e);
        }
        toRprLE(e, t, n) {
            sc(e, t, n, this.n64 * 8);
        }
        toRprBE(e, t, n) {
            mh(e, t, n, this.n64 * 8);
        }
        toRprBEM(e, t, n) {
            return this.toRprBE(e, t, this.mul(this.R, n));
        }
        toRprLEM(e, t, n) {
            return this.toRprLE(e, t, this.mul(this.R, n));
        }
        fromRprLE(e, t) {
            return wh(e, t, this.n8);
        }
        fromRprBE(e, t) {
            return xh(e, t, this.n8);
        }
        fromRprLEM(e, t) {
            return this.mul(this.fromRprLE(e, t), this.Ri);
        }
        fromRprBEM(e, t) {
            return this.mul(this.fromRprBE(e, t), this.Ri);
        }
        toObject(e) {
            return e;
        }
    }
    const _h = X5, kt = new f8(_h.fromString("21888242871839275222246405745257275088548364400416034343698204186575808495617")), oc = "mimcsponge", ya = 220;
    function of(r) {
        let e = Buffer.from(r, "utf8");
        return typeof r == "string" && r.slice(0, 2) === "0x" && r.length === 66 && (e = Buffer.from(r.slice(2), "hex")), `0x${Br(e).toString("hex").padStart(64, "0")}`;
    }
    function c8(r) {
        let e = r;
        typeof e > "u" && (e = oc);
        const t = of(`${e}_iv`);
        return _h.fromString(new Fe(t, 16).toString()).mod(kt.p);
    }
    function Sh(r, e) {
        let t = e;
        typeof e > "u" && (t = ya);
        const n = new Array(t);
        let a = of(oc);
        for(let i = 1; i < t; i += 1){
            a = of(a);
            const o = new Fe(a.slice(2), 16).mod(new Fe(kt.p.toString())).toString(16, 64);
            n[i] = kt.e(new Fe(o, 16).toString());
        }
        return n[0] = kt.e(0), n[n.length - 1] = kt.e(0), n;
    }
    const d8 = Sh(oc, ya);
    function va(r, e, t) {
        let n = kt.e(r), a = kt.e(e);
        const i = kt.e(t);
        for(let s = 0; s < ya; s += 1){
            const o = d8[s], f = s === 0 ? kt.add(n, i) : kt.add(kt.add(n, i), o), c = kt.e(a);
            s < ya - 1 ? (a = n, n = kt.add(c, kt.pow(f, 5))) : a = kt.add(c, kt.pow(f, 5));
        }
        return {
            xL: kt.normalize(n),
            xR: kt.normalize(a)
        };
    }
    function u8(r, e, t) {
        let n = e, a = t;
        typeof a > "u" && (a = 1), typeof n > "u" && (n = kt.zero);
        let i = kt.zero, s = kt.zero;
        for(let f = 0; f < r.length; f += 1){
            i = kt.add(i, kt.e(r[f]));
            const c = va(i, s, n);
            i = c.xL, s = c.xR;
        }
        const o = [
            i
        ];
        for(let f = 1; f < a; f += 1){
            const c = va(i, s, n);
            i = c.xL, s = c.xR, o.push(i);
        }
        return a === 1 ? kt.normalize(o[0]) : o.map((f)=>kt.normalize(f));
    }
    const Eh = "fffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141";
    function l8(r, e) {
        const t = new Fe(r, "hex").toString(10), n = new Fe(e).umod(new Fe(Eh, "hex")).toString(10);
        return va(1, t, n).xL.toString(16);
    }
    function ff(r, e = 3, t = 50, n = "black", a = 0, i = 20, s = "#0346ff") {
        const o = [];
        let f;
        for(f = 0; f < e; f += 1)o.push(r(s).rotate((f + 1) / e * -a).saturate((f + 1) / e * (i / 100)).mix(r(n), t / 100 * (f + 1) / e).hex());
        return o;
    }
    function Ah(r, e) {
        const t = ff(r, 3, 50, "black", 0, 20, e), n = ff(r, 6, 85, "white", 0, 20, e);
        return [
            ...t.reverse(),
            e,
            ...n
        ];
    }
    function h8(r, e, t) {
        if (t.primary) {
            const n = Ah(r, t.primary);
            e.style.setProperty("--app-primary-900", n[0]), e.style.setProperty("--app-primary-800", n[1]), e.style.setProperty("--app-primary-700", n[2]), e.style.setProperty("--app-primary-600", n[3]), e.style.setProperty("--app-primary-500", n[4]), e.style.setProperty("--app-primary-400", n[5]), e.style.setProperty("--app-primary-300", n[6]), e.style.setProperty("--app-primary-200", n[7]), e.style.setProperty("--app-primary-100", n[8]), e.style.setProperty("--app-primary-50", n[9]);
        }
        t.onPrimary && e.style.setProperty("--app-on-primary", t.onPrimary);
    }
    S8 = Object.freeze(Object.defineProperty({
        __proto__: null,
        AUTH_ACTIONS: pn,
        AUTH_CONNECTION: ot,
        AUTH_DASHBOARD_DEVELOPMENT_URL: Ju,
        AUTH_DASHBOARD_PRODUCTION_URL: Qu,
        AUTH_DASHBOARD_STAGING_URL: Xu,
        AUTH_DASHBOARD_TESTING_URL: Zu,
        AUTH_SERVICE_DEVELOPMENT_URL: Wu,
        AUTH_SERVICE_PRODUCTION_URL: Gu,
        AUTH_SERVICE_STAGING_URL: Yu,
        AUTH_SERVICE_TESTING_URL: Vu,
        Auth: y3,
        AuthError: kf,
        BUILD_ENV: tn,
        BasePostMessageStream: El,
        BrowserStorage: Df,
        CustomAuth: i6,
        EMAIL_FLOW: Tu,
        EthereumProviderError: zf,
        IFRAME_MODAL_ID: Ko,
        IGNORE_SUBSTREAM: tf,
        InitializationError: Pr,
        JRPCEngine: _r,
        JRPC_METHODS: Fr,
        JSON_RPC_SERVER_ERROR_MESSAGE: Ml,
        JsonRpcError: Fa,
        LANGUAGES: f6,
        LANGUAGE_MAP: c6,
        LoginError: At,
        MFA_FACTOR: d6,
        MFA_LEVELS: o6,
        MemoryStore: gl,
        ObjectMultiplex: Nl,
        POPUP_TIMEOUT: el,
        PopupHandler: Ba,
        PostMessageStream: T3,
        REDIRECT_PARAMS_STORAGE_METHOD: Qn,
        SDK_MODE: Mr,
        SECP256K1_CURVE_N: Eh,
        SENTRY_TXNS: Lo,
        STARKNET_NETWORKS: sf,
        SUPPORTED_KEY_CURVES: s6,
        SafeEventEmitter: Da,
        SerializableError: sn,
        StorageHelper: ju,
        Substream: Al,
        THEME_MODES: la,
        UX_MODE: Zt,
        WEB3AUTH_LEGACY_NETWORK: Hu,
        WEB3AUTH_NETWORK: Ji,
        WEB3AUTH_SAPPHIRE_NETWORK: zu,
        applyWhiteLabelTheme: h8,
        base64toJSON: l6,
        base64url: mi,
        broadcastChannelOptions: mu,
        cloneDeep: h6,
        constructURL: Nn,
        createAsyncMiddleware: W3,
        createEngineStream: V3,
        createErrorMiddleware: $3,
        createHandler: Pu,
        createIdRemapMiddleware: H3,
        createLoggerMiddleware: z3,
        createScaffoldMiddleware: j3,
        createStreamMiddleware: K3,
        dataHasCause: Pl,
        decodeToken: Pa,
        errorCodes: zt,
        errorValues: Xo,
        eventToPromise: C1,
        generateWhiteLabelTheme: Ah,
        getColorsList: ff,
        getED25519Key: _3,
        getHashQueryParams: pl,
        getMessageFromCode: Yn,
        getPopupFeatures: xf,
        getRpcPromiseCallback: F3,
        getStarkHDAccount: S5,
        getTimeout: Ta,
        getUserId: hi,
        handleRedirectParameters: Do,
        htmlToElement: tl,
        isFirefox: wu,
        isMobileOrTablet: _u,
        isObject: pi,
        isPlainObject: Rl,
        isValidCode: jf,
        isValidString: Zo,
        jsonToBase64: ri,
        log: Nr,
        loginToConnectionMap: mf,
        mergeMiddleware: Y3,
        mimcGetConstants: Sh,
        mimcHash: va,
        mimcMultiHash: u8,
        mimgGetIV: c8,
        objectToAuthDataMap: xu,
        padUrlString: Ma,
        providerAsMiddleware: J3,
        providerErrors: D3,
        providerFromEngine: Ol,
        providerFromMiddleware: G3,
        randomId: wf,
        rpcErrors: q3,
        safeatob: jo,
        safebtoa: u6,
        serializeCause: Hf,
        serializeError: Ku,
        serializeJrpcError: ha,
        setupMultiplex: a4,
        starkEc: a1,
        starkGrindKey: s1,
        starkPedersen: o1,
        starkSign: f1,
        starkVerify: c1,
        storageAvailable: oa,
        storeKey: a6,
        subkey: l8,
        validateAndConstructUrl: Ra,
        version: Jo
    }, Symbol.toStringTag, {
        value: "Module"
    }));
});
export { he as _, ea as a, Be as b, If as d, si as e, Sr as g, S8 as i, Br as k, vr as l, ai as s, __tla };
