$(function(){
	$("p.subnav").parent().find("a").hover(function() {
			var liObj = $(this).parent();
			liObj.find("p.subnav").show(); //Drop down the subnav on click  
	
			liObj.hover(
				function() {}, 
				function(){  
					$(this).parent().find("p.subnav").hide(); //When the mouse hovers out of the subnav, move it back up  
				}
			);  
		},
		function(){}
	)
	
	
	$('a[rel=new-window]').click(function(){
		window.open(this.href);
		return false;
	});
	
	$('#overlay-popup-bg').click(function(e){
		e.preventDefault();
		
		$('#overlay-popup-bg').remove();
		$('#cover-page').remove();
	});
	$('#cover-page .close-popup a').click(function(e){
		e.preventDefault();
		$('#overlay-popup-bg').remove();
		$('#cover-page').remove();
	});
});
