!function(a,c,u){"use strict";var e={getInstance:function(e,t){return a.offside.factory||(a.offside.factory=n(t)),a.offside.factory.getOffsideInstance(e,t)}};function n(e){var t,p=function(e){0<k.length&&(isNaN(e)?k.forEach(function(e){x[e].close()}):x[e].close())},b=function(){h(C,i)},h=function(e,t){e.classList?e.classList.add(t):e.className=(e.className+" "+t).trim()},S=function(e,t){e.classList?e.classList.remove(t):e.className=e.className.replace(new RegExp("(^|\\b)"+t.split(" ").join("|")+"(\\b|$)","gi")," ")},L=function(e,t,n){e.addEventListener(t,n)},A=function(e,t,n){e.removeEventListener(t,n)},E=function(e){return e instanceof HTMLElement?[e]:Array.isArray(e)?e:"string"==typeof e&&Array.apply(null,c.querySelectorAll(e))},O=function(e,t){e=e.indexOf(t);return-1<e&&e},n={slidingElementsSelector:".offside-sliding-element",disableCss3dTransforms:!1,debug:!1};for(t in e)n.hasOwnProperty(t)&&(n[t]=e[t]);var q="offside-js",o=q+"--init",i=q+"--interact",x=[],w=!0,s=!n.disableCss3dTransforms&&function(){if(!a.getComputedStyle)return!1;var e,t,n=c.createElement("p"),o={webkitTransform:"-webkit-transform",OTransform:"-o-transform",msTransform:"-ms-transform",MozTransform:"-moz-transform",transform:"transform"};for(t in c.body.insertBefore(n,null),o)n.style[t]!==u&&(n.style[t]="translate3d(1px,1px,1px)",e=a.getComputedStyle(n).getPropertyValue(o[t]));return c.body.removeChild(n),e!==u&&0<e.length&&"none"!==e}(),k=[],C=c.body,r=E(n.slidingElementsSelector),T=n.debug;function l(e,t,n){var o,i={buttonsSelector:"",slidingSide:"left",init:function(){},beforeOpen:function(){},afterOpen:function(){},beforeClose:function(){},afterClose:function(){},beforeDestroy:function(){},afterDestroy:function(){}};for(o in t)i.hasOwnProperty(o)&&(i[o]=t[o]);var s=e,r=E(i.buttonsSelector),e=i.slidingSide,l="offside",a=l+"--"+e,c="is-open",u=q+"--is-open",d=q+"--is-"+e,f=n||0,m=function(){(!1===O(k,f)?g:y)()},g=function(){i.beforeOpen(),w&&(w=!1,b()),p(),h(C,u),h(C,d),h(s,c),k.push(f),i.afterOpen()},y=function(){var e=O(k,f);!1!==e&&(i.beforeClose(),S(C,u),S(C,d),S(s,c),k.splice(e,1),i.afterClose())},v=function(e){e.preventDefault(),m()},e=function(){s||console.error('Offside alert: "offside" selector could not match any element'),r.length||console.error('Offside alert: "buttonsSelector" selector could not match any element')};this.toggle=function(){m()},this.open=function(){g()},this.close=function(){y()},this.closeAll=function(){p()},this.destroy=function(){i.beforeDestroy(),y(),r.forEach(function(e){A(e,"click",v)}),S(s,l),S(s,a),delete x[f],i.afterDestroy()},T&&e(),h(s,l),h(s,a),r.forEach(function(e){L(e,"click",v)}),i.init()}return r.forEach(function(e){h(e,"offside-sliding-element")}),s||h(c.documentElement,"no-csstransforms3d"),h(C,o),{closeOpenOffside:function(){p()},getOffsideInstance:function(e,t){var n,o=x.length||0,e=(t=t,n=o,!1!==(e=E((e=e)!==u?e:".offside"))?new l(e[0],t,n):null);if(null!==e)return x[o]=e}}}"undefined"!=typeof module&&module.exports?module.exports=e.getInstance:a.offside=e.getInstance}(window,document);for(var generateOffside=offside(".slideout-navigation",{slidingElementsSelector:"#slideout-container",buttonsSelector:".slideout-mobile .main-navigation .menu-toggle, .slideout-both .main-navigation .menu-toggle, .slideout-both .slideout-toggle, .slideout-desktop .slideout-toggle",slidingSide:offSide.side,beforeOpen:function(){document.querySelector(".slideout-navigation").classList.add("slideout-transition")},afterOpen:function(){if(setTimeout(function(){document.querySelector(".slideout-navigation").classList.remove("slideout-transition")},10),document.documentElement.classList.add("slide-opened"),document.body.classList.add("slide-opened"),document.body.classList.contains("dropdown-hover"))for(var e=document.querySelector(".slideout-navigation").querySelectorAll("li.menu-item-has-children"),t=0;t<e.length;t++){var n=e[t].querySelector("span.dropdown-menu-toggle");n&&(n.setAttribute("tabindex",0),n.setAttribute("role","button"),n.setAttribute("aria-expanded",!0))}var o=document.querySelector(".slideout-navigation").querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])');o&&setTimeout(function(){o[0].focus()},200)},beforeClose:function(){document.querySelector(".slideout-navigation").classList.add("slideout-transition")},afterClose:function(){setTimeout(function(){document.querySelector(".slideout-navigation").classList.remove("slideout-transition")},500);for(var e=document.body,t=document.querySelectorAll(".main-navigation"),n=0;n<t.length;n++)t[n].classList.contains("toggled")&&t[n].classList.remove("toggled");if(document.documentElement.classList.remove("slide-opened"),e.classList.remove("slide-opened"),"true"===document.querySelector(".main-navigation .menu-toggle").getAttribute("aria-expanded")&&document.querySelector(".main-navigation .menu-toggle").setAttribute("aria-expanded",!1),e.classList.contains("dropdown-hover"))for(var o=document.querySelector(".main-navigation:not(.slideout-navigation):not(.mobile-menu-control-wrapper)").querySelectorAll("li.menu-item-has-children"),n=0;n<o.length;n++){var i=o[n].querySelector("span.dropdown-menu-toggle");i&&(i.removeAttribute("tabindex"),i.setAttribute("role","presentation"),i.removeAttribute("aria-expanded"))}}}),closeElements=document.querySelectorAll(".slideout-overlay, .slideout-exit, .slider-exit a"),i=0;i<closeElements.length;i++)closeElements[i].addEventListener("click",function(e){e.preventDefault(),generateOffside.close()});for(var slideoutLinks=document.querySelectorAll(".slideout-navigation ul a"),closeOffsideOnAction=function(){var e=this.getAttribute("href");"#"===e||""===e||navigator.userAgent.match(/iemobile/i)||setTimeout(function(){generateOffside.close()},200)},i=0;i<slideoutLinks.length;i++)slideoutLinks[i].addEventListener("click",closeOffsideOnAction,!1);document.addEventListener("keyup",function(e){document.body.classList.contains("slide-opened")&&27==(e=e||window.event).keyCode&&(generateOffside.close(),e=document.body,window.document.documentElement.clientWidth<=768?(e.classList.contains("slideout-mobile")||e.classList.contains("slideout-both"))&&document.querySelectorAll(".main-navigation:not(.slideout-navigation)").forEach(function(e){e&&"none"!==e.style.display&&e.querySelector(".menu-toggle").focus()}):(e.classList.contains("slideout-desktop")||e.classList.contains("slideout-both"))&&document.querySelectorAll(".main-navigation:not(.slideout-navigation)").forEach(function(e){e&&"none"!==e.style.display&&e.querySelector(".slideout-toggle a").focus()}))});for(var toggles=document.querySelectorAll(".slideout-toggle a"),i=0;i<toggles.length;i++)toggles[i].addEventListener("keypress",function(e){" "===e.key&&(e.preventDefault(),generateOffside.open())});
window.Element&&!Element.prototype.closest&&(Element.prototype.closest=function(e){var t,n=(this.document||this.ownerDocument).querySelectorAll(e),o=this;do{for(t=n.length;0<=--t&&n.item(t)!==o;);}while(t<0&&(o=o.parentElement));return o}),function(){function e(e,t){t=t||{bubbles:!1,cancelable:!1,detail:void 0};var n=document.createEvent("CustomEvent");return n.initCustomEvent(e,t.bubbles,t.cancelable,t.detail),n}"function"!=typeof window.CustomEvent&&(e.prototype=window.Event.prototype,window.CustomEvent=e)}(),function(){for(var r=0,e=["ms","moz","webkit","o"],t=0;t<e.length&&!window.requestAnimationFrame;++t)window.requestAnimationFrame=window[e[t]+"RequestAnimationFrame"],window.cancelAnimationFrame=window[e[t]+"CancelAnimationFrame"]||window[e[t]+"CancelRequestAnimationFrame"];window.requestAnimationFrame||(window.requestAnimationFrame=function(e,t){var n=(new Date).getTime(),o=Math.max(0,16-(n-r)),i=window.setTimeout(function(){e(n+o)},o);return r=n+o,i}),window.cancelAnimationFrame||(window.cancelAnimationFrame=function(e){clearTimeout(e)})}(),function(e,t){"function"==typeof define&&define.amd?define([],function(){return t(e)}):"object"==typeof exports?module.exports=t(e):e.SmoothScroll=t(e)}("undefined"!=typeof global?global:"undefined"!=typeof window?window:this,function(b){"use strict";function E(){for(var e={},t=0;t<arguments.length;t++){n=void 0;var n,o=arguments[t];for(n in o)o.hasOwnProperty(n)&&(e[n]=o[n])}return e}function c(t){var n;try{n=decodeURIComponent(t)}catch(e){n=t}return n}function s(e){"#"===e.charAt(0)&&(e=e.substr(1));for(var t,n,o=String(e),i=o.length,r=-1,a="",c=o.charCodeAt(0);++r<i;){if(0===(t=o.charCodeAt(r)))throw new InvalidCharacterError("Invalid character: the input contains U+0000.");1<=t&&t<=31||127==t||0===r&&48<=t&&t<=57||1===r&&48<=t&&t<=57&&45===c?a+="\\"+t.toString(16)+" ":a+=128<=t||45===t||95===t||48<=t&&t<=57||65<=t&&t<=90||97<=t&&t<=122?o.charAt(r):"\\"+o.charAt(r)}try{n=decodeURIComponent("#"+a)}catch(e){n="#"+a}return n}function A(e){return e?t(e)+e.offsetTop:0}function C(e,t,n,o){t.emitEvents&&"function"==typeof b.CustomEvent&&(t=new CustomEvent(e,{bubbles:!0,detail:{anchor:n,toggle:o}}),document.dispatchEvent(t))}var q={ignore:"[data-scroll-ignore]",header:null,topOnEmptyHash:!0,speed:500,clip:!0,offset:0,easing:"easeInOutCubic",customEasing:null,updateURL:!0,popstate:!0,emitEvents:!0},t=function(e){return parseInt(b.getComputedStyle(e).height,10)},O=function(){return Math.max(document.body.scrollHeight,document.documentElement.scrollHeight,document.body.offsetHeight,document.documentElement.offsetHeight,document.body.clientHeight,document.documentElement.clientHeight)};return function(o,e){function t(e){var t,n;"matchMedia"in b&&b.matchMedia("(prefers-reduced-motion)").matches||0!==e.button||e.metaKey||e.ctrlKey||"closest"in e.target&&(r=e.target.closest(o))&&"a"===r.tagName.toLowerCase()&&!e.target.closest(g.ignore)&&r.hostname===b.location.hostname&&r.pathname===b.location.pathname&&/#/.test(r.href)&&(t=s(c(r.hash)),n=(n=g.topOnEmptyHash&&"#"===t?document.documentElement:document.querySelector(t))||"#top"!==t?n:document.documentElement)&&(e.preventDefault(),S.animateScroll(n,r))}function n(e){var t;null!==history.state&&history.state.smoothScroll&&history.state.smoothScroll===JSON.stringify(g)&&history.state.anchor&&(t=document.querySelector(s(c(history.state.anchor))))&&S.animateScroll(t,null,{updateURL:!1})}function i(e){a=a||setTimeout(function(){a=null,v=A(y)},66)}var g,r,y,v,a,w,S={cancelScroll:function(e){cancelAnimationFrame(w),w=null,e||C("scrollCancel",g)}};S.animateScroll=function(o,i,e){var r,a,c,s,u,l,m,d,f,t,h=E(g||q,e||{}),p="[object Number]"===Object.prototype.toString.call(o),e=p||!o.tagName?null:o;(p||e)&&(r=b.pageYOffset,h.header&&!y&&(y=document.querySelector(h.header)),v=v||A(y),a=p?o:function(e,t,n,o){var i=0;if(e.offsetParent)for(;i+=e.offsetTop,e=e.offsetParent;);return i=Math.max(i-t-n,0),i=o?Math.min(i,O()-b.innerHeight):i}(e,v,parseInt("function"==typeof h.offset?h.offset(o,i):h.offset,10),h.clip),c=a-r,s=O(),d=function(e,t){var n=b.pageYOffset;if(e==t||n==t||(r<t&&b.innerHeight+n)>=s)return S.cancelScroll(!0),e=t,n=p,0===(t=o)&&document.body.focus(),n||(t.focus(),document.activeElement!==t&&(t.setAttribute("tabindex","-1"),t.focus(),t.style.outline="none"),b.scrollTo(0,e)),C("scrollStop",h,o,i),!(w=l=null)},f=function(e){var t,n,o;m=(u+=e-(l=l||e))/parseInt(h.speed,10),m=r+c*(n=1<m?1:m,"easeInQuad"===(t=h).easing&&(o=n*n),"easeOutQuad"===t.easing&&(o=n*(2-n)),"easeInOutQuad"===t.easing&&(o=n<.5?2*n*n:(4-2*n)*n-1),"easeInCubic"===t.easing&&(o=n*n*n),"easeOutCubic"===t.easing&&(o=--n*n*n+1),"easeInOutCubic"===t.easing&&(o=n<.5?4*n*n*n:(n-1)*(2*n-2)*(2*n-2)+1),"easeInQuart"===t.easing&&(o=n*n*n*n),"easeOutQuart"===t.easing&&(o=1- --n*n*n*n),"easeInOutQuart"===t.easing&&(o=n<.5?8*n*n*n*n:1-8*--n*n*n*n),"easeInQuint"===t.easing&&(o=n*n*n*n*n),"easeOutQuint"===t.easing&&(o=1+--n*n*n*n*n),"easeInOutQuint"===t.easing&&(o=n<.5?16*n*n*n*n*n:1+16*--n*n*n*n*n),(o=t.customEasing?t.customEasing(n):o)||n),b.scrollTo(0,Math.floor(m)),d(m,a)||(w=b.requestAnimationFrame(f),l=e)},(u=0)===b.pageYOffset&&b.scrollTo(0,0),e=o,t=h,p||history.pushState&&t.updateURL&&history.pushState({smoothScroll:JSON.stringify(t),anchor:e.id},document.title,e===document.documentElement?"#top":"#"+e.id),C("scrollStart",h,o,i),S.cancelScroll(!0),b.requestAnimationFrame(f))};return S.destroy=function(){g&&(document.removeEventListener("click",t,!1),b.removeEventListener("resize",i,!1),b.removeEventListener("popstate",n,!1),S.cancelScroll(),w=a=v=y=r=g=null)},S.init=function(e){if(!("querySelector"in document&&"addEventListener"in b&&"requestAnimationFrame"in b&&"closest"in b.Element.prototype))throw"Smooth Scroll: This browser does not support the required JavaScript methods and browser APIs.";S.destroy(),g=E(q,e||{}),y=g.header?document.querySelector(g.header):null,v=A(y),document.addEventListener("click",t,!1),y&&b.addEventListener("resize",i,!1),g.updateURL&&g.popstate&&b.addEventListener("popstate",n,!1)},S.init(e),S}});var gpscroll=new SmoothScroll(gpSmoothScroll.elements.join(),{speed:gpSmoothScroll.duration,offset:function(e,t){var n=document.body,o=document.querySelector("#site-navigation"),i=document.querySelector("#sticky-navigation"),r=document.querySelector("#mobile-header"),a=document.querySelector(".menu-toggle"),c=0;return r&&(r.offsetWidth||r.offsetHeight||r.getClientRects().length)?n.classList.contains("mobile-header-sticky")&&(c+=r.clientHeight):a&&(a.offsetWidth||a.offsetHeight||a.getClientRects().length)?(n.classList.contains("both-sticky-menu")||n.classList.contains("mobile-sticky-menu"))&&(i?c+=i.clientHeight:o&&(c+=o.clientHeight)):(n.classList.contains("both-sticky-menu")||n.classList.contains("desktop-sticky-menu"))&&(i?c+=i.clientHeight:o&&(c+=o.clientHeight)),gpSmoothScroll.offset||c}});