!function(a){function b(a){this.markup=null,this.selector=null,this.fixed=!0,this.visible=!1,this.init=function(){if(this.valid()){void 0!==a&&void 0!==a.fixed&&(this.fixed=a.fixed),this.selector=a&&a.selector?a.selector:"#go-top",this.getMarkup();var b=this;if(jQuery("body").append(this.markup),this.fixed){jQuery(this.selector).hide();var c=jQuery(window).height();jQuery(window).scroll(function(){jQuery(window).scrollTop()>c-100?0==b.visible&&(jQuery(b.selector).fadeIn(),b.visible=!0):1==b.visible&&(jQuery(b.selector).fadeOut(),b.visible=!1)}),jQuery(this.selector).scrollTo()}}},this.getMarkup=function(){var b=this.fixed?"fixed":"absolute",c='style="position: '+b+'; z-index:999999; bottom: 20px; right: 20px;"',d="
Scroll To Top
';this.markup=a&&a.markup?a.markup:d},this.valid=function(){return!(a&&a.markup&&!a.selector)||(alert('Please provide selector. eg. { markup: "", selector: "#scroll-top"}'),!1)}}function c(b){var c=b+" .menu-item-has-children > a";a(c).each(function(){var b=a(this).text();b+='',a(this).html(b)}),a(document).on("click",c+" span.triangle",function(b){b.preventDefault(),b.stopPropagation(),$parentLi=a(this).parent().parent("li"),$childLi=$parentLi.find("li"),$parentLi.hasClass("open")?($parentLi.removeClass("open"),$childLi.removeClass("open"),a(this).parent("a").next().slideUp(),a(this).parent("a").next().find("ul").slideUp()):($parentLi.addClass("open"),a(this).parent("a").next().slideDown())})}function d(){var b,c=function(){a("body").hasClass("fixed-nav-active")||a("body").addClass("fixed-nav-active")},d=function(){a("body").hasClass("fixed-nav-active")&&a("body").removeClass("fixed-nav-active")},e=function(b){a("#fixed-header").css({top:b})},f=function(){a("#fixed-header").css({"margin-top":"0"})},g=function(){a("#fixed-header").css({"margin-top":"-100%"})},h=function(){b=a(".top-header").outerHeight()+a("#masthead").outerHeight(),e(b)},i=function(){var h=jQuery(document).scrollTop(),i=0,j=b+12,k=a(window).width();if(BUSINESSGRAVITY.is_admin_bar_showing&&k>=782&&(h+=32),j)j>=h?(i=j-jQuery(document).scrollTop(),d(),g()):BUSINESSGRAVITY.is_admin_bar_showing&&k>=782?(i=32,c(),f()):(c(),f());else{var l=a(".top-header, #masthead").outerHeight(),h=jQuery(document).scrollTop();l>=h?(i=BUSINESSGRAVITY.is_admin_bar_showing&&k>=782?32-h:-h,d(),g()):(i=BUSINESSGRAVITY.is_admin_bar_showing&&k>=782?32:0,c(),f())}e(i)};a(window).resize(function(){h(),i()}),h(),i(),a(window).scroll(i),jQuery(window).load(function(){h(),i()})}function e(){var b=a(".top-header").outerHeight(),c=a(".site-header-four").outerHeight();a(".site-header-four").css({top:b}),BUSINESSGRAVITY.is_admin_bar_showing&&a(".site-header-four").css({top:b+32}),a(".wrap-inner-banner .page-header, .block-slider .slide-inner").css({paddingTop:c})}function f(){a(".testimonial-carousel").owlCarousel({items:1,animateOut:"fadeOut",navContainer:".block-testimonial .controls",dotsContainer:"#testimonial-pager",responsiveClass:!0,responsive:{0:{items:1,nav:!0}},rtl:"1"==BUSINESSGRAVITY.is_rtl,loop:!1,dots:!0})}function g(){var a=parseInt(jQuery(".block-slider .slide-item").length);jQuery(".home-slider").owlCarousel({items:1,autoHeight:!1,autoHeightClass:"name",animateOut:"fadeOut",navContainer:".block-slider .controls",dotsContainer:"#kt-slide-pager",autoplay:BUSINESSGRAVITY.home_slider.autoplay,autoplayTimeout:parseInt(BUSINESSGRAVITY.home_slider.timeout),loop:a>1,rtl:"1"==BUSINESSGRAVITY.is_rtl})}function h(){var a=parseInt(jQuery(".block-highlight .slide-item").length);jQuery(".highlight-slider").owlCarousel({items:1,autoHeight:!1,autoHeightClass:"name",animateOut:"fadeOut",navContainer:".block-highlight .controls",margin:30,autoplay:BUSINESSGRAVITY.highlight.autoplay,loop:a>1,rtl:"1"==BUSINESSGRAVITY.is_rtl,responsive:{768:{items:3,nav:!0}}})}+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"))&&void 0!==(c=b.getElementsByTagName("button")[0])){if(void 0===(d=b.getElementsByTagName("ul")[0]))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;f 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;bb&&(b=jQuery(this).height())}),b},c=function(){var c=(jQuery(window).width(),b());jQuery(a).each(function(){jQuery(this).height(c)})};jQuery(document).ready(function(){c()}),jQuery(window).resize(function(){c()}),jQuery(window).load(function(){c()})}(".block-slider .slide-item"),jQuery(".kt-contact-form-area input, .kt-contact-form-area textarea").on("focus",function(){var a=jQuery(this).attr("id");jQuery('label[for="'+a+'"]').addClass("move")}),jQuery(".kt-contact-form-area input, .kt-contact-form-area textarea").on("blur",function(){var a=jQuery(this).attr("id");jQuery('label[for="'+a+'"]').removeClass("move")});var i;!function(b){var c=a("",{class:"dropdown-toggle","aria-expanded":!1}).append('');b.find(".menu-item-has-children > a, .page_item_has_children > a").after(c),b.find(".current-menu-ancestor > button").addClass("toggled-on"),b.find(".current-menu-ancestor > .sub-menu").addClass("toggled-on"),b.find(".menu-item-has-children, .page_item_has_children").attr("aria-haspopup","true"),b.find(".dropdown-toggle").click(function(b){var c=a(this);b.preventDefault(),c.toggleClass("toggled-on"),c.parent().first().toggleClass("focus"),c.attr("aria-expanded","false"===c.attr("aria-expanded")?"true":"false")})}(a(".main-navigation")),i=a("#masthead"),i.find("#site-navigation"),i.find("#social-navigation"),jQuery(document).ready(function(){d(),g(),e(),f(),h(),a(".scroll-to").scrollTo(),new b({markup:'',selector:"#go-top"}).init(),c("#offcanvas-menu"),a(document).on("click",".offcanvas-menu-toggler, .close-offcanvas-menu, .kt-offcanvas-overlay",function(b){b.preventDefault(),a("body").toggleClass("offcanvas-menu-open")}),jQuery("body").append(''),jQuery(".masonry-wrapper").length>0&&($grid=jQuery(".masonry-wrapper").masonry({itemSelector:".masonry-grid",percentPosition:!0})),infinite_count=0,a(document.body).on("post-load",function(){infinite_count+=1;var b="#infinite-view-"+infinite_count;a(b).hide(),a(a(b+" .masonry-grid")).each(function(){$items=a(this),$grid.append($items).masonry("appended",$items)}),setTimeout(function(){$grid.masonry("layout")},500)}),a("#masthead #s").attr("placeholder",BUSINESSGRAVITY.search_placeholder),a("#searchform #s").attr("placeholder",BUSINESSGRAVITY.search_default_placeholder)}),jQuery(window).load(function(){"undefined"!=typeof $grid&&($grid.masonry("reloadItems"),$grid.masonry("layout"))}),jQuery(window).load(function(){jQuery("#site-loader").fadeOut(500)}),jQuery(window).resize(function(){e()})}(jQuery);