$(document).ready(function(){
      $("ul#nav ul").fadeTo("fast", 0.95);

var totalheight = $(window).height();
var pageheight = $("#header").height()+$("#content").height()+14;

if(pageheight<totalheight) {
	$("#content").css("padding-bottom",totalheight-pageheight-34);
}
else {
	$("#content").css("padding-bottom","40px");
	}



	 $("#nav li").mouseover(function(){
      $(this).addClass("sfHover");
    });

	 $("#nav").mouseout(function(){
      $("#nav li").removeClass("sfHover");
    });
	 
	 
	 
});


$(window).resize(function(){
var totalheight = $(window).height();
var pageheight = $("#header").height()+$("#content").height()+14;

if(pageheight<totalheight) {
	$("#content").css("padding-bottom",totalheight-pageheight-34);
}
else {
	$("#content").css("padding-bottom","40px");
	}

});

function showSuccess()
{
    document.getElementById("email_form").style.display = "none";
    document.getElementById("success").style.display = "";
}