/* home page history */
function showHistory(ID){
	$("div.historySnapshot").show();
	$("div.historyDetail").hide();
	$(this).css({backgroundPosition: "0px -10px"});
	$("div.historySnapshot").find("div.content" + ID).show();
}

function hideHistory(){
	$("div.historySnapshot").hide();
	$(this).css({backgroundPosition: "0px 0px"});
}

function resetMarket(ID){
	$("ul.marketDetailsList").hide();
	$("ul#market" + ID).show();
	$("div.mapDetailOverlay").hide();
	$("div#overlay" + ID).show();
	$("div#marketLinks ul li a").removeClass("selectedMarket");
}

$(document).ready(function(){
	
	$("div#marketLinks ul li a").click(function(){
		$(this).addClass("selectedMarket");
	});
	
	/* continue reading content link */
	$("a#continueReading").click(function(){
		$(this).fadeOut(500);
		$("div.defaultContent").animate({marginTop: "-458px"}, 800);
		$("div.contentContinued").fadeIn(800);
		return false;
	});
	/* return to first screen of content */
	$("a.previousPage").click(function(){
		$("div.defaultContent").animate({marginTop: "0px"}, 800);
		$("div.contentContinued").fadeOut(500);
		$("a#continueReading").fadeIn(800);
		return false;
	});
	
	$("a#submitButton").click(function(){
		
	});	

});