$(document).ready(function(){
	
	$(".thumbI").css({opacity: ".1", filter: "alpha(opacity = 10)"});
	$(".thumbBox").hover(function(){
		$(this).find("img").fadeTo("fast", 1);
		$(this).css({cursor: "pointer"});
		$(".captionBox").animate({opacity: ".1",  filter: "alpha(opacity = 10)"},{queue:false,duration:400}); //hide afterhover
		$(".cover", this).stop().animate({left:"-180px"},{queue:false,duration:400}); //position of hover
	}, function() {
		$(this).find("img").fadeTo("slow", .1);
		$(this).css({cursor: "pointer"});
		$(".captionBox").animate({opacity: "1", filter: "alpha(opacity = 100)"},{queue:false,duration:400}); //hide afterhover
		$(".cover", this).stop().animate({left:"0px", opacity: "1", filter: "alpha(opacity=100)"},{queue:false,duration:400}); //hide afterhover
	});
	
	$(".thumbBox, .sitemap li").click(function(){
		$("#header, #thirdNav, #footer, #archive").animate({
			marginLeft: "-3000px",
			opacity: "0",
			filter: "alpha(opacity = 0)"
		}, 800); 
	});
	
	$(".thumbBox").click(function(){
		window.location = $(this).find("a").attr("href");
		return false;
	}); //open new page after click nav
});