"use client";
import { r as Li, a as qt } from "./index-Ln4l6pgx.js";
import { m as Hi } from "./index.package-D9CcaDDw.js";
var Dt = { exports: {} }, zi = Dt.exports, Ei;
function Vi() {
  return Ei || (Ei = 1, function(T) {
    (function(L, A) {
      function v(a, t) {
        if (!a) throw new Error(t || "Assertion failed");
      }
      function k(a, t) {
        a.super_ = t;
        var r = function() {
        };
        r.prototype = t.prototype, a.prototype = new r(), a.prototype.constructor = a;
      }
      function o(a, t, r) {
        if (o.isBN(a))
          return a;
        this.negative = 0, this.words = null, this.length = 0, this.red = null, a !== null && ((t === "le" || t === "be") && (r = t, t = 10), this._init(a || 0, t || 10, r || "be"));
      }
      typeof L == "object" ? L.exports = o : A.BN = o, o.BN = o, o.wordSize = 26;
      var x;
      try {
        typeof window < "u" && typeof window.Buffer < "u" ? x = window.Buffer : x = Li().Buffer;
      } catch {
      }
      o.isBN = function(t) {
        return t instanceof o ? !0 : t !== null && typeof t == "object" && t.constructor.wordSize === o.wordSize && Array.isArray(t.words);
      }, o.max = function(t, r) {
        return t.cmp(r) > 0 ? t : r;
      }, o.min = function(t, r) {
        return t.cmp(r) < 0 ? t : r;
      }, o.prototype._init = function(t, r, e) {
        if (typeof t == "number")
          return this._initNumber(t, r, e);
        if (typeof t == "object")
          return this._initArray(t, r, e);
        r === "hex" && (r = 16), v(r === (r | 0) && r >= 2 && r <= 36), t = t.toString().replace(/\s+/g, "");
        var h = 0;
        t[0] === "-" && (h++, this.negative = 1), h < t.length && (r === 16 ? this._parseHex(t, h, e) : (this._parseBase(t, r, h), e === "le" && this._initArray(this.toArray(), r, e)));
      }, o.prototype._initNumber = function(t, r, e) {
        t < 0 && (this.negative = 1, t = -t), t < 67108864 ? (this.words = [t & 67108863], this.length = 1) : t < 4503599627370496 ? (this.words = [
          t & 67108863,
          t / 67108864 & 67108863
        ], this.length = 2) : (v(t < 9007199254740992), this.words = [
          t & 67108863,
          t / 67108864 & 67108863,
          1
        ], this.length = 3), e === "le" && this._initArray(this.toArray(), r, e);
      }, o.prototype._initArray = function(t, r, e) {
        if (v(typeof t.length == "number"), t.length <= 0)
          return this.words = [0], this.length = 1, this;
        this.length = Math.ceil(t.length / 3), this.words = new Array(this.length);
        for (var h = 0; h < this.length; h++)
          this.words[h] = 0;
        var f, l, u = 0;
        if (e === "be")
          for (h = t.length - 1, f = 0; h >= 0; h -= 3)
            l = t[h] | t[h - 1] << 8 | t[h - 2] << 16, this.words[f] |= l << u & 67108863, this.words[f + 1] = l >>> 26 - u & 67108863, u += 24, u >= 26 && (u -= 26, f++);
        else if (e === "le")
          for (h = 0, f = 0; h < t.length; h += 3)
            l = t[h] | t[h + 1] << 8 | t[h + 2] << 16, this.words[f] |= l << u & 67108863, this.words[f + 1] = l >>> 26 - u & 67108863, u += 24, u >= 26 && (u -= 26, f++);
        return this._strip();
      };
      function C(a, t) {
        var r = a.charCodeAt(t);
        if (r >= 48 && r <= 57)
          return r - 48;
        if (r >= 65 && r <= 70)
          return r - 55;
        if (r >= 97 && r <= 102)
          return r - 87;
        v(!1, "Invalid character in " + a);
      }
      function D(a, t, r) {
        var e = C(a, r);
        return r - 1 >= t && (e |= C(a, r - 1) << 4), e;
      }
      o.prototype._parseHex = function(t, r, e) {
        this.length = Math.ceil((t.length - r) / 6), this.words = new Array(this.length);
        for (var h = 0; h < this.length; h++)
          this.words[h] = 0;
        var f = 0, l = 0, u;
        if (e === "be")
          for (h = t.length - 1; h >= r; h -= 2)
            u = D(t, r, h) << f, this.words[l] |= u & 67108863, f >= 18 ? (f -= 18, l += 1, this.words[l] |= u >>> 26) : f += 8;
        else {
          var s = t.length - r;
          for (h = s % 2 === 0 ? r + 1 : r; h < t.length; h += 2)
            u = D(t, r, h) << f, this.words[l] |= u & 67108863, f >= 18 ? (f -= 18, l += 1, this.words[l] |= u >>> 26) : f += 8;
        }
        this._strip();
      };
      function E(a, t, r, e) {
        for (var h = 0, f = 0, l = Math.min(a.length, r), u = t; u < l; u++) {
          var s = a.charCodeAt(u) - 48;
          h *= e, s >= 49 ? f = s - 49 + 10 : s >= 17 ? f = s - 17 + 10 : f = s, v(s >= 0 && f < e, "Invalid character"), h += f;
        }
        return h;
      }
      o.prototype._parseBase = function(t, r, e) {
        this.words = [0], this.length = 1;
        for (var h = 0, f = 1; f <= 67108863; f *= r)
          h++;
        h--, f = f / r | 0;
        for (var l = t.length - e, u = l % h, s = Math.min(l, l - u) + e, i = 0, n = e; n < s; n += h)
          i = E(t, n, n + h, r), this.imuln(f), this.words[0] + i < 67108864 ? this.words[0] += i : this._iaddn(i);
        if (u !== 0) {
          var y = 1;
          for (i = E(t, n, t.length, r), n = 0; n < u; n++)
            y *= r;
          this.imuln(y), this.words[0] + i < 67108864 ? this.words[0] += i : this._iaddn(i);
        }
        this._strip();
      }, o.prototype.copy = function(t) {
        t.words = new Array(this.length);
        for (var r = 0; r < this.length; r++)
          t.words[r] = this.words[r];
        t.length = this.length, t.negative = this.negative, t.red = this.red;
      };
      function M(a, t) {
        a.words = t.words, a.length = t.length, a.negative = t.negative, a.red = t.red;
      }
      if (o.prototype._move = function(t) {
        M(t, this);
      }, o.prototype.clone = function() {
        var t = new o(null);
        return this.copy(t), t;
      }, o.prototype._expand = function(t) {
        for (; this.length < t; )
          this.words[this.length++] = 0;
        return this;
      }, o.prototype._strip = function() {
        for (; this.length > 1 && this.words[this.length - 1] === 0; )
          this.length--;
        return this._normSign();
      }, o.prototype._normSign = function() {
        return this.length === 1 && this.words[0] === 0 && (this.negative = 0), this;
      }, typeof Symbol < "u" && typeof Symbol.for == "function")
        try {
          o.prototype[Symbol.for("nodejs.util.inspect.custom")] = S;
        } catch {
          o.prototype.inspect = S;
        }
      else
        o.prototype.inspect = S;
      function S() {
        return (this.red ? "<BN-R: " : "<BN: ") + this.toString(16) + ">";
      }
      var m = [
        "",
        "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"
      ], I = [
        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
      ], B = [
        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
      ];
      o.prototype.toString = function(t, r) {
        t = t || 10, r = r | 0 || 1;
        var e;
        if (t === 16 || t === "hex") {
          e = "";
          for (var h = 0, f = 0, l = 0; l < this.length; l++) {
            var u = this.words[l], s = ((u << h | f) & 16777215).toString(16);
            f = u >>> 24 - h & 16777215, h += 2, h >= 26 && (h -= 26, l--), f !== 0 || l !== this.length - 1 ? e = m[6 - s.length] + s + e : e = s + e;
          }
          for (f !== 0 && (e = f.toString(16) + e); e.length % r !== 0; )
            e = "0" + e;
          return this.negative !== 0 && (e = "-" + e), e;
        }
        if (t === (t | 0) && t >= 2 && t <= 36) {
          var i = I[t], n = B[t];
          e = "";
          var y = this.clone();
          for (y.negative = 0; !y.isZero(); ) {
            var _ = y.modrn(n).toString(t);
            y = y.idivn(n), y.isZero() ? e = _ + e : e = m[i - _.length] + _ + e;
          }
          for (this.isZero() && (e = "0" + e); e.length % r !== 0; )
            e = "0" + e;
          return this.negative !== 0 && (e = "-" + e), e;
        }
        v(!1, "Base should be between 2 and 36");
      }, o.prototype.toNumber = function() {
        var t = this.words[0];
        return this.length === 2 ? t += this.words[1] * 67108864 : this.length === 3 && this.words[2] === 1 ? t += 4503599627370496 + this.words[1] * 67108864 : this.length > 2 && v(!1, "Number can only safely store up to 53 bits"), this.negative !== 0 ? -t : t;
      }, o.prototype.toJSON = function() {
        return this.toString(16, 2);
      }, x && (o.prototype.toBuffer = function(t, r) {
        return this.toArrayLike(x, t, r);
      }), o.prototype.toArray = function(t, r) {
        return this.toArrayLike(Array, t, r);
      };
      var g = function(t, r) {
        return t.allocUnsafe ? t.allocUnsafe(r) : new t(r);
      };
      o.prototype.toArrayLike = function(t, r, e) {
        this._strip();
        var h = this.byteLength(), f = e || Math.max(1, h);
        v(h <= f, "byte array longer than desired length"), v(f > 0, "Requested array length <= 0");
        var l = g(t, f), u = r === "le" ? "LE" : "BE";
        return this["_toArrayLike" + u](l, h), l;
      }, o.prototype._toArrayLikeLE = function(t, r) {
        for (var e = 0, h = 0, f = 0, l = 0; f < this.length; f++) {
          var u = this.words[f] << l | h;
          t[e++] = u & 255, e < t.length && (t[e++] = u >> 8 & 255), e < t.length && (t[e++] = u >> 16 & 255), l === 6 ? (e < t.length && (t[e++] = u >> 24 & 255), h = 0, l = 0) : (h = u >>> 24, l += 2);
        }
        if (e < t.length)
          for (t[e++] = h; e < t.length; )
            t[e++] = 0;
      }, o.prototype._toArrayLikeBE = function(t, r) {
        for (var e = t.length - 1, h = 0, f = 0, l = 0; f < this.length; f++) {
          var u = this.words[f] << l | h;
          t[e--] = u & 255, e >= 0 && (t[e--] = u >> 8 & 255), e >= 0 && (t[e--] = u >> 16 & 255), l === 6 ? (e >= 0 && (t[e--] = u >> 24 & 255), h = 0, l = 0) : (h = u >>> 24, l += 2);
        }
        if (e >= 0)
          for (t[e--] = h; e >= 0; )
            t[e--] = 0;
      }, Math.clz32 ? o.prototype._countBits = function(t) {
        return 32 - Math.clz32(t);
      } : o.prototype._countBits = function(t) {
        var r = t, e = 0;
        return r >= 4096 && (e += 13, r >>>= 13), r >= 64 && (e += 7, r >>>= 7), r >= 8 && (e += 4, r >>>= 4), r >= 2 && (e += 2, r >>>= 2), e + r;
      }, o.prototype._zeroBits = function(t) {
        if (t === 0) return 26;
        var r = t, e = 0;
        return (r & 8191) === 0 && (e += 13, r >>>= 13), (r & 127) === 0 && (e += 7, r >>>= 7), (r & 15) === 0 && (e += 4, r >>>= 4), (r & 3) === 0 && (e += 2, r >>>= 2), (r & 1) === 0 && e++, e;
      }, o.prototype.bitLength = function() {
        var t = this.words[this.length - 1], r = this._countBits(t);
        return (this.length - 1) * 26 + r;
      };
      function c(a) {
        for (var t = new Array(a.bitLength()), r = 0; r < t.length; r++) {
          var e = r / 26 | 0, h = r % 26;
          t[r] = a.words[e] >>> h & 1;
        }
        return t;
      }
      o.prototype.zeroBits = function() {
        if (this.isZero()) return 0;
        for (var t = 0, r = 0; r < this.length; r++) {
          var e = this._zeroBits(this.words[r]);
          if (t += e, e !== 26) break;
        }
        return t;
      }, o.prototype.byteLength = function() {
        return Math.ceil(this.bitLength() / 8);
      }, o.prototype.toTwos = function(t) {
        return this.negative !== 0 ? this.abs().inotn(t).iaddn(1) : this.clone();
      }, o.prototype.fromTwos = function(t) {
        return this.testn(t - 1) ? this.notn(t).iaddn(1).ineg() : this.clone();
      }, o.prototype.isNeg = function() {
        return this.negative !== 0;
      }, o.prototype.neg = function() {
        return this.clone().ineg();
      }, o.prototype.ineg = function() {
        return this.isZero() || (this.negative ^= 1), this;
      }, o.prototype.iuor = function(t) {
        for (; this.length < t.length; )
          this.words[this.length++] = 0;
        for (var r = 0; r < t.length; r++)
          this.words[r] = this.words[r] | t.words[r];
        return this._strip();
      }, o.prototype.ior = function(t) {
        return v((this.negative | t.negative) === 0), this.iuor(t);
      }, o.prototype.or = function(t) {
        return this.length > t.length ? this.clone().ior(t) : t.clone().ior(this);
      }, o.prototype.uor = function(t) {
        return this.length > t.length ? this.clone().iuor(t) : t.clone().iuor(this);
      }, o.prototype.iuand = function(t) {
        var r;
        this.length > t.length ? r = t : r = this;
        for (var e = 0; e < r.length; e++)
          this.words[e] = this.words[e] & t.words[e];
        return this.length = r.length, this._strip();
      }, o.prototype.iand = function(t) {
        return v((this.negative | t.negative) === 0), this.iuand(t);
      }, o.prototype.and = function(t) {
        return this.length > t.length ? this.clone().iand(t) : t.clone().iand(this);
      }, o.prototype.uand = function(t) {
        return this.length > t.length ? this.clone().iuand(t) : t.clone().iuand(this);
      }, o.prototype.iuxor = function(t) {
        var r, e;
        this.length > t.length ? (r = this, e = t) : (r = t, e = this);
        for (var h = 0; h < e.length; h++)
          this.words[h] = r.words[h] ^ e.words[h];
        if (this !== r)
          for (; h < r.length; h++)
            this.words[h] = r.words[h];
        return this.length = r.length, this._strip();
      }, o.prototype.ixor = function(t) {
        return v((this.negative | t.negative) === 0), this.iuxor(t);
      }, o.prototype.xor = function(t) {
        return this.length > t.length ? this.clone().ixor(t) : t.clone().ixor(this);
      }, o.prototype.uxor = function(t) {
        return this.length > t.length ? this.clone().iuxor(t) : t.clone().iuxor(this);
      }, o.prototype.inotn = function(t) {
        v(typeof t == "number" && t >= 0);
        var r = Math.ceil(t / 26) | 0, e = t % 26;
        this._expand(r), e > 0 && r--;
        for (var h = 0; h < r; h++)
          this.words[h] = ~this.words[h] & 67108863;
        return e > 0 && (this.words[h] = ~this.words[h] & 67108863 >> 26 - e), this._strip();
      }, o.prototype.notn = function(t) {
        return this.clone().inotn(t);
      }, o.prototype.setn = function(t, r) {
        v(typeof t == "number" && t >= 0);
        var e = t / 26 | 0, h = t % 26;
        return this._expand(e + 1), r ? this.words[e] = this.words[e] | 1 << h : this.words[e] = this.words[e] & ~(1 << h), this._strip();
      }, o.prototype.iadd = function(t) {
        var r;
        if (this.negative !== 0 && t.negative === 0)
          return this.negative = 0, r = this.isub(t), this.negative ^= 1, this._normSign();
        if (this.negative === 0 && t.negative !== 0)
          return t.negative = 0, r = this.isub(t), t.negative = 1, r._normSign();
        var e, h;
        this.length > t.length ? (e = this, h = t) : (e = t, h = this);
        for (var f = 0, l = 0; l < h.length; l++)
          r = (e.words[l] | 0) + (h.words[l] | 0) + f, this.words[l] = r & 67108863, f = r >>> 26;
        for (; f !== 0 && l < e.length; l++)
          r = (e.words[l] | 0) + f, this.words[l] = r & 67108863, f = r >>> 26;
        if (this.length = e.length, f !== 0)
          this.words[this.length] = f, this.length++;
        else if (e !== this)
          for (; l < e.length; l++)
            this.words[l] = e.words[l];
        return this;
      }, o.prototype.add = function(t) {
        var r;
        return t.negative !== 0 && this.negative === 0 ? (t.negative = 0, r = this.sub(t), t.negative ^= 1, r) : t.negative === 0 && this.negative !== 0 ? (this.negative = 0, r = t.sub(this), this.negative = 1, r) : this.length > t.length ? this.clone().iadd(t) : t.clone().iadd(this);
      }, o.prototype.isub = function(t) {
        if (t.negative !== 0) {
          t.negative = 0;
          var r = this.iadd(t);
          return t.negative = 1, r._normSign();
        } else if (this.negative !== 0)
          return this.negative = 0, this.iadd(t), this.negative = 1, this._normSign();
        var e = this.cmp(t);
        if (e === 0)
          return this.negative = 0, this.length = 1, this.words[0] = 0, this;
        var h, f;
        e > 0 ? (h = this, f = t) : (h = t, f = this);
        for (var l = 0, u = 0; u < f.length; u++)
          r = (h.words[u] | 0) - (f.words[u] | 0) + l, l = r >> 26, this.words[u] = r & 67108863;
        for (; l !== 0 && u < h.length; u++)
          r = (h.words[u] | 0) + l, l = r >> 26, this.words[u] = r & 67108863;
        if (l === 0 && u < h.length && h !== this)
          for (; u < h.length; u++)
            this.words[u] = h.words[u];
        return this.length = Math.max(this.length, u), h !== this && (this.negative = 1), this._strip();
      }, o.prototype.sub = function(t) {
        return this.clone().isub(t);
      };
      function d(a, t, r) {
        r.negative = t.negative ^ a.negative;
        var e = a.length + t.length | 0;
        r.length = e, e = e - 1 | 0;
        var h = a.words[0] | 0, f = t.words[0] | 0, l = h * f, u = l & 67108863, s = l / 67108864 | 0;
        r.words[0] = u;
        for (var i = 1; i < e; i++) {
          for (var n = s >>> 26, y = s & 67108863, _ = Math.min(i, t.length - 1), b = Math.max(0, i - a.length + 1); b <= _; b++) {
            var yt = i - b | 0;
            h = a.words[yt] | 0, f = t.words[b] | 0, l = h * f + y, n += l / 67108864 | 0, y = l & 67108863;
          }
          r.words[i] = y | 0, s = n | 0;
        }
        return s !== 0 ? r.words[i] = s | 0 : r.length--, r._strip();
      }
      var p = function(t, r, e) {
        var h = t.words, f = r.words, l = e.words, u = 0, s, i, n, y = h[0] | 0, _ = y & 8191, b = y >>> 13, yt = h[1] | 0, N = yt & 8191, F = yt >>> 13, Nt = h[2] | 0, G = Nt & 8191, $ = Nt >>> 13, Rt = h[3] | 0, U = Rt & 8191, J = Rt >>> 13, Ft = h[4] | 0, Q = Ft & 8191, O = Ft >>> 13, Tt = h[5] | 0, K = Tt & 8191, q = Tt >>> 13, St = h[6] | 0, P = St & 8191, V = St >>> 13, di = h[7] | 0, X = di & 8191, Y = di >>> 13, vi = h[8] | 0, W = vi & 8191, j = vi >>> 13, ci = h[9] | 0, tt = ci & 8191, it = ci >>> 13, pi = f[0] | 0, rt = pi & 8191, et = pi >>> 13, mi = f[1] | 0, ht = mi & 8191, st = mi >>> 13, gi = f[2] | 0, nt = gi & 8191, ft = gi >>> 13, xi = f[3] | 0, at = xi & 8191, ot = xi >>> 13, Mi = f[4] | 0, lt = Mi & 8191, ut = Mi >>> 13, wi = f[5] | 0, dt = wi & 8191, vt = wi >>> 13, _i = f[6] | 0, ct = _i & 8191, pt = _i >>> 13, yi = f[7] | 0, mt = yi & 8191, gt = yi >>> 13, bi = f[8] | 0, xt = bi & 8191, Mt = bi >>> 13, Bi = f[9] | 0, wt = Bi & 8191, _t = Bi >>> 13;
        e.negative = t.negative ^ r.negative, e.length = 19, s = Math.imul(_, rt), i = Math.imul(_, et), i = i + Math.imul(b, rt) | 0, n = Math.imul(b, et);
        var Zt = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Zt >>> 26) | 0, Zt &= 67108863, s = Math.imul(N, rt), i = Math.imul(N, et), i = i + Math.imul(F, rt) | 0, n = Math.imul(F, et), s = s + Math.imul(_, ht) | 0, i = i + Math.imul(_, st) | 0, i = i + Math.imul(b, ht) | 0, n = n + Math.imul(b, st) | 0;
        var Ht = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Ht >>> 26) | 0, Ht &= 67108863, s = Math.imul(G, rt), i = Math.imul(G, et), i = i + Math.imul($, rt) | 0, n = Math.imul($, et), s = s + Math.imul(N, ht) | 0, i = i + Math.imul(N, st) | 0, i = i + Math.imul(F, ht) | 0, n = n + Math.imul(F, st) | 0, s = s + Math.imul(_, nt) | 0, i = i + Math.imul(_, ft) | 0, i = i + Math.imul(b, nt) | 0, n = n + Math.imul(b, ft) | 0;
        var zt = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (zt >>> 26) | 0, zt &= 67108863, s = Math.imul(U, rt), i = Math.imul(U, et), i = i + Math.imul(J, rt) | 0, n = Math.imul(J, et), s = s + Math.imul(G, ht) | 0, i = i + Math.imul(G, st) | 0, i = i + Math.imul($, ht) | 0, n = n + Math.imul($, st) | 0, s = s + Math.imul(N, nt) | 0, i = i + Math.imul(N, ft) | 0, i = i + Math.imul(F, nt) | 0, n = n + Math.imul(F, ft) | 0, s = s + Math.imul(_, at) | 0, i = i + Math.imul(_, ot) | 0, i = i + Math.imul(b, at) | 0, n = n + Math.imul(b, ot) | 0;
        var Ut = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Ut >>> 26) | 0, Ut &= 67108863, s = Math.imul(Q, rt), i = Math.imul(Q, et), i = i + Math.imul(O, rt) | 0, n = Math.imul(O, et), s = s + Math.imul(U, ht) | 0, i = i + Math.imul(U, st) | 0, i = i + Math.imul(J, ht) | 0, n = n + Math.imul(J, st) | 0, s = s + Math.imul(G, nt) | 0, i = i + Math.imul(G, ft) | 0, i = i + Math.imul($, nt) | 0, n = n + Math.imul($, ft) | 0, s = s + Math.imul(N, at) | 0, i = i + Math.imul(N, ot) | 0, i = i + Math.imul(F, at) | 0, n = n + Math.imul(F, ot) | 0, s = s + Math.imul(_, lt) | 0, i = i + Math.imul(_, ut) | 0, i = i + Math.imul(b, lt) | 0, n = n + Math.imul(b, ut) | 0;
        var Ot = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Ot >>> 26) | 0, Ot &= 67108863, s = Math.imul(K, rt), i = Math.imul(K, et), i = i + Math.imul(q, rt) | 0, n = Math.imul(q, et), s = s + Math.imul(Q, ht) | 0, i = i + Math.imul(Q, st) | 0, i = i + Math.imul(O, ht) | 0, n = n + Math.imul(O, st) | 0, s = s + Math.imul(U, nt) | 0, i = i + Math.imul(U, ft) | 0, i = i + Math.imul(J, nt) | 0, n = n + Math.imul(J, ft) | 0, s = s + Math.imul(G, at) | 0, i = i + Math.imul(G, ot) | 0, i = i + Math.imul($, at) | 0, n = n + Math.imul($, ot) | 0, s = s + Math.imul(N, lt) | 0, i = i + Math.imul(N, ut) | 0, i = i + Math.imul(F, lt) | 0, n = n + Math.imul(F, ut) | 0, s = s + Math.imul(_, dt) | 0, i = i + Math.imul(_, vt) | 0, i = i + Math.imul(b, dt) | 0, n = n + Math.imul(b, vt) | 0;
        var Kt = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Kt >>> 26) | 0, Kt &= 67108863, s = Math.imul(P, rt), i = Math.imul(P, et), i = i + Math.imul(V, rt) | 0, n = Math.imul(V, et), s = s + Math.imul(K, ht) | 0, i = i + Math.imul(K, st) | 0, i = i + Math.imul(q, ht) | 0, n = n + Math.imul(q, st) | 0, s = s + Math.imul(Q, nt) | 0, i = i + Math.imul(Q, ft) | 0, i = i + Math.imul(O, nt) | 0, n = n + Math.imul(O, ft) | 0, s = s + Math.imul(U, at) | 0, i = i + Math.imul(U, ot) | 0, i = i + Math.imul(J, at) | 0, n = n + Math.imul(J, ot) | 0, s = s + Math.imul(G, lt) | 0, i = i + Math.imul(G, ut) | 0, i = i + Math.imul($, lt) | 0, n = n + Math.imul($, ut) | 0, s = s + Math.imul(N, dt) | 0, i = i + Math.imul(N, vt) | 0, i = i + Math.imul(F, dt) | 0, n = n + Math.imul(F, vt) | 0, s = s + Math.imul(_, ct) | 0, i = i + Math.imul(_, pt) | 0, i = i + Math.imul(b, ct) | 0, n = n + Math.imul(b, pt) | 0;
        var Pt = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Pt >>> 26) | 0, Pt &= 67108863, s = Math.imul(X, rt), i = Math.imul(X, et), i = i + Math.imul(Y, rt) | 0, n = Math.imul(Y, et), s = s + Math.imul(P, ht) | 0, i = i + Math.imul(P, st) | 0, i = i + Math.imul(V, ht) | 0, n = n + Math.imul(V, st) | 0, s = s + Math.imul(K, nt) | 0, i = i + Math.imul(K, ft) | 0, i = i + Math.imul(q, nt) | 0, n = n + Math.imul(q, ft) | 0, s = s + Math.imul(Q, at) | 0, i = i + Math.imul(Q, ot) | 0, i = i + Math.imul(O, at) | 0, n = n + Math.imul(O, ot) | 0, s = s + Math.imul(U, lt) | 0, i = i + Math.imul(U, ut) | 0, i = i + Math.imul(J, lt) | 0, n = n + Math.imul(J, ut) | 0, s = s + Math.imul(G, dt) | 0, i = i + Math.imul(G, vt) | 0, i = i + Math.imul($, dt) | 0, n = n + Math.imul($, vt) | 0, s = s + Math.imul(N, ct) | 0, i = i + Math.imul(N, pt) | 0, i = i + Math.imul(F, ct) | 0, n = n + Math.imul(F, pt) | 0, s = s + Math.imul(_, mt) | 0, i = i + Math.imul(_, gt) | 0, i = i + Math.imul(b, mt) | 0, n = n + Math.imul(b, gt) | 0;
        var Gt = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Gt >>> 26) | 0, Gt &= 67108863, s = Math.imul(W, rt), i = Math.imul(W, et), i = i + Math.imul(j, rt) | 0, n = Math.imul(j, et), s = s + Math.imul(X, ht) | 0, i = i + Math.imul(X, st) | 0, i = i + Math.imul(Y, ht) | 0, n = n + Math.imul(Y, st) | 0, s = s + Math.imul(P, nt) | 0, i = i + Math.imul(P, ft) | 0, i = i + Math.imul(V, nt) | 0, n = n + Math.imul(V, ft) | 0, s = s + Math.imul(K, at) | 0, i = i + Math.imul(K, ot) | 0, i = i + Math.imul(q, at) | 0, n = n + Math.imul(q, ot) | 0, s = s + Math.imul(Q, lt) | 0, i = i + Math.imul(Q, ut) | 0, i = i + Math.imul(O, lt) | 0, n = n + Math.imul(O, ut) | 0, s = s + Math.imul(U, dt) | 0, i = i + Math.imul(U, vt) | 0, i = i + Math.imul(J, dt) | 0, n = n + Math.imul(J, vt) | 0, s = s + Math.imul(G, ct) | 0, i = i + Math.imul(G, pt) | 0, i = i + Math.imul($, ct) | 0, n = n + Math.imul($, pt) | 0, s = s + Math.imul(N, mt) | 0, i = i + Math.imul(N, gt) | 0, i = i + Math.imul(F, mt) | 0, n = n + Math.imul(F, gt) | 0, s = s + Math.imul(_, xt) | 0, i = i + Math.imul(_, Mt) | 0, i = i + Math.imul(b, xt) | 0, n = n + Math.imul(b, Mt) | 0;
        var $t = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + ($t >>> 26) | 0, $t &= 67108863, s = Math.imul(tt, rt), i = Math.imul(tt, et), i = i + Math.imul(it, rt) | 0, n = Math.imul(it, et), s = s + Math.imul(W, ht) | 0, i = i + Math.imul(W, st) | 0, i = i + Math.imul(j, ht) | 0, n = n + Math.imul(j, st) | 0, s = s + Math.imul(X, nt) | 0, i = i + Math.imul(X, ft) | 0, i = i + Math.imul(Y, nt) | 0, n = n + Math.imul(Y, ft) | 0, s = s + Math.imul(P, at) | 0, i = i + Math.imul(P, ot) | 0, i = i + Math.imul(V, at) | 0, n = n + Math.imul(V, ot) | 0, s = s + Math.imul(K, lt) | 0, i = i + Math.imul(K, ut) | 0, i = i + Math.imul(q, lt) | 0, n = n + Math.imul(q, ut) | 0, s = s + Math.imul(Q, dt) | 0, i = i + Math.imul(Q, vt) | 0, i = i + Math.imul(O, dt) | 0, n = n + Math.imul(O, vt) | 0, s = s + Math.imul(U, ct) | 0, i = i + Math.imul(U, pt) | 0, i = i + Math.imul(J, ct) | 0, n = n + Math.imul(J, pt) | 0, s = s + Math.imul(G, mt) | 0, i = i + Math.imul(G, gt) | 0, i = i + Math.imul($, mt) | 0, n = n + Math.imul($, gt) | 0, s = s + Math.imul(N, xt) | 0, i = i + Math.imul(N, Mt) | 0, i = i + Math.imul(F, xt) | 0, n = n + Math.imul(F, Mt) | 0, s = s + Math.imul(_, wt) | 0, i = i + Math.imul(_, _t) | 0, i = i + Math.imul(b, wt) | 0, n = n + Math.imul(b, _t) | 0;
        var Jt = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Jt >>> 26) | 0, Jt &= 67108863, s = Math.imul(tt, ht), i = Math.imul(tt, st), i = i + Math.imul(it, ht) | 0, n = Math.imul(it, st), s = s + Math.imul(W, nt) | 0, i = i + Math.imul(W, ft) | 0, i = i + Math.imul(j, nt) | 0, n = n + Math.imul(j, ft) | 0, s = s + Math.imul(X, at) | 0, i = i + Math.imul(X, ot) | 0, i = i + Math.imul(Y, at) | 0, n = n + Math.imul(Y, ot) | 0, s = s + Math.imul(P, lt) | 0, i = i + Math.imul(P, ut) | 0, i = i + Math.imul(V, lt) | 0, n = n + Math.imul(V, ut) | 0, s = s + Math.imul(K, dt) | 0, i = i + Math.imul(K, vt) | 0, i = i + Math.imul(q, dt) | 0, n = n + Math.imul(q, vt) | 0, s = s + Math.imul(Q, ct) | 0, i = i + Math.imul(Q, pt) | 0, i = i + Math.imul(O, ct) | 0, n = n + Math.imul(O, pt) | 0, s = s + Math.imul(U, mt) | 0, i = i + Math.imul(U, gt) | 0, i = i + Math.imul(J, mt) | 0, n = n + Math.imul(J, gt) | 0, s = s + Math.imul(G, xt) | 0, i = i + Math.imul(G, Mt) | 0, i = i + Math.imul($, xt) | 0, n = n + Math.imul($, Mt) | 0, s = s + Math.imul(N, wt) | 0, i = i + Math.imul(N, _t) | 0, i = i + Math.imul(F, wt) | 0, n = n + Math.imul(F, _t) | 0;
        var Qt = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Qt >>> 26) | 0, Qt &= 67108863, s = Math.imul(tt, nt), i = Math.imul(tt, ft), i = i + Math.imul(it, nt) | 0, n = Math.imul(it, ft), s = s + Math.imul(W, at) | 0, i = i + Math.imul(W, ot) | 0, i = i + Math.imul(j, at) | 0, n = n + Math.imul(j, ot) | 0, s = s + Math.imul(X, lt) | 0, i = i + Math.imul(X, ut) | 0, i = i + Math.imul(Y, lt) | 0, n = n + Math.imul(Y, ut) | 0, s = s + Math.imul(P, dt) | 0, i = i + Math.imul(P, vt) | 0, i = i + Math.imul(V, dt) | 0, n = n + Math.imul(V, vt) | 0, s = s + Math.imul(K, ct) | 0, i = i + Math.imul(K, pt) | 0, i = i + Math.imul(q, ct) | 0, n = n + Math.imul(q, pt) | 0, s = s + Math.imul(Q, mt) | 0, i = i + Math.imul(Q, gt) | 0, i = i + Math.imul(O, mt) | 0, n = n + Math.imul(O, gt) | 0, s = s + Math.imul(U, xt) | 0, i = i + Math.imul(U, Mt) | 0, i = i + Math.imul(J, xt) | 0, n = n + Math.imul(J, Mt) | 0, s = s + Math.imul(G, wt) | 0, i = i + Math.imul(G, _t) | 0, i = i + Math.imul($, wt) | 0, n = n + Math.imul($, _t) | 0;
        var Vt = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Vt >>> 26) | 0, Vt &= 67108863, s = Math.imul(tt, at), i = Math.imul(tt, ot), i = i + Math.imul(it, at) | 0, n = Math.imul(it, ot), s = s + Math.imul(W, lt) | 0, i = i + Math.imul(W, ut) | 0, i = i + Math.imul(j, lt) | 0, n = n + Math.imul(j, ut) | 0, s = s + Math.imul(X, dt) | 0, i = i + Math.imul(X, vt) | 0, i = i + Math.imul(Y, dt) | 0, n = n + Math.imul(Y, vt) | 0, s = s + Math.imul(P, ct) | 0, i = i + Math.imul(P, pt) | 0, i = i + Math.imul(V, ct) | 0, n = n + Math.imul(V, pt) | 0, s = s + Math.imul(K, mt) | 0, i = i + Math.imul(K, gt) | 0, i = i + Math.imul(q, mt) | 0, n = n + Math.imul(q, gt) | 0, s = s + Math.imul(Q, xt) | 0, i = i + Math.imul(Q, Mt) | 0, i = i + Math.imul(O, xt) | 0, n = n + Math.imul(O, Mt) | 0, s = s + Math.imul(U, wt) | 0, i = i + Math.imul(U, _t) | 0, i = i + Math.imul(J, wt) | 0, n = n + Math.imul(J, _t) | 0;
        var Xt = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Xt >>> 26) | 0, Xt &= 67108863, s = Math.imul(tt, lt), i = Math.imul(tt, ut), i = i + Math.imul(it, lt) | 0, n = Math.imul(it, ut), s = s + Math.imul(W, dt) | 0, i = i + Math.imul(W, vt) | 0, i = i + Math.imul(j, dt) | 0, n = n + Math.imul(j, vt) | 0, s = s + Math.imul(X, ct) | 0, i = i + Math.imul(X, pt) | 0, i = i + Math.imul(Y, ct) | 0, n = n + Math.imul(Y, pt) | 0, s = s + Math.imul(P, mt) | 0, i = i + Math.imul(P, gt) | 0, i = i + Math.imul(V, mt) | 0, n = n + Math.imul(V, gt) | 0, s = s + Math.imul(K, xt) | 0, i = i + Math.imul(K, Mt) | 0, i = i + Math.imul(q, xt) | 0, n = n + Math.imul(q, Mt) | 0, s = s + Math.imul(Q, wt) | 0, i = i + Math.imul(Q, _t) | 0, i = i + Math.imul(O, wt) | 0, n = n + Math.imul(O, _t) | 0;
        var Yt = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Yt >>> 26) | 0, Yt &= 67108863, s = Math.imul(tt, dt), i = Math.imul(tt, vt), i = i + Math.imul(it, dt) | 0, n = Math.imul(it, vt), s = s + Math.imul(W, ct) | 0, i = i + Math.imul(W, pt) | 0, i = i + Math.imul(j, ct) | 0, n = n + Math.imul(j, pt) | 0, s = s + Math.imul(X, mt) | 0, i = i + Math.imul(X, gt) | 0, i = i + Math.imul(Y, mt) | 0, n = n + Math.imul(Y, gt) | 0, s = s + Math.imul(P, xt) | 0, i = i + Math.imul(P, Mt) | 0, i = i + Math.imul(V, xt) | 0, n = n + Math.imul(V, Mt) | 0, s = s + Math.imul(K, wt) | 0, i = i + Math.imul(K, _t) | 0, i = i + Math.imul(q, wt) | 0, n = n + Math.imul(q, _t) | 0;
        var Wt = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (Wt >>> 26) | 0, Wt &= 67108863, s = Math.imul(tt, ct), i = Math.imul(tt, pt), i = i + Math.imul(it, ct) | 0, n = Math.imul(it, pt), s = s + Math.imul(W, mt) | 0, i = i + Math.imul(W, gt) | 0, i = i + Math.imul(j, mt) | 0, n = n + Math.imul(j, gt) | 0, s = s + Math.imul(X, xt) | 0, i = i + Math.imul(X, Mt) | 0, i = i + Math.imul(Y, xt) | 0, n = n + Math.imul(Y, Mt) | 0, s = s + Math.imul(P, wt) | 0, i = i + Math.imul(P, _t) | 0, i = i + Math.imul(V, wt) | 0, n = n + Math.imul(V, _t) | 0;
        var jt = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (jt >>> 26) | 0, jt &= 67108863, s = Math.imul(tt, mt), i = Math.imul(tt, gt), i = i + Math.imul(it, mt) | 0, n = Math.imul(it, gt), s = s + Math.imul(W, xt) | 0, i = i + Math.imul(W, Mt) | 0, i = i + Math.imul(j, xt) | 0, n = n + Math.imul(j, Mt) | 0, s = s + Math.imul(X, wt) | 0, i = i + Math.imul(X, _t) | 0, i = i + Math.imul(Y, wt) | 0, n = n + Math.imul(Y, _t) | 0;
        var ti = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (ti >>> 26) | 0, ti &= 67108863, s = Math.imul(tt, xt), i = Math.imul(tt, Mt), i = i + Math.imul(it, xt) | 0, n = Math.imul(it, Mt), s = s + Math.imul(W, wt) | 0, i = i + Math.imul(W, _t) | 0, i = i + Math.imul(j, wt) | 0, n = n + Math.imul(j, _t) | 0;
        var ii = (u + s | 0) + ((i & 8191) << 13) | 0;
        u = (n + (i >>> 13) | 0) + (ii >>> 26) | 0, ii &= 67108863, s = Math.imul(tt, wt), i = Math.imul(tt, _t), i = i + Math.imul(it, wt) | 0, n = Math.imul(it, _t);
        var ri = (u + s | 0) + ((i & 8191) << 13) | 0;
        return u = (n + (i >>> 13) | 0) + (ri >>> 26) | 0, ri &= 67108863, l[0] = Zt, l[1] = Ht, l[2] = zt, l[3] = Ut, l[4] = Ot, l[5] = Kt, l[6] = Pt, l[7] = Gt, l[8] = $t, l[9] = Jt, l[10] = Qt, l[11] = Vt, l[12] = Xt, l[13] = Yt, l[14] = Wt, l[15] = jt, l[16] = ti, l[17] = ii, l[18] = ri, u !== 0 && (l[19] = u, e.length++), e;
      };
      Math.imul || (p = d);
      function w(a, t, r) {
        r.negative = t.negative ^ a.negative, r.length = a.length + t.length;
        for (var e = 0, h = 0, f = 0; f < r.length - 1; f++) {
          var l = h;
          h = 0;
          for (var u = e & 67108863, s = Math.min(f, t.length - 1), i = Math.max(0, f - a.length + 1); i <= s; i++) {
            var n = f - i, y = a.words[n] | 0, _ = t.words[i] | 0, b = y * _, yt = b & 67108863;
            l = l + (b / 67108864 | 0) | 0, yt = yt + u | 0, u = yt & 67108863, l = l + (yt >>> 26) | 0, h += l >>> 26, l &= 67108863;
          }
          r.words[f] = u, e = l, l = h;
        }
        return e !== 0 ? r.words[f] = e : r.length--, r._strip();
      }
      function z(a, t, r) {
        return w(a, t, r);
      }
      o.prototype.mulTo = function(t, r) {
        var e, h = this.length + t.length;
        return this.length === 10 && t.length === 10 ? e = p(this, t, r) : h < 63 ? e = d(this, t, r) : h < 1024 ? e = w(this, t, r) : e = z(this, t, r), e;
      }, o.prototype.mul = function(t) {
        var r = new o(null);
        return r.words = new Array(this.length + t.length), this.mulTo(t, r);
      }, o.prototype.mulf = function(t) {
        var r = new o(null);
        return r.words = new Array(this.length + t.length), z(this, t, r);
      }, o.prototype.imul = function(t) {
        return this.clone().mulTo(t, this);
      }, o.prototype.imuln = function(t) {
        var r = t < 0;
        r && (t = -t), v(typeof t == "number"), v(t < 67108864);
        for (var e = 0, h = 0; h < this.length; h++) {
          var f = (this.words[h] | 0) * t, l = (f & 67108863) + (e & 67108863);
          e >>= 26, e += f / 67108864 | 0, e += l >>> 26, this.words[h] = l & 67108863;
        }
        return e !== 0 && (this.words[h] = e, this.length++), r ? this.ineg() : this;
      }, o.prototype.muln = function(t) {
        return this.clone().imuln(t);
      }, o.prototype.sqr = function() {
        return this.mul(this);
      }, o.prototype.isqr = function() {
        return this.imul(this.clone());
      }, o.prototype.pow = function(t) {
        var r = c(t);
        if (r.length === 0) return new o(1);
        for (var e = this, h = 0; h < r.length && r[h] === 0; h++, e = e.sqr())
          ;
        if (++h < r.length)
          for (var f = e.sqr(); h < r.length; h++, f = f.sqr())
            r[h] !== 0 && (e = e.mul(f));
        return e;
      }, o.prototype.iushln = function(t) {
        v(typeof t == "number" && t >= 0);
        var r = t % 26, e = (t - r) / 26, h = 67108863 >>> 26 - r << 26 - r, f;
        if (r !== 0) {
          var l = 0;
          for (f = 0; f < this.length; f++) {
            var u = this.words[f] & h, s = (this.words[f] | 0) - u << r;
            this.words[f] = s | l, l = u >>> 26 - r;
          }
          l && (this.words[f] = l, this.length++);
        }
        if (e !== 0) {
          for (f = this.length - 1; f >= 0; f--)
            this.words[f + e] = this.words[f];
          for (f = 0; f < e; f++)
            this.words[f] = 0;
          this.length += e;
        }
        return this._strip();
      }, o.prototype.ishln = function(t) {
        return v(this.negative === 0), this.iushln(t);
      }, o.prototype.iushrn = function(t, r, e) {
        v(typeof t == "number" && t >= 0);
        var h;
        r ? h = (r - r % 26) / 26 : h = 0;
        var f = t % 26, l = Math.min((t - f) / 26, this.length), u = 67108863 ^ 67108863 >>> f << f, s = e;
        if (h -= l, h = Math.max(0, h), s) {
          for (var i = 0; i < l; i++)
            s.words[i] = this.words[i];
          s.length = l;
        }
        if (l !== 0) if (this.length > l)
          for (this.length -= l, i = 0; i < this.length; i++)
            this.words[i] = this.words[i + l];
        else
          this.words[0] = 0, this.length = 1;
        var n = 0;
        for (i = this.length - 1; i >= 0 && (n !== 0 || i >= h); i--) {
          var y = this.words[i] | 0;
          this.words[i] = n << 26 - f | y >>> f, n = y & u;
        }
        return s && n !== 0 && (s.words[s.length++] = n), this.length === 0 && (this.words[0] = 0, this.length = 1), this._strip();
      }, o.prototype.ishrn = function(t, r, e) {
        return v(this.negative === 0), this.iushrn(t, r, e);
      }, o.prototype.shln = function(t) {
        return this.clone().ishln(t);
      }, o.prototype.ushln = function(t) {
        return this.clone().iushln(t);
      }, o.prototype.shrn = function(t) {
        return this.clone().ishrn(t);
      }, o.prototype.ushrn = function(t) {
        return this.clone().iushrn(t);
      }, o.prototype.testn = function(t) {
        v(typeof t == "number" && t >= 0);
        var r = t % 26, e = (t - r) / 26, h = 1 << r;
        if (this.length <= e) return !1;
        var f = this.words[e];
        return !!(f & h);
      }, o.prototype.imaskn = function(t) {
        v(typeof t == "number" && t >= 0);
        var r = t % 26, e = (t - r) / 26;
        if (v(this.negative === 0, "imaskn works only with positive numbers"), this.length <= e)
          return this;
        if (r !== 0 && e++, this.length = Math.min(e, this.length), r !== 0) {
          var h = 67108863 ^ 67108863 >>> r << r;
          this.words[this.length - 1] &= h;
        }
        return this._strip();
      }, o.prototype.maskn = function(t) {
        return this.clone().imaskn(t);
      }, o.prototype.iaddn = function(t) {
        return v(typeof t == "number"), v(t < 67108864), t < 0 ? this.isubn(-t) : this.negative !== 0 ? this.length === 1 && (this.words[0] | 0) <= t ? (this.words[0] = t - (this.words[0] | 0), this.negative = 0, this) : (this.negative = 0, this.isubn(t), this.negative = 1, this) : this._iaddn(t);
      }, o.prototype._iaddn = function(t) {
        this.words[0] += t;
        for (var r = 0; r < this.length && this.words[r] >= 67108864; r++)
          this.words[r] -= 67108864, r === this.length - 1 ? this.words[r + 1] = 1 : this.words[r + 1]++;
        return this.length = Math.max(this.length, r + 1), this;
      }, o.prototype.isubn = function(t) {
        if (v(typeof t == "number"), v(t < 67108864), t < 0) return this.iaddn(-t);
        if (this.negative !== 0)
          return this.negative = 0, this.iaddn(t), this.negative = 1, this;
        if (this.words[0] -= t, this.length === 1 && this.words[0] < 0)
          this.words[0] = -this.words[0], this.negative = 1;
        else
          for (var r = 0; r < this.length && this.words[r] < 0; r++)
            this.words[r] += 67108864, this.words[r + 1] -= 1;
        return this._strip();
      }, o.prototype.addn = function(t) {
        return this.clone().iaddn(t);
      }, o.prototype.subn = function(t) {
        return this.clone().isubn(t);
      }, o.prototype.iabs = function() {
        return this.negative = 0, this;
      }, o.prototype.abs = function() {
        return this.clone().iabs();
      }, o.prototype._ishlnsubmul = function(t, r, e) {
        var h = t.length + e, f;
        this._expand(h);
        var l, u = 0;
        for (f = 0; f < t.length; f++) {
          l = (this.words[f + e] | 0) + u;
          var s = (t.words[f] | 0) * r;
          l -= s & 67108863, u = (l >> 26) - (s / 67108864 | 0), this.words[f + e] = l & 67108863;
        }
        for (; f < this.length - e; f++)
          l = (this.words[f + e] | 0) + u, u = l >> 26, this.words[f + e] = l & 67108863;
        if (u === 0) return this._strip();
        for (v(u === -1), u = 0, f = 0; f < this.length; f++)
          l = -(this.words[f] | 0) + u, u = l >> 26, this.words[f] = l & 67108863;
        return this.negative = 1, this._strip();
      }, o.prototype._wordDiv = function(t, r) {
        var e = this.length - t.length, h = this.clone(), f = t, l = f.words[f.length - 1] | 0, u = this._countBits(l);
        e = 26 - u, e !== 0 && (f = f.ushln(e), h.iushln(e), l = f.words[f.length - 1] | 0);
        var s = h.length - f.length, i;
        if (r !== "mod") {
          i = new o(null), i.length = s + 1, i.words = new Array(i.length);
          for (var n = 0; n < i.length; n++)
            i.words[n] = 0;
        }
        var y = h.clone()._ishlnsubmul(f, 1, s);
        y.negative === 0 && (h = y, i && (i.words[s] = 1));
        for (var _ = s - 1; _ >= 0; _--) {
          var b = (h.words[f.length + _] | 0) * 67108864 + (h.words[f.length + _ - 1] | 0);
          for (b = Math.min(b / l | 0, 67108863), h._ishlnsubmul(f, b, _); h.negative !== 0; )
            b--, h.negative = 0, h._ishlnsubmul(f, 1, _), h.isZero() || (h.negative ^= 1);
          i && (i.words[_] = b);
        }
        return i && i._strip(), h._strip(), r !== "div" && e !== 0 && h.iushrn(e), {
          div: i || null,
          mod: h
        };
      }, o.prototype.divmod = function(t, r, e) {
        if (v(!t.isZero()), this.isZero())
          return {
            div: new o(0),
            mod: new o(0)
          };
        var h, f, l;
        return this.negative !== 0 && t.negative === 0 ? (l = this.neg().divmod(t, r), r !== "mod" && (h = l.div.neg()), r !== "div" && (f = l.mod.neg(), e && f.negative !== 0 && f.iadd(t)), {
          div: h,
          mod: f
        }) : this.negative === 0 && t.negative !== 0 ? (l = this.divmod(t.neg(), r), r !== "mod" && (h = l.div.neg()), {
          div: h,
          mod: l.mod
        }) : (this.negative & t.negative) !== 0 ? (l = this.neg().divmod(t.neg(), r), r !== "div" && (f = l.mod.neg(), e && f.negative !== 0 && f.isub(t)), {
          div: l.div,
          mod: f
        }) : t.length > this.length || this.cmp(t) < 0 ? {
          div: new o(0),
          mod: this
        } : t.length === 1 ? r === "div" ? {
          div: this.divn(t.words[0]),
          mod: null
        } : r === "mod" ? {
          div: null,
          mod: new o(this.modrn(t.words[0]))
        } : {
          div: this.divn(t.words[0]),
          mod: new o(this.modrn(t.words[0]))
        } : this._wordDiv(t, r);
      }, o.prototype.div = function(t) {
        return this.divmod(t, "div", !1).div;
      }, o.prototype.mod = function(t) {
        return this.divmod(t, "mod", !1).mod;
      }, o.prototype.umod = function(t) {
        return this.divmod(t, "mod", !0).mod;
      }, o.prototype.divRound = function(t) {
        var r = this.divmod(t);
        if (r.mod.isZero()) return r.div;
        var e = r.div.negative !== 0 ? r.mod.isub(t) : r.mod, h = t.ushrn(1), f = t.andln(1), l = e.cmp(h);
        return l < 0 || f === 1 && l === 0 ? r.div : r.div.negative !== 0 ? r.div.isubn(1) : r.div.iaddn(1);
      }, o.prototype.modrn = function(t) {
        var r = t < 0;
        r && (t = -t), v(t <= 67108863);
        for (var e = (1 << 26) % t, h = 0, f = this.length - 1; f >= 0; f--)
          h = (e * h + (this.words[f] | 0)) % t;
        return r ? -h : h;
      }, o.prototype.modn = function(t) {
        return this.modrn(t);
      }, o.prototype.idivn = function(t) {
        var r = t < 0;
        r && (t = -t), v(t <= 67108863);
        for (var e = 0, h = this.length - 1; h >= 0; h--) {
          var f = (this.words[h] | 0) + e * 67108864;
          this.words[h] = f / t | 0, e = f % t;
        }
        return this._strip(), r ? this.ineg() : this;
      }, o.prototype.divn = function(t) {
        return this.clone().idivn(t);
      }, o.prototype.egcd = function(t) {
        v(t.negative === 0), v(!t.isZero());
        var r = this, e = t.clone();
        r.negative !== 0 ? r = r.umod(t) : r = r.clone();
        for (var h = new o(1), f = new o(0), l = new o(0), u = new o(1), s = 0; r.isEven() && e.isEven(); )
          r.iushrn(1), e.iushrn(1), ++s;
        for (var i = e.clone(), n = r.clone(); !r.isZero(); ) {
          for (var y = 0, _ = 1; (r.words[0] & _) === 0 && y < 26; ++y, _ <<= 1) ;
          if (y > 0)
            for (r.iushrn(y); y-- > 0; )
              (h.isOdd() || f.isOdd()) && (h.iadd(i), f.isub(n)), h.iushrn(1), f.iushrn(1);
          for (var b = 0, yt = 1; (e.words[0] & yt) === 0 && b < 26; ++b, yt <<= 1) ;
          if (b > 0)
            for (e.iushrn(b); b-- > 0; )
              (l.isOdd() || u.isOdd()) && (l.iadd(i), u.isub(n)), l.iushrn(1), u.iushrn(1);
          r.cmp(e) >= 0 ? (r.isub(e), h.isub(l), f.isub(u)) : (e.isub(r), l.isub(h), u.isub(f));
        }
        return {
          a: l,
          b: u,
          gcd: e.iushln(s)
        };
      }, o.prototype._invmp = function(t) {
        v(t.negative === 0), v(!t.isZero());
        var r = this, e = t.clone();
        r.negative !== 0 ? r = r.umod(t) : r = r.clone();
        for (var h = new o(1), f = new o(0), l = e.clone(); r.cmpn(1) > 0 && e.cmpn(1) > 0; ) {
          for (var u = 0, s = 1; (r.words[0] & s) === 0 && u < 26; ++u, s <<= 1) ;
          if (u > 0)
            for (r.iushrn(u); u-- > 0; )
              h.isOdd() && h.iadd(l), h.iushrn(1);
          for (var i = 0, n = 1; (e.words[0] & n) === 0 && i < 26; ++i, n <<= 1) ;
          if (i > 0)
            for (e.iushrn(i); i-- > 0; )
              f.isOdd() && f.iadd(l), f.iushrn(1);
          r.cmp(e) >= 0 ? (r.isub(e), h.isub(f)) : (e.isub(r), f.isub(h));
        }
        var y;
        return r.cmpn(1) === 0 ? y = h : y = f, y.cmpn(0) < 0 && y.iadd(t), y;
      }, o.prototype.gcd = function(t) {
        if (this.isZero()) return t.abs();
        if (t.isZero()) return this.abs();
        var r = this.clone(), e = t.clone();
        r.negative = 0, e.negative = 0;
        for (var h = 0; r.isEven() && e.isEven(); h++)
          r.iushrn(1), e.iushrn(1);
        do {
          for (; r.isEven(); )
            r.iushrn(1);
          for (; e.isEven(); )
            e.iushrn(1);
          var f = r.cmp(e);
          if (f < 0) {
            var l = r;
            r = e, e = l;
          } else if (f === 0 || e.cmpn(1) === 0)
            break;
          r.isub(e);
        } while (!0);
        return e.iushln(h);
      }, o.prototype.invm = function(t) {
        return this.egcd(t).a.umod(t);
      }, o.prototype.isEven = function() {
        return (this.words[0] & 1) === 0;
      }, o.prototype.isOdd = function() {
        return (this.words[0] & 1) === 1;
      }, o.prototype.andln = function(t) {
        return this.words[0] & t;
      }, o.prototype.bincn = function(t) {
        v(typeof t == "number");
        var r = t % 26, e = (t - r) / 26, h = 1 << r;
        if (this.length <= e)
          return this._expand(e + 1), this.words[e] |= h, this;
        for (var f = h, l = e; f !== 0 && l < this.length; l++) {
          var u = this.words[l] | 0;
          u += f, f = u >>> 26, u &= 67108863, this.words[l] = u;
        }
        return f !== 0 && (this.words[l] = f, this.length++), this;
      }, o.prototype.isZero = function() {
        return this.length === 1 && this.words[0] === 0;
      }, o.prototype.cmpn = function(t) {
        var r = t < 0;
        if (this.negative !== 0 && !r) return -1;
        if (this.negative === 0 && r) return 1;
        this._strip();
        var e;
        if (this.length > 1)
          e = 1;
        else {
          r && (t = -t), v(t <= 67108863, "Number is too big");
          var h = this.words[0] | 0;
          e = h === t ? 0 : h < t ? -1 : 1;
        }
        return this.negative !== 0 ? -e | 0 : e;
      }, o.prototype.cmp = function(t) {
        if (this.negative !== 0 && t.negative === 0) return -1;
        if (this.negative === 0 && t.negative !== 0) return 1;
        var r = this.ucmp(t);
        return this.negative !== 0 ? -r | 0 : r;
      }, o.prototype.ucmp = function(t) {
        if (this.length > t.length) return 1;
        if (this.length < t.length) return -1;
        for (var r = 0, e = this.length - 1; e >= 0; e--) {
          var h = this.words[e] | 0, f = t.words[e] | 0;
          if (h !== f) {
            h < f ? r = -1 : h > f && (r = 1);
            break;
          }
        }
        return r;
      }, o.prototype.gtn = function(t) {
        return this.cmpn(t) === 1;
      }, o.prototype.gt = function(t) {
        return this.cmp(t) === 1;
      }, o.prototype.gten = function(t) {
        return this.cmpn(t) >= 0;
      }, o.prototype.gte = function(t) {
        return this.cmp(t) >= 0;
      }, o.prototype.ltn = function(t) {
        return this.cmpn(t) === -1;
      }, o.prototype.lt = function(t) {
        return this.cmp(t) === -1;
      }, o.prototype.lten = function(t) {
        return this.cmpn(t) <= 0;
      }, o.prototype.lte = function(t) {
        return this.cmp(t) <= 0;
      }, o.prototype.eqn = function(t) {
        return this.cmpn(t) === 0;
      }, o.prototype.eq = function(t) {
        return this.cmp(t) === 0;
      }, o.red = function(t) {
        return new H(t);
      }, o.prototype.toRed = function(t) {
        return v(!this.red, "Already a number in reduction context"), v(this.negative === 0, "red works only with positives"), t.convertTo(this)._forceRed(t);
      }, o.prototype.fromRed = function() {
        return v(this.red, "fromRed works only with numbers in reduction context"), this.red.convertFrom(this);
      }, o.prototype._forceRed = function(t) {
        return this.red = t, this;
      }, o.prototype.forceRed = function(t) {
        return v(!this.red, "Already a number in reduction context"), this._forceRed(t);
      }, o.prototype.redAdd = function(t) {
        return v(this.red, "redAdd works only with red numbers"), this.red.add(this, t);
      }, o.prototype.redIAdd = function(t) {
        return v(this.red, "redIAdd works only with red numbers"), this.red.iadd(this, t);
      }, o.prototype.redSub = function(t) {
        return v(this.red, "redSub works only with red numbers"), this.red.sub(this, t);
      }, o.prototype.redISub = function(t) {
        return v(this.red, "redISub works only with red numbers"), this.red.isub(this, t);
      }, o.prototype.redShl = function(t) {
        return v(this.red, "redShl works only with red numbers"), this.red.shl(this, t);
      }, o.prototype.redMul = function(t) {
        return v(this.red, "redMul works only with red numbers"), this.red._verify2(this, t), this.red.mul(this, t);
      }, o.prototype.redIMul = function(t) {
        return v(this.red, "redMul works only with red numbers"), this.red._verify2(this, t), this.red.imul(this, t);
      }, o.prototype.redSqr = function() {
        return v(this.red, "redSqr works only with red numbers"), this.red._verify1(this), this.red.sqr(this);
      }, o.prototype.redISqr = function() {
        return v(this.red, "redISqr works only with red numbers"), this.red._verify1(this), this.red.isqr(this);
      }, o.prototype.redSqrt = function() {
        return v(this.red, "redSqrt works only with red numbers"), this.red._verify1(this), this.red.sqrt(this);
      }, o.prototype.redInvm = function() {
        return v(this.red, "redInvm works only with red numbers"), this.red._verify1(this), this.red.invm(this);
      }, o.prototype.redNeg = function() {
        return v(this.red, "redNeg works only with red numbers"), this.red._verify1(this), this.red.neg(this);
      }, o.prototype.redPow = function(t) {
        return v(this.red && !t.red, "redPow(normalNum)"), this.red._verify1(this), this.red.pow(this, t);
      };
      var R = {
        k256: null,
        p224: null,
        p192: null,
        p25519: null
      };
      function Z(a, t) {
        this.name = a, this.p = new o(t, 16), this.n = this.p.bitLength(), this.k = new o(1).iushln(this.n).isub(this.p), this.tmp = this._tmp();
      }
      Z.prototype._tmp = function() {
        var t = new o(null);
        return t.words = new Array(Math.ceil(this.n / 13)), t;
      }, Z.prototype.ireduce = function(t) {
        var r = t, e;
        do
          this.split(r, this.tmp), r = this.imulK(r), r = r.iadd(this.tmp), e = r.bitLength();
        while (e > this.n);
        var h = e < this.n ? -1 : r.ucmp(this.p);
        return h === 0 ? (r.words[0] = 0, r.length = 1) : h > 0 ? r.isub(this.p) : r.strip !== void 0 ? r.strip() : r._strip(), r;
      }, Z.prototype.split = function(t, r) {
        t.iushrn(this.n, 0, r);
      }, Z.prototype.imulK = function(t) {
        return t.imul(this.k);
      };
      function bt() {
        Z.call(
          this,
          "k256",
          "ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f"
        );
      }
      k(bt, Z), bt.prototype.split = function(t, r) {
        for (var e = 4194303, h = Math.min(t.length, 9), f = 0; f < h; f++)
          r.words[f] = t.words[f];
        if (r.length = h, t.length <= 9) {
          t.words[0] = 0, t.length = 1;
          return;
        }
        var l = t.words[9];
        for (r.words[r.length++] = l & e, f = 10; f < t.length; f++) {
          var u = t.words[f] | 0;
          t.words[f - 10] = (u & e) << 4 | l >>> 22, l = u;
        }
        l >>>= 22, t.words[f - 10] = l, l === 0 && t.length > 10 ? t.length -= 10 : t.length -= 9;
      }, bt.prototype.imulK = function(t) {
        t.words[t.length] = 0, t.words[t.length + 1] = 0, t.length += 2;
        for (var r = 0, e = 0; e < t.length; e++) {
          var h = t.words[e] | 0;
          r += h * 977, t.words[e] = r & 67108863, r = h * 64 + (r / 67108864 | 0);
        }
        return t.words[t.length - 1] === 0 && (t.length--, t.words[t.length - 1] === 0 && t.length--), t;
      };
      function At() {
        Z.call(
          this,
          "p224",
          "ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001"
        );
      }
      k(At, Z);
      function Bt() {
        Z.call(
          this,
          "p192",
          "ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff"
        );
      }
      k(Bt, Z);
      function Ct() {
        Z.call(
          this,
          "25519",
          "7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed"
        );
      }
      k(Ct, Z), Ct.prototype.imulK = function(t) {
        for (var r = 0, e = 0; e < t.length; e++) {
          var h = (t.words[e] | 0) * 19 + r, f = h & 67108863;
          h >>>= 26, t.words[e] = f, r = h;
        }
        return r !== 0 && (t.words[t.length++] = r), t;
      }, o._prime = function(t) {
        if (R[t]) return R[t];
        var r;
        if (t === "k256")
          r = new bt();
        else if (t === "p224")
          r = new At();
        else if (t === "p192")
          r = new Bt();
        else if (t === "p25519")
          r = new Ct();
        else
          throw new Error("Unknown prime " + t);
        return R[t] = r, r;
      };
      function H(a) {
        if (typeof a == "string") {
          var t = o._prime(a);
          this.m = t.p, this.prime = t;
        } else
          v(a.gtn(1), "modulus must be greater than 1"), this.m = a, this.prime = null;
      }
      H.prototype._verify1 = function(t) {
        v(t.negative === 0, "red works only with positives"), v(t.red, "red works only with red numbers");
      }, H.prototype._verify2 = function(t, r) {
        v((t.negative | r.negative) === 0, "red works only with positives"), v(
          t.red && t.red === r.red,
          "red works only with red numbers"
        );
      }, H.prototype.imod = function(t) {
        return this.prime ? this.prime.ireduce(t)._forceRed(this) : (M(t, t.umod(this.m)._forceRed(this)), t);
      }, H.prototype.neg = function(t) {
        return t.isZero() ? t.clone() : this.m.sub(t)._forceRed(this);
      }, H.prototype.add = function(t, r) {
        this._verify2(t, r);
        var e = t.add(r);
        return e.cmp(this.m) >= 0 && e.isub(this.m), e._forceRed(this);
      }, H.prototype.iadd = function(t, r) {
        this._verify2(t, r);
        var e = t.iadd(r);
        return e.cmp(this.m) >= 0 && e.isub(this.m), e;
      }, H.prototype.sub = function(t, r) {
        this._verify2(t, r);
        var e = t.sub(r);
        return e.cmpn(0) < 0 && e.iadd(this.m), e._forceRed(this);
      }, H.prototype.isub = function(t, r) {
        this._verify2(t, r);
        var e = t.isub(r);
        return e.cmpn(0) < 0 && e.iadd(this.m), e;
      }, H.prototype.shl = function(t, r) {
        return this._verify1(t), this.imod(t.ushln(r));
      }, H.prototype.imul = function(t, r) {
        return this._verify2(t, r), this.imod(t.imul(r));
      }, H.prototype.mul = function(t, r) {
        return this._verify2(t, r), this.imod(t.mul(r));
      }, H.prototype.isqr = function(t) {
        return this.imul(t, t.clone());
      }, H.prototype.sqr = function(t) {
        return this.mul(t, t);
      }, H.prototype.sqrt = function(t) {
        if (t.isZero()) return t.clone();
        var r = this.m.andln(3);
        if (v(r % 2 === 1), r === 3) {
          var e = this.m.add(new o(1)).iushrn(2);
          return this.pow(t, e);
        }
        for (var h = this.m.subn(1), f = 0; !h.isZero() && h.andln(1) === 0; )
          f++, h.iushrn(1);
        v(!h.isZero());
        var l = new o(1).toRed(this), u = l.redNeg(), s = this.m.subn(1).iushrn(1), i = this.m.bitLength();
        for (i = new o(2 * i * i).toRed(this); this.pow(i, s).cmp(u) !== 0; )
          i.redIAdd(u);
        for (var n = this.pow(i, h), y = this.pow(t, h.addn(1).iushrn(1)), _ = this.pow(t, h), b = f; _.cmp(l) !== 0; ) {
          for (var yt = _, N = 0; yt.cmp(l) !== 0; N++)
            yt = yt.redSqr();
          v(N < b);
          var F = this.pow(n, new o(1).iushln(b - N - 1));
          y = y.redMul(F), n = F.redSqr(), _ = _.redMul(n), b = N;
        }
        return y;
      }, H.prototype.invm = function(t) {
        var r = t._invmp(this.m);
        return r.negative !== 0 ? (r.negative = 0, this.imod(r).redNeg()) : this.imod(r);
      }, H.prototype.pow = function(t, r) {
        if (r.isZero()) return new o(1).toRed(this);
        if (r.cmpn(1) === 0) return t.clone();
        var e = 4, h = new Array(1 << e);
        h[0] = new o(1).toRed(this), h[1] = t;
        for (var f = 2; f < h.length; f++)
          h[f] = this.mul(h[f - 1], t);
        var l = h[0], u = 0, s = 0, i = r.bitLength() % 26;
        for (i === 0 && (i = 26), f = r.length - 1; f >= 0; f--) {
          for (var n = r.words[f], y = i - 1; y >= 0; y--) {
            var _ = n >> y & 1;
            if (l !== h[0] && (l = this.sqr(l)), _ === 0 && u === 0) {
              s = 0;
              continue;
            }
            u <<= 1, u |= _, s++, !(s !== e && (f !== 0 || y !== 0)) && (l = this.mul(l, h[u]), s = 0, u = 0);
          }
          i = 26;
        }
        return l;
      }, H.prototype.convertTo = function(t) {
        var r = t.umod(this.m);
        return r === t ? r.clone() : r;
      }, H.prototype.convertFrom = function(t) {
        var r = t.clone();
        return r.red = null, r;
      }, o.mont = function(t) {
        return new Et(t);
      };
      function Et(a) {
        H.call(this, a), this.shift = this.m.bitLength(), this.shift % 26 !== 0 && (this.shift += 26 - this.shift % 26), this.r = new o(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);
      }
      k(Et, H), Et.prototype.convertTo = function(t) {
        return this.imod(t.ushln(this.shift));
      }, Et.prototype.convertFrom = function(t) {
        var r = this.imod(t.mul(this.rinv));
        return r.red = null, r;
      }, Et.prototype.imul = function(t, r) {
        if (t.isZero() || r.isZero())
          return t.words[0] = 0, t.length = 1, t;
        var e = t.imul(r), h = e.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m), f = e.isub(h).iushrn(this.shift), l = f;
        return f.cmp(this.m) >= 0 ? l = f.isub(this.m) : f.cmpn(0) < 0 && (l = f.iadd(this.m)), l._forceRed(this);
      }, Et.prototype.mul = function(t, r) {
        if (t.isZero() || r.isZero()) return new o(0)._forceRed(this);
        var e = t.mul(r), h = e.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m), f = e.isub(h).iushrn(this.shift), l = f;
        return f.cmp(this.m) >= 0 ? l = f.isub(this.m) : f.cmpn(0) < 0 && (l = f.iadd(this.m)), l._forceRed(this);
      }, Et.prototype.invm = function(t) {
        var r = this.imod(t._invmp(this.m).mul(this.r2));
        return r._forceRed(this);
      };
    })(T, zi);
  }(Dt)), Dt.exports;
}
var ei = { exports: {} }, Lt = { exports: {} };
/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
var Si;
function kt() {
  return Si || (Si = 1, function(T, L) {
    var A = Li(), v = A.Buffer;
    function k(x, C) {
      for (var D in x)
        C[D] = x[D];
    }
    v.from && v.alloc && v.allocUnsafe && v.allocUnsafeSlow ? T.exports = A : (k(A, L), L.Buffer = o);
    function o(x, C, D) {
      return v(x, C, D);
    }
    o.prototype = Object.create(v.prototype), k(v, o), o.from = function(x, C, D) {
      if (typeof x == "number")
        throw new TypeError("Argument must not be a number");
      return v(x, C, D);
    }, o.alloc = function(x, C, D) {
      if (typeof x != "number")
        throw new TypeError("Argument must be a number");
      var E = v(x);
      return C !== void 0 ? typeof D == "string" ? E.fill(C, D) : E.fill(C) : E.fill(0), E;
    }, o.allocUnsafe = function(x) {
      if (typeof x != "number")
        throw new TypeError("Argument must be a number");
      return v(x);
    }, o.allocUnsafeSlow = function(x) {
      if (typeof x != "number")
        throw new TypeError("Argument must be a number");
      return A.SlowBuffer(x);
    };
  }(Lt, Lt.exports)), Lt.exports;
}
var hi, Ai;
function It() {
  if (Ai) return hi;
  Ai = 1;
  var T = kt().Buffer;
  function L(A, v) {
    this._block = T.alloc(A), this._finalSize = v, this._blockSize = A, this._len = 0;
  }
  return L.prototype.update = function(A, v) {
    typeof A == "string" && (v = v || "utf8", A = T.from(A, v));
    for (var k = this._block, o = this._blockSize, x = A.length, C = this._len, D = 0; D < x; ) {
      for (var E = C % o, M = Math.min(x - D, o - E), S = 0; S < M; S++)
        k[E + S] = A[D + S];
      C += M, D += M, C % o === 0 && this._update(k);
    }
    return this._len += x, this;
  }, L.prototype.digest = function(A) {
    var v = this._len % this._blockSize;
    this._block[v] = 128, this._block.fill(0, v + 1), v >= this._finalSize && (this._update(this._block), this._block.fill(0));
    var k = this._len * 8;
    if (k <= 4294967295)
      this._block.writeUInt32BE(k, this._blockSize - 4);
    else {
      var o = (k & 4294967295) >>> 0, x = (k - o) / 4294967296;
      this._block.writeUInt32BE(x, this._blockSize - 8), this._block.writeUInt32BE(o, this._blockSize - 4);
    }
    this._update(this._block);
    var C = this._hash();
    return A ? C.toString(A) : C;
  }, L.prototype._update = function() {
    throw new Error("_update must be implemented by subclass");
  }, hi = L, hi;
}
var si, Ci;
function Ui() {
  if (Ci) return si;
  Ci = 1;
  var T = qt(), L = It(), A = kt().Buffer, v = [
    1518500249,
    1859775393,
    -1894007588,
    -899497514
  ], k = new Array(80);
  function o() {
    this.init(), this._w = k, L.call(this, 64, 56);
  }
  T(o, L), o.prototype.init = function() {
    return this._a = 1732584193, this._b = 4023233417, this._c = 2562383102, this._d = 271733878, this._e = 3285377520, this;
  };
  function x(E) {
    return E << 5 | E >>> 27;
  }
  function C(E) {
    return E << 30 | E >>> 2;
  }
  function D(E, M, S, m) {
    return E === 0 ? M & S | ~M & m : E === 2 ? M & S | M & m | S & m : M ^ S ^ m;
  }
  return o.prototype._update = function(E) {
    for (var M = this._w, S = this._a | 0, m = this._b | 0, I = this._c | 0, B = this._d | 0, g = this._e | 0, c = 0; c < 16; ++c) M[c] = E.readInt32BE(c * 4);
    for (; c < 80; ++c) M[c] = M[c - 3] ^ M[c - 8] ^ M[c - 14] ^ M[c - 16];
    for (var d = 0; d < 80; ++d) {
      var p = ~~(d / 20), w = x(S) + D(p, m, I, B) + g + M[d] + v[p] | 0;
      g = B, B = I, I = C(m), m = S, S = w;
    }
    this._a = S + this._a | 0, this._b = m + this._b | 0, this._c = I + this._c | 0, this._d = B + this._d | 0, this._e = g + this._e | 0;
  }, o.prototype._hash = function() {
    var E = A.allocUnsafe(20);
    return E.writeInt32BE(this._a | 0, 0), E.writeInt32BE(this._b | 0, 4), E.writeInt32BE(this._c | 0, 8), E.writeInt32BE(this._d | 0, 12), E.writeInt32BE(this._e | 0, 16), E;
  }, si = o, si;
}
var ni, Ni;
function Oi() {
  if (Ni) return ni;
  Ni = 1;
  var T = qt(), L = It(), A = kt().Buffer, v = [
    1518500249,
    1859775393,
    -1894007588,
    -899497514
  ], k = new Array(80);
  function o() {
    this.init(), this._w = k, L.call(this, 64, 56);
  }
  T(o, L), o.prototype.init = function() {
    return this._a = 1732584193, this._b = 4023233417, this._c = 2562383102, this._d = 271733878, this._e = 3285377520, this;
  };
  function x(M) {
    return M << 1 | M >>> 31;
  }
  function C(M) {
    return M << 5 | M >>> 27;
  }
  function D(M) {
    return M << 30 | M >>> 2;
  }
  function E(M, S, m, I) {
    return M === 0 ? S & m | ~S & I : M === 2 ? S & m | S & I | m & I : S ^ m ^ I;
  }
  return o.prototype._update = function(M) {
    for (var S = this._w, m = this._a | 0, I = this._b | 0, B = this._c | 0, g = this._d | 0, c = this._e | 0, d = 0; d < 16; ++d) S[d] = M.readInt32BE(d * 4);
    for (; d < 80; ++d) S[d] = x(S[d - 3] ^ S[d - 8] ^ S[d - 14] ^ S[d - 16]);
    for (var p = 0; p < 80; ++p) {
      var w = ~~(p / 20), z = C(m) + E(w, I, B, g) + c + S[p] + v[w] | 0;
      c = g, g = B, B = D(I), I = m, m = z;
    }
    this._a = m + this._a | 0, this._b = I + this._b | 0, this._c = B + this._c | 0, this._d = g + this._d | 0, this._e = c + this._e | 0;
  }, o.prototype._hash = function() {
    var M = A.allocUnsafe(20);
    return M.writeInt32BE(this._a | 0, 0), M.writeInt32BE(this._b | 0, 4), M.writeInt32BE(this._c | 0, 8), M.writeInt32BE(this._d | 0, 12), M.writeInt32BE(this._e | 0, 16), M;
  }, ni = o, ni;
}
var fi, ki;
function Di() {
  if (ki) return fi;
  ki = 1;
  var T = qt(), L = It(), A = kt().Buffer, v = [
    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
  ], k = new Array(64);
  function o() {
    this.init(), this._w = k, L.call(this, 64, 56);
  }
  T(o, L), o.prototype.init = function() {
    return this._a = 1779033703, this._b = 3144134277, this._c = 1013904242, this._d = 2773480762, this._e = 1359893119, this._f = 2600822924, this._g = 528734635, this._h = 1541459225, this;
  };
  function x(m, I, B) {
    return B ^ m & (I ^ B);
  }
  function C(m, I, B) {
    return m & I | B & (m | I);
  }
  function D(m) {
    return (m >>> 2 | m << 30) ^ (m >>> 13 | m << 19) ^ (m >>> 22 | m << 10);
  }
  function E(m) {
    return (m >>> 6 | m << 26) ^ (m >>> 11 | m << 21) ^ (m >>> 25 | m << 7);
  }
  function M(m) {
    return (m >>> 7 | m << 25) ^ (m >>> 18 | m << 14) ^ m >>> 3;
  }
  function S(m) {
    return (m >>> 17 | m << 15) ^ (m >>> 19 | m << 13) ^ m >>> 10;
  }
  return o.prototype._update = function(m) {
    for (var I = this._w, B = this._a | 0, g = this._b | 0, c = this._c | 0, d = this._d | 0, p = this._e | 0, w = this._f | 0, z = this._g | 0, R = this._h | 0, Z = 0; Z < 16; ++Z) I[Z] = m.readInt32BE(Z * 4);
    for (; Z < 64; ++Z) I[Z] = S(I[Z - 2]) + I[Z - 7] + M(I[Z - 15]) + I[Z - 16] | 0;
    for (var bt = 0; bt < 64; ++bt) {
      var At = R + E(p) + x(p, w, z) + v[bt] + I[bt] | 0, Bt = D(B) + C(B, g, c) | 0;
      R = z, z = w, w = p, p = d + At | 0, d = c, c = g, g = B, B = At + Bt | 0;
    }
    this._a = B + this._a | 0, this._b = g + this._b | 0, this._c = c + this._c | 0, this._d = d + this._d | 0, this._e = p + this._e | 0, this._f = w + this._f | 0, this._g = z + this._g | 0, this._h = R + this._h | 0;
  }, o.prototype._hash = function() {
    var m = A.allocUnsafe(32);
    return m.writeInt32BE(this._a, 0), m.writeInt32BE(this._b, 4), m.writeInt32BE(this._c, 8), m.writeInt32BE(this._d, 12), m.writeInt32BE(this._e, 16), m.writeInt32BE(this._f, 20), m.writeInt32BE(this._g, 24), m.writeInt32BE(this._h, 28), m;
  }, fi = o, fi;
}
var ai, qi;
function Ki() {
  if (qi) return ai;
  qi = 1;
  var T = qt(), L = Di(), A = It(), v = kt().Buffer, k = new Array(64);
  function o() {
    this.init(), this._w = k, A.call(this, 64, 56);
  }
  return T(o, L), o.prototype.init = function() {
    return this._a = 3238371032, this._b = 914150663, this._c = 812702999, this._d = 4144912697, this._e = 4290775857, this._f = 1750603025, this._g = 1694076839, this._h = 3204075428, this;
  }, o.prototype._hash = function() {
    var x = v.allocUnsafe(28);
    return x.writeInt32BE(this._a, 0), x.writeInt32BE(this._b, 4), x.writeInt32BE(this._c, 8), x.writeInt32BE(this._d, 12), x.writeInt32BE(this._e, 16), x.writeInt32BE(this._f, 20), x.writeInt32BE(this._g, 24), x;
  }, ai = o, ai;
}
var oi, Ii;
function Zi() {
  if (Ii) return oi;
  Ii = 1;
  var T = qt(), L = It(), A = kt().Buffer, v = [
    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
  ], k = new Array(160);
  function o() {
    this.init(), this._w = k, L.call(this, 128, 112);
  }
  T(o, L), o.prototype.init = function() {
    return this._ah = 1779033703, this._bh = 3144134277, this._ch = 1013904242, this._dh = 2773480762, this._eh = 1359893119, this._fh = 2600822924, this._gh = 528734635, this._hh = 1541459225, this._al = 4089235720, this._bl = 2227873595, this._cl = 4271175723, this._dl = 1595750129, this._el = 2917565137, this._fl = 725511199, this._gl = 4215389547, this._hl = 327033209, this;
  };
  function x(g, c, d) {
    return d ^ g & (c ^ d);
  }
  function C(g, c, d) {
    return g & c | d & (g | c);
  }
  function D(g, c) {
    return (g >>> 28 | c << 4) ^ (c >>> 2 | g << 30) ^ (c >>> 7 | g << 25);
  }
  function E(g, c) {
    return (g >>> 14 | c << 18) ^ (g >>> 18 | c << 14) ^ (c >>> 9 | g << 23);
  }
  function M(g, c) {
    return (g >>> 1 | c << 31) ^ (g >>> 8 | c << 24) ^ g >>> 7;
  }
  function S(g, c) {
    return (g >>> 1 | c << 31) ^ (g >>> 8 | c << 24) ^ (g >>> 7 | c << 25);
  }
  function m(g, c) {
    return (g >>> 19 | c << 13) ^ (c >>> 29 | g << 3) ^ g >>> 6;
  }
  function I(g, c) {
    return (g >>> 19 | c << 13) ^ (c >>> 29 | g << 3) ^ (g >>> 6 | c << 26);
  }
  function B(g, c) {
    return g >>> 0 < c >>> 0 ? 1 : 0;
  }
  return o.prototype._update = function(g) {
    for (var c = this._w, d = this._ah | 0, p = this._bh | 0, w = this._ch | 0, z = this._dh | 0, R = this._eh | 0, Z = this._fh | 0, bt = this._gh | 0, At = this._hh | 0, Bt = this._al | 0, Ct = this._bl | 0, H = this._cl | 0, Et = this._dl | 0, a = this._el | 0, t = this._fl | 0, r = this._gl | 0, e = this._hl | 0, h = 0; h < 32; h += 2)
      c[h] = g.readInt32BE(h * 4), c[h + 1] = g.readInt32BE(h * 4 + 4);
    for (; h < 160; h += 2) {
      var f = c[h - 30], l = c[h - 15 * 2 + 1], u = M(f, l), s = S(l, f);
      f = c[h - 2 * 2], l = c[h - 2 * 2 + 1];
      var i = m(f, l), n = I(l, f), y = c[h - 7 * 2], _ = c[h - 7 * 2 + 1], b = c[h - 16 * 2], yt = c[h - 16 * 2 + 1], N = s + _ | 0, F = u + y + B(N, s) | 0;
      N = N + n | 0, F = F + i + B(N, n) | 0, N = N + yt | 0, F = F + b + B(N, yt) | 0, c[h] = F, c[h + 1] = N;
    }
    for (var Nt = 0; Nt < 160; Nt += 2) {
      F = c[Nt], N = c[Nt + 1];
      var G = C(d, p, w), $ = C(Bt, Ct, H), Rt = D(d, Bt), U = D(Bt, d), J = E(R, a), Ft = E(a, R), Q = v[Nt], O = v[Nt + 1], Tt = x(R, Z, bt), K = x(a, t, r), q = e + Ft | 0, St = At + J + B(q, e) | 0;
      q = q + K | 0, St = St + Tt + B(q, K) | 0, q = q + O | 0, St = St + Q + B(q, O) | 0, q = q + N | 0, St = St + F + B(q, N) | 0;
      var P = U + $ | 0, V = Rt + G + B(P, U) | 0;
      At = bt, e = r, bt = Z, r = t, Z = R, t = a, a = Et + q | 0, R = z + St + B(a, Et) | 0, z = w, Et = H, w = p, H = Ct, p = d, Ct = Bt, Bt = q + P | 0, d = St + V + B(Bt, q) | 0;
    }
    this._al = this._al + Bt | 0, this._bl = this._bl + Ct | 0, this._cl = this._cl + H | 0, this._dl = this._dl + Et | 0, this._el = this._el + a | 0, this._fl = this._fl + t | 0, this._gl = this._gl + r | 0, this._hl = this._hl + e | 0, this._ah = this._ah + d + B(this._al, Bt) | 0, this._bh = this._bh + p + B(this._bl, Ct) | 0, this._ch = this._ch + w + B(this._cl, H) | 0, this._dh = this._dh + z + B(this._dl, Et) | 0, this._eh = this._eh + R + B(this._el, a) | 0, this._fh = this._fh + Z + B(this._fl, t) | 0, this._gh = this._gh + bt + B(this._gl, r) | 0, this._hh = this._hh + At + B(this._hl, e) | 0;
  }, o.prototype._hash = function() {
    var g = A.allocUnsafe(64);
    function c(d, p, w) {
      g.writeInt32BE(d, w), g.writeInt32BE(p, w + 4);
    }
    return c(this._ah, this._al, 0), c(this._bh, this._bl, 8), c(this._ch, this._cl, 16), c(this._dh, this._dl, 24), c(this._eh, this._el, 32), c(this._fh, this._fl, 40), c(this._gh, this._gl, 48), c(this._hh, this._hl, 56), g;
  }, oi = o, oi;
}
var li, Ri;
function Pi() {
  if (Ri) return li;
  Ri = 1;
  var T = qt(), L = Zi(), A = It(), v = kt().Buffer, k = new Array(160);
  function o() {
    this.init(), this._w = k, A.call(this, 128, 112);
  }
  return T(o, L), o.prototype.init = function() {
    return this._ah = 3418070365, this._bh = 1654270250, this._ch = 2438529370, this._dh = 355462360, this._eh = 1731405415, this._fh = 2394180231, this._gh = 3675008525, this._hh = 1203062813, this._al = 3238371032, this._bl = 914150663, this._cl = 812702999, this._dl = 4144912697, this._el = 4290775857, this._fl = 1750603025, this._gl = 1694076839, this._hl = 3204075428, this;
  }, o.prototype._hash = function() {
    var x = v.allocUnsafe(48);
    function C(D, E, M) {
      x.writeInt32BE(D, M), x.writeInt32BE(E, M + 4);
    }
    return C(this._ah, this._al, 0), C(this._bh, this._bl, 8), C(this._ch, this._cl, 16), C(this._dh, this._dl, 24), C(this._eh, this._el, 32), C(this._fh, this._fl, 40), x;
  }, li = o, li;
}
var Fi;
function Xi() {
  if (Fi) return ei.exports;
  Fi = 1;
  var T = ei.exports = function(A) {
    A = A.toLowerCase();
    var v = T[A];
    if (!v) throw new Error(A + " is not supported (we accept pull requests)");
    return new v();
  };
  return T.sha = Ui(), T.sha1 = Oi(), T.sha224 = Ki(), T.sha256 = Di(), T.sha384 = Pi(), T.sha512 = Zi(), ei.exports;
}
const Gi = {}, $i = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
  __proto__: null,
  default: Gi
}, Symbol.toStringTag, { value: "Module" })), Yi = /* @__PURE__ */ Hi($i);
var ui = {}, Ti;
function Wi() {
  if (Ti) return ui;
  Ti = 1;
  var T = kt().Buffer, L = T.isEncoding || function(d) {
    switch (d = "" + d, d && d.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 A(d) {
    if (!d) return "utf8";
    for (var p; ; )
      switch (d) {
        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 d;
        default:
          if (p) return;
          d = ("" + d).toLowerCase(), p = !0;
      }
  }
  function v(d) {
    var p = A(d);
    if (typeof p != "string" && (T.isEncoding === L || !L(d))) throw new Error("Unknown encoding: " + d);
    return p || d;
  }
  ui.StringDecoder = k;
  function k(d) {
    this.encoding = v(d);
    var p;
    switch (this.encoding) {
      case "utf16le":
        this.text = S, this.end = m, p = 4;
        break;
      case "utf8":
        this.fillLast = D, p = 4;
        break;
      case "base64":
        this.text = I, this.end = B, p = 3;
        break;
      default:
        this.write = g, this.end = c;
        return;
    }
    this.lastNeed = 0, this.lastTotal = 0, this.lastChar = T.allocUnsafe(p);
  }
  k.prototype.write = function(d) {
    if (d.length === 0) return "";
    var p, w;
    if (this.lastNeed) {
      if (p = this.fillLast(d), p === void 0) return "";
      w = this.lastNeed, this.lastNeed = 0;
    } else
      w = 0;
    return w < d.length ? p ? p + this.text(d, w) : this.text(d, w) : p || "";
  }, k.prototype.end = M, k.prototype.text = E, k.prototype.fillLast = function(d) {
    if (this.lastNeed <= d.length)
      return d.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, this.lastNeed), this.lastChar.toString(this.encoding, 0, this.lastTotal);
    d.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, d.length), this.lastNeed -= d.length;
  };
  function o(d) {
    return d <= 127 ? 0 : d >> 5 === 6 ? 2 : d >> 4 === 14 ? 3 : d >> 3 === 30 ? 4 : d >> 6 === 2 ? -1 : -2;
  }
  function x(d, p, w) {
    var z = p.length - 1;
    if (z < w) return 0;
    var R = o(p[z]);
    return R >= 0 ? (R > 0 && (d.lastNeed = R - 1), R) : --z < w || R === -2 ? 0 : (R = o(p[z]), R >= 0 ? (R > 0 && (d.lastNeed = R - 2), R) : --z < w || R === -2 ? 0 : (R = o(p[z]), R >= 0 ? (R > 0 && (R === 2 ? R = 0 : d.lastNeed = R - 3), R) : 0));
  }
  function C(d, p, w) {
    if ((p[0] & 192) !== 128)
      return d.lastNeed = 0, "�";
    if (d.lastNeed > 1 && p.length > 1) {
      if ((p[1] & 192) !== 128)
        return d.lastNeed = 1, "�";
      if (d.lastNeed > 2 && p.length > 2 && (p[2] & 192) !== 128)
        return d.lastNeed = 2, "�";
    }
  }
  function D(d) {
    var p = this.lastTotal - this.lastNeed, w = C(this, d);
    if (w !== void 0) return w;
    if (this.lastNeed <= d.length)
      return d.copy(this.lastChar, p, 0, this.lastNeed), this.lastChar.toString(this.encoding, 0, this.lastTotal);
    d.copy(this.lastChar, p, 0, d.length), this.lastNeed -= d.length;
  }
  function E(d, p) {
    var w = x(this, d, p);
    if (!this.lastNeed) return d.toString("utf8", p);
    this.lastTotal = w;
    var z = d.length - (w - this.lastNeed);
    return d.copy(this.lastChar, 0, z), d.toString("utf8", p, z);
  }
  function M(d) {
    var p = d && d.length ? this.write(d) : "";
    return this.lastNeed ? p + "�" : p;
  }
  function S(d, p) {
    if ((d.length - p) % 2 === 0) {
      var w = d.toString("utf16le", p);
      if (w) {
        var z = w.charCodeAt(w.length - 1);
        if (z >= 55296 && z <= 56319)
          return this.lastNeed = 2, this.lastTotal = 4, this.lastChar[0] = d[d.length - 2], this.lastChar[1] = d[d.length - 1], w.slice(0, -1);
      }
      return w;
    }
    return this.lastNeed = 1, this.lastTotal = 2, this.lastChar[0] = d[d.length - 1], d.toString("utf16le", p, d.length - 1);
  }
  function m(d) {
    var p = d && d.length ? this.write(d) : "";
    if (this.lastNeed) {
      var w = this.lastTotal - this.lastNeed;
      return p + this.lastChar.toString("utf16le", 0, w);
    }
    return p;
  }
  function I(d, p) {
    var w = (d.length - p) % 3;
    return w === 0 ? d.toString("base64", p) : (this.lastNeed = 3 - w, this.lastTotal = 3, w === 1 ? this.lastChar[0] = d[d.length - 1] : (this.lastChar[0] = d[d.length - 2], this.lastChar[1] = d[d.length - 1]), d.toString("base64", p, d.length - w));
  }
  function B(d) {
    var p = d && d.length ? this.write(d) : "";
    return this.lastNeed ? p + this.lastChar.toString("base64", 0, 3 - this.lastNeed) : p;
  }
  function g(d) {
    return d.toString(this.encoding);
  }
  function c(d) {
    return d && d.length ? this.write(d) : "";
  }
  return ui;
}
export {
  Xi as a,
  Yi as b,
  Wi as c,
  kt as d,
  Vi as r
};
//# sourceMappingURL=string_decoder-DoIgMK32.js.map
