HEX
Server: Apache
System: Linux msm5694.mjhst.com 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
User: camjab_ssh (1000)
PHP: 5.3.29
Disabled: NONE
Upload Files
File: /home/httpd/html/baretube.com/templates/default_tube2016/js/functions.min.js
!function(a, b) {
    "object" == typeof module && "object" == typeof module.exports ? module.exports = a.document ? b(a, !0) : function(a) {
        if (!a.document) throw new Error("jQuery requires a window with a document");
        return b(a);
    } : b(a);
}("undefined" != typeof window ? window : this, function(a, b) {
    function c(a) {
        var b = "length" in a && a.length, c = ea.type(a);
        return "function" === c || ea.isWindow(a) ? !1 : 1 === a.nodeType && b ? !0 : "array" === c || 0 === b || "number" == typeof b && b > 0 && b - 1 in a;
    }
    function d(a, b, c) {
        if (ea.isFunction(b)) return ea.grep(a, function(a, d) {
            return !!b.call(a, d, a) !== c;
        });
        if (b.nodeType) return ea.grep(a, function(a) {
            return a === b !== c;
        });
        if ("string" == typeof b) {
            if (ma.test(b)) return ea.filter(b, a, c);
            b = ea.filter(b, a);
        }
        return ea.grep(a, function(a) {
            return ea.inArray(a, b) >= 0 !== c;
        });
    }
    function e(a, b) {
        do a = a[b]; while (a && 1 !== a.nodeType);
        return a;
    }
    function f(a) {
        var b = ua[a] = {};
        return ea.each(a.match(ta) || [], function(a, c) {
            b[c] = !0;
        }), b;
    }
    function g() {
        oa.addEventListener ? (oa.removeEventListener("DOMContentLoaded", h, !1), a.removeEventListener("load", h, !1)) : (oa.detachEvent("onreadystatechange", h), 
        a.detachEvent("onload", h));
    }
    function h() {
        (oa.addEventListener || "load" === event.type || "complete" === oa.readyState) && (g(), 
        ea.ready());
    }
    function i(a, b, c) {
        if (void 0 === c && 1 === a.nodeType) {
            var d = "data-" + b.replace(za, "-$1").toLowerCase();
            if (c = a.getAttribute(d), "string" == typeof c) {
                try {
                    c = "true" === c ? !0 : "false" === c ? !1 : "null" === c ? null : +c + "" === c ? +c : ya.test(c) ? ea.parseJSON(c) : c;
                } catch (e) {}
                ea.data(a, b, c);
            } else c = void 0;
        }
        return c;
    }
    function j(a) {
        var b;
        for (b in a) if (("data" !== b || !ea.isEmptyObject(a[b])) && "toJSON" !== b) return !1;
        return !0;
    }
    function k(a, b, c, d) {
        if (ea.acceptData(a)) {
            var e, f, g = ea.expando, h = a.nodeType, i = h ? ea.cache : a, j = h ? a[g] : a[g] && g;
            if (j && i[j] && (d || i[j].data) || void 0 !== c || "string" != typeof b) return j || (j = h ? a[g] = W.pop() || ea.guid++ : g), 
            i[j] || (i[j] = h ? {} : {
                toJSON: ea.noop
            }), ("object" == typeof b || "function" == typeof b) && (d ? i[j] = ea.extend(i[j], b) : i[j].data = ea.extend(i[j].data, b)), 
            f = i[j], d || (f.data || (f.data = {}), f = f.data), void 0 !== c && (f[ea.camelCase(b)] = c), 
            "string" == typeof b ? (e = f[b], null == e && (e = f[ea.camelCase(b)])) : e = f, 
            e;
        }
    }
    function l(a, b, c) {
        if (ea.acceptData(a)) {
            var d, e, f = a.nodeType, g = f ? ea.cache : a, h = f ? a[ea.expando] : ea.expando;
            if (g[h]) {
                if (b && (d = c ? g[h] : g[h].data)) {
                    ea.isArray(b) ? b = b.concat(ea.map(b, ea.camelCase)) : b in d ? b = [ b ] : (b = ea.camelCase(b), 
                    b = b in d ? [ b ] : b.split(" ")), e = b.length;
                    for (;e--; ) delete d[b[e]];
                    if (c ? !j(d) : !ea.isEmptyObject(d)) return;
                }
                (c || (delete g[h].data, j(g[h]))) && (f ? ea.cleanData([ a ], !0) : ca.deleteExpando || g != g.window ? delete g[h] : g[h] = null);
            }
        }
    }
    function m() {
        return !0;
    }
    function n() {
        return !1;
    }
    function o() {
        try {
            return oa.activeElement;
        } catch (a) {}
    }
    function p(a) {
        var b = Ka.split("|"), c = a.createDocumentFragment();
        if (c.createElement) for (;b.length; ) c.createElement(b.pop());
        return c;
    }
    function q(a, b) {
        var c, d, e = 0, f = typeof a.getElementsByTagName !== xa ? a.getElementsByTagName(b || "*") : typeof a.querySelectorAll !== xa ? a.querySelectorAll(b || "*") : void 0;
        if (!f) for (f = [], c = a.childNodes || a; null != (d = c[e]); e++) !b || ea.nodeName(d, b) ? f.push(d) : ea.merge(f, q(d, b));
        return void 0 === b || b && ea.nodeName(a, b) ? ea.merge([ a ], f) : f;
    }
    function r(a) {
        Ea.test(a.type) && (a.defaultChecked = a.checked);
    }
    function s(a, b) {
        return ea.nodeName(a, "table") && ea.nodeName(11 !== b.nodeType ? b : b.firstChild, "tr") ? a.getElementsByTagName("tbody")[0] || a.appendChild(a.ownerDocument.createElement("tbody")) : a;
    }
    function t(a) {
        return a.type = (null !== ea.find.attr(a, "type")) + "/" + a.type, a;
    }
    function u(a) {
        var b = Va.exec(a.type);
        return b ? a.type = b[1] : a.removeAttribute("type"), a;
    }
    function v(a, b) {
        for (var c, d = 0; null != (c = a[d]); d++) ea._data(c, "globalEval", !b || ea._data(b[d], "globalEval"));
    }
    function w(a, b) {
        if (1 === b.nodeType && ea.hasData(a)) {
            var c, d, e, f = ea._data(a), g = ea._data(b, f), h = f.events;
            if (h) {
                delete g.handle, g.events = {};
                for (c in h) for (d = 0, e = h[c].length; e > d; d++) ea.event.add(b, c, h[c][d]);
            }
            g.data && (g.data = ea.extend({}, g.data));
        }
    }
    function x(a, b) {
        var c, d, e;
        if (1 === b.nodeType) {
            if (c = b.nodeName.toLowerCase(), !ca.noCloneEvent && b[ea.expando]) {
                e = ea._data(b);
                for (d in e.events) ea.removeEvent(b, d, e.handle);
                b.removeAttribute(ea.expando);
            }
            "script" === c && b.text !== a.text ? (t(b).text = a.text, u(b)) : "object" === c ? (b.parentNode && (b.outerHTML = a.outerHTML), 
            ca.html5Clone && a.innerHTML && !ea.trim(b.innerHTML) && (b.innerHTML = a.innerHTML)) : "input" === c && Ea.test(a.type) ? (b.defaultChecked = b.checked = a.checked, 
            b.value !== a.value && (b.value = a.value)) : "option" === c ? b.defaultSelected = b.selected = a.defaultSelected : ("input" === c || "textarea" === c) && (b.defaultValue = a.defaultValue);
        }
    }
    function y(b, c) {
        var d, e = ea(c.createElement(b)).appendTo(c.body), f = a.getDefaultComputedStyle && (d = a.getDefaultComputedStyle(e[0])) ? d.display : ea.css(e[0], "display");
        return e.detach(), f;
    }
    function z(a) {
        var b = oa, c = _a[a];
        return c || (c = y(a, b), "none" !== c && c || ($a = ($a || ea("<iframe frameborder='0' width='0' height='0'/>")).appendTo(b.documentElement), 
        b = ($a[0].contentWindow || $a[0].contentDocument).document, b.write(), b.close(), 
        c = y(a, b), $a.detach()), _a[a] = c), c;
    }
    function A(a, b) {
        return {
            get: function() {
                var c = a();
                if (null != c) return c ? void delete this.get : (this.get = b).apply(this, arguments);
            }
        };
    }
    function B(a, b) {
        if (b in a) return b;
        for (var c = b.charAt(0).toUpperCase() + b.slice(1), d = b, e = mb.length; e--; ) if (b = mb[e] + c, 
        b in a) return b;
        return d;
    }
    function C(a, b) {
        for (var c, d, e, f = [], g = 0, h = a.length; h > g; g++) d = a[g], d.style && (f[g] = ea._data(d, "olddisplay"), 
        c = d.style.display, b ? (f[g] || "none" !== c || (d.style.display = ""), "" === d.style.display && Ca(d) && (f[g] = ea._data(d, "olddisplay", z(d.nodeName)))) : (e = Ca(d), 
        (c && "none" !== c || !e) && ea._data(d, "olddisplay", e ? c : ea.css(d, "display"))));
        for (g = 0; h > g; g++) d = a[g], d.style && (b && "none" !== d.style.display && "" !== d.style.display || (d.style.display = b ? f[g] || "" : "none"));
        return a;
    }
    function D(a, b, c) {
        var d = ib.exec(b);
        return d ? Math.max(0, d[1] - (c || 0)) + (d[2] || "px") : b;
    }
    function E(a, b, c, d, e) {
        for (var f = c === (d ? "border" : "content") ? 4 : "width" === b ? 1 : 0, g = 0; 4 > f; f += 2) "margin" === c && (g += ea.css(a, c + Ba[f], !0, e)), 
        d ? ("content" === c && (g -= ea.css(a, "padding" + Ba[f], !0, e)), "margin" !== c && (g -= ea.css(a, "border" + Ba[f] + "Width", !0, e))) : (g += ea.css(a, "padding" + Ba[f], !0, e), 
        "padding" !== c && (g += ea.css(a, "border" + Ba[f] + "Width", !0, e)));
        return g;
    }
    function F(a, b, c) {
        var d = !0, e = "width" === b ? a.offsetWidth : a.offsetHeight, f = ab(a), g = ca.boxSizing && "border-box" === ea.css(a, "boxSizing", !1, f);
        if (0 >= e || null == e) {
            if (e = bb(a, b, f), (0 > e || null == e) && (e = a.style[b]), db.test(e)) return e;
            d = g && (ca.boxSizingReliable() || e === a.style[b]), e = parseFloat(e) || 0;
        }
        return e + E(a, b, c || (g ? "border" : "content"), d, f) + "px";
    }
    function G(a, b, c, d, e) {
        return new G.prototype.init(a, b, c, d, e);
    }
    function H() {
        return setTimeout(function() {
            nb = void 0;
        }), nb = ea.now();
    }
    function I(a, b) {
        var c, d = {
            height: a
        }, e = 0;
        for (b = b ? 1 : 0; 4 > e; e += 2 - b) c = Ba[e], d["margin" + c] = d["padding" + c] = a;
        return b && (d.opacity = d.width = a), d;
    }
    function J(a, b, c) {
        for (var d, e = (tb[b] || []).concat(tb["*"]), f = 0, g = e.length; g > f; f++) if (d = e[f].call(c, b, a)) return d;
    }
    function K(a, b, c) {
        var d, e, f, g, h, i, j, k, l = this, m = {}, n = a.style, o = a.nodeType && Ca(a), p = ea._data(a, "fxshow");
        c.queue || (h = ea._queueHooks(a, "fx"), null == h.unqueued && (h.unqueued = 0, 
        i = h.empty.fire, h.empty.fire = function() {
            h.unqueued || i();
        }), h.unqueued++, l.always(function() {
            l.always(function() {
                h.unqueued--, ea.queue(a, "fx").length || h.empty.fire();
            });
        })), 1 === a.nodeType && ("height" in b || "width" in b) && (c.overflow = [ n.overflow, n.overflowX, n.overflowY ], 
        j = ea.css(a, "display"), k = "none" === j ? ea._data(a, "olddisplay") || z(a.nodeName) : j, 
        "inline" === k && "none" === ea.css(a, "float") && (ca.inlineBlockNeedsLayout && "inline" !== z(a.nodeName) ? n.zoom = 1 : n.display = "inline-block")), 
        c.overflow && (n.overflow = "hidden", ca.shrinkWrapBlocks() || l.always(function() {
            n.overflow = c.overflow[0], n.overflowX = c.overflow[1], n.overflowY = c.overflow[2];
        }));
        for (d in b) if (e = b[d], pb.exec(e)) {
            if (delete b[d], f = f || "toggle" === e, e === (o ? "hide" : "show")) {
                if ("show" !== e || !p || void 0 === p[d]) continue;
                o = !0;
            }
            m[d] = p && p[d] || ea.style(a, d);
        } else j = void 0;
        if (ea.isEmptyObject(m)) "inline" === ("none" === j ? z(a.nodeName) : j) && (n.display = j); else {
            p ? "hidden" in p && (o = p.hidden) : p = ea._data(a, "fxshow", {}), f && (p.hidden = !o), 
            o ? ea(a).show() : l.done(function() {
                ea(a).hide();
            }), l.done(function() {
                var b;
                ea._removeData(a, "fxshow");
                for (b in m) ea.style(a, b, m[b]);
            });
            for (d in m) g = J(o ? p[d] : 0, d, l), d in p || (p[d] = g.start, o && (g.end = g.start, 
            g.start = "width" === d || "height" === d ? 1 : 0));
        }
    }
    function L(a, b) {
        var c, d, e, f, g;
        for (c in a) if (d = ea.camelCase(c), e = b[d], f = a[c], ea.isArray(f) && (e = f[1], 
        f = a[c] = f[0]), c !== d && (a[d] = f, delete a[c]), g = ea.cssHooks[d], g && "expand" in g) {
            f = g.expand(f), delete a[d];
            for (c in f) c in a || (a[c] = f[c], b[c] = e);
        } else b[d] = e;
    }
    function M(a, b, c) {
        var d, e, f = 0, g = sb.length, h = ea.Deferred().always(function() {
            delete i.elem;
        }), i = function() {
            if (e) return !1;
            for (var b = nb || H(), c = Math.max(0, j.startTime + j.duration - b), d = c / j.duration || 0, f = 1 - d, g = 0, i = j.tweens.length; i > g; g++) j.tweens[g].run(f);
            return h.notifyWith(a, [ j, f, c ]), 1 > f && i ? c : (h.resolveWith(a, [ j ]), 
            !1);
        }, j = h.promise({
            elem: a,
            props: ea.extend({}, b),
            opts: ea.extend(!0, {
                specialEasing: {}
            }, c),
            originalProperties: b,
            originalOptions: c,
            startTime: nb || H(),
            duration: c.duration,
            tweens: [],
            createTween: function(b, c) {
                var d = ea.Tween(a, j.opts, b, c, j.opts.specialEasing[b] || j.opts.easing);
                return j.tweens.push(d), d;
            },
            stop: function(b) {
                var c = 0, d = b ? j.tweens.length : 0;
                if (e) return this;
                for (e = !0; d > c; c++) j.tweens[c].run(1);
                return b ? h.resolveWith(a, [ j, b ]) : h.rejectWith(a, [ j, b ]), this;
            }
        }), k = j.props;
        for (L(k, j.opts.specialEasing); g > f; f++) if (d = sb[f].call(j, a, k, j.opts)) return d;
        return ea.map(k, J, j), ea.isFunction(j.opts.start) && j.opts.start.call(a, j), 
        ea.fx.timer(ea.extend(i, {
            elem: a,
            anim: j,
            queue: j.opts.queue
        })), j.progress(j.opts.progress).done(j.opts.done, j.opts.complete).fail(j.opts.fail).always(j.opts.always);
    }
    function N(a) {
        return function(b, c) {
            "string" != typeof b && (c = b, b = "*");
            var d, e = 0, f = b.toLowerCase().match(ta) || [];
            if (ea.isFunction(c)) for (;d = f[e++]; ) "+" === d.charAt(0) ? (d = d.slice(1) || "*", 
            (a[d] = a[d] || []).unshift(c)) : (a[d] = a[d] || []).push(c);
        };
    }
    function O(a, b, c, d) {
        function e(h) {
            var i;
            return f[h] = !0, ea.each(a[h] || [], function(a, h) {
                var j = h(b, c, d);
                return "string" != typeof j || g || f[j] ? g ? !(i = j) : void 0 : (b.dataTypes.unshift(j), 
                e(j), !1);
            }), i;
        }
        var f = {}, g = a === Rb;
        return e(b.dataTypes[0]) || !f["*"] && e("*");
    }
    function P(a, b) {
        var c, d, e = ea.ajaxSettings.flatOptions || {};
        for (d in b) void 0 !== b[d] && ((e[d] ? a : c || (c = {}))[d] = b[d]);
        return c && ea.extend(!0, a, c), a;
    }
    function Q(a, b, c) {
        for (var d, e, f, g, h = a.contents, i = a.dataTypes; "*" === i[0]; ) i.shift(), 
        void 0 === e && (e = a.mimeType || b.getResponseHeader("Content-Type"));
        if (e) for (g in h) if (h[g] && h[g].test(e)) {
            i.unshift(g);
            break;
        }
        if (i[0] in c) f = i[0]; else {
            for (g in c) {
                if (!i[0] || a.converters[g + " " + i[0]]) {
                    f = g;
                    break;
                }
                d || (d = g);
            }
            f = f || d;
        }
        return f ? (f !== i[0] && i.unshift(f), c[f]) : void 0;
    }
    function R(a, b, c, d) {
        var e, f, g, h, i, j = {}, k = a.dataTypes.slice();
        if (k[1]) for (g in a.converters) j[g.toLowerCase()] = a.converters[g];
        for (f = k.shift(); f; ) if (a.responseFields[f] && (c[a.responseFields[f]] = b), 
        !i && d && a.dataFilter && (b = a.dataFilter(b, a.dataType)), i = f, f = k.shift()) if ("*" === f) f = i; else if ("*" !== i && i !== f) {
            if (g = j[i + " " + f] || j["* " + f], !g) for (e in j) if (h = e.split(" "), h[1] === f && (g = j[i + " " + h[0]] || j["* " + h[0]])) {
                g === !0 ? g = j[e] : j[e] !== !0 && (f = h[0], k.unshift(h[1]));
                break;
            }
            if (g !== !0) if (g && a["throws"]) b = g(b); else try {
                b = g(b);
            } catch (l) {
                return {
                    state: "parsererror",
                    error: g ? l : "No conversion from " + i + " to " + f
                };
            }
        }
        return {
            state: "success",
            data: b
        };
    }
    function S(a, b, c, d) {
        var e;
        if (ea.isArray(b)) ea.each(b, function(b, e) {
            c || Vb.test(a) ? d(a, e) : S(a + "[" + ("object" == typeof e ? b : "") + "]", e, c, d);
        }); else if (c || "object" !== ea.type(b)) d(a, b); else for (e in b) S(a + "[" + e + "]", b[e], c, d);
    }
    function T() {
        try {
            return new a.XMLHttpRequest();
        } catch (b) {}
    }
    function U() {
        try {
            return new a.ActiveXObject("Microsoft.XMLHTTP");
        } catch (b) {}
    }
    function V(a) {
        return ea.isWindow(a) ? a : 9 === a.nodeType ? a.defaultView || a.parentWindow : !1;
    }
    var W = [], X = W.slice, Y = W.concat, Z = W.push, $ = W.indexOf, _ = {}, aa = _.toString, ba = _.hasOwnProperty, ca = {}, da = "1.11.3", ea = function(a, b) {
        return new ea.fn.init(a, b);
    }, fa = /^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, ga = /^-ms-/, ha = /-([\da-z])/gi, ia = function(a, b) {
        return b.toUpperCase();
    };
    ea.fn = ea.prototype = {
        jquery: da,
        constructor: ea,
        selector: "",
        length: 0,
        toArray: function() {
            return X.call(this);
        },
        get: function(a) {
            return null != a ? 0 > a ? this[a + this.length] : this[a] : X.call(this);
        },
        pushStack: function(a) {
            var b = ea.merge(this.constructor(), a);
            return b.prevObject = this, b.context = this.context, b;
        },
        each: function(a, b) {
            return ea.each(this, a, b);
        },
        map: function(a) {
            return this.pushStack(ea.map(this, function(b, c) {
                return a.call(b, c, b);
            }));
        },
        slice: function() {
            return this.pushStack(X.apply(this, arguments));
        },
        first: function() {
            return this.eq(0);
        },
        last: function() {
            return this.eq(-1);
        },
        eq: function(a) {
            var b = this.length, c = +a + (0 > a ? b : 0);
            return this.pushStack(c >= 0 && b > c ? [ this[c] ] : []);
        },
        end: function() {
            return this.prevObject || this.constructor(null);
        },
        push: Z,
        sort: W.sort,
        splice: W.splice
    }, ea.extend = ea.fn.extend = function() {
        var a, b, c, d, e, f, g = arguments[0] || {}, h = 1, i = arguments.length, j = !1;
        for ("boolean" == typeof g && (j = g, g = arguments[h] || {}, h++), "object" == typeof g || ea.isFunction(g) || (g = {}), 
        h === i && (g = this, h--); i > h; h++) if (null != (e = arguments[h])) for (d in e) a = g[d], 
        c = e[d], g !== c && (j && c && (ea.isPlainObject(c) || (b = ea.isArray(c))) ? (b ? (b = !1, 
        f = a && ea.isArray(a) ? a : []) : f = a && ea.isPlainObject(a) ? a : {}, g[d] = ea.extend(j, f, c)) : void 0 !== c && (g[d] = c));
        return g;
    }, ea.extend({
        expando: "jQuery" + (da + Math.random()).replace(/\D/g, ""),
        isReady: !0,
        error: function(a) {
            throw new Error(a);
        },
        noop: function() {},
        isFunction: function(a) {
            return "function" === ea.type(a);
        },
        isArray: Array.isArray || function(a) {
            return "array" === ea.type(a);
        },
        isWindow: function(a) {
            return null != a && a == a.window;
        },
        isNumeric: function(a) {
            return !ea.isArray(a) && a - parseFloat(a) + 1 >= 0;
        },
        isEmptyObject: function(a) {
            var b;
            for (b in a) return !1;
            return !0;
        },
        isPlainObject: function(a) {
            var b;
            if (!a || "object" !== ea.type(a) || a.nodeType || ea.isWindow(a)) return !1;
            try {
                if (a.constructor && !ba.call(a, "constructor") && !ba.call(a.constructor.prototype, "isPrototypeOf")) return !1;
            } catch (c) {
                return !1;
            }
            if (ca.ownLast) for (b in a) return ba.call(a, b);
            for (b in a) ;
            return void 0 === b || ba.call(a, b);
        },
        type: function(a) {
            return null == a ? a + "" : "object" == typeof a || "function" == typeof a ? _[aa.call(a)] || "object" : typeof a;
        },
        globalEval: function(b) {
            b && ea.trim(b) && (a.execScript || function(b) {
                a.eval.call(a, b);
            })(b);
        },
        camelCase: function(a) {
            return a.replace(ga, "ms-").replace(ha, ia);
        },
        nodeName: function(a, b) {
            return a.nodeName && a.nodeName.toLowerCase() === b.toLowerCase();
        },
        each: function(a, b, d) {
            var e, f = 0, g = a.length, h = c(a);
            if (d) {
                if (h) for (;g > f && (e = b.apply(a[f], d), e !== !1); f++) ; else for (f in a) if (e = b.apply(a[f], d), 
                e === !1) break;
            } else if (h) for (;g > f && (e = b.call(a[f], f, a[f]), e !== !1); f++) ; else for (f in a) if (e = b.call(a[f], f, a[f]), 
            e === !1) break;
            return a;
        },
        trim: function(a) {
            return null == a ? "" : (a + "").replace(fa, "");
        },
        makeArray: function(a, b) {
            var d = b || [];
            return null != a && (c(Object(a)) ? ea.merge(d, "string" == typeof a ? [ a ] : a) : Z.call(d, a)), 
            d;
        },
        inArray: function(a, b, c) {
            var d;
            if (b) {
                if ($) return $.call(b, a, c);
                for (d = b.length, c = c ? 0 > c ? Math.max(0, d + c) : c : 0; d > c; c++) if (c in b && b[c] === a) return c;
            }
            return -1;
        },
        merge: function(a, b) {
            for (var c = +b.length, d = 0, e = a.length; c > d; ) a[e++] = b[d++];
            if (c !== c) for (;void 0 !== b[d]; ) a[e++] = b[d++];
            return a.length = e, a;
        },
        grep: function(a, b, c) {
            for (var d, e = [], f = 0, g = a.length, h = !c; g > f; f++) d = !b(a[f], f), d !== h && e.push(a[f]);
            return e;
        },
        map: function(a, b, d) {
            var e, f = 0, g = a.length, h = c(a), i = [];
            if (h) for (;g > f; f++) e = b(a[f], f, d), null != e && i.push(e); else for (f in a) e = b(a[f], f, d), 
            null != e && i.push(e);
            return Y.apply([], i);
        },
        guid: 1,
        proxy: function(a, b) {
            var c, d, e;
            return "string" == typeof b && (e = a[b], b = a, a = e), ea.isFunction(a) ? (c = X.call(arguments, 2), 
            d = function() {
                return a.apply(b || this, c.concat(X.call(arguments)));
            }, d.guid = a.guid = a.guid || ea.guid++, d) : void 0;
        },
        now: function() {
            return +new Date();
        },
        support: ca
    }), ea.each("Boolean Number String Function Array Date RegExp Object Error".split(" "), function(a, b) {
        _["[object " + b + "]"] = b.toLowerCase();
    });
    var ja = function(a) {
        function b(a, b, c, d) {
            var e, f, g, h, i, j, l, n, o, p;
            if ((b ? b.ownerDocument || b : O) !== G && F(b), b = b || G, c = c || [], h = b.nodeType, 
            "string" != typeof a || !a || 1 !== h && 9 !== h && 11 !== h) return c;
            if (!d && I) {
                if (11 !== h && (e = sa.exec(a))) if (g = e[1]) {
                    if (9 === h) {
                        if (f = b.getElementById(g), !f || !f.parentNode) return c;
                        if (f.id === g) return c.push(f), c;
                    } else if (b.ownerDocument && (f = b.ownerDocument.getElementById(g)) && M(b, f) && f.id === g) return c.push(f), 
                    c;
                } else {
                    if (e[2]) return $.apply(c, b.getElementsByTagName(a)), c;
                    if ((g = e[3]) && v.getElementsByClassName) return $.apply(c, b.getElementsByClassName(g)), 
                    c;
                }
                if (v.qsa && (!J || !J.test(a))) {
                    if (n = l = N, o = b, p = 1 !== h && a, 1 === h && "object" !== b.nodeName.toLowerCase()) {
                        for (j = z(a), (l = b.getAttribute("id")) ? n = l.replace(ua, "\\$&") : b.setAttribute("id", n), 
                        n = "[id='" + n + "'] ", i = j.length; i--; ) j[i] = n + m(j[i]);
                        o = ta.test(a) && k(b.parentNode) || b, p = j.join(",");
                    }
                    if (p) try {
                        return $.apply(c, o.querySelectorAll(p)), c;
                    } catch (q) {} finally {
                        l || b.removeAttribute("id");
                    }
                }
            }
            return B(a.replace(ia, "$1"), b, c, d);
        }
        function c() {
            function a(c, d) {
                return b.push(c + " ") > w.cacheLength && delete a[b.shift()], a[c + " "] = d;
            }
            var b = [];
            return a;
        }
        function d(a) {
            return a[N] = !0, a;
        }
        function e(a) {
            var b = G.createElement("div");
            try {
                return !!a(b);
            } catch (c) {
                return !1;
            } finally {
                b.parentNode && b.parentNode.removeChild(b), b = null;
            }
        }
        function f(a, b) {
            for (var c = a.split("|"), d = a.length; d--; ) w.attrHandle[c[d]] = b;
        }
        function g(a, b) {
            var c = b && a, d = c && 1 === a.nodeType && 1 === b.nodeType && (~b.sourceIndex || V) - (~a.sourceIndex || V);
            if (d) return d;
            if (c) for (;c = c.nextSibling; ) if (c === b) return -1;
            return a ? 1 : -1;
        }
        function h(a) {
            return function(b) {
                var c = b.nodeName.toLowerCase();
                return "input" === c && b.type === a;
            };
        }
        function i(a) {
            return function(b) {
                var c = b.nodeName.toLowerCase();
                return ("input" === c || "button" === c) && b.type === a;
            };
        }
        function j(a) {
            return d(function(b) {
                return b = +b, d(function(c, d) {
                    for (var e, f = a([], c.length, b), g = f.length; g--; ) c[e = f[g]] && (c[e] = !(d[e] = c[e]));
                });
            });
        }
        function k(a) {
            return a && "undefined" != typeof a.getElementsByTagName && a;
        }
        function l() {}
        function m(a) {
            for (var b = 0, c = a.length, d = ""; c > b; b++) d += a[b].value;
            return d;
        }
        function n(a, b, c) {
            var d = b.dir, e = c && "parentNode" === d, f = Q++;
            return b.first ? function(b, c, f) {
                for (;b = b[d]; ) if (1 === b.nodeType || e) return a(b, c, f);
            } : function(b, c, g) {
                var h, i, j = [ P, f ];
                if (g) {
                    for (;b = b[d]; ) if ((1 === b.nodeType || e) && a(b, c, g)) return !0;
                } else for (;b = b[d]; ) if (1 === b.nodeType || e) {
                    if (i = b[N] || (b[N] = {}), (h = i[d]) && h[0] === P && h[1] === f) return j[2] = h[2];
                    if (i[d] = j, j[2] = a(b, c, g)) return !0;
                }
            };
        }
        function o(a) {
            return a.length > 1 ? function(b, c, d) {
                for (var e = a.length; e--; ) if (!a[e](b, c, d)) return !1;
                return !0;
            } : a[0];
        }
        function p(a, c, d) {
            for (var e = 0, f = c.length; f > e; e++) b(a, c[e], d);
            return d;
        }
        function q(a, b, c, d, e) {
            for (var f, g = [], h = 0, i = a.length, j = null != b; i > h; h++) (f = a[h]) && (!c || c(f, d, e)) && (g.push(f), 
            j && b.push(h));
            return g;
        }
        function r(a, b, c, e, f, g) {
            return e && !e[N] && (e = r(e)), f && !f[N] && (f = r(f, g)), d(function(d, g, h, i) {
                var j, k, l, m = [], n = [], o = g.length, r = d || p(b || "*", h.nodeType ? [ h ] : h, []), s = !a || !d && b ? r : q(r, m, a, h, i), t = c ? f || (d ? a : o || e) ? [] : g : s;
                if (c && c(s, t, h, i), e) for (j = q(t, n), e(j, [], h, i), k = j.length; k--; ) (l = j[k]) && (t[n[k]] = !(s[n[k]] = l));
                if (d) {
                    if (f || a) {
                        if (f) {
                            for (j = [], k = t.length; k--; ) (l = t[k]) && j.push(s[k] = l);
                            f(null, t = [], j, i);
                        }
                        for (k = t.length; k--; ) (l = t[k]) && (j = f ? aa(d, l) : m[k]) > -1 && (d[j] = !(g[j] = l));
                    }
                } else t = q(t === g ? t.splice(o, t.length) : t), f ? f(null, g, t, i) : $.apply(g, t);
            });
        }
        function s(a) {
            for (var b, c, d, e = a.length, f = w.relative[a[0].type], g = f || w.relative[" "], h = f ? 1 : 0, i = n(function(a) {
                return a === b;
            }, g, !0), j = n(function(a) {
                return aa(b, a) > -1;
            }, g, !0), k = [ function(a, c, d) {
                var e = !f && (d || c !== C) || ((b = c).nodeType ? i(a, c, d) : j(a, c, d));
                return b = null, e;
            } ]; e > h; h++) if (c = w.relative[a[h].type]) k = [ n(o(k), c) ]; else {
                if (c = w.filter[a[h].type].apply(null, a[h].matches), c[N]) {
                    for (d = ++h; e > d && !w.relative[a[d].type]; d++) ;
                    return r(h > 1 && o(k), h > 1 && m(a.slice(0, h - 1).concat({
                        value: " " === a[h - 2].type ? "*" : ""
                    })).replace(ia, "$1"), c, d > h && s(a.slice(h, d)), e > d && s(a = a.slice(d)), e > d && m(a));
                }
                k.push(c);
            }
            return o(k);
        }
        function t(a, c) {
            var e = c.length > 0, f = a.length > 0, g = function(d, g, h, i, j) {
                var k, l, m, n = 0, o = "0", p = d && [], r = [], s = C, t = d || f && w.find.TAG("*", j), u = P += null == s ? 1 : Math.random() || .1, v = t.length;
                for (j && (C = g !== G && g); o !== v && null != (k = t[o]); o++) {
                    if (f && k) {
                        for (l = 0; m = a[l++]; ) if (m(k, g, h)) {
                            i.push(k);
                            break;
                        }
                        j && (P = u);
                    }
                    e && ((k = !m && k) && n--, d && p.push(k));
                }
                if (n += o, e && o !== n) {
                    for (l = 0; m = c[l++]; ) m(p, r, g, h);
                    if (d) {
                        if (n > 0) for (;o--; ) p[o] || r[o] || (r[o] = Y.call(i));
                        r = q(r);
                    }
                    $.apply(i, r), j && !d && r.length > 0 && n + c.length > 1 && b.uniqueSort(i);
                }
                return j && (P = u, C = s), p;
            };
            return e ? d(g) : g;
        }
        var u, v, w, x, y, z, A, B, C, D, E, F, G, H, I, J, K, L, M, N = "sizzle" + 1 * new Date(), O = a.document, P = 0, Q = 0, R = c(), S = c(), T = c(), U = function(a, b) {
            return a === b && (E = !0), 0;
        }, V = 1 << 31, W = {}.hasOwnProperty, X = [], Y = X.pop, Z = X.push, $ = X.push, _ = X.slice, aa = function(a, b) {
            for (var c = 0, d = a.length; d > c; c++) if (a[c] === b) return c;
            return -1;
        }, ba = "checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped", ca = "[\\x20\\t\\r\\n\\f]", da = "(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+", ea = da.replace("w", "w#"), fa = "\\[" + ca + "*(" + da + ")(?:" + ca + "*([*^$|!~]?=)" + ca + "*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|(" + ea + "))|)" + ca + "*\\]", ga = ":(" + da + ")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|" + fa + ")*)|.*)\\)|)", ha = new RegExp(ca + "+", "g"), ia = new RegExp("^" + ca + "+|((?:^|[^\\\\])(?:\\\\.)*)" + ca + "+$", "g"), ja = new RegExp("^" + ca + "*," + ca + "*"), ka = new RegExp("^" + ca + "*([>+~]|" + ca + ")" + ca + "*"), la = new RegExp("=" + ca + "*([^\\]'\"]*?)" + ca + "*\\]", "g"), ma = new RegExp(ga), na = new RegExp("^" + ea + "$"), oa = {
            ID: new RegExp("^#(" + da + ")"),
            CLASS: new RegExp("^\\.(" + da + ")"),
            TAG: new RegExp("^(" + da.replace("w", "w*") + ")"),
            ATTR: new RegExp("^" + fa),
            PSEUDO: new RegExp("^" + ga),
            CHILD: new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\(" + ca + "*(even|odd|(([+-]|)(\\d*)n|)" + ca + "*(?:([+-]|)" + ca + "*(\\d+)|))" + ca + "*\\)|)", "i"),
            bool: new RegExp("^(?:" + ba + ")$", "i"),
            needsContext: new RegExp("^" + ca + "*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\(" + ca + "*((?:-\\d)?\\d*)" + ca + "*\\)|)(?=[^-]|$)", "i")
        }, pa = /^(?:input|select|textarea|button)$/i, qa = /^h\d$/i, ra = /^[^{]+\{\s*\[native \w/, sa = /^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/, ta = /[+~]/, ua = /'|\\/g, va = new RegExp("\\\\([\\da-f]{1,6}" + ca + "?|(" + ca + ")|.)", "ig"), wa = function(a, b, c) {
            var d = "0x" + b - 65536;
            return d !== d || c ? b : 0 > d ? String.fromCharCode(d + 65536) : String.fromCharCode(d >> 10 | 55296, 1023 & d | 56320);
        }, xa = function() {
            F();
        };
        try {
            $.apply(X = _.call(O.childNodes), O.childNodes), X[O.childNodes.length].nodeType;
        } catch (ya) {
            $ = {
                apply: X.length ? function(a, b) {
                    Z.apply(a, _.call(b));
                } : function(a, b) {
                    for (var c = a.length, d = 0; a[c++] = b[d++]; ) ;
                    a.length = c - 1;
                }
            };
        }
        v = b.support = {}, y = b.isXML = function(a) {
            var b = a && (a.ownerDocument || a).documentElement;
            return b ? "HTML" !== b.nodeName : !1;
        }, F = b.setDocument = function(a) {
            var b, c, d = a ? a.ownerDocument || a : O;
            return d !== G && 9 === d.nodeType && d.documentElement ? (G = d, H = d.documentElement, 
            c = d.defaultView, c && c !== c.top && (c.addEventListener ? c.addEventListener("unload", xa, !1) : c.attachEvent && c.attachEvent("onunload", xa)), 
            I = !y(d), v.attributes = e(function(a) {
                return a.className = "i", !a.getAttribute("className");
            }), v.getElementsByTagName = e(function(a) {
                return a.appendChild(d.createComment("")), !a.getElementsByTagName("*").length;
            }), v.getElementsByClassName = ra.test(d.getElementsByClassName), v.getById = e(function(a) {
                return H.appendChild(a).id = N, !d.getElementsByName || !d.getElementsByName(N).length;
            }), v.getById ? (w.find.ID = function(a, b) {
                if ("undefined" != typeof b.getElementById && I) {
                    var c = b.getElementById(a);
                    return c && c.parentNode ? [ c ] : [];
                }
            }, w.filter.ID = function(a) {
                var b = a.replace(va, wa);
                return function(a) {
                    return a.getAttribute("id") === b;
                };
            }) : (delete w.find.ID, w.filter.ID = function(a) {
                var b = a.replace(va, wa);
                return function(a) {
                    var c = "undefined" != typeof a.getAttributeNode && a.getAttributeNode("id");
                    return c && c.value === b;
                };
            }), w.find.TAG = v.getElementsByTagName ? function(a, b) {
                return "undefined" != typeof b.getElementsByTagName ? b.getElementsByTagName(a) : v.qsa ? b.querySelectorAll(a) : void 0;
            } : function(a, b) {
                var c, d = [], e = 0, f = b.getElementsByTagName(a);
                if ("*" === a) {
                    for (;c = f[e++]; ) 1 === c.nodeType && d.push(c);
                    return d;
                }
                return f;
            }, w.find.CLASS = v.getElementsByClassName && function(a, b) {
                return I ? b.getElementsByClassName(a) : void 0;
            }, K = [], J = [], (v.qsa = ra.test(d.querySelectorAll)) && (e(function(a) {
                H.appendChild(a).innerHTML = "<a id='" + N + "'></a><select id='" + N + "-\f]' msallowcapture=''><option selected=''></option></select>", 
                a.querySelectorAll("[msallowcapture^='']").length && J.push("[*^$]=" + ca + "*(?:''|\"\")"), 
                a.querySelectorAll("[selected]").length || J.push("\\[" + ca + "*(?:value|" + ba + ")"), 
                a.querySelectorAll("[id~=" + N + "-]").length || J.push("~="), a.querySelectorAll(":checked").length || J.push(":checked"), 
                a.querySelectorAll("a#" + N + "+*").length || J.push(".#.+[+~]");
            }), e(function(a) {
                var b = d.createElement("input");
                b.setAttribute("type", "hidden"), a.appendChild(b).setAttribute("name", "D"), a.querySelectorAll("[name=d]").length && J.push("name" + ca + "*[*^$|!~]?="), 
                a.querySelectorAll(":enabled").length || J.push(":enabled", ":disabled"), a.querySelectorAll("*,:x"), 
                J.push(",.*:");
            })), (v.matchesSelector = ra.test(L = H.matches || H.webkitMatchesSelector || H.mozMatchesSelector || H.oMatchesSelector || H.msMatchesSelector)) && e(function(a) {
                v.disconnectedMatch = L.call(a, "div"), L.call(a, "[s!='']:x"), K.push("!=", ga);
            }), J = J.length && new RegExp(J.join("|")), K = K.length && new RegExp(K.join("|")), 
            b = ra.test(H.compareDocumentPosition), M = b || ra.test(H.contains) ? function(a, b) {
                var c = 9 === a.nodeType ? a.documentElement : a, d = b && b.parentNode;
                return a === d || !(!d || 1 !== d.nodeType || !(c.contains ? c.contains(d) : a.compareDocumentPosition && 16 & a.compareDocumentPosition(d)));
            } : function(a, b) {
                if (b) for (;b = b.parentNode; ) if (b === a) return !0;
                return !1;
            }, U = b ? function(a, b) {
                if (a === b) return E = !0, 0;
                var c = !a.compareDocumentPosition - !b.compareDocumentPosition;
                return c ? c : (c = (a.ownerDocument || a) === (b.ownerDocument || b) ? a.compareDocumentPosition(b) : 1, 
                1 & c || !v.sortDetached && b.compareDocumentPosition(a) === c ? a === d || a.ownerDocument === O && M(O, a) ? -1 : b === d || b.ownerDocument === O && M(O, b) ? 1 : D ? aa(D, a) - aa(D, b) : 0 : 4 & c ? -1 : 1);
            } : function(a, b) {
                if (a === b) return E = !0, 0;
                var c, e = 0, f = a.parentNode, h = b.parentNode, i = [ a ], j = [ b ];
                if (!f || !h) return a === d ? -1 : b === d ? 1 : f ? -1 : h ? 1 : D ? aa(D, a) - aa(D, b) : 0;
                if (f === h) return g(a, b);
                for (c = a; c = c.parentNode; ) i.unshift(c);
                for (c = b; c = c.parentNode; ) j.unshift(c);
                for (;i[e] === j[e]; ) e++;
                return e ? g(i[e], j[e]) : i[e] === O ? -1 : j[e] === O ? 1 : 0;
            }, d) : G;
        }, b.matches = function(a, c) {
            return b(a, null, null, c);
        }, b.matchesSelector = function(a, c) {
            if ((a.ownerDocument || a) !== G && F(a), c = c.replace(la, "='$1']"), v.matchesSelector && I && (!K || !K.test(c)) && (!J || !J.test(c))) try {
                var d = L.call(a, c);
                if (d || v.disconnectedMatch || a.document && 11 !== a.document.nodeType) return d;
            } catch (e) {}
            return b(c, G, null, [ a ]).length > 0;
        }, b.contains = function(a, b) {
            return (a.ownerDocument || a) !== G && F(a), M(a, b);
        }, b.attr = function(a, b) {
            (a.ownerDocument || a) !== G && F(a);
            var c = w.attrHandle[b.toLowerCase()], d = c && W.call(w.attrHandle, b.toLowerCase()) ? c(a, b, !I) : void 0;
            return void 0 !== d ? d : v.attributes || !I ? a.getAttribute(b) : (d = a.getAttributeNode(b)) && d.specified ? d.value : null;
        }, b.error = function(a) {
            throw new Error("Syntax error, unrecognized expression: " + a);
        }, b.uniqueSort = function(a) {
            var b, c = [], d = 0, e = 0;
            if (E = !v.detectDuplicates, D = !v.sortStable && a.slice(0), a.sort(U), E) {
                for (;b = a[e++]; ) b === a[e] && (d = c.push(e));
                for (;d--; ) a.splice(c[d], 1);
            }
            return D = null, a;
        }, x = b.getText = function(a) {
            var b, c = "", d = 0, e = a.nodeType;
            if (e) {
                if (1 === e || 9 === e || 11 === e) {
                    if ("string" == typeof a.textContent) return a.textContent;
                    for (a = a.firstChild; a; a = a.nextSibling) c += x(a);
                } else if (3 === e || 4 === e) return a.nodeValue;
            } else for (;b = a[d++]; ) c += x(b);
            return c;
        }, w = b.selectors = {
            cacheLength: 50,
            createPseudo: d,
            match: oa,
            attrHandle: {},
            find: {},
            relative: {
                ">": {
                    dir: "parentNode",
                    first: !0
                },
                " ": {
                    dir: "parentNode"
                },
                "+": {
                    dir: "previousSibling",
                    first: !0
                },
                "~": {
                    dir: "previousSibling"
                }
            },
            preFilter: {
                ATTR: function(a) {
                    return a[1] = a[1].replace(va, wa), a[3] = (a[3] || a[4] || a[5] || "").replace(va, wa), 
                    "~=" === a[2] && (a[3] = " " + a[3] + " "), a.slice(0, 4);
                },
                CHILD: function(a) {
                    return a[1] = a[1].toLowerCase(), "nth" === a[1].slice(0, 3) ? (a[3] || b.error(a[0]), 
                    a[4] = +(a[4] ? a[5] + (a[6] || 1) : 2 * ("even" === a[3] || "odd" === a[3])), a[5] = +(a[7] + a[8] || "odd" === a[3])) : a[3] && b.error(a[0]), 
                    a;
                },
                PSEUDO: function(a) {
                    var b, c = !a[6] && a[2];
                    return oa.CHILD.test(a[0]) ? null : (a[3] ? a[2] = a[4] || a[5] || "" : c && ma.test(c) && (b = z(c, !0)) && (b = c.indexOf(")", c.length - b) - c.length) && (a[0] = a[0].slice(0, b), 
                    a[2] = c.slice(0, b)), a.slice(0, 3));
                }
            },
            filter: {
                TAG: function(a) {
                    var b = a.replace(va, wa).toLowerCase();
                    return "*" === a ? function() {
                        return !0;
                    } : function(a) {
                        return a.nodeName && a.nodeName.toLowerCase() === b;
                    };
                },
                CLASS: function(a) {
                    var b = R[a + " "];
                    return b || (b = new RegExp("(^|" + ca + ")" + a + "(" + ca + "|$)")) && R(a, function(a) {
                        return b.test("string" == typeof a.className && a.className || "undefined" != typeof a.getAttribute && a.getAttribute("class") || "");
                    });
                },
                ATTR: function(a, c, d) {
                    return function(e) {
                        var f = b.attr(e, a);
                        return null == f ? "!=" === c : c ? (f += "", "=" === c ? f === d : "!=" === c ? f !== d : "^=" === c ? d && 0 === f.indexOf(d) : "*=" === c ? d && f.indexOf(d) > -1 : "$=" === c ? d && f.slice(-d.length) === d : "~=" === c ? (" " + f.replace(ha, " ") + " ").indexOf(d) > -1 : "|=" === c ? f === d || f.slice(0, d.length + 1) === d + "-" : !1) : !0;
                    };
                },
                CHILD: function(a, b, c, d, e) {
                    var f = "nth" !== a.slice(0, 3), g = "last" !== a.slice(-4), h = "of-type" === b;
                    return 1 === d && 0 === e ? function(a) {
                        return !!a.parentNode;
                    } : function(b, c, i) {
                        var j, k, l, m, n, o, p = f !== g ? "nextSibling" : "previousSibling", q = b.parentNode, r = h && b.nodeName.toLowerCase(), s = !i && !h;
                        if (q) {
                            if (f) {
                                for (;p; ) {
                                    for (l = b; l = l[p]; ) if (h ? l.nodeName.toLowerCase() === r : 1 === l.nodeType) return !1;
                                    o = p = "only" === a && !o && "nextSibling";
                                }
                                return !0;
                            }
                            if (o = [ g ? q.firstChild : q.lastChild ], g && s) {
                                for (k = q[N] || (q[N] = {}), j = k[a] || [], n = j[0] === P && j[1], m = j[0] === P && j[2], 
                                l = n && q.childNodes[n]; l = ++n && l && l[p] || (m = n = 0) || o.pop(); ) if (1 === l.nodeType && ++m && l === b) {
                                    k[a] = [ P, n, m ];
                                    break;
                                }
                            } else if (s && (j = (b[N] || (b[N] = {}))[a]) && j[0] === P) m = j[1]; else for (;(l = ++n && l && l[p] || (m = n = 0) || o.pop()) && ((h ? l.nodeName.toLowerCase() !== r : 1 !== l.nodeType) || !++m || (s && ((l[N] || (l[N] = {}))[a] = [ P, m ]), 
                            l !== b)); ) ;
                            return m -= e, m === d || m % d === 0 && m / d >= 0;
                        }
                    };
                },
                PSEUDO: function(a, c) {
                    var e, f = w.pseudos[a] || w.setFilters[a.toLowerCase()] || b.error("unsupported pseudo: " + a);
                    return f[N] ? f(c) : f.length > 1 ? (e = [ a, a, "", c ], w.setFilters.hasOwnProperty(a.toLowerCase()) ? d(function(a, b) {
                        for (var d, e = f(a, c), g = e.length; g--; ) d = aa(a, e[g]), a[d] = !(b[d] = e[g]);
                    }) : function(a) {
                        return f(a, 0, e);
                    }) : f;
                }
            },
            pseudos: {
                not: d(function(a) {
                    var b = [], c = [], e = A(a.replace(ia, "$1"));
                    return e[N] ? d(function(a, b, c, d) {
                        for (var f, g = e(a, null, d, []), h = a.length; h--; ) (f = g[h]) && (a[h] = !(b[h] = f));
                    }) : function(a, d, f) {
                        return b[0] = a, e(b, null, f, c), b[0] = null, !c.pop();
                    };
                }),
                has: d(function(a) {
                    return function(c) {
                        return b(a, c).length > 0;
                    };
                }),
                contains: d(function(a) {
                    return a = a.replace(va, wa), function(b) {
                        return (b.textContent || b.innerText || x(b)).indexOf(a) > -1;
                    };
                }),
                lang: d(function(a) {
                    return na.test(a || "") || b.error("unsupported lang: " + a), a = a.replace(va, wa).toLowerCase(), 
                    function(b) {
                        var c;
                        do if (c = I ? b.lang : b.getAttribute("xml:lang") || b.getAttribute("lang")) return c = c.toLowerCase(), 
                        c === a || 0 === c.indexOf(a + "-"); while ((b = b.parentNode) && 1 === b.nodeType);
                        return !1;
                    };
                }),
                target: function(b) {
                    var c = a.location && a.location.hash;
                    return c && c.slice(1) === b.id;
                },
                root: function(a) {
                    return a === H;
                },
                focus: function(a) {
                    return a === G.activeElement && (!G.hasFocus || G.hasFocus()) && !!(a.type || a.href || ~a.tabIndex);
                },
                enabled: function(a) {
                    return a.disabled === !1;
                },
                disabled: function(a) {
                    return a.disabled === !0;
                },
                checked: function(a) {
                    var b = a.nodeName.toLowerCase();
                    return "input" === b && !!a.checked || "option" === b && !!a.selected;
                },
                selected: function(a) {
                    return a.parentNode && a.parentNode.selectedIndex, a.selected === !0;
                },
                empty: function(a) {
                    for (a = a.firstChild; a; a = a.nextSibling) if (a.nodeType < 6) return !1;
                    return !0;
                },
                parent: function(a) {
                    return !w.pseudos.empty(a);
                },
                header: function(a) {
                    return qa.test(a.nodeName);
                },
                input: function(a) {
                    return pa.test(a.nodeName);
                },
                button: function(a) {
                    var b = a.nodeName.toLowerCase();
                    return "input" === b && "button" === a.type || "button" === b;
                },
                text: function(a) {
                    var b;
                    return "input" === a.nodeName.toLowerCase() && "text" === a.type && (null == (b = a.getAttribute("type")) || "text" === b.toLowerCase());
                },
                first: j(function() {
                    return [ 0 ];
                }),
                last: j(function(a, b) {
                    return [ b - 1 ];
                }),
                eq: j(function(a, b, c) {
                    return [ 0 > c ? c + b : c ];
                }),
                even: j(function(a, b) {
                    for (var c = 0; b > c; c += 2) a.push(c);
                    return a;
                }),
                odd: j(function(a, b) {
                    for (var c = 1; b > c; c += 2) a.push(c);
                    return a;
                }),
                lt: j(function(a, b, c) {
                    for (var d = 0 > c ? c + b : c; --d >= 0; ) a.push(d);
                    return a;
                }),
                gt: j(function(a, b, c) {
                    for (var d = 0 > c ? c + b : c; ++d < b; ) a.push(d);
                    return a;
                })
            }
        }, w.pseudos.nth = w.pseudos.eq;
        for (u in {
            radio: !0,
            checkbox: !0,
            file: !0,
            password: !0,
            image: !0
        }) w.pseudos[u] = h(u);
        for (u in {
            submit: !0,
            reset: !0
        }) w.pseudos[u] = i(u);
        return l.prototype = w.filters = w.pseudos, w.setFilters = new l(), z = b.tokenize = function(a, c) {
            var d, e, f, g, h, i, j, k = S[a + " "];
            if (k) return c ? 0 : k.slice(0);
            for (h = a, i = [], j = w.preFilter; h; ) {
                (!d || (e = ja.exec(h))) && (e && (h = h.slice(e[0].length) || h), i.push(f = [])), 
                d = !1, (e = ka.exec(h)) && (d = e.shift(), f.push({
                    value: d,
                    type: e[0].replace(ia, " ")
                }), h = h.slice(d.length));
                for (g in w.filter) !(e = oa[g].exec(h)) || j[g] && !(e = j[g](e)) || (d = e.shift(), 
                f.push({
                    value: d,
                    type: g,
                    matches: e
                }), h = h.slice(d.length));
                if (!d) break;
            }
            return c ? h.length : h ? b.error(a) : S(a, i).slice(0);
        }, A = b.compile = function(a, b) {
            var c, d = [], e = [], f = T[a + " "];
            if (!f) {
                for (b || (b = z(a)), c = b.length; c--; ) f = s(b[c]), f[N] ? d.push(f) : e.push(f);
                f = T(a, t(e, d)), f.selector = a;
            }
            return f;
        }, B = b.select = function(a, b, c, d) {
            var e, f, g, h, i, j = "function" == typeof a && a, l = !d && z(a = j.selector || a);
            if (c = c || [], 1 === l.length) {
                if (f = l[0] = l[0].slice(0), f.length > 2 && "ID" === (g = f[0]).type && v.getById && 9 === b.nodeType && I && w.relative[f[1].type]) {
                    if (b = (w.find.ID(g.matches[0].replace(va, wa), b) || [])[0], !b) return c;
                    j && (b = b.parentNode), a = a.slice(f.shift().value.length);
                }
                for (e = oa.needsContext.test(a) ? 0 : f.length; e-- && (g = f[e], !w.relative[h = g.type]); ) if ((i = w.find[h]) && (d = i(g.matches[0].replace(va, wa), ta.test(f[0].type) && k(b.parentNode) || b))) {
                    if (f.splice(e, 1), a = d.length && m(f), !a) return $.apply(c, d), c;
                    break;
                }
            }
            return (j || A(a, l))(d, b, !I, c, ta.test(a) && k(b.parentNode) || b), c;
        }, v.sortStable = N.split("").sort(U).join("") === N, v.detectDuplicates = !!E, 
        F(), v.sortDetached = e(function(a) {
            return 1 & a.compareDocumentPosition(G.createElement("div"));
        }), e(function(a) {
            return a.innerHTML = "<a href='#'></a>", "#" === a.firstChild.getAttribute("href");
        }) || f("type|href|height|width", function(a, b, c) {
            return c ? void 0 : a.getAttribute(b, "type" === b.toLowerCase() ? 1 : 2);
        }), v.attributes && e(function(a) {
            return a.innerHTML = "<input/>", a.firstChild.setAttribute("value", ""), "" === a.firstChild.getAttribute("value");
        }) || f("value", function(a, b, c) {
            return c || "input" !== a.nodeName.toLowerCase() ? void 0 : a.defaultValue;
        }), e(function(a) {
            return null == a.getAttribute("disabled");
        }) || f(ba, function(a, b, c) {
            var d;
            return c ? void 0 : a[b] === !0 ? b.toLowerCase() : (d = a.getAttributeNode(b)) && d.specified ? d.value : null;
        }), b;
    }(a);
    ea.find = ja, ea.expr = ja.selectors, ea.expr[":"] = ea.expr.pseudos, ea.unique = ja.uniqueSort, 
    ea.text = ja.getText, ea.isXMLDoc = ja.isXML, ea.contains = ja.contains;
    var ka = ea.expr.match.needsContext, la = /^<(\w+)\s*\/?>(?:<\/\1>|)$/, ma = /^.[^:#\[\.,]*$/;
    ea.filter = function(a, b, c) {
        var d = b[0];
        return c && (a = ":not(" + a + ")"), 1 === b.length && 1 === d.nodeType ? ea.find.matchesSelector(d, a) ? [ d ] : [] : ea.find.matches(a, ea.grep(b, function(a) {
            return 1 === a.nodeType;
        }));
    }, ea.fn.extend({
        find: function(a) {
            var b, c = [], d = this, e = d.length;
            if ("string" != typeof a) return this.pushStack(ea(a).filter(function() {
                for (b = 0; e > b; b++) if (ea.contains(d[b], this)) return !0;
            }));
            for (b = 0; e > b; b++) ea.find(a, d[b], c);
            return c = this.pushStack(e > 1 ? ea.unique(c) : c), c.selector = this.selector ? this.selector + " " + a : a, 
            c;
        },
        filter: function(a) {
            return this.pushStack(d(this, a || [], !1));
        },
        not: function(a) {
            return this.pushStack(d(this, a || [], !0));
        },
        is: function(a) {
            return !!d(this, "string" == typeof a && ka.test(a) ? ea(a) : a || [], !1).length;
        }
    });
    var na, oa = a.document, pa = /^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/, qa = ea.fn.init = function(a, b) {
        var c, d;
        if (!a) return this;
        if ("string" == typeof a) {
            if (c = "<" === a.charAt(0) && ">" === a.charAt(a.length - 1) && a.length >= 3 ? [ null, a, null ] : pa.exec(a), 
            !c || !c[1] && b) return !b || b.jquery ? (b || na).find(a) : this.constructor(b).find(a);
            if (c[1]) {
                if (b = b instanceof ea ? b[0] : b, ea.merge(this, ea.parseHTML(c[1], b && b.nodeType ? b.ownerDocument || b : oa, !0)), 
                la.test(c[1]) && ea.isPlainObject(b)) for (c in b) ea.isFunction(this[c]) ? this[c](b[c]) : this.attr(c, b[c]);
                return this;
            }
            if (d = oa.getElementById(c[2]), d && d.parentNode) {
                if (d.id !== c[2]) return na.find(a);
                this.length = 1, this[0] = d;
            }
            return this.context = oa, this.selector = a, this;
        }
        return a.nodeType ? (this.context = this[0] = a, this.length = 1, this) : ea.isFunction(a) ? "undefined" != typeof na.ready ? na.ready(a) : a(ea) : (void 0 !== a.selector && (this.selector = a.selector, 
        this.context = a.context), ea.makeArray(a, this));
    };
    qa.prototype = ea.fn, na = ea(oa);
    var ra = /^(?:parents|prev(?:Until|All))/, sa = {
        children: !0,
        contents: !0,
        next: !0,
        prev: !0
    };
    ea.extend({
        dir: function(a, b, c) {
            for (var d = [], e = a[b]; e && 9 !== e.nodeType && (void 0 === c || 1 !== e.nodeType || !ea(e).is(c)); ) 1 === e.nodeType && d.push(e), 
            e = e[b];
            return d;
        },
        sibling: function(a, b) {
            for (var c = []; a; a = a.nextSibling) 1 === a.nodeType && a !== b && c.push(a);
            return c;
        }
    }), ea.fn.extend({
        has: function(a) {
            var b, c = ea(a, this), d = c.length;
            return this.filter(function() {
                for (b = 0; d > b; b++) if (ea.contains(this, c[b])) return !0;
            });
        },
        closest: function(a, b) {
            for (var c, d = 0, e = this.length, f = [], g = ka.test(a) || "string" != typeof a ? ea(a, b || this.context) : 0; e > d; d++) for (c = this[d]; c && c !== b; c = c.parentNode) if (c.nodeType < 11 && (g ? g.index(c) > -1 : 1 === c.nodeType && ea.find.matchesSelector(c, a))) {
                f.push(c);
                break;
            }
            return this.pushStack(f.length > 1 ? ea.unique(f) : f);
        },
        index: function(a) {
            return a ? "string" == typeof a ? ea.inArray(this[0], ea(a)) : ea.inArray(a.jquery ? a[0] : a, this) : this[0] && this[0].parentNode ? this.first().prevAll().length : -1;
        },
        add: function(a, b) {
            return this.pushStack(ea.unique(ea.merge(this.get(), ea(a, b))));
        },
        addBack: function(a) {
            return this.add(null == a ? this.prevObject : this.prevObject.filter(a));
        }
    }), ea.each({
        parent: function(a) {
            var b = a.parentNode;
            return b && 11 !== b.nodeType ? b : null;
        },
        parents: function(a) {
            return ea.dir(a, "parentNode");
        },
        parentsUntil: function(a, b, c) {
            return ea.dir(a, "parentNode", c);
        },
        next: function(a) {
            return e(a, "nextSibling");
        },
        prev: function(a) {
            return e(a, "previousSibling");
        },
        nextAll: function(a) {
            return ea.dir(a, "nextSibling");
        },
        prevAll: function(a) {
            return ea.dir(a, "previousSibling");
        },
        nextUntil: function(a, b, c) {
            return ea.dir(a, "nextSibling", c);
        },
        prevUntil: function(a, b, c) {
            return ea.dir(a, "previousSibling", c);
        },
        siblings: function(a) {
            return ea.sibling((a.parentNode || {}).firstChild, a);
        },
        children: function(a) {
            return ea.sibling(a.firstChild);
        },
        contents: function(a) {
            return ea.nodeName(a, "iframe") ? a.contentDocument || a.contentWindow.document : ea.merge([], a.childNodes);
        }
    }, function(a, b) {
        ea.fn[a] = function(c, d) {
            var e = ea.map(this, b, c);
            return "Until" !== a.slice(-5) && (d = c), d && "string" == typeof d && (e = ea.filter(d, e)), 
            this.length > 1 && (sa[a] || (e = ea.unique(e)), ra.test(a) && (e = e.reverse())), 
            this.pushStack(e);
        };
    });
    var ta = /\S+/g, ua = {};
    ea.Callbacks = function(a) {
        a = "string" == typeof a ? ua[a] || f(a) : ea.extend({}, a);
        var b, c, d, e, g, h, i = [], j = !a.once && [], k = function(f) {
            for (c = a.memory && f, d = !0, g = h || 0, h = 0, e = i.length, b = !0; i && e > g; g++) if (i[g].apply(f[0], f[1]) === !1 && a.stopOnFalse) {
                c = !1;
                break;
            }
            b = !1, i && (j ? j.length && k(j.shift()) : c ? i = [] : l.disable());
        }, l = {
            add: function() {
                if (i) {
                    var d = i.length;
                    !function f(b) {
                        ea.each(b, function(b, c) {
                            var d = ea.type(c);
                            "function" === d ? a.unique && l.has(c) || i.push(c) : c && c.length && "string" !== d && f(c);
                        });
                    }(arguments), b ? e = i.length : c && (h = d, k(c));
                }
                return this;
            },
            remove: function() {
                return i && ea.each(arguments, function(a, c) {
                    for (var d; (d = ea.inArray(c, i, d)) > -1; ) i.splice(d, 1), b && (e >= d && e--, 
                    g >= d && g--);
                }), this;
            },
            has: function(a) {
                return a ? ea.inArray(a, i) > -1 : !(!i || !i.length);
            },
            empty: function() {
                return i = [], e = 0, this;
            },
            disable: function() {
                return i = j = c = void 0, this;
            },
            disabled: function() {
                return !i;
            },
            lock: function() {
                return j = void 0, c || l.disable(), this;
            },
            locked: function() {
                return !j;
            },
            fireWith: function(a, c) {
                return !i || d && !j || (c = c || [], c = [ a, c.slice ? c.slice() : c ], b ? j.push(c) : k(c)), 
                this;
            },
            fire: function() {
                return l.fireWith(this, arguments), this;
            },
            fired: function() {
                return !!d;
            }
        };
        return l;
    }, ea.extend({
        Deferred: function(a) {
            var b = [ [ "resolve", "done", ea.Callbacks("once memory"), "resolved" ], [ "reject", "fail", ea.Callbacks("once memory"), "rejected" ], [ "notify", "progress", ea.Callbacks("memory") ] ], c = "pending", d = {
                state: function() {
                    return c;
                },
                always: function() {
                    return e.done(arguments).fail(arguments), this;
                },
                then: function() {
                    var a = arguments;
                    return ea.Deferred(function(c) {
                        ea.each(b, function(b, f) {
                            var g = ea.isFunction(a[b]) && a[b];
                            e[f[1]](function() {
                                var a = g && g.apply(this, arguments);
                                a && ea.isFunction(a.promise) ? a.promise().done(c.resolve).fail(c.reject).progress(c.notify) : c[f[0] + "With"](this === d ? c.promise() : this, g ? [ a ] : arguments);
                            });
                        }), a = null;
                    }).promise();
                },
                promise: function(a) {
                    return null != a ? ea.extend(a, d) : d;
                }
            }, e = {};
            return d.pipe = d.then, ea.each(b, function(a, f) {
                var g = f[2], h = f[3];
                d[f[1]] = g.add, h && g.add(function() {
                    c = h;
                }, b[1 ^ a][2].disable, b[2][2].lock), e[f[0]] = function() {
                    return e[f[0] + "With"](this === e ? d : this, arguments), this;
                }, e[f[0] + "With"] = g.fireWith;
            }), d.promise(e), a && a.call(e, e), e;
        },
        when: function(a) {
            var b, c, d, e = 0, f = X.call(arguments), g = f.length, h = 1 !== g || a && ea.isFunction(a.promise) ? g : 0, i = 1 === h ? a : ea.Deferred(), j = function(a, c, d) {
                return function(e) {
                    c[a] = this, d[a] = arguments.length > 1 ? X.call(arguments) : e, d === b ? i.notifyWith(c, d) : --h || i.resolveWith(c, d);
                };
            };
            if (g > 1) for (b = new Array(g), c = new Array(g), d = new Array(g); g > e; e++) f[e] && ea.isFunction(f[e].promise) ? f[e].promise().done(j(e, d, f)).fail(i.reject).progress(j(e, c, b)) : --h;
            return h || i.resolveWith(d, f), i.promise();
        }
    });
    var va;
    ea.fn.ready = function(a) {
        return ea.ready.promise().done(a), this;
    }, ea.extend({
        isReady: !1,
        readyWait: 1,
        holdReady: function(a) {
            a ? ea.readyWait++ : ea.ready(!0);
        },
        ready: function(a) {
            if (a === !0 ? !--ea.readyWait : !ea.isReady) {
                if (!oa.body) return setTimeout(ea.ready);
                ea.isReady = !0, a !== !0 && --ea.readyWait > 0 || (va.resolveWith(oa, [ ea ]), 
                ea.fn.triggerHandler && (ea(oa).triggerHandler("ready"), ea(oa).off("ready")));
            }
        }
    }), ea.ready.promise = function(b) {
        if (!va) if (va = ea.Deferred(), "complete" === oa.readyState) setTimeout(ea.ready); else if (oa.addEventListener) oa.addEventListener("DOMContentLoaded", h, !1), 
        a.addEventListener("load", h, !1); else {
            oa.attachEvent("onreadystatechange", h), a.attachEvent("onload", h);
            var c = !1;
            try {
                c = null == a.frameElement && oa.documentElement;
            } catch (d) {}
            c && c.doScroll && !function e() {
                if (!ea.isReady) {
                    try {
                        c.doScroll("left");
                    } catch (a) {
                        return setTimeout(e, 50);
                    }
                    g(), ea.ready();
                }
            }();
        }
        return va.promise(b);
    };
    var wa, xa = "undefined";
    for (wa in ea(ca)) break;
    ca.ownLast = "0" !== wa, ca.inlineBlockNeedsLayout = !1, ea(function() {
        var a, b, c, d;
        c = oa.getElementsByTagName("body")[0], c && c.style && (b = oa.createElement("div"), 
        d = oa.createElement("div"), d.style.cssText = "position:absolute;border:0;width:0;height:0;top:0;left:-9999px", 
        c.appendChild(d).appendChild(b), typeof b.style.zoom !== xa && (b.style.cssText = "display:inline;margin:0;border:0;padding:1px;width:1px;zoom:1", 
        ca.inlineBlockNeedsLayout = a = 3 === b.offsetWidth, a && (c.style.zoom = 1)), c.removeChild(d));
    }), function() {
        var a = oa.createElement("div");
        if (null == ca.deleteExpando) {
            ca.deleteExpando = !0;
            try {
                delete a.test;
            } catch (b) {
                ca.deleteExpando = !1;
            }
        }
        a = null;
    }(), ea.acceptData = function(a) {
        var b = ea.noData[(a.nodeName + " ").toLowerCase()], c = +a.nodeType || 1;
        return 1 !== c && 9 !== c ? !1 : !b || b !== !0 && a.getAttribute("classid") === b;
    };
    var ya = /^(?:\{[\w\W]*\}|\[[\w\W]*\])$/, za = /([A-Z])/g;
    ea.extend({
        cache: {},
        noData: {
            "applet ": !0,
            "embed ": !0,
            "object ": "clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
        },
        hasData: function(a) {
            return a = a.nodeType ? ea.cache[a[ea.expando]] : a[ea.expando], !!a && !j(a);
        },
        data: function(a, b, c) {
            return k(a, b, c);
        },
        removeData: function(a, b) {
            return l(a, b);
        },
        _data: function(a, b, c) {
            return k(a, b, c, !0);
        },
        _removeData: function(a, b) {
            return l(a, b, !0);
        }
    }), ea.fn.extend({
        data: function(a, b) {
            var c, d, e, f = this[0], g = f && f.attributes;
            if (void 0 === a) {
                if (this.length && (e = ea.data(f), 1 === f.nodeType && !ea._data(f, "parsedAttrs"))) {
                    for (c = g.length; c--; ) g[c] && (d = g[c].name, 0 === d.indexOf("data-") && (d = ea.camelCase(d.slice(5)), 
                    i(f, d, e[d])));
                    ea._data(f, "parsedAttrs", !0);
                }
                return e;
            }
            return "object" == typeof a ? this.each(function() {
                ea.data(this, a);
            }) : arguments.length > 1 ? this.each(function() {
                ea.data(this, a, b);
            }) : f ? i(f, a, ea.data(f, a)) : void 0;
        },
        removeData: function(a) {
            return this.each(function() {
                ea.removeData(this, a);
            });
        }
    }), ea.extend({
        queue: function(a, b, c) {
            var d;
            return a ? (b = (b || "fx") + "queue", d = ea._data(a, b), c && (!d || ea.isArray(c) ? d = ea._data(a, b, ea.makeArray(c)) : d.push(c)), 
            d || []) : void 0;
        },
        dequeue: function(a, b) {
            b = b || "fx";
            var c = ea.queue(a, b), d = c.length, e = c.shift(), f = ea._queueHooks(a, b), g = function() {
                ea.dequeue(a, b);
            };
            "inprogress" === e && (e = c.shift(), d--), e && ("fx" === b && c.unshift("inprogress"), 
            delete f.stop, e.call(a, g, f)), !d && f && f.empty.fire();
        },
        _queueHooks: function(a, b) {
            var c = b + "queueHooks";
            return ea._data(a, c) || ea._data(a, c, {
                empty: ea.Callbacks("once memory").add(function() {
                    ea._removeData(a, b + "queue"), ea._removeData(a, c);
                })
            });
        }
    }), ea.fn.extend({
        queue: function(a, b) {
            var c = 2;
            return "string" != typeof a && (b = a, a = "fx", c--), arguments.length < c ? ea.queue(this[0], a) : void 0 === b ? this : this.each(function() {
                var c = ea.queue(this, a, b);
                ea._queueHooks(this, a), "fx" === a && "inprogress" !== c[0] && ea.dequeue(this, a);
            });
        },
        dequeue: function(a) {
            return this.each(function() {
                ea.dequeue(this, a);
            });
        },
        clearQueue: function(a) {
            return this.queue(a || "fx", []);
        },
        promise: function(a, b) {
            var c, d = 1, e = ea.Deferred(), f = this, g = this.length, h = function() {
                --d || e.resolveWith(f, [ f ]);
            };
            for ("string" != typeof a && (b = a, a = void 0), a = a || "fx"; g--; ) c = ea._data(f[g], a + "queueHooks"), 
            c && c.empty && (d++, c.empty.add(h));
            return h(), e.promise(b);
        }
    });
    var Aa = /[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source, Ba = [ "Top", "Right", "Bottom", "Left" ], Ca = function(a, b) {
        return a = b || a, "none" === ea.css(a, "display") || !ea.contains(a.ownerDocument, a);
    }, Da = ea.access = function(a, b, c, d, e, f, g) {
        var h = 0, i = a.length, j = null == c;
        if ("object" === ea.type(c)) {
            e = !0;
            for (h in c) ea.access(a, b, h, c[h], !0, f, g);
        } else if (void 0 !== d && (e = !0, ea.isFunction(d) || (g = !0), j && (g ? (b.call(a, d), 
        b = null) : (j = b, b = function(a, b, c) {
            return j.call(ea(a), c);
        })), b)) for (;i > h; h++) b(a[h], c, g ? d : d.call(a[h], h, b(a[h], c)));
        return e ? a : j ? b.call(a) : i ? b(a[0], c) : f;
    }, Ea = /^(?:checkbox|radio)$/i;
    !function() {
        var a = oa.createElement("input"), b = oa.createElement("div"), c = oa.createDocumentFragment();
        if (b.innerHTML = "  <link/><table></table><a href='/a'>a</a><input type='checkbox'/>", 
        ca.leadingWhitespace = 3 === b.firstChild.nodeType, ca.tbody = !b.getElementsByTagName("tbody").length, 
        ca.htmlSerialize = !!b.getElementsByTagName("link").length, ca.html5Clone = "<:nav></:nav>" !== oa.createElement("nav").cloneNode(!0).outerHTML, 
        a.type = "checkbox", a.checked = !0, c.appendChild(a), ca.appendChecked = a.checked, 
        b.innerHTML = "<textarea>x</textarea>", ca.noCloneChecked = !!b.cloneNode(!0).lastChild.defaultValue, 
        c.appendChild(b), b.innerHTML = "<input type='radio' checked='checked' name='t'/>", 
        ca.checkClone = b.cloneNode(!0).cloneNode(!0).lastChild.checked, ca.noCloneEvent = !0, 
        b.attachEvent && (b.attachEvent("onclick", function() {
            ca.noCloneEvent = !1;
        }), b.cloneNode(!0).click()), null == ca.deleteExpando) {
            ca.deleteExpando = !0;
            try {
                delete b.test;
            } catch (d) {
                ca.deleteExpando = !1;
            }
        }
    }(), function() {
        var b, c, d = oa.createElement("div");
        for (b in {
            submit: !0,
            change: !0,
            focusin: !0
        }) c = "on" + b, (ca[b + "Bubbles"] = c in a) || (d.setAttribute(c, "t"), ca[b + "Bubbles"] = d.attributes[c].expando === !1);
        d = null;
    }();
    var Fa = /^(?:input|select|textarea)$/i, Ga = /^key/, Ha = /^(?:mouse|pointer|contextmenu)|click/, Ia = /^(?:focusinfocus|focusoutblur)$/, Ja = /^([^.]*)(?:\.(.+)|)$/;
    ea.event = {
        global: {},
        add: function(a, b, c, d, e) {
            var f, g, h, i, j, k, l, m, n, o, p, q = ea._data(a);
            if (q) {
                for (c.handler && (i = c, c = i.handler, e = i.selector), c.guid || (c.guid = ea.guid++), 
                (g = q.events) || (g = q.events = {}), (k = q.handle) || (k = q.handle = function(a) {
                    return typeof ea === xa || a && ea.event.triggered === a.type ? void 0 : ea.event.dispatch.apply(k.elem, arguments);
                }, k.elem = a), b = (b || "").match(ta) || [ "" ], h = b.length; h--; ) f = Ja.exec(b[h]) || [], 
                n = p = f[1], o = (f[2] || "").split(".").sort(), n && (j = ea.event.special[n] || {}, 
                n = (e ? j.delegateType : j.bindType) || n, j = ea.event.special[n] || {}, l = ea.extend({
                    type: n,
                    origType: p,
                    data: d,
                    handler: c,
                    guid: c.guid,
                    selector: e,
                    needsContext: e && ea.expr.match.needsContext.test(e),
                    namespace: o.join(".")
                }, i), (m = g[n]) || (m = g[n] = [], m.delegateCount = 0, j.setup && j.setup.call(a, d, o, k) !== !1 || (a.addEventListener ? a.addEventListener(n, k, !1) : a.attachEvent && a.attachEvent("on" + n, k))), 
                j.add && (j.add.call(a, l), l.handler.guid || (l.handler.guid = c.guid)), e ? m.splice(m.delegateCount++, 0, l) : m.push(l), 
                ea.event.global[n] = !0);
                a = null;
            }
        },
        remove: function(a, b, c, d, e) {
            var f, g, h, i, j, k, l, m, n, o, p, q = ea.hasData(a) && ea._data(a);
            if (q && (k = q.events)) {
                for (b = (b || "").match(ta) || [ "" ], j = b.length; j--; ) if (h = Ja.exec(b[j]) || [], 
                n = p = h[1], o = (h[2] || "").split(".").sort(), n) {
                    for (l = ea.event.special[n] || {}, n = (d ? l.delegateType : l.bindType) || n, 
                    m = k[n] || [], h = h[2] && new RegExp("(^|\\.)" + o.join("\\.(?:.*\\.|)") + "(\\.|$)"), 
                    i = f = m.length; f--; ) g = m[f], !e && p !== g.origType || c && c.guid !== g.guid || h && !h.test(g.namespace) || d && d !== g.selector && ("**" !== d || !g.selector) || (m.splice(f, 1), 
                    g.selector && m.delegateCount--, l.remove && l.remove.call(a, g));
                    i && !m.length && (l.teardown && l.teardown.call(a, o, q.handle) !== !1 || ea.removeEvent(a, n, q.handle), 
                    delete k[n]);
                } else for (n in k) ea.event.remove(a, n + b[j], c, d, !0);
                ea.isEmptyObject(k) && (delete q.handle, ea._removeData(a, "events"));
            }
        },
        trigger: function(b, c, d, e) {
            var f, g, h, i, j, k, l, m = [ d || oa ], n = ba.call(b, "type") ? b.type : b, o = ba.call(b, "namespace") ? b.namespace.split(".") : [];
            if (h = k = d = d || oa, 3 !== d.nodeType && 8 !== d.nodeType && !Ia.test(n + ea.event.triggered) && (n.indexOf(".") >= 0 && (o = n.split("."), 
            n = o.shift(), o.sort()), g = n.indexOf(":") < 0 && "on" + n, b = b[ea.expando] ? b : new ea.Event(n, "object" == typeof b && b), 
            b.isTrigger = e ? 2 : 3, b.namespace = o.join("."), b.namespace_re = b.namespace ? new RegExp("(^|\\.)" + o.join("\\.(?:.*\\.|)") + "(\\.|$)") : null, 
            b.result = void 0, b.target || (b.target = d), c = null == c ? [ b ] : ea.makeArray(c, [ b ]), 
            j = ea.event.special[n] || {}, e || !j.trigger || j.trigger.apply(d, c) !== !1)) {
                if (!e && !j.noBubble && !ea.isWindow(d)) {
                    for (i = j.delegateType || n, Ia.test(i + n) || (h = h.parentNode); h; h = h.parentNode) m.push(h), 
                    k = h;
                    k === (d.ownerDocument || oa) && m.push(k.defaultView || k.parentWindow || a);
                }
                for (l = 0; (h = m[l++]) && !b.isPropagationStopped(); ) b.type = l > 1 ? i : j.bindType || n, 
                f = (ea._data(h, "events") || {})[b.type] && ea._data(h, "handle"), f && f.apply(h, c), 
                f = g && h[g], f && f.apply && ea.acceptData(h) && (b.result = f.apply(h, c), b.result === !1 && b.preventDefault());
                if (b.type = n, !e && !b.isDefaultPrevented() && (!j._default || j._default.apply(m.pop(), c) === !1) && ea.acceptData(d) && g && d[n] && !ea.isWindow(d)) {
                    k = d[g], k && (d[g] = null), ea.event.triggered = n;
                    try {
                        d[n]();
                    } catch (p) {}
                    ea.event.triggered = void 0, k && (d[g] = k);
                }
                return b.result;
            }
        },
        dispatch: function(a) {
            a = ea.event.fix(a);
            var b, c, d, e, f, g = [], h = X.call(arguments), i = (ea._data(this, "events") || {})[a.type] || [], j = ea.event.special[a.type] || {};
            if (h[0] = a, a.delegateTarget = this, !j.preDispatch || j.preDispatch.call(this, a) !== !1) {
                for (g = ea.event.handlers.call(this, a, i), b = 0; (e = g[b++]) && !a.isPropagationStopped(); ) for (a.currentTarget = e.elem, 
                f = 0; (d = e.handlers[f++]) && !a.isImmediatePropagationStopped(); ) (!a.namespace_re || a.namespace_re.test(d.namespace)) && (a.handleObj = d, 
                a.data = d.data, c = ((ea.event.special[d.origType] || {}).handle || d.handler).apply(e.elem, h), 
                void 0 !== c && (a.result = c) === !1 && (a.preventDefault(), a.stopPropagation()));
                return j.postDispatch && j.postDispatch.call(this, a), a.result;
            }
        },
        handlers: function(a, b) {
            var c, d, e, f, g = [], h = b.delegateCount, i = a.target;
            if (h && i.nodeType && (!a.button || "click" !== a.type)) for (;i != this; i = i.parentNode || this) if (1 === i.nodeType && (i.disabled !== !0 || "click" !== a.type)) {
                for (e = [], f = 0; h > f; f++) d = b[f], c = d.selector + " ", void 0 === e[c] && (e[c] = d.needsContext ? ea(c, this).index(i) >= 0 : ea.find(c, this, null, [ i ]).length), 
                e[c] && e.push(d);
                e.length && g.push({
                    elem: i,
                    handlers: e
                });
            }
            return h < b.length && g.push({
                elem: this,
                handlers: b.slice(h)
            }), g;
        },
        fix: function(a) {
            if (a[ea.expando]) return a;
            var b, c, d, e = a.type, f = a, g = this.fixHooks[e];
            for (g || (this.fixHooks[e] = g = Ha.test(e) ? this.mouseHooks : Ga.test(e) ? this.keyHooks : {}), 
            d = g.props ? this.props.concat(g.props) : this.props, a = new ea.Event(f), b = d.length; b--; ) c = d[b], 
            a[c] = f[c];
            return a.target || (a.target = f.srcElement || oa), 3 === a.target.nodeType && (a.target = a.target.parentNode), 
            a.metaKey = !!a.metaKey, g.filter ? g.filter(a, f) : a;
        },
        props: "altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),
        fixHooks: {},
        keyHooks: {
            props: "char charCode key keyCode".split(" "),
            filter: function(a, b) {
                return null == a.which && (a.which = null != b.charCode ? b.charCode : b.keyCode), 
                a;
            }
        },
        mouseHooks: {
            props: "button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),
            filter: function(a, b) {
                var c, d, e, f = b.button, g = b.fromElement;
                return null == a.pageX && null != b.clientX && (d = a.target.ownerDocument || oa, 
                e = d.documentElement, c = d.body, a.pageX = b.clientX + (e && e.scrollLeft || c && c.scrollLeft || 0) - (e && e.clientLeft || c && c.clientLeft || 0), 
                a.pageY = b.clientY + (e && e.scrollTop || c && c.scrollTop || 0) - (e && e.clientTop || c && c.clientTop || 0)), 
                !a.relatedTarget && g && (a.relatedTarget = g === a.target ? b.toElement : g), a.which || void 0 === f || (a.which = 1 & f ? 1 : 2 & f ? 3 : 4 & f ? 2 : 0), 
                a;
            }
        },
        special: {
            load: {
                noBubble: !0
            },
            focus: {
                trigger: function() {
                    if (this !== o() && this.focus) try {
                        return this.focus(), !1;
                    } catch (a) {}
                },
                delegateType: "focusin"
            },
            blur: {
                trigger: function() {
                    return this === o() && this.blur ? (this.blur(), !1) : void 0;
                },
                delegateType: "focusout"
            },
            click: {
                trigger: function() {
                    return ea.nodeName(this, "input") && "checkbox" === this.type && this.click ? (this.click(), 
                    !1) : void 0;
                },
                _default: function(a) {
                    return ea.nodeName(a.target, "a");
                }
            },
            beforeunload: {
                postDispatch: function(a) {
                    void 0 !== a.result && a.originalEvent && (a.originalEvent.returnValue = a.result);
                }
            }
        },
        simulate: function(a, b, c, d) {
            var e = ea.extend(new ea.Event(), c, {
                type: a,
                isSimulated: !0,
                originalEvent: {}
            });
            d ? ea.event.trigger(e, null, b) : ea.event.dispatch.call(b, e), e.isDefaultPrevented() && c.preventDefault();
        }
    }, ea.removeEvent = oa.removeEventListener ? function(a, b, c) {
        a.removeEventListener && a.removeEventListener(b, c, !1);
    } : function(a, b, c) {
        var d = "on" + b;
        a.detachEvent && (typeof a[d] === xa && (a[d] = null), a.detachEvent(d, c));
    }, ea.Event = function(a, b) {
        return this instanceof ea.Event ? (a && a.type ? (this.originalEvent = a, this.type = a.type, 
        this.isDefaultPrevented = a.defaultPrevented || void 0 === a.defaultPrevented && a.returnValue === !1 ? m : n) : this.type = a, 
        b && ea.extend(this, b), this.timeStamp = a && a.timeStamp || ea.now(), void (this[ea.expando] = !0)) : new ea.Event(a, b);
    }, ea.Event.prototype = {
        isDefaultPrevented: n,
        isPropagationStopped: n,
        isImmediatePropagationStopped: n,
        preventDefault: function() {
            var a = this.originalEvent;
            this.isDefaultPrevented = m, a && (a.preventDefault ? a.preventDefault() : a.returnValue = !1);
        },
        stopPropagation: function() {
            var a = this.originalEvent;
            this.isPropagationStopped = m, a && (a.stopPropagation && a.stopPropagation(), a.cancelBubble = !0);
        },
        stopImmediatePropagation: function() {
            var a = this.originalEvent;
            this.isImmediatePropagationStopped = m, a && a.stopImmediatePropagation && a.stopImmediatePropagation(), 
            this.stopPropagation();
        }
    }, ea.each({
        mouseenter: "mouseover",
        mouseleave: "mouseout",
        pointerenter: "pointerover",
        pointerleave: "pointerout"
    }, function(a, b) {
        ea.event.special[a] = {
            delegateType: b,
            bindType: b,
            handle: function(a) {
                var c, d = this, e = a.relatedTarget, f = a.handleObj;
                return (!e || e !== d && !ea.contains(d, e)) && (a.type = f.origType, c = f.handler.apply(this, arguments), 
                a.type = b), c;
            }
        };
    }), ca.submitBubbles || (ea.event.special.submit = {
        setup: function() {
            return ea.nodeName(this, "form") ? !1 : void ea.event.add(this, "click._submit keypress._submit", function(a) {
                var b = a.target, c = ea.nodeName(b, "input") || ea.nodeName(b, "button") ? b.form : void 0;
                c && !ea._data(c, "submitBubbles") && (ea.event.add(c, "submit._submit", function(a) {
                    a._submit_bubble = !0;
                }), ea._data(c, "submitBubbles", !0));
            });
        },
        postDispatch: function(a) {
            a._submit_bubble && (delete a._submit_bubble, this.parentNode && !a.isTrigger && ea.event.simulate("submit", this.parentNode, a, !0));
        },
        teardown: function() {
            return ea.nodeName(this, "form") ? !1 : void ea.event.remove(this, "._submit");
        }
    }), ca.changeBubbles || (ea.event.special.change = {
        setup: function() {
            return Fa.test(this.nodeName) ? (("checkbox" === this.type || "radio" === this.type) && (ea.event.add(this, "propertychange._change", function(a) {
                "checked" === a.originalEvent.propertyName && (this._just_changed = !0);
            }), ea.event.add(this, "click._change", function(a) {
                this._just_changed && !a.isTrigger && (this._just_changed = !1), ea.event.simulate("change", this, a, !0);
            })), !1) : void ea.event.add(this, "beforeactivate._change", function(a) {
                var b = a.target;
                Fa.test(b.nodeName) && !ea._data(b, "changeBubbles") && (ea.event.add(b, "change._change", function(a) {
                    !this.parentNode || a.isSimulated || a.isTrigger || ea.event.simulate("change", this.parentNode, a, !0);
                }), ea._data(b, "changeBubbles", !0));
            });
        },
        handle: function(a) {
            var b = a.target;
            return this !== b || a.isSimulated || a.isTrigger || "radio" !== b.type && "checkbox" !== b.type ? a.handleObj.handler.apply(this, arguments) : void 0;
        },
        teardown: function() {
            return ea.event.remove(this, "._change"), !Fa.test(this.nodeName);
        }
    }), ca.focusinBubbles || ea.each({
        focus: "focusin",
        blur: "focusout"
    }, function(a, b) {
        var c = function(a) {
            ea.event.simulate(b, a.target, ea.event.fix(a), !0);
        };
        ea.event.special[b] = {
            setup: function() {
                var d = this.ownerDocument || this, e = ea._data(d, b);
                e || d.addEventListener(a, c, !0), ea._data(d, b, (e || 0) + 1);
            },
            teardown: function() {
                var d = this.ownerDocument || this, e = ea._data(d, b) - 1;
                e ? ea._data(d, b, e) : (d.removeEventListener(a, c, !0), ea._removeData(d, b));
            }
        };
    }), ea.fn.extend({
        on: function(a, b, c, d, e) {
            var f, g;
            if ("object" == typeof a) {
                "string" != typeof b && (c = c || b, b = void 0);
                for (f in a) this.on(f, b, c, a[f], e);
                return this;
            }
            if (null == c && null == d ? (d = b, c = b = void 0) : null == d && ("string" == typeof b ? (d = c, 
            c = void 0) : (d = c, c = b, b = void 0)), d === !1) d = n; else if (!d) return this;
            return 1 === e && (g = d, d = function(a) {
                return ea().off(a), g.apply(this, arguments);
            }, d.guid = g.guid || (g.guid = ea.guid++)), this.each(function() {
                ea.event.add(this, a, d, c, b);
            });
        },
        one: function(a, b, c, d) {
            return this.on(a, b, c, d, 1);
        },
        off: function(a, b, c) {
            var d, e;
            if (a && a.preventDefault && a.handleObj) return d = a.handleObj, ea(a.delegateTarget).off(d.namespace ? d.origType + "." + d.namespace : d.origType, d.selector, d.handler), 
            this;
            if ("object" == typeof a) {
                for (e in a) this.off(e, b, a[e]);
                return this;
            }
            return (b === !1 || "function" == typeof b) && (c = b, b = void 0), c === !1 && (c = n), 
            this.each(function() {
                ea.event.remove(this, a, c, b);
            });
        },
        trigger: function(a, b) {
            return this.each(function() {
                ea.event.trigger(a, b, this);
            });
        },
        triggerHandler: function(a, b) {
            var c = this[0];
            return c ? ea.event.trigger(a, b, c, !0) : void 0;
        }
    });
    var Ka = "abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video", La = / jQuery\d+="(?:null|\d+)"/g, Ma = new RegExp("<(?:" + Ka + ")[\\s/>]", "i"), Na = /^\s+/, Oa = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi, Pa = /<([\w:]+)/, Qa = /<tbody/i, Ra = /<|&#?\w+;/, Sa = /<(?:script|style|link)/i, Ta = /checked\s*(?:[^=]|=\s*.checked.)/i, Ua = /^$|\/(?:java|ecma)script/i, Va = /^true\/(.*)/, Wa = /^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g, Xa = {
        option: [ 1, "<select multiple='multiple'>", "</select>" ],
        legend: [ 1, "<fieldset>", "</fieldset>" ],
        area: [ 1, "<map>", "</map>" ],
        param: [ 1, "<object>", "</object>" ],
        thead: [ 1, "<table>", "</table>" ],
        tr: [ 2, "<table><tbody>", "</tbody></table>" ],
        col: [ 2, "<table><tbody></tbody><colgroup>", "</colgroup></table>" ],
        td: [ 3, "<table><tbody><tr>", "</tr></tbody></table>" ],
        _default: ca.htmlSerialize ? [ 0, "", "" ] : [ 1, "X<div>", "</div>" ]
    }, Ya = p(oa), Za = Ya.appendChild(oa.createElement("div"));
    Xa.optgroup = Xa.option, Xa.tbody = Xa.tfoot = Xa.colgroup = Xa.caption = Xa.thead, 
    Xa.th = Xa.td, ea.extend({
        clone: function(a, b, c) {
            var d, e, f, g, h, i = ea.contains(a.ownerDocument, a);
            if (ca.html5Clone || ea.isXMLDoc(a) || !Ma.test("<" + a.nodeName + ">") ? f = a.cloneNode(!0) : (Za.innerHTML = a.outerHTML, 
            Za.removeChild(f = Za.firstChild)), !(ca.noCloneEvent && ca.noCloneChecked || 1 !== a.nodeType && 11 !== a.nodeType || ea.isXMLDoc(a))) for (d = q(f), 
            h = q(a), g = 0; null != (e = h[g]); ++g) d[g] && x(e, d[g]);
            if (b) if (c) for (h = h || q(a), d = d || q(f), g = 0; null != (e = h[g]); g++) w(e, d[g]); else w(a, f);
            return d = q(f, "script"), d.length > 0 && v(d, !i && q(a, "script")), d = h = e = null, 
            f;
        },
        buildFragment: function(a, b, c, d) {
            for (var e, f, g, h, i, j, k, l = a.length, m = p(b), n = [], o = 0; l > o; o++) if (f = a[o], 
            f || 0 === f) if ("object" === ea.type(f)) ea.merge(n, f.nodeType ? [ f ] : f); else if (Ra.test(f)) {
                for (h = h || m.appendChild(b.createElement("div")), i = (Pa.exec(f) || [ "", "" ])[1].toLowerCase(), 
                k = Xa[i] || Xa._default, h.innerHTML = k[1] + f.replace(Oa, "<$1></$2>") + k[2], 
                e = k[0]; e--; ) h = h.lastChild;
                if (!ca.leadingWhitespace && Na.test(f) && n.push(b.createTextNode(Na.exec(f)[0])), 
                !ca.tbody) for (f = "table" !== i || Qa.test(f) ? "<table>" !== k[1] || Qa.test(f) ? 0 : h : h.firstChild, 
                e = f && f.childNodes.length; e--; ) ea.nodeName(j = f.childNodes[e], "tbody") && !j.childNodes.length && f.removeChild(j);
                for (ea.merge(n, h.childNodes), h.textContent = ""; h.firstChild; ) h.removeChild(h.firstChild);
                h = m.lastChild;
            } else n.push(b.createTextNode(f));
            for (h && m.removeChild(h), ca.appendChecked || ea.grep(q(n, "input"), r), o = 0; f = n[o++]; ) if ((!d || -1 === ea.inArray(f, d)) && (g = ea.contains(f.ownerDocument, f), 
            h = q(m.appendChild(f), "script"), g && v(h), c)) for (e = 0; f = h[e++]; ) Ua.test(f.type || "") && c.push(f);
            return h = null, m;
        },
        cleanData: function(a, b) {
            for (var c, d, e, f, g = 0, h = ea.expando, i = ea.cache, j = ca.deleteExpando, k = ea.event.special; null != (c = a[g]); g++) if ((b || ea.acceptData(c)) && (e = c[h], 
            f = e && i[e])) {
                if (f.events) for (d in f.events) k[d] ? ea.event.remove(c, d) : ea.removeEvent(c, d, f.handle);
                i[e] && (delete i[e], j ? delete c[h] : typeof c.removeAttribute !== xa ? c.removeAttribute(h) : c[h] = null, 
                W.push(e));
            }
        }
    }), ea.fn.extend({
        text: function(a) {
            return Da(this, function(a) {
                return void 0 === a ? ea.text(this) : this.empty().append((this[0] && this[0].ownerDocument || oa).createTextNode(a));
            }, null, a, arguments.length);
        },
        append: function() {
            return this.domManip(arguments, function(a) {
                if (1 === this.nodeType || 11 === this.nodeType || 9 === this.nodeType) {
                    var b = s(this, a);
                    b.appendChild(a);
                }
            });
        },
        prepend: function() {
            return this.domManip(arguments, function(a) {
                if (1 === this.nodeType || 11 === this.nodeType || 9 === this.nodeType) {
                    var b = s(this, a);
                    b.insertBefore(a, b.firstChild);
                }
            });
        },
        before: function() {
            return this.domManip(arguments, function(a) {
                this.parentNode && this.parentNode.insertBefore(a, this);
            });
        },
        after: function() {
            return this.domManip(arguments, function(a) {
                this.parentNode && this.parentNode.insertBefore(a, this.nextSibling);
            });
        },
        remove: function(a, b) {
            for (var c, d = a ? ea.filter(a, this) : this, e = 0; null != (c = d[e]); e++) b || 1 !== c.nodeType || ea.cleanData(q(c)), 
            c.parentNode && (b && ea.contains(c.ownerDocument, c) && v(q(c, "script")), c.parentNode.removeChild(c));
            return this;
        },
        empty: function() {
            for (var a, b = 0; null != (a = this[b]); b++) {
                for (1 === a.nodeType && ea.cleanData(q(a, !1)); a.firstChild; ) a.removeChild(a.firstChild);
                a.options && ea.nodeName(a, "select") && (a.options.length = 0);
            }
            return this;
        },
        clone: function(a, b) {
            return a = null == a ? !1 : a, b = null == b ? a : b, this.map(function() {
                return ea.clone(this, a, b);
            });
        },
        html: function(a) {
            return Da(this, function(a) {
                var b = this[0] || {}, c = 0, d = this.length;
                if (void 0 === a) return 1 === b.nodeType ? b.innerHTML.replace(La, "") : void 0;
                if ("string" == typeof a && !Sa.test(a) && (ca.htmlSerialize || !Ma.test(a)) && (ca.leadingWhitespace || !Na.test(a)) && !Xa[(Pa.exec(a) || [ "", "" ])[1].toLowerCase()]) {
                    a = a.replace(Oa, "<$1></$2>");
                    try {
                        for (;d > c; c++) b = this[c] || {}, 1 === b.nodeType && (ea.cleanData(q(b, !1)), 
                        b.innerHTML = a);
                        b = 0;
                    } catch (e) {}
                }
                b && this.empty().append(a);
            }, null, a, arguments.length);
        },
        replaceWith: function() {
            var a = arguments[0];
            return this.domManip(arguments, function(b) {
                a = this.parentNode, ea.cleanData(q(this)), a && a.replaceChild(b, this);
            }), a && (a.length || a.nodeType) ? this : this.remove();
        },
        detach: function(a) {
            return this.remove(a, !0);
        },
        domManip: function(a, b) {
            a = Y.apply([], a);
            var c, d, e, f, g, h, i = 0, j = this.length, k = this, l = j - 1, m = a[0], n = ea.isFunction(m);
            if (n || j > 1 && "string" == typeof m && !ca.checkClone && Ta.test(m)) return this.each(function(c) {
                var d = k.eq(c);
                n && (a[0] = m.call(this, c, d.html())), d.domManip(a, b);
            });
            if (j && (h = ea.buildFragment(a, this[0].ownerDocument, !1, this), c = h.firstChild, 
            1 === h.childNodes.length && (h = c), c)) {
                for (f = ea.map(q(h, "script"), t), e = f.length; j > i; i++) d = h, i !== l && (d = ea.clone(d, !0, !0), 
                e && ea.merge(f, q(d, "script"))), b.call(this[i], d, i);
                if (e) for (g = f[f.length - 1].ownerDocument, ea.map(f, u), i = 0; e > i; i++) d = f[i], 
                Ua.test(d.type || "") && !ea._data(d, "globalEval") && ea.contains(g, d) && (d.src ? ea._evalUrl && ea._evalUrl(d.src) : ea.globalEval((d.text || d.textContent || d.innerHTML || "").replace(Wa, "")));
                h = c = null;
            }
            return this;
        }
    }), ea.each({
        appendTo: "append",
        prependTo: "prepend",
        insertBefore: "before",
        insertAfter: "after",
        replaceAll: "replaceWith"
    }, function(a, b) {
        ea.fn[a] = function(a) {
            for (var c, d = 0, e = [], f = ea(a), g = f.length - 1; g >= d; d++) c = d === g ? this : this.clone(!0), 
            ea(f[d])[b](c), Z.apply(e, c.get());
            return this.pushStack(e);
        };
    });
    var $a, _a = {};
    !function() {
        var a;
        ca.shrinkWrapBlocks = function() {
            if (null != a) return a;
            a = !1;
            var b, c, d;
            return c = oa.getElementsByTagName("body")[0], c && c.style ? (b = oa.createElement("div"), 
            d = oa.createElement("div"), d.style.cssText = "position:absolute;border:0;width:0;height:0;top:0;left:-9999px", 
            c.appendChild(d).appendChild(b), typeof b.style.zoom !== xa && (b.style.cssText = "-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:1px;width:1px;zoom:1", 
            b.appendChild(oa.createElement("div")).style.width = "5px", a = 3 !== b.offsetWidth), 
            c.removeChild(d), a) : void 0;
        };
    }();
    var ab, bb, cb = /^margin/, db = new RegExp("^(" + Aa + ")(?!px)[a-z%]+$", "i"), eb = /^(top|right|bottom|left)$/;
    a.getComputedStyle ? (ab = function(b) {
        return b.ownerDocument.defaultView.opener ? b.ownerDocument.defaultView.getComputedStyle(b, null) : a.getComputedStyle(b, null);
    }, bb = function(a, b, c) {
        var d, e, f, g, h = a.style;
        return c = c || ab(a), g = c ? c.getPropertyValue(b) || c[b] : void 0, c && ("" !== g || ea.contains(a.ownerDocument, a) || (g = ea.style(a, b)), 
        db.test(g) && cb.test(b) && (d = h.width, e = h.minWidth, f = h.maxWidth, h.minWidth = h.maxWidth = h.width = g, 
        g = c.width, h.width = d, h.minWidth = e, h.maxWidth = f)), void 0 === g ? g : g + "";
    }) : oa.documentElement.currentStyle && (ab = function(a) {
        return a.currentStyle;
    }, bb = function(a, b, c) {
        var d, e, f, g, h = a.style;
        return c = c || ab(a), g = c ? c[b] : void 0, null == g && h && h[b] && (g = h[b]), 
        db.test(g) && !eb.test(b) && (d = h.left, e = a.runtimeStyle, f = e && e.left, f && (e.left = a.currentStyle.left), 
        h.left = "fontSize" === b ? "1em" : g, g = h.pixelLeft + "px", h.left = d, f && (e.left = f)), 
        void 0 === g ? g : g + "" || "auto";
    }), function() {
        function b() {
            var b, c, d, e;
            c = oa.getElementsByTagName("body")[0], c && c.style && (b = oa.createElement("div"), 
            d = oa.createElement("div"), d.style.cssText = "position:absolute;border:0;width:0;height:0;top:0;left:-9999px", 
            c.appendChild(d).appendChild(b), b.style.cssText = "-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute", 
            f = g = !1, i = !0, a.getComputedStyle && (f = "1%" !== (a.getComputedStyle(b, null) || {}).top, 
            g = "4px" === (a.getComputedStyle(b, null) || {
                width: "4px"
            }).width, e = b.appendChild(oa.createElement("div")), e.style.cssText = b.style.cssText = "-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0", 
            e.style.marginRight = e.style.width = "0", b.style.width = "1px", i = !parseFloat((a.getComputedStyle(e, null) || {}).marginRight), 
            b.removeChild(e)), b.innerHTML = "<table><tr><td></td><td>t</td></tr></table>", 
            e = b.getElementsByTagName("td"), e[0].style.cssText = "margin:0;border:0;padding:0;display:none", 
            h = 0 === e[0].offsetHeight, h && (e[0].style.display = "", e[1].style.display = "none", 
            h = 0 === e[0].offsetHeight), c.removeChild(d));
        }
        var c, d, e, f, g, h, i;
        c = oa.createElement("div"), c.innerHTML = "  <link/><table></table><a href='/a'>a</a><input type='checkbox'/>", 
        e = c.getElementsByTagName("a")[0], d = e && e.style, d && (d.cssText = "float:left;opacity:.5", 
        ca.opacity = "0.5" === d.opacity, ca.cssFloat = !!d.cssFloat, c.style.backgroundClip = "content-box", 
        c.cloneNode(!0).style.backgroundClip = "", ca.clearCloneStyle = "content-box" === c.style.backgroundClip, 
        ca.boxSizing = "" === d.boxSizing || "" === d.MozBoxSizing || "" === d.WebkitBoxSizing, 
        ea.extend(ca, {
            reliableHiddenOffsets: function() {
                return null == h && b(), h;
            },
            boxSizingReliable: function() {
                return null == g && b(), g;
            },
            pixelPosition: function() {
                return null == f && b(), f;
            },
            reliableMarginRight: function() {
                return null == i && b(), i;
            }
        }));
    }(), ea.swap = function(a, b, c, d) {
        var e, f, g = {};
        for (f in b) g[f] = a.style[f], a.style[f] = b[f];
        e = c.apply(a, d || []);
        for (f in b) a.style[f] = g[f];
        return e;
    };
    var fb = /alpha\([^)]*\)/i, gb = /opacity\s*=\s*([^)]*)/, hb = /^(none|table(?!-c[ea]).+)/, ib = new RegExp("^(" + Aa + ")(.*)$", "i"), jb = new RegExp("^([+-])=(" + Aa + ")", "i"), kb = {
        position: "absolute",
        visibility: "hidden",
        display: "block"
    }, lb = {
        letterSpacing: "0",
        fontWeight: "400"
    }, mb = [ "Webkit", "O", "Moz", "ms" ];
    ea.extend({
        cssHooks: {
            opacity: {
                get: function(a, b) {
                    if (b) {
                        var c = bb(a, "opacity");
                        return "" === c ? "1" : c;
                    }
                }
            }
        },
        cssNumber: {
            columnCount: !0,
            fillOpacity: !0,
            flexGrow: !0,
            flexShrink: !0,
            fontWeight: !0,
            lineHeight: !0,
            opacity: !0,
            order: !0,
            orphans: !0,
            widows: !0,
            zIndex: !0,
            zoom: !0
        },
        cssProps: {
            "float": ca.cssFloat ? "cssFloat" : "styleFloat"
        },
        style: function(a, b, c, d) {
            if (a && 3 !== a.nodeType && 8 !== a.nodeType && a.style) {
                var e, f, g, h = ea.camelCase(b), i = a.style;
                if (b = ea.cssProps[h] || (ea.cssProps[h] = B(i, h)), g = ea.cssHooks[b] || ea.cssHooks[h], 
                void 0 === c) return g && "get" in g && void 0 !== (e = g.get(a, !1, d)) ? e : i[b];
                if (f = typeof c, "string" === f && (e = jb.exec(c)) && (c = (e[1] + 1) * e[2] + parseFloat(ea.css(a, b)), 
                f = "number"), null != c && c === c && ("number" !== f || ea.cssNumber[h] || (c += "px"), 
                ca.clearCloneStyle || "" !== c || 0 !== b.indexOf("background") || (i[b] = "inherit"), 
                !(g && "set" in g && void 0 === (c = g.set(a, c, d))))) try {
                    i[b] = c;
                } catch (j) {}
            }
        },
        css: function(a, b, c, d) {
            var e, f, g, h = ea.camelCase(b);
            return b = ea.cssProps[h] || (ea.cssProps[h] = B(a.style, h)), g = ea.cssHooks[b] || ea.cssHooks[h], 
            g && "get" in g && (f = g.get(a, !0, c)), void 0 === f && (f = bb(a, b, d)), "normal" === f && b in lb && (f = lb[b]), 
            "" === c || c ? (e = parseFloat(f), c === !0 || ea.isNumeric(e) ? e || 0 : f) : f;
        }
    }), ea.each([ "height", "width" ], function(a, b) {
        ea.cssHooks[b] = {
            get: function(a, c, d) {
                return c ? hb.test(ea.css(a, "display")) && 0 === a.offsetWidth ? ea.swap(a, kb, function() {
                    return F(a, b, d);
                }) : F(a, b, d) : void 0;
            },
            set: function(a, c, d) {
                var e = d && ab(a);
                return D(a, c, d ? E(a, b, d, ca.boxSizing && "border-box" === ea.css(a, "boxSizing", !1, e), e) : 0);
            }
        };
    }), ca.opacity || (ea.cssHooks.opacity = {
        get: function(a, b) {
            return gb.test((b && a.currentStyle ? a.currentStyle.filter : a.style.filter) || "") ? .01 * parseFloat(RegExp.$1) + "" : b ? "1" : "";
        },
        set: function(a, b) {
            var c = a.style, d = a.currentStyle, e = ea.isNumeric(b) ? "alpha(opacity=" + 100 * b + ")" : "", f = d && d.filter || c.filter || "";
            c.zoom = 1, (b >= 1 || "" === b) && "" === ea.trim(f.replace(fb, "")) && c.removeAttribute && (c.removeAttribute("filter"), 
            "" === b || d && !d.filter) || (c.filter = fb.test(f) ? f.replace(fb, e) : f + " " + e);
        }
    }), ea.cssHooks.marginRight = A(ca.reliableMarginRight, function(a, b) {
        return b ? ea.swap(a, {
            display: "inline-block"
        }, bb, [ a, "marginRight" ]) : void 0;
    }), ea.each({
        margin: "",
        padding: "",
        border: "Width"
    }, function(a, b) {
        ea.cssHooks[a + b] = {
            expand: function(c) {
                for (var d = 0, e = {}, f = "string" == typeof c ? c.split(" ") : [ c ]; 4 > d; d++) e[a + Ba[d] + b] = f[d] || f[d - 2] || f[0];
                return e;
            }
        }, cb.test(a) || (ea.cssHooks[a + b].set = D);
    }), ea.fn.extend({
        css: function(a, b) {
            return Da(this, function(a, b, c) {
                var d, e, f = {}, g = 0;
                if (ea.isArray(b)) {
                    for (d = ab(a), e = b.length; e > g; g++) f[b[g]] = ea.css(a, b[g], !1, d);
                    return f;
                }
                return void 0 !== c ? ea.style(a, b, c) : ea.css(a, b);
            }, a, b, arguments.length > 1);
        },
        show: function() {
            return C(this, !0);
        },
        hide: function() {
            return C(this);
        },
        toggle: function(a) {
            return "boolean" == typeof a ? a ? this.show() : this.hide() : this.each(function() {
                Ca(this) ? ea(this).show() : ea(this).hide();
            });
        }
    }), ea.Tween = G, G.prototype = {
        constructor: G,
        init: function(a, b, c, d, e, f) {
            this.elem = a, this.prop = c, this.easing = e || "swing", this.options = b, this.start = this.now = this.cur(), 
            this.end = d, this.unit = f || (ea.cssNumber[c] ? "" : "px");
        },
        cur: function() {
            var a = G.propHooks[this.prop];
            return a && a.get ? a.get(this) : G.propHooks._default.get(this);
        },
        run: function(a) {
            var b, c = G.propHooks[this.prop];
            return this.options.duration ? this.pos = b = ea.easing[this.easing](a, this.options.duration * a, 0, 1, this.options.duration) : this.pos = b = a, 
            this.now = (this.end - this.start) * b + this.start, this.options.step && this.options.step.call(this.elem, this.now, this), 
            c && c.set ? c.set(this) : G.propHooks._default.set(this), this;
        }
    }, G.prototype.init.prototype = G.prototype, G.propHooks = {
        _default: {
            get: function(a) {
                var b;
                return null == a.elem[a.prop] || a.elem.style && null != a.elem.style[a.prop] ? (b = ea.css(a.elem, a.prop, ""), 
                b && "auto" !== b ? b : 0) : a.elem[a.prop];
            },
            set: function(a) {
                ea.fx.step[a.prop] ? ea.fx.step[a.prop](a) : a.elem.style && (null != a.elem.style[ea.cssProps[a.prop]] || ea.cssHooks[a.prop]) ? ea.style(a.elem, a.prop, a.now + a.unit) : a.elem[a.prop] = a.now;
            }
        }
    }, G.propHooks.scrollTop = G.propHooks.scrollLeft = {
        set: function(a) {
            a.elem.nodeType && a.elem.parentNode && (a.elem[a.prop] = a.now);
        }
    }, ea.easing = {
        linear: function(a) {
            return a;
        },
        swing: function(a) {
            return .5 - Math.cos(a * Math.PI) / 2;
        }
    }, ea.fx = G.prototype.init, ea.fx.step = {};
    var nb, ob, pb = /^(?:toggle|show|hide)$/, qb = new RegExp("^(?:([+-])=|)(" + Aa + ")([a-z%]*)$", "i"), rb = /queueHooks$/, sb = [ K ], tb = {
        "*": [ function(a, b) {
            var c = this.createTween(a, b), d = c.cur(), e = qb.exec(b), f = e && e[3] || (ea.cssNumber[a] ? "" : "px"), g = (ea.cssNumber[a] || "px" !== f && +d) && qb.exec(ea.css(c.elem, a)), h = 1, i = 20;
            if (g && g[3] !== f) {
                f = f || g[3], e = e || [], g = +d || 1;
                do h = h || ".5", g /= h, ea.style(c.elem, a, g + f); while (h !== (h = c.cur() / d) && 1 !== h && --i);
            }
            return e && (g = c.start = +g || +d || 0, c.unit = f, c.end = e[1] ? g + (e[1] + 1) * e[2] : +e[2]), 
            c;
        } ]
    };
    ea.Animation = ea.extend(M, {
        tweener: function(a, b) {
            ea.isFunction(a) ? (b = a, a = [ "*" ]) : a = a.split(" ");
            for (var c, d = 0, e = a.length; e > d; d++) c = a[d], tb[c] = tb[c] || [], tb[c].unshift(b);
        },
        prefilter: function(a, b) {
            b ? sb.unshift(a) : sb.push(a);
        }
    }), ea.speed = function(a, b, c) {
        var d = a && "object" == typeof a ? ea.extend({}, a) : {
            complete: c || !c && b || ea.isFunction(a) && a,
            duration: a,
            easing: c && b || b && !ea.isFunction(b) && b
        };
        return d.duration = ea.fx.off ? 0 : "number" == typeof d.duration ? d.duration : d.duration in ea.fx.speeds ? ea.fx.speeds[d.duration] : ea.fx.speeds._default, 
        (null == d.queue || d.queue === !0) && (d.queue = "fx"), d.old = d.complete, d.complete = function() {
            ea.isFunction(d.old) && d.old.call(this), d.queue && ea.dequeue(this, d.queue);
        }, d;
    }, ea.fn.extend({
        fadeTo: function(a, b, c, d) {
            return this.filter(Ca).css("opacity", 0).show().end().animate({
                opacity: b
            }, a, c, d);
        },
        animate: function(a, b, c, d) {
            var e = ea.isEmptyObject(a), f = ea.speed(b, c, d), g = function() {
                var b = M(this, ea.extend({}, a), f);
                (e || ea._data(this, "finish")) && b.stop(!0);
            };
            return g.finish = g, e || f.queue === !1 ? this.each(g) : this.queue(f.queue, g);
        },
        stop: function(a, b, c) {
            var d = function(a) {
                var b = a.stop;
                delete a.stop, b(c);
            };
            return "string" != typeof a && (c = b, b = a, a = void 0), b && a !== !1 && this.queue(a || "fx", []), 
            this.each(function() {
                var b = !0, e = null != a && a + "queueHooks", f = ea.timers, g = ea._data(this);
                if (e) g[e] && g[e].stop && d(g[e]); else for (e in g) g[e] && g[e].stop && rb.test(e) && d(g[e]);
                for (e = f.length; e--; ) f[e].elem !== this || null != a && f[e].queue !== a || (f[e].anim.stop(c), 
                b = !1, f.splice(e, 1));
                (b || !c) && ea.dequeue(this, a);
            });
        },
        finish: function(a) {
            return a !== !1 && (a = a || "fx"), this.each(function() {
                var b, c = ea._data(this), d = c[a + "queue"], e = c[a + "queueHooks"], f = ea.timers, g = d ? d.length : 0;
                for (c.finish = !0, ea.queue(this, a, []), e && e.stop && e.stop.call(this, !0), 
                b = f.length; b--; ) f[b].elem === this && f[b].queue === a && (f[b].anim.stop(!0), 
                f.splice(b, 1));
                for (b = 0; g > b; b++) d[b] && d[b].finish && d[b].finish.call(this);
                delete c.finish;
            });
        }
    }), ea.each([ "toggle", "show", "hide" ], function(a, b) {
        var c = ea.fn[b];
        ea.fn[b] = function(a, d, e) {
            return null == a || "boolean" == typeof a ? c.apply(this, arguments) : this.animate(I(b, !0), a, d, e);
        };
    }), ea.each({
        slideDown: I("show"),
        slideUp: I("hide"),
        slideToggle: I("toggle"),
        fadeIn: {
            opacity: "show"
        },
        fadeOut: {
            opacity: "hide"
        },
        fadeToggle: {
            opacity: "toggle"
        }
    }, function(a, b) {
        ea.fn[a] = function(a, c, d) {
            return this.animate(b, a, c, d);
        };
    }), ea.timers = [], ea.fx.tick = function() {
        var a, b = ea.timers, c = 0;
        for (nb = ea.now(); c < b.length; c++) a = b[c], a() || b[c] !== a || b.splice(c--, 1);
        b.length || ea.fx.stop(), nb = void 0;
    }, ea.fx.timer = function(a) {
        ea.timers.push(a), a() ? ea.fx.start() : ea.timers.pop();
    }, ea.fx.interval = 13, ea.fx.start = function() {
        ob || (ob = setInterval(ea.fx.tick, ea.fx.interval));
    }, ea.fx.stop = function() {
        clearInterval(ob), ob = null;
    }, ea.fx.speeds = {
        slow: 600,
        fast: 200,
        _default: 400
    }, ea.fn.delay = function(a, b) {
        return a = ea.fx ? ea.fx.speeds[a] || a : a, b = b || "fx", this.queue(b, function(b, c) {
            var d = setTimeout(b, a);
            c.stop = function() {
                clearTimeout(d);
            };
        });
    }, function() {
        var a, b, c, d, e;
        b = oa.createElement("div"), b.setAttribute("className", "t"), b.innerHTML = "  <link/><table></table><a href='/a'>a</a><input type='checkbox'/>", 
        d = b.getElementsByTagName("a")[0], c = oa.createElement("select"), e = c.appendChild(oa.createElement("option")), 
        a = b.getElementsByTagName("input")[0], d.style.cssText = "top:1px", ca.getSetAttribute = "t" !== b.className, 
        ca.style = /top/.test(d.getAttribute("style")), ca.hrefNormalized = "/a" === d.getAttribute("href"), 
        ca.checkOn = !!a.value, ca.optSelected = e.selected, ca.enctype = !!oa.createElement("form").enctype, 
        c.disabled = !0, ca.optDisabled = !e.disabled, a = oa.createElement("input"), a.setAttribute("value", ""), 
        ca.input = "" === a.getAttribute("value"), a.value = "t", a.setAttribute("type", "radio"), 
        ca.radioValue = "t" === a.value;
    }();
    var ub = /\r/g;
    ea.fn.extend({
        val: function(a) {
            var b, c, d, e = this[0];
            {
                if (arguments.length) return d = ea.isFunction(a), this.each(function(c) {
                    var e;
                    1 === this.nodeType && (e = d ? a.call(this, c, ea(this).val()) : a, null == e ? e = "" : "number" == typeof e ? e += "" : ea.isArray(e) && (e = ea.map(e, function(a) {
                        return null == a ? "" : a + "";
                    })), b = ea.valHooks[this.type] || ea.valHooks[this.nodeName.toLowerCase()], b && "set" in b && void 0 !== b.set(this, e, "value") || (this.value = e));
                });
                if (e) return b = ea.valHooks[e.type] || ea.valHooks[e.nodeName.toLowerCase()], 
                b && "get" in b && void 0 !== (c = b.get(e, "value")) ? c : (c = e.value, "string" == typeof c ? c.replace(ub, "") : null == c ? "" : c);
            }
        }
    }), ea.extend({
        valHooks: {
            option: {
                get: function(a) {
                    var b = ea.find.attr(a, "value");
                    return null != b ? b : ea.trim(ea.text(a));
                }
            },
            select: {
                get: function(a) {
                    for (var b, c, d = a.options, e = a.selectedIndex, f = "select-one" === a.type || 0 > e, g = f ? null : [], h = f ? e + 1 : d.length, i = 0 > e ? h : f ? e : 0; h > i; i++) if (c = d[i], 
                    (c.selected || i === e) && (ca.optDisabled ? !c.disabled : null === c.getAttribute("disabled")) && (!c.parentNode.disabled || !ea.nodeName(c.parentNode, "optgroup"))) {
                        if (b = ea(c).val(), f) return b;
                        g.push(b);
                    }
                    return g;
                },
                set: function(a, b) {
                    for (var c, d, e = a.options, f = ea.makeArray(b), g = e.length; g--; ) if (d = e[g], 
                    ea.inArray(ea.valHooks.option.get(d), f) >= 0) try {
                        d.selected = c = !0;
                    } catch (h) {
                        d.scrollHeight;
                    } else d.selected = !1;
                    return c || (a.selectedIndex = -1), e;
                }
            }
        }
    }), ea.each([ "radio", "checkbox" ], function() {
        ea.valHooks[this] = {
            set: function(a, b) {
                return ea.isArray(b) ? a.checked = ea.inArray(ea(a).val(), b) >= 0 : void 0;
            }
        }, ca.checkOn || (ea.valHooks[this].get = function(a) {
            return null === a.getAttribute("value") ? "on" : a.value;
        });
    });
    var vb, wb, xb = ea.expr.attrHandle, yb = /^(?:checked|selected)$/i, zb = ca.getSetAttribute, Ab = ca.input;
    ea.fn.extend({
        attr: function(a, b) {
            return Da(this, ea.attr, a, b, arguments.length > 1);
        },
        removeAttr: function(a) {
            return this.each(function() {
                ea.removeAttr(this, a);
            });
        }
    }), ea.extend({
        attr: function(a, b, c) {
            var d, e, f = a.nodeType;
            if (a && 3 !== f && 8 !== f && 2 !== f) return typeof a.getAttribute === xa ? ea.prop(a, b, c) : (1 === f && ea.isXMLDoc(a) || (b = b.toLowerCase(), 
            d = ea.attrHooks[b] || (ea.expr.match.bool.test(b) ? wb : vb)), void 0 === c ? d && "get" in d && null !== (e = d.get(a, b)) ? e : (e = ea.find.attr(a, b), 
            null == e ? void 0 : e) : null !== c ? d && "set" in d && void 0 !== (e = d.set(a, c, b)) ? e : (a.setAttribute(b, c + ""), 
            c) : void ea.removeAttr(a, b));
        },
        removeAttr: function(a, b) {
            var c, d, e = 0, f = b && b.match(ta);
            if (f && 1 === a.nodeType) for (;c = f[e++]; ) d = ea.propFix[c] || c, ea.expr.match.bool.test(c) ? Ab && zb || !yb.test(c) ? a[d] = !1 : a[ea.camelCase("default-" + c)] = a[d] = !1 : ea.attr(a, c, ""), 
            a.removeAttribute(zb ? c : d);
        },
        attrHooks: {
            type: {
                set: function(a, b) {
                    if (!ca.radioValue && "radio" === b && ea.nodeName(a, "input")) {
                        var c = a.value;
                        return a.setAttribute("type", b), c && (a.value = c), b;
                    }
                }
            }
        }
    }), wb = {
        set: function(a, b, c) {
            return b === !1 ? ea.removeAttr(a, c) : Ab && zb || !yb.test(c) ? a.setAttribute(!zb && ea.propFix[c] || c, c) : a[ea.camelCase("default-" + c)] = a[c] = !0, 
            c;
        }
    }, ea.each(ea.expr.match.bool.source.match(/\w+/g), function(a, b) {
        var c = xb[b] || ea.find.attr;
        xb[b] = Ab && zb || !yb.test(b) ? function(a, b, d) {
            var e, f;
            return d || (f = xb[b], xb[b] = e, e = null != c(a, b, d) ? b.toLowerCase() : null, 
            xb[b] = f), e;
        } : function(a, b, c) {
            return c ? void 0 : a[ea.camelCase("default-" + b)] ? b.toLowerCase() : null;
        };
    }), Ab && zb || (ea.attrHooks.value = {
        set: function(a, b, c) {
            return ea.nodeName(a, "input") ? void (a.defaultValue = b) : vb && vb.set(a, b, c);
        }
    }), zb || (vb = {
        set: function(a, b, c) {
            var d = a.getAttributeNode(c);
            return d || a.setAttributeNode(d = a.ownerDocument.createAttribute(c)), d.value = b += "", 
            "value" === c || b === a.getAttribute(c) ? b : void 0;
        }
    }, xb.id = xb.name = xb.coords = function(a, b, c) {
        var d;
        return c ? void 0 : (d = a.getAttributeNode(b)) && "" !== d.value ? d.value : null;
    }, ea.valHooks.button = {
        get: function(a, b) {
            var c = a.getAttributeNode(b);
            return c && c.specified ? c.value : void 0;
        },
        set: vb.set
    }, ea.attrHooks.contenteditable = {
        set: function(a, b, c) {
            vb.set(a, "" === b ? !1 : b, c);
        }
    }, ea.each([ "width", "height" ], function(a, b) {
        ea.attrHooks[b] = {
            set: function(a, c) {
                return "" === c ? (a.setAttribute(b, "auto"), c) : void 0;
            }
        };
    })), ca.style || (ea.attrHooks.style = {
        get: function(a) {
            return a.style.cssText || void 0;
        },
        set: function(a, b) {
            return a.style.cssText = b + "";
        }
    });
    var Bb = /^(?:input|select|textarea|button|object)$/i, Cb = /^(?:a|area)$/i;
    ea.fn.extend({
        prop: function(a, b) {
            return Da(this, ea.prop, a, b, arguments.length > 1);
        },
        removeProp: function(a) {
            return a = ea.propFix[a] || a, this.each(function() {
                try {
                    this[a] = void 0, delete this[a];
                } catch (b) {}
            });
        }
    }), ea.extend({
        propFix: {
            "for": "htmlFor",
            "class": "className"
        },
        prop: function(a, b, c) {
            var d, e, f, g = a.nodeType;
            if (a && 3 !== g && 8 !== g && 2 !== g) return f = 1 !== g || !ea.isXMLDoc(a), f && (b = ea.propFix[b] || b, 
            e = ea.propHooks[b]), void 0 !== c ? e && "set" in e && void 0 !== (d = e.set(a, c, b)) ? d : a[b] = c : e && "get" in e && null !== (d = e.get(a, b)) ? d : a[b];
        },
        propHooks: {
            tabIndex: {
                get: function(a) {
                    var b = ea.find.attr(a, "tabindex");
                    return b ? parseInt(b, 10) : Bb.test(a.nodeName) || Cb.test(a.nodeName) && a.href ? 0 : -1;
                }
            }
        }
    }), ca.hrefNormalized || ea.each([ "href", "src" ], function(a, b) {
        ea.propHooks[b] = {
            get: function(a) {
                return a.getAttribute(b, 4);
            }
        };
    }), ca.optSelected || (ea.propHooks.selected = {
        get: function(a) {
            var b = a.parentNode;
            return b && (b.selectedIndex, b.parentNode && b.parentNode.selectedIndex), null;
        }
    }), ea.each([ "tabIndex", "readOnly", "maxLength", "cellSpacing", "cellPadding", "rowSpan", "colSpan", "useMap", "frameBorder", "contentEditable" ], function() {
        ea.propFix[this.toLowerCase()] = this;
    }), ca.enctype || (ea.propFix.enctype = "encoding");
    var Db = /[\t\r\n\f]/g;
    ea.fn.extend({
        addClass: function(a) {
            var b, c, d, e, f, g, h = 0, i = this.length, j = "string" == typeof a && a;
            if (ea.isFunction(a)) return this.each(function(b) {
                ea(this).addClass(a.call(this, b, this.className));
            });
            if (j) for (b = (a || "").match(ta) || []; i > h; h++) if (c = this[h], d = 1 === c.nodeType && (c.className ? (" " + c.className + " ").replace(Db, " ") : " ")) {
                for (f = 0; e = b[f++]; ) d.indexOf(" " + e + " ") < 0 && (d += e + " ");
                g = ea.trim(d), c.className !== g && (c.className = g);
            }
            return this;
        },
        removeClass: function(a) {
            var b, c, d, e, f, g, h = 0, i = this.length, j = 0 === arguments.length || "string" == typeof a && a;
            if (ea.isFunction(a)) return this.each(function(b) {
                ea(this).removeClass(a.call(this, b, this.className));
            });
            if (j) for (b = (a || "").match(ta) || []; i > h; h++) if (c = this[h], d = 1 === c.nodeType && (c.className ? (" " + c.className + " ").replace(Db, " ") : "")) {
                for (f = 0; e = b[f++]; ) for (;d.indexOf(" " + e + " ") >= 0; ) d = d.replace(" " + e + " ", " ");
                g = a ? ea.trim(d) : "", c.className !== g && (c.className = g);
            }
            return this;
        },
        toggleClass: function(a, b) {
            var c = typeof a;
            return "boolean" == typeof b && "string" === c ? b ? this.addClass(a) : this.removeClass(a) : ea.isFunction(a) ? this.each(function(c) {
                ea(this).toggleClass(a.call(this, c, this.className, b), b);
            }) : this.each(function() {
                if ("string" === c) for (var b, d = 0, e = ea(this), f = a.match(ta) || []; b = f[d++]; ) e.hasClass(b) ? e.removeClass(b) : e.addClass(b); else (c === xa || "boolean" === c) && (this.className && ea._data(this, "__className__", this.className), 
                this.className = this.className || a === !1 ? "" : ea._data(this, "__className__") || "");
            });
        },
        hasClass: function(a) {
            for (var b = " " + a + " ", c = 0, d = this.length; d > c; c++) if (1 === this[c].nodeType && (" " + this[c].className + " ").replace(Db, " ").indexOf(b) >= 0) return !0;
            return !1;
        }
    }), ea.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "), function(a, b) {
        ea.fn[b] = function(a, c) {
            return arguments.length > 0 ? this.on(b, null, a, c) : this.trigger(b);
        };
    }), ea.fn.extend({
        hover: function(a, b) {
            return this.mouseenter(a).mouseleave(b || a);
        },
        bind: function(a, b, c) {
            return this.on(a, null, b, c);
        },
        unbind: function(a, b) {
            return this.off(a, null, b);
        },
        delegate: function(a, b, c, d) {
            return this.on(b, a, c, d);
        },
        undelegate: function(a, b, c) {
            return 1 === arguments.length ? this.off(a, "**") : this.off(b, a || "**", c);
        }
    });
    var Eb = ea.now(), Fb = /\?/, Gb = /(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;
    ea.parseJSON = function(b) {
        if (a.JSON && a.JSON.parse) return a.JSON.parse(b + "");
        var c, d = null, e = ea.trim(b + "");
        return e && !ea.trim(e.replace(Gb, function(a, b, e, f) {
            return c && b && (d = 0), 0 === d ? a : (c = e || b, d += !f - !e, "");
        })) ? Function("return " + e)() : ea.error("Invalid JSON: " + b);
    }, ea.parseXML = function(b) {
        var c, d;
        if (!b || "string" != typeof b) return null;
        try {
            a.DOMParser ? (d = new DOMParser(), c = d.parseFromString(b, "text/xml")) : (c = new ActiveXObject("Microsoft.XMLDOM"), 
            c.async = "false", c.loadXML(b));
        } catch (e) {
            c = void 0;
        }
        return c && c.documentElement && !c.getElementsByTagName("parsererror").length || ea.error("Invalid XML: " + b), 
        c;
    };
    var Hb, Ib, Jb = /#.*$/, Kb = /([?&])_=[^&]*/, Lb = /^(.*?):[ \t]*([^\r\n]*)\r?$/gm, Mb = /^(?:about|app|app-storage|.+-extension|file|res|widget):$/, Nb = /^(?:GET|HEAD)$/, Ob = /^\/\//, Pb = /^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/, Qb = {}, Rb = {}, Sb = "*/".concat("*");
    try {
        Ib = location.href;
    } catch (Tb) {
        Ib = oa.createElement("a"), Ib.href = "", Ib = Ib.href;
    }
    Hb = Pb.exec(Ib.toLowerCase()) || [], ea.extend({
        active: 0,
        lastModified: {},
        etag: {},
        ajaxSettings: {
            url: Ib,
            type: "GET",
            isLocal: Mb.test(Hb[1]),
            global: !0,
            processData: !0,
            async: !0,
            contentType: "application/x-www-form-urlencoded; charset=UTF-8",
            accepts: {
                "*": Sb,
                text: "text/plain",
                html: "text/html",
                xml: "application/xml, text/xml",
                json: "application/json, text/javascript"
            },
            contents: {
                xml: /xml/,
                html: /html/,
                json: /json/
            },
            responseFields: {
                xml: "responseXML",
                text: "responseText",
                json: "responseJSON"
            },
            converters: {
                "* text": String,
                "text html": !0,
                "text json": ea.parseJSON,
                "text xml": ea.parseXML
            },
            flatOptions: {
                url: !0,
                context: !0
            }
        },
        ajaxSetup: function(a, b) {
            return b ? P(P(a, ea.ajaxSettings), b) : P(ea.ajaxSettings, a);
        },
        ajaxPrefilter: N(Qb),
        ajaxTransport: N(Rb),
        ajax: function(a, b) {
            function c(a, b, c, d) {
                var e, k, r, s, u, w = b;
                2 !== t && (t = 2, h && clearTimeout(h), j = void 0, g = d || "", v.readyState = a > 0 ? 4 : 0, 
                e = a >= 200 && 300 > a || 304 === a, c && (s = Q(l, v, c)), s = R(l, s, v, e), 
                e ? (l.ifModified && (u = v.getResponseHeader("Last-Modified"), u && (ea.lastModified[f] = u), 
                u = v.getResponseHeader("etag"), u && (ea.etag[f] = u)), 204 === a || "HEAD" === l.type ? w = "nocontent" : 304 === a ? w = "notmodified" : (w = s.state, 
                k = s.data, r = s.error, e = !r)) : (r = w, (a || !w) && (w = "error", 0 > a && (a = 0))), 
                v.status = a, v.statusText = (b || w) + "", e ? o.resolveWith(m, [ k, w, v ]) : o.rejectWith(m, [ v, w, r ]), 
                v.statusCode(q), q = void 0, i && n.trigger(e ? "ajaxSuccess" : "ajaxError", [ v, l, e ? k : r ]), 
                p.fireWith(m, [ v, w ]), i && (n.trigger("ajaxComplete", [ v, l ]), --ea.active || ea.event.trigger("ajaxStop")));
            }
            "object" == typeof a && (b = a, a = void 0), b = b || {};
            var d, e, f, g, h, i, j, k, l = ea.ajaxSetup({}, b), m = l.context || l, n = l.context && (m.nodeType || m.jquery) ? ea(m) : ea.event, o = ea.Deferred(), p = ea.Callbacks("once memory"), q = l.statusCode || {}, r = {}, s = {}, t = 0, u = "canceled", v = {
                readyState: 0,
                getResponseHeader: function(a) {
                    var b;
                    if (2 === t) {
                        if (!k) for (k = {}; b = Lb.exec(g); ) k[b[1].toLowerCase()] = b[2];
                        b = k[a.toLowerCase()];
                    }
                    return null == b ? null : b;
                },
                getAllResponseHeaders: function() {
                    return 2 === t ? g : null;
                },
                setRequestHeader: function(a, b) {
                    var c = a.toLowerCase();
                    return t || (a = s[c] = s[c] || a, r[a] = b), this;
                },
                overrideMimeType: function(a) {
                    return t || (l.mimeType = a), this;
                },
                statusCode: function(a) {
                    var b;
                    if (a) if (2 > t) for (b in a) q[b] = [ q[b], a[b] ]; else v.always(a[v.status]);
                    return this;
                },
                abort: function(a) {
                    var b = a || u;
                    return j && j.abort(b), c(0, b), this;
                }
            };
            if (o.promise(v).complete = p.add, v.success = v.done, v.error = v.fail, l.url = ((a || l.url || Ib) + "").replace(Jb, "").replace(Ob, Hb[1] + "//"), 
            l.type = b.method || b.type || l.method || l.type, l.dataTypes = ea.trim(l.dataType || "*").toLowerCase().match(ta) || [ "" ], 
            null == l.crossDomain && (d = Pb.exec(l.url.toLowerCase()), l.crossDomain = !(!d || d[1] === Hb[1] && d[2] === Hb[2] && (d[3] || ("http:" === d[1] ? "80" : "443")) === (Hb[3] || ("http:" === Hb[1] ? "80" : "443")))), 
            l.data && l.processData && "string" != typeof l.data && (l.data = ea.param(l.data, l.traditional)), 
            O(Qb, l, b, v), 2 === t) return v;
            i = ea.event && l.global, i && 0 === ea.active++ && ea.event.trigger("ajaxStart"), 
            l.type = l.type.toUpperCase(), l.hasContent = !Nb.test(l.type), f = l.url, l.hasContent || (l.data && (f = l.url += (Fb.test(f) ? "&" : "?") + l.data, 
            delete l.data), l.cache === !1 && (l.url = Kb.test(f) ? f.replace(Kb, "$1_=" + Eb++) : f + (Fb.test(f) ? "&" : "?") + "_=" + Eb++)), 
            l.ifModified && (ea.lastModified[f] && v.setRequestHeader("If-Modified-Since", ea.lastModified[f]), 
            ea.etag[f] && v.setRequestHeader("If-None-Match", ea.etag[f])), (l.data && l.hasContent && l.contentType !== !1 || b.contentType) && v.setRequestHeader("Content-Type", l.contentType), 
            v.setRequestHeader("Accept", l.dataTypes[0] && l.accepts[l.dataTypes[0]] ? l.accepts[l.dataTypes[0]] + ("*" !== l.dataTypes[0] ? ", " + Sb + "; q=0.01" : "") : l.accepts["*"]);
            for (e in l.headers) v.setRequestHeader(e, l.headers[e]);
            if (l.beforeSend && (l.beforeSend.call(m, v, l) === !1 || 2 === t)) return v.abort();
            u = "abort";
            for (e in {
                success: 1,
                error: 1,
                complete: 1
            }) v[e](l[e]);
            if (j = O(Rb, l, b, v)) {
                v.readyState = 1, i && n.trigger("ajaxSend", [ v, l ]), l.async && l.timeout > 0 && (h = setTimeout(function() {
                    v.abort("timeout");
                }, l.timeout));
                try {
                    t = 1, j.send(r, c);
                } catch (w) {
                    if (!(2 > t)) throw w;
                    c(-1, w);
                }
            } else c(-1, "No Transport");
            return v;
        },
        getJSON: function(a, b, c) {
            return ea.get(a, b, c, "json");
        },
        getScript: function(a, b) {
            return ea.get(a, void 0, b, "script");
        }
    }), ea.each([ "get", "post" ], function(a, b) {
        ea[b] = function(a, c, d, e) {
            return ea.isFunction(c) && (e = e || d, d = c, c = void 0), ea.ajax({
                url: a,
                type: b,
                dataType: e,
                data: c,
                success: d
            });
        };
    }), ea._evalUrl = function(a) {
        return ea.ajax({
            url: a,
            type: "GET",
            dataType: "script",
            async: !1,
            global: !1,
            "throws": !0
        });
    }, ea.fn.extend({
        wrapAll: function(a) {
            if (ea.isFunction(a)) return this.each(function(b) {
                ea(this).wrapAll(a.call(this, b));
            });
            if (this[0]) {
                var b = ea(a, this[0].ownerDocument).eq(0).clone(!0);
                this[0].parentNode && b.insertBefore(this[0]), b.map(function() {
                    for (var a = this; a.firstChild && 1 === a.firstChild.nodeType; ) a = a.firstChild;
                    return a;
                }).append(this);
            }
            return this;
        },
        wrapInner: function(a) {
            return ea.isFunction(a) ? this.each(function(b) {
                ea(this).wrapInner(a.call(this, b));
            }) : this.each(function() {
                var b = ea(this), c = b.contents();
                c.length ? c.wrapAll(a) : b.append(a);
            });
        },
        wrap: function(a) {
            var b = ea.isFunction(a);
            return this.each(function(c) {
                ea(this).wrapAll(b ? a.call(this, c) : a);
            });
        },
        unwrap: function() {
            return this.parent().each(function() {
                ea.nodeName(this, "body") || ea(this).replaceWith(this.childNodes);
            }).end();
        }
    }), ea.expr.filters.hidden = function(a) {
        return a.offsetWidth <= 0 && a.offsetHeight <= 0 || !ca.reliableHiddenOffsets() && "none" === (a.style && a.style.display || ea.css(a, "display"));
    }, ea.expr.filters.visible = function(a) {
        return !ea.expr.filters.hidden(a);
    };
    var Ub = /%20/g, Vb = /\[\]$/, Wb = /\r?\n/g, Xb = /^(?:submit|button|image|reset|file)$/i, Yb = /^(?:input|select|textarea|keygen)/i;
    ea.param = function(a, b) {
        var c, d = [], e = function(a, b) {
            b = ea.isFunction(b) ? b() : null == b ? "" : b, d[d.length] = encodeURIComponent(a) + "=" + encodeURIComponent(b);
        };
        if (void 0 === b && (b = ea.ajaxSettings && ea.ajaxSettings.traditional), ea.isArray(a) || a.jquery && !ea.isPlainObject(a)) ea.each(a, function() {
            e(this.name, this.value);
        }); else for (c in a) S(c, a[c], b, e);
        return d.join("&").replace(Ub, "+");
    }, ea.fn.extend({
        serialize: function() {
            return ea.param(this.serializeArray());
        },
        serializeArray: function() {
            return this.map(function() {
                var a = ea.prop(this, "elements");
                return a ? ea.makeArray(a) : this;
            }).filter(function() {
                var a = this.type;
                return this.name && !ea(this).is(":disabled") && Yb.test(this.nodeName) && !Xb.test(a) && (this.checked || !Ea.test(a));
            }).map(function(a, b) {
                var c = ea(this).val();
                return null == c ? null : ea.isArray(c) ? ea.map(c, function(a) {
                    return {
                        name: b.name,
                        value: a.replace(Wb, "\r\n")
                    };
                }) : {
                    name: b.name,
                    value: c.replace(Wb, "\r\n")
                };
            }).get();
        }
    }), ea.ajaxSettings.xhr = void 0 !== a.ActiveXObject ? function() {
        return !this.isLocal && /^(get|post|head|put|delete|options)$/i.test(this.type) && T() || U();
    } : T;
    var Zb = 0, $b = {}, _b = ea.ajaxSettings.xhr();
    a.attachEvent && a.attachEvent("onunload", function() {
        for (var a in $b) $b[a](void 0, !0);
    }), ca.cors = !!_b && "withCredentials" in _b, _b = ca.ajax = !!_b, _b && ea.ajaxTransport(function(a) {
        if (!a.crossDomain || ca.cors) {
            var b;
            return {
                send: function(c, d) {
                    var e, f = a.xhr(), g = ++Zb;
                    if (f.open(a.type, a.url, a.async, a.username, a.password), a.xhrFields) for (e in a.xhrFields) f[e] = a.xhrFields[e];
                    a.mimeType && f.overrideMimeType && f.overrideMimeType(a.mimeType), a.crossDomain || c["X-Requested-With"] || (c["X-Requested-With"] = "XMLHttpRequest");
                    for (e in c) void 0 !== c[e] && f.setRequestHeader(e, c[e] + "");
                    f.send(a.hasContent && a.data || null), b = function(c, e) {
                        var h, i, j;
                        if (b && (e || 4 === f.readyState)) if (delete $b[g], b = void 0, f.onreadystatechange = ea.noop, 
                        e) 4 !== f.readyState && f.abort(); else {
                            j = {}, h = f.status, "string" == typeof f.responseText && (j.text = f.responseText);
                            try {
                                i = f.statusText;
                            } catch (k) {
                                i = "";
                            }
                            h || !a.isLocal || a.crossDomain ? 1223 === h && (h = 204) : h = j.text ? 200 : 404;
                        }
                        j && d(h, i, j, f.getAllResponseHeaders());
                    }, a.async ? 4 === f.readyState ? setTimeout(b) : f.onreadystatechange = $b[g] = b : b();
                },
                abort: function() {
                    b && b(void 0, !0);
                }
            };
        }
    }), ea.ajaxSetup({
        accepts: {
            script: "text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"
        },
        contents: {
            script: /(?:java|ecma)script/
        },
        converters: {
            "text script": function(a) {
                return ea.globalEval(a), a;
            }
        }
    }), ea.ajaxPrefilter("script", function(a) {
        void 0 === a.cache && (a.cache = !1), a.crossDomain && (a.type = "GET", a.global = !1);
    }), ea.ajaxTransport("script", function(a) {
        if (a.crossDomain) {
            var b, c = oa.head || ea("head")[0] || oa.documentElement;
            return {
                send: function(d, e) {
                    b = oa.createElement("script"), b.async = !0, a.scriptCharset && (b.charset = a.scriptCharset), 
                    b.src = a.url, b.onload = b.onreadystatechange = function(a, c) {
                        (c || !b.readyState || /loaded|complete/.test(b.readyState)) && (b.onload = b.onreadystatechange = null, 
                        b.parentNode && b.parentNode.removeChild(b), b = null, c || e(200, "success"));
                    }, c.insertBefore(b, c.firstChild);
                },
                abort: function() {
                    b && b.onload(void 0, !0);
                }
            };
        }
    });
    var ac = [], bc = /(=)\?(?=&|$)|\?\?/;
    ea.ajaxSetup({
        jsonp: "callback",
        jsonpCallback: function() {
            var a = ac.pop() || ea.expando + "_" + Eb++;
            return this[a] = !0, a;
        }
    }), ea.ajaxPrefilter("json jsonp", function(b, c, d) {
        var e, f, g, h = b.jsonp !== !1 && (bc.test(b.url) ? "url" : "string" == typeof b.data && !(b.contentType || "").indexOf("application/x-www-form-urlencoded") && bc.test(b.data) && "data");
        return h || "jsonp" === b.dataTypes[0] ? (e = b.jsonpCallback = ea.isFunction(b.jsonpCallback) ? b.jsonpCallback() : b.jsonpCallback, 
        h ? b[h] = b[h].replace(bc, "$1" + e) : b.jsonp !== !1 && (b.url += (Fb.test(b.url) ? "&" : "?") + b.jsonp + "=" + e), 
        b.converters["script json"] = function() {
            return g || ea.error(e + " was not called"), g[0];
        }, b.dataTypes[0] = "json", f = a[e], a[e] = function() {
            g = arguments;
        }, d.always(function() {
            a[e] = f, b[e] && (b.jsonpCallback = c.jsonpCallback, ac.push(e)), g && ea.isFunction(f) && f(g[0]), 
            g = f = void 0;
        }), "script") : void 0;
    }), ea.parseHTML = function(a, b, c) {
        if (!a || "string" != typeof a) return null;
        "boolean" == typeof b && (c = b, b = !1), b = b || oa;
        var d = la.exec(a), e = !c && [];
        return d ? [ b.createElement(d[1]) ] : (d = ea.buildFragment([ a ], b, e), e && e.length && ea(e).remove(), 
        ea.merge([], d.childNodes));
    };
    var cc = ea.fn.load;
    ea.fn.load = function(a, b, c) {
        if ("string" != typeof a && cc) return cc.apply(this, arguments);
        var d, e, f, g = this, h = a.indexOf(" ");
        return h >= 0 && (d = ea.trim(a.slice(h, a.length)), a = a.slice(0, h)), ea.isFunction(b) ? (c = b, 
        b = void 0) : b && "object" == typeof b && (f = "POST"), g.length > 0 && ea.ajax({
            url: a,
            type: f,
            dataType: "html",
            data: b
        }).done(function(a) {
            e = arguments, g.html(d ? ea("<div>").append(ea.parseHTML(a)).find(d) : a);
        }).complete(c && function(a, b) {
            g.each(c, e || [ a.responseText, b, a ]);
        }), this;
    }, ea.each([ "ajaxStart", "ajaxStop", "ajaxComplete", "ajaxError", "ajaxSuccess", "ajaxSend" ], function(a, b) {
        ea.fn[b] = function(a) {
            return this.on(b, a);
        };
    }), ea.expr.filters.animated = function(a) {
        return ea.grep(ea.timers, function(b) {
            return a === b.elem;
        }).length;
    };
    var dc = a.document.documentElement;
    ea.offset = {
        setOffset: function(a, b, c) {
            var d, e, f, g, h, i, j, k = ea.css(a, "position"), l = ea(a), m = {};
            "static" === k && (a.style.position = "relative"), h = l.offset(), f = ea.css(a, "top"), 
            i = ea.css(a, "left"), j = ("absolute" === k || "fixed" === k) && ea.inArray("auto", [ f, i ]) > -1, 
            j ? (d = l.position(), g = d.top, e = d.left) : (g = parseFloat(f) || 0, e = parseFloat(i) || 0), 
            ea.isFunction(b) && (b = b.call(a, c, h)), null != b.top && (m.top = b.top - h.top + g), 
            null != b.left && (m.left = b.left - h.left + e), "using" in b ? b.using.call(a, m) : l.css(m);
        }
    }, ea.fn.extend({
        offset: function(a) {
            if (arguments.length) return void 0 === a ? this : this.each(function(b) {
                ea.offset.setOffset(this, a, b);
            });
            var b, c, d = {
                top: 0,
                left: 0
            }, e = this[0], f = e && e.ownerDocument;
            if (f) return b = f.documentElement, ea.contains(b, e) ? (typeof e.getBoundingClientRect !== xa && (d = e.getBoundingClientRect()), 
            c = V(f), {
                top: d.top + (c.pageYOffset || b.scrollTop) - (b.clientTop || 0),
                left: d.left + (c.pageXOffset || b.scrollLeft) - (b.clientLeft || 0)
            }) : d;
        },
        position: function() {
            if (this[0]) {
                var a, b, c = {
                    top: 0,
                    left: 0
                }, d = this[0];
                return "fixed" === ea.css(d, "position") ? b = d.getBoundingClientRect() : (a = this.offsetParent(), 
                b = this.offset(), ea.nodeName(a[0], "html") || (c = a.offset()), c.top += ea.css(a[0], "borderTopWidth", !0), 
                c.left += ea.css(a[0], "borderLeftWidth", !0)), {
                    top: b.top - c.top - ea.css(d, "marginTop", !0),
                    left: b.left - c.left - ea.css(d, "marginLeft", !0)
                };
            }
        },
        offsetParent: function() {
            return this.map(function() {
                for (var a = this.offsetParent || dc; a && !ea.nodeName(a, "html") && "static" === ea.css(a, "position"); ) a = a.offsetParent;
                return a || dc;
            });
        }
    }), ea.each({
        scrollLeft: "pageXOffset",
        scrollTop: "pageYOffset"
    }, function(a, b) {
        var c = /Y/.test(b);
        ea.fn[a] = function(d) {
            return Da(this, function(a, d, e) {
                var f = V(a);
                return void 0 === e ? f ? b in f ? f[b] : f.document.documentElement[d] : a[d] : void (f ? f.scrollTo(c ? ea(f).scrollLeft() : e, c ? e : ea(f).scrollTop()) : a[d] = e);
            }, a, d, arguments.length, null);
        };
    }), ea.each([ "top", "left" ], function(a, b) {
        ea.cssHooks[b] = A(ca.pixelPosition, function(a, c) {
            return c ? (c = bb(a, b), db.test(c) ? ea(a).position()[b] + "px" : c) : void 0;
        });
    }), ea.each({
        Height: "height",
        Width: "width"
    }, function(a, b) {
        ea.each({
            padding: "inner" + a,
            content: b,
            "": "outer" + a
        }, function(c, d) {
            ea.fn[d] = function(d, e) {
                var f = arguments.length && (c || "boolean" != typeof d), g = c || (d === !0 || e === !0 ? "margin" : "border");
                return Da(this, function(b, c, d) {
                    var e;
                    return ea.isWindow(b) ? b.document.documentElement["client" + a] : 9 === b.nodeType ? (e = b.documentElement, 
                    Math.max(b.body["scroll" + a], e["scroll" + a], b.body["offset" + a], e["offset" + a], e["client" + a])) : void 0 === d ? ea.css(b, c, g) : ea.style(b, c, d, g);
                }, b, f ? d : void 0, f, null);
            };
        });
    }), ea.fn.size = function() {
        return this.length;
    }, ea.fn.andSelf = ea.fn.addBack, "function" == typeof define && define.amd && define("jquery", [], function() {
        return ea;
    });
    var ec = a.jQuery, fc = a.$;
    return ea.noConflict = function(b) {
        return a.$ === ea && (a.$ = fc), b && a.jQuery === ea && (a.jQuery = ec), ea;
    }, typeof b === xa && (a.jQuery = a.$ = ea), ea;
}), function(a) {
    "function" == typeof define && define.amd ? define([ "jquery" ], a) : a(jQuery);
}(function(a) {
    function b(b, d) {
        var e, f, g, h = b.nodeName.toLowerCase();
        return "area" === h ? (e = b.parentNode, f = e.name, b.href && f && "map" === e.nodeName.toLowerCase() ? (g = a("img[usemap='#" + f + "']")[0], 
        !!g && c(g)) : !1) : (/^(input|select|textarea|button|object)$/.test(h) ? !b.disabled : "a" === h ? b.href || d : d) && c(b);
    }
    function c(b) {
        return a.expr.filters.visible(b) && !a(b).parents().addBack().filter(function() {
            return "hidden" === a.css(this, "visibility");
        }).length;
    }
    a.ui = a.ui || {}, a.extend(a.ui, {
        version: "1.11.4",
        keyCode: {
            BACKSPACE: 8,
            COMMA: 188,
            DELETE: 46,
            DOWN: 40,
            END: 35,
            ENTER: 13,
            ESCAPE: 27,
            HOME: 36,
            LEFT: 37,
            PAGE_DOWN: 34,
            PAGE_UP: 33,
            PERIOD: 190,
            RIGHT: 39,
            SPACE: 32,
            TAB: 9,
            UP: 38
        }
    }), a.fn.extend({
        scrollParent: function(b) {
            var c = this.css("position"), d = "absolute" === c, e = b ? /(auto|scroll|hidden)/ : /(auto|scroll)/, f = this.parents().filter(function() {
                var b = a(this);
                return d && "static" === b.css("position") ? !1 : e.test(b.css("overflow") + b.css("overflow-y") + b.css("overflow-x"));
            }).eq(0);
            return "fixed" !== c && f.length ? f : a(this[0].ownerDocument || document);
        },
        uniqueId: function() {
            var a = 0;
            return function() {
                return this.each(function() {
                    this.id || (this.id = "ui-id-" + ++a);
                });
            };
        }(),
        removeUniqueId: function() {
            return this.each(function() {
                /^ui-id-\d+$/.test(this.id) && a(this).removeAttr("id");
            });
        }
    }), a.extend(a.expr[":"], {
        data: a.expr.createPseudo ? a.expr.createPseudo(function(b) {
            return function(c) {
                return !!a.data(c, b);
            };
        }) : function(b, c, d) {
            return !!a.data(b, d[3]);
        },
        focusable: function(c) {
            return b(c, !isNaN(a.attr(c, "tabindex")));
        },
        tabbable: function(c) {
            var d = a.attr(c, "tabindex"), e = isNaN(d);
            return (e || d >= 0) && b(c, !e);
        }
    }), a("<a>").outerWidth(1).jquery || a.each([ "Width", "Height" ], function(b, c) {
        function d(b, c, d, f) {
            return a.each(e, function() {
                c -= parseFloat(a.css(b, "padding" + this)) || 0, d && (c -= parseFloat(a.css(b, "border" + this + "Width")) || 0), 
                f && (c -= parseFloat(a.css(b, "margin" + this)) || 0);
            }), c;
        }
        var e = "Width" === c ? [ "Left", "Right" ] : [ "Top", "Bottom" ], f = c.toLowerCase(), g = {
            innerWidth: a.fn.innerWidth,
            innerHeight: a.fn.innerHeight,
            outerWidth: a.fn.outerWidth,
            outerHeight: a.fn.outerHeight
        };
        a.fn["inner" + c] = function(b) {
            return void 0 === b ? g["inner" + c].call(this) : this.each(function() {
                a(this).css(f, d(this, b) + "px");
            });
        }, a.fn["outer" + c] = function(b, e) {
            return "number" != typeof b ? g["outer" + c].call(this, b) : this.each(function() {
                a(this).css(f, d(this, b, !0, e) + "px");
            });
        };
    }), a.fn.addBack || (a.fn.addBack = function(a) {
        return this.add(null == a ? this.prevObject : this.prevObject.filter(a));
    }), a("<a>").data("a-b", "a").removeData("a-b").data("a-b") && (a.fn.removeData = function(b) {
        return function(c) {
            return arguments.length ? b.call(this, a.camelCase(c)) : b.call(this);
        };
    }(a.fn.removeData)), a.ui.ie = !!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase()), 
    a.fn.extend({
        focus: function(b) {
            return function(c, d) {
                return "number" == typeof c ? this.each(function() {
                    var b = this;
                    setTimeout(function() {
                        a(b).focus(), d && d.call(b);
                    }, c);
                }) : b.apply(this, arguments);
            };
        }(a.fn.focus),
        disableSelection: function() {
            var a = "onselectstart" in document.createElement("div") ? "selectstart" : "mousedown";
            return function() {
                return this.bind(a + ".ui-disableSelection", function(a) {
                    a.preventDefault();
                });
            };
        }(),
        enableSelection: function() {
            return this.unbind(".ui-disableSelection");
        },
        zIndex: function(b) {
            if (void 0 !== b) return this.css("zIndex", b);
            if (this.length) for (var c, d, e = a(this[0]); e.length && e[0] !== document; ) {
                if (c = e.css("position"), ("absolute" === c || "relative" === c || "fixed" === c) && (d = parseInt(e.css("zIndex"), 10), 
                !isNaN(d) && 0 !== d)) return d;
                e = e.parent();
            }
            return 0;
        }
    }), a.ui.plugin = {
        add: function(b, c, d) {
            var e, f = a.ui[b].prototype;
            for (e in d) f.plugins[e] = f.plugins[e] || [], f.plugins[e].push([ c, d[e] ]);
        },
        call: function(a, b, c, d) {
            var e, f = a.plugins[b];
            if (f && (d || a.element[0].parentNode && 11 !== a.element[0].parentNode.nodeType)) for (e = 0; e < f.length; e++) a.options[f[e][0]] && f[e][1].apply(a.element, c);
        }
    };
    var d = 0, e = Array.prototype.slice;
    a.cleanData = function(b) {
        return function(c) {
            var d, e, f;
            for (f = 0; null != (e = c[f]); f++) try {
                d = a._data(e, "events"), d && d.remove && a(e).triggerHandler("remove");
            } catch (g) {}
            b(c);
        };
    }(a.cleanData), a.widget = function(b, c, d) {
        var e, f, g, h, i = {}, j = b.split(".")[0];
        return b = b.split(".")[1], e = j + "-" + b, d || (d = c, c = a.Widget), a.expr[":"][e.toLowerCase()] = function(b) {
            return !!a.data(b, e);
        }, a[j] = a[j] || {}, f = a[j][b], g = a[j][b] = function(a, b) {
            return this._createWidget ? void (arguments.length && this._createWidget(a, b)) : new g(a, b);
        }, a.extend(g, f, {
            version: d.version,
            _proto: a.extend({}, d),
            _childConstructors: []
        }), h = new c(), h.options = a.widget.extend({}, h.options), a.each(d, function(b, d) {
            return a.isFunction(d) ? void (i[b] = function() {
                var a = function() {
                    return c.prototype[b].apply(this, arguments);
                }, e = function(a) {
                    return c.prototype[b].apply(this, a);
                };
                return function() {
                    var b, c = this._super, f = this._superApply;
                    return this._super = a, this._superApply = e, b = d.apply(this, arguments), this._super = c, 
                    this._superApply = f, b;
                };
            }()) : void (i[b] = d);
        }), g.prototype = a.widget.extend(h, {
            widgetEventPrefix: f ? h.widgetEventPrefix || b : b
        }, i, {
            constructor: g,
            namespace: j,
            widgetName: b,
            widgetFullName: e
        }), f ? (a.each(f._childConstructors, function(b, c) {
            var d = c.prototype;
            a.widget(d.namespace + "." + d.widgetName, g, c._proto);
        }), delete f._childConstructors) : c._childConstructors.push(g), a.widget.bridge(b, g), 
        g;
    }, a.widget.extend = function(b) {
        for (var c, d, f = e.call(arguments, 1), g = 0, h = f.length; h > g; g++) for (c in f[g]) d = f[g][c], 
        f[g].hasOwnProperty(c) && void 0 !== d && (a.isPlainObject(d) ? b[c] = a.isPlainObject(b[c]) ? a.widget.extend({}, b[c], d) : a.widget.extend({}, d) : b[c] = d);
        return b;
    }, a.widget.bridge = function(b, c) {
        var d = c.prototype.widgetFullName || b;
        a.fn[b] = function(f) {
            var g = "string" == typeof f, h = e.call(arguments, 1), i = this;
            return g ? this.each(function() {
                var c, e = a.data(this, d);
                return "instance" === f ? (i = e, !1) : e ? a.isFunction(e[f]) && "_" !== f.charAt(0) ? (c = e[f].apply(e, h), 
                c !== e && void 0 !== c ? (i = c && c.jquery ? i.pushStack(c.get()) : c, !1) : void 0) : a.error("no such method '" + f + "' for " + b + " widget instance") : a.error("cannot call methods on " + b + " prior to initialization; attempted to call method '" + f + "'");
            }) : (h.length && (f = a.widget.extend.apply(null, [ f ].concat(h))), this.each(function() {
                var b = a.data(this, d);
                b ? (b.option(f || {}), b._init && b._init()) : a.data(this, d, new c(f, this));
            })), i;
        };
    }, a.Widget = function() {}, a.Widget._childConstructors = [], a.Widget.prototype = {
        widgetName: "widget",
        widgetEventPrefix: "",
        defaultElement: "<div>",
        options: {
            disabled: !1,
            create: null
        },
        _createWidget: function(b, c) {
            c = a(c || this.defaultElement || this)[0], this.element = a(c), this.uuid = d++, 
            this.eventNamespace = "." + this.widgetName + this.uuid, this.bindings = a(), this.hoverable = a(), 
            this.focusable = a(), c !== this && (a.data(c, this.widgetFullName, this), this._on(!0, this.element, {
                remove: function(a) {
                    a.target === c && this.destroy();
                }
            }), this.document = a(c.style ? c.ownerDocument : c.document || c), this.window = a(this.document[0].defaultView || this.document[0].parentWindow)), 
            this.options = a.widget.extend({}, this.options, this._getCreateOptions(), b), this._create(), 
            this._trigger("create", null, this._getCreateEventData()), this._init();
        },
        _getCreateOptions: a.noop,
        _getCreateEventData: a.noop,
        _create: a.noop,
        _init: a.noop,
        destroy: function() {
            this._destroy(), this.element.unbind(this.eventNamespace).removeData(this.widgetFullName).removeData(a.camelCase(this.widgetFullName)), 
            this.widget().unbind(this.eventNamespace).removeAttr("aria-disabled").removeClass(this.widgetFullName + "-disabled ui-state-disabled"), 
            this.bindings.unbind(this.eventNamespace), this.hoverable.removeClass("ui-state-hover"), 
            this.focusable.removeClass("ui-state-focus");
        },
        _destroy: a.noop,
        widget: function() {
            return this.element;
        },
        option: function(b, c) {
            var d, e, f, g = b;
            if (0 === arguments.length) return a.widget.extend({}, this.options);
            if ("string" == typeof b) if (g = {}, d = b.split("."), b = d.shift(), d.length) {
                for (e = g[b] = a.widget.extend({}, this.options[b]), f = 0; f < d.length - 1; f++) e[d[f]] = e[d[f]] || {}, 
                e = e[d[f]];
                if (b = d.pop(), 1 === arguments.length) return void 0 === e[b] ? null : e[b];
                e[b] = c;
            } else {
                if (1 === arguments.length) return void 0 === this.options[b] ? null : this.options[b];
                g[b] = c;
            }
            return this._setOptions(g), this;
        },
        _setOptions: function(a) {
            var b;
            for (b in a) this._setOption(b, a[b]);
            return this;
        },
        _setOption: function(a, b) {
            return this.options[a] = b, "disabled" === a && (this.widget().toggleClass(this.widgetFullName + "-disabled", !!b), 
            b && (this.hoverable.removeClass("ui-state-hover"), this.focusable.removeClass("ui-state-focus"))), 
            this;
        },
        enable: function() {
            return this._setOptions({
                disabled: !1
            });
        },
        disable: function() {
            return this._setOptions({
                disabled: !0
            });
        },
        _on: function(b, c, d) {
            var e, f = this;
            "boolean" != typeof b && (d = c, c = b, b = !1), d ? (c = e = a(c), this.bindings = this.bindings.add(c)) : (d = c, 
            c = this.element, e = this.widget()), a.each(d, function(d, g) {
                function h() {
                    return b || f.options.disabled !== !0 && !a(this).hasClass("ui-state-disabled") ? ("string" == typeof g ? f[g] : g).apply(f, arguments) : void 0;
                }
                "string" != typeof g && (h.guid = g.guid = g.guid || h.guid || a.guid++);
                var i = d.match(/^([\w:-]*)\s*(.*)$/), j = i[1] + f.eventNamespace, k = i[2];
                k ? e.delegate(k, j, h) : c.bind(j, h);
            });
        },
        _off: function(b, c) {
            c = (c || "").split(" ").join(this.eventNamespace + " ") + this.eventNamespace, 
            b.unbind(c).undelegate(c), this.bindings = a(this.bindings.not(b).get()), this.focusable = a(this.focusable.not(b).get()), 
            this.hoverable = a(this.hoverable.not(b).get());
        },
        _delay: function(a, b) {
            function c() {
                return ("string" == typeof a ? d[a] : a).apply(d, arguments);
            }
            var d = this;
            return setTimeout(c, b || 0);
        },
        _hoverable: function(b) {
            this.hoverable = this.hoverable.add(b), this._on(b, {
                mouseenter: function(b) {
                    a(b.currentTarget).addClass("ui-state-hover");
                },
                mouseleave: function(b) {
                    a(b.currentTarget).removeClass("ui-state-hover");
                }
            });
        },
        _focusable: function(b) {
            this.focusable = this.focusable.add(b), this._on(b, {
                focusin: function(b) {
                    a(b.currentTarget).addClass("ui-state-focus");
                },
                focusout: function(b) {
                    a(b.currentTarget).removeClass("ui-state-focus");
                }
            });
        },
        _trigger: function(b, c, d) {
            var e, f, g = this.options[b];
            if (d = d || {}, c = a.Event(c), c.type = (b === this.widgetEventPrefix ? b : this.widgetEventPrefix + b).toLowerCase(), 
            c.target = this.element[0], f = c.originalEvent) for (e in f) e in c || (c[e] = f[e]);
            return this.element.trigger(c, d), !(a.isFunction(g) && g.apply(this.element[0], [ c ].concat(d)) === !1 || c.isDefaultPrevented());
        }
    }, a.each({
        show: "fadeIn",
        hide: "fadeOut"
    }, function(b, c) {
        a.Widget.prototype["_" + b] = function(d, e, f) {
            "string" == typeof e && (e = {
                effect: e
            });
            var g, h = e ? e === !0 || "number" == typeof e ? c : e.effect || c : b;
            e = e || {}, "number" == typeof e && (e = {
                duration: e
            }), g = !a.isEmptyObject(e), e.complete = f, e.delay && d.delay(e.delay), g && a.effects && a.effects.effect[h] ? d[b](e) : h !== b && d[h] ? d[h](e.duration, e.easing, f) : d.queue(function(c) {
                a(this)[b](), f && f.call(d[0]), c();
            });
        };
    });
    var f = (a.widget, !1);
    a(document).mouseup(function() {
        f = !1;
    });
    a.widget("ui.mouse", {
        version: "1.11.4",
        options: {
            cancel: "input,textarea,button,select,option",
            distance: 1,
            delay: 0
        },
        _mouseInit: function() {
            var b = this;
            this.element.bind("mousedown." + this.widgetName, function(a) {
                return b._mouseDown(a);
            }).bind("click." + this.widgetName, function(c) {
                return !0 === a.data(c.target, b.widgetName + ".preventClickEvent") ? (a.removeData(c.target, b.widgetName + ".preventClickEvent"), 
                c.stopImmediatePropagation(), !1) : void 0;
            }), this.started = !1;
        },
        _mouseDestroy: function() {
            this.element.unbind("." + this.widgetName), this._mouseMoveDelegate && this.document.unbind("mousemove." + this.widgetName, this._mouseMoveDelegate).unbind("mouseup." + this.widgetName, this._mouseUpDelegate);
        },
        _mouseDown: function(b) {
            if (!f) {
                this._mouseMoved = !1, this._mouseStarted && this._mouseUp(b), this._mouseDownEvent = b;
                var c = this, d = 1 === b.which, e = "string" == typeof this.options.cancel && b.target.nodeName ? a(b.target).closest(this.options.cancel).length : !1;
                return d && !e && this._mouseCapture(b) ? (this.mouseDelayMet = !this.options.delay, 
                this.mouseDelayMet || (this._mouseDelayTimer = setTimeout(function() {
                    c.mouseDelayMet = !0;
                }, this.options.delay)), this._mouseDistanceMet(b) && this._mouseDelayMet(b) && (this._mouseStarted = this._mouseStart(b) !== !1, 
                !this._mouseStarted) ? (b.preventDefault(), !0) : (!0 === a.data(b.target, this.widgetName + ".preventClickEvent") && a.removeData(b.target, this.widgetName + ".preventClickEvent"), 
                this._mouseMoveDelegate = function(a) {
                    return c._mouseMove(a);
                }, this._mouseUpDelegate = function(a) {
                    return c._mouseUp(a);
                }, this.document.bind("mousemove." + this.widgetName, this._mouseMoveDelegate).bind("mouseup." + this.widgetName, this._mouseUpDelegate), 
                b.preventDefault(), f = !0, !0)) : !0;
            }
        },
        _mouseMove: function(b) {
            if (this._mouseMoved) {
                if (a.ui.ie && (!document.documentMode || document.documentMode < 9) && !b.button) return this._mouseUp(b);
                if (!b.which) return this._mouseUp(b);
            }
            return (b.which || b.button) && (this._mouseMoved = !0), this._mouseStarted ? (this._mouseDrag(b), 
            b.preventDefault()) : (this._mouseDistanceMet(b) && this._mouseDelayMet(b) && (this._mouseStarted = this._mouseStart(this._mouseDownEvent, b) !== !1, 
            this._mouseStarted ? this._mouseDrag(b) : this._mouseUp(b)), !this._mouseStarted);
        },
        _mouseUp: function(b) {
            return this.document.unbind("mousemove." + this.widgetName, this._mouseMoveDelegate).unbind("mouseup." + this.widgetName, this._mouseUpDelegate), 
            this._mouseStarted && (this._mouseStarted = !1, b.target === this._mouseDownEvent.target && a.data(b.target, this.widgetName + ".preventClickEvent", !0), 
            this._mouseStop(b)), f = !1, !1;
        },
        _mouseDistanceMet: function(a) {
            return Math.max(Math.abs(this._mouseDownEvent.pageX - a.pageX), Math.abs(this._mouseDownEvent.pageY - a.pageY)) >= this.options.distance;
        },
        _mouseDelayMet: function() {
            return this.mouseDelayMet;
        },
        _mouseStart: function() {},
        _mouseDrag: function() {},
        _mouseStop: function() {},
        _mouseCapture: function() {
            return !0;
        }
    });
    !function() {
        function b(a, b, c) {
            return [ parseFloat(a[0]) * (n.test(a[0]) ? b / 100 : 1), parseFloat(a[1]) * (n.test(a[1]) ? c / 100 : 1) ];
        }
        function c(b, c) {
            return parseInt(a.css(b, c), 10) || 0;
        }
        function d(b) {
            var c = b[0];
            return 9 === c.nodeType ? {
                width: b.width(),
                height: b.height(),
                offset: {
                    top: 0,
                    left: 0
                }
            } : a.isWindow(c) ? {
                width: b.width(),
                height: b.height(),
                offset: {
                    top: b.scrollTop(),
                    left: b.scrollLeft()
                }
            } : c.preventDefault ? {
                width: 0,
                height: 0,
                offset: {
                    top: c.pageY,
                    left: c.pageX
                }
            } : {
                width: b.outerWidth(),
                height: b.outerHeight(),
                offset: b.offset()
            };
        }
        a.ui = a.ui || {};
        var e, f, g = Math.max, h = Math.abs, i = Math.round, j = /left|center|right/, k = /top|center|bottom/, l = /[\+\-]\d+(\.[\d]+)?%?/, m = /^\w+/, n = /%$/, o = a.fn.position;
        a.position = {
            scrollbarWidth: function() {
                if (void 0 !== e) return e;
                var b, c, d = a("<div style='display:block;position:absolute;width:50px;height:50px;overflow:hidden;'><div style='height:100px;width:auto;'></div></div>"), f = d.children()[0];
                return a("body").append(d), b = f.offsetWidth, d.css("overflow", "scroll"), c = f.offsetWidth, 
                b === c && (c = d[0].clientWidth), d.remove(), e = b - c;
            },
            getScrollInfo: function(b) {
                var c = b.isWindow || b.isDocument ? "" : b.element.css("overflow-x"), d = b.isWindow || b.isDocument ? "" : b.element.css("overflow-y"), e = "scroll" === c || "auto" === c && b.width < b.element[0].scrollWidth, f = "scroll" === d || "auto" === d && b.height < b.element[0].scrollHeight;
                return {
                    width: f ? a.position.scrollbarWidth() : 0,
                    height: e ? a.position.scrollbarWidth() : 0
                };
            },
            getWithinInfo: function(b) {
                var c = a(b || window), d = a.isWindow(c[0]), e = !!c[0] && 9 === c[0].nodeType;
                return {
                    element: c,
                    isWindow: d,
                    isDocument: e,
                    offset: c.offset() || {
                        left: 0,
                        top: 0
                    },
                    scrollLeft: c.scrollLeft(),
                    scrollTop: c.scrollTop(),
                    width: d || e ? c.width() : c.outerWidth(),
                    height: d || e ? c.height() : c.outerHeight()
                };
            }
        }, a.fn.position = function(e) {
            if (!e || !e.of) return o.apply(this, arguments);
            e = a.extend({}, e);
            var n, p, q, r, s, t, u = a(e.of), v = a.position.getWithinInfo(e.within), w = a.position.getScrollInfo(v), x = (e.collision || "flip").split(" "), y = {};
            return t = d(u), u[0].preventDefault && (e.at = "left top"), p = t.width, q = t.height, 
            r = t.offset, s = a.extend({}, r), a.each([ "my", "at" ], function() {
                var a, b, c = (e[this] || "").split(" ");
                1 === c.length && (c = j.test(c[0]) ? c.concat([ "center" ]) : k.test(c[0]) ? [ "center" ].concat(c) : [ "center", "center" ]), 
                c[0] = j.test(c[0]) ? c[0] : "center", c[1] = k.test(c[1]) ? c[1] : "center", a = l.exec(c[0]), 
                b = l.exec(c[1]), y[this] = [ a ? a[0] : 0, b ? b[0] : 0 ], e[this] = [ m.exec(c[0])[0], m.exec(c[1])[0] ];
            }), 1 === x.length && (x[1] = x[0]), "right" === e.at[0] ? s.left += p : "center" === e.at[0] && (s.left += p / 2), 
            "bottom" === e.at[1] ? s.top += q : "center" === e.at[1] && (s.top += q / 2), n = b(y.at, p, q), 
            s.left += n[0], s.top += n[1], this.each(function() {
                var d, j, k = a(this), l = k.outerWidth(), m = k.outerHeight(), o = c(this, "marginLeft"), t = c(this, "marginTop"), z = l + o + c(this, "marginRight") + w.width, A = m + t + c(this, "marginBottom") + w.height, B = a.extend({}, s), C = b(y.my, k.outerWidth(), k.outerHeight());
                "right" === e.my[0] ? B.left -= l : "center" === e.my[0] && (B.left -= l / 2), "bottom" === e.my[1] ? B.top -= m : "center" === e.my[1] && (B.top -= m / 2), 
                B.left += C[0], B.top += C[1], f || (B.left = i(B.left), B.top = i(B.top)), d = {
                    marginLeft: o,
                    marginTop: t
                }, a.each([ "left", "top" ], function(b, c) {
                    a.ui.position[x[b]] && a.ui.position[x[b]][c](B, {
                        targetWidth: p,
                        targetHeight: q,
                        elemWidth: l,
                        elemHeight: m,
                        collisionPosition: d,
                        collisionWidth: z,
                        collisionHeight: A,
                        offset: [ n[0] + C[0], n[1] + C[1] ],
                        my: e.my,
                        at: e.at,
                        within: v,
                        elem: k
                    });
                }), e.using && (j = function(a) {
                    var b = r.left - B.left, c = b + p - l, d = r.top - B.top, f = d + q - m, i = {
                        target: {
                            element: u,
                            left: r.left,
                            top: r.top,
                            width: p,
                            height: q
                        },
                        element: {
                            element: k,
                            left: B.left,
                            top: B.top,
                            width: l,
                            height: m
                        },
                        horizontal: 0 > c ? "left" : b > 0 ? "right" : "center",
                        vertical: 0 > f ? "top" : d > 0 ? "bottom" : "middle"
                    };
                    l > p && h(b + c) < p && (i.horizontal = "center"), m > q && h(d + f) < q && (i.vertical = "middle"), 
                    g(h(b), h(c)) > g(h(d), h(f)) ? i.important = "horizontal" : i.important = "vertical", 
                    e.using.call(this, a, i);
                }), k.offset(a.extend(B, {
                    using: j
                }));
            });
        }, a.ui.position = {
            fit: {
                left: function(a, b) {
                    var c, d = b.within, e = d.isWindow ? d.scrollLeft : d.offset.left, f = d.width, h = a.left - b.collisionPosition.marginLeft, i = e - h, j = h + b.collisionWidth - f - e;
                    b.collisionWidth > f ? i > 0 && 0 >= j ? (c = a.left + i + b.collisionWidth - f - e, 
                    a.left += i - c) : j > 0 && 0 >= i ? a.left = e : i > j ? a.left = e + f - b.collisionWidth : a.left = e : i > 0 ? a.left += i : j > 0 ? a.left -= j : a.left = g(a.left - h, a.left);
                },
                top: function(a, b) {
                    var c, d = b.within, e = d.isWindow ? d.scrollTop : d.offset.top, f = b.within.height, h = a.top - b.collisionPosition.marginTop, i = e - h, j = h + b.collisionHeight - f - e;
                    b.collisionHeight > f ? i > 0 && 0 >= j ? (c = a.top + i + b.collisionHeight - f - e, 
                    a.top += i - c) : j > 0 && 0 >= i ? a.top = e : i > j ? a.top = e + f - b.collisionHeight : a.top = e : i > 0 ? a.top += i : j > 0 ? a.top -= j : a.top = g(a.top - h, a.top);
                }
            },
            flip: {
                left: function(a, b) {
                    var c, d, e = b.within, f = e.offset.left + e.scrollLeft, g = e.width, i = e.isWindow ? e.scrollLeft : e.offset.left, j = a.left - b.collisionPosition.marginLeft, k = j - i, l = j + b.collisionWidth - g - i, m = "left" === b.my[0] ? -b.elemWidth : "right" === b.my[0] ? b.elemWidth : 0, n = "left" === b.at[0] ? b.targetWidth : "right" === b.at[0] ? -b.targetWidth : 0, o = -2 * b.offset[0];
                    0 > k ? (c = a.left + m + n + o + b.collisionWidth - g - f, (0 > c || c < h(k)) && (a.left += m + n + o)) : l > 0 && (d = a.left - b.collisionPosition.marginLeft + m + n + o - i, 
                    (d > 0 || h(d) < l) && (a.left += m + n + o));
                },
                top: function(a, b) {
                    var c, d, e = b.within, f = e.offset.top + e.scrollTop, g = e.height, i = e.isWindow ? e.scrollTop : e.offset.top, j = a.top - b.collisionPosition.marginTop, k = j - i, l = j + b.collisionHeight - g - i, m = "top" === b.my[1], n = m ? -b.elemHeight : "bottom" === b.my[1] ? b.elemHeight : 0, o = "top" === b.at[1] ? b.targetHeight : "bottom" === b.at[1] ? -b.targetHeight : 0, p = -2 * b.offset[1];
                    0 > k ? (d = a.top + n + o + p + b.collisionHeight - g - f, (0 > d || d < h(k)) && (a.top += n + o + p)) : l > 0 && (c = a.top - b.collisionPosition.marginTop + n + o + p - i, 
                    (c > 0 || h(c) < l) && (a.top += n + o + p));
                }
            },
            flipfit: {
                left: function() {
                    a.ui.position.flip.left.apply(this, arguments), a.ui.position.fit.left.apply(this, arguments);
                },
                top: function() {
                    a.ui.position.flip.top.apply(this, arguments), a.ui.position.fit.top.apply(this, arguments);
                }
            }
        }, function() {
            var b, c, d, e, g, h = document.getElementsByTagName("body")[0], i = document.createElement("div");
            b = document.createElement(h ? "div" : "body"), d = {
                visibility: "hidden",
                width: 0,
                height: 0,
                border: 0,
                margin: 0,
                background: "none"
            }, h && a.extend(d, {
                position: "absolute",
                left: "-1000px",
                top: "-1000px"
            });
            for (g in d) b.style[g] = d[g];
            b.appendChild(i), c = h || document.documentElement, c.insertBefore(b, c.firstChild), 
            i.style.cssText = "position: absolute; left: 10.7432222px;", e = a(i).offset().left, 
            f = e > 10 && 11 > e, b.innerHTML = "", c.removeChild(b);
        }();
    }();
    a.ui.position, a.widget("ui.menu", {
        version: "1.11.4",
        defaultElement: "<ul>",
        delay: 300,
        options: {
            icons: {
                submenu: "ui-icon-carat-1-e"
            },
            items: "> *",
            menus: "ul",
            position: {
                my: "left-1 top",
                at: "right top"
            },
            role: "menu",
            blur: null,
            focus: null,
            select: null
        },
        _create: function() {
            this.activeMenu = this.element, this.mouseHandled = !1, this.element.uniqueId().addClass("ui-menu ui-widget ui-widget-content").toggleClass("ui-menu-icons", !!this.element.find(".ui-icon").length).attr({
                role: this.options.role,
                tabIndex: 0
            }), this.options.disabled && this.element.addClass("ui-state-disabled").attr("aria-disabled", "true"), 
            this._on({
                "mousedown .ui-menu-item": function(a) {
                    a.preventDefault();
                },
                "click .ui-menu-item": function(b) {
                    var c = a(b.target);
                    !this.mouseHandled && c.not(".ui-state-disabled").length && (this.select(b), b.isPropagationStopped() || (this.mouseHandled = !0), 
                    c.has(".ui-menu").length ? this.expand(b) : !this.element.is(":focus") && a(this.document[0].activeElement).closest(".ui-menu").length && (this.element.trigger("focus", [ !0 ]), 
                    this.active && 1 === this.active.parents(".ui-menu").length && clearTimeout(this.timer)));
                },
                "mouseenter .ui-menu-item": function(b) {
                    if (!this.previousFilter) {
                        var c = a(b.currentTarget);
                        c.siblings(".ui-state-active").removeClass("ui-state-active"), this.focus(b, c);
                    }
                },
                mouseleave: "collapseAll",
                "mouseleave .ui-menu": "collapseAll",
                focus: function(a, b) {
                    var c = this.active || this.element.find(this.options.items).eq(0);
                    b || this.focus(a, c);
                },
                blur: function(b) {
                    this._delay(function() {
                        a.contains(this.element[0], this.document[0].activeElement) || this.collapseAll(b);
                    });
                },
                keydown: "_keydown"
            }), this.refresh(), this._on(this.document, {
                click: function(a) {
                    this._closeOnDocumentClick(a) && this.collapseAll(a), this.mouseHandled = !1;
                }
            });
        },
        _destroy: function() {
            this.element.removeAttr("aria-activedescendant").find(".ui-menu").addBack().removeClass("ui-menu ui-widget ui-widget-content ui-menu-icons ui-front").removeAttr("role").removeAttr("tabIndex").removeAttr("aria-labelledby").removeAttr("aria-expanded").removeAttr("aria-hidden").removeAttr("aria-disabled").removeUniqueId().show(), 
            this.element.find(".ui-menu-item").removeClass("ui-menu-item").removeAttr("role").removeAttr("aria-disabled").removeUniqueId().removeClass("ui-state-hover").removeAttr("tabIndex").removeAttr("role").removeAttr("aria-haspopup").children().each(function() {
                var b = a(this);
                b.data("ui-menu-submenu-carat") && b.remove();
            }), this.element.find(".ui-menu-divider").removeClass("ui-menu-divider ui-widget-content");
        },
        _keydown: function(b) {
            var c, d, e, f, g = !0;
            switch (b.keyCode) {
              case a.ui.keyCode.PAGE_UP:
                this.previousPage(b);
                break;

              case a.ui.keyCode.PAGE_DOWN:
                this.nextPage(b);
                break;

              case a.ui.keyCode.HOME:
                this._move("first", "first", b);
                break;

              case a.ui.keyCode.END:
                this._move("last", "last", b);
                break;

              case a.ui.keyCode.UP:
                this.previous(b);
                break;

              case a.ui.keyCode.DOWN:
                this.next(b);
                break;

              case a.ui.keyCode.LEFT:
                this.collapse(b);
                break;

              case a.ui.keyCode.RIGHT:
                this.active && !this.active.is(".ui-state-disabled") && this.expand(b);
                break;

              case a.ui.keyCode.ENTER:
              case a.ui.keyCode.SPACE:
                this._activate(b);
                break;

              case a.ui.keyCode.ESCAPE:
                this.collapse(b);
                break;

              default:
                g = !1, d = this.previousFilter || "", e = String.fromCharCode(b.keyCode), f = !1, 
                clearTimeout(this.filterTimer), e === d ? f = !0 : e = d + e, c = this._filterMenuItems(e), 
                c = f && -1 !== c.index(this.active.next()) ? this.active.nextAll(".ui-menu-item") : c, 
                c.length || (e = String.fromCharCode(b.keyCode), c = this._filterMenuItems(e)), 
                c.length ? (this.focus(b, c), this.previousFilter = e, this.filterTimer = this._delay(function() {
                    delete this.previousFilter;
                }, 1e3)) : delete this.previousFilter;
            }
            g && b.preventDefault();
        },
        _activate: function(a) {
            this.active.is(".ui-state-disabled") || (this.active.is("[aria-haspopup='true']") ? this.expand(a) : this.select(a));
        },
        refresh: function() {
            var b, c, d = this, e = this.options.icons.submenu, f = this.element.find(this.options.menus);
            this.element.toggleClass("ui-menu-icons", !!this.element.find(".ui-icon").length), 
            f.filter(":not(.ui-menu)").addClass("ui-menu ui-widget ui-widget-content ui-front").hide().attr({
                role: this.options.role,
                "aria-hidden": "true",
                "aria-expanded": "false"
            }).each(function() {
                var b = a(this), c = b.parent(), d = a("<span>").addClass("ui-menu-icon ui-icon " + e).data("ui-menu-submenu-carat", !0);
                c.attr("aria-haspopup", "true").prepend(d), b.attr("aria-labelledby", c.attr("id"));
            }), b = f.add(this.element), c = b.find(this.options.items), c.not(".ui-menu-item").each(function() {
                var b = a(this);
                d._isDivider(b) && b.addClass("ui-widget-content ui-menu-divider");
            }), c.not(".ui-menu-item, .ui-menu-divider").addClass("ui-menu-item").uniqueId().attr({
                tabIndex: -1,
                role: this._itemRole()
            }), c.filter(".ui-state-disabled").attr("aria-disabled", "true"), this.active && !a.contains(this.element[0], this.active[0]) && this.blur();
        },
        _itemRole: function() {
            return {
                menu: "menuitem",
                listbox: "option"
            }[this.options.role];
        },
        _setOption: function(a, b) {
            "icons" === a && this.element.find(".ui-menu-icon").removeClass(this.options.icons.submenu).addClass(b.submenu), 
            "disabled" === a && this.element.toggleClass("ui-state-disabled", !!b).attr("aria-disabled", b), 
            this._super(a, b);
        },
        focus: function(a, b) {
            var c, d;
            this.blur(a, a && "focus" === a.type), this._scrollIntoView(b), this.active = b.first(), 
            d = this.active.addClass("ui-state-focus").removeClass("ui-state-active"), this.options.role && this.element.attr("aria-activedescendant", d.attr("id")), 
            this.active.parent().closest(".ui-menu-item").addClass("ui-state-active"), a && "keydown" === a.type ? this._close() : this.timer = this._delay(function() {
                this._close();
            }, this.delay), c = b.children(".ui-menu"), c.length && a && /^mouse/.test(a.type) && this._startOpening(c), 
            this.activeMenu = b.parent(), this._trigger("focus", a, {
                item: b
            });
        },
        _scrollIntoView: function(b) {
            var c, d, e, f, g, h;
            this._hasScroll() && (c = parseFloat(a.css(this.activeMenu[0], "borderTopWidth")) || 0, 
            d = parseFloat(a.css(this.activeMenu[0], "paddingTop")) || 0, e = b.offset().top - this.activeMenu.offset().top - c - d, 
            f = this.activeMenu.scrollTop(), g = this.activeMenu.height(), h = b.outerHeight(), 
            0 > e ? this.activeMenu.scrollTop(f + e) : e + h > g && this.activeMenu.scrollTop(f + e - g + h));
        },
        blur: function(a, b) {
            b || clearTimeout(this.timer), this.active && (this.active.removeClass("ui-state-focus"), 
            this.active = null, this._trigger("blur", a, {
                item: this.active
            }));
        },
        _startOpening: function(a) {
            clearTimeout(this.timer), "true" === a.attr("aria-hidden") && (this.timer = this._delay(function() {
                this._close(), this._open(a);
            }, this.delay));
        },
        _open: function(b) {
            var c = a.extend({
                of: this.active
            }, this.options.position);
            clearTimeout(this.timer), this.element.find(".ui-menu").not(b.parents(".ui-menu")).hide().attr("aria-hidden", "true"), 
            b.show().removeAttr("aria-hidden").attr("aria-expanded", "true").position(c);
        },
        collapseAll: function(b, c) {
            clearTimeout(this.timer), this.timer = this._delay(function() {
                var d = c ? this.element : a(b && b.target).closest(this.element.find(".ui-menu"));
                d.length || (d = this.element), this._close(d), this.blur(b), this.activeMenu = d;
            }, this.delay);
        },
        _close: function(a) {
            a || (a = this.active ? this.active.parent() : this.element), a.find(".ui-menu").hide().attr("aria-hidden", "true").attr("aria-expanded", "false").end().find(".ui-state-active").not(".ui-state-focus").removeClass("ui-state-active");
        },
        _closeOnDocumentClick: function(b) {
            return !a(b.target).closest(".ui-menu").length;
        },
        _isDivider: function(a) {
            return !/[^\-\u2014\u2013\s]/.test(a.text());
        },
        collapse: function(a) {
            var b = this.active && this.active.parent().closest(".ui-menu-item", this.element);
            b && b.length && (this._close(), this.focus(a, b));
        },
        expand: function(a) {
            var b = this.active && this.active.children(".ui-menu ").find(this.options.items).first();
            b && b.length && (this._open(b.parent()), this._delay(function() {
                this.focus(a, b);
            }));
        },
        next: function(a) {
            this._move("next", "first", a);
        },
        previous: function(a) {
            this._move("prev", "last", a);
        },
        isFirstItem: function() {
            return this.active && !this.active.prevAll(".ui-menu-item").length;
        },
        isLastItem: function() {
            return this.active && !this.active.nextAll(".ui-menu-item").length;
        },
        _move: function(a, b, c) {
            var d;
            this.active && (d = "first" === a || "last" === a ? this.active["first" === a ? "prevAll" : "nextAll"](".ui-menu-item").eq(-1) : this.active[a + "All"](".ui-menu-item").eq(0)), 
            d && d.length && this.active || (d = this.activeMenu.find(this.options.items)[b]()), 
            this.focus(c, d);
        },
        nextPage: function(b) {
            var c, d, e;
            return this.active ? void (this.isLastItem() || (this._hasScroll() ? (d = this.active.offset().top, 
            e = this.element.height(), this.active.nextAll(".ui-menu-item").each(function() {
                return c = a(this), c.offset().top - d - e < 0;
            }), this.focus(b, c)) : this.focus(b, this.activeMenu.find(this.options.items)[this.active ? "last" : "first"]()))) : void this.next(b);
        },
        previousPage: function(b) {
            var c, d, e;
            return this.active ? void (this.isFirstItem() || (this._hasScroll() ? (d = this.active.offset().top, 
            e = this.element.height(), this.active.prevAll(".ui-menu-item").each(function() {
                return c = a(this), c.offset().top - d + e > 0;
            }), this.focus(b, c)) : this.focus(b, this.activeMenu.find(this.options.items).first()))) : void this.next(b);
        },
        _hasScroll: function() {
            return this.element.outerHeight() < this.element.prop("scrollHeight");
        },
        select: function(b) {
            this.active = this.active || a(b.target).closest(".ui-menu-item");
            var c = {
                item: this.active
            };
            this.active.has(".ui-menu").length || this.collapseAll(b, !0), this._trigger("select", b, c);
        },
        _filterMenuItems: function(b) {
            var c = b.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g, "\\$&"), d = new RegExp("^" + c, "i");
            return this.activeMenu.find(this.options.items).filter(".ui-menu-item").filter(function() {
                return d.test(a.trim(a(this).text()));
            });
        }
    });
    a.widget("ui.autocomplete", {
        version: "1.11.4",
        defaultElement: "<input>",
        options: {
            appendTo: null,
            autoFocus: !1,
            delay: 300,
            minLength: 1,
            position: {
                my: "left top",
                at: "left bottom",
                collision: "none"
            },
            source: null,
            change: null,
            close: null,
            focus: null,
            open: null,
            response: null,
            search: null,
            select: null
        },
        requestIndex: 0,
        pending: 0,
        _create: function() {
            var b, c, d, e = this.element[0].nodeName.toLowerCase(), f = "textarea" === e, g = "input" === e;
            this.isMultiLine = f ? !0 : g ? !1 : this.element.prop("isContentEditable"), this.valueMethod = this.element[f || g ? "val" : "text"], 
            this.isNewMenu = !0, this.element.addClass("ui-autocomplete-input").attr("autocomplete", "off"), 
            this._on(this.element, {
                keydown: function(e) {
                    if (this.element.prop("readOnly")) return b = !0, d = !0, void (c = !0);
                    b = !1, d = !1, c = !1;
                    var f = a.ui.keyCode;
                    switch (e.keyCode) {
                      case f.PAGE_UP:
                        b = !0, this._move("previousPage", e);
                        break;

                      case f.PAGE_DOWN:
                        b = !0, this._move("nextPage", e);
                        break;

                      case f.UP:
                        b = !0, this._keyEvent("previous", e);
                        break;

                      case f.DOWN:
                        b = !0, this._keyEvent("next", e);
                        break;

                      case f.ENTER:
                        this.menu.active && (b = !0, e.preventDefault(), this.menu.select(e));
                        break;

                      case f.TAB:
                        this.menu.active && this.menu.select(e);
                        break;

                      case f.ESCAPE:
                        this.menu.element.is(":visible") && (this.isMultiLine || this._value(this.term), 
                        this.close(e), e.preventDefault());
                        break;

                      default:
                        c = !0, this._searchTimeout(e);
                    }
                },
                keypress: function(d) {
                    if (b) return b = !1, void ((!this.isMultiLine || this.menu.element.is(":visible")) && d.preventDefault());
                    if (!c) {
                        var e = a.ui.keyCode;
                        switch (d.keyCode) {
                          case e.PAGE_UP:
                            this._move("previousPage", d);
                            break;

                          case e.PAGE_DOWN:
                            this._move("nextPage", d);
                            break;

                          case e.UP:
                            this._keyEvent("previous", d);
                            break;

                          case e.DOWN:
                            this._keyEvent("next", d);
                        }
                    }
                },
                input: function(a) {
                    return d ? (d = !1, void a.preventDefault()) : void this._searchTimeout(a);
                },
                focus: function() {
                    this.selectedItem = null, this.previous = this._value();
                },
                blur: function(a) {
                    return this.cancelBlur ? void delete this.cancelBlur : (clearTimeout(this.searching), 
                    this.close(a), void this._change(a));
                }
            }), this._initSource(), this.menu = a("<ul>").addClass("ui-autocomplete ui-front").appendTo(this._appendTo()).menu({
                role: null
            }).hide().menu("instance"), this._on(this.menu.element, {
                mousedown: function(b) {
                    b.preventDefault(), this.cancelBlur = !0, this._delay(function() {
                        delete this.cancelBlur;
                    });
                    var c = this.menu.element[0];
                    a(b.target).closest(".ui-menu-item").length || this._delay(function() {
                        var b = this;
                        this.document.one("mousedown", function(d) {
                            d.target === b.element[0] || d.target === c || a.contains(c, d.target) || b.close();
                        });
                    });
                },
                menufocus: function(b, c) {
                    var d, e;
                    return this.isNewMenu && (this.isNewMenu = !1, b.originalEvent && /^mouse/.test(b.originalEvent.type)) ? (this.menu.blur(), 
                    void this.document.one("mousemove", function() {
                        a(b.target).trigger(b.originalEvent);
                    })) : (e = c.item.data("ui-autocomplete-item"), !1 !== this._trigger("focus", b, {
                        item: e
                    }) && b.originalEvent && /^key/.test(b.originalEvent.type) && this._value(e.value), 
                    d = c.item.attr("aria-label") || e.value, void (d && a.trim(d).length && (this.liveRegion.children().hide(), 
                    a("<div>").text(d).appendTo(this.liveRegion))));
                },
                menuselect: function(a, b) {
                    var c = b.item.data("ui-autocomplete-item"), d = this.previous;
                    this.element[0] !== this.document[0].activeElement && (this.element.focus(), this.previous = d, 
                    this._delay(function() {
                        this.previous = d, this.selectedItem = c;
                    })), !1 !== this._trigger("select", a, {
                        item: c
                    }) && this._value(c.value), this.term = this._value(), this.close(a), this.selectedItem = c;
                }
            }), this.liveRegion = a("<span>", {
                role: "status",
                "aria-live": "assertive",
                "aria-relevant": "additions"
            }).addClass("ui-helper-hidden-accessible").appendTo(this.document[0].body), this._on(this.window, {
                beforeunload: function() {
                    this.element.removeAttr("autocomplete");
                }
            });
        },
        _destroy: function() {
            clearTimeout(this.searching), this.element.removeClass("ui-autocomplete-input").removeAttr("autocomplete"), 
            this.menu.element.remove(), this.liveRegion.remove();
        },
        _setOption: function(a, b) {
            this._super(a, b), "source" === a && this._initSource(), "appendTo" === a && this.menu.element.appendTo(this._appendTo()), 
            "disabled" === a && b && this.xhr && this.xhr.abort();
        },
        _appendTo: function() {
            var b = this.options.appendTo;
            return b && (b = b.jquery || b.nodeType ? a(b) : this.document.find(b).eq(0)), b && b[0] || (b = this.element.closest(".ui-front")), 
            b.length || (b = this.document[0].body), b;
        },
        _initSource: function() {
            var b, c, d = this;
            a.isArray(this.options.source) ? (b = this.options.source, this.source = function(c, d) {
                d(a.ui.autocomplete.filter(b, c.term));
            }) : "string" == typeof this.options.source ? (c = this.options.source, this.source = function(b, e) {
                d.xhr && d.xhr.abort(), d.xhr = a.ajax({
                    url: c,
                    data: b,
                    dataType: "json",
                    success: function(a) {
                        e(a);
                    },
                    error: function() {
                        e([]);
                    }
                });
            }) : this.source = this.options.source;
        },
        _searchTimeout: function(a) {
            clearTimeout(this.searching), this.searching = this._delay(function() {
                var b = this.term === this._value(), c = this.menu.element.is(":visible"), d = a.altKey || a.ctrlKey || a.metaKey || a.shiftKey;
                (!b || b && !c && !d) && (this.selectedItem = null, this.search(null, a));
            }, this.options.delay);
        },
        search: function(a, b) {
            return a = null != a ? a : this._value(), this.term = this._value(), a.length < this.options.minLength ? this.close(b) : this._trigger("search", b) !== !1 ? this._search(a) : void 0;
        },
        _search: function(a) {
            this.pending++, this.element.addClass("ui-autocomplete-loading"), this.cancelSearch = !1, 
            this.source({
                term: a
            }, this._response());
        },
        _response: function() {
            var b = ++this.requestIndex;
            return a.proxy(function(a) {
                b === this.requestIndex && this.__response(a), this.pending--, this.pending || this.element.removeClass("ui-autocomplete-loading");
            }, this);
        },
        __response: function(a) {
            a && (a = this._normalize(a)), this._trigger("response", null, {
                content: a
            }), !this.options.disabled && a && a.length && !this.cancelSearch ? (this._suggest(a), 
            this._trigger("open")) : this._close();
        },
        close: function(a) {
            this.cancelSearch = !0, this._close(a);
        },
        _close: function(a) {
            this.menu.element.is(":visible") && (this.menu.element.hide(), this.menu.blur(), 
            this.isNewMenu = !0, this._trigger("close", a));
        },
        _change: function(a) {
            this.previous !== this._value() && this._trigger("change", a, {
                item: this.selectedItem
            });
        },
        _normalize: function(b) {
            return b.length && b[0].label && b[0].value ? b : a.map(b, function(b) {
                return "string" == typeof b ? {
                    label: b,
                    value: b
                } : a.extend({}, b, {
                    label: b.label || b.value,
                    value: b.value || b.label
                });
            });
        },
        _suggest: function(b) {
            var c = this.menu.element.empty();
            this._renderMenu(c, b), this.isNewMenu = !0, this.menu.refresh(), c.show(), this._resizeMenu(), 
            c.position(a.extend({
                of: this.element
            }, this.options.position)), this.options.autoFocus && this.menu.next();
        },
        _resizeMenu: function() {
            var a = this.menu.element;
            a.outerWidth(Math.max(a.width("").outerWidth() + 1, this.element.outerWidth()));
        },
        _renderMenu: function(b, c) {
            var d = this;
            a.each(c, function(a, c) {
                d._renderItemData(b, c);
            });
        },
        _renderItemData: function(a, b) {
            return this._renderItem(a, b).data("ui-autocomplete-item", b);
        },
        _renderItem: function(b, c) {
            return a("<li>").text(c.label).appendTo(b);
        },
        _move: function(a, b) {
            return this.menu.element.is(":visible") ? this.menu.isFirstItem() && /^previous/.test(a) || this.menu.isLastItem() && /^next/.test(a) ? (this.isMultiLine || this._value(this.term), 
            void this.menu.blur()) : void this.menu[a](b) : void this.search(null, b);
        },
        widget: function() {
            return this.menu.element;
        },
        _value: function() {
            return this.valueMethod.apply(this.element, arguments);
        },
        _keyEvent: function(a, b) {
            (!this.isMultiLine || this.menu.element.is(":visible")) && (this._move(a, b), b.preventDefault());
        }
    }), a.extend(a.ui.autocomplete, {
        escapeRegex: function(a) {
            return a.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g, "\\$&");
        },
        filter: function(b, c) {
            var d = new RegExp(a.ui.autocomplete.escapeRegex(c), "i");
            return a.grep(b, function(a) {
                return d.test(a.label || a.value || a);
            });
        }
    }), a.widget("ui.autocomplete", a.ui.autocomplete, {
        options: {
            messages: {
                noResults: "No search results.",
                results: function(a) {
                    return a + (a > 1 ? " results are" : " result is") + " available, use up and down arrow keys to navigate.";
                }
            }
        },
        __response: function(b) {
            var c;
            this._superApply(arguments), this.options.disabled || this.cancelSearch || (c = b && b.length ? this.options.messages.results(b.length) : this.options.messages.noResults, 
            this.liveRegion.children().hide(), a("<div>").text(c).appendTo(this.liveRegion));
        }
    });
    a.ui.autocomplete;
}), function(a) {
    "use strict";
    "function" == typeof define && define.amd ? define([ "jquery" ], a) : "undefined" != typeof module && module.exports ? module.exports = a(require("jquery")) : a(jQuery);
}(function(a) {
    "use strict";
    function b(b) {
        return !b.nodeName || -1 !== a.inArray(b.nodeName.toLowerCase(), [ "iframe", "#document", "html", "body" ]);
    }
    function c(b) {
        return a.isFunction(b) || a.isPlainObject(b) ? b : {
            top: b,
            left: b
        };
    }
    var d = a.scrollTo = function(b, c, d) {
        return a(window).scrollTo(b, c, d);
    };
    return d.defaults = {
        axis: "xy",
        duration: 0,
        limit: !0
    }, a.fn.scrollTo = function(e, f, g) {
        "object" == typeof f && (g = f, f = 0), "function" == typeof g && (g = {
            onAfter: g
        }), "max" === e && (e = 9e9), g = a.extend({}, d.defaults, g), f = f || g.duration;
        var h = g.queue && g.axis.length > 1;
        return h && (f /= 2), g.offset = c(g.offset), g.over = c(g.over), this.each(function() {
            function i(b) {
                var c = a.extend({}, g, {
                    queue: !0,
                    duration: f,
                    complete: b && function() {
                        b.call(l, n, g);
                    }
                });
                m.animate(o, c);
            }
            if (null !== e) {
                var j, k = b(this), l = k ? this.contentWindow || window : this, m = a(l), n = e, o = {};
                switch (typeof n) {
                  case "number":
                  case "string":
                    if (/^([+-]=?)?\d+(\.\d+)?(px|%)?$/.test(n)) {
                        n = c(n);
                        break;
                    }
                    n = k ? a(n) : a(n, l);

                  case "object":
                    if (0 === n.length) return;
                    (n.is || n.style) && (j = (n = a(n)).offset());
                }
                var p = a.isFunction(g.offset) && g.offset(l, n) || g.offset;
                a.each(g.axis.split(""), function(a, b) {
                    var c = "x" === b ? "Left" : "Top", e = c.toLowerCase(), f = "scroll" + c, q = m[f](), r = d.max(l, b);
                    if (j) o[f] = j[e] + (k ? 0 : q - m.offset()[e]), g.margin && (o[f] -= parseInt(n.css("margin" + c), 10) || 0, 
                    o[f] -= parseInt(n.css("border" + c + "Width"), 10) || 0), o[f] += p[e] || 0, g.over[e] && (o[f] += n["x" === b ? "width" : "height"]() * g.over[e]); else {
                        var s = n[e];
                        o[f] = s.slice && "%" === s.slice(-1) ? parseFloat(s) / 100 * r : s;
                    }
                    g.limit && /^\d+$/.test(o[f]) && (o[f] = o[f] <= 0 ? 0 : Math.min(o[f], r)), !a && g.axis.length > 1 && (q === o[f] ? o = {} : h && (i(g.onAfterFirst), 
                    o = {}));
                }), i(g.onAfter);
            }
        });
    }, d.max = function(c, d) {
        var e = "x" === d ? "Width" : "Height", f = "scroll" + e;
        if (!b(c)) return c[f] - a(c)[e.toLowerCase()]();
        var g = "client" + e, h = c.ownerDocument || c.document, i = h.documentElement, j = h.body;
        return Math.max(i[f], j[f]) - Math.min(i[g], j[g]);
    }, a.Tween.propHooks.scrollLeft = a.Tween.propHooks.scrollTop = {
        get: function(b) {
            return a(b.elem)[b.prop]();
        },
        set: function(b) {
            var c = this.get(b);
            if (b.options.interrupt && b._last && b._last !== c) return a(b.elem).stop();
            var d = Math.round(b.now);
            c !== d && (a(b.elem)[b.prop](d), b._last = this.get(b));
        }
    }, d;
}), function(a, b, c) {
    "use strict";
    a.fn.scrollUp = function(b) {
        a.data(c.body, "scrollUp") || (a.data(c.body, "scrollUp", !0), a.fn.scrollUp.init(b));
    }, a.fn.scrollUp.init = function(d) {
        var e, f, g, h, i, j, k, l = a.fn.scrollUp.settings = a.extend({}, a.fn.scrollUp.defaults, d), m = !1;
        switch (k = l.scrollTrigger ? a(l.scrollTrigger) : a("<a/>", {
            id: l.scrollName,
            href: "#top"
        }), l.scrollTitle && k.attr("title", l.scrollTitle), k.appendTo("body"), l.scrollImg || l.scrollTrigger || k.html(l.scrollText), 
        k.css({
            display: "none",
            position: "fixed",
            zIndex: l.zIndex
        }), l.activeOverlay && a("<div/>", {
            id: l.scrollName + "-active"
        }).css({
            position: "absolute",
            top: l.scrollDistance + "px",
            width: "100%",
            borderTop: "1px dotted" + l.activeOverlay,
            zIndex: l.zIndex
        }).appendTo("body"), l.animation) {
          case "fade":
            e = "fadeIn", f = "fadeOut", g = l.animationSpeed;
            break;

          case "slide":
            e = "slideDown", f = "slideUp", g = l.animationSpeed;
            break;

          default:
            e = "show", f = "hide", g = 0;
        }
        h = "top" === l.scrollFrom ? l.scrollDistance : a(c).height() - a(b).height() - l.scrollDistance, 
        i = a(b).scroll(function() {
            a(b).scrollTop() > h ? m || (k[e](g), m = !0) : m && (k[f](g), m = !1);
        }), l.scrollTarget ? "number" == typeof l.scrollTarget ? j = l.scrollTarget : "string" == typeof l.scrollTarget && (j = Math.floor(a(l.scrollTarget).offset().top)) : j = 0, 
        k.click(function(b) {
            b.preventDefault(), a("html, body").animate({
                scrollTop: j
            }, l.scrollSpeed, l.easingType);
        });
    }, a.fn.scrollUp.defaults = {
        scrollName: "scrollUp",
        scrollDistance: 300,
        scrollFrom: "top",
        scrollSpeed: 300,
        easingType: "linear",
        animation: "fade",
        animationSpeed: 200,
        scrollTrigger: !1,
        scrollTarget: !1,
        scrollText: "Scroll to top",
        scrollTitle: !1,
        scrollImg: !1,
        activeOverlay: !1,
        zIndex: 2147483647
    }, a.fn.scrollUp.destroy = function(d) {
        a.removeData(c.body, "scrollUp"), a("#" + a.fn.scrollUp.settings.scrollName).remove(), 
        a("#" + a.fn.scrollUp.settings.scrollName + "-active").remove(), a.fn.jquery.split(".")[1] >= 7 ? a(b).off("scroll", d) : a(b).unbind("scroll", d);
    }, a.scrollUp = a.fn.scrollUp;
}(jQuery, window, document), +function(a) {
    "use strict";
    function b(b) {
        return this.each(function() {
            var d = a(this), e = d.data("bs.affix"), f = "object" == typeof b && b;
            e || d.data("bs.affix", e = new c(this, f)), "string" == typeof b && e[b]();
        });
    }
    var c = function(b, d) {
        this.options = a.extend({}, c.DEFAULTS, d), this.$target = a(this.options.target).on("scroll.bs.affix.data-api", a.proxy(this.checkPosition, this)).on("click.bs.affix.data-api", a.proxy(this.checkPositionWithEventLoop, this)), 
        this.$element = a(b), this.affixed = null, this.unpin = null, this.pinnedOffset = null, 
        this.checkPosition();
    };
    c.VERSION = "3.3.5", c.RESET = "affix affix-top affix-bottom", c.DEFAULTS = {
        offset: 0,
        target: window
    }, c.prototype.getState = function(a, b, c, d) {
        var e = this.$target.scrollTop(), f = this.$element.offset(), g = this.$target.height();
        if (null != c && "top" == this.affixed) return c > e ? "top" : !1;
        if ("bottom" == this.affixed) return null != c ? e + this.unpin <= f.top ? !1 : "bottom" : a - d >= e + g ? !1 : "bottom";
        var h = null == this.affixed, i = h ? e : f.top, j = h ? g : b;
        return null != c && c >= e ? "top" : null != d && i + j >= a - d ? "bottom" : !1;
    }, c.prototype.getPinnedOffset = function() {
        if (this.pinnedOffset) return this.pinnedOffset;
        this.$element.removeClass(c.RESET).addClass("affix");
        var a = this.$target.scrollTop(), b = this.$element.offset();
        return this.pinnedOffset = b.top - a;
    }, c.prototype.checkPositionWithEventLoop = function() {
        setTimeout(a.proxy(this.checkPosition, this), 1);
    }, c.prototype.checkPosition = function() {
        if (this.$element.is(":visible")) {
            var b = this.$element.height(), d = this.options.offset, e = d.top, f = d.bottom, g = Math.max(a(document).height(), a(document.body).height());
            "object" != typeof d && (f = e = d), "function" == typeof e && (e = d.top(this.$element)), 
            "function" == typeof f && (f = d.bottom(this.$element));
            var h = this.getState(g, b, e, f);
            if (this.affixed != h) {
                null != this.unpin && this.$element.css("top", "");
                var i = "affix" + (h ? "-" + h : ""), j = a.Event(i + ".bs.affix");
                if (this.$element.trigger(j), j.isDefaultPrevented()) return;
                this.affixed = h, this.unpin = "bottom" == h ? this.getPinnedOffset() : null, this.$element.removeClass(c.RESET).addClass(i).trigger(i.replace("affix", "affixed") + ".bs.affix");
            }
            "bottom" == h && this.$element.offset({
                top: g - b - f
            });
        }
    };
    var d = a.fn.affix;
    a.fn.affix = b, a.fn.affix.Constructor = c, a.fn.affix.noConflict = function() {
        return a.fn.affix = d, this;
    }, a(window).on("load", function() {
        a('[data-spy="affix"]').each(function() {
            var c = a(this), d = c.data();
            d.offset = d.offset || {}, null != d.offsetBottom && (d.offset.bottom = d.offsetBottom), 
            null != d.offsetTop && (d.offset.top = d.offsetTop), b.call(c, d);
        });
    });
}(jQuery), +function(a) {
    "use strict";
    function b(b) {
        var c, d = b.attr("data-target") || (c = b.attr("href")) && c.replace(/.*(?=#[^\s]+$)/, "");
        return a(d);
    }
    function c(b) {
        return this.each(function() {
            var c = a(this), e = c.data("bs.collapse"), f = a.extend({}, d.DEFAULTS, c.data(), "object" == typeof b && b);
            !e && f.toggle && /show|hide/.test(b) && (f.toggle = !1), e || c.data("bs.collapse", e = new d(this, f)), 
            "string" == typeof b && e[b]();
        });
    }
    var d = function(b, c) {
        this.$element = a(b), this.options = a.extend({}, d.DEFAULTS, c), this.$trigger = a('[data-toggle="collapse"][href="#' + b.id + '"],[data-toggle="collapse"][data-target="#' + b.id + '"]'), 
        this.transitioning = null, this.options.parent ? this.$parent = this.getParent() : this.addAriaAndCollapsedClass(this.$element, this.$trigger), 
        this.options.toggle && this.toggle();
    };
    d.VERSION = "3.3.5", d.TRANSITION_DURATION = 350, d.DEFAULTS = {
        toggle: !0
    }, d.prototype.dimension = function() {
        var a = this.$element.hasClass("width");
        return a ? "width" : "height";
    }, d.prototype.show = function() {
        if (!this.transitioning && !this.$element.hasClass("in")) {
            var b, e = this.$parent && this.$parent.children(".panel").children(".in, .collapsing");
            if (!(e && e.length && (b = e.data("bs.collapse"), b && b.transitioning))) {
                var f = a.Event("show.bs.collapse");
                if (this.$element.trigger(f), !f.isDefaultPrevented()) {
                    e && e.length && (c.call(e, "hide"), b || e.data("bs.collapse", null));
                    var g = this.dimension();
                    this.$element.removeClass("collapse").addClass("collapsing")[g](0).attr("aria-expanded", !0), 
                    this.$trigger.removeClass("collapsed").attr("aria-expanded", !0), this.transitioning = 1;
                    var h = function() {
                        this.$element.removeClass("collapsing").addClass("collapse in")[g](""), this.transitioning = 0, 
                        this.$element.trigger("shown.bs.collapse");
                    };
                    if (!a.support.transition) return h.call(this);
                    var i = a.camelCase([ "scroll", g ].join("-"));
                    this.$element.one("bsTransitionEnd", a.proxy(h, this)).emulateTransitionEnd(d.TRANSITION_DURATION)[g](this.$element[0][i]);
                }
            }
        }
    }, d.prototype.hide = function() {
        if (!this.transitioning && this.$element.hasClass("in")) {
            var b = a.Event("hide.bs.collapse");
            if (this.$element.trigger(b), !b.isDefaultPrevented()) {
                var c = this.dimension();
                this.$element[c](this.$element[c]())[0].offsetHeight, this.$element.addClass("collapsing").removeClass("collapse in").attr("aria-expanded", !1), 
                this.$trigger.addClass("collapsed").attr("aria-expanded", !1), this.transitioning = 1;
                var e = function() {
                    this.transitioning = 0, this.$element.removeClass("collapsing").addClass("collapse").trigger("hidden.bs.collapse");
                };
                return a.support.transition ? void this.$element[c](0).one("bsTransitionEnd", a.proxy(e, this)).emulateTransitionEnd(d.TRANSITION_DURATION) : e.call(this);
            }
        }
    }, d.prototype.toggle = function() {
        this[this.$element.hasClass("in") ? "hide" : "show"]();
    }, d.prototype.getParent = function() {
        return a(this.options.parent).find('[data-toggle="collapse"][data-parent="' + this.options.parent + '"]').each(a.proxy(function(c, d) {
            var e = a(d);
            this.addAriaAndCollapsedClass(b(e), e);
        }, this)).end();
    }, d.prototype.addAriaAndCollapsedClass = function(a, b) {
        var c = a.hasClass("in");
        a.attr("aria-expanded", c), b.toggleClass("collapsed", !c).attr("aria-expanded", c);
    };
    var e = a.fn.collapse;
    a.fn.collapse = c, a.fn.collapse.Constructor = d, a.fn.collapse.noConflict = function() {
        return a.fn.collapse = e, this;
    }, a(document).on("click.bs.collapse.data-api", '[data-toggle="collapse"]', function(d) {
        var e = a(this);
        e.attr("data-target") || d.preventDefault();
        var f = b(e), g = f.data("bs.collapse"), h = g ? "toggle" : e.data();
        c.call(f, h);
    });
}(jQuery), +function(a) {
    "use strict";
    function b(b) {
        var c = b.attr("data-target");
        c || (c = b.attr("href"), c = c && /#[A-Za-z]/.test(c) && c.replace(/.*(?=#[^\s]*$)/, ""));
        var d = c && a(c);
        return d && d.length ? d : b.parent();
    }
    function c(c) {
        c && 3 === c.which || (a(e).remove(), a(f).each(function() {
            var d = a(this), e = b(d), f = {
                relatedTarget: this
            };
            e.hasClass("open") && (c && "click" == c.type && /input|textarea/i.test(c.target.tagName) && a.contains(e[0], c.target) || (e.trigger(c = a.Event("hide.bs.dropdown", f)), 
            c.isDefaultPrevented() || (d.attr("aria-expanded", "false"), e.removeClass("open").trigger("hidden.bs.dropdown", f))));
        }));
    }
    function d(b) {
        return this.each(function() {
            var c = a(this), d = c.data("bs.dropdown");
            d || c.data("bs.dropdown", d = new g(this)), "string" == typeof b && d[b].call(c);
        });
    }
    var e = ".dropdown-backdrop", f = '[data-toggle="dropdown"]', g = function(b) {
        a(b).on("click.bs.dropdown", this.toggle);
    };
    g.VERSION = "3.3.5", g.prototype.toggle = function(d) {
        var e = a(this);
        if (!e.is(".disabled, :disabled")) {
            var f = b(e), g = f.hasClass("open");
            if (c(), !g) {
                "ontouchstart" in document.documentElement && !f.closest(".navbar-nav").length && a(document.createElement("div")).addClass("dropdown-backdrop").insertAfter(a(this)).on("click", c);
                var h = {
                    relatedTarget: this
                };
                if (f.trigger(d = a.Event("show.bs.dropdown", h)), d.isDefaultPrevented()) return;
                e.trigger("focus").attr("aria-expanded", "true"), f.toggleClass("open").trigger("shown.bs.dropdown", h);
            }
            return !1;
        }
    }, g.prototype.keydown = function(c) {
        if (/(38|40|27|32)/.test(c.which) && !/input|textarea/i.test(c.target.tagName)) {
            var d = a(this);
            if (c.preventDefault(), c.stopPropagation(), !d.is(".disabled, :disabled")) {
                var e = b(d), g = e.hasClass("open");
                if (!g && 27 != c.which || g && 27 == c.which) return 27 == c.which && e.find(f).trigger("focus"), 
                d.trigger("click");
                var h = " li:not(.disabled):visible a", i = e.find(".dropdown-menu" + h);
                if (i.length) {
                    var j = i.index(c.target);
                    38 == c.which && j > 0 && j--, 40 == c.which && j < i.length - 1 && j++, ~j || (j = 0), 
                    i.eq(j).trigger("focus");
                }
            }
        }
    };
    var h = a.fn.dropdown;
    a.fn.dropdown = d, a.fn.dropdown.Constructor = g, a.fn.dropdown.noConflict = function() {
        return a.fn.dropdown = h, this;
    }, a(document).on("click.bs.dropdown.data-api", c).on("click.bs.dropdown.data-api", ".dropdown form", function(a) {
        a.stopPropagation();
    }).on("click.bs.dropdown.data-api", f, g.prototype.toggle).on("keydown.bs.dropdown.data-api", f, g.prototype.keydown).on("keydown.bs.dropdown.data-api", ".dropdown-menu", g.prototype.keydown);
}(jQuery), +function(a) {
    "use strict";
    function b(b, d) {
        return this.each(function() {
            var e = a(this), f = e.data("bs.modal"), g = a.extend({}, c.DEFAULTS, e.data(), "object" == typeof b && b);
            f || e.data("bs.modal", f = new c(this, g)), "string" == typeof b ? f[b](d) : g.show && f.show(d);
        });
    }
    var c = function(b, c) {
        this.options = c, this.$body = a(document.body), this.$element = a(b), this.$dialog = this.$element.find(".modal-dialog"), 
        this.$backdrop = null, this.isShown = null, this.originalBodyPad = null, this.scrollbarWidth = 0, 
        this.ignoreBackdropClick = !1, this.options.remote && this.$element.find(".modal-content").load(this.options.remote, a.proxy(function() {
            this.$element.trigger("loaded.bs.modal");
        }, this));
    };
    c.VERSION = "3.3.5", c.TRANSITION_DURATION = 300, c.BACKDROP_TRANSITION_DURATION = 150, 
    c.DEFAULTS = {
        backdrop: !0,
        keyboard: !0,
        show: !0
    }, c.prototype.toggle = function(a) {
        return this.isShown ? this.hide() : this.show(a);
    }, c.prototype.show = function(b) {
        var d = this, e = a.Event("show.bs.modal", {
            relatedTarget: b
        });
        this.$element.trigger(e), this.isShown || e.isDefaultPrevented() || (this.isShown = !0, 
        this.checkScrollbar(), this.setScrollbar(), this.$body.addClass("modal-open"), this.escape(), 
        this.resize(), this.$element.on("click.dismiss.bs.modal", '[data-dismiss="modal"]', a.proxy(this.hide, this)), 
        this.$dialog.on("mousedown.dismiss.bs.modal", function() {
            d.$element.one("mouseup.dismiss.bs.modal", function(b) {
                a(b.target).is(d.$element) && (d.ignoreBackdropClick = !0);
            });
        }), this.backdrop(function() {
            var e = a.support.transition && d.$element.hasClass("fade");
            d.$element.parent().length || d.$element.appendTo(d.$body), d.$element.show().scrollTop(0), 
            d.adjustDialog(), e && d.$element[0].offsetWidth, d.$element.addClass("in"), d.enforceFocus();
            var f = a.Event("shown.bs.modal", {
                relatedTarget: b
            });
            e ? d.$dialog.one("bsTransitionEnd", function() {
                d.$element.trigger("focus").trigger(f);
            }).emulateTransitionEnd(c.TRANSITION_DURATION) : d.$element.trigger("focus").trigger(f);
        }));
    }, c.prototype.hide = function(b) {
        b && b.preventDefault(), b = a.Event("hide.bs.modal"), this.$element.trigger(b), 
        this.isShown && !b.isDefaultPrevented() && (this.isShown = !1, this.escape(), this.resize(), 
        a(document).off("focusin.bs.modal"), this.$element.removeClass("in").off("click.dismiss.bs.modal").off("mouseup.dismiss.bs.modal"), 
        this.$dialog.off("mousedown.dismiss.bs.modal"), a.support.transition && this.$element.hasClass("fade") ? this.$element.one("bsTransitionEnd", a.proxy(this.hideModal, this)).emulateTransitionEnd(c.TRANSITION_DURATION) : this.hideModal());
    }, c.prototype.enforceFocus = function() {
        a(document).off("focusin.bs.modal").on("focusin.bs.modal", a.proxy(function(a) {
            this.$element[0] === a.target || this.$element.has(a.target).length || this.$element.trigger("focus");
        }, this));
    }, c.prototype.escape = function() {
        this.isShown && this.options.keyboard ? this.$element.on("keydown.dismiss.bs.modal", a.proxy(function(a) {
            27 == a.which && this.hide();
        }, this)) : this.isShown || this.$element.off("keydown.dismiss.bs.modal");
    }, c.prototype.resize = function() {
        this.isShown ? a(window).on("resize.bs.modal", a.proxy(this.handleUpdate, this)) : a(window).off("resize.bs.modal");
    }, c.prototype.hideModal = function() {
        var a = this;
        this.$element.hide(), this.backdrop(function() {
            a.$body.removeClass("modal-open"), a.resetAdjustments(), a.resetScrollbar(), a.$element.trigger("hidden.bs.modal");
        });
    }, c.prototype.removeBackdrop = function() {
        this.$backdrop && this.$backdrop.remove(), this.$backdrop = null;
    }, c.prototype.backdrop = function(b) {
        var d = this, e = this.$element.hasClass("fade") ? "fade" : "";
        if (this.isShown && this.options.backdrop) {
            var f = a.support.transition && e;
            if (this.$backdrop = a(document.createElement("div")).addClass("modal-backdrop " + e).appendTo(this.$body), 
            this.$element.on("click.dismiss.bs.modal", a.proxy(function(a) {
                return this.ignoreBackdropClick ? void (this.ignoreBackdropClick = !1) : void (a.target === a.currentTarget && ("static" == this.options.backdrop ? this.$element[0].focus() : this.hide()));
            }, this)), f && this.$backdrop[0].offsetWidth, this.$backdrop.addClass("in"), !b) return;
            f ? this.$backdrop.one("bsTransitionEnd", b).emulateTransitionEnd(c.BACKDROP_TRANSITION_DURATION) : b();
        } else if (!this.isShown && this.$backdrop) {
            this.$backdrop.removeClass("in");
            var g = function() {
                d.removeBackdrop(), b && b();
            };
            a.support.transition && this.$element.hasClass("fade") ? this.$backdrop.one("bsTransitionEnd", g).emulateTransitionEnd(c.BACKDROP_TRANSITION_DURATION) : g();
        } else b && b();
    }, c.prototype.handleUpdate = function() {
        this.adjustDialog();
    }, c.prototype.adjustDialog = function() {
        var a = this.$element[0].scrollHeight > document.documentElement.clientHeight;
        this.$element.css({
            paddingLeft: !this.bodyIsOverflowing && a ? this.scrollbarWidth : "",
            paddingRight: this.bodyIsOverflowing && !a ? this.scrollbarWidth : ""
        });
    }, c.prototype.resetAdjustments = function() {
        this.$element.css({
            paddingLeft: "",
            paddingRight: ""
        });
    }, c.prototype.checkScrollbar = function() {
        var a = window.innerWidth;
        if (!a) {
            var b = document.documentElement.getBoundingClientRect();
            a = b.right - Math.abs(b.left);
        }
        this.bodyIsOverflowing = document.body.clientWidth < a, this.scrollbarWidth = this.measureScrollbar();
    }, c.prototype.setScrollbar = function() {
        var a = parseInt(this.$body.css("padding-right") || 0, 10);
        this.originalBodyPad = document.body.style.paddingRight || "", this.bodyIsOverflowing && this.$body.css("padding-right", a + this.scrollbarWidth);
    }, c.prototype.resetScrollbar = function() {
        this.$body.css("padding-right", this.originalBodyPad);
    }, c.prototype.measureScrollbar = function() {
        var a = document.createElement("div");
        a.className = "modal-scrollbar-measure", this.$body.append(a);
        var b = a.offsetWidth - a.clientWidth;
        return this.$body[0].removeChild(a), b;
    };
    var d = a.fn.modal;
    a.fn.modal = b, a.fn.modal.Constructor = c, a.fn.modal.noConflict = function() {
        return a.fn.modal = d, this;
    }, a(document).on("click.bs.modal.data-api", '[data-toggle="modal"]', function(c) {
        var d = a(this), e = d.attr("href"), f = a(d.attr("data-target") || e && e.replace(/.*(?=#[^\s]+$)/, "")), g = f.data("bs.modal") ? "toggle" : a.extend({
            remote: !/#/.test(e) && e
        }, f.data(), d.data());
        d.is("a") && c.preventDefault(), f.one("show.bs.modal", function(a) {
            a.isDefaultPrevented() || f.one("hidden.bs.modal", function() {
                d.is(":visible") && d.trigger("focus");
            });
        }), b.call(f, g, this);
    });
}(jQuery), +function(a) {
    "use strict";
    function b(b) {
        return this.each(function() {
            var d = a(this), e = d.data("bs.tooltip"), f = "object" == typeof b && b;
            (e || !/destroy|hide/.test(b)) && (e || d.data("bs.tooltip", e = new c(this, f)), 
            "string" == typeof b && e[b]());
        });
    }
    var c = function(a, b) {
        this.type = null, this.options = null, this.enabled = null, this.timeout = null, 
        this.hoverState = null, this.$element = null, this.inState = null, this.init("tooltip", a, b);
    };
    c.VERSION = "3.3.5", c.TRANSITION_DURATION = 150, c.DEFAULTS = {
        animation: !0,
        placement: "top",
        selector: !1,
        template: '<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',
        trigger: "hover focus",
        title: "",
        delay: 0,
        html: !1,
        container: !1,
        viewport: {
            selector: "body",
            padding: 0
        }
    }, c.prototype.init = function(b, c, d) {
        if (this.enabled = !0, this.type = b, this.$element = a(c), this.options = this.getOptions(d), 
        this.$viewport = this.options.viewport && a(a.isFunction(this.options.viewport) ? this.options.viewport.call(this, this.$element) : this.options.viewport.selector || this.options.viewport), 
        this.inState = {
            click: !1,
            hover: !1,
            focus: !1
        }, this.$element[0] instanceof document.constructor && !this.options.selector) throw new Error("`selector` option must be specified when initializing " + this.type + " on the window.document object!");
        for (var e = this.options.trigger.split(" "), f = e.length; f--; ) {
            var g = e[f];
            if ("click" == g) this.$element.on("click." + this.type, this.options.selector, a.proxy(this.toggle, this)); else if ("manual" != g) {
                var h = "hover" == g ? "mouseenter" : "focusin", i = "hover" == g ? "mouseleave" : "focusout";
                this.$element.on(h + "." + this.type, this.options.selector, a.proxy(this.enter, this)), 
                this.$element.on(i + "." + this.type, this.options.selector, a.proxy(this.leave, this));
            }
        }
        this.options.selector ? this._options = a.extend({}, this.options, {
            trigger: "manual",
            selector: ""
        }) : this.fixTitle();
    }, c.prototype.getDefaults = function() {
        return c.DEFAULTS;
    }, c.prototype.getOptions = function(b) {
        return b = a.extend({}, this.getDefaults(), this.$element.data(), b), b.delay && "number" == typeof b.delay && (b.delay = {
            show: b.delay,
            hide: b.delay
        }), b;
    }, c.prototype.getDelegateOptions = function() {
        var b = {}, c = this.getDefaults();
        return this._options && a.each(this._options, function(a, d) {
            c[a] != d && (b[a] = d);
        }), b;
    }, c.prototype.enter = function(b) {
        var c = b instanceof this.constructor ? b : a(b.currentTarget).data("bs." + this.type);
        return c || (c = new this.constructor(b.currentTarget, this.getDelegateOptions()), 
        a(b.currentTarget).data("bs." + this.type, c)), b instanceof a.Event && (c.inState["focusin" == b.type ? "focus" : "hover"] = !0), 
        c.tip().hasClass("in") || "in" == c.hoverState ? void (c.hoverState = "in") : (clearTimeout(c.timeout), 
        c.hoverState = "in", c.options.delay && c.options.delay.show ? void (c.timeout = setTimeout(function() {
            "in" == c.hoverState && c.show();
        }, c.options.delay.show)) : c.show());
    }, c.prototype.isInStateTrue = function() {
        for (var a in this.inState) if (this.inState[a]) return !0;
        return !1;
    }, c.prototype.leave = function(b) {
        var c = b instanceof this.constructor ? b : a(b.currentTarget).data("bs." + this.type);
        return c || (c = new this.constructor(b.currentTarget, this.getDelegateOptions()), 
        a(b.currentTarget).data("bs." + this.type, c)), b instanceof a.Event && (c.inState["focusout" == b.type ? "focus" : "hover"] = !1), 
        c.isInStateTrue() ? void 0 : (clearTimeout(c.timeout), c.hoverState = "out", c.options.delay && c.options.delay.hide ? void (c.timeout = setTimeout(function() {
            "out" == c.hoverState && c.hide();
        }, c.options.delay.hide)) : c.hide());
    }, c.prototype.show = function() {
        var b = a.Event("show.bs." + this.type);
        if (this.hasContent() && this.enabled) {
            this.$element.trigger(b);
            var d = a.contains(this.$element[0].ownerDocument.documentElement, this.$element[0]);
            if (b.isDefaultPrevented() || !d) return;
            var e = this, f = this.tip(), g = this.getUID(this.type);
            this.setContent(), f.attr("id", g), this.$element.attr("aria-describedby", g), this.options.animation && f.addClass("fade");
            var h = "function" == typeof this.options.placement ? this.options.placement.call(this, f[0], this.$element[0]) : this.options.placement, i = /\s?auto?\s?/i, j = i.test(h);
            j && (h = h.replace(i, "") || "top"), f.detach().css({
                top: 0,
                left: 0,
                display: "block"
            }).addClass(h).data("bs." + this.type, this), this.options.container ? f.appendTo(this.options.container) : f.insertAfter(this.$element), 
            this.$element.trigger("inserted.bs." + this.type);
            var k = this.getPosition(), l = f[0].offsetWidth, m = f[0].offsetHeight;
            if (j) {
                var n = h, o = this.getPosition(this.$viewport);
                h = "bottom" == h && k.bottom + m > o.bottom ? "top" : "top" == h && k.top - m < o.top ? "bottom" : "right" == h && k.right + l > o.width ? "left" : "left" == h && k.left - l < o.left ? "right" : h, 
                f.removeClass(n).addClass(h);
            }
            var p = this.getCalculatedOffset(h, k, l, m);
            this.applyPlacement(p, h);
            var q = function() {
                var a = e.hoverState;
                e.$element.trigger("shown.bs." + e.type), e.hoverState = null, "out" == a && e.leave(e);
            };
            a.support.transition && this.$tip.hasClass("fade") ? f.one("bsTransitionEnd", q).emulateTransitionEnd(c.TRANSITION_DURATION) : q();
        }
    }, c.prototype.applyPlacement = function(b, c) {
        var d = this.tip(), e = d[0].offsetWidth, f = d[0].offsetHeight, g = parseInt(d.css("margin-top"), 10), h = parseInt(d.css("margin-left"), 10);
        isNaN(g) && (g = 0), isNaN(h) && (h = 0), b.top += g, b.left += h, a.offset.setOffset(d[0], a.extend({
            using: function(a) {
                d.css({
                    top: Math.round(a.top),
                    left: Math.round(a.left)
                });
            }
        }, b), 0), d.addClass("in");
        var i = d[0].offsetWidth, j = d[0].offsetHeight;
        "top" == c && j != f && (b.top = b.top + f - j);
        var k = this.getViewportAdjustedDelta(c, b, i, j);
        k.left ? b.left += k.left : b.top += k.top;
        var l = /top|bottom/.test(c), m = l ? 2 * k.left - e + i : 2 * k.top - f + j, n = l ? "offsetWidth" : "offsetHeight";
        d.offset(b), this.replaceArrow(m, d[0][n], l);
    }, c.prototype.replaceArrow = function(a, b, c) {
        this.arrow().css(c ? "left" : "top", 50 * (1 - a / b) + "%").css(c ? "top" : "left", "");
    }, c.prototype.setContent = function() {
        var a = this.tip(), b = this.getTitle();
        a.find(".tooltip-inner")[this.options.html ? "html" : "text"](b), a.removeClass("fade in top bottom left right");
    }, c.prototype.hide = function(b) {
        function d() {
            "in" != e.hoverState && f.detach(), e.$element.removeAttr("aria-describedby").trigger("hidden.bs." + e.type), 
            b && b();
        }
        var e = this, f = a(this.$tip), g = a.Event("hide.bs." + this.type);
        return this.$element.trigger(g), g.isDefaultPrevented() ? void 0 : (f.removeClass("in"), 
        a.support.transition && f.hasClass("fade") ? f.one("bsTransitionEnd", d).emulateTransitionEnd(c.TRANSITION_DURATION) : d(), 
        this.hoverState = null, this);
    }, c.prototype.fixTitle = function() {
        var a = this.$element;
        (a.attr("title") || "string" != typeof a.attr("data-original-title")) && a.attr("data-original-title", a.attr("title") || "").attr("title", "");
    }, c.prototype.hasContent = function() {
        return this.getTitle();
    }, c.prototype.getPosition = function(b) {
        b = b || this.$element;
        var c = b[0], d = "BODY" == c.tagName, e = c.getBoundingClientRect();
        null == e.width && (e = a.extend({}, e, {
            width: e.right - e.left,
            height: e.bottom - e.top
        }));
        var f = d ? {
            top: 0,
            left: 0
        } : b.offset(), g = {
            scroll: d ? document.documentElement.scrollTop || document.body.scrollTop : b.scrollTop()
        }, h = d ? {
            width: a(window).width(),
            height: a(window).height()
        } : null;
        return a.extend({}, e, g, h, f);
    }, c.prototype.getCalculatedOffset = function(a, b, c, d) {
        return "bottom" == a ? {
            top: b.top + b.height,
            left: b.left + b.width / 2 - c / 2
        } : "top" == a ? {
            top: b.top - d,
            left: b.left + b.width / 2 - c / 2
        } : "left" == a ? {
            top: b.top + b.height / 2 - d / 2,
            left: b.left - c
        } : {
            top: b.top + b.height / 2 - d / 2,
            left: b.left + b.width
        };
    }, c.prototype.getViewportAdjustedDelta = function(a, b, c, d) {
        var e = {
            top: 0,
            left: 0
        };
        if (!this.$viewport) return e;
        var f = this.options.viewport && this.options.viewport.padding || 0, g = this.getPosition(this.$viewport);
        if (/right|left/.test(a)) {
            var h = b.top - f - g.scroll, i = b.top + f - g.scroll + d;
            h < g.top ? e.top = g.top - h : i > g.top + g.height && (e.top = g.top + g.height - i);
        } else {
            var j = b.left - f, k = b.left + f + c;
            j < g.left ? e.left = g.left - j : k > g.right && (e.left = g.left + g.width - k);
        }
        return e;
    }, c.prototype.getTitle = function() {
        var a, b = this.$element, c = this.options;
        return a = b.attr("data-original-title") || ("function" == typeof c.title ? c.title.call(b[0]) : c.title);
    }, c.prototype.getUID = function(a) {
        do a += ~~(1e6 * Math.random()); while (document.getElementById(a));
        return a;
    }, c.prototype.tip = function() {
        if (!this.$tip && (this.$tip = a(this.options.template), 1 != this.$tip.length)) throw new Error(this.type + " `template` option must consist of exactly 1 top-level element!");
        return this.$tip;
    }, c.prototype.arrow = function() {
        return this.$arrow = this.$arrow || this.tip().find(".tooltip-arrow");
    }, c.prototype.enable = function() {
        this.enabled = !0;
    }, c.prototype.disable = function() {
        this.enabled = !1;
    }, c.prototype.toggleEnabled = function() {
        this.enabled = !this.enabled;
    }, c.prototype.toggle = function(b) {
        var c = this;
        b && (c = a(b.currentTarget).data("bs." + this.type), c || (c = new this.constructor(b.currentTarget, this.getDelegateOptions()), 
        a(b.currentTarget).data("bs." + this.type, c))), b ? (c.inState.click = !c.inState.click, 
        c.isInStateTrue() ? c.enter(c) : c.leave(c)) : c.tip().hasClass("in") ? c.leave(c) : c.enter(c);
    }, c.prototype.destroy = function() {
        var a = this;
        clearTimeout(this.timeout), this.hide(function() {
            a.$element.off("." + a.type).removeData("bs." + a.type), a.$tip && a.$tip.detach(), 
            a.$tip = null, a.$arrow = null, a.$viewport = null;
        });
    };
    var d = a.fn.tooltip;
    a.fn.tooltip = b, a.fn.tooltip.Constructor = c, a.fn.tooltip.noConflict = function() {
        return a.fn.tooltip = d, this;
    };
}(jQuery), +function(a) {
    "use strict";
    function b() {
        var a = document.createElement("bootstrap"), b = {
            WebkitTransition: "webkitTransitionEnd",
            MozTransition: "transitionend",
            OTransition: "oTransitionEnd otransitionend",
            transition: "transitionend"
        };
        for (var c in b) if (void 0 !== a.style[c]) return {
            end: b[c]
        };
        return !1;
    }
    a.fn.emulateTransitionEnd = function(b) {
        var c = !1, d = this;
        a(this).one("bsTransitionEnd", function() {
            c = !0;
        });
        var e = function() {
            c || a(d).trigger(a.support.transition.end);
        };
        return setTimeout(e, b), this;
    }, a(function() {
        a.support.transition = b(), a.support.transition && (a.event.special.bsTransitionEnd = {
            bindType: a.support.transition.end,
            delegateType: a.support.transition.end,
            handle: function(b) {
                return a(b.target).is(this) ? b.handleObj.handler.apply(this, arguments) : void 0;
            }
        });
    });
}(jQuery), "object" != typeof JSON && (JSON = {}), function() {
    "use strict";
    function f(a) {
        return 10 > a ? "0" + a : a;
    }
    function quote(a) {
        return escapable.lastIndex = 0, escapable.test(a) ? '"' + a.replace(escapable, function(a) {
            var b = meta[a];
            return "string" == typeof b ? b : "\\u" + ("0000" + a.charCodeAt(0).toString(16)).slice(-4);
        }) + '"' : '"' + a + '"';
    }
    function str(a, b) {
        var c, d, e, f, g, h = gap, i = b[a];
        switch (i && "object" == typeof i && "function" == typeof i.toJSON && (i = i.toJSON(a)), 
        "function" == typeof rep && (i = rep.call(b, a, i)), typeof i) {
          case "string":
            return quote(i);

          case "number":
            return isFinite(i) ? String(i) : "null";

          case "boolean":
          case "null":
            return String(i);

          case "object":
            if (!i) return "null";
            if (gap += indent, g = [], "[object Array]" === Object.prototype.toString.apply(i)) {
                for (f = i.length, c = 0; f > c; c += 1) g[c] = str(c, i) || "null";
                return e = 0 === g.length ? "[]" : gap ? "[\n" + gap + g.join(",\n" + gap) + "\n" + h + "]" : "[" + g.join(",") + "]", 
                gap = h, e;
            }
            if (rep && "object" == typeof rep) for (f = rep.length, c = 0; f > c; c += 1) "string" == typeof rep[c] && (d = rep[c], 
            e = str(d, i), e && g.push(quote(d) + (gap ? ": " : ":") + e)); else for (d in i) Object.prototype.hasOwnProperty.call(i, d) && (e = str(d, i), 
            e && g.push(quote(d) + (gap ? ": " : ":") + e));
            return e = 0 === g.length ? "{}" : gap ? "{\n" + gap + g.join(",\n" + gap) + "\n" + h + "}" : "{" + g.join(",") + "}", 
            gap = h, e;
        }
    }
    "function" != typeof Date.prototype.toJSON && (Date.prototype.toJSON = function(a) {
        return isFinite(this.valueOf()) ? this.getUTCFullYear() + "-" + f(this.getUTCMonth() + 1) + "-" + f(this.getUTCDate()) + "T" + f(this.getUTCHours()) + ":" + f(this.getUTCMinutes()) + ":" + f(this.getUTCSeconds()) + "Z" : null;
    }, String.prototype.toJSON = Number.prototype.toJSON = Boolean.prototype.toJSON = function(a) {
        return this.valueOf();
    });
    var cx = /[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g, escapable = /[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g, gap, indent, meta = {
        "\b": "\\b",
        "	": "\\t",
        "\n": "\\n",
        "\f": "\\f",
        "\r": "\\r",
        '"': '\\"',
        "\\": "\\\\"
    }, rep;
    "function" != typeof JSON.stringify && (JSON.stringify = function(a, b, c) {
        var d;
        if (gap = "", indent = "", "number" == typeof c) for (d = 0; c > d; d += 1) indent += " "; else "string" == typeof c && (indent = c);
        if (rep = b, !b || "function" == typeof b || "object" == typeof b && "number" == typeof b.length) return str("", {
            "": a
        });
        throw new Error("JSON.stringify");
    }), "function" != typeof JSON.parse && (JSON.parse = function(text, reviver) {
        function walk(a, b) {
            var c, d, e = a[b];
            if (e && "object" == typeof e) for (c in e) Object.prototype.hasOwnProperty.call(e, c) && (d = walk(e, c), 
            void 0 !== d ? e[c] = d : delete e[c]);
            return reviver.call(a, b, e);
        }
        var j;
        if (text = String(text), cx.lastIndex = 0, cx.test(text) && (text = text.replace(cx, function(a) {
            return "\\u" + ("0000" + a.charCodeAt(0).toString(16)).slice(-4);
        })), /^[\],:{}\s]*$/.test(text.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g, "@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g, "]").replace(/(?:^|:|,)(?:\s*\[)+/g, ""))) return j = eval("(" + text + ")"), 
        "function" == typeof reviver ? walk({
            "": j
        }, "") : j;
        throw new SyntaxError("JSON.parse");
    });
}(), function(a, b) {
    "use strict";
    var c = a.History = a.History || {};
    if ("undefined" != typeof c.Adapter) throw new Error("History.js Adapter has already been loaded...");
    c.Adapter = {
        handlers: {},
        _uid: 1,
        uid: function(a) {
            return a._uid || (a._uid = c.Adapter._uid++);
        },
        bind: function(a, b, d) {
            var e = c.Adapter.uid(a);
            c.Adapter.handlers[e] = c.Adapter.handlers[e] || {}, c.Adapter.handlers[e][b] = c.Adapter.handlers[e][b] || [], 
            c.Adapter.handlers[e][b].push(d), a["on" + b] = function(a, b) {
                return function(d) {
                    c.Adapter.trigger(a, b, d);
                };
            }(a, b);
        },
        trigger: function(a, b, d) {
            d = d || {};
            var e, f, g = c.Adapter.uid(a);
            for (c.Adapter.handlers[g] = c.Adapter.handlers[g] || {}, c.Adapter.handlers[g][b] = c.Adapter.handlers[g][b] || [], 
            e = 0, f = c.Adapter.handlers[g][b].length; f > e; ++e) c.Adapter.handlers[g][b][e].apply(this, [ d ]);
        },
        extractEventData: function(a, c) {
            var d = c && c[a] || b;
            return d;
        },
        onDomLoad: function(b) {
            var c = a.setTimeout(function() {
                b();
            }, 2e3);
            a.onload = function() {
                clearTimeout(c), b();
            };
        }
    }, "undefined" != typeof c.init && c.init();
}(window), function(a, b) {
    "use strict";
    var c = a.document, d = a.setTimeout || d, e = a.clearTimeout || e, f = a.setInterval || f, g = a.History = a.History || {};
    if ("undefined" != typeof g.initHtml4) throw new Error("History.js HTML4 Support has already been loaded...");
    g.initHtml4 = function() {
        return "undefined" != typeof g.initHtml4.initialized ? !1 : (g.initHtml4.initialized = !0, 
        g.enabled = !0, g.savedHashes = [], g.isLastHash = function(a) {
            var b, c = g.getHashByIndex();
            return b = a === c;
        }, g.isHashEqual = function(a, b) {
            return a = encodeURIComponent(a).replace(/%25/g, "%"), b = encodeURIComponent(b).replace(/%25/g, "%"), 
            a === b;
        }, g.saveHash = function(a) {
            return g.isLastHash(a) ? !1 : (g.savedHashes.push(a), !0);
        }, g.getHashByIndex = function(a) {
            var b = null;
            return b = "undefined" == typeof a ? g.savedHashes[g.savedHashes.length - 1] : 0 > a ? g.savedHashes[g.savedHashes.length + a] : g.savedHashes[a];
        }, g.discardedHashes = {}, g.discardedStates = {}, g.discardState = function(a, b, c) {
            var d, e = g.getHashByState(a);
            return d = {
                discardedState: a,
                backState: c,
                forwardState: b
            }, g.discardedStates[e] = d, !0;
        }, g.discardHash = function(a, b, c) {
            var d = {
                discardedHash: a,
                backState: c,
                forwardState: b
            };
            return g.discardedHashes[a] = d, !0;
        }, g.discardedState = function(a) {
            var b, c = g.getHashByState(a);
            return b = g.discardedStates[c] || !1;
        }, g.discardedHash = function(a) {
            var b = g.discardedHashes[a] || !1;
            return b;
        }, g.recycleState = function(a) {
            var b = g.getHashByState(a);
            return g.discardedState(a) && delete g.discardedStates[b], !0;
        }, g.emulated.hashChange && (g.hashChangeInit = function() {
            g.checkerFunction = null;
            var b, d, e, h, i = "", j = Boolean(g.getHash());
            return g.isInternetExplorer() ? (b = "historyjs-iframe", d = c.createElement("iframe"), 
            d.setAttribute("id", b), d.setAttribute("src", "#"), d.style.display = "none", c.body.appendChild(d), 
            d.contentWindow.document.open(), d.contentWindow.document.close(), e = "", h = !1, 
            g.checkerFunction = function() {
                if (h) return !1;
                h = !0;
                var b = g.getHash(), c = g.getHash(d.contentWindow.document);
                return b !== i ? (i = b, c !== b && (e = c = b, d.contentWindow.document.open(), 
                d.contentWindow.document.close(), d.contentWindow.document.location.hash = g.escapeHash(b)), 
                g.Adapter.trigger(a, "hashchange")) : c !== e && (e = c, j && "" === c ? g.back() : g.setHash(c, !1)), 
                h = !1, !0;
            }) : g.checkerFunction = function() {
                var b = g.getHash() || "";
                return b !== i && (i = b, g.Adapter.trigger(a, "hashchange")), !0;
            }, g.intervalList.push(f(g.checkerFunction, g.options.hashChangeInterval)), !0;
        }, g.Adapter.onDomLoad(g.hashChangeInit)), g.emulated.pushState && (g.onHashChange = function(b) {
            var c, d = b && b.newURL || g.getLocationHref(), e = g.getHashByUrl(d), f = null, h = null;
            return g.isLastHash(e) ? (g.busy(!1), !1) : (g.doubleCheckComplete(), g.saveHash(e), 
            e && g.isTraditionalAnchor(e) ? (g.Adapter.trigger(a, "anchorchange"), g.busy(!1), 
            !1) : (f = g.extractState(g.getFullUrl(e || g.getLocationHref()), !0), g.isLastSavedState(f) ? (g.busy(!1), 
            !1) : (h = g.getHashByState(f), c = g.discardedState(f), c ? (g.getHashByIndex(-2) === g.getHashByState(c.forwardState) ? g.back(!1) : g.forward(!1), 
            !1) : (g.pushState(f.data, f.title, encodeURI(f.url), !1), !0))));
        }, g.Adapter.bind(a, "hashchange", g.onHashChange), g.pushState = function(b, c, d, e) {
            if (d = encodeURI(d).replace(/%25/g, "%"), g.getHashByUrl(d)) throw new Error("History.js does not support states with fragment-identifiers (hashes/anchors).");
            if (e !== !1 && g.busy()) return g.pushQueue({
                scope: g,
                callback: g.pushState,
                args: arguments,
                queue: e
            }), !1;
            g.busy(!0);
            var f = g.createStateObject(b, c, d), h = g.getHashByState(f), i = g.getState(!1), j = g.getHashByState(i), k = g.getHash(), l = g.expectedStateId == f.id;
            return g.storeState(f), g.expectedStateId = f.id, g.recycleState(f), g.setTitle(f), 
            h === j ? (g.busy(!1), !1) : (g.saveState(f), l || g.Adapter.trigger(a, "statechange"), 
            !g.isHashEqual(h, k) && !g.isHashEqual(h, g.getShortUrl(g.getLocationHref())) && g.setHash(h, !1), 
            g.busy(!1), !0);
        }, g.replaceState = function(b, c, d, e) {
            if (d = encodeURI(d).replace(/%25/g, "%"), g.getHashByUrl(d)) throw new Error("History.js does not support states with fragment-identifiers (hashes/anchors).");
            if (e !== !1 && g.busy()) return g.pushQueue({
                scope: g,
                callback: g.replaceState,
                args: arguments,
                queue: e
            }), !1;
            g.busy(!0);
            var f = g.createStateObject(b, c, d), h = g.getHashByState(f), i = g.getState(!1), j = g.getHashByState(i), k = g.getStateByIndex(-2);
            return g.discardState(i, f, k), h === j ? (g.storeState(f), g.expectedStateId = f.id, 
            g.recycleState(f), g.setTitle(f), g.saveState(f), g.Adapter.trigger(a, "statechange"), 
            g.busy(!1)) : g.pushState(f.data, f.title, f.url, !1), !0;
        }), g.emulated.pushState && g.getHash() && !g.emulated.hashChange && g.Adapter.onDomLoad(function() {
            g.Adapter.trigger(a, "hashchange");
        }), void 0);
    }, "undefined" != typeof g.init && g.init();
}(window), function(a, b) {
    "use strict";
    var c = a.console || b, d = a.document, e = a.navigator, f = !1, g = a.setTimeout, h = a.clearTimeout, i = a.setInterval, j = a.clearInterval, k = a.JSON, l = a.alert, m = a.History = a.History || {}, n = a.history;
    try {
        f = a.sessionStorage, f.setItem("TEST", "1"), f.removeItem("TEST");
    } catch (o) {
        f = !1;
    }
    if (k.stringify = k.stringify || k.encode, k.parse = k.parse || k.decode, "undefined" != typeof m.init) throw new Error("History.js Core has already been loaded...");
    m.init = function(a) {
        return "undefined" == typeof m.Adapter ? !1 : ("undefined" != typeof m.initCore && m.initCore(), 
        "undefined" != typeof m.initHtml4 && m.initHtml4(), !0);
    }, m.initCore = function(o) {
        if ("undefined" != typeof m.initCore.initialized) return !1;
        if (m.initCore.initialized = !0, m.options = m.options || {}, m.options.hashChangeInterval = m.options.hashChangeInterval || 100, 
        m.options.safariPollInterval = m.options.safariPollInterval || 500, m.options.doubleCheckInterval = m.options.doubleCheckInterval || 500, 
        m.options.disableSuid = m.options.disableSuid || !1, m.options.storeInterval = m.options.storeInterval || 1e3, 
        m.options.busyDelay = m.options.busyDelay || 250, m.options.debug = m.options.debug || !1, 
        m.options.initialTitle = m.options.initialTitle || d.title, m.options.html4Mode = m.options.html4Mode || !1, 
        m.options.delayInit = m.options.delayInit || !1, m.intervalList = [], m.clearAllIntervals = function() {
            var a, b = m.intervalList;
            if ("undefined" != typeof b && null !== b) {
                for (a = 0; a < b.length; a++) j(b[a]);
                m.intervalList = null;
            }
        }, m.debug = function() {
            (m.options.debug || !1) && m.log.apply(m, arguments);
        }, m.log = function() {
            var a, b, e, f, g, h = "undefined" != typeof c && "undefined" != typeof c.log && "undefined" != typeof c.log.apply, i = d.getElementById("log");
            for (h ? (f = Array.prototype.slice.call(arguments), a = f.shift(), "undefined" != typeof c.debug ? c.debug.apply(c, [ a, f ]) : c.log.apply(c, [ a, f ])) : a = "\n" + arguments[0] + "\n", 
            b = 1, e = arguments.length; e > b; ++b) {
                if (g = arguments[b], "object" == typeof g && "undefined" != typeof k) try {
                    g = k.stringify(g);
                } catch (j) {}
                a += "\n" + g + "\n";
            }
            return i ? (i.value += a + "\n-----\n", i.scrollTop = i.scrollHeight - i.clientHeight) : h || l(a), 
            !0;
        }, m.getInternetExplorerMajorVersion = function() {
            var a = m.getInternetExplorerMajorVersion.cached = "undefined" != typeof m.getInternetExplorerMajorVersion.cached ? m.getInternetExplorerMajorVersion.cached : function() {
                for (var a = 3, b = d.createElement("div"), c = b.getElementsByTagName("i"); (b.innerHTML = "<!--[if gt IE " + ++a + "]><i></i><![endif]-->") && c[0]; ) ;
                return a > 4 ? a : !1;
            }();
            return a;
        }, m.isInternetExplorer = function() {
            var a = m.isInternetExplorer.cached = "undefined" != typeof m.isInternetExplorer.cached ? m.isInternetExplorer.cached : Boolean(m.getInternetExplorerMajorVersion());
            return a;
        }, m.options.html4Mode ? m.emulated = {
            pushState: !0,
            hashChange: !0
        } : m.emulated = {
            pushState: !Boolean(a.history && a.history.pushState && a.history.replaceState && !/ Mobile\/([1-7][a-z]|(8([abcde]|f(1[0-8]))))/i.test(e.userAgent) && !/AppleWebKit\/5([0-2]|3[0-2])/i.test(e.userAgent)),
            hashChange: Boolean(!("onhashchange" in a || "onhashchange" in d) || m.isInternetExplorer() && m.getInternetExplorerMajorVersion() < 8)
        }, m.enabled = !m.emulated.pushState, m.bugs = {
            setHash: Boolean(!m.emulated.pushState && "Apple Computer, Inc." === e.vendor && /AppleWebKit\/5([0-2]|3[0-3])/.test(e.userAgent)),
            safariPoll: Boolean(!m.emulated.pushState && "Apple Computer, Inc." === e.vendor && /AppleWebKit\/5([0-2]|3[0-3])/.test(e.userAgent)),
            ieDoubleCheck: Boolean(m.isInternetExplorer() && m.getInternetExplorerMajorVersion() < 8),
            hashEscape: Boolean(m.isInternetExplorer() && m.getInternetExplorerMajorVersion() < 7)
        }, m.isEmptyObject = function(a) {
            for (var b in a) if (a.hasOwnProperty(b)) return !1;
            return !0;
        }, m.cloneObject = function(a) {
            var b, c;
            return a ? (b = k.stringify(a), c = k.parse(b)) : c = {}, c;
        }, m.getRootUrl = function() {
            var a = d.location.protocol + "//" + (d.location.hostname || d.location.host);
            return d.location.port && (a += ":" + d.location.port), a += "/";
        }, m.getBaseHref = function() {
            var a = d.getElementsByTagName("base"), b = null, c = "";
            return 1 === a.length && (b = a[0], c = b.href.replace(/[^\/]+$/, "")), c = c.replace(/\/+$/, ""), 
            c && (c += "/"), c;
        }, m.getBaseUrl = function() {
            var a = m.getBaseHref() || m.getBasePageUrl() || m.getRootUrl();
            return a;
        }, m.getPageUrl = function() {
            var a, b = m.getState(!1, !1), c = (b || {}).url || m.getLocationHref();
            return a = c.replace(/\/+$/, "").replace(/[^\/]+$/, function(a, b, c) {
                return /\./.test(a) ? a : a + "/";
            });
        }, m.getBasePageUrl = function() {
            var a = m.getLocationHref().replace(/[#\?].*/, "").replace(/[^\/]+$/, function(a, b, c) {
                return /[^\/]$/.test(a) ? "" : a;
            }).replace(/\/+$/, "") + "/";
            return a;
        }, m.getFullUrl = function(a, b) {
            var c = a, d = a.substring(0, 1);
            return b = "undefined" == typeof b ? !0 : b, /[a-z]+\:\/\//.test(a) || (c = "/" === d ? m.getRootUrl() + a.replace(/^\/+/, "") : "#" === d ? m.getPageUrl().replace(/#.*/, "") + a : "?" === d ? m.getPageUrl().replace(/[\?#].*/, "") + a : b ? m.getBaseUrl() + a.replace(/^(\.\/)+/, "") : m.getBasePageUrl() + a.replace(/^(\.\/)+/, "")), 
            c.replace(/\#$/, "");
        }, m.getShortUrl = function(a) {
            var b = a, c = m.getBaseUrl(), d = m.getRootUrl();
            return m.emulated.pushState && (b = b.replace(c, "")), b = b.replace(d, "/"), m.isTraditionalAnchor(b) && (b = "./" + b), 
            b = b.replace(/^(\.\/)+/g, "./").replace(/\#$/, "");
        }, m.getLocationHref = function(a) {
            return a = a || d, a.URL === a.location.href ? a.location.href : a.location.href === decodeURIComponent(a.URL) ? a.URL : a.location.hash && decodeURIComponent(a.location.href.replace(/^[^#]+/, "")) === a.location.hash ? a.location.href : -1 == a.URL.indexOf("#") && -1 != a.location.href.indexOf("#") ? a.location.href : a.URL || a.location.href;
        }, m.store = {}, m.idToState = m.idToState || {}, m.stateToId = m.stateToId || {}, 
        m.urlToId = m.urlToId || {}, m.storedStates = m.storedStates || [], m.savedStates = m.savedStates || [], 
        m.normalizeStore = function() {
            m.store.idToState = m.store.idToState || {}, m.store.urlToId = m.store.urlToId || {}, 
            m.store.stateToId = m.store.stateToId || {};
        }, m.getState = function(a, b) {
            "undefined" == typeof a && (a = !0), "undefined" == typeof b && (b = !0);
            var c = m.getLastSavedState();
            return !c && b && (c = m.createStateObject()), a && (c = m.cloneObject(c), c.url = c.cleanUrl || c.url), 
            c;
        }, m.getIdByState = function(a) {
            var b, c = m.extractId(a.url);
            if (!c) if (b = m.getStateString(a), "undefined" != typeof m.stateToId[b]) c = m.stateToId[b]; else if ("undefined" != typeof m.store.stateToId[b]) c = m.store.stateToId[b]; else {
                for (;c = new Date().getTime() + String(Math.random()).replace(/\D/g, ""), "undefined" != typeof m.idToState[c] || "undefined" != typeof m.store.idToState[c]; ) ;
                m.stateToId[b] = c, m.idToState[c] = a;
            }
            return c;
        }, m.normalizeState = function(a) {
            var b, c;
            return a && "object" == typeof a || (a = {}), "undefined" != typeof a.normalized ? a : (a.data && "object" == typeof a.data || (a.data = {}), 
            b = {}, b.normalized = !0, b.title = a.title || "", b.url = m.getFullUrl(a.url ? a.url : m.getLocationHref()), 
            b.hash = m.getShortUrl(b.url), b.data = m.cloneObject(a.data), b.id = m.getIdByState(b), 
            b.cleanUrl = b.url.replace(/\??\&_suid.*/, ""), b.url = b.cleanUrl, c = !m.isEmptyObject(b.data), 
            (b.title || c) && m.options.disableSuid !== !0 && (b.hash = m.getShortUrl(b.url).replace(/\??\&_suid.*/, ""), 
            /\?/.test(b.hash) || (b.hash += "?"), b.hash += "&_suid=" + b.id), b.hashedUrl = m.getFullUrl(b.hash), 
            (m.emulated.pushState || m.bugs.safariPoll) && m.hasUrlDuplicate(b) && (b.url = b.hashedUrl), 
            b);
        }, m.createStateObject = function(a, b, c) {
            var d = {
                data: a,
                title: b,
                url: c
            };
            return d = m.normalizeState(d);
        }, m.getStateById = function(a) {
            a = String(a);
            var c = m.idToState[a] || m.store.idToState[a] || b;
            return c;
        }, m.getStateString = function(a) {
            var b, c, d;
            return b = m.normalizeState(a), c = {
                data: b.data,
                title: a.title,
                url: a.url
            }, d = k.stringify(c);
        }, m.getStateId = function(a) {
            var b, c;
            return b = m.normalizeState(a), c = b.id;
        }, m.getHashByState = function(a) {
            var b, c;
            return b = m.normalizeState(a), c = b.hash;
        }, m.extractId = function(a) {
            var b, c, d, e;
            return e = -1 != a.indexOf("#") ? a.split("#")[0] : a, c = /(.*)\&_suid=([0-9]+)$/.exec(e), 
            d = c ? c[1] || a : a, b = c ? String(c[2] || "") : "", b || !1;
        }, m.isTraditionalAnchor = function(a) {
            var b = !/[\/\?\.]/.test(a);
            return b;
        }, m.extractState = function(a, b) {
            var c, d, e = null;
            return b = b || !1, c = m.extractId(a), c && (e = m.getStateById(c)), e || (d = m.getFullUrl(a), 
            c = m.getIdByUrl(d) || !1, c && (e = m.getStateById(c)), !e && b && !m.isTraditionalAnchor(a) && (e = m.createStateObject(null, null, d))), 
            e;
        }, m.getIdByUrl = function(a) {
            var c = m.urlToId[a] || m.store.urlToId[a] || b;
            return c;
        }, m.getLastSavedState = function() {
            return m.savedStates[m.savedStates.length - 1] || b;
        }, m.getLastStoredState = function() {
            return m.storedStates[m.storedStates.length - 1] || b;
        }, m.hasUrlDuplicate = function(a) {
            var b, c = !1;
            return b = m.extractState(a.url), c = b && b.id !== a.id;
        }, m.storeState = function(a) {
            return m.urlToId[a.url] = a.id, m.storedStates.push(m.cloneObject(a)), a;
        }, m.isLastSavedState = function(a) {
            var b, c, d, e = !1;
            return m.savedStates.length && (b = a.id, c = m.getLastSavedState(), d = c.id, e = b === d), 
            e;
        }, m.saveState = function(a) {
            return m.isLastSavedState(a) ? !1 : (m.savedStates.push(m.cloneObject(a)), !0);
        }, m.getStateByIndex = function(a) {
            var b = null;
            return b = "undefined" == typeof a ? m.savedStates[m.savedStates.length - 1] : 0 > a ? m.savedStates[m.savedStates.length + a] : m.savedStates[a];
        }, m.getCurrentIndex = function() {
            var a = null;
            return a = m.savedStates.length < 1 ? 0 : m.savedStates.length - 1;
        }, m.getHash = function(a) {
            var b, c = m.getLocationHref(a);
            return b = m.getHashByUrl(c);
        }, m.unescapeHash = function(a) {
            var b = m.normalizeHash(a);
            return b = decodeURIComponent(b);
        }, m.normalizeHash = function(a) {
            var b = a.replace(/[^#]*#/, "").replace(/#.*/, "");
            return b;
        }, m.setHash = function(a, b) {
            var c, e;
            return b !== !1 && m.busy() ? (m.pushQueue({
                scope: m,
                callback: m.setHash,
                args: arguments,
                queue: b
            }), !1) : (m.busy(!0), c = m.extractState(a, !0), c && !m.emulated.pushState ? m.pushState(c.data, c.title, c.url, !1) : m.getHash() !== a && (m.bugs.setHash ? (e = m.getPageUrl(), 
            m.pushState(null, null, e + "#" + a, !1)) : d.location.hash = a), m);
        }, m.escapeHash = function(b) {
            var c = m.normalizeHash(b);
            return c = a.encodeURIComponent(c), m.bugs.hashEscape || (c = c.replace(/\%21/g, "!").replace(/\%26/g, "&").replace(/\%3D/g, "=").replace(/\%3F/g, "?")), 
            c;
        }, m.getHashByUrl = function(a) {
            var b = String(a).replace(/([^#]*)#?([^#]*)#?(.*)/, "$2");
            return b = m.unescapeHash(b);
        }, m.setTitle = function(a) {
            var b, c = a.title;
            c || (b = m.getStateByIndex(0), b && b.url === a.url && (c = b.title || m.options.initialTitle));
            try {
                d.getElementsByTagName("title")[0].innerHTML = c.replace("<", "&lt;").replace(">", "&gt;").replace(" & ", " &amp; ");
            } catch (e) {}
            return d.title = c, m;
        }, m.queues = [], m.busy = function(a) {
            if ("undefined" != typeof a ? m.busy.flag = a : "undefined" == typeof m.busy.flag && (m.busy.flag = !1), 
            !m.busy.flag) {
                h(m.busy.timeout);
                var b = function() {
                    var a, c, d;
                    if (!m.busy.flag) for (a = m.queues.length - 1; a >= 0; --a) c = m.queues[a], 0 !== c.length && (d = c.shift(), 
                    m.fireQueueItem(d), m.busy.timeout = g(b, m.options.busyDelay));
                };
                m.busy.timeout = g(b, m.options.busyDelay);
            }
            return m.busy.flag;
        }, m.busy.flag = !1, m.fireQueueItem = function(a) {
            return a.callback.apply(a.scope || m, a.args || []);
        }, m.pushQueue = function(a) {
            return m.queues[a.queue || 0] = m.queues[a.queue || 0] || [], m.queues[a.queue || 0].push(a), 
            m;
        }, m.queue = function(a, b) {
            return "function" == typeof a && (a = {
                callback: a
            }), "undefined" != typeof b && (a.queue = b), m.busy() ? m.pushQueue(a) : m.fireQueueItem(a), 
            m;
        }, m.clearQueue = function() {
            return m.busy.flag = !1, m.queues = [], m;
        }, m.stateChanged = !1, m.doubleChecker = !1, m.doubleCheckComplete = function() {
            return m.stateChanged = !0, m.doubleCheckClear(), m;
        }, m.doubleCheckClear = function() {
            return m.doubleChecker && (h(m.doubleChecker), m.doubleChecker = !1), m;
        }, m.doubleCheck = function(a) {
            return m.stateChanged = !1, m.doubleCheckClear(), m.bugs.ieDoubleCheck && (m.doubleChecker = g(function() {
                return m.doubleCheckClear(), m.stateChanged || a(), !0;
            }, m.options.doubleCheckInterval)), m;
        }, m.safariStatePoll = function() {
            var b, c = m.extractState(m.getLocationHref());
            return m.isLastSavedState(c) ? void 0 : (b = c, b || (b = m.createStateObject()), 
            m.Adapter.trigger(a, "popstate"), m);
        }, m.back = function(a) {
            return a !== !1 && m.busy() ? (m.pushQueue({
                scope: m,
                callback: m.back,
                args: arguments,
                queue: a
            }), !1) : (m.busy(!0), m.doubleCheck(function() {
                m.back(!1);
            }), n.go(-1), !0);
        }, m.forward = function(a) {
            return a !== !1 && m.busy() ? (m.pushQueue({
                scope: m,
                callback: m.forward,
                args: arguments,
                queue: a
            }), !1) : (m.busy(!0), m.doubleCheck(function() {
                m.forward(!1);
            }), n.go(1), !0);
        }, m.go = function(a, b) {
            var c;
            if (a > 0) for (c = 1; a >= c; ++c) m.forward(b); else {
                if (!(0 > a)) throw new Error("History.go: History.go requires a positive or negative integer passed.");
                for (c = -1; c >= a; --c) m.back(b);
            }
            return m;
        }, m.emulated.pushState) {
            var p = function() {};
            m.pushState = m.pushState || p, m.replaceState = m.replaceState || p;
        } else m.onPopState = function(b, c) {
            var d, e, f = !1, g = !1;
            return m.doubleCheckComplete(), d = m.getHash(), d ? (e = m.extractState(d || m.getLocationHref(), !0), 
            e ? m.replaceState(e.data, e.title, e.url, !1) : (m.Adapter.trigger(a, "anchorchange"), 
            m.busy(!1)), m.expectedStateId = !1, !1) : (f = m.Adapter.extractEventData("state", b, c) || !1, 
            g = f ? m.getStateById(f) : m.expectedStateId ? m.getStateById(m.expectedStateId) : m.extractState(m.getLocationHref()), 
            g || (g = m.createStateObject(null, null, m.getLocationHref())), m.expectedStateId = !1, 
            m.isLastSavedState(g) ? (m.busy(!1), !1) : (m.storeState(g), m.saveState(g), m.setTitle(g), 
            m.Adapter.trigger(a, "statechange"), m.busy(!1), !0));
        }, m.Adapter.bind(a, "popstate", m.onPopState), m.pushState = function(b, c, d, e) {
            if (m.getHashByUrl(d) && m.emulated.pushState) throw new Error("History.js does not support states with fragement-identifiers (hashes/anchors).");
            if (e !== !1 && m.busy()) return m.pushQueue({
                scope: m,
                callback: m.pushState,
                args: arguments,
                queue: e
            }), !1;
            m.busy(!0);
            var f = m.createStateObject(b, c, d);
            return m.isLastSavedState(f) ? m.busy(!1) : (m.storeState(f), m.expectedStateId = f.id, 
            n.pushState(f.id, f.title, f.url), m.Adapter.trigger(a, "popstate")), !0;
        }, m.replaceState = function(b, c, d, e) {
            if (m.getHashByUrl(d) && m.emulated.pushState) throw new Error("History.js does not support states with fragement-identifiers (hashes/anchors).");
            if (e !== !1 && m.busy()) return m.pushQueue({
                scope: m,
                callback: m.replaceState,
                args: arguments,
                queue: e
            }), !1;
            m.busy(!0);
            var f = m.createStateObject(b, c, d);
            return m.isLastSavedState(f) ? m.busy(!1) : (m.storeState(f), m.expectedStateId = f.id, 
            n.replaceState(f.id, f.title, f.url), m.Adapter.trigger(a, "popstate")), !0;
        };
        if (f) {
            try {
                m.store = k.parse(f.getItem("History.store")) || {};
            } catch (q) {
                m.store = {};
            }
            m.normalizeStore();
        } else m.store = {}, m.normalizeStore();
        m.Adapter.bind(a, "unload", m.clearAllIntervals), m.saveState(m.storeState(m.extractState(m.getLocationHref(), !0))), 
        f && (m.onUnload = function() {
            var a, b, c;
            try {
                a = k.parse(f.getItem("History.store")) || {};
            } catch (d) {
                a = {};
            }
            a.idToState = a.idToState || {}, a.urlToId = a.urlToId || {}, a.stateToId = a.stateToId || {};
            for (b in m.idToState) m.idToState.hasOwnProperty(b) && (a.idToState[b] = m.idToState[b]);
            for (b in m.urlToId) m.urlToId.hasOwnProperty(b) && (a.urlToId[b] = m.urlToId[b]);
            for (b in m.stateToId) m.stateToId.hasOwnProperty(b) && (a.stateToId[b] = m.stateToId[b]);
            m.store = a, m.normalizeStore(), c = k.stringify(a);
            try {
                f.setItem("History.store", c);
            } catch (e) {
                if (e.code !== DOMException.QUOTA_EXCEEDED_ERR) throw e;
                f.length && (f.removeItem("History.store"), f.setItem("History.store", c));
            }
        }, m.intervalList.push(i(m.onUnload, m.options.storeInterval)), m.Adapter.bind(a, "beforeunload", m.onUnload), 
        m.Adapter.bind(a, "unload", m.onUnload)), m.emulated.pushState || (m.bugs.safariPoll && m.intervalList.push(i(m.safariStatePoll, m.options.safariPollInterval)), 
        ("Apple Computer, Inc." === e.vendor || "Mozilla" === (e.appCodeName || "")) && (m.Adapter.bind(a, "hashchange", function() {
            m.Adapter.trigger(a, "popstate");
        }), m.getHash() && m.Adapter.onDomLoad(function() {
            m.Adapter.trigger(a, "hashchange");
        })));
    }, (!m.options || !m.options.delayInit) && m.init();
}(window);

var qq = function(a) {
    "use strict";
    return {
        hide: function() {
            return a.style.display = "none", this;
        },
        attach: function(b, c) {
            return a.addEventListener ? a.addEventListener(b, c, !1) : a.attachEvent && a.attachEvent("on" + b, c), 
            function() {
                qq(a).detach(b, c);
            };
        },
        detach: function(b, c) {
            return a.removeEventListener ? a.removeEventListener(b, c, !1) : a.attachEvent && a.detachEvent("on" + b, c), 
            this;
        },
        contains: function(b) {
            return a === b ? !0 : a.contains ? a.contains(b) : !!(8 & b.compareDocumentPosition(a));
        },
        insertBefore: function(b) {
            return b.parentNode.insertBefore(a, b), this;
        },
        remove: function() {
            return a.parentNode.removeChild(a), this;
        },
        css: function(b) {
            return null !== b.opacity && "string" != typeof a.style.opacity && "undefined" != typeof a.filters && (b.filter = "alpha(opacity=" + Math.round(100 * b.opacity) + ")"), 
            qq.extend(a.style, b), this;
        },
        hasClass: function(b) {
            var c = new RegExp("(^| )" + b + "( |$)");
            return c.test(a.className);
        },
        addClass: function(b) {
            return qq(a).hasClass(b) || (a.className += " " + b), this;
        },
        removeClass: function(b) {
            var c = new RegExp("(^| )" + b + "( |$)");
            return a.className = a.className.replace(c, " ").replace(/^\s+|\s+$/g, ""), this;
        },
        getByClass: function(b) {
            var c, d = [];
            return a.querySelectorAll ? a.querySelectorAll("." + b) : (c = a.getElementsByTagName("*"), 
            qq.each(c, function(a, c) {
                qq(c).hasClass(b) && d.push(c);
            }), d);
        },
        children: function() {
            for (var b = [], c = a.firstChild; c; ) 1 === c.nodeType && b.push(c), c = c.nextSibling;
            return b;
        },
        setText: function(b) {
            return a.innerText = b, a.textContent = b, this;
        },
        clearText: function() {
            return qq(a).setText("");
        }
    };
};

qq.log = function(a, b) {
    "use strict";
    window.console && (b && "info" !== b ? window.console[b] ? window.console[b](a) : window.console.log("<" + b + "> " + a) : window.console.log(a));
}, qq.isObject = function(a) {
    "use strict";
    return null !== a && a && "object" == typeof a && a.constructor === Object;
}, qq.isFunction = function(a) {
    "use strict";
    return "function" == typeof a;
}, qq.isFileOrInput = function(a) {
    "use strict";
    if (window.File && a instanceof File) return !0;
    if (window.HTMLInputElement) {
        if (a instanceof HTMLInputElement && a.type && "file" === a.type.toLowerCase()) return !0;
    } else if (a.tagName && "input" === a.tagName.toLowerCase() && a.type && "file" === a.type.toLowerCase()) return !0;
    return !1;
}, qq.isXhrUploadSupported = function() {
    "use strict";
    var a = document.createElement("input");
    return a.type = "file", void 0 !== a.multiple && "undefined" != typeof File && "undefined" != typeof FormData && "undefined" != typeof new XMLHttpRequest().upload;
}, qq.isFolderDropSupported = function(a) {
    "use strict";
    return a.items && a.items[0].webkitGetAsEntry;
}, qq.isFileChunkingSupported = function() {
    "use strict";
    return !qq.android() && qq.isXhrUploadSupported() && (File.prototype.slice || File.prototype.webkitSlice || File.prototype.mozSlice);
}, qq.extend = function(a, b, c) {
    "use strict";
    qq.each(b, function(b, d) {
        c && qq.isObject(d) ? (void 0 === a[b] && (a[b] = {}), qq.extend(a[b], d, !0)) : a[b] = d;
    });
}, qq.indexOf = function(a, b, c) {
    "use strict";
    if (a.indexOf) return a.indexOf(b, c);
    c = c || 0;
    var d = a.length;
    for (0 > c && (c += d); d > c; c += 1) if (a.hasOwnProperty(c) && a[c] === b) return c;
    return -1;
}, qq.getUniqueId = function() {
    "use strict";
    return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(a) {
        var b = 16 * Math.random() | 0, c = "x" == a ? b : 3 & b | 8;
        return c.toString(16);
    });
}, qq.ie = function() {
    "use strict";
    return -1 !== navigator.userAgent.indexOf("MSIE");
}, qq.ie10 = function() {
    "use strict";
    return -1 !== navigator.userAgent.indexOf("MSIE 10");
}, qq.safari = function() {
    "use strict";
    return void 0 !== navigator.vendor && -1 !== navigator.vendor.indexOf("Apple");
}, qq.chrome = function() {
    "use strict";
    return void 0 !== navigator.vendor && -1 !== navigator.vendor.indexOf("Google");
}, qq.firefox = function() {
    "use strict";
    return -1 !== navigator.userAgent.indexOf("Mozilla") && void 0 !== navigator.vendor && "" === navigator.vendor;
}, qq.windows = function() {
    "use strict";
    return "Win32" === navigator.platform;
}, qq.android = function() {
    "use strict";
    return -1 !== navigator.userAgent.toLowerCase().indexOf("android");
}, qq.preventDefault = function(a) {
    "use strict";
    a.preventDefault ? a.preventDefault() : a.returnValue = !1;
}, qq.toElement = function() {
    "use strict";
    var a = document.createElement("div");
    return function(b) {
        a.innerHTML = b;
        var c = a.firstChild;
        return a.removeChild(c), c;
    };
}(), qq.each = function(a, b) {
    "use strict";
    var c, d;
    if (a) for (c in a) if (Object.prototype.hasOwnProperty.call(a, c) && (d = b(c, a[c]), 
    d === !1)) break;
}, qq.obj2url = function(a, b, c) {
    "use strict";
    var d, e, f = [], g = "&", h = function(a, c) {
        var d = b ? /\[\]$/.test(b) ? b : b + "[" + c + "]" : c;
        "undefined" !== d && "undefined" !== c && f.push("object" == typeof a ? qq.obj2url(a, d, !0) : "[object Function]" === Object.prototype.toString.call(a) ? encodeURIComponent(d) + "=" + encodeURIComponent(a()) : encodeURIComponent(d) + "=" + encodeURIComponent(a));
    };
    if (!c && b) g = /\?/.test(b) ? /\?$/.test(b) ? "" : "&" : "?", f.push(b), f.push(qq.obj2url(a)); else if ("[object Array]" === Object.prototype.toString.call(a) && "undefined" != typeof a) for (d = -1, 
    e = a.length; e > d; d += 1) h(a[d], d); else if ("undefined" != typeof a && null !== a && "object" == typeof a) for (d in a) a.hasOwnProperty(d) && h(a[d], d); else f.push(encodeURIComponent(b) + "=" + encodeURIComponent(a));
    return b ? f.join(g) : f.join(g).replace(/^&/, "").replace(/%20/g, "+");
}, qq.obj2FormData = function(a, b, c) {
    "use strict";
    return b || (b = new FormData()), qq.each(a, function(a, d) {
        a = c ? c + "[" + a + "]" : a, qq.isObject(d) ? qq.obj2FormData(d, b, a) : qq.isFunction(d) ? b.append(encodeURIComponent(a), encodeURIComponent(d())) : b.append(encodeURIComponent(a), encodeURIComponent(d));
    }), b;
}, qq.obj2Inputs = function(a, b) {
    "use strict";
    var c;
    return b || (b = document.createElement("form")), qq.obj2FormData(a, {
        append: function(a, d) {
            c = document.createElement("input"), c.setAttribute("name", a), c.setAttribute("value", d), 
            b.appendChild(c);
        }
    }), b;
}, qq.setCookie = function(a, b, c) {
    var d = new Date(), e = "";
    c && (d.setTime(d.getTime() + 24 * c * 60 * 60 * 1e3), e = "; expires=" + d.toGMTString()), 
    document.cookie = a + "=" + b + e + "; path=/";
}, qq.getCookie = function(a) {
    for (var b, c = a + "=", d = document.cookie.split(";"), e = 0; e < d.length; e++) {
        for (b = d[e]; " " == b.charAt(0); ) b = b.substring(1, b.length);
        if (0 === b.indexOf(c)) return b.substring(c.length, b.length);
    }
}, qq.getCookieNames = function(a) {
    var b = document.cookie.split(";"), c = [];
    return qq.each(b, function(b, d) {
        d = d.trim();
        var e = d.indexOf("=");
        d.match(a) && c.push(d.substr(0, e));
    }), c;
}, qq.deleteCookie = function(a) {
    qq.setCookie(a, "", -1);
}, qq.areCookiesEnabled = function() {
    var a = 1e5 * Math.random(), b = "qqCookieTest:" + a;
    return qq.setCookie(b, 1), qq.getCookie(b) ? (qq.deleteCookie(b), !0) : !1;
}, qq.parseJson = function(json) {
    return "function" == typeof JSON.parse ? JSON.parse(json) : eval("(" + json + ")");
}, qq.DisposeSupport = function() {
    "use strict";
    var a = [];
    return {
        dispose: function() {
            var b;
            do b = a.shift(), b && b(); while (b);
        },
        attach: function() {
            var a = arguments;
            this.addDisposer(qq(a[0]).attach.apply(this, Array.prototype.slice.call(arguments, 1)));
        },
        addDisposer: function(b) {
            a.push(b);
        }
    };
}, qq.UploadButton = function(a) {
    this._options = {
        element: null,
        multiple: !1,
        acceptFiles: null,
        name: "file",
        onChange: function(a) {},
        hoverClass: "qq-upload-button-hover",
        focusClass: "qq-upload-button-focus"
    }, qq.extend(this._options, a), this._disposeSupport = new qq.DisposeSupport(), 
    this._element = this._options.element, qq(this._element).css({
        position: "relative",
        overflow: "hidden",
        direction: "ltr"
    }), this._input = this._createInput();
}, qq.UploadButton.prototype = {
    getInput: function() {
        return this._input;
    },
    reset: function() {
        this._input.parentNode && qq(this._input).remove(), qq(this._element).removeClass(this._options.focusClass), 
        this._input = this._createInput();
    },
    _createInput: function() {
        var a = document.createElement("input");
        this._options.multiple && a.setAttribute("multiple", "multiple"), this._options.acceptFiles && a.setAttribute("accept", this._options.acceptFiles), 
        a.setAttribute("type", "file"), a.setAttribute("id", "fileInput"), a.setAttribute("name", this._options.name), 
        qq(a).css({
            position: "absolute",
            right: 0,
            top: 0,
            fontFamily: "Arial",
            fontSize: "118px",
            margin: 0,
            padding: 0,
            cursor: "pointer",
            opacity: 0
        }), this._element.appendChild(a);
        var b = this;
        return this._disposeSupport.attach(a, "change", function() {
            b._options.onChange(a);
        }), this._disposeSupport.attach(a, "mouseover", function() {
            qq(b._element).addClass(b._options.hoverClass);
        }), this._disposeSupport.attach(a, "mouseout", function() {
            qq(b._element).removeClass(b._options.hoverClass);
        }), this._disposeSupport.attach(a, "focus", function() {
            qq(b._element).addClass(b._options.focusClass);
        }), this._disposeSupport.attach(a, "blur", function() {
            qq(b._element).removeClass(b._options.focusClass);
        }), window.attachEvent && a.setAttribute("tabIndex", "-1"), a;
    }
}, qq.FineUploaderBasic = function(a) {
    this._options = {
        debug: !1,
        button: null,
        multiple: !0,
        maxConnections: 3,
        disableCancelForFormUploads: !1,
        autoUpload: !0,
        request: {
            endpoint: "/server/upload",
            params: {},
            paramsInBody: !1,
            customHeaders: {},
            forceMultipart: !0,
            inputName: "qqfile",
            uuidName: "qquuid",
            totalFileSizeName: "qqtotalfilesize"
        },
        validation: {
            allowedExtensions: [],
            sizeLimit: 0,
            minSizeLimit: 0,
            stopOnFirstInvalidFile: !0
        },
        callbacks: {
            onSubmit: function(a, b) {},
            onComplete: function(a, b, c) {},
            onCancel: function(a, b) {},
            onUpload: function(a, b) {},
            onUploadChunk: function(a, b, c) {},
            onResume: function(a, b, c) {},
            onProgress: function(a, b, c, d) {},
            onError: function(a, b, c) {},
            onAutoRetry: function(a, b, c) {},
            onManualRetry: function(a, b) {},
            onValidateBatch: function(a) {},
            onValidate: function(a) {}
        },
        messages: {
            typeError: "{file} has an invalid extension. Valid extension(s): {extensions}.",
            sizeError: "{file} is too large, maximum file size is {sizeLimit}.",
            minSizeError: "{file} is too small, minimum file size is {minSizeLimit}.",
            emptyError: "{file} is empty, please select files again without it.",
            noFilesError: "No files to upload.",
            onLeave: "The files are being uploaded, if you leave now the upload will be cancelled."
        },
        retry: {
            enableAuto: !1,
            maxAutoAttempts: 3,
            autoAttemptDelay: 5,
            preventRetryResponseProperty: "preventRetry"
        },
        classes: {
            buttonHover: "qq-upload-button-hover",
            buttonFocus: "qq-upload-button-focus"
        },
        chunking: {
            enabled: !1,
            partSize: 2e6,
            paramNames: {
                partIndex: "qqpartindex",
                partByteOffset: "qqpartbyteoffset",
                chunkSize: "qqchunksize",
                totalFileSize: "qqtotalfilesize",
                totalParts: "qqtotalparts",
                filename: "qqfilename"
            }
        },
        resume: {
            enabled: !1,
            id: null,
            cookiesExpireIn: 7,
            paramNames: {
                resuming: "qqresume"
            }
        },
        formatFileName: function(a) {
            return a.length > 33 && (a = a.slice(0, 19) + "..." + a.slice(-14)), a;
        },
        text: {
            sizeSymbols: [ "kB", "MB", "GB", "TB", "PB", "EB" ]
        }
    }, qq.extend(this._options, a, !0), this._wrapCallbacks(), this._disposeSupport = new qq.DisposeSupport(), 
    this._filesInProgress = [], this._storedFileIds = [], this._autoRetries = [], this._retryTimeouts = [], 
    this._preventRetries = [], this._paramsStore = this._createParamsStore(), this._endpointStore = this._createEndpointStore(), 
    this._handler = this._createUploadHandler(), this._options.button && (this._button = this._createUploadButton(this._options.button)), 
    this._preventLeaveInProgress();
}, qq.FineUploaderBasic.prototype = {
    log: function(a, b) {
        !this._options.debug || b && "info" !== b ? b && "info" !== b && qq.log("[FineUploader] " + a, b) : qq.log("[FineUploader] " + a);
    },
    setParams: function(a, b) {
        null == b ? this._options.request.params = a : this._paramsStore.setParams(a, b);
    },
    setEndpoint: function(a, b) {
        null == b ? this._options.request.endpoint = a : this._endpointStore.setEndpoint(a, b);
    },
    getInProgress: function() {
        return this._filesInProgress.length;
    },
    uploadStoredFiles: function() {
        "use strict";
        for (var a; this._storedFileIds.length; ) a = this._storedFileIds.shift(), this._filesInProgress.push(a), 
        this._handler.upload(a);
    },
    clearStoredFiles: function() {
        this._storedFileIds = [];
    },
    retry: function(a) {
        return this._onBeforeManualRetry(a) ? (this._handler.retry(a), !0) : !1;
    },
    cancel: function(a) {
        this._handler.cancel(a);
    },
    reset: function() {
        this.log("Resetting uploader..."), this._handler.reset(), this._filesInProgress = [], 
        this._storedFileIds = [], this._autoRetries = [], this._retryTimeouts = [], this._preventRetries = [], 
        this._button.reset(), this._paramsStore.reset(), this._endpointStore.reset();
    },
    addFiles: function(a) {
        var b, c, d = this, e = [];
        if (a) {
            for (window.FileList && a instanceof FileList || (a = [].concat(a)), b = 0; b < a.length; b += 1) c = a[b], 
            qq.isFileOrInput(c) ? e.push(c) : d.log(c + " is not a File or INPUT element!  Ignoring!", "warn");
            this.log("Processing " + e.length + " files or inputs..."), this._uploadFileList(e);
        }
    },
    getUuid: function(a) {
        return this._handler.getUuid(a);
    },
    getResumableFilesData: function() {
        return this._handler.getResumableFilesData();
    },
    getSize: function(a) {
        return this._handler.getSize(a);
    },
    getFile: function(a) {
        return this._handler.getFile(a);
    },
    _createUploadButton: function(a) {
        var b = this, c = new qq.UploadButton({
            element: a,
            multiple: this._options.multiple && qq.isXhrUploadSupported(),
            acceptFiles: this._options.validation.acceptFiles,
            onChange: function(a) {
                b._onInputChange(a);
            },
            hoverClass: this._options.classes.buttonHover,
            focusClass: this._options.classes.buttonFocus
        });
        return this._disposeSupport.addDisposer(function() {
            c.dispose();
        }), c;
    },
    _createUploadHandler: function() {
        var a = this;
        return new qq.UploadHandler({
            debug: this._options.debug,
            forceMultipart: this._options.request.forceMultipart,
            maxConnections: this._options.maxConnections,
            customHeaders: this._options.request.customHeaders,
            inputName: this._options.request.inputName,
            uuidParamName: this._options.request.uuidName,
            totalFileSizeParamName: this._options.request.totalFileSizeName,
            demoMode: this._options.demoMode,
            paramsInBody: this._options.request.paramsInBody,
            paramsStore: this._paramsStore,
            endpointStore: this._endpointStore,
            chunking: this._options.chunking,
            resume: this._options.resume,
            log: function(b, c) {
                a.log(b, c);
            },
            onProgress: function(b, c, d, e) {
                a._onProgress(b, c, d, e), a._options.callbacks.onProgress(b, c, d, e);
            },
            onComplete: function(b, c, d, e) {
                a._onComplete(b, c, d, e), a._options.callbacks.onComplete(b, c, d);
            },
            onCancel: function(b, c) {
                a._onCancel(b, c), a._options.callbacks.onCancel(b, c);
            },
            onUpload: function(b, c) {
                a._onUpload(b, c), a._options.callbacks.onUpload(b, c);
            },
            onUploadChunk: function(b, c, d) {
                a._options.callbacks.onUploadChunk(b, c, d);
            },
            onResume: function(b, c, d) {
                return a._options.callbacks.onResume(b, c, d);
            },
            onAutoRetry: function(b, c, d, e) {
                return a._preventRetries[b] = d[a._options.retry.preventRetryResponseProperty], 
                a._shouldAutoRetry(b, c, d) ? (a._maybeParseAndSendUploadError(b, c, d, e), a._options.callbacks.onAutoRetry(b, c, a._autoRetries[b] + 1), 
                a._onBeforeAutoRetry(b, c), a._retryTimeouts[b] = setTimeout(function() {
                    a._onAutoRetry(b, c, d);
                }, 1e3 * a._options.retry.autoAttemptDelay), !0) : !1;
            }
        });
    },
    _preventLeaveInProgress: function() {
        var a = this;
        this._disposeSupport.attach(window, "beforeunload", function(b) {
            if (a._filesInProgress.length) {
                var b = b || window.event;
                return b.returnValue = a._options.messages.onLeave, a._options.messages.onLeave;
            }
        });
    },
    _onSubmit: function(a, b) {
        this._options.autoUpload && this._filesInProgress.push(a);
    },
    _onProgress: function(a, b, c, d) {},
    _onComplete: function(a, b, c, d) {
        this._removeFromFilesInProgress(a), this._maybeParseAndSendUploadError(a, b, c, d);
    },
    _onCancel: function(a, b) {
        this._removeFromFilesInProgress(a), clearTimeout(this._retryTimeouts[a]);
        var c = qq.indexOf(this._storedFileIds, a);
        !this._options.autoUpload && c >= 0 && this._storedFileIds.splice(c, 1);
    },
    _removeFromFilesInProgress: function(a) {
        var b = qq.indexOf(this._filesInProgress, a);
        b >= 0 && this._filesInProgress.splice(b, 1);
    },
    _onUpload: function(a, b) {},
    _onInputChange: function(a) {
        qq.isXhrUploadSupported() ? this.addFiles(a.files) : this.addFiles(a), this._button.reset();
    },
    _onBeforeAutoRetry: function(a, b) {
        this.log("Waiting " + this._options.retry.autoAttemptDelay + " seconds before retrying " + b + "...");
    },
    _onAutoRetry: function(a, b, c) {
        this.log("Retrying " + b + "..."), this._autoRetries[a]++, this._handler.retry(a);
    },
    _shouldAutoRetry: function(a, b, c) {
        return !this._preventRetries[a] && this._options.retry.enableAuto ? (void 0 === this._autoRetries[a] && (this._autoRetries[a] = 0), 
        this._autoRetries[a] < this._options.retry.maxAutoAttempts) : !1;
    },
    _onBeforeManualRetry: function(a) {
        if (this._preventRetries[a]) return this.log("Retries are forbidden for id " + a, "warn"), 
        !1;
        if (this._handler.isValid(a)) {
            var b = this._handler.getName(a);
            return this._options.callbacks.onManualRetry(a, b) === !1 ? !1 : (this.log("Retrying upload for '" + b + "' (id: " + a + ")..."), 
            this._filesInProgress.push(a), !0);
        }
        return this.log("'" + a + "' is not a valid file ID", "error"), !1;
    },
    _maybeParseAndSendUploadError: function(a, b, c, d) {
        if (!c.success) if (d && 200 !== d.status && !c.error) this._options.callbacks.onError(a, b, "XHR returned response code " + d.status); else {
            var e = c.error ? c.error : "Upload failure reason unknown";
            this._options.callbacks.onError(a, b, e);
        }
    },
    _uploadFileList: function(a) {
        var b, c, d;
        if (b = this._getValidationDescriptors(a), d = this._options.callbacks.onValidateBatch(b) === !1, 
        !d) if (a.length > 0) {
            for (c = 0; c < a.length; c++) if (this._validateFile(a[c])) this._uploadFile(a[c]); else if (this._options.validation.stopOnFirstInvalidFile) return;
        } else this._error("noFilesError", "");
    },
    _uploadFile: function(a) {
        var b = this._handler.add(a), c = this._handler.getName(b);
        this._options.callbacks.onSubmit(b, c) !== !1 && (this._onSubmit(b, c), this._options.autoUpload ? this._handler.upload(b) : this._storeFileForLater(b));
    },
    _storeFileForLater: function(a) {
        this._storedFileIds.push(a);
    },
    _validateFile: function(a) {
        var b, c, d;
        return b = this._getValidationDescriptor(a), c = b.name, d = b.size, this._options.callbacks.onValidate(b) === !1 ? !1 : this._isAllowedExtension(c) ? 0 === d ? (this._error("emptyError", c), 
        !1) : d && this._options.validation.sizeLimit && d > this._options.validation.sizeLimit ? (this._error("sizeError", c), 
        !1) : d && d < this._options.validation.minSizeLimit ? (this._error("minSizeError", c), 
        !1) : !0 : (this._error("typeError", c), !1);
    },
    _error: function(a, b) {
        function c(a, b) {
            d = d.replace(a, b);
        }
        var d = this._options.messages[a], e = this._options.validation.allowedExtensions.join(", ").toLowerCase();
        return c("{file}", this._options.formatFileName(b)), c("{extensions}", e), c("{sizeLimit}", this._formatSize(this._options.validation.sizeLimit)), 
        c("{minSizeLimit}", this._formatSize(this._options.validation.minSizeLimit)), this._options.callbacks.onError(null, b, d), 
        d;
    },
    _isAllowedExtension: function(a) {
        var b = this._options.validation.allowedExtensions, c = !1;
        return b.length ? (qq.each(b, function(b, d) {
            var e = new RegExp("\\." + d + "$", "i");
            return null != a.match(e) ? (c = !0, !1) : void 0;
        }), c) : !0;
    },
    _formatSize: function(a) {
        var b = -1;
        do a /= 1024, b++; while (a > 99);
        return Math.max(a, .1).toFixed(1) + this._options.text.sizeSymbols[b];
    },
    _wrapCallbacks: function() {
        var a, b;
        a = this, b = function(b, c, d) {
            try {
                return c.apply(a, d);
            } catch (e) {
                a.log("Caught exception in '" + b + "' callback - " + e.message, "error");
            }
        };
        for (var c in this._options.callbacks) !function() {
            var d, e;
            d = c, e = a._options.callbacks[d], a._options.callbacks[d] = function() {
                return b(d, e, arguments);
            };
        }();
    },
    _parseFileName: function(a) {
        var b;
        return b = a.value ? a.value.replace(/.*(\/|\\)/, "") : null !== a.fileName && void 0 !== a.fileName ? a.fileName : a.name;
    },
    _parseFileSize: function(a) {
        var b;
        return a.value || (b = null !== a.fileSize && void 0 !== a.fileSize ? a.fileSize : a.size), 
        b;
    },
    _getValidationDescriptor: function(a) {
        var b, c, d;
        return d = {}, b = this._parseFileName(a), c = this._parseFileSize(a), d.name = b, 
        c && (d.size = c), d;
    },
    _getValidationDescriptors: function(a) {
        var b = this, c = [];
        return qq.each(a, function(a, d) {
            c.push(b._getValidationDescriptor(d));
        }), c;
    },
    _createParamsStore: function() {
        var a = {}, b = this;
        return {
            setParams: function(b, c) {
                var d = {};
                qq.extend(d, b), a[c] = d;
            },
            getParams: function(c) {
                var d = {};
                return null != c && a[c] ? qq.extend(d, a[c]) : qq.extend(d, b._options.request.params), 
                d;
            },
            remove: function(b) {
                return delete a[b];
            },
            reset: function() {
                a = {};
            }
        };
    },
    _createEndpointStore: function() {
        var a = {}, b = this;
        return {
            setEndpoint: function(b, c) {
                a[c] = b;
            },
            getEndpoint: function(c) {
                return null != c && a[c] ? a[c] : b._options.request.endpoint;
            },
            remove: function(b) {
                return delete a[b];
            },
            reset: function() {
                a = {};
            }
        };
    }
}, qq.DragAndDrop = function(a) {
    "use strict";
    function b() {
        m !== n || k || (i.callbacks.log("Grabbed " + l.length + " files after tree traversal."), 
        j.dropDisabled(!1), i.callbacks.dropProcessing(!1, l));
    }
    function c(a) {
        l.push(a), n += 1, b();
    }
    function d(a) {
        var e, f;
        m += 1, a.isFile ? a.file(function(a) {
            c(a);
        }) : a.isDirectory && (k = !0, e = a.createReader(), e.readEntries(function(a) {
            for (n += 1, f = 0; f < a.length; f += 1) d(a[f]);
            k = !1, a.length || b();
        }));
    }
    function e(a) {
        var c, e, f;
        if (i.callbacks.dropProcessing(!0), j.dropDisabled(!0), a.files.length > 1 && !i.multiple) i.callbacks.dropProcessing(!1), 
        i.callbacks.error("tooManyFilesError", ""), j.dropDisabled(!1); else if (l = [], 
        m = 0, n = 0, qq.isFolderDropSupported(a)) for (e = a.items, c = 0; c < e.length; c += 1) f = e[c].webkitGetAsEntry(), 
        f && (f.isFile ? (l.push(e[c].getAsFile()), c === e.length - 1 && b()) : d(f)); else i.callbacks.dropProcessing(!1, a.files), 
        j.dropDisabled(!1);
    }
    function f(a) {
        j = new qq.UploadDropZone({
            element: a,
            onEnter: function(b) {
                qq(a).addClass(i.classes.dropActive), b.stopPropagation();
            },
            onLeaveNotDescendants: function(b) {
                qq(a).removeClass(i.classes.dropActive);
            },
            onDrop: function(b) {
                i.hideDropzones && qq(a).hide(), qq(a).removeClass(i.classes.dropActive), e(b.dataTransfer);
            }
        }), o.addDisposer(function() {
            j.dispose();
        }), i.hideDropzones && qq(a).hide();
    }
    function g(a) {
        var b;
        return qq.each(a.dataTransfer.types, function(a, c) {
            return "Files" === c ? (b = !0, !1) : void 0;
        }), b;
    }
    function h() {
        i.dropArea && i.extraDropzones.push(i.dropArea);
        var a, b = i.extraDropzones;
        for (a = 0; a < b.length; a += 1) f(b[a]);
        !i.dropArea || qq.ie() && !qq.ie10() || o.attach(document, "dragenter", function(c) {
            if (!j.dropDisabled() && g(c)) {
                if (qq(i.dropArea).hasClass(i.classes.dropDisabled)) return;
                for (i.dropArea.style.display = "block", a = 0; a < b.length; a += 1) b[a].style.display = "block";
            }
        }), o.attach(document, "dragleave", function(c) {
            if (i.hideDropzones && qq.FineUploader.prototype._leaving_document_out(c)) for (a = 0; a < b.length; a += 1) qq(b[a]).hide();
        }), o.attach(document, "drop", function(c) {
            if (i.hideDropzones) for (a = 0; a < b.length; a += 1) qq(b[a]).hide();
            c.preventDefault();
        });
    }
    var i, j, k, l = [], m = 0, n = 0, o = new qq.DisposeSupport();
    return i = {
        dropArea: null,
        extraDropzones: [],
        hideDropzones: !0,
        multiple: !0,
        classes: {
            dropActive: null
        },
        callbacks: {
            dropProcessing: function(a, b) {},
            error: function(a, b) {},
            log: function(a, b) {}
        }
    }, qq.extend(i, a), {
        setup: function() {
            h();
        },
        setupExtraDropzone: function(a) {
            i.extraDropzones.push(a), f(a);
        },
        removeExtraDropzone: function(a) {
            var b, c = i.extraDropzones;
            for (b in c) if (c[b] === a) return c.splice(b, 1);
        },
        dispose: function() {
            o.dispose(), j.dispose();
        }
    };
}, qq.UploadDropZone = function(a) {
    "use strict";
    function b() {
        return qq.safari() || qq.firefox() && qq.windows();
    }
    function c(a) {
        j || (b ? k.attach(document, "dragover", function(a) {
            a.preventDefault();
        }) : k.attach(document, "dragover", function(a) {
            a.dataTransfer && (a.dataTransfer.dropEffect = "none", a.preventDefault());
        }), j = !0);
    }
    function d(a) {
        if (qq.ie() && !qq.ie10()) return !1;
        var b, c = a.dataTransfer, d = qq.safari();
        return b = qq.ie10() ? !0 : "none" !== c.effectAllowed, c && b && (c.files || !d && c.types.contains && c.types.contains("Files"));
    }
    function e(a) {
        return void 0 !== a && (i = a), i;
    }
    function f() {
        k.attach(h, "dragover", function(a) {
            if (d(a)) {
                var b = qq.ie() ? null : a.dataTransfer.effectAllowed;
                "move" === b || "linkMove" === b ? a.dataTransfer.dropEffect = "move" : a.dataTransfer.dropEffect = "copy", 
                a.stopPropagation(), a.preventDefault();
            }
        }), k.attach(h, "dragenter", function(a) {
            if (!e()) {
                if (!d(a)) return;
                g.onEnter(a);
            }
        }), k.attach(h, "dragleave", function(a) {
            if (d(a)) {
                g.onLeave(a);
                var b = document.elementFromPoint(a.clientX, a.clientY);
                qq(this).contains(b) || g.onLeaveNotDescendants(a);
            }
        }), k.attach(h, "drop", function(a) {
            if (!e()) {
                if (!d(a)) return;
                a.preventDefault(), g.onDrop(a);
            }
        });
    }
    var g, h, i, j, k = new qq.DisposeSupport();
    return g = {
        element: null,
        onEnter: function(a) {},
        onLeave: function(a) {},
        onLeaveNotDescendants: function(a) {},
        onDrop: function(a) {}
    }, qq.extend(g, a), h = g.element, c(), f(), {
        dropDisabled: function(a) {
            return e(a);
        },
        dispose: function() {
            k.dispose();
        }
    };
}, qq.FineUploader = function(a) {
    qq.FineUploaderBasic.apply(this, arguments), qq.extend(this._options, {
        element: null,
        listElement: null,
        dragAndDrop: {
            extraDropzones: [],
            hideDropzones: !0,
            disableDefaultDropzone: !1
        },
        text: {
            uploadButton: "Upload a file",
            cancelButton: "Cancel",
            retryButton: "Retry",
            failUpload: "Upload failed",
            dragZone: "Drop files here to upload",
            dropProcessing: "Processing dropped files...",
            formatProgress: "{percent}% of {total_size}",
            waitingForResponse: "Processing..."
        },
        template: '<div class="qq-uploader">' + (this._options.dragAndDrop && this._options.dragAndDrop.disableDefaultDropzone ? "" : '<div class="qq-upload-drop-area"><span>{dragZoneText}</span></div>') + (this._options.button ? "" : '<div class="qq-upload-button"><div>{uploadButtonText}</div></div>') + '<span class="qq-drop-processing"><span>{dropProcessingText}</span><span class="qq-drop-processing-spinner"></span></span>' + (this._options.listElement ? "" : '<ul class="qq-upload-list"></ul>') + "</div>",
        fileTemplate: '<li><div class="qq-progress-bar"></div><span class="qq-upload-spinner"></span><span class="qq-upload-finished"></span><span class="qq-upload-file"></span><span class="qq-upload-size"></span><a class="qq-upload-cancel" href="#">{cancelButtonText}</a><a class="qq-upload-retry" href="#">{retryButtonText}</a><span class="qq-upload-status-text">{statusText}</span></li>',
        classes: {
            button: "qq-upload-button",
            drop: "qq-upload-drop-area",
            dropActive: "qq-upload-drop-area-active",
            dropDisabled: "qq-upload-drop-area-disabled",
            list: "qq-upload-list",
            progressBar: "qq-progress-bar",
            file: "qq-upload-file",
            spinner: "qq-upload-spinner",
            finished: "qq-upload-finished",
            retrying: "qq-upload-retrying",
            retryable: "qq-upload-retryable",
            size: "qq-upload-size",
            cancel: "qq-upload-cancel",
            retry: "qq-upload-retry",
            statusText: "qq-upload-status-text",
            success: "qq-upload-success",
            fail: "qq-upload-fail",
            successIcon: null,
            failIcon: null,
            dropProcessing: "qq-drop-processing",
            dropProcessingSpinner: "qq-drop-processing-spinner"
        },
        failedUploadTextDisplay: {
            mode: "default",
            maxChars: 50,
            responseProperty: "error",
            enableTooltip: !0
        },
        messages: {
            tooManyFilesError: "You may only drop one file"
        },
        retry: {
            showAutoRetryNote: !0,
            autoRetryNote: "Retrying {retryNum}/{maxAuto}...",
            showButton: !1
        },
        showMessage: function(a) {
            setTimeout(function() {
                alert(a);
            }, 0);
        }
    }, !0), qq.extend(this._options, a, !0), this._wrapCallbacks(), this._options.template = this._options.template.replace(/\{dragZoneText\}/g, this._options.text.dragZone), 
    this._options.template = this._options.template.replace(/\{uploadButtonText\}/g, this._options.text.uploadButton), 
    this._options.template = this._options.template.replace(/\{dropProcessingText\}/g, this._options.text.dropProcessing), 
    this._options.fileTemplate = this._options.fileTemplate.replace(/\{cancelButtonText\}/g, this._options.text.cancelButton), 
    this._options.fileTemplate = this._options.fileTemplate.replace(/\{retryButtonText\}/g, this._options.text.retryButton), 
    this._options.fileTemplate = this._options.fileTemplate.replace(/\{statusText\}/g, ""), 
    this._element = this._options.element, this._element.innerHTML = this._options.template, 
    this._listElement = this._options.listElement || this._find(this._element, "list"), 
    this._classes = this._options.classes, this._button || (this._button = this._createUploadButton(this._find(this._element, "button"))), 
    this._bindCancelAndRetryEvents(), this._dnd = this._setupDragAndDrop();
}, qq.extend(qq.FineUploader.prototype, qq.FineUploaderBasic.prototype), qq.extend(qq.FineUploader.prototype, {
    clearStoredFiles: function() {
        qq.FineUploaderBasic.prototype.clearStoredFiles.apply(this, arguments), this._listElement.innerHTML = "";
    },
    addExtraDropzone: function(a) {
        this._dnd.setupExtraDropzone(a);
    },
    removeExtraDropzone: function(a) {
        return this._dnd.removeExtraDropzone(a);
    },
    getItemByFileId: function(a) {
        for (var b = this._listElement.firstChild; b; ) {
            if (b.qqFileId == a) return b;
            b = b.nextSibling;
        }
    },
    cancel: function(a) {
        qq.FineUploaderBasic.prototype.cancel.apply(this, arguments);
        var b = this.getItemByFileId(a);
        qq(b).remove();
    },
    reset: function() {
        qq.FineUploaderBasic.prototype.reset.apply(this, arguments), this._element.innerHTML = this._options.template, 
        this._listElement = this._options.listElement || this._find(this._element, "list"), 
        this._options.button || (this._button = this._createUploadButton(this._find(this._element, "button"))), 
        this._bindCancelAndRetryEvents(), this._dnd.dispose(), this._dnd = this._setupDragAndDrop();
    },
    _setupDragAndDrop: function() {
        var a, b, c, d = this, e = this._find(this._element, "dropProcessing");
        return b = function(a) {
            a.preventDefault();
        }, this._options.dragAndDrop.disableDefaultDropzone || (c = this._find(this._options.element, "drop")), 
        a = new qq.DragAndDrop({
            dropArea: c,
            extraDropzones: this._options.dragAndDrop.extraDropzones,
            hideDropzones: this._options.dragAndDrop.hideDropzones,
            multiple: this._options.multiple,
            classes: {
                dropActive: this._options.classes.dropActive
            },
            callbacks: {
                dropProcessing: function(a, c) {
                    var f = d._button.getInput();
                    a ? (qq(e).css({
                        display: "block"
                    }), qq(f).attach("click", b)) : (qq(e).hide(), qq(f).detach("click", b)), c && d.addFiles(c);
                },
                error: function(a, b) {
                    d._error(a, b);
                },
                log: function(a, b) {
                    d.log(a, b);
                }
            }
        }), a.setup(), a;
    },
    _leaving_document_out: function(a) {
        return (qq.chrome() || qq.safari() && qq.windows()) && 0 == a.clientX && 0 == a.clientY || qq.firefox() && !a.relatedTarget;
    },
    _storeFileForLater: function(a) {
        qq.FineUploaderBasic.prototype._storeFileForLater.apply(this, arguments);
        var b = this.getItemByFileId(a);
        qq(this._find(b, "spinner")).hide();
    },
    _find: function(a, b) {
        var c = qq(a).getByClass(this._options.classes[b])[0];
        if (!c) throw new Error("element not found " + b);
        return c;
    },
    _onSubmit: function(a, b) {
        qq.FineUploaderBasic.prototype._onSubmit.apply(this, arguments), this._addToList(a, b);
    },
    _onProgress: function(a, b, c, d) {
        qq.FineUploaderBasic.prototype._onProgress.apply(this, arguments);
        var e, f, g, h, i, j;
        e = this.getItemByFileId(a), f = this._find(e, "progressBar"), h = Math.round(c / d * 100), 
        c === d ? (i = this._find(e, "cancel"), qq(i).hide(), qq(f).hide(), qq(this._find(e, "statusText")).setText(this._options.text.waitingForResponse), 
        g = this._formatSize(d)) : (g = this._formatProgress(c, d), qq(f).css({
            display: "block"
        })), qq(f).css({
            width: h + "%"
        }), j = this._find(e, "size"), qq(j).css({
            display: "inline"
        }), qq(j).setText(g);
    },
    _onComplete: function(a, b, c, d) {
        qq.FineUploaderBasic.prototype._onComplete.apply(this, arguments);
        var e = this.getItemByFileId(a);
        qq(this._find(e, "statusText")).clearText(), qq(e).removeClass(this._classes.retrying), 
        qq(this._find(e, "progressBar")).hide(), (!this._options.disableCancelForFormUploads || qq.isXhrUploadSupported()) && qq(this._find(e, "cancel")).hide(), 
        qq(this._find(e, "spinner")).hide(), c.success ? (qq(e).addClass(this._classes.success), 
        this._classes.successIcon && (this._find(e, "finished").style.display = "inline-block", 
        qq(e).addClass(this._classes.successIcon))) : (qq(e).addClass(this._classes.fail), 
        this._classes.failIcon && (this._find(e, "finished").style.display = "inline-block", 
        qq(e).addClass(this._classes.failIcon)), this._options.retry.showButton && !this._preventRetries[a] && qq(e).addClass(this._classes.retryable), 
        this._controlFailureTextDisplay(e, c));
    },
    _onUpload: function(a, b) {
        qq.FineUploaderBasic.prototype._onUpload.apply(this, arguments);
        var c = this.getItemByFileId(a);
        this._showSpinner(c);
    },
    _onBeforeAutoRetry: function(a) {
        var b, c, d, e, f, g;
        qq.FineUploaderBasic.prototype._onBeforeAutoRetry.apply(this, arguments), b = this.getItemByFileId(a), 
        c = this._find(b, "progressBar"), this._showCancelLink(b), c.style.width = 0, qq(c).hide(), 
        this._options.retry.showAutoRetryNote && (d = this._find(b, "statusText"), e = this._autoRetries[a] + 1, 
        f = this._options.retry.maxAutoAttempts, g = this._options.retry.autoRetryNote.replace(/\{retryNum\}/g, e), 
        g = g.replace(/\{maxAuto\}/g, f), qq(d).setText(g), 1 === e && qq(b).addClass(this._classes.retrying));
    },
    _onBeforeManualRetry: function(a) {
        if (qq.FineUploaderBasic.prototype._onBeforeManualRetry.apply(this, arguments)) {
            var b = this.getItemByFileId(a);
            return this._find(b, "progressBar").style.width = 0, qq(b).removeClass(this._classes.fail), 
            qq(this._find(b, "statusText")).clearText(), this._showSpinner(b), this._showCancelLink(b), 
            !0;
        }
        return !1;
    },
    _addToList: function(a, b) {
        var c = qq.toElement(this._options.fileTemplate);
        if (this._options.disableCancelForFormUploads && !qq.isXhrUploadSupported()) {
            var d = this._find(c, "cancel");
            qq(d).remove();
        }
        c.qqFileId = a;
        var e = this._find(c, "file");
        qq(e).setText(this._options.formatFileName(b)), qq(this._find(c, "size")).hide(), 
        this._options.multiple || this._clearList(), this._listElement.appendChild(c);
    },
    _clearList: function() {
        this._listElement.innerHTML = "", this.clearStoredFiles();
    },
    _bindCancelAndRetryEvents: function() {
        var a = this, b = this._listElement;
        this._disposeSupport.attach(b, "click", function(b) {
            b = b || window.event;
            var c = b.target || b.srcElement;
            if (qq(c).hasClass(a._classes.cancel) || qq(c).hasClass(a._classes.retry)) {
                qq.preventDefault(b);
                for (var d = c.parentNode; void 0 == d.qqFileId; ) d = c = c.parentNode;
                qq(c).hasClass(a._classes.cancel) ? a.cancel(d.qqFileId) : (qq(d).removeClass(a._classes.retryable), 
                a.retry(d.qqFileId));
            }
        });
    },
    _formatProgress: function(a, b) {
        function c(a, b) {
            d = d.replace(a, b);
        }
        var d = this._options.text.formatProgress;
        return c("{percent}", Math.round(a / b * 100)), c("{total_size}", this._formatSize(b)), 
        d;
    },
    _controlFailureTextDisplay: function(a, b) {
        var c, d, e, f, g;
        c = this._options.failedUploadTextDisplay.mode, d = this._options.failedUploadTextDisplay.maxChars, 
        e = this._options.failedUploadTextDisplay.responseProperty, "custom" === c ? (f = b[e], 
        f ? f.length > d && (g = f.substring(0, d) + "...") : (f = this._options.text.failUpload, 
        this.log("'" + e + "' is not a valid property on the server response.", "warn")), 
        qq(this._find(a, "statusText")).setText(g || f), this._options.failedUploadTextDisplay.enableTooltip && this._showTooltip(a, f)) : "default" === c ? qq(this._find(a, "statusText")).setText(this._options.text.failUpload) : "none" !== c && this.log("failedUploadTextDisplay.mode value of '" + c + "' is not valid", "warn");
    },
    _showTooltip: function(a, b) {
        a.title = b;
    },
    _showSpinner: function(a) {
        var b = this._find(a, "spinner");
        b.style.display = "inline-block";
    },
    _showCancelLink: function(a) {
        if (!this._options.disableCancelForFormUploads || qq.isXhrUploadSupported()) {
            var b = this._find(a, "cancel");
            b.style.display = "inline";
        }
    },
    _error: function(a, b) {
        var c = qq.FineUploaderBasic.prototype._error.apply(this, arguments);
        this._options.showMessage(c);
    }
}), qq.UploadHandler = function(a) {
    "use strict";
    var b, c, d, e, f = [];
    return b = {
        debug: !1,
        forceMultipart: !0,
        paramsInBody: !1,
        paramsStore: {},
        endpointStore: {},
        maxConnections: 3,
        uuidParamName: "qquuid",
        totalFileSizeParamName: "qqtotalfilesize",
        chunking: {
            enabled: !1,
            partSize: 2e6,
            paramNames: {
                partIndex: "qqpartindex",
                partByteOffset: "qqpartbyteoffset",
                chunkSize: "qqchunksize",
                totalParts: "qqtotalparts",
                filename: "qqfilename"
            }
        },
        resume: {
            enabled: !1,
            id: null,
            cookiesExpireIn: 7,
            paramNames: {
                resuming: "qqresume"
            }
        },
        log: function(a, b) {},
        onProgress: function(a, b, c, d) {},
        onComplete: function(a, b, c, d) {},
        onCancel: function(a, b) {},
        onUpload: function(a, b) {},
        onUploadChunk: function(a, b, c) {},
        onAutoRetry: function(a, b, c, d) {},
        onResume: function(a, b, c) {}
    }, qq.extend(b, a), c = b.log, d = function(a) {
        var c, d = qq.indexOf(f, a), g = b.maxConnections;
        f.splice(d, 1), f.length >= g && g > d && (c = f[g - 1], e.upload(c));
    }, e = qq.isXhrUploadSupported() ? new qq.UploadHandlerXhr(b, d, c) : new qq.UploadHandlerForm(b, d, c), 
    {
        add: function(a) {
            return e.add(a);
        },
        upload: function(a) {
            var c = f.push(a);
            return c <= b.maxConnections ? e.upload(a) : void 0;
        },
        retry: function(a) {
            var b = qq.indexOf(f, a);
            return b >= 0 ? e.upload(a, !0) : this.upload(a);
        },
        cancel: function(a) {
            c("Cancelling " + a), b.paramsStore.remove(a), e.cancel(a), d(a);
        },
        cancelAll: function() {
            qq.each(f, function(a, b) {
                this.cancel(b);
            }), f = [];
        },
        getName: function(a) {
            return e.getName(a);
        },
        getSize: function(a) {
            return e.getSize ? e.getSize(a) : void 0;
        },
        getFile: function(a) {
            return e.getFile ? e.getFile(a) : void 0;
        },
        getQueue: function() {
            return f;
        },
        reset: function() {
            c("Resetting upload handler"), f = [], e.reset();
        },
        getUuid: function(a) {
            return e.getUuid(a);
        },
        isValid: function(a) {
            return e.isValid(a);
        },
        getResumableFilesData: function() {
            return e.getResumableFilesData ? e.getResumableFilesData() : [];
        }
    };
}, qq.UploadHandlerForm = function(o, uploadCompleteCallback, logCallback) {
    "use strict";
    function attachLoadEvent(a, b) {
        detachLoadEvents[a.id] = qq(a).attach("load", function() {
            if (log("Received response for " + a.id), a.parentNode) {
                try {
                    if (a.contentDocument && a.contentDocument.body && "false" == a.contentDocument.body.innerHTML) return;
                } catch (c) {
                    log("Error when attempting to access iframe during handling of upload response (" + c + ")", "error");
                }
                b();
            }
        });
    }
    function getIframeContentJson(iframe) {
        var response;
        try {
            var doc = iframe.contentDocument || iframe.contentWindow.document, innerHTML = doc.body.innerHTML;
            log("converting iframe's innerHTML to JSON"), log("innerHTML = " + innerHTML), innerHTML && innerHTML.match(/^<pre/i) && (innerHTML = doc.body.firstChild.firstChild.nodeValue), 
            response = eval("(" + innerHTML + ")");
        } catch (error) {
            log("Error when attempting to parse form upload response (" + error + ")", "error"), 
            response = {
                success: !1
            };
        }
        return response;
    }
    function createIframe(a) {
        var b = qq.toElement('<iframe src="javascript:false;" name="' + a + '" />');
        return b.setAttribute("id", a), b.style.display = "none", document.body.appendChild(b), 
        b;
    }
    function createForm(a, b) {
        var c = options.paramsStore.getParams(a), d = options.demoMode ? "GET" : "POST", e = qq.toElement('<form method="' + d + '" enctype="multipart/form-data"></form>'), f = options.endpointStore.getEndpoint(a), g = f;
        return c[options.uuidParamName] = uuids[a], options.paramsInBody ? qq.obj2Inputs(c, e) : g = qq.obj2url(c, f), 
        e.setAttribute("action", g), e.setAttribute("target", b.name), e.style.display = "none", 
        document.body.appendChild(e), e;
    }
    var options = o, inputs = [], uuids = [], detachLoadEvents = {}, uploadComplete = uploadCompleteCallback, log = logCallback, api;
    return api = {
        add: function(a) {
            a.setAttribute("name", options.inputName);
            var b = inputs.push(a) - 1;
            return uuids[b] = qq.getUniqueId(), a.parentNode && qq(a).remove(), b;
        },
        getName: function(a) {
            return inputs[a].value.replace(/.*(\/|\\)/, "");
        },
        isValid: function(a) {
            return void 0 !== inputs[a];
        },
        reset: function() {
            qq.UploadHandler.prototype.reset.apply(this, arguments), inputs = [], uuids = [], 
            detachLoadEvents = {};
        },
        getUuid: function(a) {
            return uuids[a];
        },
        cancel: function(a) {
            options.onCancel(a, this.getName(a)), delete inputs[a], delete uuids[a], delete detachLoadEvents[a];
            var b = document.getElementById(a);
            b && (b.setAttribute("src", "java" + String.fromCharCode(115) + "cript:false;"), 
            qq(b).remove());
        },
        upload: function(a) {
            var b = inputs[a], c = api.getName(a), d = createIframe(a), e = createForm(a, d);
            if (!b) throw new Error("file with passed id was not added, or already uploaded or cancelled");
            return options.onUpload(a, this.getName(a)), e.appendChild(b), attachLoadEvent(d, function() {
                log("iframe loaded");
                var b = getIframeContentJson(d);
                setTimeout(function() {
                    detachLoadEvents[a](), delete detachLoadEvents[a], qq(d).remove();
                }, 1), (b.success || !options.onAutoRetry(a, c, b)) && (options.onComplete(a, c, b), 
                uploadComplete(a));
            }), log("Sending upload request for " + a), e.submit(), qq(e).remove(), a;
        }
    };
}, qq.UploadHandlerXhr = function(a, b, c) {
    "use strict";
    function d(a, b, c) {
        var d = D.getSize(a), e = D.getName(a);
        b[E.chunking.paramNames.partIndex] = c.part, b[E.chunking.paramNames.partByteOffset] = c.start, 
        b[E.chunking.paramNames.chunkSize] = c.end - c.start, b[E.chunking.paramNames.totalParts] = c.count, 
        b[E.totalFileSizeParamName] = d, M && (b[E.chunking.paramNames.filename] = e);
    }
    function e(a) {
        a[E.resume.paramNames.resuming] = !0;
    }
    function f(a, b, c) {
        return a.slice ? a.slice(b, c) : a.mozSlice ? a.mozSlice(b, c) : a.webkitSlice ? a.webkitSlice(b, c) : void 0;
    }
    function g(a, b) {
        var c = E.chunking.partSize, d = D.getSize(a), e = H[a].file, g = c * b, i = g + c >= d ? d : g + c, j = h(a);
        return {
            part: b,
            start: g,
            end: i,
            count: j,
            blob: f(e, g, i)
        };
    }
    function h(a) {
        var b = D.getSize(a), c = E.chunking.partSize;
        return Math.ceil(b / c);
    }
    function i(a) {
        return H[a].xhr = new XMLHttpRequest(), H[a].xhr;
    }
    function j(a, b, c, d) {
        var e = new FormData(), f = E.demoMode ? "GET" : "POST", g = E.endpointStore.getEndpoint(d), h = g, i = D.getName(d), j = D.getSize(d);
        return a[E.uuidParamName] = H[d].uuid, M && (a[E.totalFileSizeParamName] = j), E.paramsInBody || (a[E.inputName] = i, 
        h = qq.obj2url(a, g)), b.open(f, h, !0), M ? (E.paramsInBody && qq.obj2FormData(a, e), 
        e.append(E.inputName, c), e) : c;
    }
    function k(a, b) {
        var c = E.customHeaders, d = (D.getName(a), H[a].file);
        b.setRequestHeader("X-Requested-With", "XMLHttpRequest"), b.setRequestHeader("Cache-Control", "no-cache"), 
        M || (b.setRequestHeader("Content-Type", "application/octet-stream"), b.setRequestHeader("X-Mime-Type", d.type)), 
        qq.each(c, function(a, c) {
            b.setRequestHeader(a, c);
        });
    }
    function l(a, b, c) {
        var d = D.getName(a), e = D.getSize(a);
        H[a].attemptingResume = !1, E.onProgress(a, d, e, e), E.onComplete(a, d, b, c), 
        delete H[a].xhr, F(a);
    }
    function m(a) {
        var b, c, f = g(a, H[a].remainingChunkIdxs[0]), h = i(a), l = D.getSize(a), m = D.getName(a);
        void 0 === H[a].loaded && (H[a].loaded = 0), w(a, f), h.onreadystatechange = v(a, h), 
        h.upload.onprogress = function(b) {
            if (b.lengthComputable && H[a].loaded < l) {
                var c = b.loaded + H[a].loaded;
                E.onProgress(a, m, c, l);
            }
        }, E.onUploadChunk(a, m, u(f)), c = E.paramsStore.getParams(a), d(a, c, f), H[a].attemptingResume && e(c), 
        b = j(c, h, f.blob, a), k(a, h), G("Sending chunked upload request for " + a + ": bytes " + (f.start + 1) + "-" + f.end + " of " + l), 
        h.send(b);
    }
    function n(a, b, c) {
        var d = H[a].remainingChunkIdxs.shift(), e = g(a, d);
        H[a].attemptingResume = !1, H[a].loaded += e.end - e.start, H[a].remainingChunkIdxs.length > 0 ? m(a) : (x(a), 
        l(a, b, c));
    }
    function o(a, b) {
        return 200 !== a.status || !b.success || b.reset;
    }
    function p(a) {
        var b;
        try {
            b = qq.parseJson(a.responseText);
        } catch (c) {
            G("Error when attempting to parse xhr response text (" + c + ")", "error"), b = {};
        }
        return b;
    }
    function q(a) {
        G("Server has ordered chunking effort to be restarted on next attempt for file ID " + a, "error"), 
        K && x(a), H[a].remainingChunkIdxs = [], delete H[a].loaded;
    }
    function r(a) {
        H[a].attemptingResume = !1, G("Server has declared that it cannot handle resume for file ID " + a + " - starting from the first chunk", "error"), 
        D.upload(a, !0);
    }
    function s(a, b, c) {
        var d = D.getName(a);
        E.onAutoRetry(a, d, b, c) || l(a, b, c);
    }
    function t(a, b) {
        var c;
        H[a] && (G("xhr - server response received for " + a), G("responseText = " + b.responseText), 
        c = p(b), o(b, c) ? (c.reset && q(a), H[a].attemptingResume && c.reset ? r(a) : s(a, c, b)) : J ? n(a, c, b) : l(a, c, b));
    }
    function u(a) {
        return {
            partIndex: a.part,
            startByte: a.start + 1,
            endByte: a.end,
            totalParts: a.count
        };
    }
    function v(a, b) {
        return function() {
            4 === b.readyState && t(a, b);
        };
    }
    function w(a, b) {
        var c = D.getUuid(a), d = z(a), e = c + I + b.part, f = E.resume.cookiesExpireIn;
        qq.setCookie(d, e, f);
    }
    function x(a) {
        var b = z(a);
        qq.deleteCookie(b);
    }
    function y(a) {
        var b, c, d, e = qq.getCookie(z(a));
        return e ? (b = e.indexOf(I), c = e.substr(0, b), d = parseInt(e.substr(b + 1, e.length - b), 10), 
        {
            uuid: c,
            part: d
        }) : void 0;
    }
    function z(a) {
        var b, c = D.getName(a), d = D.getSize(a), e = E.chunking.partSize;
        return b = "qqfilechunk" + I + encodeURIComponent(c) + I + d + I + e, void 0 !== L && (b += I + L), 
        b;
    }
    function A() {
        return null === E.resume.id || void 0 === E.resume.id || qq.isFunction(E.resume.id) || qq.isObject(E.resume.id) ? void 0 : E.resume.id;
    }
    function B(a, b) {
        var c, d, e, f = D.getName(a), i = 0;
        if (!H[a].remainingChunkIdxs || 0 === H[a].remainingChunkIdxs.length) for (H[a].remainingChunkIdxs = [], 
        K && !b && (c = y(a), c && (d = g(a, c.part), E.onResume(a, f, u(d)) !== !1 && (i = c.part, 
        H[a].uuid = c.uuid, H[a].loaded = d.start, H[a].attemptingResume = !0, G("Resuming " + f + " at partition index " + i)))), 
        e = h(a) - 1; e >= i; e -= 1) H[a].remainingChunkIdxs.unshift(e);
        m(a);
    }
    function C(a) {
        var b, c, d, e = H[a].file, f = D.getName(a);
        H[a].loaded = 0, b = i(a), b.upload.onprogress = function(b) {
            b.lengthComputable && (H[a].loaded = b.loaded, E.onProgress(a, f, b.loaded, b.total));
        }, b.onreadystatechange = v(a, b), c = E.paramsStore.getParams(a), d = j(c, b, e, a), 
        k(a, b), G("Sending upload request for " + a), b.send(d);
    }
    var D, E = a, F = b, G = c, H = [], I = "|", J = E.chunking.enabled && qq.isFileChunkingSupported(), K = E.resume.enabled && J && qq.areCookiesEnabled(), L = A(), M = E.forceMultipart || E.paramsInBody;
    return D = {
        add: function(a) {
            if (!(a instanceof File)) throw new Error("Passed obj in not a File (in qq.UploadHandlerXhr)");
            var b = H.push({
                file: a
            }) - 1;
            return H[b].uuid = qq.getUniqueId(), b;
        },
        getName: function(a) {
            var b = H[a].file;
            return null !== b.fileName && void 0 !== b.fileName ? b.fileName : b.name;
        },
        getSize: function(a) {
            var b = H[a].file;
            return null != b.fileSize ? b.fileSize : b.size;
        },
        getFile: function(a) {
            return H[a] ? H[a].file : void 0;
        },
        getLoaded: function(a) {
            return H[a].loaded || 0;
        },
        isValid: function(a) {
            return void 0 !== H[a];
        },
        reset: function() {
            H = [];
        },
        getUuid: function(a) {
            return H[a].uuid;
        },
        upload: function(a, b) {
            var c = this.getName(a);
            E.onUpload(a, c), J ? B(a, b) : C(a);
        },
        cancel: function(a) {
            E.onCancel(a, this.getName(a)), H[a].xhr && H[a].xhr.abort(), K && x(a), delete H[a];
        },
        getResumableFilesData: function() {
            var a = [], b = [];
            return J && K ? (a = void 0 === L ? qq.getCookieNames(new RegExp("^qqfilechunk\\" + I + ".+\\" + I + "\\d+\\" + I + E.chunking.partSize + "=")) : qq.getCookieNames(new RegExp("^qqfilechunk\\" + I + ".+\\" + I + "\\d+\\" + I + E.chunking.partSize + "\\" + I + L + "=")), 
            qq.each(a, function(a, c) {
                var d = c.split(I), e = qq.getCookie(c).split(I);
                b.push({
                    name: decodeURIComponent(d[1]),
                    size: d[2],
                    uuid: e[0],
                    partIdx: e[1]
                });
            }), b) : [];
        }
    };
}, function(a) {
    "use strict";
    var b, c, d, e, f, g, h, i, j, k;
    g = [ "uploaderType" ], d = function(a) {
        if (a) {
            var d = i(a);
            h(d), b("basic" === f("uploaderType") ? new qq.FineUploaderBasic(d) : new qq.FineUploader(d));
        }
        return c;
    }, e = function(a, b) {
        var d = c.data("fineuploader");
        return b ? (void 0 === d && (d = {}), d[a] = b, c.data("fineuploader", d), void 0) : void 0 === d ? null : d[a];
    }, b = function(a) {
        return e("uploader", a);
    }, f = function(a, b) {
        return e(a, b);
    }, h = function(b) {
        var d = b.callbacks = {};
        a.each(new qq.FineUploaderBasic()._options.callbacks, function(a, b) {
            var e, f;
            e = /^on(\w+)/.exec(a)[1], e = e.substring(0, 1).toLowerCase() + e.substring(1), 
            f = c, d[a] = function() {
                var a = Array.prototype.slice.call(arguments);
                return f.triggerHandler(e, a);
            };
        });
    }, i = function(b, d) {
        var e, h;
        return e = void 0 === d ? "basic" !== b.uploaderType ? {
            element: c[0]
        } : {} : d, a.each(b, function(b, c) {
            a.inArray(b, g) >= 0 ? f(b, c) : c instanceof a ? e[b] = c[0] : a.isPlainObject(c) ? (e[b] = {}, 
            i(c, e[b])) : a.isArray(c) ? (h = [], a.each(c, function(b, c) {
                c instanceof a ? a.merge(h, c) : h.push(c);
            }), e[b] = h) : e[b] = c;
        }), void 0 === d ? e : void 0;
    }, j = function(c) {
        return "string" === a.type(c) && !c.match(/^_/) && void 0 !== b()[c];
    }, k = function(a) {
        var c = [], d = Array.prototype.slice.call(arguments, 1);
        return i(d, c), b()[a].apply(b(), c);
    }, a.fn.fineUploader = function(e) {
        var f = this, g = arguments, h = [];
        return this.each(function(i, l) {
            if (c = a(l), b() && j(e)) {
                if (h.push(k.apply(f, g)), 1 === f.length) return !1;
            } else "object" != typeof e && e ? a.error("Method " + e + " does not exist on jQuery.fineUploader") : d.apply(f, g);
        }), 1 === h.length ? h[0] : h.length > 1 ? h : this;
    };
}(jQuery), function(a) {
    a.fn.validationEngineLanguage = function() {}, a.validationEngineLanguage = {
        newLang: function() {
            a.validationEngineLanguage.allRules = {
                required: {
                    regex: "none",
                    alertText: "* This field is required",
                    alertTextCheckboxMultiple: "* Please select an option",
                    alertTextCheckboxe: "* This checkbox is required",
                    alertTextDateRange: "* Both date range fields are required"
                },
                requiredInFunction: {
                    func: function(a, b, c, d) {
                        return "test" == a.val() ? !0 : !1;
                    },
                    alertText: "* Field must equal test"
                },
                dateRange: {
                    regex: "none",
                    alertText: "* Invalid ",
                    alertText2: "Date Range"
                },
                dateTimeRange: {
                    regex: "none",
                    alertText: "* Invalid ",
                    alertText2: "Date Time Range"
                },
                minSize: {
                    regex: "none",
                    alertText: "* Minimum ",
                    alertText2: " characters allowed"
                },
                maxSize: {
                    regex: "none",
                    alertText: "* Maximum ",
                    alertText2: " characters allowed"
                },
                groupRequired: {
                    regex: "none",
                    alertText: "* You must fill one of the following fields"
                },
                min: {
                    regex: "none",
                    alertText: "* Minimum value is "
                },
                max: {
                    regex: "none",
                    alertText: "* Maximum value is "
                },
                past: {
                    regex: "none",
                    alertText: "* Date prior to "
                },
                future: {
                    regex: "none",
                    alertText: "* Date past "
                },
                maxCheckbox: {
                    regex: "none",
                    alertText: "* Maximum ",
                    alertText2: " options allowed"
                },
                minCheckbox: {
                    regex: "none",
                    alertText: "* Please select ",
                    alertText2: " options"
                },
                equals: {
                    regex: "none",
                    alertText: "* Fields do not match"
                },
                creditCard: {
                    regex: "none",
                    alertText: "* Invalid credit card number"
                },
                phone: {
                    regex: /^([\+][0-9]{1,3}[\ \.\-])?([\(]{1}[0-9]{2,6}[\)])?([0-9\ \.\-\/]{3,20})((x|ext|extension)[\ ]?[0-9]{1,4})?$/,
                    alertText: "* Invalid phone number"
                },
                email: {
                    regex: /^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/,
                    alertText: "* Invalid email address"
                },
                integer: {
                    regex: /^[\-\+]?\d+$/,
                    alertText: "* Not a valid integer"
                },
                number: {
                    regex: /^[\-\+]?((([0-9]{1,3})([,][0-9]{3})*)|([0-9]+))?([\.]([0-9]+))?$/,
                    alertText: "* Invalid floating decimal number"
                },
                date: {
                    func: function(a) {
                        var b = new RegExp(/^(\d{4})[\/\-\.](0?[1-9]|1[012])[\/\-\.](0?[1-9]|[12][0-9]|3[01])$/), c = b.exec(a.val());
                        if (null == c) return !1;
                        var d = c[1], e = 1 * c[2], f = 1 * c[3], g = new Date(d, e - 1, f);
                        return g.getFullYear() == d && g.getMonth() == e - 1 && g.getDate() == f;
                    },
                    alertText: "* Invalid date, must be in YYYY-MM-DD format"
                },
                ipv4: {
                    regex: /^((([01]?[0-9]{1,2})|(2[0-4][0-9])|(25[0-5]))[.]){3}(([0-1]?[0-9]{1,2})|(2[0-4][0-9])|(25[0-5]))$/,
                    alertText: "* Invalid IP address"
                },
                url: {
                    regex: /^(https?|ftp):\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,
                    alertText: "* Invalid URL"
                },
                onlyNumberSp: {
                    regex: /^[0-9\ ]+$/,
                    alertText: "* Numbers only"
                },
                onlyLetterSp: {
                    regex: /^[a-zA-Z\ \']+$/,
                    alertText: "* Letters only"
                },
                onlyLetterNumber: {
                    regex: /^[0-9a-zA-Z]+$/,
                    alertText: "* No special characters allowed"
                },
                ajaxUserCall: {
                    url: "ajaxValidateFieldUser",
                    extraData: "name=eric",
                    alertText: "* This user is already taken",
                    alertTextLoad: "* Validating, please wait"
                },
                ajaxUserCallPhp: {
                    url: "phpajax/ajaxValidateFieldUser.php",
                    extraData: "name=eric",
                    alertTextOk: "* This username is available",
                    alertText: "* This user is already taken",
                    alertTextLoad: "* Validating, please wait"
                },
                ajaxNameCall: {
                    url: "ajaxValidateFieldName",
                    alertText: "* This name is already taken",
                    alertTextOk: "* This name is available",
                    alertTextLoad: "* Validating, please wait"
                },
                ajaxNameCallPhp: {
                    url: "phpajax/ajaxValidateFieldName.php",
                    alertText: "* This name is already taken",
                    alertTextLoad: "* Validating, please wait"
                },
                validate2fields: {
                    alertText: "* Please input HELLO"
                },
                dateFormat: {
                    regex: /^\d{4}[\/\-](0?[1-9]|1[012])[\/\-](0?[1-9]|[12][0-9]|3[01])$|^(?:(?:(?:0?[13578]|1[02])(\/|-)31)|(?:(?:0?[1,3-9]|1[0-2])(\/|-)(?:29|30)))(\/|-)(?:[1-9]\d\d\d|\d[1-9]\d\d|\d\d[1-9]\d|\d\d\d[1-9])$|^(?:(?:0?[1-9]|1[0-2])(\/|-)(?:0?[1-9]|1\d|2[0-8]))(\/|-)(?:[1-9]\d\d\d|\d[1-9]\d\d|\d\d[1-9]\d|\d\d\d[1-9])$|^(0?2(\/|-)29)(\/|-)(?:(?:0[48]00|[13579][26]00|[2468][048]00)|(?:\d\d)?(?:0[48]|[2468][048]|[13579][26]))$/,
                    alertText: "* Invalid Date"
                },
                dateTimeFormat: {
                    regex: /^\d{4}[\/\-](0?[1-9]|1[012])[\/\-](0?[1-9]|[12][0-9]|3[01])\s+(1[012]|0?[1-9]){1}:(0?[1-5]|[0-6][0-9]){1}:(0?[0-6]|[0-6][0-9]){1}\s+(am|pm|AM|PM){1}$|^(?:(?:(?:0?[13578]|1[02])(\/|-)31)|(?:(?:0?[1,3-9]|1[0-2])(\/|-)(?:29|30)))(\/|-)(?:[1-9]\d\d\d|\d[1-9]\d\d|\d\d[1-9]\d|\d\d\d[1-9])$|^((1[012]|0?[1-9]){1}\/(0?[1-9]|[12][0-9]|3[01]){1}\/\d{2,4}\s+(1[012]|0?[1-9]){1}:(0?[1-5]|[0-6][0-9]){1}:(0?[0-6]|[0-6][0-9]){1}\s+(am|pm|AM|PM){1})$/,
                    alertText: "* Invalid Date or Date Format",
                    alertText2: "Expected Format: ",
                    alertText3: "mm/dd/yyyy hh:mm:ss AM|PM or ",
                    alertText4: "yyyy-mm-dd hh:mm:ss AM|PM"
                }
            };
        }
    }, a.validationEngineLanguage.newLang();
}(jQuery), function(a) {
    "use strict";
    var b = {
        init: function(c) {
            var d = this;
            return d.data("jqv") && null != d.data("jqv") || (c = b._saveOptions(d, c), a(".formError").on("click", function() {
                a(this).fadeOut(150, function() {
                    a(this).parent(".formErrorOuter").remove(), a(this).remove();
                });
            })), this;
        },
        attach: function(c) {
            var d, e = this;
            return d = c ? b._saveOptions(e, c) : e.data("jqv"), d.validateAttribute = e.find("[data-validation-engine*=validate]").length ? "data-validation-engine" : "class", 
            d.binded && (e.on(d.validationEventTrigger, "[" + d.validateAttribute + "*=validate]:not([type=checkbox]):not([type=radio]):not(.datepicker)", b._onFieldEvent), 
            e.on("click", "[" + d.validateAttribute + "*=validate][type=checkbox],[" + d.validateAttribute + "*=validate][type=radio]", b._onFieldEvent), 
            e.on(d.validationEventTrigger, "[" + d.validateAttribute + "*=validate][class*=datepicker]", {
                delay: 300
            }, b._onFieldEvent)), d.autoPositionUpdate && a(window).bind("resize", {
                noAnimation: !0,
                formElem: e
            }, b.updatePromptsPosition), e.on("click", "a[data-validation-engine-skip], a[class*='validate-skip'], button[data-validation-engine-skip], button[class*='validate-skip'], input[data-validation-engine-skip], input[class*='validate-skip']", b._submitButtonClick), 
            e.removeData("jqv_submitButton"), e.on("submit", b._onSubmitEvent), this;
        },
        detach: function() {
            var c = this, d = c.data("jqv");
            return c.find("[" + d.validateAttribute + "*=validate]").not("[type=checkbox]").off(d.validationEventTrigger, b._onFieldEvent), 
            c.find("[" + d.validateAttribute + "*=validate][type=checkbox],[class*=validate][type=radio]").off("click", b._onFieldEvent), 
            c.off("submit", b.onAjaxFormComplete), c.die("submit", b.onAjaxFormComplete), c.removeData("jqv"), 
            c.off("click", "a[data-validation-engine-skip], a[class*='validate-skip'], button[data-validation-engine-skip], button[class*='validate-skip'], input[data-validation-engine-skip], input[class*='validate-skip']", b._submitButtonClick), 
            c.removeData("jqv_submitButton"), d.autoPositionUpdate && a(window).unbind("resize", b.updatePromptsPosition), 
            this;
        },
        validate: function() {
            var c = a(this), d = null;
            if (!c.is("form") && !c.hasClass("validationEngineContainer") || c.hasClass("validating")) if (c.is("form") || c.hasClass("validationEngineContainer")) c.removeClass("validating"); else {
                var e = c.closest("form, .validationEngineContainer"), f = e.data("jqv") ? e.data("jqv") : a.validationEngine.defaults, d = b._validateField(c, f);
                d && f.onFieldSuccess ? f.onFieldSuccess() : f.onFieldFailure && f.InvalidFields.length > 0 && f.onFieldFailure();
            } else {
                c.addClass("validating");
                var f = c.data("jqv"), d = b._validateFields(this);
                setTimeout(function() {
                    c.removeClass("validating");
                }, 100), d && f.onSuccess ? f.onSuccess() : !d && f.onFailure && f.onFailure();
            }
            return f.onValidationComplete ? !!f.onValidationComplete(e, d) : d;
        },
        updatePromptsPosition: function(c) {
            if (c && this == window) var d = c.data.formElem, e = c.data.noAnimation; else var d = a(this.closest("form, .validationEngineContainer"));
            var f = d.data("jqv");
            return d.find("[" + f.validateAttribute + "*=validate]").not(":disabled").each(function() {
                var c = a(this);
                f.prettySelect && c.is(":hidden") && (c = d.find("#" + f.usePrefix + c.attr("id") + f.useSuffix));
                var g = b._getPrompt(c), h = a(g).find(".formErrorContent").html();
                g && b._updatePrompt(c, a(g), h, void 0, !1, f, e);
            }), this;
        },
        showPrompt: function(a, c, d, e) {
            var f = this.closest("form, .validationEngineContainer"), g = f.data("jqv");
            return g || (g = b._saveOptions(this, g)), d && (g.promptPosition = d), g.showArrow = 1 == e, 
            b._showPrompt(this, a, c, !1, g), this;
        },
        hide: function() {
            var c, d = a(this).closest("form, .validationEngineContainer"), e = d.data("jqv"), f = e && e.fadeDuration ? e.fadeDuration : .3;
            return c = a(this).is("form") || a(this).hasClass("validationEngineContainer") ? "parentForm" + b._getClassName(a(this).attr("id")) : b._getClassName(a(this).attr("id")) + "formError", 
            a("." + c).fadeTo(f, .3, function() {
                a(this).parent(".formErrorOuter").remove(), a(this).remove();
            }), this;
        },
        hideAll: function() {
            var b = this, c = b.data("jqv"), d = c ? c.fadeDuration : .3;
            return a(".formError").fadeTo(d, .3, function() {
                a(this).parent(".formErrorOuter").remove(), a(this).remove();
            }), this;
        },
        _onFieldEvent: function(c) {
            var d = a(this), e = d.closest("form, .validationEngineContainer"), f = e.data("jqv");
            f.eventTrigger = "field", window.setTimeout(function() {
                b._validateField(d, f), 0 == f.InvalidFields.length && f.onFieldSuccess ? f.onFieldSuccess() : f.InvalidFields.length > 0 && f.onFieldFailure && f.onFieldFailure();
            }, c.data ? c.data.delay : 0);
        },
        _onSubmitEvent: function() {
            var c = a(this), d = c.data("jqv");
            if (c.data("jqv_submitButton")) {
                var e = a("#" + c.data("jqv_submitButton"));
                if (e && e.length > 0 && (e.hasClass("validate-skip") || "true" == e.attr("data-validation-engine-skip"))) return !0;
            }
            d.eventTrigger = "submit";
            var f = b._validateFields(c);
            return f && d.ajaxFormValidation ? (b._validateFormWithAjax(c, d), !1) : d.onValidationComplete ? !!d.onValidationComplete(c, f) : f;
        },
        _checkAjaxStatus: function(b) {
            var c = !0;
            return a.each(b.ajaxValidCache, function(a, b) {
                return b ? void 0 : (c = !1, !1);
            }), c;
        },
        _checkAjaxFieldStatus: function(a, b) {
            return 1 == b.ajaxValidCache[a];
        },
        _validateFields: function(c) {
            var d = c.data("jqv"), e = !1;
            c.trigger("jqv.form.validating");
            var f = null;
            if (c.find("[" + d.validateAttribute + "*=validate]").not(":disabled").each(function() {
                var g = a(this), h = [];
                if (a.inArray(g.attr("name"), h) < 0) {
                    if (e |= b._validateField(g, d), e && null == f && (f = g.is(":hidden") && d.prettySelect ? g = c.find("#" + d.usePrefix + b._jqSelector(g.attr("id")) + d.useSuffix) : g), 
                    d.doNotShowAllErrosOnSubmit) return !1;
                    if (h.push(g.attr("name")), 1 == d.showOneMessage && e) return !1;
                }
            }), c.trigger("jqv.form.result", [ e ]), e) {
                if (d.scroll) {
                    var g = f.offset().top, h = f.offset().left, i = d.promptPosition;
                    if ("string" == typeof i && -1 != i.indexOf(":") && (i = i.substring(0, i.indexOf(":"))), 
                    "bottomRight" != i && "bottomLeft" != i) {
                        var j = b._getPrompt(f);
                        j && (g = j.offset().top);
                    }
                    if (d.scrollOffset && (g -= d.scrollOffset), d.isOverflown) {
                        var k = a(d.overflownDIV);
                        if (!k.length) return !1;
                        var l = k.scrollTop(), m = -parseInt(k.offset().top);
                        g += l + m - 5;
                        var n = a(d.overflownDIV + ":not(:animated)");
                        n.animate({
                            scrollTop: g
                        }, 1100, function() {
                            d.focusFirstField && f.focus();
                        });
                    } else a("html, body").animate({
                        scrollTop: g
                    }, 1100, function() {
                        d.focusFirstField && f.focus();
                    }), a("html, body").animate({
                        scrollLeft: h
                    }, 1100);
                } else d.focusFirstField && f.focus();
                return !1;
            }
            return !0;
        },
        _validateFormWithAjax: function(c, d) {
            var e = c.serialize(), f = d.ajaxFormValidationMethod ? d.ajaxFormValidationMethod : "GET", g = d.ajaxFormValidationURL ? d.ajaxFormValidationURL : c.attr("action"), h = d.dataType ? d.dataType : "json";
            a.ajax({
                type: f,
                url: g,
                cache: !1,
                dataType: h,
                data: e,
                form: c,
                methods: b,
                options: d,
                beforeSend: function() {
                    return d.onBeforeAjaxFormValidation(c, d);
                },
                error: function(a, c) {
                    b._ajaxError(a, c);
                },
                success: function(e) {
                    if ("json" == h && e !== !0) {
                        for (var f = !1, g = 0; g < e.length; g++) {
                            var i = e[g], j = i[0], k = a(a("#" + j)[0]);
                            if (1 == k.length) {
                                var l = i[2];
                                if (1 == i[1]) if ("" != l && l) {
                                    if (d.allrules[l]) {
                                        var m = d.allrules[l].alertTextOk;
                                        m && (l = m);
                                    }
                                    d.showPrompts && b._showPrompt(k, l, "pass", !1, d, !0);
                                } else b._closePrompt(k); else {
                                    if (f |= !0, d.allrules[l]) {
                                        var m = d.allrules[l].alertText;
                                        m && (l = m);
                                    }
                                    d.showPrompts && b._showPrompt(k, l, "", !1, d, !0);
                                }
                            }
                        }
                        d.onAjaxFormComplete(!f, c, e, d);
                    } else d.onAjaxFormComplete(!0, c, e, d);
                }
            });
        },
        _validateField: function(c, d, e) {
            if (c.attr("id") || (c.attr("id", "form-validation-field-" + a.validationEngine.fieldIdCounter), 
            ++a.validationEngine.fieldIdCounter), c.is(":hidden") && !d.prettySelect || c.parent().is(":hidden")) return !1;
            var f = c.attr(d.validateAttribute), g = /validate\[(.*)\]/.exec(f);
            if (!g) return !1;
            var h = g[1], i = h.split(/\[|,|\]/), j = !1, k = c.attr("name"), l = "", m = "", n = !1, o = !1;
            d.isError = !1, d.showArrow = !0, d.maxErrorsPerField > 0 && (o = !0);
            for (var p = a(c.closest("form, .validationEngineContainer")), q = 0; q < i.length; q++) i[q] = i[q].replace(" ", ""), 
            "" === i[q] && delete i[q];
            for (var q = 0, r = 0; q < i.length; q++) {
                if (o && r >= d.maxErrorsPerField) {
                    if (!n) {
                        var s = a.inArray("required", i);
                        n = -1 != s && s >= q;
                    }
                    break;
                }
                var t = void 0;
                switch (i[q]) {
                  case "required":
                    n = !0, t = b._getErrorMessage(p, c, i[q], i, q, d, b._required);
                    break;

                  case "custom":
                    t = b._getErrorMessage(p, c, i[q], i, q, d, b._custom);
                    break;

                  case "groupRequired":
                    var u = "[" + d.validateAttribute + "*=" + i[q + 1] + "]", v = p.find(u).eq(0);
                    v[0] != c[0] && (b._validateField(v, d, e), d.showArrow = !0), t = b._getErrorMessage(p, c, i[q], i, q, d, b._groupRequired), 
                    t && (n = !0), d.showArrow = !1;
                    break;

                  case "ajax":
                    t = b._ajax(c, i, q, d), t && (m = "load");
                    break;

                  case "minSize":
                    t = b._getErrorMessage(p, c, i[q], i, q, d, b._minSize);
                    break;

                  case "maxSize":
                    t = b._getErrorMessage(p, c, i[q], i, q, d, b._maxSize);
                    break;

                  case "min":
                    t = b._getErrorMessage(p, c, i[q], i, q, d, b._min);
                    break;

                  case "max":
                    t = b._getErrorMessage(p, c, i[q], i, q, d, b._max);
                    break;

                  case "past":
                    t = b._getErrorMessage(p, c, i[q], i, q, d, b._past);
                    break;

                  case "future":
                    t = b._getErrorMessage(p, c, i[q], i, q, d, b._future);
                    break;

                  case "dateRange":
                    var u = "[" + d.validateAttribute + "*=" + i[q + 1] + "]";
                    d.firstOfGroup = p.find(u).eq(0), d.secondOfGroup = p.find(u).eq(1), (d.firstOfGroup[0].value || d.secondOfGroup[0].value) && (t = b._getErrorMessage(p, c, i[q], i, q, d, b._dateRange)), 
                    t && (n = !0), d.showArrow = !1;
                    break;

                  case "dateTimeRange":
                    var u = "[" + d.validateAttribute + "*=" + i[q + 1] + "]";
                    d.firstOfGroup = p.find(u).eq(0), d.secondOfGroup = p.find(u).eq(1), (d.firstOfGroup[0].value || d.secondOfGroup[0].value) && (t = b._getErrorMessage(p, c, i[q], i, q, d, b._dateTimeRange)), 
                    t && (n = !0), d.showArrow = !1;
                    break;

                  case "maxCheckbox":
                    c = a(p.find("input[name='" + k + "']")), t = b._getErrorMessage(p, c, i[q], i, q, d, b._maxCheckbox);
                    break;

                  case "minCheckbox":
                    c = a(p.find("input[name='" + k + "']")), t = b._getErrorMessage(p, c, i[q], i, q, d, b._minCheckbox);
                    break;

                  case "equals":
                    t = b._getErrorMessage(p, c, i[q], i, q, d, b._equals);
                    break;

                  case "funcCall":
                    t = b._getErrorMessage(p, c, i[q], i, q, d, b._funcCall);
                    break;

                  case "creditCard":
                    t = b._getErrorMessage(p, c, i[q], i, q, d, b._creditCard);
                    break;

                  case "condRequired":
                    t = b._getErrorMessage(p, c, i[q], i, q, d, b._condRequired), void 0 !== t && (n = !0);
                }
                var w = !1;
                if ("object" == typeof t) switch (t.status) {
                  case "_break":
                    w = !0;
                    break;

                  case "_error":
                    t = t.message;
                    break;

                  case "_error_no_prompt":
                    return !0;
                }
                if (w) break;
                "string" == typeof t && (l += t + "<br/>", d.isError = !0, r++);
            }
            !n && !c.val() && c.val().length < 1 && (d.isError = !1);
            var x = c.prop("type"), y = c.data("promptPosition") || d.promptPosition;
            ("radio" == x || "checkbox" == x) && p.find("input[name='" + k + "']").size() > 1 && (c = a("inline" === y ? p.find("input[name='" + k + "'][type!=hidden]:last") : p.find("input[name='" + k + "'][type!=hidden]:first")), 
            d.showArrow = !1), c.is(":hidden") && d.prettySelect && (c = p.find("#" + d.usePrefix + b._jqSelector(c.attr("id")) + d.useSuffix)), 
            d.isError && d.showPrompts ? b._showPrompt(c, l, m, !1, d) : j || b._closePrompt(c), 
            j || c.trigger("jqv.field.result", [ c, d.isError, l ]);
            var z = a.inArray(c[0], d.InvalidFields);
            return -1 == z ? d.isError && d.InvalidFields.push(c[0]) : d.isError || d.InvalidFields.splice(z, 1), 
            b._handleStatusCssClasses(c, d), d.isError && d.onFieldFailure && d.onFieldFailure(c), 
            !d.isError && d.onFieldSuccess && d.onFieldSuccess(c), d.isError;
        },
        _handleStatusCssClasses: function(a, b) {
            b.addSuccessCssClassToField && a.removeClass(b.addSuccessCssClassToField), b.addFailureCssClassToField && a.removeClass(b.addFailureCssClassToField), 
            b.addSuccessCssClassToField && !b.isError && a.addClass(b.addSuccessCssClassToField), 
            b.addFailureCssClassToField && b.isError && a.addClass(b.addFailureCssClassToField);
        },
        _getErrorMessage: function(c, d, e, f, g, h, i) {
            var j = jQuery.inArray(e, f);
            if ("custom" === e || "funcCall" === e) {
                var k = f[j + 1];
                e = e + "[" + k + "]", delete f[j];
            }
            var l, m = e, n = d.attr("data-validation-engine") ? d.attr("data-validation-engine") : d.attr("class"), o = n.split(" ");
            if (l = "future" == e || "past" == e || "maxCheckbox" == e || "minCheckbox" == e ? i(c, d, f, g, h) : i(d, f, g, h), 
            void 0 != l) {
                var p = b._getCustomErrorMessage(a(d), o, m, h);
                p && (l = p);
            }
            return l;
        },
        _getCustomErrorMessage: function(a, c, d, e) {
            var f = !1, g = b._validityProp[d];
            if (void 0 != g && (f = a.attr("data-errormessage-" + g), void 0 != f)) return f;
            if (f = a.attr("data-errormessage"), void 0 != f) return f;
            var h = "#" + a.attr("id");
            if ("undefined" != typeof e.custom_error_messages[h] && "undefined" != typeof e.custom_error_messages[h][d]) f = e.custom_error_messages[h][d].message; else if (c.length > 0) for (var i = 0; i < c.length && c.length > 0; i++) {
                var j = "." + c[i];
                if ("undefined" != typeof e.custom_error_messages[j] && "undefined" != typeof e.custom_error_messages[j][d]) {
                    f = e.custom_error_messages[j][d].message;
                    break;
                }
            }
            return f || "undefined" == typeof e.custom_error_messages[d] || "undefined" == typeof e.custom_error_messages[d].message || (f = e.custom_error_messages[d].message), 
            f;
        },
        _validityProp: {
            required: "value-missing",
            custom: "custom-error",
            groupRequired: "value-missing",
            ajax: "custom-error",
            minSize: "range-underflow",
            maxSize: "range-overflow",
            min: "range-underflow",
            max: "range-overflow",
            past: "type-mismatch",
            future: "type-mismatch",
            dateRange: "type-mismatch",
            dateTimeRange: "type-mismatch",
            maxCheckbox: "range-overflow",
            minCheckbox: "range-underflow",
            equals: "pattern-mismatch",
            funcCall: "custom-error",
            creditCard: "pattern-mismatch",
            condRequired: "value-missing"
        },
        _required: function(b, c, d, e, f) {
            switch (b.prop("type")) {
              case "text":
              case "password":
              case "textarea":
              case "file":
              case "select-one":
              case "select-multiple":
              default:
                if (!a.trim(b.val()) && (b.val() != b.attr("data-validation-placeholder") || b.val() !== b.attr("placeholder"))) return e.allrules[c[d]].alertText;
                break;

              case "radio":
              case "checkbox":
                if (f) {
                    if (!b.attr("checked")) return e.allrules[c[d]].alertTextCheckboxMultiple;
                    break;
                }
                var g = b.closest("form, .validationEngineContainer"), h = b.attr("name");
                if (0 == g.find("input[name='" + h + "']:checked").size()) return 1 == g.find("input[name='" + h + "']:visible").size() ? e.allrules[c[d]].alertTextCheckboxe : e.allrules[c[d]].alertTextCheckboxMultiple;
            }
        },
        _groupRequired: function(c, d, e, f) {
            var g = "[" + f.validateAttribute + "*=" + d[e + 1] + "]", h = !1;
            return c.closest("form, .validationEngineContainer").find(g).each(function() {
                return b._required(a(this), d, e, f) ? void 0 : (h = !0, !1);
            }), h ? void 0 : f.allrules[d[e]].alertText;
        },
        _custom: function(a, b, c, d) {
            var e, f = b[c + 1], g = d.allrules[f];
            if (!g) return void alert("jqv:custom rule not found - " + f);
            if (g.regex) {
                var h = g.regex;
                if (!h) return void alert("jqv:custom regex not found - " + f);
                var i = new RegExp(h);
                if (!i.test(a.val())) return d.allrules[f].alertText;
            } else {
                if (!g.func) return void alert("jqv:custom type not allowed " + f);
                if (e = g.func, "function" != typeof e) return void alert("jqv:custom parameter 'function' is no function - " + f);
                if (!e(a, b, c, d)) return d.allrules[f].alertText;
            }
        },
        _funcCall: function(a, b, c, d) {
            var e, f = b[c + 1];
            if (f.indexOf(".") > -1) {
                for (var g = f.split("."), h = window; g.length; ) h = h[g.shift()];
                e = h;
            } else e = window[f] || d.customFunctions[f];
            return "function" == typeof e ? e(a, b, c, d) : void 0;
        },
        _equals: function(b, c, d, e) {
            var f = c[d + 1];
            return b.val() != a("#" + f).val() ? e.allrules.equals.alertText : void 0;
        },
        _maxSize: function(a, b, c, d) {
            var e = b[c + 1], f = a.val().length;
            if (f > e) {
                var g = d.allrules.maxSize;
                return g.alertText + e + g.alertText2;
            }
        },
        _minSize: function(a, b, c, d) {
            var e = b[c + 1], f = a.val().length;
            if (e > f) {
                var g = d.allrules.minSize;
                return g.alertText + e + g.alertText2;
            }
        },
        _min: function(a, b, c, d) {
            var e = parseFloat(b[c + 1]), f = parseFloat(a.val());
            if (e > f) {
                var g = d.allrules.min;
                return g.alertText2 ? g.alertText + e + g.alertText2 : g.alertText + e;
            }
        },
        _max: function(a, b, c, d) {
            var e = parseFloat(b[c + 1]), f = parseFloat(a.val());
            if (f > e) {
                var g = d.allrules.max;
                return g.alertText2 ? g.alertText + e + g.alertText2 : g.alertText + e;
            }
        },
        _past: function(c, d, e, f, g) {
            var h, i = e[f + 1], j = a(c.find("input[name='" + i.replace(/^#+/, "") + "']"));
            if ("now" == i.toLowerCase()) h = new Date(); else if (void 0 != j.val()) {
                if (j.is(":disabled")) return;
                h = b._parseDate(j.val());
            } else h = b._parseDate(i);
            var k = b._parseDate(d.val());
            if (k > h) {
                var l = g.allrules.past;
                return l.alertText2 ? l.alertText + b._dateToString(h) + l.alertText2 : l.alertText + b._dateToString(h);
            }
        },
        _future: function(c, d, e, f, g) {
            var h, i = e[f + 1], j = a(c.find("input[name='" + i.replace(/^#+/, "") + "']"));
            if ("now" == i.toLowerCase()) h = new Date(); else if (void 0 != j.val()) {
                if (j.is(":disabled")) return;
                h = b._parseDate(j.val());
            } else h = b._parseDate(i);
            var k = b._parseDate(d.val());
            if (h > k) {
                var l = g.allrules.future;
                return l.alertText2 ? l.alertText + b._dateToString(h) + l.alertText2 : l.alertText + b._dateToString(h);
            }
        },
        _isDate: function(a) {
            var b = new RegExp(/^\d{4}[\/\-](0?[1-9]|1[012])[\/\-](0?[1-9]|[12][0-9]|3[01])$|^(?:(?:(?:0?[13578]|1[02])(\/|-)31)|(?:(?:0?[1,3-9]|1[0-2])(\/|-)(?:29|30)))(\/|-)(?:[1-9]\d\d\d|\d[1-9]\d\d|\d\d[1-9]\d|\d\d\d[1-9])$|^(?:(?:0?[1-9]|1[0-2])(\/|-)(?:0?[1-9]|1\d|2[0-8]))(\/|-)(?:[1-9]\d\d\d|\d[1-9]\d\d|\d\d[1-9]\d|\d\d\d[1-9])$|^(0?2(\/|-)29)(\/|-)(?:(?:0[48]00|[13579][26]00|[2468][048]00)|(?:\d\d)?(?:0[48]|[2468][048]|[13579][26]))$/);
            return b.test(a);
        },
        _isDateTime: function(a) {
            var b = new RegExp(/^\d{4}[\/\-](0?[1-9]|1[012])[\/\-](0?[1-9]|[12][0-9]|3[01])\s+(1[012]|0?[1-9]){1}:(0?[1-5]|[0-6][0-9]){1}:(0?[0-6]|[0-6][0-9]){1}\s+(am|pm|AM|PM){1}$|^(?:(?:(?:0?[13578]|1[02])(\/|-)31)|(?:(?:0?[1,3-9]|1[0-2])(\/|-)(?:29|30)))(\/|-)(?:[1-9]\d\d\d|\d[1-9]\d\d|\d\d[1-9]\d|\d\d\d[1-9])$|^((1[012]|0?[1-9]){1}\/(0?[1-9]|[12][0-9]|3[01]){1}\/\d{2,4}\s+(1[012]|0?[1-9]){1}:(0?[1-5]|[0-6][0-9]){1}:(0?[0-6]|[0-6][0-9]){1}\s+(am|pm|AM|PM){1})$/);
            return b.test(a);
        },
        _dateCompare: function(a, b) {
            return new Date(a.toString()) < new Date(b.toString());
        },
        _dateRange: function(a, c, d, e) {
            return !e.firstOfGroup[0].value && e.secondOfGroup[0].value || e.firstOfGroup[0].value && !e.secondOfGroup[0].value ? e.allrules[c[d]].alertText + e.allrules[c[d]].alertText2 : b._isDate(e.firstOfGroup[0].value) && b._isDate(e.secondOfGroup[0].value) && b._dateCompare(e.firstOfGroup[0].value, e.secondOfGroup[0].value) ? void 0 : e.allrules[c[d]].alertText + e.allrules[c[d]].alertText2;
        },
        _dateTimeRange: function(a, c, d, e) {
            return !e.firstOfGroup[0].value && e.secondOfGroup[0].value || e.firstOfGroup[0].value && !e.secondOfGroup[0].value ? e.allrules[c[d]].alertText + e.allrules[c[d]].alertText2 : b._isDateTime(e.firstOfGroup[0].value) && b._isDateTime(e.secondOfGroup[0].value) && b._dateCompare(e.firstOfGroup[0].value, e.secondOfGroup[0].value) ? void 0 : e.allrules[c[d]].alertText + e.allrules[c[d]].alertText2;
        },
        _maxCheckbox: function(a, b, c, d, e) {
            var f = c[d + 1], g = b.attr("name"), h = a.find("input[name='" + g + "']:checked").size();
            return h > f ? (e.showArrow = !1, e.allrules.maxCheckbox.alertText2 ? e.allrules.maxCheckbox.alertText + " " + f + " " + e.allrules.maxCheckbox.alertText2 : e.allrules.maxCheckbox.alertText) : void 0;
        },
        _minCheckbox: function(a, b, c, d, e) {
            var f = c[d + 1], g = b.attr("name"), h = a.find("input[name='" + g + "']:checked").size();
            return f > h ? (e.showArrow = !1, e.allrules.minCheckbox.alertText + " " + f + " " + e.allrules.minCheckbox.alertText2) : void 0;
        },
        _creditCard: function(a, b, c, d) {
            var e = !1, f = a.val().replace(/ +/g, "").replace(/-+/g, ""), g = f.length;
            if (g >= 14 && 16 >= g && parseInt(f) > 0) {
                var h, i = 0, c = g - 1, j = 1, k = new String();
                do h = parseInt(f.charAt(c)), k += j++ % 2 == 0 ? 2 * h : h; while (--c >= 0);
                for (c = 0; c < k.length; c++) i += parseInt(k.charAt(c));
                e = i % 10 == 0;
            }
            return e ? void 0 : d.allrules.creditCard.alertText;
        },
        _ajax: function(c, d, e, f) {
            var g = d[e + 1], h = f.allrules[g], i = h.extraData, j = h.extraDataDynamic, k = {
                fieldId: c.attr("id"),
                fieldValue: c.val()
            };
            if ("object" == typeof i) a.extend(k, i); else if ("string" == typeof i) for (var l = i.split("&"), e = 0; e < l.length; e++) {
                var m = l[e].split("=");
                m[0] && m[0] && (k[m[0]] = m[1]);
            }
            if (j) for (var n = String(j).split(","), e = 0; e < n.length; e++) {
                var o = n[e];
                if (a(o).length) {
                    var p = c.closest("form, .validationEngineContainer").find(o).val();
                    o.replace("#", "") + "=" + escape(p);
                    k[o.replace("#", "")] = p;
                }
            }
            return "field" == f.eventTrigger && delete f.ajaxValidCache[c.attr("id")], f.isError || b._checkAjaxFieldStatus(c.attr("id"), f) ? void 0 : (a.ajax({
                type: f.ajaxFormValidationMethod,
                url: h.url,
                cache: !1,
                dataType: "json",
                data: k,
                field: c,
                rule: h,
                methods: b,
                options: f,
                beforeSend: function() {},
                error: function(a, c) {
                    b._ajaxError(a, c);
                },
                success: function(d) {
                    var e = d[0], g = a("#" + e).eq(0);
                    if (1 == g.length) {
                        var i = d[1], j = d[2];
                        if (i) {
                            if (f.ajaxValidCache[e] = !0, j) {
                                if (f.allrules[j]) {
                                    var k = f.allrules[j].alertTextOk;
                                    k && (j = k);
                                }
                            } else j = h.alertTextOk;
                            f.showPrompts && (j ? b._showPrompt(g, j, "pass", !0, f) : b._closePrompt(g)), "submit" == f.eventTrigger && c.closest("form").submit();
                        } else {
                            if (f.ajaxValidCache[e] = !1, f.isError = !0, j) {
                                if (f.allrules[j]) {
                                    var k = f.allrules[j].alertText;
                                    k && (j = k);
                                }
                            } else j = h.alertText;
                            f.showPrompts && b._showPrompt(g, j, "", !0, f);
                        }
                    }
                    g.trigger("jqv.field.result", [ g, f.isError, j ]);
                }
            }), h.alertTextLoad);
        },
        _ajaxError: function(a, b) {
            0 == a.status && null == b ? alert("The page is not served from a server! ajax call failed") : "undefined" != typeof console && console.log("Ajax error: " + a.status + " " + b);
        },
        _dateToString: function(a) {
            return a.getFullYear() + "-" + (a.getMonth() + 1) + "-" + a.getDate();
        },
        _parseDate: function(a) {
            var b = a.split("-");
            return b == a && (b = a.split("/")), new Date(b[0], b[1] - 1, b[2]);
        },
        _showPrompt: function(c, d, e, f, g, h) {
            var i = b._getPrompt(c);
            h && (i = !1), a.trim(d) && (i ? b._updatePrompt(c, i, d, e, f, g) : b._buildPrompt(c, d, e, f, g));
        },
        _buildPrompt: function(c, d, e, f, g) {
            var h = a("<div>");
            switch (h.addClass(b._getClassName(c.attr("id")) + "formError"), h.addClass("parentForm" + b._getClassName(c.closest("form, .validationEngineContainer").attr("id"))), 
            h.addClass("formError"), e) {
              case "pass":
                h.addClass("greenPopup");
                break;

              case "load":
                h.addClass("blackPopup");
            }
            f && h.addClass("ajaxed");
            var i = (a("<div>").addClass("formErrorContent").html(d).appendTo(h), c.data("promptPosition") || g.promptPosition);
            if (g.showArrow) {
                var j = a("<div>").addClass("formErrorArrow");
                if ("string" == typeof i) {
                    var k = i.indexOf(":");
                    -1 != k && (i = i.substring(0, k));
                }
                switch (i) {
                  case "bottomLeft":
                  case "bottomRight":
                    h.find(".formErrorContent").before(j), j.addClass("formErrorArrowBottom").html('<div class="line1"><!-- --></div><div class="line2"><!-- --></div><div class="line3"><!-- --></div><div class="line4"><!-- --></div><div class="line5"><!-- --></div><div class="line6"><!-- --></div><div class="line7"><!-- --></div><div class="line8"><!-- --></div><div class="line9"><!-- --></div><div class="line10"><!-- --></div>');
                    break;

                  case "topLeft":
                  case "topRight":
                    j.html('<div class="line10"><!-- --></div><div class="line9"><!-- --></div><div class="line8"><!-- --></div><div class="line7"><!-- --></div><div class="line6"><!-- --></div><div class="line5"><!-- --></div><div class="line4"><!-- --></div><div class="line3"><!-- --></div><div class="line2"><!-- --></div><div class="line1"><!-- --></div>'), 
                    h.append(j);
                }
            }
            g.addPromptClass && h.addClass(g.addPromptClass), h.css({
                opacity: 0
            }), "inline" === i ? (h.addClass("inline"), "undefined" != typeof c.attr("data-prompt-target") && a("#" + c.attr("data-prompt-target")).length > 0 ? h.appendTo(a("#" + c.attr("data-prompt-target"))) : c.after(h)) : c.before(h);
            var k = b._calculatePosition(c, h, g);
            return h.css({
                position: "inline" === i ? "relative" : "absolute",
                top: k.callerTopPosition,
                left: k.callerleftPosition,
                marginTop: k.marginTopSize,
                opacity: 0
            }).data("callerField", c), g.autoHidePrompt && setTimeout(function() {
                h.animate({
                    opacity: 0
                }, function() {
                    h.closest(".formErrorOuter").remove(), h.remove();
                });
            }, g.autoHideDelay), h.animate({
                opacity: .87
            });
        },
        _updatePrompt: function(a, c, d, e, f, g, h) {
            if (c) {
                "undefined" != typeof e && ("pass" == e ? c.addClass("greenPopup") : c.removeClass("greenPopup"), 
                "load" == e ? c.addClass("blackPopup") : c.removeClass("blackPopup")), f ? c.addClass("ajaxed") : c.removeClass("ajaxed"), 
                c.find(".formErrorContent").html(d);
                var i = b._calculatePosition(a, c, g), j = {
                    top: i.callerTopPosition,
                    left: i.callerleftPosition,
                    marginTop: i.marginTopSize
                };
                h ? c.css(j) : c.animate(j);
            }
        },
        _closePrompt: function(a) {
            var c = b._getPrompt(a);
            c && c.fadeTo("fast", 0, function() {
                c.parent(".formErrorOuter").remove(), c.remove();
            });
        },
        closePrompt: function(a) {
            return b._closePrompt(a);
        },
        _getPrompt: function(c) {
            var d = a(c).closest("form, .validationEngineContainer").attr("id"), e = b._getClassName(c.attr("id")) + "formError", f = a("." + b._escapeExpression(e) + ".parentForm" + d)[0];
            return f ? a(f) : void 0;
        },
        _escapeExpression: function(a) {
            return a.replace(/([#;&,\.\+\*\~':"\!\^$\[\]\(\)=>\|])/g, "\\$1");
        },
        isRTL: function(b) {
            var c = a(document), d = a("body"), e = b && b.hasClass("rtl") || b && "rtl" === (b.attr("dir") || "").toLowerCase() || c.hasClass("rtl") || "rtl" === (c.attr("dir") || "").toLowerCase() || d.hasClass("rtl") || "rtl" === (d.attr("dir") || "").toLowerCase();
            return Boolean(e);
        },
        _calculatePosition: function(a, b, c) {
            var d, e, f, g = a.width(), h = a.position().left, i = a.position().top, j = (a.height(), 
            b.height());
            d = e = 0, f = -j;
            var k = a.data("promptPosition") || c.promptPosition, l = "", m = "", n = 0, o = 0;
            switch ("string" == typeof k && -1 != k.indexOf(":") && (l = k.substring(k.indexOf(":") + 1), 
            k = k.substring(0, k.indexOf(":")), -1 != l.indexOf(",") && (m = l.substring(l.indexOf(",") + 1), 
            l = l.substring(0, l.indexOf(",")), o = parseInt(m), isNaN(o) && (o = 0)), n = parseInt(l), 
            isNaN(l) && (l = 0)), k) {
              default:
              case "topRight":
                e += h + g - 30, d += i;
                break;

              case "topLeft":
                d += i, e += h;
                break;

              case "centerRight":
                d = i + 4, f = 0, e = h + a.outerWidth(!0) + 5;
                break;

              case "centerLeft":
                e = h - (b.width() + 2), d = i + 4, f = 0;
                break;

              case "bottomLeft":
                d = i + a.height() + 5, f = 0, e = h;
                break;

              case "bottomRight":
                e = h + g - 30, d = i + a.height() + 5, f = 0;
                break;

              case "inline":
                e = 0, d = 0, f = 0;
            }
            return e += n, d += o, {
                callerTopPosition: d + "px",
                callerleftPosition: e + "px",
                marginTopSize: f + "px"
            };
        },
        _saveOptions: function(b, c) {
            if (a.validationEngineLanguage) var d = a.validationEngineLanguage.allRules; else a.error("jQuery.validationEngine rules are not loaded, plz add localization files to the page");
            a.validationEngine.defaults.allrules = d;
            var e = a.extend(!0, {}, a.validationEngine.defaults, c);
            return b.data("jqv", e), e;
        },
        _getClassName: function(a) {
            return a ? a.replace(/:/g, "_").replace(/\./g, "_") : void 0;
        },
        _jqSelector: function(a) {
            return a.replace(/([;&,\.\+\*\~':"\!\^#$%@\[\]\(\)=>\|])/g, "\\$1");
        },
        _condRequired: function(a, c, d, e) {
            var f, g;
            for (f = d + 1; f < c.length; f++) if (g = jQuery("#" + c[f]).first(), g.length && void 0 == b._required(g, [ "required" ], 0, e, !0)) return b._required(a, [ "required" ], 0, e);
        },
        _submitButtonClick: function(b) {
            var c = a(this), d = c.closest("form, .validationEngineContainer");
            d.data("jqv_submitButton", c.attr("id"));
        }
    };
    a.fn.validationEngine = function(c) {
        var d = a(this);
        return d[0] ? "string" == typeof c && "_" != c.charAt(0) && b[c] ? ("showPrompt" != c && "hide" != c && "hideAll" != c && b.init.apply(d), 
        b[c].apply(d, Array.prototype.slice.call(arguments, 1))) : "object" != typeof c && c ? void a.error("Method " + c + " does not exist in jQuery.validationEngine") : (b.init.apply(d, arguments), 
        b.attach.apply(d)) : d;
    }, a.validationEngine = {
        fieldIdCounter: 0,
        defaults: {
            validationEventTrigger: "blur",
            scroll: !0,
            focusFirstField: !0,
            showPrompts: !0,
            promptPosition: "topRight",
            bindMethod: "bind",
            inlineAjax: !1,
            ajaxFormValidation: !1,
            ajaxFormValidationURL: !1,
            ajaxFormValidationMethod: "get",
            onAjaxFormComplete: a.noop,
            onBeforeAjaxFormValidation: a.noop,
            onValidationComplete: !1,
            doNotShowAllErrosOnSubmit: !1,
            custom_error_messages: {},
            binded: !0,
            showArrow: !0,
            isError: !1,
            maxErrorsPerField: !1,
            ajaxValidCache: {},
            autoPositionUpdate: !1,
            InvalidFields: [],
            onFieldSuccess: !1,
            onFieldFailure: !1,
            onSuccess: !1,
            onFailure: !1,
            validateAttribute: "class",
            addSuccessCssClassToField: !1,
            addFailureCssClassToField: !1,
            autoHidePrompt: !1,
            autoHideDelay: 1e4,
            fadeDuration: .3,
            prettySelect: !1,
            addPromptClass: "",
            usePrefix: "",
            useSuffix: "",
            showOneMessage: !1
        }
    }, a(function() {
        a.validationEngine.defaults.promptPosition = b.isRTL() ? "topLeft" : "topRight";
    });
}(jQuery), function(a) {
    a.fn.jRating = function(b) {
        var c = {
            bigStarsPath: _basehttp + "/includes/rating/js/icons/stars.png",
            smallStarsPath: _basehttp + "/includes/rating/js/icons/small.png",
            phpPath: _basehttp + "/includes/rating/jRating.php",
            type: "big",
            step: !1,
            isDisabled: !1,
            showRateInfo: !0,
            canRateAgain: !1,
            length: 5,
            decimalLength: 0,
            rateMax: 20,
            rateInfosX: -45,
            rateInfosY: 5,
            nbRates: 1,
            onSuccess: null,
            onError: null
        };
        return this.length > 0 ? this.each(function() {
            function d(a) {
                var b = parseFloat(100 * a / s * g.rateMax / 100);
                switch (g.decimalLength) {
                  case 1:
                    var c = Math.round(10 * b) / 10;
                    break;

                  case 2:
                    var c = Math.round(100 * b) / 100;
                    break;

                  case 3:
                    var c = Math.round(1e3 * b) / 1e3;
                    break;

                  default:
                    var c = Math.round(1 * b) / 1;
                }
                return c;
            }
            function e() {
                switch (g.type) {
                  case "small":
                    i = 12, j = 10, k = g.smallStarsPath;
                    break;

                  default:
                    i = 23, j = 20, k = g.bigStarsPath;
                }
            }
            function f(a) {
                return a ? a.offsetLeft + f(a.offsetParent) : 0;
            }
            var g = a.extend(c, b), h = 0, i = 0, j = 0, k = "", l = !1, m = 0, n = g.nbRates;
            if (a(this).hasClass("jDisabled") || g.isDisabled) var o = !0; else var o = !1;
            e(), a(this).height(j);
            var p = parseFloat(a(this).attr("data-average")), q = parseInt(a(this).attr("data-id")), r = parseInt(a(this).attr("data-type")), s = i * g.length, t = p / g.rateMax * s, p = (a("<div>", {
                "class": "jRatingColor",
                css: {
                    width: t
                }
            }).appendTo(a(this)), a("<div>", {
                "class": "jRatingAverage",
                css: {
                    width: 0,
                    top: -j
                }
            }).appendTo(a(this)));
            a("<div>", {
                "class": "jStar",
                css: {
                    width: s,
                    height: j,
                    top: -(2 * j),
                    background: "url(" + k + ") repeat-x"
                }
            }).appendTo(a(this));
            a(this).css({
                width: s,
                overflow: "hidden",
                zIndex: 1,
                position: "relative"
            }), o || a(this).unbind().bind({
                mouseenter: function(b) {
                    var c = f(this), e = b.pageX - c;
                    if (g.showRateInfo) {
                        a("<p>", {
                            "class": "jRatingInfos",
                            html: d(e) + ' <span class="maxRate">/ ' + g.rateMax + "</span>",
                            css: {
                                top: b.pageY + g.rateInfosY,
                                left: b.pageX + g.rateInfosX
                            }
                        }).appendTo("body").show();
                    }
                },
                mouseover: function(b) {
                    a(this).css("cursor", "pointer");
                },
                mouseout: function() {
                    a(this).css("cursor", "default"), l ? p.width(m) : p.width(0);
                },
                mousemove: function(b) {
                    var c = f(this), e = b.pageX - c;
                    h = g.step ? Math.floor(e / i) * i + i : e, p.width(h), g.showRateInfo && a("p.jRatingInfos").css({
                        left: b.pageX + g.rateInfosX
                    }).html(d(h) + ' <span class="maxRate">/ ' + g.rateMax + "</span>");
                },
                mouseleave: function() {
                    a("p.jRatingInfos").remove();
                },
                click: function(b) {
                    var c = this;
                    l = !0, m = h, n--, (!g.canRateAgain || parseInt(n) <= 0) && a(this).unbind().css("cursor", "default").addClass("jDisabled"), 
                    g.showRateInfo && a("p.jRatingInfos").fadeOut("fast", function() {
                        a(this).remove();
                    }), b.preventDefault();
                    var e = d(h);
                    p.width(h), a(".datasSent p").html("<strong>idBox : </strong>" + q + "<br /><strong>rate : </strong>" + e + "<br /><strong>action :</strong> rating"), 
                    a(".serverResponse p").html("<strong>Loading...</strong>"), a.post(g.phpPath, {
                        idBox: q,
                        type: r,
                        rate: e,
                        action: "rating"
                    }, function(b) {
                        b.error ? (a(".serverResponse p").html(b.server), g.onError && g.onError(c, e)) : (a(".serverResponse p").html(b.server), 
                        g.onSuccess && g.onSuccess(c, e));
                    }, "json");
                }
            });
        }) : void 0;
    };
}(jQuery), function(a) {
    "function" == typeof define && define.amd ? define([ "jquery" ], a(jQuery, document, window, navigator)) : a(jQuery, document, window, navigator);
}(function(a, b, c, d, e) {
    "use strict";
    var f = 0, g = function() {
        var b, c = d.userAgent, e = /msie\s\d+/i;
        return c.search(e) > 0 && (b = e.exec(c).toString(), b = b.split(" ")[1], 9 > b) ? (a("html").addClass("lt-ie9"), 
        !0) : !1;
    }();
    Function.prototype.bind || (Function.prototype.bind = function(a) {
        var b = this, c = [].slice;
        if ("function" != typeof b) throw new TypeError();
        var d = c.call(arguments, 1), e = function() {
            if (this instanceof e) {
                var f = function() {};
                f.prototype = b.prototype;
                var g = new f(), h = b.apply(g, d.concat(c.call(arguments)));
                return Object(h) === h ? h : g;
            }
            return b.apply(a, d.concat(c.call(arguments)));
        };
        return e;
    }), Array.prototype.indexOf || (Array.prototype.indexOf = function(a, b) {
        var c;
        if (null == this) throw new TypeError('"this" is null or not defined');
        var d = Object(this), e = d.length >>> 0;
        if (0 === e) return -1;
        var f = +b || 0;
        if (Math.abs(f) === 1 / 0 && (f = 0), f >= e) return -1;
        for (c = Math.max(f >= 0 ? f : e - Math.abs(f), 0); e > c; ) {
            if (c in d && d[c] === a) return c;
            c++;
        }
        return -1;
    });
    var h = '<span class="irs"><span class="irs-line" tabindex="-1"><span class="irs-line-left"></span><span class="irs-line-mid"></span><span class="irs-line-right"></span></span><span class="irs-min">0</span><span class="irs-max">1</span><span class="irs-from">0</span><span class="irs-to">0</span><span class="irs-single">0</span></span><span class="irs-grid"></span><span class="irs-bar"></span>', i = '<span class="irs-bar-edge"></span><span class="irs-shadow shadow-single"></span><span class="irs-slider single"></span>', j = '<span class="irs-shadow shadow-from"></span><span class="irs-shadow shadow-to"></span><span class="irs-slider from"></span><span class="irs-slider to"></span>', k = '<span class="irs-disable-mask"></span>', l = function(d, e, f) {
        this.VERSION = "2.1.3", this.input = d, this.plugin_count = f, this.current_plugin = 0, 
        this.calc_count = 0, this.update_tm = 0, this.old_from = 0, this.old_to = 0, this.old_min_interval = null, 
        this.raf_id = null, this.dragging = !1, this.force_redraw = !1, this.no_diapason = !1, 
        this.is_key = !1, this.is_update = !1, this.is_start = !0, this.is_finish = !1, 
        this.is_active = !1, this.is_resize = !1, this.is_click = !1, this.$cache = {
            win: a(c),
            body: a(b.body),
            input: a(d),
            cont: null,
            rs: null,
            min: null,
            max: null,
            from: null,
            to: null,
            single: null,
            bar: null,
            line: null,
            s_single: null,
            s_from: null,
            s_to: null,
            shad_single: null,
            shad_from: null,
            shad_to: null,
            edge: null,
            grid: null,
            grid_labels: []
        }, this.coords = {
            x_gap: 0,
            x_pointer: 0,
            w_rs: 0,
            w_rs_old: 0,
            w_handle: 0,
            p_gap: 0,
            p_gap_left: 0,
            p_gap_right: 0,
            p_step: 0,
            p_pointer: 0,
            p_handle: 0,
            p_single_fake: 0,
            p_single_real: 0,
            p_from_fake: 0,
            p_from_real: 0,
            p_to_fake: 0,
            p_to_real: 0,
            p_bar_x: 0,
            p_bar_w: 0,
            grid_gap: 0,
            big_num: 0,
            big: [],
            big_w: [],
            big_p: [],
            big_x: []
        }, this.labels = {
            w_min: 0,
            w_max: 0,
            w_from: 0,
            w_to: 0,
            w_single: 0,
            p_min: 0,
            p_max: 0,
            p_from_fake: 0,
            p_from_left: 0,
            p_to_fake: 0,
            p_to_left: 0,
            p_single_fake: 0,
            p_single_left: 0
        };
        var g, h, i, j = this.$cache.input, k = j.prop("value");
        g = {
            type: "single",
            min: 10,
            max: 100,
            from: null,
            to: null,
            step: 1,
            min_interval: 0,
            max_interval: 0,
            drag_interval: !1,
            values: [],
            p_values: [],
            from_fixed: !1,
            from_min: null,
            from_max: null,
            from_shadow: !1,
            to_fixed: !1,
            to_min: null,
            to_max: null,
            to_shadow: !1,
            prettify_enabled: !0,
            prettify_separator: " ",
            prettify: null,
            force_edges: !1,
            keyboard: !1,
            keyboard_step: 5,
            grid: !1,
            grid_margin: !0,
            grid_num: 4,
            grid_snap: !1,
            hide_min_max: !1,
            hide_from_to: !1,
            prefix: "",
            postfix: "",
            max_postfix: "",
            decorate_both: !0,
            values_separator: " — ",
            input_values_separator: ";",
            disable: !1,
            onStart: null,
            onChange: null,
            onFinish: null,
            onUpdate: null
        }, h = {
            type: j.data("type"),
            min: j.data("min"),
            max: j.data("max"),
            from: j.data("from"),
            to: j.data("to"),
            step: j.data("step"),
            min_interval: j.data("minInterval"),
            max_interval: j.data("maxInterval"),
            drag_interval: j.data("dragInterval"),
            values: j.data("values"),
            from_fixed: j.data("fromFixed"),
            from_min: j.data("fromMin"),
            from_max: j.data("fromMax"),
            from_shadow: j.data("fromShadow"),
            to_fixed: j.data("toFixed"),
            to_min: j.data("toMin"),
            to_max: j.data("toMax"),
            to_shadow: j.data("toShadow"),
            prettify_enabled: j.data("prettifyEnabled"),
            prettify_separator: j.data("prettifySeparator"),
            force_edges: j.data("forceEdges"),
            keyboard: j.data("keyboard"),
            keyboard_step: j.data("keyboardStep"),
            grid: j.data("grid"),
            grid_margin: j.data("gridMargin"),
            grid_num: j.data("gridNum"),
            grid_snap: j.data("gridSnap"),
            hide_min_max: j.data("hideMinMax"),
            hide_from_to: j.data("hideFromTo"),
            prefix: j.data("prefix"),
            postfix: j.data("postfix"),
            max_postfix: j.data("maxPostfix"),
            decorate_both: j.data("decorateBoth"),
            values_separator: j.data("valuesSeparator"),
            input_values_separator: j.data("inputValuesSeparator"),
            disable: j.data("disable")
        }, h.values = h.values && h.values.split(",");
        for (i in h) h.hasOwnProperty(i) && (h[i] || 0 === h[i] || delete h[i]);
        k && (k = k.split(h.input_values_separator || e.input_values_separator || ";"), 
        k[0] && k[0] == +k[0] && (k[0] = +k[0]), k[1] && k[1] == +k[1] && (k[1] = +k[1]), 
        e && e.values && e.values.length ? (g.from = k[0] && e.values.indexOf(k[0]), g.to = k[1] && e.values.indexOf(k[1])) : (g.from = k[0] && +k[0], 
        g.to = k[1] && +k[1])), a.extend(g, e), a.extend(g, h), this.options = g, this.validate(), 
        this.result = {
            input: this.$cache.input,
            slider: null,
            min: this.options.min,
            max: this.options.max,
            from: this.options.from,
            from_percent: 0,
            from_value: null,
            to: this.options.to,
            to_percent: 0,
            to_value: null
        }, this.init();
    };
    l.prototype = {
        init: function(a) {
            this.no_diapason = !1, this.coords.p_step = this.convertToPercent(this.options.step, !0), 
            this.target = "base", this.toggleInput(), this.append(), this.setMinMax(), a ? (this.force_redraw = !0, 
            this.calc(!0), this.callOnUpdate()) : (this.force_redraw = !0, this.calc(!0), this.callOnStart()), 
            this.updateScene();
        },
        append: function() {
            var a = '<span class="irs js-irs-' + this.plugin_count + '"></span>';
            this.$cache.input.before(a), this.$cache.input.prop("readonly", !0), this.$cache.cont = this.$cache.input.prev(), 
            this.result.slider = this.$cache.cont, this.$cache.cont.html(h), this.$cache.rs = this.$cache.cont.find(".irs"), 
            this.$cache.min = this.$cache.cont.find(".irs-min"), this.$cache.max = this.$cache.cont.find(".irs-max"), 
            this.$cache.from = this.$cache.cont.find(".irs-from"), this.$cache.to = this.$cache.cont.find(".irs-to"), 
            this.$cache.single = this.$cache.cont.find(".irs-single"), this.$cache.bar = this.$cache.cont.find(".irs-bar"), 
            this.$cache.line = this.$cache.cont.find(".irs-line"), this.$cache.grid = this.$cache.cont.find(".irs-grid"), 
            "single" === this.options.type ? (this.$cache.cont.append(i), this.$cache.edge = this.$cache.cont.find(".irs-bar-edge"), 
            this.$cache.s_single = this.$cache.cont.find(".single"), this.$cache.from[0].style.visibility = "hidden", 
            this.$cache.to[0].style.visibility = "hidden", this.$cache.shad_single = this.$cache.cont.find(".shadow-single")) : (this.$cache.cont.append(j), 
            this.$cache.s_from = this.$cache.cont.find(".from"), this.$cache.s_to = this.$cache.cont.find(".to"), 
            this.$cache.shad_from = this.$cache.cont.find(".shadow-from"), this.$cache.shad_to = this.$cache.cont.find(".shadow-to"), 
            this.setTopHandler()), this.options.hide_from_to && (this.$cache.from[0].style.display = "none", 
            this.$cache.to[0].style.display = "none", this.$cache.single[0].style.display = "none"), 
            this.appendGrid(), this.options.disable ? (this.appendDisableMask(), this.$cache.input[0].disabled = !0) : (this.$cache.cont.removeClass("irs-disabled"), 
            this.$cache.input[0].disabled = !1, this.bindEvents()), this.options.drag_interval && (this.$cache.bar[0].style.cursor = "ew-resize");
        },
        setTopHandler: function() {
            var a = this.options.min, b = this.options.max, c = this.options.from, d = this.options.to;
            c > a && d === b ? this.$cache.s_from.addClass("type_last") : b > d && this.$cache.s_to.addClass("type_last");
        },
        changeLevel: function(a) {
            switch (a) {
              case "single":
                this.coords.p_gap = this.toFixed(this.coords.p_pointer - this.coords.p_single_fake);
                break;

              case "from":
                this.coords.p_gap = this.toFixed(this.coords.p_pointer - this.coords.p_from_fake), 
                this.$cache.s_from.addClass("state_hover"), this.$cache.s_from.addClass("type_last"), 
                this.$cache.s_to.removeClass("type_last");
                break;

              case "to":
                this.coords.p_gap = this.toFixed(this.coords.p_pointer - this.coords.p_to_fake), 
                this.$cache.s_to.addClass("state_hover"), this.$cache.s_to.addClass("type_last"), 
                this.$cache.s_from.removeClass("type_last");
                break;

              case "both":
                this.coords.p_gap_left = this.toFixed(this.coords.p_pointer - this.coords.p_from_fake), 
                this.coords.p_gap_right = this.toFixed(this.coords.p_to_fake - this.coords.p_pointer), 
                this.$cache.s_to.removeClass("type_last"), this.$cache.s_from.removeClass("type_last");
            }
        },
        appendDisableMask: function() {
            this.$cache.cont.append(k), this.$cache.cont.addClass("irs-disabled");
        },
        remove: function() {
            this.$cache.cont.remove(), this.$cache.cont = null, this.$cache.line.off("keydown.irs_" + this.plugin_count), 
            this.$cache.body.off("touchmove.irs_" + this.plugin_count), this.$cache.body.off("mousemove.irs_" + this.plugin_count), 
            this.$cache.win.off("touchend.irs_" + this.plugin_count), this.$cache.win.off("mouseup.irs_" + this.plugin_count), 
            g && (this.$cache.body.off("mouseup.irs_" + this.plugin_count), this.$cache.body.off("mouseleave.irs_" + this.plugin_count)), 
            this.$cache.grid_labels = [], this.coords.big = [], this.coords.big_w = [], this.coords.big_p = [], 
            this.coords.big_x = [], cancelAnimationFrame(this.raf_id);
        },
        bindEvents: function() {
            this.no_diapason || (this.$cache.body.on("touchmove.irs_" + this.plugin_count, this.pointerMove.bind(this)), 
            this.$cache.body.on("mousemove.irs_" + this.plugin_count, this.pointerMove.bind(this)), 
            this.$cache.win.on("touchend.irs_" + this.plugin_count, this.pointerUp.bind(this)), 
            this.$cache.win.on("mouseup.irs_" + this.plugin_count, this.pointerUp.bind(this)), 
            this.$cache.line.on("touchstart.irs_" + this.plugin_count, this.pointerClick.bind(this, "click")), 
            this.$cache.line.on("mousedown.irs_" + this.plugin_count, this.pointerClick.bind(this, "click")), 
            this.options.drag_interval && "double" === this.options.type ? (this.$cache.bar.on("touchstart.irs_" + this.plugin_count, this.pointerDown.bind(this, "both")), 
            this.$cache.bar.on("mousedown.irs_" + this.plugin_count, this.pointerDown.bind(this, "both"))) : (this.$cache.bar.on("touchstart.irs_" + this.plugin_count, this.pointerClick.bind(this, "click")), 
            this.$cache.bar.on("mousedown.irs_" + this.plugin_count, this.pointerClick.bind(this, "click"))), 
            "single" === this.options.type ? (this.$cache.single.on("touchstart.irs_" + this.plugin_count, this.pointerDown.bind(this, "single")), 
            this.$cache.s_single.on("touchstart.irs_" + this.plugin_count, this.pointerDown.bind(this, "single")), 
            this.$cache.shad_single.on("touchstart.irs_" + this.plugin_count, this.pointerClick.bind(this, "click")), 
            this.$cache.single.on("mousedown.irs_" + this.plugin_count, this.pointerDown.bind(this, "single")), 
            this.$cache.s_single.on("mousedown.irs_" + this.plugin_count, this.pointerDown.bind(this, "single")), 
            this.$cache.edge.on("mousedown.irs_" + this.plugin_count, this.pointerClick.bind(this, "click")), 
            this.$cache.shad_single.on("mousedown.irs_" + this.plugin_count, this.pointerClick.bind(this, "click"))) : (this.$cache.single.on("touchstart.irs_" + this.plugin_count, this.pointerDown.bind(this, null)), 
            this.$cache.single.on("mousedown.irs_" + this.plugin_count, this.pointerDown.bind(this, null)), 
            this.$cache.from.on("touchstart.irs_" + this.plugin_count, this.pointerDown.bind(this, "from")), 
            this.$cache.s_from.on("touchstart.irs_" + this.plugin_count, this.pointerDown.bind(this, "from")), 
            this.$cache.to.on("touchstart.irs_" + this.plugin_count, this.pointerDown.bind(this, "to")), 
            this.$cache.s_to.on("touchstart.irs_" + this.plugin_count, this.pointerDown.bind(this, "to")), 
            this.$cache.shad_from.on("touchstart.irs_" + this.plugin_count, this.pointerClick.bind(this, "click")), 
            this.$cache.shad_to.on("touchstart.irs_" + this.plugin_count, this.pointerClick.bind(this, "click")), 
            this.$cache.from.on("mousedown.irs_" + this.plugin_count, this.pointerDown.bind(this, "from")), 
            this.$cache.s_from.on("mousedown.irs_" + this.plugin_count, this.pointerDown.bind(this, "from")), 
            this.$cache.to.on("mousedown.irs_" + this.plugin_count, this.pointerDown.bind(this, "to")), 
            this.$cache.s_to.on("mousedown.irs_" + this.plugin_count, this.pointerDown.bind(this, "to")), 
            this.$cache.shad_from.on("mousedown.irs_" + this.plugin_count, this.pointerClick.bind(this, "click")), 
            this.$cache.shad_to.on("mousedown.irs_" + this.plugin_count, this.pointerClick.bind(this, "click"))), 
            this.options.keyboard && this.$cache.line.on("keydown.irs_" + this.plugin_count, this.key.bind(this, "keyboard")), 
            g && (this.$cache.body.on("mouseup.irs_" + this.plugin_count, this.pointerUp.bind(this)), 
            this.$cache.body.on("mouseleave.irs_" + this.plugin_count, this.pointerUp.bind(this))));
        },
        pointerMove: function(a) {
            if (this.dragging) {
                var b = a.pageX || a.originalEvent.touches && a.originalEvent.touches[0].pageX;
                this.coords.x_pointer = b - this.coords.x_gap, this.calc();
            }
        },
        pointerUp: function(b) {
            this.current_plugin === this.plugin_count && this.is_active && (this.is_active = !1, 
            this.$cache.cont.find(".state_hover").removeClass("state_hover"), this.force_redraw = !0, 
            g && a("*").prop("unselectable", !1), this.updateScene(), this.restoreOriginalMinInterval(), 
            (a.contains(this.$cache.cont[0], b.target) || this.dragging) && (this.is_finish = !0, 
            this.callOnFinish()), this.dragging = !1);
        },
        pointerDown: function(b, c) {
            c.preventDefault();
            var d = c.pageX || c.originalEvent.touches && c.originalEvent.touches[0].pageX;
            2 !== c.button && ("both" === b && this.setTempMinInterval(), b || (b = this.target), 
            this.current_plugin = this.plugin_count, this.target = b, this.is_active = !0, this.dragging = !0, 
            this.coords.x_gap = this.$cache.rs.offset().left, this.coords.x_pointer = d - this.coords.x_gap, 
            this.calcPointerPercent(), this.changeLevel(b), g && a("*").prop("unselectable", !0), 
            this.$cache.line.trigger("focus"), this.updateScene());
        },
        pointerClick: function(a, b) {
            b.preventDefault();
            var c = b.pageX || b.originalEvent.touches && b.originalEvent.touches[0].pageX;
            2 !== b.button && (this.current_plugin = this.plugin_count, this.target = a, this.is_click = !0, 
            this.coords.x_gap = this.$cache.rs.offset().left, this.coords.x_pointer = +(c - this.coords.x_gap).toFixed(), 
            this.force_redraw = !0, this.calc(), this.$cache.line.trigger("focus"));
        },
        key: function(a, b) {
            if (!(this.current_plugin !== this.plugin_count || b.altKey || b.ctrlKey || b.shiftKey || b.metaKey)) {
                switch (b.which) {
                  case 83:
                  case 65:
                  case 40:
                  case 37:
                    b.preventDefault(), this.moveByKey(!1);
                    break;

                  case 87:
                  case 68:
                  case 38:
                  case 39:
                    b.preventDefault(), this.moveByKey(!0);
                }
                return !0;
            }
        },
        moveByKey: function(a) {
            var b = this.coords.p_pointer;
            a ? b += this.options.keyboard_step : b -= this.options.keyboard_step, this.coords.x_pointer = this.toFixed(this.coords.w_rs / 100 * b), 
            this.is_key = !0, this.calc();
        },
        setMinMax: function() {
            if (this.options) {
                if (this.options.hide_min_max) return this.$cache.min[0].style.display = "none", 
                void (this.$cache.max[0].style.display = "none");
                this.options.values.length ? (this.$cache.min.html(this.decorate(this.options.p_values[this.options.min])), 
                this.$cache.max.html(this.decorate(this.options.p_values[this.options.max]))) : (this.$cache.min.html(this.decorate(this._prettify(this.options.min), this.options.min)), 
                this.$cache.max.html(this.decorate(this._prettify(this.options.max), this.options.max))), 
                this.labels.w_min = this.$cache.min.outerWidth(!1), this.labels.w_max = this.$cache.max.outerWidth(!1);
            }
        },
        setTempMinInterval: function() {
            var a = this.result.to - this.result.from;
            null === this.old_min_interval && (this.old_min_interval = this.options.min_interval), 
            this.options.min_interval = a;
        },
        restoreOriginalMinInterval: function() {
            null !== this.old_min_interval && (this.options.min_interval = this.old_min_interval, 
            this.old_min_interval = null);
        },
        calc: function(a) {
            if (this.options && (this.calc_count++, (10 === this.calc_count || a) && (this.calc_count = 0, 
            this.coords.w_rs = this.$cache.rs.outerWidth(!1), this.calcHandlePercent()), this.coords.w_rs)) {
                this.calcPointerPercent();
                var b = this.getHandleX();
                switch ("click" === this.target && (this.coords.p_gap = this.coords.p_handle / 2, 
                b = this.getHandleX(), this.options.drag_interval ? this.target = "both_one" : this.target = this.chooseHandle(b)), 
                this.target) {
                  case "base":
                    var c = (this.options.max - this.options.min) / 100, d = (this.result.from - this.options.min) / c, e = (this.result.to - this.options.min) / c;
                    this.coords.p_single_real = this.toFixed(d), this.coords.p_from_real = this.toFixed(d), 
                    this.coords.p_to_real = this.toFixed(e), this.coords.p_single_real = this.checkDiapason(this.coords.p_single_real, this.options.from_min, this.options.from_max), 
                    this.coords.p_from_real = this.checkDiapason(this.coords.p_from_real, this.options.from_min, this.options.from_max), 
                    this.coords.p_to_real = this.checkDiapason(this.coords.p_to_real, this.options.to_min, this.options.to_max), 
                    this.coords.p_single_fake = this.convertToFakePercent(this.coords.p_single_real), 
                    this.coords.p_from_fake = this.convertToFakePercent(this.coords.p_from_real), this.coords.p_to_fake = this.convertToFakePercent(this.coords.p_to_real), 
                    this.target = null;
                    break;

                  case "single":
                    if (this.options.from_fixed) break;
                    this.coords.p_single_real = this.convertToRealPercent(b), this.coords.p_single_real = this.calcWithStep(this.coords.p_single_real), 
                    this.coords.p_single_real = this.checkDiapason(this.coords.p_single_real, this.options.from_min, this.options.from_max), 
                    this.coords.p_single_fake = this.convertToFakePercent(this.coords.p_single_real);
                    break;

                  case "from":
                    if (this.options.from_fixed) break;
                    this.coords.p_from_real = this.convertToRealPercent(b), this.coords.p_from_real = this.calcWithStep(this.coords.p_from_real), 
                    this.coords.p_from_real > this.coords.p_to_real && (this.coords.p_from_real = this.coords.p_to_real), 
                    this.coords.p_from_real = this.checkDiapason(this.coords.p_from_real, this.options.from_min, this.options.from_max), 
                    this.coords.p_from_real = this.checkMinInterval(this.coords.p_from_real, this.coords.p_to_real, "from"), 
                    this.coords.p_from_real = this.checkMaxInterval(this.coords.p_from_real, this.coords.p_to_real, "from"), 
                    this.coords.p_from_fake = this.convertToFakePercent(this.coords.p_from_real);
                    break;

                  case "to":
                    if (this.options.to_fixed) break;
                    this.coords.p_to_real = this.convertToRealPercent(b), this.coords.p_to_real = this.calcWithStep(this.coords.p_to_real), 
                    this.coords.p_to_real < this.coords.p_from_real && (this.coords.p_to_real = this.coords.p_from_real), 
                    this.coords.p_to_real = this.checkDiapason(this.coords.p_to_real, this.options.to_min, this.options.to_max), 
                    this.coords.p_to_real = this.checkMinInterval(this.coords.p_to_real, this.coords.p_from_real, "to"), 
                    this.coords.p_to_real = this.checkMaxInterval(this.coords.p_to_real, this.coords.p_from_real, "to"), 
                    this.coords.p_to_fake = this.convertToFakePercent(this.coords.p_to_real);
                    break;

                  case "both":
                    if (this.options.from_fixed || this.options.to_fixed) break;
                    b = this.toFixed(b + .1 * this.coords.p_handle), this.coords.p_from_real = this.convertToRealPercent(b) - this.coords.p_gap_left, 
                    this.coords.p_from_real = this.calcWithStep(this.coords.p_from_real), this.coords.p_from_real = this.checkDiapason(this.coords.p_from_real, this.options.from_min, this.options.from_max), 
                    this.coords.p_from_real = this.checkMinInterval(this.coords.p_from_real, this.coords.p_to_real, "from"), 
                    this.coords.p_from_fake = this.convertToFakePercent(this.coords.p_from_real), this.coords.p_to_real = this.convertToRealPercent(b) + this.coords.p_gap_right, 
                    this.coords.p_to_real = this.calcWithStep(this.coords.p_to_real), this.coords.p_to_real = this.checkDiapason(this.coords.p_to_real, this.options.to_min, this.options.to_max), 
                    this.coords.p_to_real = this.checkMinInterval(this.coords.p_to_real, this.coords.p_from_real, "to"), 
                    this.coords.p_to_fake = this.convertToFakePercent(this.coords.p_to_real);
                    break;

                  case "both_one":
                    if (this.options.from_fixed || this.options.to_fixed) break;
                    var f = this.convertToRealPercent(b), g = this.result.from_percent, h = this.result.to_percent, i = h - g, j = i / 2, k = f - j, l = f + j;
                    0 > k && (k = 0, l = k + i), l > 100 && (l = 100, k = l - i), this.coords.p_from_real = this.calcWithStep(k), 
                    this.coords.p_from_real = this.checkDiapason(this.coords.p_from_real, this.options.from_min, this.options.from_max), 
                    this.coords.p_from_fake = this.convertToFakePercent(this.coords.p_from_real), this.coords.p_to_real = this.calcWithStep(l), 
                    this.coords.p_to_real = this.checkDiapason(this.coords.p_to_real, this.options.to_min, this.options.to_max), 
                    this.coords.p_to_fake = this.convertToFakePercent(this.coords.p_to_real);
                }
                "single" === this.options.type ? (this.coords.p_bar_x = this.coords.p_handle / 2, 
                this.coords.p_bar_w = this.coords.p_single_fake, this.result.from_percent = this.coords.p_single_real, 
                this.result.from = this.convertToValue(this.coords.p_single_real), this.options.values.length && (this.result.from_value = this.options.values[this.result.from])) : (this.coords.p_bar_x = this.toFixed(this.coords.p_from_fake + this.coords.p_handle / 2), 
                this.coords.p_bar_w = this.toFixed(this.coords.p_to_fake - this.coords.p_from_fake), 
                this.result.from_percent = this.coords.p_from_real, this.result.from = this.convertToValue(this.coords.p_from_real), 
                this.result.to_percent = this.coords.p_to_real, this.result.to = this.convertToValue(this.coords.p_to_real), 
                this.options.values.length && (this.result.from_value = this.options.values[this.result.from], 
                this.result.to_value = this.options.values[this.result.to])), this.calcMinMax(), 
                this.calcLabels();
            }
        },
        calcPointerPercent: function() {
            return this.coords.w_rs ? (this.coords.x_pointer < 0 || isNaN(this.coords.x_pointer) ? this.coords.x_pointer = 0 : this.coords.x_pointer > this.coords.w_rs && (this.coords.x_pointer = this.coords.w_rs), 
            void (this.coords.p_pointer = this.toFixed(this.coords.x_pointer / this.coords.w_rs * 100))) : void (this.coords.p_pointer = 0);
        },
        convertToRealPercent: function(a) {
            var b = 100 - this.coords.p_handle;
            return a / b * 100;
        },
        convertToFakePercent: function(a) {
            var b = 100 - this.coords.p_handle;
            return a / 100 * b;
        },
        getHandleX: function() {
            var a = 100 - this.coords.p_handle, b = this.toFixed(this.coords.p_pointer - this.coords.p_gap);
            return 0 > b ? b = 0 : b > a && (b = a), b;
        },
        calcHandlePercent: function() {
            "single" === this.options.type ? this.coords.w_handle = this.$cache.s_single.outerWidth(!1) : this.coords.w_handle = this.$cache.s_from.outerWidth(!1), 
            this.coords.p_handle = this.toFixed(this.coords.w_handle / this.coords.w_rs * 100);
        },
        chooseHandle: function(a) {
            if ("single" === this.options.type) return "single";
            var b = this.coords.p_from_real + (this.coords.p_to_real - this.coords.p_from_real) / 2;
            return a >= b ? this.options.to_fixed ? "from" : "to" : this.options.from_fixed ? "to" : "from";
        },
        calcMinMax: function() {
            this.coords.w_rs && (this.labels.p_min = this.labels.w_min / this.coords.w_rs * 100, 
            this.labels.p_max = this.labels.w_max / this.coords.w_rs * 100);
        },
        calcLabels: function() {
            this.coords.w_rs && !this.options.hide_from_to && ("single" === this.options.type ? (this.labels.w_single = this.$cache.single.outerWidth(!1), 
            this.labels.p_single_fake = this.labels.w_single / this.coords.w_rs * 100, this.labels.p_single_left = this.coords.p_single_fake + this.coords.p_handle / 2 - this.labels.p_single_fake / 2, 
            this.labels.p_single_left = this.checkEdges(this.labels.p_single_left, this.labels.p_single_fake)) : (this.labels.w_from = this.$cache.from.outerWidth(!1), 
            this.labels.p_from_fake = this.labels.w_from / this.coords.w_rs * 100, this.labels.p_from_left = this.coords.p_from_fake + this.coords.p_handle / 2 - this.labels.p_from_fake / 2, 
            this.labels.p_from_left = this.toFixed(this.labels.p_from_left), this.labels.p_from_left = this.checkEdges(this.labels.p_from_left, this.labels.p_from_fake), 
            this.labels.w_to = this.$cache.to.outerWidth(!1), this.labels.p_to_fake = this.labels.w_to / this.coords.w_rs * 100, 
            this.labels.p_to_left = this.coords.p_to_fake + this.coords.p_handle / 2 - this.labels.p_to_fake / 2, 
            this.labels.p_to_left = this.toFixed(this.labels.p_to_left), this.labels.p_to_left = this.checkEdges(this.labels.p_to_left, this.labels.p_to_fake), 
            this.labels.w_single = this.$cache.single.outerWidth(!1), this.labels.p_single_fake = this.labels.w_single / this.coords.w_rs * 100, 
            this.labels.p_single_left = (this.labels.p_from_left + this.labels.p_to_left + this.labels.p_to_fake) / 2 - this.labels.p_single_fake / 2, 
            this.labels.p_single_left = this.toFixed(this.labels.p_single_left), this.labels.p_single_left = this.checkEdges(this.labels.p_single_left, this.labels.p_single_fake)));
        },
        updateScene: function() {
            this.raf_id && (cancelAnimationFrame(this.raf_id), this.raf_id = null), clearTimeout(this.update_tm), 
            this.update_tm = null, this.options && (this.drawHandles(), this.is_active ? this.raf_id = requestAnimationFrame(this.updateScene.bind(this)) : this.update_tm = setTimeout(this.updateScene.bind(this), 300));
        },
        drawHandles: function() {
            this.coords.w_rs = this.$cache.rs.outerWidth(!1), this.coords.w_rs && (this.coords.w_rs !== this.coords.w_rs_old && (this.target = "base", 
            this.is_resize = !0), (this.coords.w_rs !== this.coords.w_rs_old || this.force_redraw) && (this.setMinMax(), 
            this.calc(!0), this.drawLabels(), this.options.grid && (this.calcGridMargin(), this.calcGridLabels()), 
            this.force_redraw = !0, this.coords.w_rs_old = this.coords.w_rs, this.drawShadow()), 
            this.coords.w_rs && (this.dragging || this.force_redraw || this.is_key) && ((this.old_from !== this.result.from || this.old_to !== this.result.to || this.force_redraw || this.is_key) && (this.drawLabels(), 
            this.$cache.bar[0].style.left = this.coords.p_bar_x + "%", this.$cache.bar[0].style.width = this.coords.p_bar_w + "%", 
            "single" === this.options.type ? (this.$cache.s_single[0].style.left = this.coords.p_single_fake + "%", 
            this.$cache.single[0].style.left = this.labels.p_single_left + "%", this.options.values.length ? this.$cache.input.prop("value", this.result.from_value) : this.$cache.input.prop("value", this.result.from), 
            this.$cache.input.data("from", this.result.from)) : (this.$cache.s_from[0].style.left = this.coords.p_from_fake + "%", 
            this.$cache.s_to[0].style.left = this.coords.p_to_fake + "%", (this.old_from !== this.result.from || this.force_redraw) && (this.$cache.from[0].style.left = this.labels.p_from_left + "%"), 
            (this.old_to !== this.result.to || this.force_redraw) && (this.$cache.to[0].style.left = this.labels.p_to_left + "%"), 
            this.$cache.single[0].style.left = this.labels.p_single_left + "%", this.options.values.length ? this.$cache.input.prop("value", this.result.from_value + this.options.input_values_separator + this.result.to_value) : this.$cache.input.prop("value", this.result.from + this.options.input_values_separator + this.result.to), 
            this.$cache.input.data("from", this.result.from), this.$cache.input.data("to", this.result.to)), 
            this.old_from === this.result.from && this.old_to === this.result.to || this.is_start || this.$cache.input.trigger("change"), 
            this.old_from = this.result.from, this.old_to = this.result.to, this.is_resize || this.is_update || this.is_start || this.is_finish || this.callOnChange(), 
            (this.is_key || this.is_click) && (this.is_key = !1, this.is_click = !1, this.callOnFinish()), 
            this.is_update = !1, this.is_resize = !1, this.is_finish = !1), this.is_start = !1, 
            this.is_key = !1, this.is_click = !1, this.force_redraw = !1));
        },
        drawLabels: function() {
            if (this.options) {
                var a, b, c, d = this.options.values.length, e = this.options.p_values;
                if (!this.options.hide_from_to) if ("single" === this.options.type) d ? (a = this.decorate(e[this.result.from]), 
                this.$cache.single.html(a)) : (a = this.decorate(this._prettify(this.result.from), this.result.from), 
                this.$cache.single.html(a)), this.calcLabels(), this.labels.p_single_left < this.labels.p_min + 1 ? this.$cache.min[0].style.visibility = "hidden" : this.$cache.min[0].style.visibility = "visible", 
                this.labels.p_single_left + this.labels.p_single_fake > 100 - this.labels.p_max - 1 ? this.$cache.max[0].style.visibility = "hidden" : this.$cache.max[0].style.visibility = "visible"; else {
                    d ? (this.options.decorate_both ? (a = this.decorate(e[this.result.from]), a += this.options.values_separator, 
                    a += this.decorate(e[this.result.to])) : a = this.decorate(e[this.result.from] + this.options.values_separator + e[this.result.to]), 
                    b = this.decorate(e[this.result.from]), c = this.decorate(e[this.result.to]), this.$cache.single.html(a), 
                    this.$cache.from.html(b), this.$cache.to.html(c)) : (this.options.decorate_both ? (a = this.decorate(this._prettify(this.result.from), this.result.from), 
                    a += this.options.values_separator, a += this.decorate(this._prettify(this.result.to), this.result.to)) : a = this.decorate(this._prettify(this.result.from) + this.options.values_separator + this._prettify(this.result.to), this.result.to), 
                    b = this.decorate(this._prettify(this.result.from), this.result.from), c = this.decorate(this._prettify(this.result.to), this.result.to), 
                    this.$cache.single.html(a), this.$cache.from.html(b), this.$cache.to.html(c)), this.calcLabels();
                    var f = Math.min(this.labels.p_single_left, this.labels.p_from_left), g = this.labels.p_single_left + this.labels.p_single_fake, h = this.labels.p_to_left + this.labels.p_to_fake, i = Math.max(g, h);
                    this.labels.p_from_left + this.labels.p_from_fake >= this.labels.p_to_left ? (this.$cache.from[0].style.visibility = "hidden", 
                    this.$cache.to[0].style.visibility = "hidden", this.$cache.single[0].style.visibility = "visible", 
                    this.result.from === this.result.to ? ("from" === this.target ? this.$cache.from[0].style.visibility = "visible" : "to" === this.target && (this.$cache.to[0].style.visibility = "visible"), 
                    this.$cache.single[0].style.visibility = "hidden", i = h) : (this.$cache.from[0].style.visibility = "hidden", 
                    this.$cache.to[0].style.visibility = "hidden", this.$cache.single[0].style.visibility = "visible", 
                    i = Math.max(g, h))) : (this.$cache.from[0].style.visibility = "visible", this.$cache.to[0].style.visibility = "visible", 
                    this.$cache.single[0].style.visibility = "hidden"), f < this.labels.p_min + 1 ? this.$cache.min[0].style.visibility = "hidden" : this.$cache.min[0].style.visibility = "visible", 
                    i > 100 - this.labels.p_max - 1 ? this.$cache.max[0].style.visibility = "hidden" : this.$cache.max[0].style.visibility = "visible";
                }
            }
        },
        drawShadow: function() {
            var a, b, c, d, e = this.options, f = this.$cache, g = "number" == typeof e.from_min && !isNaN(e.from_min), h = "number" == typeof e.from_max && !isNaN(e.from_max), i = "number" == typeof e.to_min && !isNaN(e.to_min), j = "number" == typeof e.to_max && !isNaN(e.to_max);
            "single" === e.type ? e.from_shadow && (g || h) ? (a = this.convertToPercent(g ? e.from_min : e.min), 
            b = this.convertToPercent(h ? e.from_max : e.max) - a, a = this.toFixed(a - this.coords.p_handle / 100 * a), 
            b = this.toFixed(b - this.coords.p_handle / 100 * b), a += this.coords.p_handle / 2, 
            f.shad_single[0].style.display = "block", f.shad_single[0].style.left = a + "%", 
            f.shad_single[0].style.width = b + "%") : f.shad_single[0].style.display = "none" : (e.from_shadow && (g || h) ? (a = this.convertToPercent(g ? e.from_min : e.min), 
            b = this.convertToPercent(h ? e.from_max : e.max) - a, a = this.toFixed(a - this.coords.p_handle / 100 * a), 
            b = this.toFixed(b - this.coords.p_handle / 100 * b), a += this.coords.p_handle / 2, 
            f.shad_from[0].style.display = "block", f.shad_from[0].style.left = a + "%", f.shad_from[0].style.width = b + "%") : f.shad_from[0].style.display = "none", 
            e.to_shadow && (i || j) ? (c = this.convertToPercent(i ? e.to_min : e.min), d = this.convertToPercent(j ? e.to_max : e.max) - c, 
            c = this.toFixed(c - this.coords.p_handle / 100 * c), d = this.toFixed(d - this.coords.p_handle / 100 * d), 
            c += this.coords.p_handle / 2, f.shad_to[0].style.display = "block", f.shad_to[0].style.left = c + "%", 
            f.shad_to[0].style.width = d + "%") : f.shad_to[0].style.display = "none");
        },
        callOnStart: function() {
            this.options.onStart && "function" == typeof this.options.onStart && this.options.onStart(this.result);
        },
        callOnChange: function() {
            this.options.onChange && "function" == typeof this.options.onChange && this.options.onChange(this.result);
        },
        callOnFinish: function() {
            this.options.onFinish && "function" == typeof this.options.onFinish && this.options.onFinish(this.result);
        },
        callOnUpdate: function() {
            this.options.onUpdate && "function" == typeof this.options.onUpdate && this.options.onUpdate(this.result);
        },
        toggleInput: function() {
            this.$cache.input.toggleClass("irs-hidden-input");
        },
        convertToPercent: function(a, b) {
            var c, d, e = this.options.max - this.options.min, f = e / 100;
            return e ? (c = b ? a : a - this.options.min, d = c / f, this.toFixed(d)) : (this.no_diapason = !0, 
            0);
        },
        convertToValue: function(a) {
            var b, c, d = this.options.min, e = this.options.max, f = d.toString().split(".")[1], g = e.toString().split(".")[1], h = 0, i = 0;
            if (0 === a) return this.options.min;
            if (100 === a) return this.options.max;
            f && (b = f.length, h = b), g && (c = g.length, h = c), b && c && (h = b >= c ? b : c), 
            0 > d && (i = Math.abs(d), d = +(d + i).toFixed(h), e = +(e + i).toFixed(h));
            var j, k = (e - d) / 100 * a + d, l = this.options.step.toString().split(".")[1];
            return l ? k = +k.toFixed(l.length) : (k /= this.options.step, k *= this.options.step, 
            k = +k.toFixed(0)), i && (k -= i), j = l ? +k.toFixed(l.length) : this.toFixed(k), 
            j < this.options.min ? j = this.options.min : j > this.options.max && (j = this.options.max), 
            j;
        },
        calcWithStep: function(a) {
            var b = Math.round(a / this.coords.p_step) * this.coords.p_step;
            return b > 100 && (b = 100), 100 === a && (b = 100), this.toFixed(b);
        },
        checkMinInterval: function(a, b, c) {
            var d, e, f = this.options;
            return f.min_interval ? (d = this.convertToValue(a), e = this.convertToValue(b), 
            "from" === c ? e - d < f.min_interval && (d = e - f.min_interval) : d - e < f.min_interval && (d = e + f.min_interval), 
            this.convertToPercent(d)) : a;
        },
        checkMaxInterval: function(a, b, c) {
            var d, e, f = this.options;
            return f.max_interval ? (d = this.convertToValue(a), e = this.convertToValue(b), 
            "from" === c ? e - d > f.max_interval && (d = e - f.max_interval) : d - e > f.max_interval && (d = e + f.max_interval), 
            this.convertToPercent(d)) : a;
        },
        checkDiapason: function(a, b, c) {
            var d = this.convertToValue(a), e = this.options;
            return "number" != typeof b && (b = e.min), "number" != typeof c && (c = e.max), 
            b > d && (d = b), d > c && (d = c), this.convertToPercent(d);
        },
        toFixed: function(a) {
            return a = a.toFixed(9), +a;
        },
        _prettify: function(a) {
            return this.options.prettify_enabled ? this.options.prettify && "function" == typeof this.options.prettify ? this.options.prettify(a) : this.prettify(a) : a;
        },
        prettify: function(a) {
            var b = a.toString();
            return b.replace(/(\d{1,3}(?=(?:\d\d\d)+(?!\d)))/g, "$1" + this.options.prettify_separator);
        },
        checkEdges: function(a, b) {
            return this.options.force_edges ? (0 > a ? a = 0 : a > 100 - b && (a = 100 - b), 
            this.toFixed(a)) : this.toFixed(a);
        },
        validate: function() {
            var a, b, c = this.options, d = this.result, e = c.values, f = e.length;
            if ("string" == typeof c.min && (c.min = +c.min), "string" == typeof c.max && (c.max = +c.max), 
            "string" == typeof c.from && (c.from = +c.from), "string" == typeof c.to && (c.to = +c.to), 
            "string" == typeof c.step && (c.step = +c.step), "string" == typeof c.from_min && (c.from_min = +c.from_min), 
            "string" == typeof c.from_max && (c.from_max = +c.from_max), "string" == typeof c.to_min && (c.to_min = +c.to_min), 
            "string" == typeof c.to_max && (c.to_max = +c.to_max), "string" == typeof c.keyboard_step && (c.keyboard_step = +c.keyboard_step), 
            "string" == typeof c.grid_num && (c.grid_num = +c.grid_num), c.max < c.min && (c.max = c.min), 
            f) for (c.p_values = [], c.min = 0, c.max = f - 1, c.step = 1, c.grid_num = c.max, 
            c.grid_snap = !0, b = 0; f > b; b++) a = +e[b], isNaN(a) ? a = e[b] : (e[b] = a, 
            a = this._prettify(a)), c.p_values.push(a);
            ("number" != typeof c.from || isNaN(c.from)) && (c.from = c.min), ("number" != typeof c.to || isNaN(c.from)) && (c.to = c.max), 
            "single" === c.type ? (c.from < c.min && (c.from = c.min), c.from > c.max && (c.from = c.max)) : ((c.from < c.min || c.from > c.max) && (c.from = c.min), 
            (c.to > c.max || c.to < c.min) && (c.to = c.max), c.from > c.to && (c.from = c.to)), 
            ("number" != typeof c.step || isNaN(c.step) || !c.step || c.step < 0) && (c.step = 1), 
            ("number" != typeof c.keyboard_step || isNaN(c.keyboard_step) || !c.keyboard_step || c.keyboard_step < 0) && (c.keyboard_step = 5), 
            "number" == typeof c.from_min && c.from < c.from_min && (c.from = c.from_min), "number" == typeof c.from_max && c.from > c.from_max && (c.from = c.from_max), 
            "number" == typeof c.to_min && c.to < c.to_min && (c.to = c.to_min), "number" == typeof c.to_max && c.from > c.to_max && (c.to = c.to_max), 
            d && (d.min !== c.min && (d.min = c.min), d.max !== c.max && (d.max = c.max), (d.from < d.min || d.from > d.max) && (d.from = c.from), 
            (d.to < d.min || d.to > d.max) && (d.to = c.to)), ("number" != typeof c.min_interval || isNaN(c.min_interval) || !c.min_interval || c.min_interval < 0) && (c.min_interval = 0), 
            ("number" != typeof c.max_interval || isNaN(c.max_interval) || !c.max_interval || c.max_interval < 0) && (c.max_interval = 0), 
            c.min_interval && c.min_interval > c.max - c.min && (c.min_interval = c.max - c.min), 
            c.max_interval && c.max_interval > c.max - c.min && (c.max_interval = c.max - c.min);
        },
        decorate: function(a, b) {
            var c = "", d = this.options;
            return d.prefix && (c += d.prefix), c += a, d.max_postfix && (d.values.length && a === d.p_values[d.max] ? (c += d.max_postfix, 
            d.postfix && (c += " ")) : b === d.max && (c += d.max_postfix, d.postfix && (c += " "))), 
            d.postfix && (c += d.postfix), c;
        },
        updateFrom: function() {
            this.result.from = this.options.from, this.result.from_percent = this.convertToPercent(this.result.from), 
            this.options.values && (this.result.from_value = this.options.values[this.result.from]);
        },
        updateTo: function() {
            this.result.to = this.options.to, this.result.to_percent = this.convertToPercent(this.result.to), 
            this.options.values && (this.result.to_value = this.options.values[this.result.to]);
        },
        updateResult: function() {
            this.result.min = this.options.min, this.result.max = this.options.max, this.updateFrom(), 
            this.updateTo();
        },
        appendGrid: function() {
            if (this.options.grid) {
                var a, b, c, d, e, f = this.options, g = f.max - f.min, h = f.grid_num, i = 0, j = 0, k = 4, l = 0, m = "";
                for (this.calcGridMargin(), f.grid_snap ? (h = g / f.step, i = this.toFixed(f.step / (g / 100))) : i = this.toFixed(100 / h), 
                h > 4 && (k = 3), h > 7 && (k = 2), h > 14 && (k = 1), h > 28 && (k = 0), a = 0; h + 1 > a; a++) {
                    for (c = k, j = this.toFixed(i * a), j > 100 && (j = 100, c -= 2, 0 > c && (c = 0)), 
                    this.coords.big[a] = j, d = (j - i * (a - 1)) / (c + 1), b = 1; c >= b && 0 !== j; b++) l = this.toFixed(j - d * b), 
                    m += '<span class="irs-grid-pol small" style="left: ' + l + '%"></span>';
                    m += '<span class="irs-grid-pol" style="left: ' + j + '%"></span>', e = this.convertToValue(j), 
                    e = f.values.length ? f.p_values[e] : this._prettify(e), m += '<span class="irs-grid-text js-grid-text-' + a + '" style="left: ' + j + '%">' + e + "</span>";
                }
                this.coords.big_num = Math.ceil(h + 1), this.$cache.cont.addClass("irs-with-grid"), 
                this.$cache.grid.html(m), this.cacheGridLabels();
            }
        },
        cacheGridLabels: function() {
            var a, b, c = this.coords.big_num;
            for (b = 0; c > b; b++) a = this.$cache.grid.find(".js-grid-text-" + b), this.$cache.grid_labels.push(a);
            this.calcGridLabels();
        },
        calcGridLabels: function() {
            var a, b, c = [], d = [], e = this.coords.big_num;
            for (a = 0; e > a; a++) this.coords.big_w[a] = this.$cache.grid_labels[a].outerWidth(!1), 
            this.coords.big_p[a] = this.toFixed(this.coords.big_w[a] / this.coords.w_rs * 100), 
            this.coords.big_x[a] = this.toFixed(this.coords.big_p[a] / 2), c[a] = this.toFixed(this.coords.big[a] - this.coords.big_x[a]), 
            d[a] = this.toFixed(c[a] + this.coords.big_p[a]);
            for (this.options.force_edges && (c[0] < -this.coords.grid_gap && (c[0] = -this.coords.grid_gap, 
            d[0] = this.toFixed(c[0] + this.coords.big_p[0]), this.coords.big_x[0] = this.coords.grid_gap), 
            d[e - 1] > 100 + this.coords.grid_gap && (d[e - 1] = 100 + this.coords.grid_gap, 
            c[e - 1] = this.toFixed(d[e - 1] - this.coords.big_p[e - 1]), this.coords.big_x[e - 1] = this.toFixed(this.coords.big_p[e - 1] - this.coords.grid_gap))), 
            this.calcGridCollision(2, c, d), this.calcGridCollision(4, c, d), a = 0; e > a; a++) b = this.$cache.grid_labels[a][0], 
            b.style.marginLeft = -this.coords.big_x[a] + "%";
        },
        calcGridCollision: function(a, b, c) {
            var d, e, f, g = this.coords.big_num;
            for (d = 0; g > d && (e = d + a / 2, !(e >= g)); d += a) f = this.$cache.grid_labels[e][0], 
            c[d] <= b[e] ? f.style.visibility = "visible" : f.style.visibility = "hidden";
        },
        calcGridMargin: function() {
            this.options.grid_margin && (this.coords.w_rs = this.$cache.rs.outerWidth(!1), this.coords.w_rs && ("single" === this.options.type ? this.coords.w_handle = this.$cache.s_single.outerWidth(!1) : this.coords.w_handle = this.$cache.s_from.outerWidth(!1), 
            this.coords.p_handle = this.toFixed(this.coords.w_handle / this.coords.w_rs * 100), 
            this.coords.grid_gap = this.toFixed(this.coords.p_handle / 2 - .1), this.$cache.grid[0].style.width = this.toFixed(100 - this.coords.p_handle) + "%", 
            this.$cache.grid[0].style.left = this.coords.grid_gap + "%"));
        },
        update: function(b) {
            this.input && (this.is_update = !0, this.options.from = this.result.from, this.options.to = this.result.to, 
            this.options = a.extend(this.options, b), this.validate(), this.updateResult(b), 
            this.toggleInput(), this.remove(), this.init(!0));
        },
        reset: function() {
            this.input && (this.updateResult(), this.update());
        },
        destroy: function() {
            this.input && (this.toggleInput(), this.$cache.input.prop("readonly", !1), a.data(this.input, "ionRangeSlider", null), 
            this.remove(), this.input = null, this.options = null);
        }
    }, a.fn.ionRangeSlider = function(b) {
        return this.each(function() {
            a.data(this, "ionRangeSlider") || a.data(this, "ionRangeSlider", new l(this, b, f++));
        });
    }, function() {
        for (var a = 0, b = [ "ms", "moz", "webkit", "o" ], d = 0; d < b.length && !c.requestAnimationFrame; ++d) c.requestAnimationFrame = c[b[d] + "RequestAnimationFrame"], 
        c.cancelAnimationFrame = c[b[d] + "CancelAnimationFrame"] || c[b[d] + "CancelRequestAnimationFrame"];
        c.requestAnimationFrame || (c.requestAnimationFrame = function(b, d) {
            var e = new Date().getTime(), f = Math.max(0, 16 - (e - a)), g = c.setTimeout(function() {
                b(e + f);
            }, f);
            return a = e + f, g;
        }), c.cancelAnimationFrame || (c.cancelAnimationFrame = function(a) {
            clearTimeout(a);
        });
    }();
}), function(a, b) {
    a.easing.jswing = a.easing.swing, a.extend(a.easing, {
        def: "easeOutQuad",
        swing: function(b, c, d, e, f) {
            return a.easing[a.easing.def](b, c, d, e, f);
        },
        easeInQuad: function(a, b, c, d, e) {
            return d * (b /= e) * b + c;
        },
        easeOutQuad: function(a, b, c, d, e) {
            return -d * (b /= e) * (b - 2) + c;
        },
        easeInOutQuad: function(a, b, c, d, e) {
            return (b /= e / 2) < 1 ? d / 2 * b * b + c : -d / 2 * (--b * (b - 2) - 1) + c;
        },
        easeInCubic: function(a, b, c, d, e) {
            return d * (b /= e) * b * b + c;
        },
        easeOutCubic: function(a, b, c, d, e) {
            return d * ((b = b / e - 1) * b * b + 1) + c;
        },
        easeInOutCubic: function(a, b, c, d, e) {
            return (b /= e / 2) < 1 ? d / 2 * b * b * b + c : d / 2 * ((b -= 2) * b * b + 2) + c;
        },
        easeInQuart: function(a, b, c, d, e) {
            return d * (b /= e) * b * b * b + c;
        },
        easeOutQuart: function(a, b, c, d, e) {
            return -d * ((b = b / e - 1) * b * b * b - 1) + c;
        },
        easeInOutQuart: function(a, b, c, d, e) {
            return (b /= e / 2) < 1 ? d / 2 * b * b * b * b + c : -d / 2 * ((b -= 2) * b * b * b - 2) + c;
        },
        easeInQuint: function(a, b, c, d, e) {
            return d * (b /= e) * b * b * b * b + c;
        },
        easeOutQuint: function(a, b, c, d, e) {
            return d * ((b = b / e - 1) * b * b * b * b + 1) + c;
        },
        easeInOutQuint: function(a, b, c, d, e) {
            return (b /= e / 2) < 1 ? d / 2 * b * b * b * b * b + c : d / 2 * ((b -= 2) * b * b * b * b + 2) + c;
        },
        easeInSine: function(a, b, c, d, e) {
            return -d * Math.cos(b / e * (Math.PI / 2)) + d + c;
        },
        easeOutSine: function(a, b, c, d, e) {
            return d * Math.sin(b / e * (Math.PI / 2)) + c;
        },
        easeInOutSine: function(a, b, c, d, e) {
            return -d / 2 * (Math.cos(Math.PI * b / e) - 1) + c;
        },
        easeInExpo: function(a, b, c, d, e) {
            return 0 == b ? c : d * Math.pow(2, 10 * (b / e - 1)) + c;
        },
        easeOutExpo: function(a, b, c, d, e) {
            return b == e ? c + d : d * (-Math.pow(2, -10 * b / e) + 1) + c;
        },
        easeInOutExpo: function(a, b, c, d, e) {
            return 0 == b ? c : b == e ? c + d : (b /= e / 2) < 1 ? d / 2 * Math.pow(2, 10 * (b - 1)) + c : d / 2 * (-Math.pow(2, -10 * --b) + 2) + c;
        },
        easeInCirc: function(a, b, c, d, e) {
            return -d * (Math.sqrt(1 - (b /= e) * b) - 1) + c;
        },
        easeOutCirc: function(a, b, c, d, e) {
            return d * Math.sqrt(1 - (b = b / e - 1) * b) + c;
        },
        easeInOutCirc: function(a, b, c, d, e) {
            return (b /= e / 2) < 1 ? -d / 2 * (Math.sqrt(1 - b * b) - 1) + c : d / 2 * (Math.sqrt(1 - (b -= 2) * b) + 1) + c;
        },
        easeInElastic: function(a, b, c, d, e) {
            var f = 1.70158, g = 0, h = d;
            if (0 == b) return c;
            if (1 == (b /= e)) return c + d;
            if (g || (g = .3 * e), h < Math.abs(d)) {
                h = d;
                var f = g / 4;
            } else var f = g / (2 * Math.PI) * Math.asin(d / h);
            return -(h * Math.pow(2, 10 * (b -= 1)) * Math.sin((b * e - f) * (2 * Math.PI) / g)) + c;
        },
        easeOutElastic: function(a, b, c, d, e) {
            var f = 1.70158, g = 0, h = d;
            if (0 == b) return c;
            if (1 == (b /= e)) return c + d;
            if (g || (g = .3 * e), h < Math.abs(d)) {
                h = d;
                var f = g / 4;
            } else var f = g / (2 * Math.PI) * Math.asin(d / h);
            return h * Math.pow(2, -10 * b) * Math.sin((b * e - f) * (2 * Math.PI) / g) + d + c;
        },
        easeInOutElastic: function(a, b, c, d, e) {
            var f = 1.70158, g = 0, h = d;
            if (0 == b) return c;
            if (2 == (b /= e / 2)) return c + d;
            if (g || (g = e * (.3 * 1.5)), h < Math.abs(d)) {
                h = d;
                var f = g / 4;
            } else var f = g / (2 * Math.PI) * Math.asin(d / h);
            return 1 > b ? -.5 * (h * Math.pow(2, 10 * (b -= 1)) * Math.sin((b * e - f) * (2 * Math.PI) / g)) + c : h * Math.pow(2, -10 * (b -= 1)) * Math.sin((b * e - f) * (2 * Math.PI) / g) * .5 + d + c;
        },
        easeInBack: function(a, c, d, e, f, g) {
            return g == b && (g = 1.70158), e * (c /= f) * c * ((g + 1) * c - g) + d;
        },
        easeOutBack: function(a, c, d, e, f, g) {
            return g == b && (g = 1.70158), e * ((c = c / f - 1) * c * ((g + 1) * c + g) + 1) + d;
        },
        easeInOutBack: function(a, c, d, e, f, g) {
            return g == b && (g = 1.70158), (c /= f / 2) < 1 ? e / 2 * (c * c * (((g *= 1.525) + 1) * c - g)) + d : e / 2 * ((c -= 2) * c * (((g *= 1.525) + 1) * c + g) + 2) + d;
        },
        easeInBounce: function(b, c, d, e, f) {
            return e - a.easing.easeOutBounce(b, f - c, 0, e, f) + d;
        },
        easeOutBounce: function(a, b, c, d, e) {
            return (b /= e) < 1 / 2.75 ? d * (7.5625 * b * b) + c : 2 / 2.75 > b ? d * (7.5625 * (b -= 1.5 / 2.75) * b + .75) + c : 2.5 / 2.75 > b ? d * (7.5625 * (b -= 2.25 / 2.75) * b + .9375) + c : d * (7.5625 * (b -= 2.625 / 2.75) * b + .984375) + c;
        },
        easeInOutBounce: function(b, c, d, e, f) {
            return f / 2 > c ? .5 * a.easing.easeInBounce(b, 2 * c, 0, e, f) + d : .5 * a.easing.easeOutBounce(b, 2 * c - f, 0, e, f) + .5 * e + d;
        }
    });
}(jQuery), function(a) {
    a.nhancedMenu = function(b) {
        function c(b, c) {
            var d = !1;
            return "#" == b[0] ? (0 != a(c.target).parents(b).length || a(c.target).attr("id") == b.substring(1)) && (d = !0) : (0 != a(c.target).parents(b).length || 1 == a(c.target).hasClass(b.substring(1))) && (d = !0), 
            d;
        }
        function d() {
            function b() {
                a(n.trigger).removeClass(n.trigger_active_class), a(n.area).removeClass(n.area_class), 
                a(n.target).collapse("hide"), g(!1), n.onAreaClick.call(a(n.trigger));
            }
            if (n.anywhereClose) {
                var d = n.anywhereCloseBlockingElement;
                "target" == n.anywhereCloseBlockingElement && (d = n.target), a("body").on(o, function(a) {
                    e() <= n.maxRes && (c(d, a) || c(n.trigger, a) || (n.anywhereCloseBlockingMaxRes ? e() <= n.anywhereCloseBlockingMaxRes && b() : b()));
                });
            }
        }
        function e() {
            function a() {
                var a = window, b = "inner";
                return "innerWidth" in window || (b = "client", a = document.documentElement || document.body), 
                {
                    width: a[b + "Width"],
                    height: a[b + "Height"]
                };
            }
            return a().width;
        }
        function f(a, b) {
            1 == a && console.log(b);
        }
        function g(b) {
            n.cookie && (0 == b ? a.cookie(n.cookieName, n.cookieValFalse, {
                domain: n.cookieDomain,
                path: "/"
            }) : a.cookie(n.cookieName, n.cookieValTrue, {
                domain: n.cookieDomain,
                path: "/"
            }));
        }
        function h() {
            a(n.target).on("hidden.bs.collapse", function() {
                f(n.debug, "Target - add class:" + n.target_hidden_class);
            }), a(n.target).on("show.bs.collapse", function() {
                f(n.debug, "Target - remove class:" + n.target_hidden_class);
            });
        }
        function i() {
            a(n.trigger).hasClass(n.trigger_active_class) ? (a(n.trigger).removeClass(n.trigger_active_class).addClass("collapsed"), 
            a(n.target).collapse("hide").attr("aria-expanded", "false").css("height", "0"), 
            a(n.area).removeClass(n.area_class), g(!1), n.onTriggerClickClose.call(n)) : (a(n.target).collapse("show"), 
            a(n.trigger).addClass(n.trigger_active_class).removeClass("collapsed"), a(n.area).addClass(n.area_class), 
            g(!0), n.onTriggerClickOpen.call(n));
        }
        function j() {
            n.defaultOpen && (n.defaultOpenMinimalRes ? e() >= n.defaultOpenMinimalRes ? (a(n.target).collapse("show"), 
            a(n.trigger).addClass(n.trigger_active_class), a(n.area).addClass(n.area_class), 
            g(!0)) : (a(n.target).collapse("hide"), a(n.trigger).removeClass(n.trigger_active_class), 
            a(n.area).removeClass(n.area_class), g(!1)) : (a(n.target).collapse("show"), a(n.trigger).addClass(n.trigger_active_class), 
            a(n.area).addClass(n.area_class), g(!0)));
        }
        function k() {
            n.maxRes ? e() < n.maxRes ? a(n.target).hasClass(n.collapse_class) || (a(n.target).addClass(n.collapse_class).attr("aria-expanded", "false").css("height", "0"), 
            a(n.trigger).removeClass("hidden")) : a(n.trigger).addClass(n.target_hidden_class) : a(n.target).hasClass(n.collapse_class) || a(n.target).addClass(n.collapse_class);
        }
        function l() {
            a(n.target).removeClass(n.trigger_active_class), a(n.area).removeClass(n.area_class), 
            a(n.target).removeClass(n.collapse_class).removeClass(n.ex_class3).removeAttr("aria-expanded").css("height", ""), 
            a(n.trigger).removeClass(n.trigger_active_class);
        }
        var m = {
            trigger: "#nav-trigger",
            target: "#main-nav",
            anywhereClose: !0,
            anywhereCloseBlockingElement: "target",
            anywhereCloseBlockingMaxRes: !1,
            area: "body",
            area_class: "main-nav-open",
            trigger_active_class: "active",
            target_hidden_class: "hidden",
            collapse_class: "collapse",
            ex_class3: "in",
            maxRes: !1,
            debug: !1,
            preventD: !0,
            defaultOpen: !1,
            defaultOpenMinimalRes: 1040,
            cookie: !1,
            cookieName: "yourCookieName",
            cookieValTrue: "open",
            cookieValFalse: "closed",
            cookieDomain: !1,
            onTriggerClick: function() {},
            onTriggerClickOpen: function() {},
            onTriggerClickClose: function() {},
            onAreaClick: function() {}
        }, n = a.extend(!0, {}, m, b), o = "click";
        navigator.userAgent.match(/Mobi/) && navigator.userAgent.match(/(iPod|iPhone|iPad)/) && (o = "touchend"), 
        n.cookie && a.cookie(n.cookieName) == n.cookieValFalse && (a(n.trigger).removeClass(n.trigger_active_class), 
        a(n.area).removeClass(n.area_class)), (a(n.area).hasClass(n.area_class) || a(n.trigger).hasClass(n.trigger_active_class)) && (a(n.trigger).addClass(n.trigger_active_class), 
        a(n.area).addClass(n.area_class)), n.target && (n.maxRes ? n.maxRes < e() && h() : h()), 
        a(n.trigger).on(o, function(b) {
            n.preventD && b.preventDefault(), n.maxRes ? e() < n.maxRes && i() : i(), n.onTriggerClick.call(a(n.trigger));
        }), k(), a.cookie(n.cookieName) == n.cookieValFalse || j(), d(), a(window).resize(function() {
            n.maxRes && a(window).width() >= n.maxRes && l(), k();
        });
    };
}(jQuery), function(a) {
    jQuery.detectIE = function() {
        var a = window.navigator.userAgent, b = a.indexOf("MSIE ");
        if (b > 0) return parseInt(a.substring(b + 5, a.indexOf(".", b)), 10);
        var c = a.indexOf("Trident/");
        if (c > 0) {
            var d = a.indexOf("rv:");
            return parseInt(a.substring(d + 3, a.indexOf(".", d)), 10);
        }
        var e = a.indexOf("Edge/");
        return e > 0 ? parseInt(a.substring(e + 5, a.indexOf(".", e)), 10) : !1;
    }, jQuery.windowsPhone8_support = function() {
        if (navigator.userAgent.match(/IEMobile\/10\.0/)) {
            var a = document.createElement("style");
            a.appendChild(document.createTextNode("@-ms-viewport{width:auto!important}")), document.getElementsByTagName("head")[0].appendChild(a);
        }
    }, jQuery.helpers = function() {
        a.windowsPhone8_support(), a.detectIE() && a("html").addClass("ie ie-" + a.detectIE()), 
        console.log("is mobile? " + navigator.userAgent.match(/Mobi/)), navigator.userAgent.match(/Mobi/) && a("html").addClass("user-agent-mobile");
    }, jQuery.IOSDoubleTapFix = function(b) {
        function c(a) {
            var b = a, c = b.attr("href");
            window.location = c;
        }
        var d = {
            exclude: !1
        }, e = a.extend(d, b);
        navigator.userAgent.match(/Mobi/) && navigator.userAgent.match(/(iPod|iPhone|iPad)/) && (e.exclude ? a("a").not(e.exclude).on("click touchend", function(b) {
            var d = a(this);
            c(d);
        }) : a("a").on("click touchend", function(b) {
            var d = a(this);
            c(d);
        }));
    };
}(jQuery), function(a) {
    "function" == typeof define && define.amd ? define([ "jquery" ], a) : "object" == typeof exports ? module.exports = a(require("jquery")) : a(jQuery);
}(function(a) {
    function b(a) {
        return h.raw ? a : encodeURIComponent(a);
    }
    function c(a) {
        return h.raw ? a : decodeURIComponent(a);
    }
    function d(a) {
        return b(h.json ? JSON.stringify(a) : String(a));
    }
    function e(a) {
        0 === a.indexOf('"') && (a = a.slice(1, -1).replace(/\\"/g, '"').replace(/\\\\/g, "\\"));
        try {
            return a = decodeURIComponent(a.replace(g, " ")), h.json ? JSON.parse(a) : a;
        } catch (b) {}
    }
    function f(b, c) {
        var d = h.raw ? b : e(b);
        return a.isFunction(c) ? c(d) : d;
    }
    var g = /\+/g, h = a.cookie = function(e, g, i) {
        if (arguments.length > 1 && !a.isFunction(g)) {
            if (i = a.extend({}, h.defaults, i), "number" == typeof i.expires) {
                var j = i.expires, k = i.expires = new Date();
                k.setMilliseconds(k.getMilliseconds() + 864e5 * j);
            }
            return document.cookie = [ b(e), "=", d(g), i.expires ? "; expires=" + i.expires.toUTCString() : "", i.path ? "; path=" + i.path : "", i.domain ? "; domain=" + i.domain : "", i.secure ? "; secure" : "" ].join("");
        }
        for (var l = e ? void 0 : {}, m = document.cookie ? document.cookie.split("; ") : [], n = 0, o = m.length; o > n; n++) {
            var p = m[n].split("="), q = c(p.shift()), r = p.join("=");
            if (e === q) {
                l = f(r, g);
                break;
            }
            e || void 0 === (r = f(r)) || (l[q] = r);
        }
        return l;
    };
    h.defaults = {}, a.removeCookie = function(b, c) {
        return a.cookie(b, "", a.extend({}, c, {
            expires: -1
        })), !a.cookie(b);
    };
}), function(a) {
    jQuery.modalWindows = function(b) {
        function c(a) {
            a = a || window.event, a.preventDefault && a.preventDefault(), a.returnValue = !1;
        }
        function d(a) {
            return l[a.keyCode] ? (c(a), !1) : void 0;
        }
        function e() {
            window.addEventListener && window.addEventListener("DOMMouseScroll", c, !1), window.onwheel = c, 
            window.onmousewheel = document.onmousewheel = c, window.ontouchmove = c, document.onkeydown = d;
        }
        function f() {
            window.removeEventListener && window.removeEventListener("DOMMouseScroll", c, !1), 
            window.onmousewheel = document.onmousewheel = null, window.onwheel = null, window.ontouchmove = null, 
            document.onkeydown = null;
        }
        function g() {
            k.bodyClass && a("body").addClass(k.bodyClass), a(k.target).modal("show"), e(), 
            k.nh_modalShow.call(k);
        }
        function h() {
            a(k.trigger).click(function(a) {
                a.preventDefault(), g(), k.nh_modalTriggerClick.call(k);
            });
        }
        function i() {
            k.defaultOpen && g();
        }
        var j = {
            target: ".modal",
            trigger: "[data-toggle-modal]",
            defaultOpen: !1,
            bodyClass: "modal-open",
            nh_modalShow: function() {},
            nh_modalHide: function() {},
            nh_modalTriggerClick: function() {}
        }, k = a.extend(!0, {}, j, b), l = {
            37: 1,
            38: 1,
            39: 1,
            40: 1
        };
        i(), h(), a(k.target).on("hidden.bs.modal", function(a) {
            f(), k.nh_modalHide.call(k);
        }), k.bodyClass && a(k.target).on("hidden.bs.modal", function(b) {
            a("body").removeClass(k.bodyClass);
        });
    };
}(jQuery), function(a, b, c, d) {
    a.fn.doubleTapToGo = function(d) {
        return "ontouchstart" in b || navigator.msMaxTouchPoints || navigator.userAgent.toLowerCase().match(/windows phone os 7/i) ? (this.each(function() {
            var b = !1;
            a(this).on("click", function(c) {
                var d = a(this);
                d[0] != b[0] && (c.preventDefault(), b = d);
            }), a(c).on("click touchstart MSPointerDown", function(c) {
                for (var d = !0, e = a(c.target).parents(), f = 0; f < e.length; f++) e[f] == b[0] && (d = !1);
                d && (b = !1);
            });
        }), this) : !1;
    };
}(jQuery, window, document), function() {
    var a = jQuery, b = function() {
        function a() {
            this.fadeDuration = 500, this.fitImagesInViewport = !0, this.resizeDuration = 700, 
            this.positionFromTop = 50, this.showImageNumberLabel = !0, this.alwaysShowNavOnTouchDevices = !1, 
            this.wrapAround = !1;
        }
        return a.prototype.albumLabel = function(a, b) {
            return "Image " + a + " of " + b;
        }, a;
    }(), c = function() {
        function b(a) {
            this.options = a, this.album = [], this.currentImageIndex = void 0, this.init();
        }
        return b.prototype.init = function() {
            this.enable(), this.build();
        }, b.prototype.enable = function() {
            var b = this;
            a("body").on("click", "a[rel^=lightbox], area[rel^=lightbox], a[data-lightbox], area[data-lightbox]", function(c) {
                return b.start(a(c.currentTarget)), !1;
            });
        }, b.prototype.build = function() {
            var b = this;
            a("<div id='lightboxOverlay' class='lightboxOverlay'></div><div id='lightbox' class='lightbox'><div class='lb-outerContainer'><div class='lb-container'><img class='lb-image' src='' /><div class='lb-nav'><a class='lb-prev' href='' ></a><a class='lb-next' href='' ></a></div><div class='lb-loader'><a class='lb-cancel'></a></div></div></div><div class='lb-dataContainer'><div class='lb-data'><div class='lb-details'><span class='lb-caption'></span><span class='lb-number'></span></div><div class='lb-closeContainer'><a class='lb-close'></a></div></div></div></div>").appendTo(a("body")), 
            this.$lightbox = a("#lightbox"), this.$overlay = a("#lightboxOverlay"), this.$outerContainer = this.$lightbox.find(".lb-outerContainer"), 
            this.$container = this.$lightbox.find(".lb-container"), this.containerTopPadding = parseInt(this.$container.css("padding-top"), 10), 
            this.containerRightPadding = parseInt(this.$container.css("padding-right"), 10), 
            this.containerBottomPadding = parseInt(this.$container.css("padding-bottom"), 10), 
            this.containerLeftPadding = parseInt(this.$container.css("padding-left"), 10), this.$overlay.hide().on("click", function() {
                return b.end(), !1;
            }), this.$lightbox.hide().on("click", function(c) {
                return "lightbox" === a(c.target).attr("id") && b.end(), !1;
            }), this.$outerContainer.on("click", function(c) {
                return "lightbox" === a(c.target).attr("id") && b.end(), !1;
            }), this.$lightbox.find(".lb-prev").on("click", function() {
                return 0 === b.currentImageIndex ? b.changeImage(b.album.length - 1) : b.changeImage(b.currentImageIndex - 1), 
                !1;
            }), this.$lightbox.find(".lb-next").on("click", function() {
                return b.currentImageIndex === b.album.length - 1 ? b.changeImage(0) : b.changeImage(b.currentImageIndex + 1), 
                !1;
            }), this.$lightbox.find(".lb-loader, .lb-close").on("click", function() {
                return b.end(), !1;
            });
        }, b.prototype.start = function(b) {
            function c(a) {
                d.album.push({
                    link: a.attr("href"),
                    title: a.attr("data-title") || a.attr("title")
                });
            }
            var d = this, e = a(window);
            e.on("resize", a.proxy(this.sizeOverlay, this)), a("select, object, embed").css({
                visibility: "hidden"
            }), this.sizeOverlay(), this.album = [];
            var f, g = 0, h = b.attr("data-lightbox");
            if (h) {
                f = a(b.prop("tagName") + '[data-lightbox="' + h + '"]');
                for (var i = 0; i < f.length; i = ++i) c(a(f[i])), f[i] === b[0] && (g = i);
            } else if ("lightbox" === b.attr("rel")) c(b); else {
                f = a(b.prop("tagName") + '[rel="' + b.attr("rel") + '"]');
                for (var j = 0; j < f.length; j = ++j) c(a(f[j])), f[j] === b[0] && (g = j);
            }
            var k = e.scrollTop() + this.options.positionFromTop, l = e.scrollLeft();
            this.$lightbox.css({
                top: k + "px",
                left: l + "px"
            }).fadeIn(this.options.fadeDuration), this.changeImage(g);
        }, b.prototype.changeImage = function(b) {
            var c = this;
            this.disableKeyboardNav();
            var d = this.$lightbox.find(".lb-image");
            this.$overlay.fadeIn(this.options.fadeDuration), a(".lb-loader").fadeIn("slow"), 
            this.$lightbox.find(".lb-image, .lb-nav, .lb-prev, .lb-next, .lb-dataContainer, .lb-numbers, .lb-caption").hide(), 
            this.$outerContainer.addClass("animating");
            var e = new Image();
            e.onload = function() {
                var f, g, h, i, j, k, l;
                d.attr("src", c.album[b].link), f = a(e), d.width(e.width), d.height(e.height), 
                c.options.fitImagesInViewport && (l = a(window).width(), k = a(window).height(), 
                j = l - c.containerLeftPadding - c.containerRightPadding - 20, i = k - c.containerTopPadding - c.containerBottomPadding - 120, 
                (e.width > j || e.height > i) && (e.width / j > e.height / i ? (h = j, g = parseInt(e.height / (e.width / h), 10), 
                d.width(h), d.height(g)) : (g = i, h = parseInt(e.width / (e.height / g), 10), d.width(h), 
                d.height(g)))), c.sizeContainer(d.width(), d.height());
            }, e.src = this.album[b].link, this.currentImageIndex = b;
        }, b.prototype.sizeOverlay = function() {
            this.$overlay.width(a(window).width()).height(a(document).height());
        }, b.prototype.sizeContainer = function(a, b) {
            function c() {
                d.$lightbox.find(".lb-dataContainer").width(g), d.$lightbox.find(".lb-prevLink").height(h), 
                d.$lightbox.find(".lb-nextLink").height(h), d.showImage();
            }
            var d = this, e = this.$outerContainer.outerWidth(), f = this.$outerContainer.outerHeight(), g = a + this.containerLeftPadding + this.containerRightPadding, h = b + this.containerTopPadding + this.containerBottomPadding;
            e !== g || f !== h ? this.$outerContainer.animate({
                width: g,
                height: h
            }, this.options.resizeDuration, "swing", function() {
                c();
            }) : c();
        }, b.prototype.showImage = function() {
            this.$lightbox.find(".lb-loader").hide(), this.$lightbox.find(".lb-image").fadeIn("slow"), 
            this.updateNav(), this.updateDetails(), this.preloadNeighboringImages(), this.enableKeyboardNav();
        }, b.prototype.updateNav = function() {
            var a = !1;
            try {
                document.createEvent("TouchEvent"), a = this.options.alwaysShowNavOnTouchDevices ? !0 : !1;
            } catch (b) {}
            this.$lightbox.find(".lb-nav").show(), this.album.length > 1 && (this.options.wrapAround ? (a && this.$lightbox.find(".lb-prev, .lb-next").css("opacity", "1"), 
            this.$lightbox.find(".lb-prev, .lb-next").show()) : (this.currentImageIndex > 0 && (this.$lightbox.find(".lb-prev").show(), 
            a && this.$lightbox.find(".lb-prev").css("opacity", "1")), this.currentImageIndex < this.album.length - 1 && (this.$lightbox.find(".lb-next").show(), 
            a && this.$lightbox.find(".lb-next").css("opacity", "1"))));
        }, b.prototype.updateDetails = function() {
            var b = this;
            "undefined" != typeof this.album[this.currentImageIndex].title && "" !== this.album[this.currentImageIndex].title && this.$lightbox.find(".lb-caption").html(this.album[this.currentImageIndex].title).fadeIn("fast").find("a").on("click", function(b) {
                location.href = a(this).attr("href");
            }), this.album.length > 1 && this.options.showImageNumberLabel ? this.$lightbox.find(".lb-number").text(this.options.albumLabel(this.currentImageIndex + 1, this.album.length)).fadeIn("fast") : this.$lightbox.find(".lb-number").hide(), 
            this.$outerContainer.removeClass("animating"), this.$lightbox.find(".lb-dataContainer").fadeIn(this.options.resizeDuration, function() {
                return b.sizeOverlay();
            });
        }, b.prototype.preloadNeighboringImages = function() {
            if (this.album.length > this.currentImageIndex + 1) {
                var a = new Image();
                a.src = this.album[this.currentImageIndex + 1].link;
            }
            if (this.currentImageIndex > 0) {
                var b = new Image();
                b.src = this.album[this.currentImageIndex - 1].link;
            }
        }, b.prototype.enableKeyboardNav = function() {
            a(document).on("keyup.keyboard", a.proxy(this.keyboardAction, this));
        }, b.prototype.disableKeyboardNav = function() {
            a(document).off(".keyboard");
        }, b.prototype.keyboardAction = function(a) {
            var b = 27, c = 37, d = 39, e = a.keyCode, f = String.fromCharCode(e).toLowerCase();
            e === b || f.match(/x|o|c/) ? this.end() : "p" === f || e === c ? 0 !== this.currentImageIndex ? this.changeImage(this.currentImageIndex - 1) : this.options.wrapAround && this.album.length > 1 && this.changeImage(this.album.length - 1) : ("n" === f || e === d) && (this.currentImageIndex !== this.album.length - 1 ? this.changeImage(this.currentImageIndex + 1) : this.options.wrapAround && this.album.length > 1 && this.changeImage(0));
        }, b.prototype.end = function() {
            this.disableKeyboardNav(), a(window).off("resize", this.sizeOverlay), this.$lightbox.fadeOut(this.options.fadeDuration), 
            this.$overlay.fadeOut(this.options.fadeDuration), a("select, object, embed").css({
                visibility: "visible"
            });
        }, b;
    }();
    a(function() {
        var a = new b();
        new c(a);
    });
}.call(this), function(a) {
    "function" == typeof define && define.amd ? define([ "jquery" ], a) : "object" == typeof exports ? module.exports = a : a(jQuery);
}(function(a) {
    function b(b) {
        var g = b || window.event, h = i.call(arguments, 1), j = 0, l = 0, m = 0, n = 0, o = 0, p = 0;
        if (b = a.event.fix(g), b.type = "mousewheel", "detail" in g && (m = -1 * g.detail), 
        "wheelDelta" in g && (m = g.wheelDelta), "wheelDeltaY" in g && (m = g.wheelDeltaY), 
        "wheelDeltaX" in g && (l = -1 * g.wheelDeltaX), "axis" in g && g.axis === g.HORIZONTAL_AXIS && (l = -1 * m, 
        m = 0), j = 0 === m ? l : m, "deltaY" in g && (m = -1 * g.deltaY, j = m), "deltaX" in g && (l = g.deltaX, 
        0 === m && (j = -1 * l)), 0 !== m || 0 !== l) {
            if (1 === g.deltaMode) {
                var q = a.data(this, "mousewheel-line-height");
                j *= q, m *= q, l *= q;
            } else if (2 === g.deltaMode) {
                var r = a.data(this, "mousewheel-page-height");
                j *= r, m *= r, l *= r;
            }
            if (n = Math.max(Math.abs(m), Math.abs(l)), (!f || f > n) && (f = n, d(g, n) && (f /= 40)), 
            d(g, n) && (j /= 40, l /= 40, m /= 40), j = Math[j >= 1 ? "floor" : "ceil"](j / f), 
            l = Math[l >= 1 ? "floor" : "ceil"](l / f), m = Math[m >= 1 ? "floor" : "ceil"](m / f), 
            k.settings.normalizeOffset && this.getBoundingClientRect) {
                var s = this.getBoundingClientRect();
                o = b.clientX - s.left, p = b.clientY - s.top;
            }
            return b.deltaX = l, b.deltaY = m, b.deltaFactor = f, b.offsetX = o, b.offsetY = p, 
            b.deltaMode = 0, h.unshift(b, j, l, m), e && clearTimeout(e), e = setTimeout(c, 200), 
            (a.event.dispatch || a.event.handle).apply(this, h);
        }
    }
    function c() {
        f = null;
    }
    function d(a, b) {
        return k.settings.adjustOldDeltas && "mousewheel" === a.type && b % 120 === 0;
    }
    var e, f, g = [ "wheel", "mousewheel", "DOMMouseScroll", "MozMousePixelScroll" ], h = "onwheel" in document || document.documentMode >= 9 ? [ "wheel" ] : [ "mousewheel", "DomMouseScroll", "MozMousePixelScroll" ], i = Array.prototype.slice;
    if (a.event.fixHooks) for (var j = g.length; j; ) a.event.fixHooks[g[--j]] = a.event.mouseHooks;
    var k = a.event.special.mousewheel = {
        version: "3.1.12",
        setup: function() {
            if (this.addEventListener) for (var c = h.length; c; ) this.addEventListener(h[--c], b, !1); else this.onmousewheel = b;
            a.data(this, "mousewheel-line-height", k.getLineHeight(this)), a.data(this, "mousewheel-page-height", k.getPageHeight(this));
        },
        teardown: function() {
            if (this.removeEventListener) for (var c = h.length; c; ) this.removeEventListener(h[--c], b, !1); else this.onmousewheel = null;
            a.removeData(this, "mousewheel-line-height"), a.removeData(this, "mousewheel-page-height");
        },
        getLineHeight: function(b) {
            var c = a(b), d = c["offsetParent" in a.fn ? "offsetParent" : "parent"]();
            return d.length || (d = a("body")), parseInt(d.css("fontSize"), 10) || parseInt(c.css("fontSize"), 10) || 16;
        },
        getPageHeight: function(b) {
            return a(b).height();
        },
        settings: {
            adjustOldDeltas: !0,
            normalizeOffset: !0
        }
    };
    a.fn.extend({
        mousewheel: function(a) {
            return a ? this.bind("mousewheel", a) : this.trigger("mousewheel");
        },
        unmousewheel: function(a) {
            return this.unbind("mousewheel", a);
        }
    });
}), function(a) {
    "use strict";
    function b(b) {
        var c = [ {
            re: /[\xC0-\xC6]/g,
            ch: "A"
        }, {
            re: /[\xE0-\xE6]/g,
            ch: "a"
        }, {
            re: /[\xC8-\xCB]/g,
            ch: "E"
        }, {
            re: /[\xE8-\xEB]/g,
            ch: "e"
        }, {
            re: /[\xCC-\xCF]/g,
            ch: "I"
        }, {
            re: /[\xEC-\xEF]/g,
            ch: "i"
        }, {
            re: /[\xD2-\xD6]/g,
            ch: "O"
        }, {
            re: /[\xF2-\xF6]/g,
            ch: "o"
        }, {
            re: /[\xD9-\xDC]/g,
            ch: "U"
        }, {
            re: /[\xF9-\xFC]/g,
            ch: "u"
        }, {
            re: /[\xC7-\xE7]/g,
            ch: "c"
        }, {
            re: /[\xD1]/g,
            ch: "N"
        }, {
            re: /[\xF1]/g,
            ch: "n"
        } ];
        return a.each(c, function() {
            b = b.replace(this.re, this.ch);
        }), b;
    }
    function c(a) {
        var b = {
            "&": "&amp;",
            "<": "&lt;",
            ">": "&gt;",
            '"': "&quot;",
            "'": "&#x27;",
            "`": "&#x60;"
        }, c = "(?:" + Object.keys(b).join("|") + ")", d = new RegExp(c), e = new RegExp(c, "g"), f = null == a ? "" : "" + a;
        return d.test(f) ? f.replace(e, function(a) {
            return b[a];
        }) : f;
    }
    function d(b, c) {
        var d = arguments, f = b, g = c;
        [].shift.apply(d);
        var h, i = this.each(function() {
            var b = a(this);
            if (b.is("select")) {
                var c = b.data("selectpicker"), i = "object" == typeof f && f;
                if (c) {
                    if (i) for (var j in i) i.hasOwnProperty(j) && (c.options[j] = i[j]);
                } else {
                    var k = a.extend({}, e.DEFAULTS, a.fn.selectpicker.defaults || {}, b.data(), i);
                    k.template = a.extend({}, e.DEFAULTS.template, a.fn.selectpicker.defaults ? a.fn.selectpicker.defaults.template : {}, b.data().template, i.template), 
                    b.data("selectpicker", c = new e(this, k, g));
                }
                "string" == typeof f && (h = c[f] instanceof Function ? c[f].apply(c, d) : c.options[f]);
            }
        });
        return "undefined" != typeof h ? h : i;
    }
    String.prototype.includes || !function() {
        var a = {}.toString, b = function() {
            try {
                var a = {}, b = Object.defineProperty, c = b(a, a, a) && b;
            } catch (d) {}
            return c;
        }(), c = "".indexOf, d = function(b) {
            if (null == this) throw new TypeError();
            var d = String(this);
            if (b && "[object RegExp]" == a.call(b)) throw new TypeError();
            var e = d.length, f = String(b), g = f.length, h = arguments.length > 1 ? arguments[1] : void 0, i = h ? Number(h) : 0;
            i != i && (i = 0);
            var j = Math.min(Math.max(i, 0), e);
            return g + j > e ? !1 : -1 != c.call(d, f, i);
        };
        b ? b(String.prototype, "includes", {
            value: d,
            configurable: !0,
            writable: !0
        }) : String.prototype.includes = d;
    }(), String.prototype.startsWith || !function() {
        var a = function() {
            try {
                var a = {}, b = Object.defineProperty, c = b(a, a, a) && b;
            } catch (d) {}
            return c;
        }(), b = {}.toString, c = function(a) {
            if (null == this) throw new TypeError();
            var c = String(this);
            if (a && "[object RegExp]" == b.call(a)) throw new TypeError();
            var d = c.length, e = String(a), f = e.length, g = arguments.length > 1 ? arguments[1] : void 0, h = g ? Number(g) : 0;
            h != h && (h = 0);
            var i = Math.min(Math.max(h, 0), d);
            if (f + i > d) return !1;
            for (var j = -1; ++j < f; ) if (c.charCodeAt(i + j) != e.charCodeAt(j)) return !1;
            return !0;
        };
        a ? a(String.prototype, "startsWith", {
            value: c,
            configurable: !0,
            writable: !0
        }) : String.prototype.startsWith = c;
    }(), Object.keys || (Object.keys = function(a, b, c) {
        c = [];
        for (b in a) c.hasOwnProperty.call(a, b) && c.push(b);
        return c;
    }), a.fn.triggerNative = function(a) {
        var b, c = this[0];
        c.dispatchEvent ? ("function" == typeof Event ? b = new Event(a, {
            bubbles: !0
        }) : (b = document.createEvent("Event"), b.initEvent(a, !0, !1)), c.dispatchEvent(b)) : (c.fireEvent && (b = document.createEventObject(), 
        b.eventType = a, c.fireEvent("on" + a, b)), this.trigger(a));
    }, a.expr[":"].icontains = function(b, c, d) {
        var e = a(b), f = (e.data("tokens") || e.text()).toUpperCase();
        return f.includes(d[3].toUpperCase());
    }, a.expr[":"].ibegins = function(b, c, d) {
        var e = a(b), f = (e.data("tokens") || e.text()).toUpperCase();
        return f.startsWith(d[3].toUpperCase());
    }, a.expr[":"].aicontains = function(b, c, d) {
        var e = a(b), f = (e.data("tokens") || e.data("normalizedText") || e.text()).toUpperCase();
        return f.includes(d[3].toUpperCase());
    }, a.expr[":"].aibegins = function(b, c, d) {
        var e = a(b), f = (e.data("tokens") || e.data("normalizedText") || e.text()).toUpperCase();
        return f.startsWith(d[3].toUpperCase());
    };
    var e = function(b, c, d) {
        d && (d.stopPropagation(), d.preventDefault()), this.$element = a(b), this.$newElement = null, 
        this.$button = null, this.$menu = null, this.$lis = null, this.options = c, null === this.options.title && (this.options.title = this.$element.attr("title")), 
        this.val = e.prototype.val, this.render = e.prototype.render, this.refresh = e.prototype.refresh, 
        this.setStyle = e.prototype.setStyle, this.selectAll = e.prototype.selectAll, this.deselectAll = e.prototype.deselectAll, 
        this.destroy = e.prototype.destroy, this.remove = e.prototype.remove, this.show = e.prototype.show, 
        this.hide = e.prototype.hide, this.init();
    };
    e.VERSION = "1.10.0", e.DEFAULTS = {
        noneSelectedText: "Nothing selected",
        noneResultsText: "No results matched {0}",
        countSelectedText: function(a, b) {
            return 1 == a ? "{0} item selected" : "{0} items selected";
        },
        maxOptionsText: function(a, b) {
            return [ 1 == a ? "Limit reached ({n} item max)" : "Limit reached ({n} items max)", 1 == b ? "Group limit reached ({n} item max)" : "Group limit reached ({n} items max)" ];
        },
        selectAllText: "Select All",
        deselectAllText: "Deselect All",
        doneButton: !1,
        doneButtonText: "Close",
        multipleSeparator: ", ",
        styleBase: "btn",
        style: "btn-default",
        size: "auto",
        title: null,
        selectedTextFormat: "values",
        width: !1,
        container: !1,
        hideDisabled: !1,
        showSubtext: !1,
        showIcon: !0,
        showContent: !0,
        dropupAuto: !0,
        header: !1,
        liveSearch: !1,
        liveSearchPlaceholder: null,
        liveSearchNormalize: !1,
        liveSearchStyle: "contains",
        actionsBox: !1,
        iconBase: "glyphicon",
        tickIcon: "glyphicon-ok",
        showTick: !1,
        template: {
            caret: '<span class="caret"></span>'
        },
        maxOptions: !1,
        mobile: !1,
        selectOnTab: !1,
        dropdownAlignRight: !1
    }, e.prototype = {
        constructor: e,
        init: function() {
            var b = this, c = this.$element.attr("id");
            this.$element.addClass("bs-select-hidden"), this.liObj = {}, this.multiple = this.$element.prop("multiple"), 
            this.autofocus = this.$element.prop("autofocus"), this.$newElement = this.createView(), 
            this.$element.after(this.$newElement).appendTo(this.$newElement), this.$button = this.$newElement.children("button"), 
            this.$menu = this.$newElement.children(".dropdown-menu"), this.$menuInner = this.$menu.children(".inner"), 
            this.$searchbox = this.$menu.find("input"), this.$element.removeClass("bs-select-hidden"), 
            this.options.dropdownAlignRight && this.$menu.addClass("dropdown-menu-right"), "undefined" != typeof c && (this.$button.attr("data-id", c), 
            a('label[for="' + c + '"]').click(function(a) {
                a.preventDefault(), b.$button.focus();
            })), this.checkDisabled(), this.clickListener(), this.options.liveSearch && this.liveSearchListener(), 
            this.render(), this.setStyle(), this.setWidth(), this.options.container && this.selectPosition(), 
            this.$menu.data("this", this), this.$newElement.data("this", this), this.options.mobile && this.mobile(), 
            this.$newElement.on({
                "hide.bs.dropdown": function(a) {
                    b.$element.trigger("hide.bs.select", a);
                },
                "hidden.bs.dropdown": function(a) {
                    b.$element.trigger("hidden.bs.select", a);
                },
                "show.bs.dropdown": function(a) {
                    b.$element.trigger("show.bs.select", a);
                },
                "shown.bs.dropdown": function(a) {
                    b.$element.trigger("shown.bs.select", a);
                }
            }), b.$element[0].hasAttribute("required") && this.$element.on("invalid", function() {
                b.$button.addClass("bs-invalid").focus(), b.$element.on({
                    "focus.bs.select": function() {
                        b.$button.focus(), b.$element.off("focus.bs.select");
                    },
                    "shown.bs.select": function() {
                        b.$element.val(b.$element.val()).off("shown.bs.select");
                    },
                    "rendered.bs.select": function() {
                        this.validity.valid && b.$button.removeClass("bs-invalid"), b.$element.off("rendered.bs.select");
                    }
                });
            }), setTimeout(function() {
                b.$element.trigger("loaded.bs.select");
            });
        },
        createDropdown: function() {
            var b = this.multiple || this.options.showTick ? " show-tick" : "", d = this.$element.parent().hasClass("input-group") ? " input-group-btn" : "", e = this.autofocus ? " autofocus" : "", f = this.options.header ? '<div class="popover-title"><button type="button" class="close" aria-hidden="true">&times;</button>' + this.options.header + "</div>" : "", g = this.options.liveSearch ? '<div class="bs-searchbox"><input type="text" class="form-control" autocomplete="off"' + (null === this.options.liveSearchPlaceholder ? "" : ' placeholder="' + c(this.options.liveSearchPlaceholder) + '"') + "></div>" : "", h = this.multiple && this.options.actionsBox ? '<div class="bs-actionsbox"><div class="btn-group btn-group-sm btn-block"><button type="button" class="actions-btn bs-select-all btn btn-default">' + this.options.selectAllText + '</button><button type="button" class="actions-btn bs-deselect-all btn btn-default">' + this.options.deselectAllText + "</button></div></div>" : "", i = this.multiple && this.options.doneButton ? '<div class="bs-donebutton"><div class="btn-group btn-block"><button type="button" class="btn btn-sm btn-default">' + this.options.doneButtonText + "</button></div></div>" : "", j = '<div class="btn-group bootstrap-select' + b + d + '"><button type="button" class="' + this.options.styleBase + ' dropdown-toggle" data-toggle="dropdown"' + e + '><span class="filter-option pull-left"></span>&nbsp;<span class="bs-caret">' + this.options.template.caret + '</span></button><div class="dropdown-menu open">' + f + g + h + '<ul class="dropdown-menu inner" role="menu"></ul>' + i + "</div></div>";
            return a(j);
        },
        createView: function() {
            var a = this.createDropdown(), b = this.createLi();
            return a.find("ul")[0].innerHTML = b, a;
        },
        reloadLi: function() {
            this.destroyLi();
            var a = this.createLi();
            this.$menuInner[0].innerHTML = a;
        },
        destroyLi: function() {
            this.$menu.find("li").remove();
        },
        createLi: function() {
            var d = this, e = [], f = 0, g = document.createElement("option"), h = -1, i = function(a, b, c, d) {
                return "<li" + ("undefined" != typeof c & "" !== c ? ' class="' + c + '"' : "") + ("undefined" != typeof b & null !== b ? ' data-original-index="' + b + '"' : "") + ("undefined" != typeof d & null !== d ? 'data-optgroup="' + d + '"' : "") + ">" + a + "</li>";
            }, j = function(a, e, f, g) {
                return '<a tabindex="0"' + ("undefined" != typeof e ? ' class="' + e + '"' : "") + ("undefined" != typeof f ? ' style="' + f + '"' : "") + (d.options.liveSearchNormalize ? ' data-normalized-text="' + b(c(a)) + '"' : "") + ("undefined" != typeof g || null !== g ? ' data-tokens="' + g + '"' : "") + ">" + a + '<span class="' + d.options.iconBase + " " + d.options.tickIcon + ' check-mark"></span></a>';
            };
            if (this.options.title && !this.multiple && (h--, !this.$element.find(".bs-title-option").length)) {
                var k = this.$element[0];
                g.className = "bs-title-option", g.appendChild(document.createTextNode(this.options.title)), 
                g.value = "", k.insertBefore(g, k.firstChild), void 0 === a(k.options[k.selectedIndex]).attr("selected") && (g.selected = !0);
            }
            return this.$element.find("option").each(function(b) {
                var c = a(this);
                if (h++, !c.hasClass("bs-title-option")) {
                    var g = this.className || "", k = this.style.cssText, l = c.data("content") ? c.data("content") : c.html(), m = c.data("tokens") ? c.data("tokens") : null, n = "undefined" != typeof c.data("subtext") ? '<small class="text-muted">' + c.data("subtext") + "</small>" : "", o = "undefined" != typeof c.data("icon") ? '<span class="' + d.options.iconBase + " " + c.data("icon") + '"></span> ' : "", p = "OPTGROUP" === this.parentNode.tagName, q = this.disabled || p && this.parentNode.disabled;
                    if ("" !== o && q && (o = "<span>" + o + "</span>"), d.options.hideDisabled && q && !p) return void h--;
                    if (c.data("content") || (l = o + '<span class="text">' + l + n + "</span>"), p && c.data("divider") !== !0) {
                        var r = " " + this.parentNode.className || "";
                        if (0 === c.index()) {
                            f += 1;
                            var s = this.parentNode.label, t = "undefined" != typeof c.parent().data("subtext") ? '<small class="text-muted">' + c.parent().data("subtext") + "</small>" : "", u = c.parent().data("icon") ? '<span class="' + d.options.iconBase + " " + c.parent().data("icon") + '"></span> ' : "";
                            s = u + '<span class="text">' + s + t + "</span>", 0 !== b && e.length > 0 && (h++, 
                            e.push(i("", null, "divider", f + "div"))), h++, e.push(i(s, null, "dropdown-header" + r, f));
                        }
                        if (d.options.hideDisabled && q) return void h--;
                        e.push(i(j(l, "opt " + g + r, k, m), b, "", f));
                    } else c.data("divider") === !0 ? e.push(i("", b, "divider")) : c.data("hidden") === !0 ? e.push(i(j(l, g, k, m), b, "hidden is-hidden")) : (this.previousElementSibling && "OPTGROUP" === this.previousElementSibling.tagName && (h++, 
                    e.push(i("", null, "divider", f + "div"))), e.push(i(j(l, g, k, m), b)));
                    d.liObj[b] = h;
                }
            }), this.multiple || 0 !== this.$element.find("option:selected").length || this.options.title || this.$element.find("option").eq(0).prop("selected", !0).attr("selected", "selected"), 
            e.join("");
        },
        findLis: function() {
            return null == this.$lis && (this.$lis = this.$menu.find("li")), this.$lis;
        },
        render: function(b) {
            var c, d = this;
            b !== !1 && this.$element.find("option").each(function(a) {
                var b = d.findLis().eq(d.liObj[a]);
                d.setDisabled(a, this.disabled || "OPTGROUP" === this.parentNode.tagName && this.parentNode.disabled, b), 
                d.setSelected(a, this.selected, b);
            }), this.tabIndex();
            var e = this.$element.find("option").map(function() {
                if (this.selected) {
                    if (d.options.hideDisabled && (this.disabled || "OPTGROUP" === this.parentNode.tagName && this.parentNode.disabled)) return;
                    var b, c = a(this), e = c.data("icon") && d.options.showIcon ? '<i class="' + d.options.iconBase + " " + c.data("icon") + '"></i> ' : "";
                    return b = d.options.showSubtext && c.data("subtext") && !d.multiple ? ' <small class="text-muted">' + c.data("subtext") + "</small>" : "", 
                    "undefined" != typeof c.attr("title") ? c.attr("title") : c.data("content") && d.options.showContent ? c.data("content") : e + c.html() + b;
                }
            }).toArray(), f = this.multiple ? e.join(this.options.multipleSeparator) : e[0];
            if (this.multiple && this.options.selectedTextFormat.indexOf("count") > -1) {
                var g = this.options.selectedTextFormat.split(">");
                if (g.length > 1 && e.length > g[1] || 1 == g.length && e.length >= 2) {
                    c = this.options.hideDisabled ? ", [disabled]" : "";
                    var h = this.$element.find("option").not('[data-divider="true"], [data-hidden="true"]' + c).length, i = "function" == typeof this.options.countSelectedText ? this.options.countSelectedText(e.length, h) : this.options.countSelectedText;
                    f = i.replace("{0}", e.length.toString()).replace("{1}", h.toString());
                }
            }
            void 0 == this.options.title && (this.options.title = this.$element.attr("title")), 
            "static" == this.options.selectedTextFormat && (f = this.options.title), f || (f = "undefined" != typeof this.options.title ? this.options.title : this.options.noneSelectedText), 
            this.$button.attr("title", a.trim(f.replace(/<[^>]*>?/g, ""))), this.$button.children(".filter-option").html(f), 
            this.$element.trigger("rendered.bs.select");
        },
        setStyle: function(a, b) {
            this.$element.attr("class") && this.$newElement.addClass(this.$element.attr("class").replace(/selectpicker|mobile-device|bs-select-hidden|validate\[.*\]/gi, ""));
            var c = a ? a : this.options.style;
            "add" == b ? this.$button.addClass(c) : "remove" == b ? this.$button.removeClass(c) : (this.$button.removeClass(this.options.style), 
            this.$button.addClass(c));
        },
        liHeight: function(b) {
            if (b || this.options.size !== !1 && !this.sizeInfo) {
                var c = document.createElement("div"), d = document.createElement("div"), e = document.createElement("ul"), f = document.createElement("li"), g = document.createElement("li"), h = document.createElement("a"), i = document.createElement("span"), j = this.options.header && this.$menu.find(".popover-title").length > 0 ? this.$menu.find(".popover-title")[0].cloneNode(!0) : null, k = this.options.liveSearch ? document.createElement("div") : null, l = this.options.actionsBox && this.multiple && this.$menu.find(".bs-actionsbox").length > 0 ? this.$menu.find(".bs-actionsbox")[0].cloneNode(!0) : null, m = this.options.doneButton && this.multiple && this.$menu.find(".bs-donebutton").length > 0 ? this.$menu.find(".bs-donebutton")[0].cloneNode(!0) : null;
                if (i.className = "text", c.className = this.$menu[0].parentNode.className + " open", 
                d.className = "dropdown-menu open", e.className = "dropdown-menu inner", f.className = "divider", 
                i.appendChild(document.createTextNode("Inner text")), h.appendChild(i), g.appendChild(h), 
                e.appendChild(g), e.appendChild(f), j && d.appendChild(j), k) {
                    var n = document.createElement("span");
                    k.className = "bs-searchbox", n.className = "form-control", k.appendChild(n), d.appendChild(k);
                }
                l && d.appendChild(l), d.appendChild(e), m && d.appendChild(m), c.appendChild(d), 
                document.body.appendChild(c);
                var o = h.offsetHeight, p = j ? j.offsetHeight : 0, q = k ? k.offsetHeight : 0, r = l ? l.offsetHeight : 0, s = m ? m.offsetHeight : 0, t = a(f).outerHeight(!0), u = "function" == typeof getComputedStyle ? getComputedStyle(d) : !1, v = u ? null : a(d), w = parseInt(u ? u.paddingTop : v.css("paddingTop")) + parseInt(u ? u.paddingBottom : v.css("paddingBottom")) + parseInt(u ? u.borderTopWidth : v.css("borderTopWidth")) + parseInt(u ? u.borderBottomWidth : v.css("borderBottomWidth")), x = w + parseInt(u ? u.marginTop : v.css("marginTop")) + parseInt(u ? u.marginBottom : v.css("marginBottom")) + 2;
                document.body.removeChild(c), this.sizeInfo = {
                    liHeight: o,
                    headerHeight: p,
                    searchHeight: q,
                    actionsHeight: r,
                    doneButtonHeight: s,
                    dividerHeight: t,
                    menuPadding: w,
                    menuExtras: x
                };
            }
        },
        setSize: function() {
            if (this.findLis(), this.liHeight(), this.options.header && this.$menu.css("padding-top", 0), 
            this.options.size !== !1) {
                var b, c, d, e, f = this, g = this.$menu, h = this.$menuInner, i = a(window), j = this.$newElement[0].offsetHeight, k = this.sizeInfo.liHeight, l = this.sizeInfo.headerHeight, m = this.sizeInfo.searchHeight, n = this.sizeInfo.actionsHeight, o = this.sizeInfo.doneButtonHeight, p = this.sizeInfo.dividerHeight, q = this.sizeInfo.menuPadding, r = this.sizeInfo.menuExtras, s = this.options.hideDisabled ? ".disabled" : "", t = function() {
                    d = f.$newElement.offset().top - i.scrollTop(), e = i.height() - d - j;
                };
                if (t(), "auto" === this.options.size) {
                    var u = function() {
                        var i, j = function(b, c) {
                            return function(d) {
                                return c ? d.classList ? d.classList.contains(b) : a(d).hasClass(b) : !(d.classList ? d.classList.contains(b) : a(d).hasClass(b));
                            };
                        }, p = f.$menuInner[0].getElementsByTagName("li"), s = Array.prototype.filter ? Array.prototype.filter.call(p, j("hidden", !1)) : f.$lis.not(".hidden"), u = Array.prototype.filter ? Array.prototype.filter.call(s, j("dropdown-header", !0)) : s.filter(".dropdown-header");
                        t(), b = e - r, f.options.container ? (g.data("height") || g.data("height", g.height()), 
                        c = g.data("height")) : c = g.height(), f.options.dropupAuto && f.$newElement.toggleClass("dropup", d > e && c > b - r), 
                        f.$newElement.hasClass("dropup") && (b = d - r), i = s.length + u.length > 3 ? 3 * k + r - 2 : 0, 
                        g.css({
                            "max-height": b + "px",
                            overflow: "hidden",
                            "min-height": i + l + m + n + o + "px"
                        }), h.css({
                            "max-height": b - l - m - n - o - q + "px",
                            "overflow-y": "auto",
                            "min-height": Math.max(i - q, 0) + "px"
                        });
                    };
                    u(), this.$searchbox.off("input.getSize propertychange.getSize").on("input.getSize propertychange.getSize", u), 
                    i.off("resize.getSize scroll.getSize").on("resize.getSize scroll.getSize", u);
                } else if (this.options.size && "auto" != this.options.size && this.$lis.not(s).length > this.options.size) {
                    var v = this.$lis.not(".divider").not(s).children().slice(0, this.options.size).last().parent().index(), w = this.$lis.slice(0, v + 1).filter(".divider").length;
                    b = k * this.options.size + w * p + q, f.options.container ? (g.data("height") || g.data("height", g.height()), 
                    c = g.data("height")) : c = g.height(), f.options.dropupAuto && this.$newElement.toggleClass("dropup", d > e && c > b - r), 
                    g.css({
                        "max-height": b + l + m + n + o + "px",
                        overflow: "hidden",
                        "min-height": ""
                    }), h.css({
                        "max-height": b - q + "px",
                        "overflow-y": "auto",
                        "min-height": ""
                    });
                }
            }
        },
        setWidth: function() {
            if ("auto" === this.options.width) {
                this.$menu.css("min-width", "0");
                var a = this.$menu.parent().clone().appendTo("body"), b = this.options.container ? this.$newElement.clone().appendTo("body") : a, c = a.children(".dropdown-menu").outerWidth(), d = b.css("width", "auto").children("button").outerWidth();
                a.remove(), b.remove(), this.$newElement.css("width", Math.max(c, d) + "px");
            } else "fit" === this.options.width ? (this.$menu.css("min-width", ""), this.$newElement.css("width", "").addClass("fit-width")) : this.options.width ? (this.$menu.css("min-width", ""), 
            this.$newElement.css("width", this.options.width)) : (this.$menu.css("min-width", ""), 
            this.$newElement.css("width", ""));
            this.$newElement.hasClass("fit-width") && "fit" !== this.options.width && this.$newElement.removeClass("fit-width");
        },
        selectPosition: function() {
            this.$bsContainer = a('<div class="bs-container" />');
            var b, c, d = this, e = function(a) {
                d.$bsContainer.addClass(a.attr("class").replace(/form-control|fit-width/gi, "")).toggleClass("dropup", a.hasClass("dropup")), 
                b = a.offset(), c = a.hasClass("dropup") ? 0 : a[0].offsetHeight, d.$bsContainer.css({
                    top: b.top + c,
                    left: b.left,
                    width: a[0].offsetWidth
                });
            };
            this.$button.on("click", function() {
                var b = a(this);
                d.isDisabled() || (e(d.$newElement), d.$bsContainer.appendTo(d.options.container).toggleClass("open", !b.hasClass("open")).append(d.$menu));
            }), a(window).on("resize scroll", function() {
                e(d.$newElement);
            }), this.$element.on("hide.bs.select", function() {
                d.$menu.data("height", d.$menu.height()), d.$bsContainer.detach();
            });
        },
        setSelected: function(a, b, c) {
            c || (c = this.findLis().eq(this.liObj[a])), c.toggleClass("selected", b);
        },
        setDisabled: function(a, b, c) {
            c || (c = this.findLis().eq(this.liObj[a])), b ? c.addClass("disabled").children("a").attr("href", "#").attr("tabindex", -1) : c.removeClass("disabled").children("a").removeAttr("href").attr("tabindex", 0);
        },
        isDisabled: function() {
            return this.$element[0].disabled;
        },
        checkDisabled: function() {
            var a = this;
            this.isDisabled() ? (this.$newElement.addClass("disabled"), this.$button.addClass("disabled").attr("tabindex", -1)) : (this.$button.hasClass("disabled") && (this.$newElement.removeClass("disabled"), 
            this.$button.removeClass("disabled")), -1 != this.$button.attr("tabindex") || this.$element.data("tabindex") || this.$button.removeAttr("tabindex")), 
            this.$button.click(function() {
                return !a.isDisabled();
            });
        },
        tabIndex: function() {
            this.$element.data("tabindex") !== this.$element.attr("tabindex") && -98 !== this.$element.attr("tabindex") && "-98" !== this.$element.attr("tabindex") && (this.$element.data("tabindex", this.$element.attr("tabindex")), 
            this.$button.attr("tabindex", this.$element.data("tabindex"))), this.$element.attr("tabindex", -98);
        },
        clickListener: function() {
            var b = this, c = a(document);
            this.$newElement.on("touchstart.dropdown", ".dropdown-menu", function(a) {
                a.stopPropagation();
            }), c.data("spaceSelect", !1), this.$button.on("keyup", function(a) {
                /(32)/.test(a.keyCode.toString(10)) && c.data("spaceSelect") && (a.preventDefault(), 
                c.data("spaceSelect", !1));
            }), this.$button.on("click", function() {
                b.setSize();
            }), this.$element.on("shown.bs.select", function() {
                if (b.options.liveSearch || b.multiple) {
                    if (!b.multiple) {
                        var a = b.liObj[b.$element[0].selectedIndex];
                        if ("number" != typeof a || b.options.size === !1) return;
                        var c = b.$lis.eq(a)[0].offsetTop - b.$menuInner[0].offsetTop;
                        c = c - b.$menuInner[0].offsetHeight / 2 + b.sizeInfo.liHeight / 2, b.$menuInner[0].scrollTop = c;
                    }
                } else b.$menuInner.find(".selected a").focus();
            }), this.$menuInner.on("click", "li a", function(c) {
                var d = a(this), e = d.parent().data("originalIndex"), f = b.$element.val(), g = b.$element.prop("selectedIndex");
                if (b.multiple && c.stopPropagation(), c.preventDefault(), !b.isDisabled() && !d.parent().hasClass("disabled")) {
                    var h = b.$element.find("option"), i = h.eq(e), j = i.prop("selected"), k = i.parent("optgroup"), l = b.options.maxOptions, m = k.data("maxOptions") || !1;
                    if (b.multiple) {
                        if (i.prop("selected", !j), b.setSelected(e, !j), d.blur(), l !== !1 || m !== !1) {
                            var n = l < h.filter(":selected").length, o = m < k.find("option:selected").length;
                            if (l && n || m && o) if (l && 1 == l) h.prop("selected", !1), i.prop("selected", !0), 
                            b.$menuInner.find(".selected").removeClass("selected"), b.setSelected(e, !0); else if (m && 1 == m) {
                                k.find("option:selected").prop("selected", !1), i.prop("selected", !0);
                                var p = d.parent().data("optgroup");
                                b.$menuInner.find('[data-optgroup="' + p + '"]').removeClass("selected"), b.setSelected(e, !0);
                            } else {
                                var q = "function" == typeof b.options.maxOptionsText ? b.options.maxOptionsText(l, m) : b.options.maxOptionsText, r = q[0].replace("{n}", l), s = q[1].replace("{n}", m), t = a('<div class="notify"></div>');
                                q[2] && (r = r.replace("{var}", q[2][l > 1 ? 0 : 1]), s = s.replace("{var}", q[2][m > 1 ? 0 : 1])), 
                                i.prop("selected", !1), b.$menu.append(t), l && n && (t.append(a("<div>" + r + "</div>")), 
                                b.$element.trigger("maxReached.bs.select")), m && o && (t.append(a("<div>" + s + "</div>")), 
                                b.$element.trigger("maxReachedGrp.bs.select")), setTimeout(function() {
                                    b.setSelected(e, !1);
                                }, 10), t.delay(750).fadeOut(300, function() {
                                    a(this).remove();
                                });
                            }
                        }
                    } else h.prop("selected", !1), i.prop("selected", !0), b.$menuInner.find(".selected").removeClass("selected"), 
                    b.setSelected(e, !0);
                    b.multiple ? b.options.liveSearch && b.$searchbox.focus() : b.$button.focus(), (f != b.$element.val() && b.multiple || g != b.$element.prop("selectedIndex") && !b.multiple) && b.$element.trigger("changed.bs.select", [ e, i.prop("selected"), j ]).triggerNative("change");
                }
            }), this.$menu.on("click", "li.disabled a, .popover-title, .popover-title :not(.close)", function(c) {
                c.currentTarget == this && (c.preventDefault(), c.stopPropagation(), b.options.liveSearch && !a(c.target).hasClass("close") ? b.$searchbox.focus() : b.$button.focus());
            }), this.$menuInner.on("click", ".divider, .dropdown-header", function(a) {
                a.preventDefault(), a.stopPropagation(), b.options.liveSearch ? b.$searchbox.focus() : b.$button.focus();
            }), this.$menu.on("click", ".popover-title .close", function() {
                b.$button.click();
            }), this.$searchbox.on("click", function(a) {
                a.stopPropagation();
            }), this.$menu.on("click", ".actions-btn", function(c) {
                b.options.liveSearch ? b.$searchbox.focus() : b.$button.focus(), c.preventDefault(), 
                c.stopPropagation(), a(this).hasClass("bs-select-all") ? b.selectAll() : b.deselectAll();
            }), this.$element.change(function() {
                b.render(!1);
            });
        },
        liveSearchListener: function() {
            var d = this, e = a('<li class="no-results"></li>');
            this.$button.on("click.dropdown.data-api touchstart.dropdown.data-api", function() {
                d.$menuInner.find(".active").removeClass("active"), d.$searchbox.val() && (d.$searchbox.val(""), 
                d.$lis.not(".is-hidden").removeClass("hidden"), e.parent().length && e.remove()), 
                d.multiple || d.$menuInner.find(".selected").addClass("active"), setTimeout(function() {
                    d.$searchbox.focus();
                }, 10);
            }), this.$searchbox.on("click.dropdown.data-api focus.dropdown.data-api touchend.dropdown.data-api", function(a) {
                a.stopPropagation();
            }), this.$searchbox.on("input propertychange", function() {
                if (d.$searchbox.val()) {
                    var f = d.$lis.not(".is-hidden").removeClass("hidden").children("a");
                    f = d.options.liveSearchNormalize ? f.not(":a" + d._searchStyle() + '("' + b(d.$searchbox.val()) + '")') : f.not(":" + d._searchStyle() + '("' + d.$searchbox.val() + '")'), 
                    f.parent().addClass("hidden"), d.$lis.filter(".dropdown-header").each(function() {
                        var b = a(this), c = b.data("optgroup");
                        0 === d.$lis.filter("[data-optgroup=" + c + "]").not(b).not(".hidden").length && (b.addClass("hidden"), 
                        d.$lis.filter("[data-optgroup=" + c + "div]").addClass("hidden"));
                    });
                    var g = d.$lis.not(".hidden");
                    g.each(function(b) {
                        var c = a(this);
                        c.hasClass("divider") && (c.index() === g.first().index() || c.index() === g.last().index() || g.eq(b + 1).hasClass("divider")) && c.addClass("hidden");
                    }), d.$lis.not(".hidden, .no-results").length ? e.parent().length && e.remove() : (e.parent().length && e.remove(), 
                    e.html(d.options.noneResultsText.replace("{0}", '"' + c(d.$searchbox.val()) + '"')).show(), 
                    d.$menuInner.append(e));
                } else d.$lis.not(".is-hidden").removeClass("hidden"), e.parent().length && e.remove();
                d.$lis.filter(".active").removeClass("active"), d.$searchbox.val() && d.$lis.not(".hidden, .divider, .dropdown-header").eq(0).addClass("active").children("a").focus(), 
                a(this).focus();
            });
        },
        _searchStyle: function() {
            var a = {
                begins: "ibegins",
                startsWith: "ibegins"
            };
            return a[this.options.liveSearchStyle] || "icontains";
        },
        val: function(a) {
            return "undefined" != typeof a ? (this.$element.val(a), this.render(), this.$element) : this.$element.val();
        },
        changeAll: function(b) {
            "undefined" == typeof b && (b = !0), this.findLis();
            for (var c = this.$element.find("option"), d = this.$lis.not(".divider, .dropdown-header, .disabled, .hidden").toggleClass("selected", b), e = d.length, f = [], g = 0; e > g; g++) {
                var h = d[g].getAttribute("data-original-index");
                f[f.length] = c.eq(h)[0];
            }
            a(f).prop("selected", b), this.render(!1), this.$element.trigger("changed.bs.select").triggerNative("change");
        },
        selectAll: function() {
            return this.changeAll(!0);
        },
        deselectAll: function() {
            return this.changeAll(!1);
        },
        toggle: function(a) {
            a = a || window.event, a && a.stopPropagation(), this.$button.trigger("click");
        },
        keydown: function(c) {
            var d, e, f, g, h, i, j, k, l, m = a(this), n = m.is("input") ? m.parent().parent() : m.parent(), o = n.data("this"), p = ":not(.disabled, .hidden, .dropdown-header, .divider)", q = {
                32: " ",
                48: "0",
                49: "1",
                50: "2",
                51: "3",
                52: "4",
                53: "5",
                54: "6",
                55: "7",
                56: "8",
                57: "9",
                59: ";",
                65: "a",
                66: "b",
                67: "c",
                68: "d",
                69: "e",
                70: "f",
                71: "g",
                72: "h",
                73: "i",
                74: "j",
                75: "k",
                76: "l",
                77: "m",
                78: "n",
                79: "o",
                80: "p",
                81: "q",
                82: "r",
                83: "s",
                84: "t",
                85: "u",
                86: "v",
                87: "w",
                88: "x",
                89: "y",
                90: "z",
                96: "0",
                97: "1",
                98: "2",
                99: "3",
                100: "4",
                101: "5",
                102: "6",
                103: "7",
                104: "8",
                105: "9"
            };
            if (o.options.liveSearch && (n = m.parent().parent()), o.options.container && (n = o.$menu), 
            d = a("[role=menu] li", n), l = o.$newElement.hasClass("open"), !l && (c.keyCode >= 48 && c.keyCode <= 57 || c.keyCode >= 96 && c.keyCode <= 105 || c.keyCode >= 65 && c.keyCode <= 90) && (o.options.container ? o.$button.trigger("click") : (o.setSize(), 
            o.$menu.parent().addClass("open"), l = !0), o.$searchbox.focus()), o.options.liveSearch && (/(^9$|27)/.test(c.keyCode.toString(10)) && l && 0 === o.$menu.find(".active").length && (c.preventDefault(), 
            o.$menu.parent().removeClass("open"), o.options.container && o.$newElement.removeClass("open"), 
            o.$button.focus()), d = a("[role=menu] li" + p, n), m.val() || /(38|40)/.test(c.keyCode.toString(10)) || 0 === d.filter(".active").length && (d = o.$menuInner.find("li"), 
            d = o.options.liveSearchNormalize ? d.filter(":a" + o._searchStyle() + "(" + b(q[c.keyCode]) + ")") : d.filter(":" + o._searchStyle() + "(" + q[c.keyCode] + ")"))), 
            d.length) {
                if (/(38|40)/.test(c.keyCode.toString(10))) e = d.index(d.find("a").filter(":focus").parent()), 
                g = d.filter(p).first().index(), h = d.filter(p).last().index(), f = d.eq(e).nextAll(p).eq(0).index(), 
                i = d.eq(e).prevAll(p).eq(0).index(), j = d.eq(f).prevAll(p).eq(0).index(), o.options.liveSearch && (d.each(function(b) {
                    a(this).hasClass("disabled") || a(this).data("index", b);
                }), e = d.index(d.filter(".active")), g = d.first().data("index"), h = d.last().data("index"), 
                f = d.eq(e).nextAll().eq(0).data("index"), i = d.eq(e).prevAll().eq(0).data("index"), 
                j = d.eq(f).prevAll().eq(0).data("index")), k = m.data("prevIndex"), 38 == c.keyCode ? (o.options.liveSearch && e--, 
                e != j && e > i && (e = i), g > e && (e = g), e == k && (e = h)) : 40 == c.keyCode && (o.options.liveSearch && e++, 
                -1 == e && (e = 0), e != j && f > e && (e = f), e > h && (e = h), e == k && (e = g)), 
                m.data("prevIndex", e), o.options.liveSearch ? (c.preventDefault(), m.hasClass("dropdown-toggle") || (d.removeClass("active").eq(e).addClass("active").children("a").focus(), 
                m.focus())) : d.eq(e).children("a").focus(); else if (!m.is("input")) {
                    var r, s, t = [];
                    d.each(function() {
                        a(this).hasClass("disabled") || a.trim(a(this).children("a").text().toLowerCase()).substring(0, 1) == q[c.keyCode] && t.push(a(this).index());
                    }), r = a(document).data("keycount"), r++, a(document).data("keycount", r), s = a.trim(a(":focus").text().toLowerCase()).substring(0, 1), 
                    s != q[c.keyCode] ? (r = 1, a(document).data("keycount", r)) : r >= t.length && (a(document).data("keycount", 0), 
                    r > t.length && (r = 1)), d.eq(t[r - 1]).children("a").focus();
                }
                if ((/(13|32)/.test(c.keyCode.toString(10)) || /(^9$)/.test(c.keyCode.toString(10)) && o.options.selectOnTab) && l) {
                    if (/(32)/.test(c.keyCode.toString(10)) || c.preventDefault(), o.options.liveSearch) /(32)/.test(c.keyCode.toString(10)) || (o.$menuInner.find(".active a").click(), 
                    m.focus()); else {
                        var u = a(":focus");
                        u.click(), u.focus(), c.preventDefault(), a(document).data("spaceSelect", !0);
                    }
                    a(document).data("keycount", 0);
                }
                (/(^9$|27)/.test(c.keyCode.toString(10)) && l && (o.multiple || o.options.liveSearch) || /(27)/.test(c.keyCode.toString(10)) && !l) && (o.$menu.parent().removeClass("open"), 
                o.options.container && o.$newElement.removeClass("open"), o.$button.focus());
            }
        },
        mobile: function() {
            this.$element.addClass("mobile-device");
        },
        refresh: function() {
            this.$lis = null, this.liObj = {}, this.reloadLi(), this.render(), this.checkDisabled(), 
            this.liHeight(!0), this.setStyle(), this.setWidth(), this.$lis && this.$searchbox.trigger("propertychange"), 
            this.$element.trigger("refreshed.bs.select");
        },
        hide: function() {
            this.$newElement.hide();
        },
        show: function() {
            this.$newElement.show();
        },
        remove: function() {
            this.$newElement.remove(), this.$element.remove();
        },
        destroy: function() {
            this.$newElement.before(this.$element).remove(), this.$bsContainer ? this.$bsContainer.remove() : this.$menu.remove(), 
            this.$element.off(".bs.select").removeData("selectpicker").removeClass("bs-select-hidden selectpicker");
        }
    };
    var f = a.fn.selectpicker;
    a.fn.selectpicker = d, a.fn.selectpicker.Constructor = e, a.fn.selectpicker.noConflict = function() {
        return a.fn.selectpicker = f, this;
    }, a(document).data("keycount", 0).on("keydown.bs.select", '.bootstrap-select [data-toggle=dropdown], .bootstrap-select [role="menu"], .bs-searchbox input', e.prototype.keydown).on("focusin.modal", '.bootstrap-select [data-toggle=dropdown], .bootstrap-select [role="menu"], .bs-searchbox input', function(a) {
        a.stopPropagation();
    }), a(window).on("load.bs.select.data-api", function() {
        a(".selectpicker").each(function() {
            var b = a(this);
            d.call(b, b.data());
        });
    });
}(jQuery), !function(a, b, c, d) {
    function e(b, c) {
        this.settings = null, this.options = a.extend({}, e.Defaults, c), this.$element = a(b), 
        this.drag = a.extend({}, m), this.state = a.extend({}, n), this.e = a.extend({}, o), 
        this._plugins = {}, this._supress = {}, this._current = null, this._speed = null, 
        this._coordinates = [], this._breakpoint = null, this._width = null, this._items = [], 
        this._clones = [], this._mergers = [], this._invalidated = {}, this._pipe = [], 
        a.each(e.Plugins, a.proxy(function(a, b) {
            this._plugins[a[0].toLowerCase() + a.slice(1)] = new b(this);
        }, this)), a.each(e.Pipe, a.proxy(function(b, c) {
            this._pipe.push({
                filter: c.filter,
                run: a.proxy(c.run, this)
            });
        }, this)), this.setup(), this.initialize();
    }
    function f(a) {
        if (a.touches !== d) return {
            x: a.touches[0].pageX,
            y: a.touches[0].pageY
        };
        if (a.touches === d) {
            if (a.pageX !== d) return {
                x: a.pageX,
                y: a.pageY
            };
            if (a.pageX === d) return {
                x: a.clientX,
                y: a.clientY
            };
        }
    }
    function g(a) {
        var b, d, e = c.createElement("div"), f = a;
        for (b in f) if (d = f[b], "undefined" != typeof e.style[d]) return e = null, [ d, b ];
        return [ !1 ];
    }
    function h() {
        return g([ "transition", "WebkitTransition", "MozTransition", "OTransition" ])[1];
    }
    function i() {
        return g([ "transform", "WebkitTransform", "MozTransform", "OTransform", "msTransform" ])[0];
    }
    function j() {
        return g([ "perspective", "webkitPerspective", "MozPerspective", "OPerspective", "MsPerspective" ])[0];
    }
    function k() {
        return "ontouchstart" in b || !!navigator.msMaxTouchPoints;
    }
    function l() {
        return b.navigator.msPointerEnabled;
    }
    var m, n, o;
    m = {
        start: 0,
        startX: 0,
        startY: 0,
        current: 0,
        currentX: 0,
        currentY: 0,
        offsetX: 0,
        offsetY: 0,
        distance: null,
        startTime: 0,
        endTime: 0,
        updatedX: 0,
        targetEl: null
    }, n = {
        isTouch: !1,
        isScrolling: !1,
        isSwiping: !1,
        direction: !1,
        inMotion: !1
    }, o = {
        _onDragStart: null,
        _onDragMove: null,
        _onDragEnd: null,
        _transitionEnd: null,
        _resizer: null,
        _responsiveCall: null,
        _goToLoop: null,
        _checkVisibile: null
    }, e.Defaults = {
        items: 3,
        loop: !1,
        center: !1,
        mouseDrag: !0,
        touchDrag: !0,
        pullDrag: !0,
        freeDrag: !1,
        margin: 0,
        stagePadding: 0,
        merge: !1,
        mergeFit: !0,
        autoWidth: !1,
        startPosition: 0,
        rtl: !1,
        smartSpeed: 250,
        fluidSpeed: !1,
        dragEndSpeed: !1,
        responsive: {},
        responsiveRefreshRate: 200,
        responsiveBaseElement: b,
        responsiveClass: !1,
        fallbackEasing: "swing",
        info: !1,
        nestedItemSelector: !1,
        itemElement: "div",
        stageElement: "div",
        themeClass: "owl-theme",
        baseClass: "owl-carousel",
        itemClass: "owl-item",
        centerClass: "center",
        activeClass: "active"
    }, e.Width = {
        Default: "default",
        Inner: "inner",
        Outer: "outer"
    }, e.Plugins = {}, e.Pipe = [ {
        filter: [ "width", "items", "settings" ],
        run: function(a) {
            a.current = this._items && this._items[this.relative(this._current)];
        }
    }, {
        filter: [ "items", "settings" ],
        run: function() {
            var a = this._clones, b = this.$stage.children(".cloned");
            (b.length !== a.length || !this.settings.loop && a.length > 0) && (this.$stage.children(".cloned").remove(), 
            this._clones = []);
        }
    }, {
        filter: [ "items", "settings" ],
        run: function() {
            var a, b, c = this._clones, d = this._items, e = this.settings.loop ? c.length - Math.max(2 * this.settings.items, 4) : 0;
            for (a = 0, b = Math.abs(e / 2); b > a; a++) e > 0 ? (this.$stage.children().eq(d.length + c.length - 1).remove(), 
            c.pop(), this.$stage.children().eq(0).remove(), c.pop()) : (c.push(c.length / 2), 
            this.$stage.append(d[c[c.length - 1]].clone().addClass("cloned")), c.push(d.length - 1 - (c.length - 1) / 2), 
            this.$stage.prepend(d[c[c.length - 1]].clone().addClass("cloned")));
        }
    }, {
        filter: [ "width", "items", "settings" ],
        run: function() {
            var a, b, c, d = this.settings.rtl ? 1 : -1, e = (this.width() / this.settings.items).toFixed(3), f = 0;
            for (this._coordinates = [], b = 0, c = this._clones.length + this._items.length; c > b; b++) a = this._mergers[this.relative(b)], 
            a = this.settings.mergeFit && Math.min(a, this.settings.items) || a, f += (this.settings.autoWidth ? this._items[this.relative(b)].width() + this.settings.margin : e * a) * d, 
            this._coordinates.push(f);
        }
    }, {
        filter: [ "width", "items", "settings" ],
        run: function() {
            var b, c, d = (this.width() / this.settings.items).toFixed(3), e = {
                width: Math.abs(this._coordinates[this._coordinates.length - 1]) + 2 * this.settings.stagePadding,
                "padding-left": this.settings.stagePadding || "",
                "padding-right": this.settings.stagePadding || ""
            };
            if (this.$stage.css(e), e = {
                width: this.settings.autoWidth ? "auto" : d - this.settings.margin
            }, e[this.settings.rtl ? "margin-left" : "margin-right"] = this.settings.margin, 
            !this.settings.autoWidth && a.grep(this._mergers, function(a) {
                return a > 1;
            }).length > 0) for (b = 0, c = this._coordinates.length; c > b; b++) e.width = Math.abs(this._coordinates[b]) - Math.abs(this._coordinates[b - 1] || 0) - this.settings.margin, 
            this.$stage.children().eq(b).css(e); else this.$stage.children().css(e);
        }
    }, {
        filter: [ "width", "items", "settings" ],
        run: function(a) {
            a.current && this.reset(this.$stage.children().index(a.current));
        }
    }, {
        filter: [ "position" ],
        run: function() {
            this.animate(this.coordinates(this._current));
        }
    }, {
        filter: [ "width", "position", "items", "settings" ],
        run: function() {
            var a, b, c, d, e = this.settings.rtl ? 1 : -1, f = 2 * this.settings.stagePadding, g = this.coordinates(this.current()) + f, h = g + this.width() * e, i = [];
            for (c = 0, d = this._coordinates.length; d > c; c++) a = this._coordinates[c - 1] || 0, 
            b = Math.abs(this._coordinates[c]) + f * e, (this.op(a, "<=", g) && this.op(a, ">", h) || this.op(b, "<", g) && this.op(b, ">", h)) && i.push(c);
            this.$stage.children("." + this.settings.activeClass).removeClass(this.settings.activeClass), 
            this.$stage.children(":eq(" + i.join("), :eq(") + ")").addClass(this.settings.activeClass), 
            this.settings.center && (this.$stage.children("." + this.settings.centerClass).removeClass(this.settings.centerClass), 
            this.$stage.children().eq(this.current()).addClass(this.settings.centerClass));
        }
    } ], e.prototype.initialize = function() {
        if (this.trigger("initialize"), this.$element.addClass(this.settings.baseClass).addClass(this.settings.themeClass).toggleClass("owl-rtl", this.settings.rtl), 
        this.browserSupport(), this.settings.autoWidth && this.state.imagesLoaded !== !0) {
            var b, c, e;
            if (b = this.$element.find("img"), c = this.settings.nestedItemSelector ? "." + this.settings.nestedItemSelector : d, 
            e = this.$element.children(c).width(), b.length && 0 >= e) return this.preloadAutoWidthImages(b), 
            !1;
        }
        this.$element.addClass("owl-loading"), this.$stage = a("<" + this.settings.stageElement + ' class="owl-stage"/>').wrap('<div class="owl-stage-outer">'), 
        this.$element.append(this.$stage.parent()), this.replace(this.$element.children().not(this.$stage.parent())), 
        this._width = this.$element.width(), this.refresh(), this.$element.removeClass("owl-loading").addClass("owl-loaded"), 
        this.eventsCall(), this.internalEvents(), this.addTriggerableEvents(), this.trigger("initialized");
    }, e.prototype.setup = function() {
        var b = this.viewport(), c = this.options.responsive, d = -1, e = null;
        c ? (a.each(c, function(a) {
            b >= a && a > d && (d = Number(a));
        }), e = a.extend({}, this.options, c[d]), delete e.responsive, e.responsiveClass && this.$element.attr("class", function(a, b) {
            return b.replace(/\b owl-responsive-\S+/g, "");
        }).addClass("owl-responsive-" + d)) : e = a.extend({}, this.options), (null === this.settings || this._breakpoint !== d) && (this.trigger("change", {
            property: {
                name: "settings",
                value: e
            }
        }), this._breakpoint = d, this.settings = e, this.invalidate("settings"), this.trigger("changed", {
            property: {
                name: "settings",
                value: this.settings
            }
        }));
    }, e.prototype.optionsLogic = function() {
        this.$element.toggleClass("owl-center", this.settings.center), this.settings.loop && this._items.length < this.settings.items && (this.settings.loop = !1), 
        this.settings.autoWidth && (this.settings.stagePadding = !1, this.settings.merge = !1);
    }, e.prototype.prepare = function(b) {
        var c = this.trigger("prepare", {
            content: b
        });
        return c.data || (c.data = a("<" + this.settings.itemElement + "/>").addClass(this.settings.itemClass).append(b)), 
        this.trigger("prepared", {
            content: c.data
        }), c.data;
    }, e.prototype.update = function() {
        for (var b = 0, c = this._pipe.length, d = a.proxy(function(a) {
            return this[a];
        }, this._invalidated), e = {}; c > b; ) (this._invalidated.all || a.grep(this._pipe[b].filter, d).length > 0) && this._pipe[b].run(e), 
        b++;
        this._invalidated = {};
    }, e.prototype.width = function(a) {
        switch (a = a || e.Width.Default) {
          case e.Width.Inner:
          case e.Width.Outer:
            return this._width;

          default:
            return this._width - 2 * this.settings.stagePadding + this.settings.margin;
        }
    }, e.prototype.refresh = function() {
        return 0 === this._items.length ? !1 : (new Date().getTime(), this.trigger("refresh"), 
        this.setup(), this.optionsLogic(), this.$stage.addClass("owl-refresh"), this.update(), 
        this.$stage.removeClass("owl-refresh"), this.state.orientation = b.orientation, 
        this.watchVisibility(), this.trigger("refreshed"), void 0);
    }, e.prototype.eventsCall = function() {
        this.e._onDragStart = a.proxy(function(a) {
            this.onDragStart(a);
        }, this), this.e._onDragMove = a.proxy(function(a) {
            this.onDragMove(a);
        }, this), this.e._onDragEnd = a.proxy(function(a) {
            this.onDragEnd(a);
        }, this), this.e._onResize = a.proxy(function(a) {
            this.onResize(a);
        }, this), this.e._transitionEnd = a.proxy(function(a) {
            this.transitionEnd(a);
        }, this), this.e._preventClick = a.proxy(function(a) {
            this.preventClick(a);
        }, this);
    }, e.prototype.onThrottledResize = function() {
        b.clearTimeout(this.resizeTimer), this.resizeTimer = b.setTimeout(this.e._onResize, this.settings.responsiveRefreshRate);
    }, e.prototype.onResize = function() {
        return this._items.length ? this._width === this.$element.width() ? !1 : this.trigger("resize").isDefaultPrevented() ? !1 : (this._width = this.$element.width(), 
        this.invalidate("width"), this.refresh(), void this.trigger("resized")) : !1;
    }, e.prototype.eventsRouter = function(a) {
        var b = a.type;
        "mousedown" === b || "touchstart" === b ? this.onDragStart(a) : "mousemove" === b || "touchmove" === b ? this.onDragMove(a) : "mouseup" === b || "touchend" === b ? this.onDragEnd(a) : "touchcancel" === b && this.onDragEnd(a);
    }, e.prototype.internalEvents = function() {
        var c = (k(), l());
        this.settings.mouseDrag ? (this.$stage.on("mousedown", a.proxy(function(a) {
            this.eventsRouter(a);
        }, this)), this.$stage.on("dragstart", function() {
            return !1;
        }), this.$stage.get(0).onselectstart = function() {
            return !1;
        }) : this.$element.addClass("owl-text-select-on"), this.settings.touchDrag && !c && this.$stage.on("touchstart touchcancel", a.proxy(function(a) {
            this.eventsRouter(a);
        }, this)), this.transitionEndVendor && this.on(this.$stage.get(0), this.transitionEndVendor, this.e._transitionEnd, !1), 
        this.settings.responsive !== !1 && this.on(b, "resize", a.proxy(this.onThrottledResize, this));
    }, e.prototype.onDragStart = function(d) {
        var e, g, h, i;
        if (e = d.originalEvent || d || b.event, 3 === e.which || this.state.isTouch) return !1;
        if ("mousedown" === e.type && this.$stage.addClass("owl-grab"), this.trigger("drag"), 
        this.drag.startTime = new Date().getTime(), this.speed(0), this.state.isTouch = !0, 
        this.state.isScrolling = !1, this.state.isSwiping = !1, this.drag.distance = 0, 
        g = f(e).x, h = f(e).y, this.drag.offsetX = this.$stage.position().left, this.drag.offsetY = this.$stage.position().top, 
        this.settings.rtl && (this.drag.offsetX = this.$stage.position().left + this.$stage.width() - this.width() + this.settings.margin), 
        this.state.inMotion && this.support3d) i = this.getTransformProperty(), this.drag.offsetX = i, 
        this.animate(i), this.state.inMotion = !0; else if (this.state.inMotion && !this.support3d) return this.state.inMotion = !1, 
        !1;
        this.drag.startX = g - this.drag.offsetX, this.drag.startY = h - this.drag.offsetY, 
        this.drag.start = g - this.drag.startX, this.drag.targetEl = e.target || e.srcElement, 
        this.drag.updatedX = this.drag.start, ("IMG" === this.drag.targetEl.tagName || "A" === this.drag.targetEl.tagName) && (this.drag.targetEl.draggable = !1), 
        a(c).on("mousemove.owl.dragEvents mouseup.owl.dragEvents touchmove.owl.dragEvents touchend.owl.dragEvents", a.proxy(function(a) {
            this.eventsRouter(a);
        }, this));
    }, e.prototype.onDragMove = function(a) {
        var c, e, g, h, i, j;
        this.state.isTouch && (this.state.isScrolling || (c = a.originalEvent || a || b.event, 
        e = f(c).x, g = f(c).y, this.drag.currentX = e - this.drag.startX, this.drag.currentY = g - this.drag.startY, 
        this.drag.distance = this.drag.currentX - this.drag.offsetX, this.drag.distance < 0 ? this.state.direction = this.settings.rtl ? "right" : "left" : this.drag.distance > 0 && (this.state.direction = this.settings.rtl ? "left" : "right"), 
        this.settings.loop ? this.op(this.drag.currentX, ">", this.coordinates(this.minimum())) && "right" === this.state.direction ? this.drag.currentX -= (this.settings.center && this.coordinates(0)) - this.coordinates(this._items.length) : this.op(this.drag.currentX, "<", this.coordinates(this.maximum())) && "left" === this.state.direction && (this.drag.currentX += (this.settings.center && this.coordinates(0)) - this.coordinates(this._items.length)) : (h = this.coordinates(this.settings.rtl ? this.maximum() : this.minimum()), 
        i = this.coordinates(this.settings.rtl ? this.minimum() : this.maximum()), j = this.settings.pullDrag ? this.drag.distance / 5 : 0, 
        this.drag.currentX = Math.max(Math.min(this.drag.currentX, h + j), i + j)), (this.drag.distance > 8 || this.drag.distance < -8) && (c.preventDefault !== d ? c.preventDefault() : c.returnValue = !1, 
        this.state.isSwiping = !0), this.drag.updatedX = this.drag.currentX, (this.drag.currentY > 16 || this.drag.currentY < -16) && this.state.isSwiping === !1 && (this.state.isScrolling = !0, 
        this.drag.updatedX = this.drag.start), this.animate(this.drag.updatedX)));
    }, e.prototype.onDragEnd = function(b) {
        var d, e, f;
        if (this.state.isTouch) {
            if ("mouseup" === b.type && this.$stage.removeClass("owl-grab"), this.trigger("dragged"), 
            this.drag.targetEl.removeAttribute("draggable"), this.state.isTouch = !1, this.state.isScrolling = !1, 
            this.state.isSwiping = !1, 0 === this.drag.distance && this.state.inMotion !== !0) return this.state.inMotion = !1, 
            !1;
            this.drag.endTime = new Date().getTime(), d = this.drag.endTime - this.drag.startTime, 
            e = Math.abs(this.drag.distance), (e > 3 || d > 300) && this.removeClick(this.drag.targetEl), 
            f = this.closest(this.drag.updatedX), this.speed(this.settings.dragEndSpeed || this.settings.smartSpeed), 
            this.current(f), this.invalidate("position"), this.update(), this.settings.pullDrag || this.drag.updatedX !== this.coordinates(f) || this.transitionEnd(), 
            this.drag.distance = 0, a(c).off(".owl.dragEvents");
        }
    }, e.prototype.removeClick = function(c) {
        this.drag.targetEl = c, a(c).on("click.preventClick", this.e._preventClick), b.setTimeout(function() {
            a(c).off("click.preventClick");
        }, 300);
    }, e.prototype.preventClick = function(b) {
        b.preventDefault ? b.preventDefault() : b.returnValue = !1, b.stopPropagation && b.stopPropagation(), 
        a(b.target).off("click.preventClick");
    }, e.prototype.getTransformProperty = function() {
        var a, c;
        return a = b.getComputedStyle(this.$stage.get(0), null).getPropertyValue(this.vendorName + "transform"), 
        a = a.replace(/matrix(3d)?\(|\)/g, "").split(","), c = 16 === a.length, c !== !0 ? a[4] : a[12];
    }, e.prototype.closest = function(b) {
        var c = -1, d = 30, e = this.width(), f = this.coordinates();
        return this.settings.freeDrag || a.each(f, a.proxy(function(a, g) {
            return b > g - d && g + d > b ? c = a : this.op(b, "<", g) && this.op(b, ">", f[a + 1] || g - e) && (c = "left" === this.state.direction ? a + 1 : a), 
            -1 === c;
        }, this)), this.settings.loop || (this.op(b, ">", f[this.minimum()]) ? c = b = this.minimum() : this.op(b, "<", f[this.maximum()]) && (c = b = this.maximum())), 
        c;
    }, e.prototype.animate = function(b) {
        this.trigger("translate"), this.state.inMotion = this.speed() > 0, this.support3d ? this.$stage.css({
            transform: "translate3d(" + b + "px,0px, 0px)",
            transition: this.speed() / 1e3 + "s"
        }) : this.state.isTouch ? this.$stage.css({
            left: b + "px"
        }) : this.$stage.animate({
            left: b
        }, this.speed() / 1e3, this.settings.fallbackEasing, a.proxy(function() {
            this.state.inMotion && this.transitionEnd();
        }, this));
    }, e.prototype.current = function(a) {
        if (a === d) return this._current;
        if (0 === this._items.length) return d;
        if (a = this.normalize(a), this._current !== a) {
            var b = this.trigger("change", {
                property: {
                    name: "position",
                    value: a
                }
            });
            b.data !== d && (a = this.normalize(b.data)), this._current = a, this.invalidate("position"), 
            this.trigger("changed", {
                property: {
                    name: "position",
                    value: this._current
                }
            });
        }
        return this._current;
    }, e.prototype.invalidate = function(a) {
        this._invalidated[a] = !0;
    }, e.prototype.reset = function(a) {
        a = this.normalize(a), a !== d && (this._speed = 0, this._current = a, this.suppress([ "translate", "translated" ]), 
        this.animate(this.coordinates(a)), this.release([ "translate", "translated" ]));
    }, e.prototype.normalize = function(b, c) {
        var e = c ? this._items.length : this._items.length + this._clones.length;
        return !a.isNumeric(b) || 1 > e ? d : b = this._clones.length ? (b % e + e) % e : Math.max(this.minimum(c), Math.min(this.maximum(c), b));
    }, e.prototype.relative = function(a) {
        return a = this.normalize(a), a -= this._clones.length / 2, this.normalize(a, !0);
    }, e.prototype.maximum = function(a) {
        var b, c, d, e = 0, f = this.settings;
        if (a) return this._items.length - 1;
        if (!f.loop && f.center) b = this._items.length - 1; else if (f.loop || f.center) if (f.loop || f.center) b = this._items.length + f.items; else {
            if (!f.autoWidth && !f.merge) throw "Can not detect maximum absolute position.";
            for (revert = f.rtl ? 1 : -1, c = this.$stage.width() - this.$element.width(); (d = this.coordinates(e)) && !(d * revert >= c); ) b = ++e;
        } else b = this._items.length - f.items;
        return b;
    }, e.prototype.minimum = function(a) {
        return a ? 0 : this._clones.length / 2;
    }, e.prototype.items = function(a) {
        return a === d ? this._items.slice() : (a = this.normalize(a, !0), this._items[a]);
    }, e.prototype.mergers = function(a) {
        return a === d ? this._mergers.slice() : (a = this.normalize(a, !0), this._mergers[a]);
    }, e.prototype.clones = function(b) {
        var c = this._clones.length / 2, e = c + this._items.length, f = function(a) {
            return a % 2 === 0 ? e + a / 2 : c - (a + 1) / 2;
        };
        return b === d ? a.map(this._clones, function(a, b) {
            return f(b);
        }) : a.map(this._clones, function(a, c) {
            return a === b ? f(c) : null;
        });
    }, e.prototype.speed = function(a) {
        return a !== d && (this._speed = a), this._speed;
    }, e.prototype.coordinates = function(b) {
        var c = null;
        return b === d ? a.map(this._coordinates, a.proxy(function(a, b) {
            return this.coordinates(b);
        }, this)) : (this.settings.center ? (c = this._coordinates[b], c += (this.width() - c + (this._coordinates[b - 1] || 0)) / 2 * (this.settings.rtl ? -1 : 1)) : c = this._coordinates[b - 1] || 0, 
        c);
    }, e.prototype.duration = function(a, b, c) {
        return Math.min(Math.max(Math.abs(b - a), 1), 6) * Math.abs(c || this.settings.smartSpeed);
    }, e.prototype.to = function(c, d) {
        if (this.settings.loop) {
            var e = c - this.relative(this.current()), f = this.current(), g = this.current(), h = this.current() + e, i = 0 > g - h ? !0 : !1, j = this._clones.length + this._items.length;
            h < this.settings.items && i === !1 ? (f = g + this._items.length, this.reset(f)) : h >= j - this.settings.items && i === !0 && (f = g - this._items.length, 
            this.reset(f)), b.clearTimeout(this.e._goToLoop), this.e._goToLoop = b.setTimeout(a.proxy(function() {
                this.speed(this.duration(this.current(), f + e, d)), this.current(f + e), this.update();
            }, this), 30);
        } else this.speed(this.duration(this.current(), c, d)), this.current(c), this.update();
    }, e.prototype.next = function(a) {
        a = a || !1, this.to(this.relative(this.current()) + 1, a);
    }, e.prototype.prev = function(a) {
        a = a || !1, this.to(this.relative(this.current()) - 1, a);
    }, e.prototype.transitionEnd = function(a) {
        return a !== d && (a.stopPropagation(), (a.target || a.srcElement || a.originalTarget) !== this.$stage.get(0)) ? !1 : (this.state.inMotion = !1, 
        void this.trigger("translated"));
    }, e.prototype.viewport = function() {
        var d;
        if (this.options.responsiveBaseElement !== b) d = a(this.options.responsiveBaseElement).width(); else if (b.innerWidth) d = b.innerWidth; else {
            if (!c.documentElement || !c.documentElement.clientWidth) throw "Can not detect viewport width.";
            d = c.documentElement.clientWidth;
        }
        return d;
    }, e.prototype.replace = function(b) {
        this.$stage.empty(), this._items = [], b && (b = b instanceof jQuery ? b : a(b)), 
        this.settings.nestedItemSelector && (b = b.find("." + this.settings.nestedItemSelector)), 
        b.filter(function() {
            return 1 === this.nodeType;
        }).each(a.proxy(function(a, b) {
            b = this.prepare(b), this.$stage.append(b), this._items.push(b), this._mergers.push(1 * b.find("[data-merge]").andSelf("[data-merge]").attr("data-merge") || 1);
        }, this)), this.reset(a.isNumeric(this.settings.startPosition) ? this.settings.startPosition : 0), 
        this.invalidate("items");
    }, e.prototype.add = function(a, b) {
        b = b === d ? this._items.length : this.normalize(b, !0), this.trigger("add", {
            content: a,
            position: b
        }), 0 === this._items.length || b === this._items.length ? (this.$stage.append(a), 
        this._items.push(a), this._mergers.push(1 * a.find("[data-merge]").andSelf("[data-merge]").attr("data-merge") || 1)) : (this._items[b].before(a), 
        this._items.splice(b, 0, a), this._mergers.splice(b, 0, 1 * a.find("[data-merge]").andSelf("[data-merge]").attr("data-merge") || 1)), 
        this.invalidate("items"), this.trigger("added", {
            content: a,
            position: b
        });
    }, e.prototype.remove = function(a) {
        a = this.normalize(a, !0), a !== d && (this.trigger("remove", {
            content: this._items[a],
            position: a
        }), this._items[a].remove(), this._items.splice(a, 1), this._mergers.splice(a, 1), 
        this.invalidate("items"), this.trigger("removed", {
            content: null,
            position: a
        }));
    }, e.prototype.addTriggerableEvents = function() {
        var b = a.proxy(function(b, c) {
            return a.proxy(function(a) {
                a.relatedTarget !== this && (this.suppress([ c ]), b.apply(this, [].slice.call(arguments, 1)), 
                this.release([ c ]));
            }, this);
        }, this);
        a.each({
            next: this.next,
            prev: this.prev,
            to: this.to,
            destroy: this.destroy,
            refresh: this.refresh,
            replace: this.replace,
            add: this.add,
            remove: this.remove
        }, a.proxy(function(a, c) {
            this.$element.on(a + ".owl.carousel", b(c, a + ".owl.carousel"));
        }, this));
    }, e.prototype.watchVisibility = function() {
        function c(a) {
            return a.offsetWidth > 0 && a.offsetHeight > 0;
        }
        function d() {
            c(this.$element.get(0)) && (this.$element.removeClass("owl-hidden"), this.refresh(), 
            b.clearInterval(this.e._checkVisibile));
        }
        c(this.$element.get(0)) || (this.$element.addClass("owl-hidden"), b.clearInterval(this.e._checkVisibile), 
        this.e._checkVisibile = b.setInterval(a.proxy(d, this), 500));
    }, e.prototype.preloadAutoWidthImages = function(b) {
        var c, d, e, f;
        c = 0, d = this, b.each(function(g, h) {
            e = a(h), f = new Image(), f.onload = function() {
                c++, e.attr("src", f.src), e.css("opacity", 1), c >= b.length && (d.state.imagesLoaded = !0, 
                d.initialize());
            }, f.src = e.attr("src") || e.attr("data-src") || e.attr("data-src-retina");
        });
    }, e.prototype.destroy = function() {
        this.$element.hasClass(this.settings.themeClass) && this.$element.removeClass(this.settings.themeClass), 
        this.settings.responsive !== !1 && a(b).off("resize.owl.carousel"), this.transitionEndVendor && this.off(this.$stage.get(0), this.transitionEndVendor, this.e._transitionEnd);
        for (var d in this._plugins) this._plugins[d].destroy();
        (this.settings.mouseDrag || this.settings.touchDrag) && (this.$stage.off("mousedown touchstart touchcancel"), 
        a(c).off(".owl.dragEvents"), this.$stage.get(0).onselectstart = function() {}, this.$stage.off("dragstart", function() {
            return !1;
        })), this.$element.off(".owl"), this.$stage.children(".cloned").remove(), this.e = null, 
        this.$element.removeData("owlCarousel"), this.$stage.children().contents().unwrap(), 
        this.$stage.children().unwrap(), this.$stage.unwrap();
    }, e.prototype.op = function(a, b, c) {
        var d = this.settings.rtl;
        switch (b) {
          case "<":
            return d ? a > c : c > a;

          case ">":
            return d ? c > a : a > c;

          case ">=":
            return d ? c >= a : a >= c;

          case "<=":
            return d ? a >= c : c >= a;
        }
    }, e.prototype.on = function(a, b, c, d) {
        a.addEventListener ? a.addEventListener(b, c, d) : a.attachEvent && a.attachEvent("on" + b, c);
    }, e.prototype.off = function(a, b, c, d) {
        a.removeEventListener ? a.removeEventListener(b, c, d) : a.detachEvent && a.detachEvent("on" + b, c);
    }, e.prototype.trigger = function(b, c, d) {
        var e = {
            item: {
                count: this._items.length,
                index: this.current()
            }
        }, f = a.camelCase(a.grep([ "on", b, d ], function(a) {
            return a;
        }).join("-").toLowerCase()), g = a.Event([ b, "owl", d || "carousel" ].join(".").toLowerCase(), a.extend({
            relatedTarget: this
        }, e, c));
        return this._supress[b] || (a.each(this._plugins, function(a, b) {
            b.onTrigger && b.onTrigger(g);
        }), this.$element.trigger(g), this.settings && "function" == typeof this.settings[f] && this.settings[f].apply(this, g)), 
        g;
    }, e.prototype.suppress = function(b) {
        a.each(b, a.proxy(function(a, b) {
            this._supress[b] = !0;
        }, this));
    }, e.prototype.release = function(b) {
        a.each(b, a.proxy(function(a, b) {
            delete this._supress[b];
        }, this));
    }, e.prototype.browserSupport = function() {
        if (this.support3d = j(), this.support3d) {
            this.transformVendor = i();
            var a = [ "transitionend", "webkitTransitionEnd", "transitionend", "oTransitionEnd" ];
            this.transitionEndVendor = a[h()], this.vendorName = this.transformVendor.replace(/Transform/i, ""), 
            this.vendorName = "" !== this.vendorName ? "-" + this.vendorName.toLowerCase() + "-" : "";
        }
        this.state.orientation = b.orientation;
    }, a.fn.owlCarousel = function(b) {
        return this.each(function() {
            a(this).data("owlCarousel") || a(this).data("owlCarousel", new e(this, b));
        });
    }, a.fn.owlCarousel.Constructor = e;
}(window.Zepto || window.jQuery, window, document), function(a, b) {
    var c = function(b) {
        this._core = b, this._loaded = [], this._handlers = {
            "initialized.owl.carousel change.owl.carousel": a.proxy(function(b) {
                if (b.namespace && this._core.settings && this._core.settings.lazyLoad && (b.property && "position" == b.property.name || "initialized" == b.type)) for (var c = this._core.settings, d = c.center && Math.ceil(c.items / 2) || c.items, e = c.center && -1 * d || 0, f = (b.property && b.property.value || this._core.current()) + e, g = this._core.clones().length, h = a.proxy(function(a, b) {
                    this.load(b);
                }, this); e++ < d; ) this.load(g / 2 + this._core.relative(f)), g && a.each(this._core.clones(this._core.relative(f++)), h);
            }, this)
        }, this._core.options = a.extend({}, c.Defaults, this._core.options), this._core.$element.on(this._handlers);
    };
    c.Defaults = {
        lazyLoad: !1
    }, c.prototype.load = function(c) {
        var d = this._core.$stage.children().eq(c), e = d && d.find(".owl-lazy");
        !e || a.inArray(d.get(0), this._loaded) > -1 || (e.each(a.proxy(function(c, d) {
            var e, f = a(d), g = b.devicePixelRatio > 1 && f.attr("data-src-retina") || f.attr("data-src");
            this._core.trigger("load", {
                element: f,
                url: g
            }, "lazy"), f.is("img") ? f.one("load.owl.lazy", a.proxy(function() {
                f.css("opacity", 1), this._core.trigger("loaded", {
                    element: f,
                    url: g
                }, "lazy");
            }, this)).attr("src", g) : (e = new Image(), e.onload = a.proxy(function() {
                f.css({
                    "background-image": "url(" + g + ")",
                    opacity: "1"
                }), this._core.trigger("loaded", {
                    element: f,
                    url: g
                }, "lazy");
            }, this), e.src = g);
        }, this)), this._loaded.push(d.get(0)));
    }, c.prototype.destroy = function() {
        var a, b;
        for (a in this.handlers) this._core.$element.off(a, this.handlers[a]);
        for (b in Object.getOwnPropertyNames(this)) "function" != typeof this[b] && (this[b] = null);
    }, a.fn.owlCarousel.Constructor.Plugins.Lazy = c;
}(window.Zepto || window.jQuery, window, document), function(a) {
    var b = function(c) {
        this._core = c, this._handlers = {
            "initialized.owl.carousel": a.proxy(function() {
                this._core.settings.autoHeight && this.update();
            }, this),
            "changed.owl.carousel": a.proxy(function(a) {
                this._core.settings.autoHeight && "position" == a.property.name && this.update();
            }, this),
            "loaded.owl.lazy": a.proxy(function(a) {
                this._core.settings.autoHeight && a.element.closest("." + this._core.settings.itemClass) === this._core.$stage.children().eq(this._core.current()) && this.update();
            }, this)
        }, this._core.options = a.extend({}, b.Defaults, this._core.options), this._core.$element.on(this._handlers);
    };
    b.Defaults = {
        autoHeight: !1,
        autoHeightClass: "owl-height"
    }, b.prototype.update = function() {
        this._core.$stage.parent().height(this._core.$stage.children().eq(this._core.current()).height()).addClass(this._core.settings.autoHeightClass);
    }, b.prototype.destroy = function() {
        var a, b;
        for (a in this._handlers) this._core.$element.off(a, this._handlers[a]);
        for (b in Object.getOwnPropertyNames(this)) "function" != typeof this[b] && (this[b] = null);
    }, a.fn.owlCarousel.Constructor.Plugins.AutoHeight = b;
}(window.Zepto || window.jQuery, window, document), function(a, b, c) {
    var d = function(b) {
        this._core = b, this._videos = {}, this._playing = null, this._fullscreen = !1, 
        this._handlers = {
            "resize.owl.carousel": a.proxy(function(a) {
                this._core.settings.video && !this.isInFullScreen() && a.preventDefault();
            }, this),
            "refresh.owl.carousel changed.owl.carousel": a.proxy(function() {
                this._playing && this.stop();
            }, this),
            "prepared.owl.carousel": a.proxy(function(b) {
                var c = a(b.content).find(".owl-video");
                c.length && (c.css("display", "none"), this.fetch(c, a(b.content)));
            }, this)
        }, this._core.options = a.extend({}, d.Defaults, this._core.options), this._core.$element.on(this._handlers), 
        this._core.$element.on("click.owl.video", ".owl-video-play-icon", a.proxy(function(a) {
            this.play(a);
        }, this));
    };
    d.Defaults = {
        video: !1,
        videoHeight: !1,
        videoWidth: !1
    }, d.prototype.fetch = function(a, b) {
        var c = a.attr("data-vimeo-id") ? "vimeo" : "youtube", d = a.attr("data-vimeo-id") || a.attr("data-youtube-id"), e = a.attr("data-width") || this._core.settings.videoWidth, f = a.attr("data-height") || this._core.settings.videoHeight, g = a.attr("href");
        if (!g) throw new Error("Missing video URL.");
        if (d = g.match(/(http:|https:|)\/\/(player.|www.)?(vimeo\.com|youtu(be\.com|\.be|be\.googleapis\.com))\/(video\/|embed\/|watch\?v=|v\/)?([A-Za-z0-9._%-]*)(\&\S+)?/), 
        d[3].indexOf("youtu") > -1) c = "youtube"; else {
            if (!(d[3].indexOf("vimeo") > -1)) throw new Error("Video URL not supported.");
            c = "vimeo";
        }
        d = d[6], this._videos[g] = {
            type: c,
            id: d,
            width: e,
            height: f
        }, b.attr("data-video", g), this.thumbnail(a, this._videos[g]);
    }, d.prototype.thumbnail = function(b, c) {
        var d, e, f, g = c.width && c.height ? 'style="width:' + c.width + "px;height:" + c.height + 'px;"' : "", h = b.find("img"), i = "src", j = "", k = this._core.settings, l = function(a) {
            e = '<div class="owl-video-play-icon"></div>', d = k.lazyLoad ? '<div class="owl-video-tn ' + j + '" ' + i + '="' + a + '"></div>' : '<div class="owl-video-tn" style="opacity:1;background-image:url(' + a + ')"></div>', 
            b.after(d), b.after(e);
        };
        return b.wrap('<div class="owl-video-wrapper"' + g + "></div>"), this._core.settings.lazyLoad && (i = "data-src", 
        j = "owl-lazy"), h.length ? (l(h.attr(i)), h.remove(), !1) : void ("youtube" === c.type ? (f = "http://img.youtube.com/vi/" + c.id + "/hqdefault.jpg", 
        l(f)) : "vimeo" === c.type && a.ajax({
            type: "GET",
            url: "http://vimeo.com/api/v2/video/" + c.id + ".json",
            jsonp: "callback",
            dataType: "jsonp",
            success: function(a) {
                f = a[0].thumbnail_large, l(f);
            }
        }));
    }, d.prototype.stop = function() {
        this._core.trigger("stop", null, "video"), this._playing.find(".owl-video-frame").remove(), 
        this._playing.removeClass("owl-video-playing"), this._playing = null;
    }, d.prototype.play = function(b) {
        this._core.trigger("play", null, "video"), this._playing && this.stop();
        var c, d, e = a(b.target || b.srcElement), f = e.closest("." + this._core.settings.itemClass), g = this._videos[f.attr("data-video")], h = g.width || "100%", i = g.height || this._core.$stage.height();
        "youtube" === g.type ? c = '<iframe width="' + h + '" height="' + i + '" src="http://www.youtube.com/embed/' + g.id + "?autoplay=1&v=" + g.id + '" frameborder="0" allowfullscreen></iframe>' : "vimeo" === g.type && (c = '<iframe src="http://player.vimeo.com/video/' + g.id + '?autoplay=1" width="' + h + '" height="' + i + '" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe>'), 
        f.addClass("owl-video-playing"), this._playing = f, d = a('<div style="height:' + i + "px; width:" + h + 'px" class="owl-video-frame">' + c + "</div>"), 
        e.after(d);
    }, d.prototype.isInFullScreen = function() {
        var d = c.fullscreenElement || c.mozFullScreenElement || c.webkitFullscreenElement;
        return d && a(d).parent().hasClass("owl-video-frame") && (this._core.speed(0), this._fullscreen = !0), 
        d && this._fullscreen && this._playing ? !1 : this._fullscreen ? (this._fullscreen = !1, 
        !1) : this._playing && this._core.state.orientation !== b.orientation ? (this._core.state.orientation = b.orientation, 
        !1) : !0;
    }, d.prototype.destroy = function() {
        var a, b;
        this._core.$element.off("click.owl.video");
        for (a in this._handlers) this._core.$element.off(a, this._handlers[a]);
        for (b in Object.getOwnPropertyNames(this)) "function" != typeof this[b] && (this[b] = null);
    }, a.fn.owlCarousel.Constructor.Plugins.Video = d;
}(window.Zepto || window.jQuery, window, document), function(a, b, c, d) {
    var e = function(b) {
        this.core = b, this.core.options = a.extend({}, e.Defaults, this.core.options), 
        this.swapping = !0, this.previous = d, this.next = d, this.handlers = {
            "change.owl.carousel": a.proxy(function(a) {
                "position" == a.property.name && (this.previous = this.core.current(), this.next = a.property.value);
            }, this),
            "drag.owl.carousel dragged.owl.carousel translated.owl.carousel": a.proxy(function(a) {
                this.swapping = "translated" == a.type;
            }, this),
            "translate.owl.carousel": a.proxy(function() {
                this.swapping && (this.core.options.animateOut || this.core.options.animateIn) && this.swap();
            }, this)
        }, this.core.$element.on(this.handlers);
    };
    e.Defaults = {
        animateOut: !1,
        animateIn: !1
    }, e.prototype.swap = function() {
        if (1 === this.core.settings.items && this.core.support3d) {
            this.core.speed(0);
            var b, c = a.proxy(this.clear, this), d = this.core.$stage.children().eq(this.previous), e = this.core.$stage.children().eq(this.next), f = this.core.settings.animateIn, g = this.core.settings.animateOut;
            this.core.current() !== this.previous && (g && (b = this.core.coordinates(this.previous) - this.core.coordinates(this.next), 
            d.css({
                left: b + "px"
            }).addClass("animated owl-animated-out").addClass(g).one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend", c)), 
            f && e.addClass("animated owl-animated-in").addClass(f).one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend", c));
        }
    }, e.prototype.clear = function(b) {
        a(b.target).css({
            left: ""
        }).removeClass("animated owl-animated-out owl-animated-in").removeClass(this.core.settings.animateIn).removeClass(this.core.settings.animateOut), 
        this.core.transitionEnd();
    }, e.prototype.destroy = function() {
        var a, b;
        for (a in this.handlers) this.core.$element.off(a, this.handlers[a]);
        for (b in Object.getOwnPropertyNames(this)) "function" != typeof this[b] && (this[b] = null);
    }, a.fn.owlCarousel.Constructor.Plugins.Animate = e;
}(window.Zepto || window.jQuery, window, document), function(a, b, c) {
    var d = function(b) {
        this.core = b, this.core.options = a.extend({}, d.Defaults, this.core.options), 
        this.handlers = {
            "translated.owl.carousel refreshed.owl.carousel": a.proxy(function() {
                this.autoplay();
            }, this),
            "play.owl.autoplay": a.proxy(function(a, b, c) {
                this.play(b, c);
            }, this),
            "stop.owl.autoplay": a.proxy(function() {
                this.stop();
            }, this),
            "mouseover.owl.autoplay": a.proxy(function() {
                this.core.settings.autoplayHoverPause && this.pause();
            }, this),
            "mouseleave.owl.autoplay": a.proxy(function() {
                this.core.settings.autoplayHoverPause && this.autoplay();
            }, this)
        }, this.core.$element.on(this.handlers);
    };
    d.Defaults = {
        autoplay: !1,
        autoplayTimeout: 5e3,
        autoplayHoverPause: !1,
        autoplaySpeed: !1
    }, d.prototype.autoplay = function() {
        this.core.settings.autoplay && !this.core.state.videoPlay ? (b.clearInterval(this.interval), 
        this.interval = b.setInterval(a.proxy(function() {
            this.play();
        }, this), this.core.settings.autoplayTimeout)) : b.clearInterval(this.interval);
    }, d.prototype.play = function() {
        return c.hidden === !0 || this.core.state.isTouch || this.core.state.isScrolling || this.core.state.isSwiping || this.core.state.inMotion ? void 0 : this.core.settings.autoplay === !1 ? void b.clearInterval(this.interval) : void this.core.next(this.core.settings.autoplaySpeed);
    }, d.prototype.stop = function() {
        b.clearInterval(this.interval);
    }, d.prototype.pause = function() {
        b.clearInterval(this.interval);
    }, d.prototype.destroy = function() {
        var a, c;
        b.clearInterval(this.interval);
        for (a in this.handlers) this.core.$element.off(a, this.handlers[a]);
        for (c in Object.getOwnPropertyNames(this)) "function" != typeof this[c] && (this[c] = null);
    }, a.fn.owlCarousel.Constructor.Plugins.autoplay = d;
}(window.Zepto || window.jQuery, window, document), function(a) {
    "use strict";
    var b = function(c) {
        this._core = c, this._initialized = !1, this._pages = [], this._controls = {}, this._templates = [], 
        this.$element = this._core.$element, this._overrides = {
            next: this._core.next,
            prev: this._core.prev,
            to: this._core.to
        }, this._handlers = {
            "prepared.owl.carousel": a.proxy(function(b) {
                this._core.settings.dotsData && this._templates.push(a(b.content).find("[data-dot]").andSelf("[data-dot]").attr("data-dot"));
            }, this),
            "add.owl.carousel": a.proxy(function(b) {
                this._core.settings.dotsData && this._templates.splice(b.position, 0, a(b.content).find("[data-dot]").andSelf("[data-dot]").attr("data-dot"));
            }, this),
            "remove.owl.carousel prepared.owl.carousel": a.proxy(function(a) {
                this._core.settings.dotsData && this._templates.splice(a.position, 1);
            }, this),
            "change.owl.carousel": a.proxy(function(a) {
                if ("position" == a.property.name && !this._core.state.revert && !this._core.settings.loop && this._core.settings.navRewind) {
                    var b = this._core.current(), c = this._core.maximum(), d = this._core.minimum();
                    a.data = a.property.value > c ? b >= c ? d : c : a.property.value < d ? c : a.property.value;
                }
            }, this),
            "changed.owl.carousel": a.proxy(function(a) {
                "position" == a.property.name && this.draw();
            }, this),
            "refreshed.owl.carousel": a.proxy(function() {
                this._initialized || (this.initialize(), this._initialized = !0), this._core.trigger("refresh", null, "navigation"), 
                this.update(), this.draw(), this._core.trigger("refreshed", null, "navigation");
            }, this)
        }, this._core.options = a.extend({}, b.Defaults, this._core.options), this.$element.on(this._handlers);
    };
    b.Defaults = {
        nav: !1,
        navRewind: !0,
        navText: [ "prev", "next" ],
        navSpeed: !1,
        navElement: "div",
        navContainer: !1,
        navContainerClass: "owl-nav",
        navClass: [ "owl-prev", "owl-next" ],
        slideBy: 1,
        dotClass: "owl-dot",
        dotsClass: "owl-dots",
        dots: !0,
        dotsEach: !1,
        dotData: !1,
        dotsSpeed: !1,
        dotsContainer: !1,
        controlsClass: "owl-controls"
    }, b.prototype.initialize = function() {
        var b, c, d = this._core.settings;
        d.dotsData || (this._templates = [ a("<div>").addClass(d.dotClass).append(a("<span>")).prop("outerHTML") ]), 
        d.navContainer && d.dotsContainer || (this._controls.$container = a("<div>").addClass(d.controlsClass).appendTo(this.$element)), 
        this._controls.$indicators = d.dotsContainer ? a(d.dotsContainer) : a("<div>").hide().addClass(d.dotsClass).appendTo(this._controls.$container), 
        this._controls.$indicators.on("click", "div", a.proxy(function(b) {
            var c = a(b.target).parent().is(this._controls.$indicators) ? a(b.target).index() : a(b.target).parent().index();
            b.preventDefault(), this.to(c, d.dotsSpeed);
        }, this)), b = d.navContainer ? a(d.navContainer) : a("<div>").addClass(d.navContainerClass).prependTo(this._controls.$container), 
        this._controls.$next = a("<" + d.navElement + ">"), this._controls.$previous = this._controls.$next.clone(), 
        this._controls.$previous.addClass(d.navClass[0]).html(d.navText[0]).hide().prependTo(b).on("click", a.proxy(function() {
            this.prev(d.navSpeed);
        }, this)), this._controls.$next.addClass(d.navClass[1]).html(d.navText[1]).hide().appendTo(b).on("click", a.proxy(function() {
            this.next(d.navSpeed);
        }, this));
        for (c in this._overrides) this._core[c] = a.proxy(this[c], this);
    }, b.prototype.destroy = function() {
        var a, b, c, d;
        for (a in this._handlers) this.$element.off(a, this._handlers[a]);
        for (b in this._controls) this._controls[b].remove();
        for (d in this.overides) this._core[d] = this._overrides[d];
        for (c in Object.getOwnPropertyNames(this)) "function" != typeof this[c] && (this[c] = null);
    }, b.prototype.update = function() {
        var a, b, c, d = this._core.settings, e = this._core.clones().length / 2, f = e + this._core.items().length, g = d.center || d.autoWidth || d.dotData ? 1 : d.dotsEach || d.items;
        if ("page" !== d.slideBy && (d.slideBy = Math.min(d.slideBy, d.items)), d.dots || "page" == d.slideBy) for (this._pages = [], 
        a = e, b = 0, c = 0; f > a; a++) (b >= g || 0 === b) && (this._pages.push({
            start: a - e,
            end: a - e + g - 1
        }), b = 0, ++c), b += this._core.mergers(this._core.relative(a));
    }, b.prototype.draw = function() {
        var b, c, d = "", e = this._core.settings, f = (this._core.$stage.children(), this._core.relative(this._core.current()));
        if (!e.nav || e.loop || e.navRewind || (this._controls.$previous.toggleClass("disabled", 0 >= f), 
        this._controls.$next.toggleClass("disabled", f >= this._core.maximum())), this._controls.$previous.toggle(e.nav), 
        this._controls.$next.toggle(e.nav), e.dots) {
            if (b = this._pages.length - this._controls.$indicators.children().length, e.dotData && 0 !== b) {
                for (c = 0; c < this._controls.$indicators.children().length; c++) d += this._templates[this._core.relative(c)];
                this._controls.$indicators.html(d);
            } else b > 0 ? (d = new Array(b + 1).join(this._templates[0]), this._controls.$indicators.append(d)) : 0 > b && this._controls.$indicators.children().slice(b).remove();
            this._controls.$indicators.find(".active").removeClass("active"), this._controls.$indicators.children().eq(a.inArray(this.current(), this._pages)).addClass("active");
        }
        this._controls.$indicators.toggle(e.dots);
    }, b.prototype.onTrigger = function(b) {
        var c = this._core.settings;
        b.page = {
            index: a.inArray(this.current(), this._pages),
            count: this._pages.length,
            size: c && (c.center || c.autoWidth || c.dotData ? 1 : c.dotsEach || c.items)
        };
    }, b.prototype.current = function() {
        var b = this._core.relative(this._core.current());
        return a.grep(this._pages, function(a) {
            return a.start <= b && a.end >= b;
        }).pop();
    }, b.prototype.getPosition = function(b) {
        var c, d, e = this._core.settings;
        return "page" == e.slideBy ? (c = a.inArray(this.current(), this._pages), d = this._pages.length, 
        b ? ++c : --c, c = this._pages[(c % d + d) % d].start) : (c = this._core.relative(this._core.current()), 
        d = this._core.items().length, b ? c += e.slideBy : c -= e.slideBy), c;
    }, b.prototype.next = function(b) {
        a.proxy(this._overrides.to, this._core)(this.getPosition(!0), b);
    }, b.prototype.prev = function(b) {
        a.proxy(this._overrides.to, this._core)(this.getPosition(!1), b);
    }, b.prototype.to = function(b, c, d) {
        var e;
        d ? a.proxy(this._overrides.to, this._core)(b, c) : (e = this._pages.length, a.proxy(this._overrides.to, this._core)(this._pages[(b % e + e) % e].start, c));
    }, a.fn.owlCarousel.Constructor.Plugins.Navigation = b;
}(window.Zepto || window.jQuery, window, document), function(a, b) {
    "use strict";
    var c = function(d) {
        this._core = d, this._hashes = {}, this.$element = this._core.$element, this._handlers = {
            "initialized.owl.carousel": a.proxy(function() {
                "URLHash" == this._core.settings.startPosition && a(b).trigger("hashchange.owl.navigation");
            }, this),
            "prepared.owl.carousel": a.proxy(function(b) {
                var c = a(b.content).find("[data-hash]").andSelf("[data-hash]").attr("data-hash");
                this._hashes[c] = b.content;
            }, this)
        }, this._core.options = a.extend({}, c.Defaults, this._core.options), this.$element.on(this._handlers), 
        a(b).on("hashchange.owl.navigation", a.proxy(function() {
            var a = b.location.hash.substring(1), c = this._core.$stage.children(), d = this._hashes[a] && c.index(this._hashes[a]) || 0;
            return a ? void this._core.to(d, !1, !0) : !1;
        }, this));
    };
    c.Defaults = {
        URLhashListener: !1
    }, c.prototype.destroy = function() {
        var c, d;
        a(b).off("hashchange.owl.navigation");
        for (c in this._handlers) this._core.$element.off(c, this._handlers[c]);
        for (d in Object.getOwnPropertyNames(this)) "function" != typeof this[d] && (this[d] = null);
    }, a.fn.owlCarousel.Constructor.Plugins.Hash = c;
}(window.Zepto || window.jQuery, window, document), WebFontConfig = {
    google: {
        families: [ "Roboto:400,900italic,900,700italic,700,500italic,500,400italic,300italic,300,100italic,100:latin,cyrillic-ext,latin-ext,cyrillic" ]
    }
}, jQuery.base64 = function(a) {
    function b(a, b) {
        var c = g.indexOf(a.charAt(b));
        if (-1 === c) throw "Cannot decode base64";
        return c;
    }
    function c(a) {
        var c, d, e = 0, g = a.length, h = [];
        if (a = String(a), 0 === g) return a;
        if (g % 4 !== 0) throw "Cannot decode base64";
        for (a.charAt(g - 1) === f && (e = 1, a.charAt(g - 2) === f && (e = 2), g -= 4), 
        c = 0; g > c; c += 4) d = b(a, c) << 18 | b(a, c + 1) << 12 | b(a, c + 2) << 6 | b(a, c + 3), 
        h.push(String.fromCharCode(d >> 16, d >> 8 & 255, 255 & d));
        switch (e) {
          case 1:
            d = b(a, c) << 18 | b(a, c + 1) << 12 | b(a, c + 2) << 6, h.push(String.fromCharCode(d >> 16, d >> 8 & 255));
            break;

          case 2:
            d = b(a, c) << 18 | b(a, c + 1) << 12, h.push(String.fromCharCode(d >> 16));
        }
        return h.join("");
    }
    function d(a, b) {
        var c = a.charCodeAt(b);
        if (c > 255) throw "INVALID_CHARACTER_ERR: DOM Exception 5";
        return c;
    }
    function e(a) {
        if (1 !== arguments.length) throw "SyntaxError: exactly one argument required";
        a = String(a);
        var b, c, e = [], h = a.length - a.length % 3;
        if (0 === a.length) return a;
        for (b = 0; h > b; b += 3) c = d(a, b) << 16 | d(a, b + 1) << 8 | d(a, b + 2), e.push(g.charAt(c >> 18)), 
        e.push(g.charAt(c >> 12 & 63)), e.push(g.charAt(c >> 6 & 63)), e.push(g.charAt(63 & c));
        switch (a.length - h) {
          case 1:
            c = d(a, b) << 16, e.push(g.charAt(c >> 18) + g.charAt(c >> 12 & 63) + f + f);
            break;

          case 2:
            c = d(a, b) << 16 | d(a, b + 1) << 8, e.push(g.charAt(c >> 18) + g.charAt(c >> 12 & 63) + g.charAt(c >> 6 & 63) + f);
        }
        return e.join("");
    }
    var f = "=", g = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", h = "1.0";
    return {
        decode: c,
        encode: e,
        VERSION: h
    };
}(jQuery), function() {
    var a = document.createElement("script");
    a.src = ("https:" == document.location.protocol ? "https" : "http") + "://ajax.googleapis.com/ajax/libs/webfont/1/webfont.js", 
    a.type = "text/javascript", a.async = "true";
    var b = document.getElementsByTagName("script")[0];
    b.parentNode.insertBefore(a, b);
}(), function(a) {
    function b() {
        var b = new Object();
        b = {
            i: 102,
            btn: "data-mb",
            btn_expand: a("[" + this.btn + "='expand']"),
            btn_expand_c: a("[" + this.btn + "='expand-comments']"),
            init: function() {
                c.networkTrigger(), c.headerThing(), c.shuffleThumbs(), c.categoriesTapController(), 
                c.movePanelsToSide(), c.listAdvertHeight(), c.rangeFilter(), c.createFilterTrigger(), 
                c.mbTabs(), c.expandContent(), c.modalWindows(), c.comments(), c.fakeUpload(), c.rating(), 
                c.inputAutocomplete(), c.popupWindow(), c.ajaxGalleryNavigation();
            }
        };
        var c = {
            getAttributes: function(b) {
                var c = {};
                return a(b).length && a.each(a(b)[0].attributes, function(a, b) {
                    c[b.name] = b.value;
                }), c;
            },
            networkTrigger: function() {
                function c() {
                    a(d + " a").not("[" + b.btn + "='expand-network']").each(function() {
                        a(this).offset().top > 10 ? a(d).addClass(f) : a(d).removeClass(f).removeClass(e);
                    });
                }
                var d = ".network-col", e = "expand-height", f = "unlock";
                a("[" + b.btn + '="expand-network"]').on("click", function(b) {
                    b.preventDefault(), a(d).toggleClass(e);
                }), a(window).load(function() {
                    c();
                }), a(window).resize(function() {
                    setTimeout(c, 500);
                });
            },
            headerThing: function(b) {
                var c = {
                    header: ".sticky-top",
                    initialHeight: 30,
                    affix: !0
                }, d = a.extend(!0, {}, c, b);
                d.affix && a(d.header).affix({
                    offset: {
                        top: d.initialHeight
                    }
                });
            },
            invertColors: function() {
                var c = a("[" + b.btn + "='invert-colors']");
                c.on("click", function(b) {
                    b.preventDefault(), a("html").toggleClass("inverted-colors");
                });
            },
            shuffleThumbs: function(d) {
                var e, f, g = {
                    limit: 10,
                    selector: "[" + b.btn + "='shuffle-thumbs']",
                    timeout: 500
                }, h = a.extend(!0, {}, g, d), i = a(h.selector), j = "";
                i.hover(function() {
                    j = a(this).attr("src"), f = a(this);
                    var b = c.getAttributes(a(this)), d = b["data-opt-limit"] ? b["data-opt-limit"] : h.limit, g = b["data-opt-timeout"] ? b["data-opt-timeout"] : h.timeout, i = j.lastIndexOf("."), k = j.slice(0, i - 1), l = j.slice(i, j.length), m = parseInt(j.slice(i - 1, i));
                    m++, m == d && (m = 1), f.attr("src", k + m + l), e = setInterval(function() {
                        m++, m == d && (m = 1), f.attr("src", k + m + l);
                    }, g);
                }, function() {
                    f.attr("src", j), clearInterval(e);
                });
            },
            checkIfIsParent: function(b, c) {
                var d = !1;
                return "#" == b[0] ? (0 != a(c.target).parents(b).length || a(c.target).attr("id") == b.substring(1)) && (d = !0) : (0 != a(c.target).parents(b).length || 1 == a(c.target).hasClass(b.substring(1))) && (d = !0), 
                d;
            },
            ww: function() {
                function a() {
                    var a = window, b = "inner";
                    return "innerWidth" in window || (b = "client", a = document.documentElement || document.body), 
                    {
                        width: a[b + "Width"],
                        height: a[b + "Height"]
                    };
                }
                return a().width;
            },
            categoriesTapController: function() {
                (navigator.userAgent.match(/Mobi/) || navigator.userAgent.match(/Android/)) && c.ww() > 767 && a("[" + b.btn + "='expand-mobile'] > a").on("click", function(b) {
                    return a(this).parent().hasClass("expand-content") ? !0 : (b.preventDefault(), void a(this).parent().addClass("expand-content"));
                });
            },
            movePanelsToSide: function() {
                function b() {
                    if (c.ww() < 768 && a("#sUcp").length > 0 && 0 == d) {
                        var b = a("#sUcp").clone(!0, !0), f = a("#sUcp + ul").clone(!0, !0);
                        f.removeClass("dropdown-menu").addClass("main-nav-list main-nav-list-ucp"), a(".main-nav-list").not(".main-nav-list-ucp").before("<div class='ucp-side'></div>"), 
                        a(".ucp-side").append(b).append(f), d = 1;
                    }
                    if (c.ww() < 768 && a(".guest-options-list").length > 0 && 0 == d) {
                        var f = a(".guest-options-list").clone(!0, !0);
                        f.removeClass("guest-options-list").addClass("main-nav-list main-nav-list-ucp guest-list-open"), 
                        a(".main-nav-list").not(".main-nav-list-ucp").before("<div class='ucp-side'></div>"), 
                        a(".ucp-side").append(f), d = 1;
                    }
                    if (c.ww() < 768 && a("#sLang").length > 0 && 0 == e) {
                        var b = a("#sLang").clone(!0, !0), f = a("#sLang + ul").clone(!0, !0);
                        f.removeClass("dropdown-menu").addClass("main-nav-list main-nav-list-ucp lang-side-list"), 
                        a(".main-nav-list").not(".main-nav-list-ucp").after("<div class='ucp-side ucp-bottom'></div>"), 
                        a(".ucp-side.ucp-bottom").append(b).append(f), e = 1;
                    }
                    1 == d && c.ww() > 767 && (a(".ucp-side").remove(), d = 0), 1 == e && c.ww() > 767 && (a(".ucp-side").remove(), 
                    e = 0);
                }
                var d = 0, e = 0;
                a(window).load(function() {
                    b();
                }), a(window).resize(function() {
                    b();
                });
            },
            listAdvertHeight: function(d) {
                function e() {
                    return parseInt(a(k.elem).next(k.adjustTo).height());
                }
                function f() {
                    a(k.elem).siblings(k.adjustTo).addClass("aff-siblings");
                }
                function g() {
                    return parseInt(a(k.elem).next(k.adjustTo).css("margin-bottom"));
                }
                function h() {
                    var a = 2 * e() + g() - k.adjustPX;
                    return a;
                }
                function i() {
                    if (c.ww() > 1039) {
                        var b = a(k.elem).children(".inner-col");
                        b.css("height", ""), 2 * b.height() < h() && (b.height(h()), a(k.elem).show());
                    }
                }
                var j = {
                    elem: "[" + b.btn + "='advert-height']",
                    adjustTo: ".item-col",
                    adjustPX: 1
                }, k = a.extend(!0, {}, j, d);
                a(window).load(function() {
                    setTimeout(i, 200), f();
                }), a(window).resize(function() {
                    setTimeout(i, 200);
                });
            },
            rangeFilter: function() {
                var b = a("#range_length_filter");
                b.ionRangeSlider({
                    type: "double",
                    step: 5,
                    grid: !0,
                    grid_snap: !0,
                    oldUrl: "",
                    newUrl: "",
                    onStart: function(a) {},
                    onChange: function(a) {},
                    onFinish: function(a) {
                        var c = window.location.href, d = "", e = (c.length, parseInt(b.attr("data-multiplication")) > 0 ? parseInt(b.attr("data-multiplication")) : 1), f = a.max * e, g = a.to * e, h = a.from * e, i = b.attr("data-attr-to") + "=" + g, j = b.attr("data-attr-from") + "=" + h, k = [], l = [];
                        if (console.log(e), c.indexOf("?") > -1) {
                            k = c.split("?");
                            var m = k[0];
                            k = k[1], l = k.split("&");
                            for (var n = l.length - 1; n >= 0; n--) (l[n].indexOf(b.attr("data-attr-to")) > -1 || l[n].indexOf(b.attr("data-attr-from")) > -1) && l.splice(n, 1);
                        } else var m = c;
                        h > a.min && l.push(j), g != f && l.push(i);
                        for (var o = [], p = [], n = 0; n < l.length; n++) p.push(l[n]), o += 0 == n ? "?" + l[n] : "&" + l[n];
                        d = m + o, "onpost" != b.attr("data-method") && (window.location.href = d);
                    },
                    onUpdate: function(a) {}
                });
                a("#range_length_filter").data("ionRangeSlider");
            },
            createFilterTrigger: function() {
                function d(a) {
                    a ? m.addClass(n) : m.removeClass(n);
                }
                function e(a) {
                    l.before(a), l.append(a);
                }
                function f(c) {
                    a("[" + b.btn + '="' + c + '"]').remove(), l.css("display", ""), a("[" + b.btn + "='" + k + "']").removeClass("active"), 
                    d(!1);
                }
                function g() {
                    a("[" + b.btn + "='" + k + "']").on("click", function(c) {
                        a(this).hasClass("active") ? (a("[" + b.btn + "='" + k + "']").removeClass("active"), 
                        l.slideUp(), d(!1)) : (a("[" + b.btn + "='" + k + "']").addClass("active"), l.slideDown(), 
                        d(!0), setTimeout(function() {
                            a.scrollTo(l.offset().top - 74, 1e3, {
                                easing: "easeInOutQuart"
                            });
                        }, 200));
                    });
                }
                function h() {
                    if (a("[" + b.btn + "='aside']").length && c.ww() < 768) {
                        var d = c.getAttributes(a("[" + b.btn + '="aside"]')), h = d["data-opt-filters-on"] ? d["data-opt-filters-on"] : "Show filters", l = d["data-opt-filters-off"] ? d["data-opt-filters-off"] : "Hide filters", m = "<div " + b.btn + '="' + i + '" class="row"><div class="filter-trigger-col col"><button ' + b.btn + '="' + k + '" id="' + j + '" class="btn btn-header"><span class="icon i-filters"></span><span class="sub-label sub-label-off">' + l + '</span><span class="sub-label sub-label-on">' + h + "</span></button></div></div>";
                        0 == a("[" + b.btn + "='" + k + "']").length && (e(m), g());
                    } else f(i);
                }
                var i = "aside-filter-trigger", j = "show-filters", k = "show-aside", l = (a("#" + j), 
                a("[" + b.btn + "='aside']")), m = a("body"), n = "aside-mobile-open";
                a(window).load(function() {
                    h();
                }), a(window).resize(function() {
                    setTimeout(h, 100);
                });
            },
            mbTabs: function() {
                function d() {
                    var a = c.getAttributes(e.parent().filter("." + g).children());
                    f.removeClass(g), f.filter('[data-opt-tab-content="' + a["data-opt-tab"] + '"]').addClass(g);
                }
                var e = a("[" + b.btn + "='tab']"), f = a("[" + b.btn + "='tab-content']"), g = "active";
                d(), e.on("click", function(b) {
                    var d = c.getAttributes(a(this));
                    b.preventDefault(), a(this).parent().hasClass(g) || (e.parent().removeClass(g), 
                    a(this).parent().addClass(g), f.removeClass(g), f.filter("[data-opt-tab-content='" + d["data-opt-tab"] + "']").addClass(g));
                });
            },
            expandContent: function(d) {
                function e() {
                    g.comments = a("ul#ul-comments li:gt(" + g.l + ")").clone(!0, !0), a("ul#ul-comments li:gt(" + g.l + ")").remove(), 
                    a("ul#ul-comments").after('<ul data-opt-expand-target="comments" class="ul-comments more-comments"></ul>'), 
                    a(".more-comments").append(g.comments), a("ul#ul-comments").not(".more-comments").slideDown(g.slideTime);
                }
                var f = {
                    btn: a("[" + b.btn + "='expand']"),
                    comments: "",
                    limitComments: "3",
                    slideTime: 1e3,
                    l: ""
                }, g = a.extend(!0, {}, f, d);
                g.btn.on("click", function(b) {
                    b.preventDefault();
                    var d = c.getAttributes(a(this)), e = d["data-opt-target"];
                    a(this).hasClass("active") ? (a(this).removeClass("active"), a("[data-opt-expand-target='" + e + "']").slideUp(g.slideTime)) : (a(this).addClass("active"), 
                    a("[data-opt-expand-target='" + e + "']").slideDown(g.slideTime));
                }), a("[data-opt-target='comments']").hide(), a(window).load(function() {
                    g.l = a("[data-opt-target='comments']").filter("[data-opt-limit]").length ? a("[data-opt-target='comments']").filter("[data-opt-limit]").attr("data-opt-limit") - 1 : g.limitComments - 1, 
                    setTimeout(function() {
                        var b = a("#ul-comments li").length;
                        b > g.l + 1 && (a("[data-opt-target='comments']").css("display", "inline-block"), 
                        e());
                    }, 1e3);
                });
            },
            buildNewModal: function(b, c) {
                var d, e = {}, f = a.extend(!0, {}, e, c), g = '<div id="' + f.id + '-modal" class="modal fade" tabindex="-1" role="dialog"><div class="modal-dialog"><div class="modal-content"><div class="modal-header"><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button><h4 class="modal-title">' + f.title + '</h4></div><div class="modal-body">' + b + '</div><div class="modal-footer"><button class="btn btn-default" data-dismiss="modal" type="button">' + f.closeTitle + "</button></div></div></div></div>";
                a("body").append(g), "object" == typeof b && a("#" + f.id + "-modal").find(".modal-body").text("").append(b), 
                d = a("#" + f.id + "-modal"), d.modal("show"), d.on("hidden.bs.modal", function() {
                    d.remove();
                });
            },
            modalWindows: function(d) {
                var e = {
                    btn: a("[" + b.btn + "='modal']")
                };
                e.btn.on("click", function(b) {
                    b.preventDefault();
                    var d = c.getAttributes(a(this)), e = d["data-opt-iframe-width"] ? d["data-opt-iframe-width"] : "100%", f = d["data-opt-iframe-height"] ? d["data-opt-iframe-height"] : "150px", g = {
                        rand: Math.floor(1e3 * Math.random(0, 9999)),
                        closeTitle: d["data-opt-close"] ? d["data-opt-close"] : "Close",
                        id: d.id ? d.id : "modal-" + this.rand,
                        title: d.title ? d.title : "Popup"
                    };
                    if ("iframe" == d["data-opt-type"]) {
                        var h = '<iframe src="' + d.href + '" style="width:' + e + ";height:" + f + ';"></iframe>';
                        c.buildNewModal(h, g);
                    } else "object" == typeof xhr && xhr.abort(), xhr = a.ajax({
                        url: d.href,
                        type: "GET",
                        dataType: "html",
                        cache: !1,
                        crossDomain: !1,
                        data: {},
                        success: function(b) {
                            var d = a("<div/>").html(b);
                            if (b.match(/<body>/)) var e = d.children().not("meta, link"); else var e = b;
                            c.buildNewModal(e, g);
                        },
                        error: function(a) {
                            h = a;
                        }
                    });
                });
            },
            comments: function() {
                var d = {
                    comments_container: a("[" + b.btn + '="load-comments"]'),
                    form: a("[" + b.btn + '="add-comment"]'),
                    loaded: 0,
                    newCommentID: "new-comment",
                    bodyNewClass: "comment-added",
                    scrollToTimeout: 500,
                    scrollToLength: 1e3,
                    loadComments: function() {
                        if (this.comments_container.length) {
                            var b = c.getAttributes(this.comments_container), d = b["data-opt-url"] + "?id=" + b["data-opt-id"] + "&type=" + b["data-opt-type"] + "&loaded=" + this.loaded + "&time=" + new Date().getTime();
                            1 == this.loaded ? (a("ul#ul-comments").length ? a("ul#ul-comments").before("<div id='" + this.newCommentID + "' style='display:none;'></div>") : (this.comments_container.children("p").remove().append("<div id='" + this.newCommentID + "' style='display:none;'></div>"), 
                            this.comments_container.append("<div id='" + this.newCommentID + "' style='display:none;'></div>")), 
                            a("#new-comment").load(d)) : (this.comments_container.load(d), this.loaded = 1);
                        }
                    },
                    addComment: function(c) {
                        var d = this, e = this.form.find("button[type='submit']");
                        e.on("click", function(c) {
                            c.preventDefault(), a.ajax({
                                type: "POST",
                                dataType: "json",
                                data: a(this.form).serialize(),
                                url: _basehttp + "/includes/ajax.post_comment.php",
                                cache: !1,
                                crossDomain: !1,
                                success: function(c) {
                                    "true" !== c.error && (a(d.form).find("textarea").val("").prop("disabled", !0), 
                                    a("body").addClass(d.bodyNewClass), a("body").trigger("added.mb.comment")), "true" == c.error || d.reloadComments(), 
                                    a("[" + b.btn + "='comment-alert']").html(c.info), setTimeout(function() {
                                        a("#" + d.newCommentID).slideDown(), a("#" + d.newCommentID).length && a.scrollTo(d.comments_container.offset().top - 160, d.scrollToLength, {
                                            easing: "easeInOutQuart"
                                        });
                                    }, d.scrollToTimeout), d.resetCaptha();
                                }
                            });
                        });
                    },
                    resetCaptha: function() {
                        var b = Math.floor(1e3 * Math.random() + 1);
                        a("img.captcha").attr("src", _basehttp + "/captcha.php?" + b);
                    },
                    reloadComments: function() {
                        this.loadComments();
                    }
                };
                d.loadComments(), d.addComment();
            },
            fakeUpload: function() {
                var c = a("[" + b.btn + '="fake-upload"]'), d = a('[data-opt="' + c.attr("data-opt-target") + '"]');
                c.length && c.on("click", function(a) {
                    a.preventDefault(), d.click();
                }), d.change(function() {
                    c.find(".sub-label").text(a(this).val());
                });
            },
            rating: function() {
                if (a(".ratingStars").length && a(".ratingStars").jRating({
                    rateMax: 100,
                    onSuccess: function() {
                        a("#ratingStarsMessage").text("Thanks for voting!");
                    },
                    onError: function() {
                        a("#ratingStarsMessage").text("Sorry, you've already voted on this video/gallery.");
                    }
                }, "json"), a("[" + b.btn + '="thumbs-rating"]').length) {
                    var d, e = _basehttp + "/includes/rating/jRating.php", f = a("[" + b.btn + '="thumbs-rating"]').attr("data-opt-id"), g = "Thanks for voting!", h = "Sorry, you've already voted.", i = a("[" + b.btn + '="thumbs-rating"]').attr("data-opt-type") ? a("[" + b.btn + '="thumbs-rating"]').attr("data-opt-type") : 0;
                    a("[" + b.btn + '="vote"]').click(function(b) {
                        var j = "up" == a(this).attr("data-opt-vote") ? 100 : 0;
                        d = c.getAttributes(a(this)), b.preventDefault(), a.post(e, {
                            idBox: f,
                            type: i,
                            rate: j,
                            action: "rating"
                        }, function(a) {
                            var b, e = {
                                rand: Math.floor(1e3 * Math.random(0, 9999)),
                                closeTitle: d["data-opt-close"],
                                id: "voting",
                                title: d.title
                            };
                            b = a.error ? h : g, c.buildNewModal(b, e);
                        }, "json");
                    });
                }
            },
            inputAutocomplete: function() {
                a("input#additionalUsername").length && a("input#additionalUsername").autocomplete({
                    source: function(b, c) {
                        a.getJSON(_basehttp + "/includes/mailbox/mail_autocomplete.php", {
                            term: b.term
                        }, c);
                    },
                    minLength: 3
                });
            },
            popupWindow: function() {
                function c(a, b, c, d) {
                    var e = screen.width / 2 - c / 2, f = screen.height / 2 - d / 2;
                    return window.open(a, b, "toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=no, width=" + c + ", height=" + d + ", top=" + f + ", left=" + e);
                }
                if (a("[" + b.btn + '="popup"]').length) {
                    var d = a("[" + b.btn + '="popup"]');
                    d.on("click", function(b) {
                        b.preventDefault();
                        var d = a(this).attr("href"), e = a(this).attr("title"), f = a(this).attr("data-opt-width"), g = a(this).attr("data-opt-height");
                        c(d, e, f, g);
                    });
                }
            },
//            hoverDelay: function() {
//                navigator.userAgent.match(/Mobi/) || navigator.userAgent.match(/Android/) || a("[" + b.btn + '="expand-mobile"]').mouseenter(function() {
//                    console.log("in"), a(this).addClass("hover");
//                });
//                navigator.userAgent.match(/Mobi/) || navigator.userAgent.match(/Android/) || a("[" + b.btn + '="expand-mobile"]').mouseleave(function() {
//                    that = a(this), setTimeout(function() {
//                        that.removeClass("hover");
//                    }, 250);
//                });
//            },
            ajaxGalleryNavigation: function() {
                var d = a("[" + b.btn + '="load-img"]'), e = "[" + b.btn + '="load-img"]', f = b.btn + '="ajax-container"';
                d.length && a(window).on("keyup", function(b) {
                    switch (b.which) {
                      case 37:
                        a(document).find(e).filter('[rel="prev"]').click();
                        break;

                      case 39:
                        a(document).find(e).filter('[rel="next"]').click();
                        break;

                      default:
                        return;
                    }
                    b.preventDefault();
                }), a(window).on("click", function(d) {
                    var e = "";
                    ("load-img" == a(d.target).attr(b.btn) || "load-img" == a(d.target).parent().attr(b.btn)) && (d.preventDefault(), 
                    e = "load-img" == a(d.target).attr(b.btn) ? a(d.target).attr("href") : a(d.target).parent().attr("href"), 
                    a("[" + f + "]").css("min-height", a("[" + f + "] img").height()), a("[" + f + "]").addClass("loading-img"), 
                    "object" == typeof xhr && xhr.abort(), xhr = a.ajax({
                        url: e,
                        type: "GET",
                        dataType: "html",
                        cache: !1,
                        crossDomain: !1,
                        data: {},
                        success: function(b) {
                            var d = a(b).find("[" + f + "]"), e = a(b).find("[" + f + "] img"), g = a(b).filter("title").text(), h = d.attr("data-opt-current");
                            d.addClass("loading-img");
                            var i = c.getAttributes(".loading-img"), j = {
                                rand: Math.floor(1e3 * Math.random(0, 9999)),
                                closeTitle: i["data-opt-close"] ? i["data-opt-close"] : "Close",
                                id: i.id ? i.id : "modal-" + this.rand,
                                title: i["data-opt-title"] ? i["data-opt-title"] : "Error"
                            };
                            e.on("load", function() {
                                console.log("image loaded correctly"), a("[" + f + "]").removeClass("loading-img");
                            }), e.on("error", function() {
                                c.buildNewModal("Error loading image", j);
                            }), e.attr("src", e.attr("src")), function(a, b) {
                                History.Adapter.bind(a, "statechange", function() {
                                    History.getState();
                                }), History.pushState({
                                    state: 1
                                }, g, "?image=" + h);
                            }(window), a("[" + f + "]").replaceWith(d), setTimeout(function() {
                                a(".owl-carousel").trigger("to.owl.carousel", [ parseInt(h) - 1, 0, !0 ]), a(".gallery-item-col").removeClass("active"), 
                                a(".gi-" + h).addClass("active");
                            }, 500);
                        },
                        error: function(a) {
                            console.log("ERROR " + a);
                        }
                    }));
                });
            },
            lazyLoad: function(b) {
                function c() {
                    return parseInt(a(window).height()) + parseInt(a(window).scrollTop());
                }
                function d(a) {
                    return a.attr("data-position", parseInt(a.offset().top)), parseInt(a.offset().top);
                }
                function e(b) {
                    var c = b, d = c.attr(i.originalImgAttribute);
                    d ? (c.attr("src", d), c.on("load", function() {
                        c.addClass(i.classLoaded).removeClass(i.classLoading).attr("data-position", c.offset().top), 
                        c.animate({
                            opacity: 1
                        }, i.inTimeout), console.log(c), f("remove", a(this));
                    })) : (c.addClass(i.classLoaded).removeClass(i.classLoading).attr("data-position", c.offset().top), 
                    c.animate({
                        opacity: 1
                    }, i.inTimeout)), !c.hasClass(i.classLoaded);
                }
                function f(a, b) {
                    i.loading && ("add" == a ? b.hasClass(i.classLoaded) || b.hasClass(i.classLoading) || (b.addClass(i.classLoading), 
                    b.after('<span class="loader"><span class="loader-inner ball-clip-rotate"><span></span></span></span>')) : b.next(".loader").remove());
                }
                function g() {
                    a(i.lazyImg).each(function() {
                        a(this).hasClass(i.classLoaded) || (f("add", a(this)), c() > d(a(this)) && e(a(this)));
                    });
                }
                var h = {
                    lazyImg: "[data-opt-loading='lazy']",
                    inTimeout: 500,
                    classLoading: "loading",
                    classLoaded: "loaded",
                    originalImgAttribute: "data-opts-original",
                    edgePositionAdjust: 0,
                    loading: !0
                }, i = a.extend(!0, {}, h, b);
                a(window).scroll(function() {
                    g();
                }), a(window).resize(function() {
                    g();
                }), g();
            }
        };
        return b;
    }
    var c = b();
    a(document).ready(function() {
        if (a("select").length && a("select:not([multiple])").selectpicker(), a("body").on("added.mb.comment", function(a) {
            console.log("comment added");
        }), c.init(), a.nhancedMenu({
            trigger: "#nav-trigger",
            target: !1,
            anywhereClose: !0,
            anywhereCloseBlockingElement: ".inner-nav-sec",
            anywhereCloseBlockingMaxRes: !1,
            area_class: "main-nav-open",
            maxRes: 768
        }), a.nhancedMenu({
            trigger: "#search-trigger",
            target: !1,
            anywhereClose: !0,
            anywhereCloseBlockingElement: ".search-inner-col",
            anywhereCloseBlockingMaxRes: !1,
            area_class: "search-open",
            maxRes: 480,
            onTriggerClickOpen: function() {
                a(".search-col").find("input[type='text']").focus();
            },
            onTriggerClickClose: function() {
                a(".search-col").find("input[type='text']").blur();
            }
        }), a.modalWindows({
            target: ".modal",
            trigger: "[data-toggle-modal]",
            defaultOpen: !1,
            bodyClass: "modal-open",
            nh_modalShow: function() {},
            nh_modalHide: function() {},
            nh_modalTriggerClick: function() {}
        }), a('[data-mb="slider"]').length) {
            var b = a('[data-mb="slider"]');
            b.owlCarousel({
                items: 5,
                responsive: {
                    100: {
                        items: 3,
                        nav: !0
                    },
                    1024: {
                        items: 5,
                        nav: !0
                    }
                },
                nav: !0,
                dots: !0,
                autoplay: !1,
                autoplayTimeout: 3e3,
                animateIn: "fadeIn",
                animateOut: "fadeOut",
                loop: !1,
                navText: [ "<span class='icon i-prev'></span>", "<span class='icon i-next'></span>" ],
                baseClass: "owl-carousel",
                itemClass: "owl-item",
                navContainerClass: "owl-nav",
                controlsClass: "owl-controls",
                dotClass: "owl-dot",
                dotsClass: "owl-dots",
                autoHeightClass: "owl-height",
                startPosition: b.attr("data-opt-current-img") - 1,
                checkItems: function() {
                    console.log(this);
                }
            });
            b.attr("data-opt-current-img") > 1 && a("html, body").animate({
                scrollTop: a("#singleImage").offset().top - a(".sticky-top").height() - 10 + "px"
            }, 1);
        }
        a.scrollUp({
            scrollName: "scrollUp",
            topDistance: "300",
            topSpeed: 3200,
            scrollSpeed: 800,
            easingType: "easeInOutQuart",
            animation: "fade",
            animationInSpeed: 200,
            animationOutSpeed: 200,
            scrollText: "",
            activeOverlay: !1
        });
    });
}(jQuery);