
// Sticky Plugin v1.0.4 for jQuery
// =============
// Author: Anthony Garand
// Improvements by German M. Bravo (Kronuz) and Ruud Kamphuis (ruudk)
// Improvements by Leonardo C. Daronco (daronco)
// Created: 02/14/2011
// Date: 07/20/2015
// Website: http://stickyjs.com/
// Description: Makes an element on the page stick on the screen as you scroll
//              It will only set the 'top' and 'position' of your element, you
//              might need to adjust the width in some cases.
!function(t){"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof module&&module.exports?module.exports=t(require("jquery")):t(jQuery)}(function(t){var e=Array.prototype.slice,i=Array.prototype.splice,n={topSpacing:0,bottomSpacing:0,className:"is-sticky",wrapperClassName:"sticky-wrapper",center:!1,getWidthFrom:"",widthFromWrapper:!0,responsiveWidth:!1,zIndex:"auto"},r=t(window),s=t(document),o=[],a=r.height(),c=function(){for(var e=r.scrollTop(),i=s.height(),n=i-a,c=e>n?n-e:0,p=0,d=o.length;d>p;p++){var l=o[p],u=l.stickyWrapper.offset().top,h=u-l.topSpacing-c;if(l.stickyWrapper.css("height",l.stickyElement.outerHeight()),e>h){var g=i-l.stickyElement.outerHeight()-l.topSpacing-l.bottomSpacing-e-c;if(0>g?g+=l.topSpacing:g=l.topSpacing,l.currentTop!==g){var m;l.getWidthFrom?m=t(l.getWidthFrom).width()||null:l.widthFromWrapper&&(m=l.stickyWrapper.width()),null==m&&(m=l.stickyElement.width()),l.stickyElement.css("width",m).css("position","fixed").css("top",g).css("z-index",l.zIndex),l.stickyElement.parent().addClass(l.className),null===l.currentTop?l.stickyElement.trigger("sticky-start",[l]):l.stickyElement.trigger("sticky-update",[l]),l.currentTop===l.topSpacing&&l.currentTop>g||null===l.currentTop&&g<l.topSpacing?l.stickyElement.trigger("sticky-bottom-reached",[l]):null!==l.currentTop&&g===l.topSpacing&&l.currentTop<g&&l.stickyElement.trigger("sticky-bottom-unreached",[l]),l.currentTop=g}var y=l.stickyWrapper.parent(),f=l.stickyElement.offset().top+l.stickyElement.outerHeight()>=y.offset().top+y.outerHeight()&&l.stickyElement.offset().top<=l.topSpacing;f?l.stickyElement.css("position","absolute").css("top","").css("bottom",0).css("z-index",""):l.stickyElement.css("position","fixed").css("top",g).css("bottom","").css("z-index",l.zIndex)}else null!==l.currentTop&&(l.stickyElement.css({width:"",position:"",top:"","z-index":""}),l.stickyElement.parent().removeClass(l.className),l.stickyElement.trigger("sticky-end",[l]),l.currentTop=null)}},p=function(){a=r.height();for(var e=0,i=o.length;i>e;e++){var n=o[e],s=null;n.getWidthFrom?n.responsiveWidth&&(s=t(n.getWidthFrom).width()):n.widthFromWrapper&&(s=n.stickyWrapper.width()),null!=s&&n.stickyElement.css("width",s)}},d={init:function(e){var i=t.extend({},n,e);return this.each(function(){var e=t(this),r=e.attr("id"),s=r?r+"-"+n.wrapperClassName:n.wrapperClassName,a=t("<div></div>").attr("id",s).addClass(i.wrapperClassName);e.wrapAll(function(){return 0==t(this).parent("#"+s).length?a:void 0});var c=e.parent();i.center&&c.css({width:e.outerWidth(),marginLeft:"auto",marginRight:"auto"}),"right"===e.css("float")&&e.css({"float":"none"}).parent().css({"float":"right"}),i.stickyElement=e,i.stickyWrapper=c,i.currentTop=null,o.push(i),d.setWrapperHeight(this),d.setupChangeListeners(this)})},setWrapperHeight:function(e){var i=t(e),n=i.parent();n&&n.css("height",i.outerHeight())},setupChangeListeners:function(t){if(window.MutationObserver){var e=new window.MutationObserver(function(e){(e[0].addedNodes.length||e[0].removedNodes.length)&&d.setWrapperHeight(t)});e.observe(t,{subtree:!0,childList:!0})}else window.addEventListener?(t.addEventListener("DOMNodeInserted",function(){d.setWrapperHeight(t)},!1),t.addEventListener("DOMNodeRemoved",function(){d.setWrapperHeight(t)},!1)):window.attachEvent&&(t.attachEvent("onDOMNodeInserted",function(){d.setWrapperHeight(t)}),t.attachEvent("onDOMNodeRemoved",function(){d.setWrapperHeight(t)}))},update:c,unstick:function(){return this.each(function(){for(var e=this,n=t(e),r=-1,s=o.length;s-->0;)o[s].stickyElement.get(0)===e&&(i.call(o,s,1),r=s);-1!==r&&(n.unwrap(),n.css({width:"",position:"",top:"","float":"","z-index":""}))})}};window.addEventListener?(window.addEventListener("scroll",c,!1),window.addEventListener("resize",p,!1)):window.attachEvent&&(window.attachEvent("onscroll",c),window.attachEvent("onresize",p)),t.fn.sticky=function(i){return d[i]?d[i].apply(this,e.call(arguments,1)):"object"!=typeof i&&i?void t.error("Method "+i+" does not exist on jQuery.sticky"):d.init.apply(this,arguments)},t.fn.unstick=function(i){return d[i]?d[i].apply(this,e.call(arguments,1)):"object"!=typeof i&&i?void t.error("Method "+i+" does not exist on jQuery.sticky"):d.unstick.apply(this,arguments)},t(function(){setTimeout(c,0)})});



!function(a,b,c,d){var e=function(d,e){this.elem=d,this.$elem=a(d),this.options=e,this.metadata=this.$elem.data("plugin-options"),this.$win=a(b),this.sections={},this.didScroll=!1,this.$doc=a(c),this.docHeight=this.$doc.height()};e.prototype={defaults:{navItems:"a",currentClass:"current",changeHash:!1,easing:"swing",filter:null,scrollOffset:0,scrollSpeed:750,scrollThreshold:.5,begin:!1,end:!1,scrollChange:!1},init:function(){return this.config=a.extend({},this.defaults,this.options,this.metadata),this.$nav=this.$elem.find(this.config.navItems),this.config.filter&&(this.$nav=this.$nav.filter(this.config.filter)),this.$nav.on("click.onePageNav",a.proxy(this.handleClick,this)),this.getPositions(),this.bindInterval(),this.$win.on("resize.onePageNav",a.proxy(this.getPositions,this)),this},adjustNav:function(a,b){a.$elem.find("."+a.config.currentClass).removeClass(a.config.currentClass),b.addClass(a.config.currentClass)},bindInterval:function(){var a,b=this;b.$win.on("scroll.onePageNav",function(){b.didScroll=!0}),b.t=setInterval(function(){a=b.$doc.height(),b.didScroll&&(b.didScroll=!1,b.scrollChange()),a!==b.docHeight&&(b.docHeight=a,b.getPositions())},250)},getHash:function(a){return a.attr("href").split("#")[1]},getPositions:function(){var b,c,d,e=this;e.$nav.each(function(){b=e.getHash(a(this)),d=a("#"+b),d.length&&(c=d.position().top,e.sections[b]=Math.round(c))})},getSection:function(a){var b=null,c=Math.round(this.$win.height()*this.config.scrollThreshold);for(var d in this.sections)this.sections[d]-c<a&&(b=d);return b},handleClick:function(c){var d=this,e=a(c.currentTarget),f=e.parent(),g=d.getHash(e),h="#"+g;g&&!d.isExternalLink(e)&&0!==a(h).length&&(f.hasClass(d.config.currentClass)||(d.config.begin&&d.config.begin(),d.adjustNav(d,f),d.unbindInterval(),d.scrollTo(h,function(){d.config.changeHash&&(b.location.hash=h),d.bindInterval(),d.config.end&&d.config.end()})),c.preventDefault())},scrollChange:function(){var a,b=this.$win.scrollTop(),c=this.getSection(b);null!==c&&(a=this.$elem.find('a[href$="#'+c+'"]').parent(),a.hasClass(this.config.currentClass)||(this.adjustNav(this,a),this.config.scrollChange&&this.config.scrollChange(a)))},scrollTo:function(b,c){var d=a(b).position().top;a("html, body").animate({scrollTop:d-this.config.scrollOffset},this.config.scrollSpeed,this.config.easing,c)},unbindInterval:function(){clearInterval(this.t),this.$win.unbind("scroll.onePageNav")},isExternalLink:function(a){return b.location.host!==a.get(0).host}},e.defaults=e.prototype.defaults,a.fn.onePageNav=function(a){return this.each(function(){new e(this,a).init()})}}(jQuery,window,document);



jQuery(document).ready(function(){function a(a){a.matches?jQuery(".main-navigation .menu").slideUp("slow"):jQuery("#site-navigation ul").show()}var b=window.matchMedia("(max-width: 980px)");a(b),b.addListener(a),jQuery('#site-navigation li > a[href*="#"]').click(function(){a(b)});var c=function(){jQuery(".search-wrap .search-box").removeClass("active")};if(jQuery(".search-wrap .search-icon").on("click",function(){jQuery(".search-wrap .search-box").toggleClass("active"),setTimeout(function(){jQuery(".search-wrap .search-box.active input").focus()},200),jQuery(document).on("keyup",function(a){27===a.keyCode&&jQuery(".search-wrap .search-box").hasClass("active")&&c()}),jQuery(document).on("click.outEvent",function(a){a.target.closest(".search-wrap")||(c(),jQuery(document).off("click.outEvent"))})}),jQuery(".main-navigation .menu-item-has-children").append('<span class="sub-toggle"> <i class="fa fa-angle-down"></i> </span>'),jQuery(".main-navigation .menu-toggle").click(function(){jQuery(".main-navigation .menu").slideToggle("slow")}),jQuery(".main-navigation .sub-toggle").on("click",function(){var a=jQuery(this).children(".fa"),b=jQuery(this).parent("li"),c=b.siblings(".menu-item-has-children"),d=c.find(".fa");a.toggleClass("animate-icon"),d.hasClass("animate-icon")&&d.removeClass("animate-icon"),c.not(b).removeClass("mobile-menu--slided").children("ul").slideUp("1000"),b.toggleClass("mobile-menu--slided").children("ul").slideToggle("1000")}),jQuery(window).load(function(){var a=jQuery("#masthead-sticky-wrapper").height()-1;jQuery("#site-navigation").onePageNav({currentClass:"current-flash-item",changeHash:!1,scrollSpeed:1500,scrollOffset:a,scrollThreshold:.5,filter:"",easing:"swing"})}),"undefined"!=typeof jQuery.fn.sticky){var d=jQuery("#wpadminbar");d.length?jQuery(".header-sticky .site-header").sticky({topSpacing:d.height()}):jQuery(".header-sticky .site-header").sticky({topSpacing:0})}"undefined"!=typeof jQuery.fn.counterUp&&jQuery(".counter").counterUp({delay:10,time:1e3}),jQuery(document).ready(function(){jQuery("#scroll-up").hide(),jQuery(function(){jQuery(window).scroll(function(){jQuery(this).scrollTop()>1e3?jQuery("#scroll-up").fadeIn():jQuery("#scroll-up").fadeOut()}),jQuery("a#scroll-up").click(function(){return jQuery("body,html").animate({scrollTop:0},800),!1})})}),jQuery("#preloader-background").length>0&&setTimeout(function(){jQuery("#preloader-background").hide()},600);var e=jQuery(".site-header"),f=e.height(),g=jQuery(window).height(),h=jQuery(".tg-slider-widget.full-screen .swiper-container");jQuery("body").hasClass("transparent")?h.css({height:g}):h.css({height:g-f})}),jQuery(window).on("load",function(){if("function"==typeof Swiper){jQuery(".tg-section.tg-slider-widget").each(function(a,b){var c=jQuery(this).find(".swiper-container"),d=jQuery(this).find(".swiper-button-next"),e=jQuery(this).find(".swiper-button-prev");f="tgsliderinstance-"+a;var f=new Swiper(c,{paginationClickable:!0,slidesPerView:1,autoplay:{delay:4e3},speed:1e3,loop:!0,navigation:{nextEl:d,prevEl:e}});jQuery(this).on({mouseenter:function(){f.autoplay.stop()},mouseleave:function(){f.autoplay.start()}}),setTimeout(function(){f.update()},500)});new Swiper(".tg-testimonial-widget .swiper-container",{pagination:{el:".swiper-pagination",clickable:!0},paginationClickable:!0,direction:"horizontal",slidesPerView:2,spaceBetween:30,breakpoints:{1024:{slidesPerView:2,spaceBetween:30},768:{slidesPerView:1,spaceBetween:10},640:{slidesPerView:1,spaceBetween:10},320:{slidesPerView:1,spaceBetween:10}}}),new Swiper(".tg-client-widget .swiper-container",{slidesPerView:4,autoplay:1e3,direction:"horizontal",setWrapperSize:!0})}if("function"==typeof jQuery.fn.isotope){var a=jQuery(".grid").isotope({itemSelector:".element-item",layoutMode:"fitRows"}),b={numberGreaterThan50:function(){var a=jQuery(this).find(".number").text();return parseInt(a,10)>50},ium:function(){var a=jQuery(this).find(".name").text();return a.match(/ium$/)}};jQuery(".filters-button-group").on("click","button",function(){var c=jQuery(this).attr("data-filter");c=b[c]||c,a.isotope({filter:c})}),jQuery(".button-group").each(function(a,b){var c=jQuery(b);c.on("click","button",function(){c.find(".is-checked").removeClass("is-checked"),jQuery(this).addClass("is-checked")})})}});



!function(){function a(){for(var a=this;-1===a.className.indexOf("nav-menu");)"li"===a.tagName.toLowerCase()&&(-1!==a.className.indexOf("focus")?a.className=a.className.replace(" focus",""):a.className+=" focus"),a=a.parentElement}var b,c,d,e,f,g;if(b=document.getElementById("site-navigation"),b&&(c=b.getElementsByClassName("menu-toggle")[0],"undefined"!=typeof c)){if(d=b.getElementsByTagName("ul")[0],"undefined"==typeof d)return void(c.style.display="none");for(d.setAttribute("aria-expanded","false"),-1===d.className.indexOf("nav-menu")&&(d.className+=" nav-menu"),c.onclick=function(){-1!==b.className.indexOf("toggled")?(b.className=b.className.replace(" toggled",""),c.setAttribute("aria-expanded","false"),d.setAttribute("aria-expanded","false")):(b.className+=" toggled",c.setAttribute("aria-expanded","true"),d.setAttribute("aria-expanded","true"))},e=d.getElementsByTagName("a"),f=0,g=e.length;g>f;f++)e[f].addEventListener("focus",a,!0),e[f].addEventListener("blur",a,!0);!function(a){var b,c,d=a.querySelectorAll(".menu-item-has-children > a, .page_item_has_children > a");if("ontouchstart"in window)for(b=function(a){var b,c=this.parentNode;if(c.classList.contains("focus"))c.classList.remove("focus");else{for(a.preventDefault(),b=0;b<c.parentNode.children.length;++b)c!==c.parentNode.children[b]&&c.parentNode.children[b].classList.remove("focus");c.classList.add("focus")}},c=0;c<d.length;++c)d[c].addEventListener("touchstart",b,!1)}(b)}}(),jQuery(window).load(function(){if(window.matchMedia("(max-width: 980px)").matches&&jQuery("#masthead-sticky-wrapper").length>=1){var a=jQuery(window).height(),b=jQuery("#masthead > .header-top"),c=jQuery("#masthead > .header-bottom"),d=0,e=0;b.length>0&&"none"!=b.css("display")&&(d=b.outerHeight()),c.length>0&&"none"!=c.css("display")&&(e=c.outerHeight());var f=a-d-e-50,g=jQuery("#site-navigation").find("ul").first();g.css("max-height",f),g.addClass("menu-scrollbar")}});



(function(){var isWebkit=navigator.userAgent.toLowerCase().indexOf('webkit')>-1,isOpera=navigator.userAgent.toLowerCase().indexOf('opera')>-1,isIe=navigator.userAgent.toLowerCase().indexOf('msie')>-1;if((isWebkit||isOpera||isIe)&&document.getElementById&&window.addEventListener){window.addEventListener('hashchange',function(){var id=location.hash.substring(1),element;if(!(/^[A-z0-9_-]+$/.test(id))){return}
element=document.getElementById(id);if(element){if(!(/^(?:a|select|input|button|textarea)$/i.test(element.tagName))){element.tabIndex=-1}
element.focus()}},!1)}})();



jQuery((function(e){const t=function(){let t=e(panelsStyles.fullContainer);0===t.length&&(t=e("body"));const a=e(".siteorigin-panels-stretch.panel-row-style");a.length&&(a.each((function(){const a=e(this),l=a.data("stretch-type");a.css({"margin-left":0,"margin-right":0});const i=a.offset().left-t.offset().left,s=t.outerWidth()-i-a.parent().outerWidth();a.css({"margin-left":-i+"px","margin-right":-s+"px"}),"full"===l&&a.css({"padding-left":i+"px","padding-right":s+"px"})})),e(window).trigger("panelsStretchRows"))};if(panelsStyles.stretchRows&&e(window).on("resize load",t).trigger("resize"),"undefined"!=typeof parallaxStyles&&"undefined"!=typeof simpleParallax){const{"disable-parallax-mobile":e,"mobile-breakpoint":t,delay:a,scale:l}=parallaxStyles;e&&window.matchMedia(`(max-width: ${t})`).matches||new simpleParallax(document.querySelectorAll("[data-siteorigin-parallax], .sow-slider-image-parallax .sow-slider-background-image"),{delay:a,scale:l<1.1?1.1:l})}e("body").removeClass("siteorigin-panels-before-js")}));


