function initScrollingSections(){var n,i,e,t=jQuery("#content").find(".fusion-scroll-section"),s=(Number(fusionContainerVars.is_sticky_header_transparent)||"function"!=typeof getStickyHeaderHeight?0:getStickyHeaderHeight(!0))+(jQuery("#wpadminbar").length?parseInt(jQuery("#wpadminbar").height(),10):0);t.length&&(jQuery("#content").find(".non-hundred-percent-height-scrolling").length||1!==t.length||jQuery.trim(jQuery("#sliders-container").html())||(t.addClass("active"),t.find(".fusion-scroll-section-nav li:first a").addClass("active"),i=!0),t.each(function(){1<jQuery(this).children("div").length&&(e=s?"calc("+(100*jQuery(this).children("div").size()+50)+"vh - "+s+"px)":100*jQuery(this).children("div").size()+50+"vh",jQuery(this).css("height",e),s&&(jQuery(this).find(".hundred-percent-height-scrolling").css("height","calc(100vh - "+s+"px)"),jQuery(this).find(".fusion-scroll-section-nav").css("top","calc(50% + "+s/2+"px)")))}),n=jQuery(window).scrollTop(),jQuery(window).scroll(function(){var e=jQuery(window).scrollTop();jQuery(".fusion-scroll-section").each(function(){1<jQuery(this).children("div").length&&!jQuery(this).hasClass("fusion-scroll-section-mobile-disabled")&&jQuery(this).fusionPositionScrollSectionElements(n,e,i)}),n=e}),jQuery(".fusion-scroll-section-link").on("click",function(e){var n=jQuery(this).parents(".fusion-scroll-section"),i=parseInt(jQuery(this).parents(".fusion-scroll-section-nav").find(".fusion-scroll-section-link.active").data("element"),10),t=parseInt(jQuery(this).data("element"),10),s=Math.abs(t-i),o=(350+30*(s-1))*s;e.preventDefault(),0!==s&&(20<s&&(o=950*s),jQuery(this).parents(".fusion-scroll-section").find(".fusion-scroll-section-element").removeClass("active"),jQuery("html, body").animate({scrollTop:Math.ceil(n.offset().top)+jQuery(window).height()*(jQuery(this).data("element")-1)},o,"linear"))})),jQuery(".hundred-percent-height").length&&(setCorrectResizeValuesForScrollSections(),jQuery(window).on("resize",function(){setCorrectResizeValuesForScrollSections()}))}function setCorrectResizeValuesForScrollSections(){var e=jQuery("#content").find(".fusion-scroll-section"),n=0,i=0,t=jQuery("#wpadminbar").length?parseInt(jQuery("#wpadminbar").height(),10):0;e.length&&(jQuery(".fusion-scroll-section.active").find(".fusion-scroll-section-element").css({left:jQuery("#content").offset().left}),jQuery(".fusion-scroll-section").find(".fusion-scroll-section-element").css({width:jQuery("#content").width()}),0==fusionContainerVars.container_hundred_percent_height_mobile&&(Modernizr.mq("only screen and (max-width: "+fusionContainerVars.content_break_point+"px)")?(jQuery(".fusion-scroll-section").removeClass("active").addClass("fusion-scroll-section-mobile-disabled"),jQuery(".fusion-scroll-section").attr("style",""),jQuery(".fusion-scroll-section").find(".fusion-scroll-section-element").attr("style",""),jQuery(".fusion-scroll-section").find(".hundred-percent-height-scrolling").css("height","auto"),jQuery(".fusion-scroll-section").find(".fusion-fullwidth-center-content").css("height","auto")):jQuery(".fusion-scroll-section").hasClass("fusion-scroll-section-mobile-disabled")&&(jQuery(".fusion-scroll-section").find(".fusion-fullwidth-center-content").css("height",""),Number(fusionContainerVars.is_sticky_header_transparent)||"function"!=typeof getStickyHeaderHeight||(n=getStickyHeaderHeight(!0)),i=n+t,e.each(function(){1<jQuery(this).children("div").length&&(jQuery(this).css("height",100*jQuery(this).children("div").size()+50+"vh"),jQuery(this).find(".hundred-percent-height-scrolling").css("height","calc(100vh - "+i+"px)"))}),scrollToCurrentScrollSection()))),jQuery(".hundred-percent-height.non-hundred-percent-height-scrolling").length&&(Number(fusionContainerVars.is_sticky_header_transparent)||"function"!=typeof getStickyHeaderHeight||(n=getStickyHeaderHeight(!0)),i=n+t,0==fusionContainerVars.container_hundred_percent_height_mobile&&(Modernizr.mq("only screen and (max-width: "+fusionContainerVars.content_break_point+"px)")?(jQuery(".hundred-percent-height.non-hundred-percent-height-scrolling").css("height","auto"),jQuery(".hundred-percent-height.non-hundred-percent-height-scrolling").find(".fusion-fullwidth-center-content").css("height","auto")):(jQuery(".hundred-percent-height.non-hundred-percent-height-scrolling").css("height","calc(100vh - "+i+"px)"),jQuery(".hundred-percent-height.non-hundred-percent-height-scrolling").find(".fusion-fullwidth-center-content").css("height",""))))}function scrollToCurrentScrollSection(){var s=Math.ceil(jQuery(window).scrollTop()),e=jQuery(window).height(),o=Math.floor(s+e),n=Number(fusionContainerVars.is_sticky_header_transparent)||"function"!=typeof getStickyHeaderHeight?0:getStickyHeaderHeight(!0),i=jQuery("#wpadminbar").length?parseInt(jQuery("#wpadminbar").height(),10):0;s+=n+i,jQuery(".fusion-page-load-link").hasClass("fusion-page.load-scroll-section-link")||jQuery(".fusion-scroll-section").each(function(){var e=jQuery(this),n=Math.ceil(e.offset().top),i=Math.ceil(e.outerHeight()),t=Math.floor(n+i);n<=s&&o<=t&&(e.addClass("active"),jQuery("html, body").animate({scrollTop:n-50},{duration:50,easing:"easeInExpo",complete:function(){jQuery("html, body").animate({scrollTop:n},{duration:50,easing:"easeOutExpo",complete:function(){Modernizr.mq("only screen and (max-width: "+fusionContainerVars.content_break_point+"px)")||jQuery(".fusion-scroll-section").removeClass("fusion-scroll-section-mobile-disabled")}})}}))})}jQuery(window).on("load fusion-element-render-fusion_builder_container resize",function(e,n){var i=void 0!==n?jQuery('div[data-cid="'+n+'"]').find(".fullwidth-faded"):jQuery(".fullwidth-faded"),t=void 0!==n?jQuery('div[data-cid="'+n+'"]').find(".hundred-percent-height"):jQuery(".hundred-percent-height"),s=Number(fusionContainerVars.is_sticky_header_transparent)||"function"!=typeof getStickyHeaderHeight?0:getStickyHeaderHeight(!0),o=jQuery("#wpadminbar").length?parseInt(jQuery("#wpadminbar").height(),10):0,r=jQuery("body").hasClass("fusion-builder-live")&&!jQuery("body").hasClass("fusion-builder-preview-mode"),l=s+o;i.fusionScroller({type:"fading_blur"}),t.css("min-height","").css("height",""),t.find(".fusion-fullwidth-center-content").css("min-height",""),0==fusionContainerVars.container_hundred_percent_height_mobile&&Modernizr.mq("only screen and (max-width: "+fusionContainerVars.content_break_point+"px)")?(t.css("height","auto"),r&&(t.css("min-height","0"),t.find(".fusion-fullwidth-center-content").css("min-height","0"))):(t.css("height","calc(100vh - "+l+"px)"),r&&(t.css("min-height","calc(100vh - "+l+"px)"),t.find(".fusion-fullwidth-center-content").css("min-height","calc(100vh - "+l+"px)")))}),jQuery(document).ready(function(){initScrollingSections(),Modernizr.mq("only screen and (max-width: "+fusionContainerVars.content_break_point+"px)")&&jQuery(".fullwidth-faded").each(function(){var e=jQuery(this).css("background-image"),n=jQuery(this).css("background-color");jQuery(this).parent().css("background-image",e),jQuery(this).parent().css("background-color",n),jQuery(this).remove()})}),jQuery(window).on("load",function(){jQuery("#content").find(".fusion-scroll-section").length&&void 0===jQuery(".fusion-page-load-link").attr("href")&&setTimeout(function(){scrollToCurrentScrollSection()},400)}),function(m){"use strict";m.fn.fusionPositionScrollSectionElements=function(e,n,i){var t,s,o,r,l=m(this),c=Math.ceil(l.offset().top),a=Math.ceil(l.outerHeight()),d=Math.floor(c+a),h=Math.ceil(m(window).scrollTop()),u=m(window).height(),f=Math.floor(h+u),y=l.find(".fusion-scroll-section-element").length,g=0;if(i=i||!1,s=m("#wpadminbar").length?parseInt(m("#wpadminbar").height(),10):0,h+=s+=Number(fusionContainerVars.is_sticky_header_transparent)||"function"!=typeof getStickyHeaderHeight?0:getStickyHeaderHeight(!0),t=m("#content").width(),o=m("#content").offset().left,"0",i||(c<=h&&f<=d?l.addClass("active"):l.removeClass("active")),e<n){for(r=1;r<y;r++)c+u*r<=h&&h<c+u*(r+1)&&(g=r+1);c<=h&&h<c+u?(l.find(".fusion-scroll-section-element").removeClass("active"),l.children(":nth-child(1)").addClass("active"),l.find(".fusion-scroll-section-nav a").removeClass("active"),l.find('.fusion-scroll-section-nav a[data-element="'+l.children(":nth-child(1)").data("element")+'"] ').addClass("active"),l.find(".fusion-scroll-section-element").css({position:"fixed",top:s,left:o,padding:"0 0",width:t}),l.children(":nth-child(1)").css("display","block")):d<=f&&"absolute"!==l.find(".fusion-scroll-section-element").last().css("position")?(l.find(".fusion-scroll-section-element").removeClass("active"),l.find(".fusion-scroll-section-element").last().addClass("active"),l.find(".fusion-scroll-section-element").css("position","absolute"),l.find(".fusion-scroll-section-element").last().css({top:"auto",left:"0",bottom:"0",padding:""})):0<g&&!l.children(":nth-child("+g+")").hasClass("active")&&(l.find(".fusion-scroll-section-element").removeClass("active"),l.children(":nth-child("+g+")").addClass("active"),l.find(".fusion-scroll-section-nav a").removeClass("active"),l.find('.fusion-scroll-section-nav a[data-element="'+l.children(":nth-child("+g+")").data("element")+'"] ').addClass("active"))}else if(n<e){for(r=1;r<y;r++)h<c+u*r&&c+u*(r-1)<h&&(g=r);f<=d&&c+u*(y-1)<h&&"fixed"!==l.find(".fusion-scroll-section-element").last().css("position")?(l.find(".fusion-scroll-section-element").removeClass("active"),l.find(".fusion-scroll-section-element").last().addClass("active"),l.find(".fusion-scroll-section-nav a").removeClass("active"),l.find('.fusion-scroll-section-nav a[data-element="'+l.find(".fusion-scroll-section-element").last().data("element")+'"] ').addClass("active"),l.find(".fusion-scroll-section-element").css({position:"fixed",top:s,left:o,padding:"0 0",width:t}),l.find(".fusion-scroll-section-element").last().css("display","block")):(h<=c||0===m(window).scrollTop()&&l.find(".fusion-scroll-section-element").first().hasClass("active"))&&""!==l.find(".fusion-scroll-section-element").first().css("position")?(l.find(".fusion-scroll-section-element").removeClass("active"),l.find(".fusion-scroll-section-element").first().addClass("active"),l.find(".fusion-scroll-section-element").css("position",""),l.find(".fusion-scroll-section-element").first().css("padding","")):0<g&&!l.children(":nth-child("+g+")").hasClass("active")&&(l.find(".fusion-scroll-section-element").removeClass("active"),l.children(":nth-child("+g+")").addClass("active"),l.find(".fusion-scroll-section-nav a").removeClass("active"),l.find('.fusion-scroll-section-nav a[data-element="'+l.children(":nth-child("+g+")").data("element")+'"] ').addClass("active"))}}}(jQuery);