/*!
 * Glide.js v3.4.1
 * (c) 2013-2019 Jędrzej Chałubek <jedrzej.chalubek@gmail.com> (http://jedrzejchalubek.com/)
 * Released under the MIT License.
 */
!function (t, e) { "object" == typeof exports && "undefined" != typeof module ? module.exports = e() : "function" == typeof define && define.amd ? define(e) : t.Glide = e() }(this, function () { "use strict"; var n = { type: "slider", startAt: 0, perView: 1, focusAt: 0, gap: 10, autoplay: !1, hoverpause: !0, keyboard: !0, bound: !1, swipeThreshold: 80, dragThreshold: 120, perTouch: !1, touchRatio: .5, touchAngle: 45, animationDuration: 400, rewind: !0, rewindDuration: 800, animationTimingFunc: "cubic-bezier(.165, .840, .440, 1)", throttle: 10, direction: "ltr", peek: 0, breakpoints: {}, classes: { direction: { ltr: "glide--ltr", rtl: "glide--rtl" }, slider: "glide--slider", carousel: "glide--carousel", swipeable: "glide--swipeable", dragging: "glide--dragging", cloneSlide: "glide__slide--clone", activeNav: "glide__bullet--active", activeSlide: "glide__slide--active", disabledArrow: "glide__arrow--disabled" } }; function i(t, e) { if (!(t instanceof e)) throw new TypeError("Cannot call a class as a function") } var r = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (t) { return typeof t } : function (t) { return t && "function" == typeof Symbol && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t }, t = function (t, e, n) { return e && o(t.prototype, e), n && o(t, n), t }; function o(t, e) { for (var n = 0; n < e.length; n++) { var i = e[n]; i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(t, i.key, i) } } var a = Object.assign || function (t) { for (var e = 1; e < arguments.length; e++) { var n = arguments[e]; for (var i in n) Object.prototype.hasOwnProperty.call(n, i) && (t[i] = n[i]) } return t }; function y(t) { return parseInt(t) } function s(t) { return "string" == typeof t } function u(t) { var e = void 0 === t ? "undefined" : r(t); return "function" === e || "object" === e && !!t } function c(t) { return "function" == typeof t } function l(t) { return void 0 === t } function f(t) { return t.constructor === Array } function d(t, e, n) { Object.defineProperty(t, e, n) } function h(t, e) { var n = a({}, t, e); return e.hasOwnProperty("classes") && (n.classes = a({}, t.classes, e.classes), e.classes.hasOwnProperty("direction") && (n.classes.direction = a({}, t.classes.direction, e.classes.direction))), e.hasOwnProperty("breakpoints") && (n.breakpoints = a({}, t.breakpoints, e.breakpoints)), n } var v = (t(e, [{ key: "on", value: function (t, e) { if (f(t)) for (var n = 0; n < t.length; n++)this.on(t[n], e); this.hop.call(this.events, t) || (this.events[t] = []); var i = this.events[t].push(e) - 1; return { remove: function () { delete this.events[t][i] } } } }, { key: "emit", value: function (t, e) { if (f(t)) for (var n = 0; n < t.length; n++)this.emit(t[n], e); this.hop.call(this.events, t) && this.events[t].forEach(function (t) { t(e || {}) }) } }]), e); function e() { var t = 0 < arguments.length && void 0 !== arguments[0] ? arguments[0] : {}; i(this, e), this.events = t, this.hop = t.hasOwnProperty } var p = (t(m, [{ key: "mount", value: function (t) { var e = 0 < arguments.length && void 0 !== t ? t : {}; return this._e.emit("mount.before"), u(e) && (this._c = function (t, e, n) { var i = {}; for (var r in e) c(e[r]) && (i[r] = e[r](t, i, n)); for (var o in i) c(i[o].mount) && i[o].mount(); return i }(this, e, this._e)), this._e.emit("mount.after"), this } }, { key: "mutate", value: function (t) { var e = 0 < arguments.length && void 0 !== t ? t : []; return f(e) && (this._t = e), this } }, { key: "update", value: function (t) { var e = 0 < arguments.length && void 0 !== t ? t : {}; return this.settings = h(this.settings, e), e.hasOwnProperty("startAt") && (this.index = e.startAt), this._e.emit("update"), this } }, { key: "go", value: function (t) { return this._c.Run.make(t), this } }, { key: "move", value: function (t) { return this._c.Transition.disable(), this._c.Move.make(t), this } }, { key: "destroy", value: function () { return this._e.emit("destroy"), this } }, { key: "play", value: function (t) { var e = 0 < arguments.length && void 0 !== t && t; return e && (this.settings.autoplay = e), this._e.emit("play"), this } }, { key: "pause", value: function () { return this._e.emit("pause"), this } }, { key: "disable", value: function () { return this.disabled = !0, this } }, { key: "enable", value: function () { return this.disabled = !1, this } }, { key: "on", value: function (t, e) { return this._e.on(t, e), this } }, { key: "isType", value: function (t) { return this.settings.type === t } }, { key: "settings", get: function () { return this._o }, set: function (t) { u(t) && (this._o = t) } }, { key: "index", get: function () { return this._i }, set: function (t) { this._i = y(t) } }, { key: "type", get: function () { return this.settings.type } }, { key: "disabled", get: function () { return this._d }, set: function (t) { this._d = !!t } }]), m); function m(t) { var e = 1 < arguments.length && void 0 !== arguments[1] ? arguments[1] : {}; i(this, m), this._c = {}, this._t = [], this._e = new v, this.disabled = !1, this.selector = t, this.settings = h(n, e), this.index = this.settings.startAt } function g() { return (new Date).getTime() } function b(n, i, r) { var o = void 0, s = void 0, u = void 0, a = void 0, c = 0; r = r || {}; function l() { c = !1 === r.leading ? 0 : g(), o = null, a = n.apply(s, u), o || (s = u = null) } function t() { var t = g(); c || !1 !== r.leading || (c = t); var e = i - (t - c); return s = this, u = arguments, e <= 0 || i < e ? (o && (clearTimeout(o), o = null), c = t, a = n.apply(s, u), o || (s = u = null)) : o || !1 === r.trailing || (o = setTimeout(l, e)), a } return t.cancel = function () { clearTimeout(o), c = 0, o = s = u = null }, t } var w = { ltr: ["marginLeft", "marginRight"], rtl: ["marginRight", "marginLeft"] }; function _(t) { if (t && t.parentNode) { for (var e = t.parentNode.firstChild, n = []; e; e = e.nextSibling)1 === e.nodeType && e !== t && n.push(e); return n } return [] } function k(t) { return !!(t && t instanceof window.HTMLElement) } var S = '[data-glide-el="track"]'; var H = (t(T, [{ key: "on", value: function (t, e, n, i) { var r = 3 < arguments.length && void 0 !== i && i; s(t) && (t = [t]); for (var o = 0; o < t.length; o++)this.listeners[t[o]] = n, e.addEventListener(t[o], this.listeners[t[o]], r) } }, { key: "off", value: function (t, e, n) { var i = 2 < arguments.length && void 0 !== n && n; s(t) && (t = [t]); for (var r = 0; r < t.length; r++)e.removeEventListener(t[r], this.listeners[t[r]], i) } }, { key: "destroy", value: function () { delete this.listeners } }]), T); function T() { var t = 0 < arguments.length && void 0 !== arguments[0] ? arguments[0] : {}; i(this, T), this.listeners = t } var x = ["ltr", "rtl"], O = { ">": "<", "<": ">", "=": "=" }; function A(t, e) { return { modify: function (t) { return e.Direction.is("rtl") ? -t : t } } } function M(i, r, o) { var s = [function (e, n) { return { modify: function (t) { return t + n.Gaps.value * e.index } } }, function (t, e) { return { modify: function (t) { return t + e.Clones.grow / 2 } } }, function (n, i) { return { modify: function (t) { if (0 <= n.settings.focusAt) { var e = i.Peek.value; return u(e) ? t - e.before : t - e } return t } } }, function (o, s) { return { modify: function (t) { var e = s.Gaps.value, n = s.Sizes.width, i = o.settings.focusAt, r = s.Sizes.slideWidth; return "center" === i ? t - (n / 2 - r / 2) : t - r * i - e * i } } }].concat(i._t, [A]); return { mutate: function (t) { for (var e = 0; e < s.length; e++) { var n = s[e]; c(n) && c(n().modify) && (t = n(i, r, o).modify(t)) } return t } } } var C = !1; try { var P = Object.defineProperty({}, "passive", { get: function () { C = !0 } }); window.addEventListener("testPassive", null, P), window.removeEventListener("testPassive", null, P) } catch (t) { } var L = C, z = ["touchstart", "mousedown"], j = ["touchmove", "mousemove"], D = ["touchend", "touchcancel", "mouseup", "mouseleave"], E = ["mousedown", "mousemove", "mouseup", "mouseleave"]; function R(t) { return u(t) ? function (n) { return Object.keys(n).sort().reduce(function (t, e) { return t[e] = n[e], t[e], t }, {}) }(t) : {} } var W = { Html: function (e, t) { var n = { mount: function () { this.root = e.selector, this.track = this.root.querySelector(S), this.slides = Array.prototype.slice.call(this.wrapper.children).filter(function (t) { return !t.classList.contains(e.settings.classes.cloneSlide) }) } }; return d(n, "root", { get: function () { return n._r }, set: function (t) { s(t) && (t = document.querySelector(t)), k(t) && (n._r = t) } }), d(n, "track", { get: function () { return n._t }, set: function (t) { k(t) && (n._t = t) } }), d(n, "wrapper", { get: function () { return n.track.children[0] } }), n }, Translate: function (r, o, s) { var u = { set: function (t) { var e = M(r, o).mutate(t); o.Html.wrapper.style.transform = "translate3d(" + -1 * e + "px, 0px, 0px)" }, remove: function () { o.Html.wrapper.style.transform = "" } }; return s.on("move", function (t) { var e = o.Gaps.value, n = o.Sizes.length, i = o.Sizes.slideWidth; return r.isType("carousel") && o.Run.isOffset("<") ? (o.Transition.after(function () { s.emit("translate.jump"), u.set(i * (n - 1)) }), u.set(-i - e * n)) : r.isType("carousel") && o.Run.isOffset(">") ? (o.Transition.after(function () { s.emit("translate.jump"), u.set(0) }), u.set(i * n + e * n)) : u.set(t.movement) }), s.on("destroy", function () { u.remove() }), u }, Transition: function (n, i, t) { var r = !1, e = { compose: function (t) { var e = n.settings; return r ? t + " 0ms " + e.animationTimingFunc : t + " " + this.duration + "ms " + e.animationTimingFunc }, set: function (t) { var e = 0 < arguments.length && void 0 !== t ? t : "transform"; i.Html.wrapper.style.transition = this.compose(e) }, remove: function () { i.Html.wrapper.style.transition = "" }, after: function (t) { setTimeout(function () { t() }, this.duration) }, enable: function () { r = !1, this.set() }, disable: function () { r = !0, this.set() } }; return d(e, "duration", { get: function () { var t = n.settings; return n.isType("slider") && i.Run.offset ? t.rewindDuration : t.animationDuration } }), t.on("move", function () { e.set() }), t.on(["build.before", "resize", "translate.jump"], function () { e.disable() }), t.on("run", function () { e.enable() }), t.on("destroy", function () { e.remove() }), e }, Direction: function (t, e, n) { var i = { mount: function () { this.value = t.settings.direction }, resolve: function (t) { var e = t.slice(0, 1); return this.is("rtl") ? t.split(e).join(O[e]) : t }, is: function (t) { return this.value === t }, addClass: function () { e.Html.root.classList.add(t.settings.classes.direction[this.value]) }, removeClass: function () { e.Html.root.classList.remove(t.settings.classes.direction[this.value]) } }; return d(i, "value", { get: function () { return i._v }, set: function (t) { -1 < x.indexOf(t) && (i._v = t) } }), n.on(["destroy", "update"], function () { i.removeClass() }), n.on("update", function () { i.mount() }), n.on(["build.before", "update"], function () { i.addClass() }), i }, Peek: function (n, t, e) { var i = { mount: function () { this.value = n.settings.peek } }; return d(i, "value", { get: function () { return i._v }, set: function (t) { u(t) ? (t.before = y(t.before), t.after = y(t.after)) : t = y(t), i._v = t } }), d(i, "reductor", { get: function () { var t = i.value, e = n.settings.perView; return u(t) ? t.before / e + t.after / e : 2 * t / e } }), e.on(["resize", "update"], function () { i.mount() }), i }, Sizes: function (t, i, e) { var n = { setupSlides: function () { for (var t = this.slideWidth + "px", e = i.Html.slides, n = 0; n < e.length; n++)e[n].style.width = t }, setupWrapper: function (t) { i.Html.wrapper.style.width = this.wrapperSize + "px" }, remove: function () { for (var t = i.Html.slides, e = 0; e < t.length; e++)t[e].style.width = ""; i.Html.wrapper.style.width = "" } }; return d(n, "length", { get: function () { return i.Html.slides.length } }), d(n, "width", { get: function () { return i.Html.root.offsetWidth } }), d(n, "wrapperSize", { get: function () { return n.slideWidth * n.length + i.Gaps.grow + i.Clones.grow } }), d(n, "slideWidth", { get: function () { return n.width / t.settings.perView - i.Peek.reductor - i.Gaps.reductor } }), e.on(["build.before", "resize", "update"], function () { n.setupSlides(), n.setupWrapper() }), e.on("destroy", function () { n.remove() }), n }, Gaps: function (e, o, t) { var n = { apply: function (t) { for (var e = 0, n = t.length; e < n; e++) { var i = t[e].style, r = o.Direction.value; i[w[r][0]] = 0 !== e ? this.value / 2 + "px" : "", e !== t.length - 1 ? i[w[r][1]] = this.value / 2 + "px" : i[w[r][1]] = "" } }, remove: function (t) { for (var e = 0, n = t.length; e < n; e++) { var i = t[e].style; i.marginLeft = "", i.marginRight = "" } } }; return d(n, "value", { get: function () { return y(e.settings.gap) } }), d(n, "grow", { get: function () { return n.value * (o.Sizes.length - 1) } }), d(n, "reductor", { get: function () { var t = e.settings.perView; return n.value * (t - 1) / t } }), t.on(["build.after", "update"], b(function () { n.apply(o.Html.wrapper.children) }, 30)), t.on("destroy", function () { n.remove(o.Html.wrapper.children) }), n }, Move: function (t, i, r) { var e = { mount: function () { this._o = 0 }, make: function (t) { var e = this, n = 0 < arguments.length && void 0 !== t ? t : 0; this.offset = n, r.emit("move", { movement: this.value }), i.Transition.after(function () { r.emit("move.after", { movement: e.value }) }) } }; return d(e, "offset", { get: function () { return e._o }, set: function (t) { e._o = l(t) ? 0 : y(t) } }), d(e, "translate", { get: function () { return i.Sizes.slideWidth * t.index } }), d(e, "value", { get: function () { var t = this.offset, e = this.translate; return i.Direction.is("rtl") ? e + t : e - t } }), r.on(["build.before", "run"], function () { e.make() }), e }, Clones: function (v, p, t) { var e = { mount: function () { this.items = [], v.isType("carousel") && (this.items = this.collect()) }, collect: function (t) { for (var e = 0 < arguments.length && void 0 !== t ? t : [], n = p.Html.slides, i = v.settings, r = i.perView, o = i.classes, s = r + +!!v.settings.peek, u = n.slice(0, s), a = n.slice(-s), c = 0; c < Math.max(1, Math.floor(r / n.length)); c++) { for (var l = 0; l < u.length; l++) { var f = u[l].cloneNode(!0); f.classList.add(o.cloneSlide), e.push(f) } for (var d = 0; d < a.length; d++) { var h = a[d].cloneNode(!0); h.classList.add(o.cloneSlide), e.unshift(h) } } return e }, append: function () { for (var t = this.items, e = p.Html, n = e.wrapper, i = e.slides, r = Math.floor(t.length / 2), o = t.slice(0, r).reverse(), s = t.slice(r, t.length), u = p.Sizes.slideWidth + "px", a = 0; a < s.length; a++)n.appendChild(s[a]); for (var c = 0; c < o.length; c++)n.insertBefore(o[c], i[0]); for (var l = 0; l < t.length; l++)t[l].style.width = u }, remove: function () { for (var t = this.items, e = 0; e < t.length; e++)p.Html.wrapper.removeChild(t[e]) } }; return d(e, "grow", { get: function () { return (p.Sizes.slideWidth + p.Gaps.value) * e.items.length } }), t.on("update", function () { e.remove(), e.mount(), e.append() }), t.on("build.before", function () { v.isType("carousel") && e.append() }), t.on("destroy", function () { e.remove() }), e }, Resize: function (t, e, n) { var i = new H, r = { mount: function () { this.bind() }, bind: function () { i.on("resize", window, b(function () { n.emit("resize") }, t.settings.throttle)) }, unbind: function () { i.off("resize", window) } }; return n.on("destroy", function () { r.unbind(), i.destroy() }), r }, Build: function (n, i, t) { var e = { mount: function () { t.emit("build.before"), this.typeClass(), this.activeClass(), t.emit("build.after") }, typeClass: function () { i.Html.root.classList.add(n.settings.classes[n.settings.type]) }, activeClass: function () { var e = n.settings.classes, t = i.Html.slides[n.index]; t && (t.classList.add(e.activeSlide), _(t).forEach(function (t) { t.classList.remove(e.activeSlide) })) }, removeClasses: function () { var e = n.settings.classes; i.Html.root.classList.remove(e[n.settings.type]), i.Html.slides.forEach(function (t) { t.classList.remove(e.activeSlide) }) } }; return t.on(["destroy", "update"], function () { e.removeClasses() }), t.on(["resize", "update"], function () { e.mount() }), t.on("move.after", function () { e.activeClass() }), e }, Run: function (o, n, i) { var t = { mount: function () { this._o = !1 }, make: function (t) { var e = this; o.disabled || (o.disable(), this.move = t, i.emit("run.before", this.move), this.calculate(), i.emit("run", this.move), n.Transition.after(function () { e.isStart() && i.emit("run.start", e.move), e.isEnd() && i.emit("run.end", e.move), (e.isOffset("<") || e.isOffset(">")) && (e._o = !1, i.emit("run.offset", e.move)), i.emit("run.after", e.move), o.enable() })) }, calculate: function () { var t = this.move, e = this.length, n = t.steps, i = t.direction, r = function (t) { return "number" == typeof t }(y(n)) && 0 !== y(n); switch (i) { case ">": ">" === n ? o.index = e : this.isEnd() ? o.isType("slider") && !o.settings.rewind || (this._o = !0, o.index = 0) : r ? o.index += Math.min(e - o.index, -y(n)) : o.index++; break; case "<": "<" === n ? o.index = 0 : this.isStart() ? o.isType("slider") && !o.settings.rewind || (this._o = !0, o.index = e) : r ? o.index -= Math.min(o.index, y(n)) : o.index--; break; case "=": o.index = n } }, isStart: function () { return 0 === o.index }, isEnd: function () { return o.index === this.length }, isOffset: function (t) { return this._o && this.move.direction === t } }; return d(t, "move", { get: function () { return this._m }, set: function (t) { var e = t.substr(1); this._m = { direction: t.substr(0, 1), steps: e ? y(e) ? y(e) : e : 0 } } }), d(t, "length", { get: function () { var t = o.settings, e = n.Html.slides.length; return o.isType("slider") && "center" !== t.focusAt && t.bound ? e - 1 - (y(t.perView) - 1) + y(t.focusAt) : e - 1 } }), d(t, "offset", { get: function () { return this._o } }), t }, Swipe: function (d, h, v) { var n = new H, p = 0, m = 0, g = 0, i = !1, r = !!L && { passive: !0 }, t = { mount: function () { this.bindSwipeStart() }, start: function (t) { if (!i && !d.disabled) { this.disable(); var e = this.touches(t); p = null, m = y(e.pageX), g = y(e.pageY), this.bindSwipeMove(), this.bindSwipeEnd(), v.emit("swipe.start") } }, move: function (t) { if (!d.disabled) { var e = d.settings, n = e.touchAngle, i = e.touchRatio, r = e.classes, o = this.touches(t), s = y(o.pageX) - m, u = y(o.pageY) - g, a = Math.abs(s << 2), c = Math.abs(u << 2), l = Math.sqrt(a + c), f = Math.sqrt(c); if (!(180 * (p = Math.asin(f / l)) / Math.PI < n)) return !1; t.stopPropagation(), h.Move.make(s * function (t) { return parseFloat(t) }(i)), h.Html.root.classList.add(r.dragging), v.emit("swipe.move") } }, end: function (t) { if (!d.disabled) { var e = d.settings, n = this.touches(t), i = this.threshold(t), r = n.pageX - m, o = 180 * p / Math.PI, s = Math.round(r / h.Sizes.slideWidth); this.enable(), i < r && o < e.touchAngle ? (e.perTouch && (s = Math.min(s, y(e.perTouch))), h.Direction.is("rtl") && (s = -s), h.Run.make(h.Direction.resolve("<" + s))) : r < -i && o < e.touchAngle ? (e.perTouch && (s = Math.max(s, -y(e.perTouch))), h.Direction.is("rtl") && (s = -s), h.Run.make(h.Direction.resolve(">" + s))) : h.Move.make(), h.Html.root.classList.remove(e.classes.dragging), this.unbindSwipeMove(), this.unbindSwipeEnd(), v.emit("swipe.end") } }, bindSwipeStart: function () { var e = this, t = d.settings; t.swipeThreshold && n.on(z[0], h.Html.wrapper, function (t) { e.start(t) }, r), t.dragThreshold && n.on(z[1], h.Html.wrapper, function (t) { e.start(t) }, r) }, unbindSwipeStart: function () { n.off(z[0], h.Html.wrapper, r), n.off(z[1], h.Html.wrapper, r) }, bindSwipeMove: function () { var e = this; n.on(j, h.Html.wrapper, b(function (t) { e.move(t) }, d.settings.throttle), r) }, unbindSwipeMove: function () { n.off(j, h.Html.wrapper, r) }, bindSwipeEnd: function () { var e = this; n.on(D, h.Html.wrapper, function (t) { e.end(t) }) }, unbindSwipeEnd: function () { n.off(D, h.Html.wrapper) }, touches: function (t) { return -1 < E.indexOf(t.type) ? t : t.touches[0] || t.changedTouches[0] }, threshold: function (t) { var e = d.settings; return -1 < E.indexOf(t.type) ? e.dragThreshold : e.swipeThreshold }, enable: function () { return i = !1, h.Transition.enable(), this }, disable: function () { return i = !0, h.Transition.disable(), this } }; return v.on("build.after", function () { h.Html.root.classList.add(d.settings.classes.swipeable) }), v.on("destroy", function () { t.unbindSwipeStart(), t.unbindSwipeMove(), t.unbindSwipeEnd(), n.destroy() }), t }, Images: function (t, e, n) { var i = new H, r = { mount: function () { this.bind() }, bind: function () { i.on("dragstart", e.Html.wrapper, this.dragstart) }, unbind: function () { i.off("dragstart", e.Html.wrapper) }, dragstart: function (t) { t.preventDefault() } }; return n.on("destroy", function () { r.unbind(), i.destroy() }), r }, Anchors: function (t, e, n) { var i = new H, r = !1, o = !1, s = { mount: function () { this._a = e.Html.wrapper.querySelectorAll("a"), this.bind() }, bind: function () { i.on("click", e.Html.wrapper, this.click) }, unbind: function () { i.off("click", e.Html.wrapper) }, click: function (t) { o && (t.stopPropagation(), t.preventDefault()) }, detach: function () { if (o = !0, !r) { for (var t = 0; t < this.items.length; t++)this.items[t].draggable = !1, this.items[t].setAttribute("data-href", this.items[t].getAttribute("href")), this.items[t].removeAttribute("href"); r = !0 } return this }, attach: function () { if (o = !1, r) { for (var t = 0; t < this.items.length; t++)this.items[t].draggable = !0, this.items[t].setAttribute("href", this.items[t].getAttribute("data-href")); r = !1 } return this } }; return d(s, "items", { get: function () { return s._a } }), n.on("swipe.move", function () { s.detach() }), n.on("swipe.end", function () { e.Transition.after(function () { s.attach() }) }), n.on("destroy", function () { s.attach(), s.unbind(), i.destroy() }), s }, Controls: function (i, e, t) { var n = new H, r = !!L && { passive: !0 }, o = { mount: function () { this._n = e.Html.root.querySelectorAll('[data-glide-el="controls[nav]"]'), this._c = e.Html.root.querySelectorAll('[data-glide-el^="controls"]'), this.addBindings() }, setActive: function () { for (var t = 0; t < this._n.length; t++)this.addClass(this._n[t].children) }, removeActive: function () { for (var t = 0; t < this._n.length; t++)this.removeClass(this._n[t].children) }, addClass: function (t) { var e = i.settings, n = t[i.index]; n && (n.classList.add(e.classes.activeNav), _(n).forEach(function (t) { t.classList.remove(e.classes.activeNav) })) }, removeClass: function (t) { var e = t[i.index]; e && e.classList.remove(i.settings.classes.activeNav) }, addBindings: function () { for (var t = 0; t < this._c.length; t++)this.bind(this._c[t].children) }, removeBindings: function () { for (var t = 0; t < this._c.length; t++)this.unbind(this._c[t].children) }, bind: function (t) { for (var e = 0; e < t.length; e++)n.on("click", t[e], this.click), n.on("touchstart", t[e], this.click, r) }, unbind: function (t) { for (var e = 0; e < t.length; e++)n.off(["click", "touchstart"], t[e]) }, click: function (t) { t.preventDefault(), e.Run.make(e.Direction.resolve(t.currentTarget.getAttribute("data-glide-dir"))) } }; return d(o, "items", { get: function () { return o._c } }), t.on(["mount.after", "move.after"], function () { o.setActive() }), t.on("destroy", function () { o.removeBindings(), o.removeActive(), n.destroy() }), o }, Keyboard: function (t, e, n) { var i = new H, r = { mount: function () { t.settings.keyboard && this.bind() }, bind: function () { i.on("keyup", document, this.press) }, unbind: function () { i.off("keyup", document) }, press: function (t) { 39 === t.keyCode && e.Run.make(e.Direction.resolve(">")), 37 === t.keyCode && e.Run.make(e.Direction.resolve("<")) } }; return n.on(["destroy", "update"], function () { r.unbind() }), n.on("update", function () { r.mount() }), n.on("destroy", function () { i.destroy() }), r }, Autoplay: function (e, n, t) { var i = new H, r = { mount: function () { this.start(), e.settings.hoverpause && this.bind() }, start: function () { var t = this; e.settings.autoplay && l(this._i) && (this._i = setInterval(function () { t.stop(), n.Run.make(">"), t.start() }, this.time)) }, stop: function () { this._i = clearInterval(this._i) }, bind: function () { var t = this; i.on("mouseover", n.Html.root, function () { t.stop() }), i.on("mouseout", n.Html.root, function () { t.start() }) }, unbind: function () { i.off(["mouseover", "mouseout"], n.Html.root) } }; return d(r, "time", { get: function () { var t = n.Html.slides[e.index].getAttribute("data-glide-autoplay"); return y(t || e.settings.autoplay) } }), t.on(["destroy", "update"], function () { r.unbind() }), t.on(["run.before", "pause", "destroy", "swipe.start", "update"], function () { r.stop() }), t.on(["run.after", "play", "swipe.end"], function () { r.start() }), t.on("update", function () { r.mount() }), t.on("destroy", function () { i.destroy() }), r }, Breakpoints: function (t, e, n) { var i = new H, r = t.settings, o = R(r.breakpoints), s = a({}, r), u = { match: function (t) { if (void 0 !== window.matchMedia) for (var e in t) if (t.hasOwnProperty(e) && window.matchMedia("(max-width: " + e + "px)").matches) return t[e]; return s } }; return a(r, u.match(o)), i.on("resize", window, b(function () { t.settings = h(r, u.match(o)) }, t.settings.throttle)), n.on("update", function () { o = R(o), s = a({}, r) }), n.on("destroy", function () { i.off("resize", window) }), u } }; function G() { return i(this, G), function (t, e) { if (!t) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); return !e || "object" != typeof e && "function" != typeof e ? t : e }(this, (G.__proto__ || Object.getPrototypeOf(G)).apply(this, arguments)) } return function (t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function, not " + typeof e); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, enumerable: !1, writable: !0, configurable: !0 } }), e && (Object.setPrototypeOf ? Object.setPrototypeOf(t, e) : t.__proto__ = e) }(G, p), t(G, [{ key: "mount", value: function (t) { var e = 0 < arguments.length && void 0 !== t ? t : {}; return function t(e, n, i) { null === e && (e = Function.prototype); var r = Object.getOwnPropertyDescriptor(e, n); if (void 0 === r) { var o = Object.getPrototypeOf(e); return null === o ? void 0 : t(o, n, i) } if ("value" in r) return r.value; var s = r.get; return void 0 !== s ? s.call(i) : void 0 }(G.prototype.__proto__ || Object.getPrototypeOf(G.prototype), "mount", this).call(this, a({}, W, e)) } }]), G });;
jQuery(document).ready(function(){$(".hamburger").click(function(){$(this).toggleClass("is-active");$(".menu__inner--menu").slideToggle();$(".menu").toggleClass("open")})});
jQuery(document).ready(function(){if(document.querySelector(".counter")!=null){var a=0;$(window).scroll(function(){var oTop=$(".counter").offset().top-window.innerHeight;a==0&&$(window).scrollTop()>oTop&&($(".counter-value").each(function(){var $this=$(this),countTo=$this.attr("data-count");$({countNum:$this.text()}).animate({countNum:countTo},{duration:2e3,easing:"swing",step:function(){$this.text(Math.floor(this.countNum))},complete:function(){$this.text(this.countNum)}})}),a=1)})}});
function triggerScripts(){runScripts();clearTimeout(autoLoadDuration);eventList.forEach(function(t){window.removeEventListener(t,triggerScripts,{passive:!0})})}function runScripts(){document.querySelectorAll("script[delay]").forEach(function(t){t.setAttribute("src",t.getAttribute("delay"))})}const autoLoadDuration=setTimeout(runScripts,3e3),eventList=["keydown","mousemove","wheel","touchmove","touchstart","touchend"];eventList.forEach(function(t){window.addEventListener(t,triggerScripts,{passive:!0})});
jQuery(document).ready(function(){var logoCarousels,reviewCarousels,teamCarousels;try{new Glide(".glideHeroSlider",{type:"slider",startAt:0,perView:1,autoplay:!1,gap:0}).mount()}catch(err){}try{new Glide(".glideCarousel",{type:"carousel",startAt:0,perView:3,autoplay:!1,gap:30,breakpoints:{992:{perView:2}}}).mount()}catch(err){}logoCarousels=document.querySelectorAll(".glideLogoCarousel");try{logoCarousels.forEach(item=>{new Glide(item,{type:"carousel",startAt:0,perView:4,autoplay:!1,gap:30,breakpoints:{992:{perView:2}}}).mount()})}catch(err){}reviewCarousels=document.querySelectorAll(".reviewsCarousel");try{reviewCarousels.forEach(item=>{new Glide(item,{type:"carousel",startAt:0,perView:1.5,autoplay:5e3,gap:0,breakpoints:{1100:{perView:1}}}).mount()})}catch(err){}teamCarousels=document.querySelectorAll(".teamCarousel");try{teamCarousels.forEach(item=>{new Glide(item,{type:"carousel",startAt:0,perView:3,autoplay:5e3,gap:25,breakpoints:{1100:{perView:1}}}).mount()})}catch(err){}});
/*! lazysizes - v5.3.2 */
!function (e) { var t = function (u, D, f) { "use strict"; var k, H; if (function () { var e; var t = { lazyClass: "lazyload", loadedClass: "lazyloaded", loadingClass: "lazyloading", preloadClass: "lazypreload", errorClass: "lazyerror", autosizesClass: "lazyautosizes", fastLoadedClass: "ls-is-cached", iframeLoadMode: 0, srcAttr: "data-src", srcsetAttr: "data-srcset", sizesAttr: "data-sizes", minSize: 40, customMedia: {}, init: true, expFactor: 1.5, hFac: .8, loadMode: 2, loadHidden: true, ricTimeout: 0, throttleDelay: 125 }; H = u.lazySizesConfig || u.lazysizesConfig || {}; for (e in t) { if (!(e in H)) { H[e] = t[e] } } }(), !D || !D.getElementsByClassName) { return { init: function () { }, cfg: H, noSupport: true } } var O = D.documentElement, i = u.HTMLPictureElement, P = "addEventListener", $ = "getAttribute", q = u[P].bind(u), I = u.setTimeout, U = u.requestAnimationFrame || I, o = u.requestIdleCallback, j = /^picture$/i, r = ["load", "error", "lazyincluded", "_lazyloaded"], a = {}, G = Array.prototype.forEach, J = function (e, t) { if (!a[t]) { a[t] = new RegExp("(\\s|^)" + t + "(\\s|$)") } return a[t].test(e[$]("class") || "") && a[t] }, K = function (e, t) { if (!J(e, t)) { e.setAttribute("class", (e[$]("class") || "").trim() + " " + t) } }, Q = function (e, t) { var a; if (a = J(e, t)) { e.setAttribute("class", (e[$]("class") || "").replace(a, " ")) } }, V = function (t, a, e) { var i = e ? P : "removeEventListener"; if (e) { V(t, a) } r.forEach(function (e) { t[i](e, a) }) }, X = function (e, t, a, i, r) { var n = D.createEvent("Event"); if (!a) { a = {} } a.instance = k; n.initEvent(t, !i, !r); n.detail = a; e.dispatchEvent(n); return n }, Y = function (e, t) { var a; if (!i && (a = u.picturefill || H.pf)) { if (t && t.src && !e[$]("srcset")) { e.setAttribute("srcset", t.src) } a({ reevaluate: true, elements: [e] }) } else if (t && t.src) { e.src = t.src } }, Z = function (e, t) { return (getComputedStyle(e, null) || {})[t] }, s = function (e, t, a) { a = a || e.offsetWidth; while (a < H.minSize && t && !e._lazysizesWidth) { a = t.offsetWidth; t = t.parentNode } return a }, ee = function () { var a, i; var t = []; var r = []; var n = t; var s = function () { var e = n; n = t.length ? r : t; a = true; i = false; while (e.length) { e.shift()() } a = false }; var e = function (e, t) { if (a && !t) { e.apply(this, arguments) } else { n.push(e); if (!i) { i = true; (D.hidden ? I : U)(s) } } }; e._lsFlush = s; return e }(), te = function (a, e) { return e ? function () { ee(a) } : function () { var e = this; var t = arguments; ee(function () { a.apply(e, t) }) } }, ae = function (e) { var a; var i = 0; var r = H.throttleDelay; var n = H.ricTimeout; var t = function () { a = false; i = f.now(); e() }; var s = o && n > 49 ? function () { o(t, { timeout: n }); if (n !== H.ricTimeout) { n = H.ricTimeout } } : te(function () { I(t) }, true); return function (e) { var t; if (e = e === true) { n = 33 } if (a) { return } a = true; t = r - (f.now() - i); if (t < 0) { t = 0 } if (e || t < 9) { s() } else { I(s, t) } } }, ie = function (e) { var t, a; var i = 99; var r = function () { t = null; e() }; var n = function () { var e = f.now() - a; if (e < i) { I(n, i - e) } else { (o || r)(r) } }; return function () { a = f.now(); if (!t) { t = I(n, i) } } }, e = function () { var v, m, c, h, e; var y, z, g, p, C, b, A; var n = /^img$/i; var d = /^iframe$/i; var E = "onscroll" in u && !/(gle|ing)bot/.test(navigator.userAgent); var _ = 0; var w = 0; var M = 0; var N = -1; var L = function (e) { M--; if (!e || M < 0 || !e.target) { M = 0 } }; var x = function (e) { if (A == null) { A = Z(D.body, "visibility") == "hidden" } return A || !(Z(e.parentNode, "visibility") == "hidden" && Z(e, "visibility") == "hidden") }; var W = function (e, t) { var a; var i = e; var r = x(e); g -= t; b += t; p -= t; C += t; while (r && (i = i.offsetParent) && i != D.body && i != O) { r = (Z(i, "opacity") || 1) > 0; if (r && Z(i, "overflow") != "visible") { a = i.getBoundingClientRect(); r = C > a.left && p < a.right && b > a.top - 1 && g < a.bottom + 1 } } return r }; var t = function () { var e, t, a, i, r, n, s, o, l, u, f, c; var d = k.elements; if ((h = H.loadMode) && M < 8 && (e = d.length)) { t = 0; N++; for (; t < e; t++) { if (!d[t] || d[t]._lazyRace) { continue } if (!E || k.prematureUnveil && k.prematureUnveil(d[t])) { R(d[t]); continue } if (!(o = d[t][$]("data-expand")) || !(n = o * 1)) { n = w } if (!u) { u = !H.expand || H.expand < 1 ? O.clientHeight > 500 && O.clientWidth > 500 ? 500 : 370 : H.expand; k._defEx = u; f = u * H.expFactor; c = H.hFac; A = null; if (w < f && M < 1 && N > 2 && h > 2 && !D.hidden) { w = f; N = 0 } else if (h > 1 && N > 1 && M < 6) { w = u } else { w = _ } } if (l !== n) { y = innerWidth + n * c; z = innerHeight + n; s = n * -1; l = n } a = d[t].getBoundingClientRect(); if ((b = a.bottom) >= s && (g = a.top) <= z && (C = a.right) >= s * c && (p = a.left) <= y && (b || C || p || g) && (H.loadHidden || x(d[t])) && (m && M < 3 && !o && (h < 3 || N < 4) || W(d[t], n))) { R(d[t]); r = true; if (M > 9) { break } } else if (!r && m && !i && M < 4 && N < 4 && h > 2 && (v[0] || H.preloadAfterLoad) && (v[0] || !o && (b || C || p || g || d[t][$](H.sizesAttr) != "auto"))) { i = v[0] || d[t] } } if (i && !r) { R(i) } } }; var a = ae(t); var S = function (e) { var t = e.target; if (t._lazyCache) { delete t._lazyCache; return } L(e); K(t, H.loadedClass); Q(t, H.loadingClass); V(t, B); X(t, "lazyloaded") }; var i = te(S); var B = function (e) { i({ target: e.target }) }; var T = function (e, t) { var a = e.getAttribute("data-load-mode") || H.iframeLoadMode; if (a == 0) { e.contentWindow.location.replace(t) } else if (a == 1) { e.src = t } }; var F = function (e) { var t; var a = e[$](H.srcsetAttr); if (t = H.customMedia[e[$]("data-media") || e[$]("media")]) { e.setAttribute("media", t) } if (a) { e.setAttribute("srcset", a) } }; var s = te(function (t, e, a, i, r) { var n, s, o, l, u, f; if (!(u = X(t, "lazybeforeunveil", e)).defaultPrevented) { if (i) { if (a) { K(t, H.autosizesClass) } else { t.setAttribute("sizes", i) } } s = t[$](H.srcsetAttr); n = t[$](H.srcAttr); if (r) { o = t.parentNode; l = o && j.test(o.nodeName || "") } f = e.firesLoad || "src" in t && (s || n || l); u = { target: t }; K(t, H.loadingClass); if (f) { clearTimeout(c); c = I(L, 2500); V(t, B, true) } if (l) { G.call(o.getElementsByTagName("source"), F) } if (s) { t.setAttribute("srcset", s) } else if (n && !l) { if (d.test(t.nodeName)) { T(t, n) } else { t.src = n } } if (r && (s || l)) { Y(t, { src: n }) } } if (t._lazyRace) { delete t._lazyRace } Q(t, H.lazyClass); ee(function () { var e = t.complete && t.naturalWidth > 1; if (!f || e) { if (e) { K(t, H.fastLoadedClass) } S(u); t._lazyCache = true; I(function () { if ("_lazyCache" in t) { delete t._lazyCache } }, 9) } if (t.loading == "lazy") { M-- } }, true) }); var R = function (e) { if (e._lazyRace) { return } var t; var a = n.test(e.nodeName); var i = a && (e[$](H.sizesAttr) || e[$]("sizes")); var r = i == "auto"; if ((r || !m) && a && (e[$]("src") || e.srcset) && !e.complete && !J(e, H.errorClass) && J(e, H.lazyClass)) { return } t = X(e, "lazyunveilread").detail; if (r) { re.updateElem(e, true, e.offsetWidth) } e._lazyRace = true; M++; s(e, t, r, i, a) }; var r = ie(function () { H.loadMode = 3; a() }); var o = function () { if (H.loadMode == 3) { H.loadMode = 2 } r() }; var l = function () { if (m) { return } if (f.now() - e < 999) { I(l, 999); return } m = true; H.loadMode = 3; a(); q("scroll", o, true) }; return { _: function () { e = f.now(); k.elements = D.getElementsByClassName(H.lazyClass); v = D.getElementsByClassName(H.lazyClass + " " + H.preloadClass); q("scroll", a, true); q("resize", a, true); q("pageshow", function (e) { if (e.persisted) { var t = D.querySelectorAll("." + H.loadingClass); if (t.length && t.forEach) { U(function () { t.forEach(function (e) { if (e.complete) { R(e) } }) }) } } }); if (u.MutationObserver) { new MutationObserver(a).observe(O, { childList: true, subtree: true, attributes: true }) } else { O[P]("DOMNodeInserted", a, true); O[P]("DOMAttrModified", a, true); setInterval(a, 999) } q("hashchange", a, true);["focus", "mouseover", "click", "load", "transitionend", "animationend"].forEach(function (e) { D[P](e, a, true) }); if (/d$|^c/.test(D.readyState)) { l() } else { q("load", l); D[P]("DOMContentLoaded", a); I(l, 2e4) } if (k.elements.length) { t(); ee._lsFlush() } else { a() } }, checkElems: a, unveil: R, _aLSL: o } }(), re = function () { var a; var n = te(function (e, t, a, i) { var r, n, s; e._lazysizesWidth = i; i += "px"; e.setAttribute("sizes", i); if (j.test(t.nodeName || "")) { r = t.getElementsByTagName("source"); for (n = 0, s = r.length; n < s; n++) { r[n].setAttribute("sizes", i) } } if (!a.detail.dataAttr) { Y(e, a.detail) } }); var i = function (e, t, a) { var i; var r = e.parentNode; if (r) { a = s(e, r, a); i = X(e, "lazybeforesizes", { width: a, dataAttr: !!t }); if (!i.defaultPrevented) { a = i.detail.width; if (a && a !== e._lazysizesWidth) { n(e, r, i, a) } } } }; var e = function () { var e; var t = a.length; if (t) { e = 0; for (; e < t; e++) { i(a[e]) } } }; var t = ie(e); return { _: function () { a = D.getElementsByClassName(H.autosizesClass); q("resize", t) }, checkElems: t, updateElem: i } }(), t = function () { if (!t.i && D.getElementsByClassName) { t.i = true; re._(); e._() } }; return I(function () { H.init && t() }), k = { cfg: H, autoSizer: re, loader: e, init: t, uP: Y, aC: K, rC: Q, hC: J, fire: X, gW: s, rAF: ee } }(e, e.document, Date); e.lazySizes = t, "object" == typeof module && module.exports && (module.exports = t) }("undefined" != typeof window ? window : {});;
/*! picturefill - v3.0.2 - 2016-02-12
 * https://scottjehl.github.io/picturefill/
 * Copyright (c) 2016 https://github.com/scottjehl/picturefill/blob/master/Authors.txt; Licensed MIT
 */
!function(a){var b=navigator.userAgent;a.HTMLPictureElement&&/ecko/.test(b)&&b.match(/rv\:(\d+)/)&&RegExp.$1<45&&addEventListener("resize",function(){var b,c=document.createElement("source"),d=function(a){var b,d,e=a.parentNode;"PICTURE"===e.nodeName.toUpperCase()?(b=c.cloneNode(),e.insertBefore(b,e.firstElementChild),setTimeout(function(){e.removeChild(b)})):(!a._pfLastSize||a.offsetWidth>a._pfLastSize)&&(a._pfLastSize=a.offsetWidth,d=a.sizes,a.sizes+=",100vw",setTimeout(function(){a.sizes=d}))},e=function(){var a,b=document.querySelectorAll("picture > img, img[srcset][sizes]");for(a=0;a<b.length;a++)d(b[a])},f=function(){clearTimeout(b),b=setTimeout(e,99)},g=a.matchMedia&&matchMedia("(orientation: landscape)"),h=function(){f(),g&&g.addListener&&g.addListener(f)};return c.srcset="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",/^[c|i]|d$/.test(document.readyState||"")?h():document.addEventListener("DOMContentLoaded",h),f}())}(window),function(a,b,c){"use strict";function d(a){return" "===a||"	"===a||"\n"===a||"\f"===a||"\r"===a}function e(b,c){var d=new a.Image;return d.onerror=function(){A[b]=!1,ba()},d.onload=function(){A[b]=1===d.width,ba()},d.src=c,"pending"}function f(){M=!1,P=a.devicePixelRatio,N={},O={},s.DPR=P||1,Q.width=Math.max(a.innerWidth||0,z.clientWidth),Q.height=Math.max(a.innerHeight||0,z.clientHeight),Q.vw=Q.width/100,Q.vh=Q.height/100,r=[Q.height,Q.width,P].join("-"),Q.em=s.getEmValue(),Q.rem=Q.em}function g(a,b,c,d){var e,f,g,h;return"saveData"===B.algorithm?a>2.7?h=c+1:(f=b-c,e=Math.pow(a-.6,1.5),g=f*e,d&&(g+=.1*e),h=a+g):h=c>1?Math.sqrt(a*b):a,h>c}function h(a){var b,c=s.getSet(a),d=!1;"pending"!==c&&(d=r,c&&(b=s.setRes(c),s.applySetCandidate(b,a))),a[s.ns].evaled=d}function i(a,b){return a.res-b.res}function j(a,b,c){var d;return!c&&b&&(c=a[s.ns].sets,c=c&&c[c.length-1]),d=k(b,c),d&&(b=s.makeUrl(b),a[s.ns].curSrc=b,a[s.ns].curCan=d,d.res||aa(d,d.set.sizes)),d}function k(a,b){var c,d,e;if(a&&b)for(e=s.parseSet(b),a=s.makeUrl(a),c=0;c<e.length;c++)if(a===s.makeUrl(e[c].url)){d=e[c];break}return d}function l(a,b){var c,d,e,f,g=a.getElementsByTagName("source");for(c=0,d=g.length;d>c;c++)e=g[c],e[s.ns]=!0,f=e.getAttribute("srcset"),f&&b.push({srcset:f,media:e.getAttribute("media"),type:e.getAttribute("type"),sizes:e.getAttribute("sizes")})}function m(a,b){function c(b){var c,d=b.exec(a.substring(m));return d?(c=d[0],m+=c.length,c):void 0}function e(){var a,c,d,e,f,i,j,k,l,m=!1,o={};for(e=0;e<h.length;e++)f=h[e],i=f[f.length-1],j=f.substring(0,f.length-1),k=parseInt(j,10),l=parseFloat(j),X.test(j)&&"w"===i?((a||c)&&(m=!0),0===k?m=!0:a=k):Y.test(j)&&"x"===i?((a||c||d)&&(m=!0),0>l?m=!0:c=l):X.test(j)&&"h"===i?((d||c)&&(m=!0),0===k?m=!0:d=k):m=!0;m||(o.url=g,a&&(o.w=a),c&&(o.d=c),d&&(o.h=d),d||c||a||(o.d=1),1===o.d&&(b.has1x=!0),o.set=b,n.push(o))}function f(){for(c(T),i="",j="in descriptor";;){if(k=a.charAt(m),"in descriptor"===j)if(d(k))i&&(h.push(i),i="",j="after descriptor");else{if(","===k)return m+=1,i&&h.push(i),void e();if("("===k)i+=k,j="in parens";else{if(""===k)return i&&h.push(i),void e();i+=k}}else if("in parens"===j)if(")"===k)i+=k,j="in descriptor";else{if(""===k)return h.push(i),void e();i+=k}else if("after descriptor"===j)if(d(k));else{if(""===k)return void e();j="in descriptor",m-=1}m+=1}}for(var g,h,i,j,k,l=a.length,m=0,n=[];;){if(c(U),m>=l)return n;g=c(V),h=[],","===g.slice(-1)?(g=g.replace(W,""),e()):f()}}function n(a){function b(a){function b(){f&&(g.push(f),f="")}function c(){g[0]&&(h.push(g),g=[])}for(var e,f="",g=[],h=[],i=0,j=0,k=!1;;){if(e=a.charAt(j),""===e)return b(),c(),h;if(k){if("*"===e&&"/"===a[j+1]){k=!1,j+=2,b();continue}j+=1}else{if(d(e)){if(a.charAt(j-1)&&d(a.charAt(j-1))||!f){j+=1;continue}if(0===i){b(),j+=1;continue}e=" "}else if("("===e)i+=1;else if(")"===e)i-=1;else{if(","===e){b(),c(),j+=1;continue}if("/"===e&&"*"===a.charAt(j+1)){k=!0,j+=2;continue}}f+=e,j+=1}}}function c(a){return k.test(a)&&parseFloat(a)>=0?!0:l.test(a)?!0:"0"===a||"-0"===a||"+0"===a?!0:!1}var e,f,g,h,i,j,k=/^(?:[+-]?[0-9]+|[0-9]*\.[0-9]+)(?:[eE][+-]?[0-9]+)?(?:ch|cm|em|ex|in|mm|pc|pt|px|rem|vh|vmin|vmax|vw)$/i,l=/^calc\((?:[0-9a-z \.\+\-\*\/\(\)]+)\)$/i;for(f=b(a),g=f.length,e=0;g>e;e++)if(h=f[e],i=h[h.length-1],c(i)){if(j=i,h.pop(),0===h.length)return j;if(h=h.join(" "),s.matchesMedia(h))return j}return"100vw"}b.createElement("picture");var o,p,q,r,s={},t=!1,u=function(){},v=b.createElement("img"),w=v.getAttribute,x=v.setAttribute,y=v.removeAttribute,z=b.documentElement,A={},B={algorithm:""},C="data-pfsrc",D=C+"set",E=navigator.userAgent,F=/rident/.test(E)||/ecko/.test(E)&&E.match(/rv\:(\d+)/)&&RegExp.$1>35,G="currentSrc",H=/\s+\+?\d+(e\d+)?w/,I=/(\([^)]+\))?\s*(.+)/,J=a.picturefillCFG,K="position:absolute;left:0;visibility:hidden;display:block;padding:0;border:none;font-size:1em;width:1em;overflow:hidden;clip:rect(0px, 0px, 0px, 0px)",L="font-size:100%!important;",M=!0,N={},O={},P=a.devicePixelRatio,Q={px:1,"in":96},R=b.createElement("a"),S=!1,T=/^[ \t\n\r\u000c]+/,U=/^[, \t\n\r\u000c]+/,V=/^[^ \t\n\r\u000c]+/,W=/[,]+$/,X=/^\d+$/,Y=/^-?(?:[0-9]+|[0-9]*\.[0-9]+)(?:[eE][+-]?[0-9]+)?$/,Z=function(a,b,c,d){a.addEventListener?a.addEventListener(b,c,d||!1):a.attachEvent&&a.attachEvent("on"+b,c)},$=function(a){var b={};return function(c){return c in b||(b[c]=a(c)),b[c]}},_=function(){var a=/^([\d\.]+)(em|vw|px)$/,b=function(){for(var a=arguments,b=0,c=a[0];++b in a;)c=c.replace(a[b],a[++b]);return c},c=$(function(a){return"return "+b((a||"").toLowerCase(),/\band\b/g,"&&",/,/g,"||",/min-([a-z-\s]+):/g,"e.$1>=",/max-([a-z-\s]+):/g,"e.$1<=",/calc([^)]+)/g,"($1)",/(\d+[\.]*[\d]*)([a-z]+)/g,"($1 * e.$2)",/^(?!(e.[a-z]|[0-9\.&=|><\+\-\*\(\)\/])).*/gi,"")+";"});return function(b,d){var e;if(!(b in N))if(N[b]=!1,d&&(e=b.match(a)))N[b]=e[1]*Q[e[2]];else try{N[b]=new Function("e",c(b))(Q)}catch(f){}return N[b]}}(),aa=function(a,b){return a.w?(a.cWidth=s.calcListLength(b||"100vw"),a.res=a.w/a.cWidth):a.res=a.d,a},ba=function(a){if(t){var c,d,e,f=a||{};if(f.elements&&1===f.elements.nodeType&&("IMG"===f.elements.nodeName.toUpperCase()?f.elements=[f.elements]:(f.context=f.elements,f.elements=null)),c=f.elements||s.qsa(f.context||b,f.reevaluate||f.reselect?s.sel:s.selShort),e=c.length){for(s.setupRun(f),S=!0,d=0;e>d;d++)s.fillImg(c[d],f);s.teardownRun(f)}}};o=a.console&&console.warn?function(a){console.warn(a)}:u,G in v||(G="src"),A["image/jpeg"]=!0,A["image/gif"]=!0,A["image/png"]=!0,A["image/svg+xml"]=b.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#Image","1.1"),s.ns=("pf"+(new Date).getTime()).substr(0,9),s.supSrcset="srcset"in v,s.supSizes="sizes"in v,s.supPicture=!!a.HTMLPictureElement,s.supSrcset&&s.supPicture&&!s.supSizes&&!function(a){v.srcset="data:,a",a.src="data:,a",s.supSrcset=v.complete===a.complete,s.supPicture=s.supSrcset&&s.supPicture}(b.createElement("img")),s.supSrcset&&!s.supSizes?!function(){var a="data:image/gif;base64,R0lGODlhAgABAPAAAP///wAAACH5BAAAAAAALAAAAAACAAEAAAICBAoAOw==",c="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",d=b.createElement("img"),e=function(){var a=d.width;2===a&&(s.supSizes=!0),q=s.supSrcset&&!s.supSizes,t=!0,setTimeout(ba)};d.onload=e,d.onerror=e,d.setAttribute("sizes","9px"),d.srcset=c+" 1w,"+a+" 9w",d.src=c}():t=!0,s.selShort="picture>img,img[srcset]",s.sel=s.selShort,s.cfg=B,s.DPR=P||1,s.u=Q,s.types=A,s.setSize=u,s.makeUrl=$(function(a){return R.href=a,R.href}),s.qsa=function(a,b){return"querySelector"in a?a.querySelectorAll(b):[]},s.matchesMedia=function(){return a.matchMedia&&(matchMedia("(min-width: 0.1em)")||{}).matches?s.matchesMedia=function(a){return!a||matchMedia(a).matches}:s.matchesMedia=s.mMQ,s.matchesMedia.apply(this,arguments)},s.mMQ=function(a){return a?_(a):!0},s.calcLength=function(a){var b=_(a,!0)||!1;return 0>b&&(b=!1),b},s.supportsType=function(a){return a?A[a]:!0},s.parseSize=$(function(a){var b=(a||"").match(I);return{media:b&&b[1],length:b&&b[2]}}),s.parseSet=function(a){return a.cands||(a.cands=m(a.srcset,a)),a.cands},s.getEmValue=function(){var a;if(!p&&(a=b.body)){var c=b.createElement("div"),d=z.style.cssText,e=a.style.cssText;c.style.cssText=K,z.style.cssText=L,a.style.cssText=L,a.appendChild(c),p=c.offsetWidth,a.removeChild(c),p=parseFloat(p,10),z.style.cssText=d,a.style.cssText=e}return p||16},s.calcListLength=function(a){if(!(a in O)||B.uT){var b=s.calcLength(n(a));O[a]=b?b:Q.width}return O[a]},s.setRes=function(a){var b;if(a){b=s.parseSet(a);for(var c=0,d=b.length;d>c;c++)aa(b[c],a.sizes)}return b},s.setRes.res=aa,s.applySetCandidate=function(a,b){if(a.length){var c,d,e,f,h,k,l,m,n,o=b[s.ns],p=s.DPR;if(k=o.curSrc||b[G],l=o.curCan||j(b,k,a[0].set),l&&l.set===a[0].set&&(n=F&&!b.complete&&l.res-.1>p,n||(l.cached=!0,l.res>=p&&(h=l))),!h)for(a.sort(i),f=a.length,h=a[f-1],d=0;f>d;d++)if(c=a[d],c.res>=p){e=d-1,h=a[e]&&(n||k!==s.makeUrl(c.url))&&g(a[e].res,c.res,p,a[e].cached)?a[e]:c;break}h&&(m=s.makeUrl(h.url),o.curSrc=m,o.curCan=h,m!==k&&s.setSrc(b,h),s.setSize(b))}},s.setSrc=function(a,b){var c;a.src=b.url,"image/svg+xml"===b.set.type&&(c=a.style.width,a.style.width=a.offsetWidth+1+"px",a.offsetWidth+1&&(a.style.width=c))},s.getSet=function(a){var b,c,d,e=!1,f=a[s.ns].sets;for(b=0;b<f.length&&!e;b++)if(c=f[b],c.srcset&&s.matchesMedia(c.media)&&(d=s.supportsType(c.type))){"pending"===d&&(c=d),e=c;break}return e},s.parseSets=function(a,b,d){var e,f,g,h,i=b&&"PICTURE"===b.nodeName.toUpperCase(),j=a[s.ns];(j.src===c||d.src)&&(j.src=w.call(a,"src"),j.src?x.call(a,C,j.src):y.call(a,C)),(j.srcset===c||d.srcset||!s.supSrcset||a.srcset)&&(e=w.call(a,"srcset"),j.srcset=e,h=!0),j.sets=[],i&&(j.pic=!0,l(b,j.sets)),j.srcset?(f={srcset:j.srcset,sizes:w.call(a,"sizes")},j.sets.push(f),g=(q||j.src)&&H.test(j.srcset||""),g||!j.src||k(j.src,f)||f.has1x||(f.srcset+=", "+j.src,f.cands.push({url:j.src,d:1,set:f}))):j.src&&j.sets.push({srcset:j.src,sizes:null}),j.curCan=null,j.curSrc=c,j.supported=!(i||f&&!s.supSrcset||g&&!s.supSizes),h&&s.supSrcset&&!j.supported&&(e?(x.call(a,D,e),a.srcset=""):y.call(a,D)),j.supported&&!j.srcset&&(!j.src&&a.src||a.src!==s.makeUrl(j.src))&&(null===j.src?a.removeAttribute("src"):a.src=j.src),j.parsed=!0},s.fillImg=function(a,b){var c,d=b.reselect||b.reevaluate;a[s.ns]||(a[s.ns]={}),c=a[s.ns],(d||c.evaled!==r)&&((!c.parsed||b.reevaluate)&&s.parseSets(a,a.parentNode,b),c.supported?c.evaled=r:h(a))},s.setupRun=function(){(!S||M||P!==a.devicePixelRatio)&&f()},s.supPicture?(ba=u,s.fillImg=u):!function(){var c,d=a.attachEvent?/d$|^c/:/d$|^c|^i/,e=function(){var a=b.readyState||"";f=setTimeout(e,"loading"===a?200:999),b.body&&(s.fillImgs(),c=c||d.test(a),c&&clearTimeout(f))},f=setTimeout(e,b.body?9:99),g=function(a,b){var c,d,e=function(){var f=new Date-d;b>f?c=setTimeout(e,b-f):(c=null,a())};return function(){d=new Date,c||(c=setTimeout(e,b))}},h=z.clientHeight,i=function(){M=Math.max(a.innerWidth||0,z.clientWidth)!==Q.width||z.clientHeight!==h,h=z.clientHeight,M&&s.fillImgs()};Z(a,"resize",g(i,99)),Z(b,"readystatechange",e)}(),s.picturefill=ba,s.fillImgs=ba,s.teardownRun=u,ba._=s,a.picturefillCFG={pf:s,push:function(a){var b=a.shift();"function"==typeof s[b]?s[b].apply(s,a):(B[b]=a[0],S&&s.fillImgs({reselect:!0}))}};for(;J&&J.length;)a.picturefillCFG.push(J.shift());a.picturefill=ba,"object"==typeof module&&"object"==typeof module.exports?module.exports=ba:"function"==typeof define&&define.amd&&define("picturefill",function(){return ba}),s.supPicture||(A["image/webp"]=e("image/webp","data:image/webp;base64,UklGRkoAAABXRUJQVlA4WAoAAAAQAAAAAAAAAAAAQUxQSAwAAAABBxAR/Q9ERP8DAABWUDggGAAAADABAJ0BKgEAAQADADQlpAADcAD++/1QAA=="))}(window,document);;
