$(document).ready(function(event) {
	$("#content h3.heading").css({opacity:0,marginLeft:120});
	$("#header li.product a").filter(":not(.selected)").css({paddingTop:0, opacity:0}).removeClass("clickable");
	$("#header li.service a").filter(":not(.selected)").css({paddingTop:30, opacity:0}).removeClass("clickable");
	
	$(".logo").click(function(event) {
		window.location = "index.html";
	});
	
	$(".expandinglist.categories > li > ul").hide();
	$(".expandinglist.courses ul, .expandinglist.courses p").hide();
	$(".expandinglist.categories h4").click(function(eventData) {
		if ($(this).parent().hasClass("expanded")) {
			$(this).parent().find("ul.expandinglist").slideUp("slow");
			$(this).parent().removeClass("expanded");
		} else {
			$(this).parent().find("ul.expandinglist").slideDown("slow");
			$(this).parent().addClass("expanded");
		}
	});
	
	$(".expandinglist.categories h5").click(function(eventData) {
		if ($(this).parent().hasClass("expanded")) {
			$(this).parent().find("ul, p").slideUp("slow");
			$(this).parent().removeClass("expanded");
		} else {
			$(this).parent().find("ul, p").slideDown("slow");
			$(this).parent().addClass("expanded");
		}
	});
});

$(window).load(function() {
	$("#content h3.heading").animate({opacity:1,marginLeft:15},3000);				
	$("#header li.product a").animate({paddingTop:30, opacity:1},2000).addClass("clickable");
	$("#header li.service a").animate({paddingTop:1, opacity:1},2000).addClass("clickable");
});