$(document).ready(function(){function f(){var n=t.scrollTop(),r=$(".js-background-1"),u=r.height();$(".js-background-1").css("backgroundPosition","120% "+Math.round((u-n)*i)+"px")}function u(){window.innerWidth>750&&!n&&(r=window.setInterval(e,5e3),n=!0)}function e(){($(".headerImage").is(":visible")||$(".headerImageHome").is(":visible"))&&($(".layer2").fadeToggle(3e3).delay(2e3),$(".homeLayer2").fadeToggle(3e3).delay(2e3))}var t,i,r,n;$("nav ul li ul li").click(function(){var n=$(this).find("a").attr("href");return n&&(window.location=n),!1}),$(".mobileNav li").click(function(){var n=$(this).find("a").attr("href");return n&&(window.location=n),!1}),$(".navParent").doubleTapToGo(),$(".showSubNav").click(function(n){n.preventDefault(),$(".subMenu").toggle(),window.innerWidth<=550&&$(".subMenu2").toggle()}),$(".js-background-1:has(div#homePage)").css("background","transparent"),$("#headerSection h1").fitText(.8,{minFontSize:"50px",maxFontSize:"100px"}),$("#headerSection.smaller h1").fitText(1,{minFontSize:"50px",maxFontSize:"70px"}),$(".homeMajor section h1").fitText(1,{minFontSize:"50px",maxFontSize:"100px"}),$(".subNav section div h1").fitText(.8),$(".subNav section div .headerMinor").fitText(2.3),t=$(window),i=.6,t.bind("scroll",f),$(".findOutMore").click(function(){$(this).animate({opacity:"0"},500,function(){$(this).animate({height:0},500),$(this).parent().siblings(".hiddenContent").css("opacity",0),$(this).parent().siblings(".hiddenContent").slideDown("slow",function(){$(this).animate({opacity:1},1e3)})})}),n=!1,u(),window.onresize=function(){window.innerWidth<=750&&n?($(".layer2").stop().css({opacity:0}).hide(),$(".homeLayer2").stop().css({opacity:0}).hide(),clearInterval(r),n=!1):u()}}),function(n,t,i){n.fn.doubleTapToGo=function(){return!("ontouchstart"in t)&&!navigator.msMaxTouchPoints&&!navigator.userAgent.toLowerCase().match(/windows phone os 7/i)?!1:(this.each(function(){var t=!1;n(this).on("click",function(i){var r=n(this);r[0]!=t[0]&&(i.preventDefault(),t=r)});n(i).on("click touchstart MSPointerDown",function(i){for(var u=!0,f=n(i.target).parents(),r=0;r<f.length;r++)f[r]==t[0]&&(u=!1);u&&(t=!1)})}),this)}}(jQuery,window,document),function(n){n.fn.fitText=function(t,i){var u=t||1,r=n.extend({minFontSize:Number.NEGATIVE_INFINITY,maxFontSize:Number.POSITIVE_INFINITY},i);return this.each(function(){var t=n(this),i=function(){t.css("font-size",Math.max(Math.min(t.width()/(u*10),parseFloat(r.maxFontSize)),parseFloat(r.minFontSize)))};i();n(window).on("resize.fittext orientationchange.fittext",i)})}}(jQuery)