// JavaScript Document
$(function() {
	$(".lavaLamp").lavaLamp({
		fx: "backout",
		speed: 700,
		click: function(event, menuItem) {
			return true;
		}
	});

	$("#innerNavigation ul li").hover(function() {
		if($(this).attr('class') != 'current') {
			$(this).animate({backgroundPosition:'202px 4px'},"fast");
		} else {
			$(this).animate({backgroundPosition:'196px 4px'},"fast");
			$(this).animate({backgroundPosition:'202px 4px'},"fast");
		}
	}, function() {
		if($(this).attr('class') != 'current') {
			$(this).animate({backgroundPosition:'220px 4px'},"fast");
		} else {
			$(this).animate({backgroundPosition:'208px 4px'},"fast");
			$(this).animate({backgroundPosition:'202px 4px'},"fast");
		}
	});

	$("h2.newsHeader").click(function() {
		$(this).next(".newsArticle").slideToggle();
		if($(this).css("backgroundImage").indexOf("-down.png") != -1) {
			$(this).css({backgroundImage: "url(/images/arrow.png)"});
			$(this).css({backgroundPosition: "0px 2px"});
		} else {
			$(this).css({backgroundImage: "url(/images/arrow-down.png)"});
			$(this).css({backgroundPosition: "0px 5px"});
		}
	});
});

swfobject.registerObject("headerLogo", "9.0.0");
