(function(){function setOpacity(){$('body').find('.hero').each(function(index){var inner=$(this).find('.inner');inner.fadeIn(1000);});}
function verticalCenter(){if($(window).width()>767){$('body').find('.vertical-center').each(function(index){var containerHeight=$(this).outerHeight();var inner=$(this).find('.inner');if(inner.length===0)
return;var boxHeight=inner.outerHeight(true);var top=(containerHeight/2)-(boxHeight/2);inner.css("top",top+"px");});}}
function verticalBottom(){if($(window).width()>767){$('body').find('.vertical-bottom').each(function(index){var containerHeight=$(this).outerHeight();var inner=$(this).find('.content-box');if(inner.length===0)
return;inner.css("height",containerHeight+"px");});}}
function heroLinkBox(){if($(window).width()>767){$('body').find('.hero').each(function(index){var containerHeight=$(this).outerHeight();var inner=$(this).find('> .hero-link');if(inner.length===0)
return;inner.css("height",containerHeight+"px");});}}
function verticalCenterSlider(){if($(window).width()>767){$('body').find('.slider .hero').each(function(index){var containerHeight=$(this).outerHeight();var inner=$(this).find('.inner');if(inner.length===0)
return;var boxHeight=inner.outerHeight(true);var top=(containerHeight/2)-(boxHeight/2);inner.css("top",top+"px");});}}
function horizontalCenter(){if($(window).width()>767){$('[class*="horizontal-"]').each(function(){var inner=$(this).find('.inner');if(inner.length===0)
return;var boxWidth=inner.outerWidth(true);var left=(inner.parent().width()-boxWidth)/2;inner.css("left",left+"px");});}}
function moveHeroContentUnderImage(){if($(window).width()<767){$('body').find('.hero').each(function(index){var textBox=$(this).find('.content-box');textBox.insertAfter($(this));});}else{$('body').find('.hero + .content-box').each(function(index){$(this).prev('.hero').append($(this));});}}
$(window).on("load resize orientationchange",function(event){verticalCenter();verticalCenterSlider();horizontalCenter();verticalBottom();heroLinkBox();moveHeroContentUnderImage();setOpacity();});})();;