"use strict";var _slicedToArray=function(t,e){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return function(t,e){var i=[],n=!0,s=!1,r=void 0;try{for(var o,a=t[Symbol.iterator]();!(n=(o=a.next()).done)&&(i.push(o.value),!e||i.length!==e);n=!0);}catch(t){s=!0,r=t}finally{try{!n&&a.return&&a.return()}finally{if(s)throw r}}return i}(t,e);throw new TypeError("Invalid attempt to destructure non-iterable instance")},_createClass=function(){function n(t,e){for(var i=0;i").css({width:"100%"});t.append(e);t=t.width()-e.width();return e.remove(),t}function isInViewport(t,e){var i=t.getBoundingClientRect(),n=i.top,s=i.bottom,r=i.left,o=i.right,a=$.extend({tolerance:0,viewport:window},e),l=!1,c=a.viewport.jquery?a.viewport:$(a.viewport);c.length||(console.warn("isInViewport: The viewport selector you have provided matches no element on page."),console.warn("isInViewport: Defaulting to viewport as window"),c=$(window));t=c.height(),i=c.width(),e=c[0].toString();return c[0]!==window&&"[object Window]"!==e&&"[object DOMWindow]"!==e&&(n-=(e=c[0].getBoundingClientRect()).top,s-=e.top,r-=e.left,o-=e.left,isInViewport.scrollBarWidth=isInViewport.scrollBarWidth||getScrollbarWidth(c),i-=isInViewport.scrollBarWidth),a.tolerance=~~Math.round(parseFloat(a.tolerance)),a.tolerance<0&&(a.tolerance=t+a.tolerance),o<=0||i<=r?l:l=a.tolerance?n<=a.tolerance&&s>=a.tolerance:0",{class:a.classes.input,readonly:a.utils.isMobile()}),i=u("
",{class:a.classes.items,tabindex:-1}),n=u("
",{class:a.classes.scroll}),s=u("
",{class:a.classes.prefix,html:a.options.arrowButtonMarkup}),r=u("",{class:"label"}),o=a.$element.wrap("
").parent().append(s.prepend(r),i,e),t=u("
",{class:a.classes.hideselect}),a.elements={input:e,items:i,itemsScroll:n,wrapper:s,label:r,outerWrapper:o},a.options.nativeOnMobile&&a.utils.isMobile()&&(a.elements.input=void 0,t.addClass(a.classes.prefix+"-is-native"),a.$element.on("change",function(){a.refresh()})),a.$element.on(a.eventTriggers).wrap(t),a.originalTabindex=a.$element.prop("tabindex"),a.$element.prop("tabindex",-1),a.populate(),a.activate(),a.utils.triggerCallback("Init",a))},activate:function(){var t=this,e=t.elements.items.closest(":visible").children(":hidden").addClass(t.classes.tempshow),i=t.$element.width();e.removeClass(t.classes.tempshow),t.utils.triggerCallback("BeforeActivate",t),t.elements.outerWrapper.prop("class",t.utils.arrayToClassname([t.classes.wrapper,t.$element.prop("class").replace(/\S+/g,t.classes.prefix+"-$&"),t.options.responsive?t.classes.responsive:""])),t.options.inheritOriginalWidth&&0=i.options.multiple.maxLabelEntries+1?(e=e.slice(0,i.options.multiple.maxLabelEntries)).push(u.isFunction(n)?n({text:"..."}):i.utils.format(n,{text:"..."})):e.slice(e.length-1)),i.elements.label.html(e.join(i.options.multiple.separator))):(t=i.lookupItems[i.state.currValue],i.elements.label.html(u.isFunction(n)?n(t):i.utils.format(n,t)))},populate:function(){var n=this,t=n.$element.children(),e=n.$element.find("option"),i=e.filter(":selected"),s=e.index(i),r=0,e=n.state.multiple?[]:0;1";return u.isFunction(i.options.listBuilder)&&i.options.listBuilder&&(t=i.options.listBuilder(t)),u.each(t,function(t,e){void 0!==e.label?(n+=i.utils.format('
  • {3}
  • ',i.utils.arrayToClassname([i.classes.group,e.groupDisabled?"disabled":"",e.element.prop("class")]),i.classes.grouplabel,e.element.prop("label")),u.each(e.items,function(t,e){n+=i.getItemMarkup(e.index,e)}),n+="
"):n+=i.getItemMarkup(e.index,e)}),n+""},getItemMarkup:function(t,e){var i=this,n=i.options.optionsItemBuilder,s={value:e.value,text:e.text,slug:e.slug,index:e.index};return i.utils.format('
  • {3}
  • ',t,i.utils.arrayToClassname([e.className,t===i.items.length-1?"last":"",e.disabled?"disabled":"",e.selected?"selected":""]),u.isFunction(n)?i.utils.format(n(e,this.$element,t),e):i.utils.format(n,s))},unbindEvents:function(){this.elements.wrapper.add(this.$element).add(this.elements.outerWrapper).add(this.elements.input).off(n)},bindEvents:function(){var r=this;r.elements.outerWrapper.on("mouseenter.sl mouseleave"+n,function(t){u(this).toggleClass(r.classes.hover,"mouseenter"===t.type),r.options.openOnHover&&(clearTimeout(r.closeTimer),"mouseleave"===t.type?r.closeTimer=setTimeout(u.proxy(r.close,r),r.options.hoverIntentTimeout):r.open())}),r.elements.wrapper.on("click"+n,function(t){r.state.opened?r.close():r.open(t)}),r.options.nativeOnMobile&&r.utils.isMobile()||(r.$element.on("focus"+n,function(){r.elements.input.focus()}),r.elements.input.prop({tabindex:r.originalTabindex,disabled:!1}).on("keydown"+n,u.proxy(r.handleKeys,r)).on("focusin"+n,function(t){r.elements.outerWrapper.addClass(r.classes.focus),r.elements.input.one("blur",function(){r.elements.input.blur()}),r.options.openOnFocus&&!r.state.opened&&r.open(t)}).on("focusout"+n,function(){r.elements.outerWrapper.removeClass(r.classes.focus)}).on("input propertychange",function(){var t=r.elements.input.val(),s=new RegExp("^"+r.utils.escapeRegExp(t),"i");clearTimeout(r.resetStr),r.resetStr=setTimeout(function(){r.elements.input.val("")},r.options.keySearchTimeout),t.length&&u.each(r.items,function(t,e){if(!e.disabled)if(s.test(e.text)||s.test(e.slug))r.highlight(t);else if(e.alt)for(var i=e.alt.split("|"),n=0;ni&&t.elements.items.height(i),e.removeClass(t.classes.tempshow)},isInViewport:function(){var t,e,i,n=this;!0===n.options.forceRenderAbove?n.elements.outerWrapper.addClass(n.classes.above):!0===n.options.forceRenderBelow?n.elements.outerWrapper.addClass(n.classes.below):(i=s.scrollTop(),e=s.height(),e=(t=n.elements.outerWrapper.offset().top)+n.elements.outerWrapper.outerHeight()+n.itemsHeight<=i+e,i=t-n.itemsHeight>i,i=!(e=!e&&i),n.elements.outerWrapper.toggleClass(n.classes.above,e),n.elements.outerWrapper.toggleClass(n.classes.below,i))},detectItemVisibility:function(t){var e=this,i=e.$li.filter("[data-index]");e.state.multiple&&(t=u.isArray(t)&&0===t.length?0:t,t=u.isArray(t)?Math.min.apply(Math,t):t);var n=i.eq(t).outerHeight(),s=i[t].offsetTop,i=e.elements.itemsScroll.scrollTop(),t=s+2*n;e.elements.itemsScroll.scrollTop(t>i+e.itemsHeight?t-e.itemsHeight:s-n▾',disableOnMobile:!1,nativeOnMobile:!0,openOnFocus:!0,openOnHover:!1,hoverIntentTimeout:500,expandToItemText:!1,responsive:!1,preventWindowScroll:!0,inheritOriginalWidth:!1,allowWrap:!0,forceRenderAbove:!1,forceRenderBelow:!1,stopPropagation:!0,optionsItemBuilder:"{text}",labelBuilder:"{text}",listBuilder:!1,keys:{previous:[37,38],next:[39,40],select:[9,13,27],open:[13,32,37,38,39,40],close:[9,27]},customClass:{prefix:l,camelCase:!1},multiple:{separator:", ",keepMenuOpen:!0,maxLabelEntries:!1}}}),function(t,e){"function"==typeof define&&define.amd?define(e):"object"===("undefined"==typeof exports?"undefined":_typeof(exports))?module.exports=e():t.ScrollMagic=e()}(window||{},function(){function D(){F.log(2,"(COMPATIBILITY NOTICE) -> As of ScrollMagic 2.0.0 you need to use 'new ScrollMagic.Controller()' to create a new controller instance. Use 'new ScrollMagic.Scene()' to instance a scene.")}D.version="2.0.5",window.addEventListener("mousewheel",function(){});var L="data-scrollmagic-pin-spacer";D.Controller=function(t){function e(){var i,t;_&&d&&(i=F.type.Array(d)?d:u.slice(0),d=!1,t=h,t=(h=l.scrollPos())-t,(p=0!=t?0=t&&(Array.prototype.splice.call(arguments,1,0,"("+r+") ->"),F.log.apply(window,arguments))};this._options=c;function S(t){return t.length<=1||(t=t.slice(0)).sort(function(t,e){return t.scrollOffset()>e.scrollOffset()?1:-1}),t}return this.addScene=function(t){if(F.type.Array(t))t.forEach(function(t,e){l.addScene(t)});else if(t instanceof D.Scene){if(t.controller()!==l)t.addTo(l);else if(u.indexOf(t)<0){for(var e in u.push(t),u=S(u),t.on("shift.controller_sort",function(){u=S(u)}),c.globalSceneOptions)t[e]&&t[e].call(t,c.globalSceneOptions[e]);x(3,"adding Scene (now "+u.length+" total)")}}else x(1,"ERROR: invalid argument supplied for '.addScene()'");return l},this.removeScene=function(t){var e;return F.type.Array(t)?t.forEach(function(t,e){l.removeScene(t)}):-1<(e=u.indexOf(t))&&(t.off("shift.controller_sort"),u.splice(e,1),x(3,"removing Scene (now "+u.length+" left)"),t.remove()),l},this.updateScene=function(t,i){return F.type.Array(t)?t.forEach(function(t,e){l.updateScene(t,i)}):i?t.update(!0):!0!==d&&t instanceof D.Scene&&(-1==(d=d||[]).indexOf(t)&&d.push(t),d=S(d),n()),l},this.update=function(t){return T({type:"resize"}),t&&e(),l},this.scrollTo=function(t,e){if(F.type.Number(t))w.call(c.container,t,e);else if(t instanceof D.Scene)t.controller()===l?l.scrollTo(t.scrollOffset(),e):x(2,"scrollTo(): The supplied scene does not belong to this controller. Scroll cancelled.",t);else if(F.type.Function(t))w=t;else{var i=F.get.elements(t)[0];if(i){for(;i.parentNode.hasAttribute(L);)i=i.parentNode;var n=c.vertical?"top":"left",s=F.get.offset(c.container),r=F.get.offset(i);f||(s[n]-=l.scrollPos()),l.scrollTo(r[n]-s[n],e)}else x(2,"scrollTo(): The supplied argument is invalid. Scroll cancelled.",t)}return l},this.scrollPos=function(t){return arguments.length?(F.type.Function(t)?v=t:x(2,"Provided value for method 'scrollPos' is not a function. To change the current scroll position use 'scrollTo()'."),l):v.call(l)},this.info=function(t){var e={size:m,vertical:c.vertical,scrollPos:h,scrollDirection:p,container:c.container,isDocument:f};return arguments.length?void 0!==e[t]?e[t]:void x(1,'ERROR: option "'+t+'" is not available'):e},this.loglevel=function(t){return arguments.length?(c.loglevel!=t&&(c.loglevel=t),l):c.loglevel},this.enabled=function(t){return arguments.length?(_!=t&&(_=!!t,l.updateScene(u,!0)),l):_},this.destroy=function(t){window.clearTimeout(s);for(var e=u.length;e--;)u[e].destroy(t);return c.container.removeEventListener("resize",T),c.container.removeEventListener("scroll",T),F.cAF(i),x(3,"destroyed "+r+" (reset: "+(t?"true":"false")+")"),null},function(){for(var t in c)a.hasOwnProperty(t)||(x(2,'WARNING: Unknown option "'+t+'"'),delete c[t]);if(c.container=F.get.elements(c.container)[0],!c.container)throw x(1,"ERROR creating object "+r+": No valid scroll container supplied"),r+" init failed.";(f=c.container===window||c.container===document.body||!document.body.contains(c.container))&&(c.container=window),m=y(),c.container.addEventListener("resize",T),c.container.addEventListener("scroll",T),c.refreshInterval=parseInt(c.refreshInterval)||a.refreshInterval,g(),x(3,"added new "+r+" controller (v"+D.version+")")}(),l};var k={defaults:{container:window,vertical:!0,globalSceneOptions:{},loglevel:2,refreshInterval:100}};D.Controller.addOption=function(t,e){k.defaults[t]=e},D.Controller.extend=function(t){var e=this;D.Controller=function(){return e.apply(this,arguments),this.$super=F.extend({},this),t.apply(this,arguments)||this},F.extend(D.Controller,e),D.Controller.prototype=e.prototype,D.Controller.prototype.constructor=D.Controller},D.Scene=function(t){var i,a,n="ScrollMagic.Scene",o="BEFORE",l="DURING",c="AFTER",s=I.defaults,u=this,d=F.extend({},s,t),h=o,p=0,r={start:0,end:0},f=0,m=!0,_={};this.on=function(t,i){return F.type.Function(i)?(t=t.trim().split(" ")).forEach(function(t){var e=t.split("."),t=e[0],e=e[1];"*"!=t&&(_[t]||(_[t]=[]),_[t].push({namespace:e||"",callback:i}))}):g(1,"ERROR when calling '.on()': Supplied callback for '"+t+"' is not a valid function!"),u},this.off=function(t,r){return t?(t=t.trim().split(" ")).forEach(function(t,e){var i=t.split("."),t=i[0],s=i[1]||"";("*"===t?Object.keys(_):[t]).forEach(function(t){for(var e=_[t]||[],i=e.length;i--;){var n=e[i];!n||s!==n.namespace&&"*"!==s||r&&r!=n.callback||e.splice(i,1)}e.length||delete _[t]})}):g(1,"ERROR: Invalid event name supplied."),u},this.trigger=function(t,i){var n,s;return t?(t=t.trim().split("."),n=t[0],s=t[1],t=_[n],g(3,"event fired:",n,i?"->":"",i||""),t&&t.forEach(function(t,e){s&&s!==t.namespace||t.callback.call(u,new D.Event(n,t.namespace,u,i))})):g(1,"ERROR: Invalid event name supplied."),u},u.on("change.internal",function(t){"loglevel"!==t.what&&"tweenChanges"!==t.what&&("triggerElement"===t.what?T():"reverse"===t.what&&u.update())}).on("shift.internal",function(t){e(),u.update()});var g=this._log=function(t,e){d.loglevel>=t&&(Array.prototype.splice.call(arguments,1,0,"("+n+") ->"),F.log.apply(window,arguments))};this.addTo=function(t){return t instanceof D.Controller?a!=t&&(a&&a.removeScene(u),a=t,S(),w(!0),T(!0),e(),a.info("container").addEventListener("resize",b),t.addScene(u),u.trigger("add",{controller:a}),g(3,"added "+n+" to controller"),u.update()):g(1,"ERROR: supplied argument of 'addTo()' is not a valid ScrollMagic Controller"),u},this.enabled=function(t){return arguments.length?(m!=t&&(m=!!t,u.update(!0)),u):m},this.remove=function(){var t;return a&&(a.info("container").removeEventListener("resize",b),t=a,a=void 0,t.removeScene(u),u.trigger("remove"),g(3,"removed "+n+" from controller")),u},this.destroy=function(t){return u.trigger("destroy",{reset:t}),u.remove(),u.off("*.*"),g(3,"destroyed "+n+" (reset: "+(t?"true":"false")+")"),null},this.update=function(t){var e;return a&&(t?a.enabled()&&m?(e=a.info("scrollPos"),t=0=r.start?1:0,u.trigger("update",{startPos:r.start,endPos:r.end,scrollPos:e}),u.progress(t)):v&&h===l&&O(!0):a.updateScene(u,!1)),u},this.refresh=function(){return w(),T(),u},this.progress=function(t){if(arguments.length){var e,i=!1,n=h,s=a?a.info("scrollDirection"):"PAUSED",r=d.reverse||p<=t;return 0===d.duration?(i=p!=t,h=0===(p=t<1&&r?0:1)?o:l):t<0&&h!==o&&r?(h=o,i=!(p=0)):0<=t&&t<1&&r?(p=t,h=l,i=!0):1<=t&&h!==c?(p=1,h=c,i=!0):h!==l||r||O(),i&&(e={progress:p,state:h,scrollDirection:s},i=function(t){u.trigger(t,e)},(s=h!=n)&&n!==l&&(i("enter"),i(n===o?"start":"end")),i("progress"),s&&h!==l&&(i(h===o?"start":"end"),i("leave"))),u}return p};var v,y,e=function(){r={start:f+d.offset},a&&d.triggerElement&&(r.start-=a.info("size")*d.triggerHook),r.end=r.start+d.duration},w=function(t){var e;!i||k(e="duration",i.call(u))&&!t&&(u.trigger("change",{what:e,newval:d[e]}),u.trigger("shift",{reason:e}))},T=function(t){var e=0,i=d.triggerElement;if(a&&i){for(var n=a.info(),s=F.get.offset(n.container),r=n.vertical?"top":"left";i.parentNode.hasAttribute(L);)i=i.parentNode;var o=F.get.offset(i);n.isDocument||(s[r]-=a.scrollPos()),e=o[r]-s[r]}r=e!=f;f=e,r&&!t&&u.trigger("shift",{reason:"triggerElementPosition"})},b=function(t){0 Cannot add Scene option '"+t+"', because it already exists."):(I.defaults[t]=e,I.validate[t]=i,n&&I.shifts.push(t))},D.Scene.extend=function(t){var e=this;D.Scene=function(){return e.apply(this,arguments),this.$super=F.extend({},this),t.apply(this,arguments)||this},F.extend(D.Scene,e),D.Scene.prototype=e.prototype,D.Scene.prototype.constructor=D.Scene},D.Event=function(t,e,i,n){for(var s in n=n||{})this[s]=n[s];return this.type=t,this.target=this.currentTarget=i,this.namespace=e||"",this.timeStamp=this.timestamp=Date.now(),this};var F=D._util=function(r){function o(t){return parseFloat(t)||0}function a(t){return t.currentStyle||r.getComputedStyle(t)}function n(t,e,i,n){if((e=e===document?r:e)===r)n=!1;else if(!f.DomElement(e))return 0;t=t.charAt(0).toUpperCase()+t.substr(1).toLowerCase();var s=(i?e["offset"+t]||e["outer"+t]:e["client"+t]||e["inner"+t])||0;return i&&n&&(e=a(e),s+="Height"===t?o(e.marginTop)+o(e.marginBottom):o(e.marginLeft)+o(e.marginRight)),s}function l(t){return t.replace(/^[^a-z]+([a-z])/g,"$1").replace(/-([a-z])/g,function(t){return t[1].toUpperCase()})}var t={};t.extend=function(t){for(t=t||{},u=1;u ERROR calling addIndicators() due to missing Plugin 'debug.addIndicators'. Please make sure to include plugins/debug.addIndicators.js"),this},D.Scene.prototype.removeIndicators=function(){return D._util.log(1,"(ScrollMagic.Scene) -> ERROR calling removeIndicators() due to missing Plugin 'debug.addIndicators'. Please make sure to include plugins/debug.addIndicators.js"),this},D.Scene.prototype.setTween=function(){return D._util.log(1,"(ScrollMagic.Scene) -> ERROR calling setTween() due to missing Plugin 'animation.gsap'. Please make sure to include plugins/animation.gsap.js"),this},D.Scene.prototype.removeTween=function(){return D._util.log(1,"(ScrollMagic.Scene) -> ERROR calling removeTween() due to missing Plugin 'animation.gsap'. Please make sure to include plugins/animation.gsap.js"),this},D.Scene.prototype.setVelocity=function(){return D._util.log(1,"(ScrollMagic.Scene) -> ERROR calling setVelocity() due to missing Plugin 'animation.velocity'. Please make sure to include plugins/animation.velocity.js"),this},D.Scene.prototype.removeVelocity=function(){return D._util.log(1,"(ScrollMagic.Scene) -> ERROR calling removeVelocity() due to missing Plugin 'animation.velocity'. Please make sure to include plugins/animation.velocity.js"),this},D}),setTimeout(function(){var t,e;t=this,e=function(t,a,l){t.Scene.addOption("tweenChanges",!1,function(t){return!!t}),t.Scene.extend(function(){var s,r=this;r.on("progress.plugin_gsap",function(){o()}),r.on("destroy.plugin_gsap",function(t){r.removeTween(t.reset)});var o=function(){var t,e;s&&(t=r.progress(),e=r.state(),s.repeat&&-1===s.repeat()?"DURING"===e&&s.paused()?s.play():"DURING"===e||s.paused()||s.pause():t!=s.progress()&&(0===r.duration()?0c.endVal,c.frameVal=c.startVal,c.initialized=!0):(console.error("[CountUp] startVal or endVal is not a number",c.startVal,c.endVal),!1)):(console.error("[CountUp] target is null or undefined",c.d),!1))},c.printValue=function(t){t=c.options.formattingFn(t);"INPUT"===c.d.tagName?this.d.value=t:"text"===c.d.tagName||"tspan"===c.d.tagName?this.d.textContent=t:this.d.innerHTML=t},c.count=function(t){c.startTime||(c.startTime=t);t=(c.timestamp=t)-c.startTime;c.remaining=c.duration-t,c.options.useEasing?c.countDown?c.frameVal=c.startVal-c.options.easingFn(t,0,c.startVal-c.endVal,c.duration):c.frameVal=c.options.easingFn(t,c.startVal,c.endVal-c.startVal,c.duration):c.countDown?c.frameVal=c.startVal-(c.startVal-c.endVal)*(t/c.duration):c.frameVal=c.startVal+(c.endVal-c.startVal)*(t/c.duration),c.countDown?c.frameVal=c.frameValc.endVal?c.endVal:c.frameVal,c.frameVal=Math.round(c.frameVal*c.dec)/c.dec,c.printValue(c.frameVal),tc.endVal,c.rAF=requestAnimationFrame(c.count)):console.error("[CountUp] update() - new endVal is not a number",t))},c.initialize()&&c.printValue(c.startVal)}}),function(s,a,c){var r=["","webkit","Moz","MS","ms","o"],t=a.createElement("div"),i="function",o=Math.round,u=Math.abs,l=Date.now;function d(t,e,i){return setTimeout(g(t,i),e)}function n(t,e,i){return Array.isArray(t)&&(h(t,i[e],i),1)}function h(t,e,i){if(t)if(t.forEach)t.forEach(e,i);else if(t.length!==c)for(n=0;n\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",t=s.console&&(s.console.warn||s.console.log);return t&&t.call(s.console,n,e),i.apply(this,arguments)}}var p="function"!=typeof Object.assign?function(t){if(t===c||null===t)throw new TypeError("Cannot convert undefined or null to object");for(var e=Object(t),i=1;ie[i]}):n.sort():n}function $(t,e){for(var i,n=e[0].toUpperCase()+e.slice(1),s=0;su(s.y)?s.x:s.y,e.scale=o?function(t,e){return it(e[0],e[1],G)/it(t[0],t[1],G)}(o.pointers,n):1,e.rotation=o?function(t,e){return nt(e[1],e[0],G)+nt(t[1],t[0],G)}(o.pointers,n):0,e.maxPointers=!i.prevInput||e.pointers.length>i.prevInput.maxPointers?e.pointers.length:i.prevInput.maxPointers,function(t,e){var i,n,s,r,o,a=t.lastInterval||e,l=e.timeStamp-a.timeStamp;e.eventType!=N&&(Iu(o.y)?o.x:o.y,r=et(s,r),t.lastInterval=e):(o=a.velocity,i=a.velocityX,n=a.velocityY,r=a.direction),e.velocity=o,e.velocityX=i,e.velocityY=n,e.direction=r}(i,e),t=t.element,b(e.srcEvent.target,t)&&(t=e.srcEvent.target),e.target=t}(t,i),t.emit("hammer.input",i),t.recognize(i),t.session.prevInput=i}function J(t){for(var e=[],i=0;i=u(e)?t<0?j:W:e<0?V:B}function it(t,e,i){var n=e[(i=i||Y)[0]]-t[i[0]],i=e[i[1]]-t[i[1]];return Math.sqrt(n*n+i*i)}function nt(t,e,i){var n=e[(i=i||Y)[0]]-t[i[0]],i=e[i[1]]-t[i[1]];return 180*Math.atan2(i,n)/Math.PI}Z.prototype={handler:function(){},init:function(){this.evEl&&w(this.element,this.evEl,this.domHandler),this.evTarget&&w(this.target,this.evTarget,this.domHandler),this.evWin&&w(O(this.element),this.evWin,this.domHandler)},destroy:function(){this.evEl&&T(this.element,this.evEl,this.domHandler),this.evTarget&&T(this.target,this.evTarget,this.domHandler),this.evWin&&T(O(this.element),this.evWin,this.domHandler)}};var st={mousedown:F,mousemove:2,mouseup:z},rt="mousedown",ot="mousemove mouseup";function at(){this.evEl=rt,this.evWin=ot,this.pressed=!1,Z.apply(this,arguments)}_(at,Z,{handler:function(t){var e=st[t.type];e&F&&0===t.button&&(this.pressed=!0),2&e&&1!==t.which&&(e=z),this.pressed&&(e&z&&(this.pressed=!1),this.callback(this.manager,e,{pointers:[t],changedPointers:[t],pointerType:L,srcEvent:t}))}});var lt={pointerdown:F,pointermove:2,pointerup:z,pointercancel:N,pointerout:N},ct={2:D,3:"pen",4:L,5:"kinect"},ut="pointerdown",dt="pointermove pointerup pointercancel";function ht(){this.evEl=ut,this.evWin=dt,Z.apply(this,arguments),this.store=this.manager.session.pointerEvents=[]}s.MSPointerEvent&&!s.PointerEvent&&(ut="MSPointerDown",dt="MSPointerMove MSPointerUp MSPointerCancel"),_(ht,Z,{handler:function(t){var e=this.store,i=!1,n=t.type.toLowerCase().replace("ms",""),s=lt[n],r=ct[t.pointerType]||t.pointerType,o=r==D,n=k(e,t.pointerId,"pointerId");s&F&&(0===t.button||o)?n<0&&(e.push(t),n=e.length-1):s&(z|N)&&(i=!0),n<0||(e[n]=t,this.callback(this.manager,s,{pointers:e,changedPointers:[t],pointerType:r,srcEvent:t}),i&&e.splice(n,1))}});var pt={touchstart:F,touchmove:2,touchend:z,touchcancel:N};function ft(){this.evTarget="touchstart",this.evWin="touchstart touchmove touchend touchcancel",this.started=!1,Z.apply(this,arguments)}_(ft,Z,{handler:function(t){var e,i=pt[t.type];i===F&&(this.started=!0),this.started&&(e=function(t,e){var i=C(t.touches),t=C(t.changedTouches);e&(z|N)&&(i=P(i.concat(t),"identifier",!0));return[i,t]}.call(this,t,i),i&(z|N)&&e[0].length-e[1].length==0&&(this.started=!1),this.callback(this.manager,i,{pointers:e[0],changedPointers:e[1],pointerType:D,srcEvent:t}))}});var mt={touchstart:F,touchmove:2,touchend:z,touchcancel:N},_t="touchstart touchmove touchend touchcancel";function gt(){this.evTarget=_t,this.targetIds={},Z.apply(this,arguments)}_(gt,Z,{handler:function(t){var e=mt[t.type],i=function(t,e){var i=C(t.touches),n=this.targetIds;if(e&(2|F)&&1===i.length)return n[i[0].identifier]=!0,[i,i];var s,r,o=C(t.changedTouches),a=[],l=this.target;if(r=i.filter(function(t){return b(t.target,l)}),e===F)for(s=0;se.threshold&&s&e.direction},attrTest:function(t){return Lt.prototype.attrTest.call(this,t)&&(2&this.state||!(2&this.state)&&this.directionTest(t))},emit:function(t){this.pX=t.deltaX,this.pY=t.deltaY;var e=Rt(t.direction);e&&(t.additionalEvent=this.options.event+e),this._super.emit.call(this,t)}}),_(Ft,Lt,{defaults:{event:"pinch",threshold:0,pointers:2},getTouchAction:function(){return[kt]},attrTest:function(t){return this._super.attrTest.call(this,t)&&(Math.abs(t.scale-1)>this.options.threshold||2&this.state)},emit:function(t){var e;1!==t.scale&&(e=t.scale<1?"in":"out",t.additionalEvent=this.options.event+e),this._super.emit.call(this,t)}}),_(zt,Et,{defaults:{event:"press",pointers:1,time:251,threshold:9},getTouchAction:function(){return["auto"]},process:function(t){var e=this.options,i=t.pointers.length===e.pointers,n=t.distancee.time;if(this._input=t,!n||!i||t.eventType&(z|N)&&!s)this.reset();else if(t.eventType&F)this.reset(),this._timer=d(function(){this.state=8,this.tryEmit()},e.time,this);else if(t.eventType&z)return 8;return 32},reset:function(){clearTimeout(this._timer)},emit:function(t){8===this.state&&(t&&t.eventType&z?this.manager.emit(this.options.event+"up",t):(this._input.timeStamp=l(),this.manager.emit(this.options.event,this._input)))}}),_(Nt,Lt,{defaults:{event:"rotate",threshold:0,pointers:2},getTouchAction:function(){return[kt]},attrTest:function(t){return this._super.attrTest.call(this,t)&&(Math.abs(t.rotation)>this.options.threshold||2&this.state)}}),_(Ht,Lt,{defaults:{event:"swipe",threshold:10,velocity:.3,direction:X|q,pointers:1},getTouchAction:function(){return It.prototype.getTouchAction.call(this)},attrTest:function(t){var e,i=this.options.direction;return i&(X|q)?e=t.overallVelocity:i&X?e=t.overallVelocityX:i&q&&(e=t.overallVelocityY),this._super.attrTest.call(this,t)&&i&t.offsetDirection&&t.distance>this.options.threshold&&t.maxPointers==this.options.pointers&&u(e)>this.options.velocity&&t.eventType&z},emit:function(t){var e=Rt(t.offsetDirection);e&&this.manager.emit(this.options.event+e,t),this.manager.emit(this.options.event,t)}}),_(jt,Et,{defaults:{event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},getTouchAction:function(){return[St]},process:function(t){var e=this.options,i=t.pointers.length===e.pointers,n=t.distance"),n.contentWindow.document.body.appendChild(e),n.contentWindow.document.close();var s,r,t=n.contentWindow.document.querySelectorAll(t.nodeName.toLowerCase())[0],o=this.getComputedStyle(t,n.contentWindow);for(r in o)if(null!==(s=!0===o.getPropertyValue?o.getPropertyValue(r):o[r]))switch(r){default:i[r]=s;break;case"width":case"height":case"minWidth":case"minHeight":case"maxWidth":case"maxHeight":}return document.body.removeChild(n),i},getMatchedStyle:function(t,e){var i=null,n=null;t.style.getPropertyValue?n=t.style.getPropertyValue(e):t.currentStyle&&(n=t.currentStyle[e]);var s,r,o=window.getMatchedCSSRules(t),a=o.length;if(a)for(;0Previous',nextArrow:'',autoplay:!1,autoplaySpeed:3e3,centerMode:!1,centerPadding:"50px",cssEase:"ease",customPaging:function(t,e){return c('\n ";i.innerHTML+=t}),$(i).find("li").on("click",function(t){t=t.target.getAttribute("data-index");e.goto(t)}),i}},{key:"addSwipeSupport",value:function(){var e=this;this.hammer=new Hammer(this.ele),this.hammer.get("swipe").set({direction:Hammer.DIRECTION_ALL}),this.hammer.on("swipeup swipedown",function(t){"swipeup"===t.type&&e.next(),"swipedown"===t.type&&e.previous()})}},{key:"removeMouseWheelPageSupport",value:function(){this.mouseWheelFunc&&document.removeEventListener("wheel",this.mouseWheelFunc.bind(this))}},{key:"addMouseWheelPageSupport",value:function(){var o=this,a=Math.abs,l=0;this.mouseWheelFunc=function(t){var e=t.deltaY,i=a(e),n=o.$ele.is(".fixed"),s=(o.numSlidesIndex,o.slideId,i div").height():0,e=$(".sticky-nav").height()||0;return t+parseInt(e)}},{key:"initEvents",value:function(){function i(){var t=s.offset().top-n.getHeaderHeight();!s.is(".fixed")&&n.isInited&&0===n.slideId&&t!==n.mainScene.offset()&&(n.mainScene.offset(t),a.clear()),n.mainOffset=t}var n=this,s=this.$ele,t=$(window),e=($("html"),$("body")),r=(this.ele,s.find(".carousel__vertical--slide")),o=$(".line"),a=void 0;e.on("ON_HEADER_CHANGE JUSTUNO_LOAD JUSTUNO_UNLOAD",function(t){var e=n.getHeaderHeight();r.css("minHeight","calc(100vh - "+e+"px)"),s.css({minHeight:"calc(100vh - "+e+"px)"}),o.length&&o.css({height:"calc(100vh - "+e+"px)",top:e+"px"}),i()}),t.on("resize",this.resize.bind(this)),a=rInterval(i.bind(this),200)}},{key:"init",value:function(){window.innerWidth<769?this.mobileInteraction():(ScrollToTop(),this.page=!1,this.mainOffset=0,this.initSlides(),this.initEvents(),this.page&&this.addMouseWheelPageSupport(),this.ele.classList.add("inited"))}},{key:"resize",value:function(){window.innerWidth',nextArrow:'',responsive:[{breakpoint:767,settings:{arrows:!0}}]}),this.$top.find(".exclusive__feature").each(function(t,e){}),$(this.ele).on("beforeChange",function(t,e,i,n){s.$top.find(".exclusive__feature--current").removeClass("exclusive__feature--current"),s.$top.find(".exclusive__feature:eq("+n+")").addClass("exclusive__feature--current")})}}]),e}();TRX_GLOBAL.ExclusiveCarousel=ExclusiveCarousel;var FeatureCarousel=function(){function e(t){_classCallCheck(this,e);t=_possibleConstructorReturn(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return t.init(),t}return _inherits(e,TRX_GLOBAL.Carousel),_createClass(e,[{key:"pauseAllWistiaVideo",value:function(){window.Wistia&&$(".wistia_embed").each(function(t,e){try{var i=e.getAttribute("id");Wistia.api(i).pause()}catch(t){}})}},{key:"handleWistiaVideo",value:function(){var t=this.$ele.find(".slick-current").is(".wistia"),e=this.$ele.find(".wistia").length;t?this.$ele.addClass("wistia"):this.$ele.removeClass("wistia"),e&&this.$ele.addClass("has-wistia")}},{key:"initEvents",value:function(){var i,t,n,e,s=this;window.innerWidth<769||(i=this.$ele,$(window),$("html"),t=$("body"),this.ele,n=null,e=function(){if(window.innerWidth',nextArrow:''}),this.$ele.on("beforeChange",function(t,e,i,n){s.pauseAllWistiaVideo()}),this.$ele.on("afterChange",function(t,e,i,n){s.handleWistiaVideo()}),this.handleWistiaVideo(),this.initEvents()}}]),e}();TRX_GLOBAL.FeatureCarousel=FeatureCarousel;var HeroCarousel=function(){function e(t){_classCallCheck(this,e);t=_possibleConstructorReturn(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return t.init(),t}return _inherits(e,TRX_GLOBAL.Carousel),_createClass(e,[{key:"init",value:function(){this.$ele.slick({speed:900,dots:!1,arrows:!1,autoplay:!0,centerMode:!0,centerPadding:"0px",accessibility:!1})}}]),e}();TRX_GLOBAL.HeroCarousel=HeroCarousel;var isElementInViewport=function(t){t=t.getBoundingClientRect();return 0',nextArrow:'',responsive:[{breakpoint:1400,settings:{variableWidth:!1}}]};this.$ele.attr("data-slide")&&(t.slide=this.$ele.attr("data-slide")),this.$ele.slick(t),this.$ele.on("beforeChange",function(t,e,i){n.$ele.find(".slide").addClass("transition")}),this.$ele.on("animationend",function(){n.$ele.find(".slide").removeClass("transition next")}),this.$ele.on("afterChange",function(){n.$ele.find(".slide").removeClass("transition next")})}}]),i}();TRX_GLOBAL.ImageCarousel=ImageCarousel;var TimelineCarousel=function(){function e(t){_classCallCheck(this,e);t=_possibleConstructorReturn(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return t.offsetY=0,t.init(),t}return _inherits(e,TRX_GLOBAL.Carousel),_createClass(e,[{key:"init",value:function(){var t=this;this.isTouch||(this.initEvents(),setTimeout(function(){ScrollToTop(),t.initSlides()},1e3))}},{key:"getHeaderHeight",value:function(){var t=$("#justuno_form").length?$("#justuno_form > div").height():0,e=$(".sticky-nav").height()||0;return t+parseInt(e)}},{key:"initEvents",value:function(){var t,e,i,n,s,r=this;window.innerWidth\n \n ";i.innerHTML+=t}),$(i).find("li").on("click",function(t){t=t.target.getAttribute("data-index");e.gotoSlide(t)}),i}},{key:"dispatchSlide",value:function(t){var e=this.getSlides().eq(t);$("html").trigger({type:"ON_ITEM_SELECTED",id:e.attr("id"),index:t})}},{key:"showSlide",value:function(t,e){var i="slick-active",n=this.getSlides().eq(t),s=this.indicators.find("li");return this.getSlides().removeClass(i),n.addClass(i),s.removeClass(i),s.eq(t).addClass(i),e&&this.dispatchSlide(t),n}},{key:"gotoSlide",value:function(t,e){var i=this,n=this.showSlide(t);$("html, body").animate({scrollTop:n.offset().top},300+200*t,function(){e||i.dispatchSlide(t)})}},{key:"handleScrolling",value:function(t,e){for(var i=0;i=s&&this.showSlide(i,!0)}}},{key:"initSlides",value:function(){var t,i,e,n=this;window.innerWidthn.$ele.offset().top-1,t=t.scrollTop()=s-1?r(0):r(i.index+1)},p=function(){i.index-1<0?r(s-1):r(i.index-1)};return e.forEach(function(e,i){["touchstart","click"].forEach(function(t){e.classList.remove("down"),e.addEventListener(t,function(t){d(i)})}),e.addEventListener("mousedown",function(){e.classList.add("down")})}),n.on("scroll",function(t){var e=Math.ceil(n.scrollLeft()/n.width());i.index!==e&&d(e)}),n.on("click",function(t){var e=n.width(),e=t.screenX'}),$("#country_select").selectric({labelBuilder:function(t,e){return''+t.text+""},optionsItemBuilder:function(t,e,i){return' '+t.text+""}}),$(".form__number").each(function(t,e){var i;e.classList.contains("form__number--no-bind")||(i=$('[type="number"]',e).get(0),$(".form__number-up",e).click(function(){return i.stepUp()}),$(".form__number-down",e).click(function(){return i.stepDown()}),e.setAttribute("tabindex",-1))});var desktopWidth=$(".commercial-header").length?1155:1025;function isMobile(){return document.documentElement.clientWidth=desktopWidth}var focusableElements='[href]:not([disabled]), button:not([disabled]), input[type=text]:not([disabled]), select[type=text]:not([disabled]), textarea[type=text]:not([disabled]), [tabindex]:not([disabled]):not([tabindex="-1"])',$html=$("html"),$body=$("body"),headerElement=document.querySelector(".header"),$headerGroups=$(".header__group-title").parents(".header__group"),$headerMenu=$(".header__menu-bottom");$headerGroups.each(function(t,e){var i=$(e);i.find(".header__group-subnav .header__shop-link").on("click tap",function(t){isMobile()&&(t.preventDefault(),i.addClass("header__group--open"),$headerMenu.addClass("header__menu--group-open"),trapFocus(i.find(".subnav__content")))}),i.find(".subnav__back-button").on("click",function(t){isMobile()&&(t.preventDefault(),$(".header__group--open").removeClass("header__group--open"),$headerMenu.removeClass("header__menu--group-open"),trapFocus($headerMenu))}),i.on("mouseenter",function(){isDesktop()&&($(".header__group--open").removeClass("header__group--open"),i.addClass("header__group--open"))}).on("mouseleave",function(){isDesktop()&&$(".header__group--open").removeClass("header__group--open")}),i.on("click tap",function(t){isDesktop()&&("click"!==t.type&&t.preventDefault(),$(".header__group--open").removeClass("header__group--open"),i.addClass("header__group--open"))}),i.on("focusin",function(){isDesktop()&&($(".header__group--open").removeClass("header__group--open"),i.addClass("header__group--open"))}).on("focusout",function(t){isDesktop()&&($(t.relatedTarget).parents(".header__group").hasClass("header__group--open")||$(".header__group--open").removeClass("header__group--open"))})});var $hamburger=$(".header__hamburger"),$mainMenu=$(".header__menu");$hamburger.on("click",function(){$hamburger.toggleClass("is-active"),$html.toggleClass("menu--active"),$hamburger.hasClass("is-active")?($mainMenu.addClass("header__menu--open"),trapFocus($headerMenu)):($mainMenu.removeClass("header__menu--open"),$headerMenu.removeClass("header__menu--group-open"),untrapFocus())});var $search=$(".js-search"),$searchModal=$(".search--mobile");$search.on("click",function(t){$html.removeClass("menu-active"),untrapFocus(),$hamburger.hasClass("is-active")&&$mainMenu.removeClass("header__menu--open"),$body.addClass("search--active"),$(".header__hamburger").addClass("is-active"),trapFocus($searchModal),t.stopPropagation()}),$search.find("button").on("click",function(t){isMobile()&&t.preventDefault()}),$(".search--mobile").on("click",function(t){$body.addClass("search--active"),t.stopPropagation()}),$body.on("click",function(){$body.hasClass("search--active")&&$body.removeClass("search--active")}),$(".header__search__close-button").on("click",function(t){t.stopPropagation(),$("body").hasClass("search--active")&&$("body").removeClass("search--active")});var firstFocusableElement="",focusableContent="",lastFocusableElement="",closeElement=document.querySelector(".header__hamburger"),trapFocusHandle=null,maintainHiddenHandle=null;function trapFocus(t){untrapFocus(),t instanceof jQuery&&(t=t[0]),focusableContent=(focusableContent=Array.from(t.querySelectorAll(focusableElements))).filter(function(t){return"none"!==getComputedStyle(t).display}),firstFocusableElement=focusableContent[0],lastFocusableElement=focusableContent[focusableContent.length-1]}function untrapFocus(){lastFocusableElement=focusableContent=firstFocusableElement=""}function removeUnfocusableElements(t){return Array.prototype.filter.call(t,function(t){return"0"<=t.tabIndex&&null!==t.offsetParent})}function skipToContent(){var t=removeUnfocusableElements(document.querySelectorAll(focusableElements)),e=removeUnfocusableElements(headerElement.querySelectorAll(focusableElements)),e=e[e.length-1],e=t.indexOf(e);(e===t.length?t[0]:t[e+1]).focus()}document.addEventListener("keydown",function(t){"Tab"!==t.key&&9!==t.code||""===focusableContent||(t.shiftKey?document.activeElement===firstFocusableElement?(closeElement.focus(),t.preventDefault()):document.activeElement===closeElement&&(lastFocusableElement.focus(),t.preventDefault()):document.activeElement===lastFocusableElement?(closeElement.focus(),t.preventDefault()):document.activeElement===closeElement&&(firstFocusableElement.focus(),t.preventDefault()))}),$(".skip-to-content").on("click",function(t){t.preventDefault(),skipToContent()}),$("#country_select").on("change",function(){window.location.href=$("#country_select option:selected").val()}),$(".hero__scroll-hint").on("click",function(t){t=$(t.currentTarget).parent(".hero");$("html, body").animate({scrollTop:t.offset().top+t.height()},1e3)});var buildData=function(t){var e=t.querySelectorAll(".field"),r={questions:[],sku:{dom:null,value:""},email:{dom:null,value:""},form:{dom:t}};return forEach(e,function(t,e){var n,i,s;-1!==e.className.indexOf("hs_email")?(r.email.dom=e.querySelector('[name="email"]'),r.email.value=r.email.dom.value):-1!==e.className.indexOf("hs_recommended_product_sku")?(r.sku.dom=e.querySelector('[name="recommended_product_sku"]'),r.sku.value=r.sku.dom.value):(n=[],i=e.querySelector("label"),s=e.querySelector("input"),forEach(e.querySelectorAll(".hs-form-radio"),function(t,e){var i=e.querySelector("input"),e=e.querySelector("span"),e=e.innerText||i.value;n.push({index:t++,dom:i,text:e,value:i.value,id:i.getAttribute("id"),selected:!1})}),r.questions.push({q:s.getAttribute("name"),id:i.getAttribute("for"),dom:e,text:i.innerText,options:n}))}),!r.sku.value&&localStorage.getItem("sku")&&(r.sku.value=localStorage.getItem("sku")),r},IntentWidget=function(){function s(t,e,i,n){_classCallCheck(this,s),this.ele=t,this.selector=e,this.data=buildData(i),this.quizname=n}return _createClass(s,[{key:"init",value:function(){TRX_GLOBAL.IntentAppInit(this.ele,this.selector,this.data,this.quizname)}}]),s}();TRX_GLOBAL.IntentWidget=IntentWidget;var $jumpTop=$(".jump-top");function renderJumpTop(){var t=$(window),e=t.height()/2,i="jump-top--visible";t.scrollTop()>e&&!$jumpTop.hasClass(i)?$jumpTop.addClass(i):t.scrollTop()$summitMenuContainer.offset().top?($summitMenu.addClass("summit__menu--stuck"),$summitMenuContainer.height($summitMenu.outerHeight())):$summitMenu.hasClass("summit__menu--stuck")&&$summitWindow.scrollTop()<$summitMenuContainer.offset().top&&($summitMenu.removeClass("summit__menu--stuck"),$summitMenuContainer.height("auto")),window.requestAnimationFrame(t)},$summitHamburger=$(".summit__menu-toggle"),$summitMenu=$(".summit__menu"),$summitHamburger.on("click",function(){$summitHamburger.toggleClass("is-active"),$summitHamburger.hasClass("is-active")?$summitMenu.addClass("summit__menu--open"):$summitMenu.removeClass("summit__menu--open")}),$summitWindow=$(window),$summitMenuContainer=$summitMenu.parent(),window.requestAnimationFrame(renderStickyHeader),$(".summit__hero").length&&768<$(window).width()&&(backgroundVideo=$(".summit__hero-background-video"),videoId=backgroundVideo.data("video-id"),backgroundVideo.attr("id","wistia_"+videoId),Wistia.embed(videoId,{smallPlayButton:!1,playButton:!1,playerColor:"00c7f8",version:"v1",autoPlay:!0,controlsVisibleOnLoad:!1,playBar:!1,endVideoBehavior:"loop",volume:"0",videoFoam:!1,settingsControl:!1,plugin:{cropFill:{src:"//fast.wistia.com/labs/crop-fill/plugin.js"}}})),googleApiKey&&(summitMap=$(".summit__map"),$.getScript("https://maps.googleapis.com/maps/api/js?key="+googleApiKey,function(){var t={lat:summitMap.data("lat"),lng:summitMap.data("lng")},e=new google.maps.Map(summitMap[0],{zoom:summitMap.data("zoom"),center:t,disableDefaultUI:!0});new google.maps.Marker({position:t,map:e,title:summitMap.data("title")})}))),$(".text-carousel__carousel").on("init",function(t,e){$(e.$dots[0]).attr("data-dir","forward")}).on("beforeChange",function(t,e,i,n){$(e.$dots[0]).attr("data-dir",i