$(document).ready(function(){  
	$(".box a").hover(
		function() { $(this).closest("div.box").addClass("over"); },
		function() { $(this).closest("div.box").removeClass("over");}
	); 
	$("#mainMenu>ul>li").hover(
		function() { $(this).find(".sottomenu").html() != null ? $(this).closest("li").addClass("over") : "" },
		function() { $(this).closest("li").removeClass("over");} 
	);
	$('#footer p a, a.lb').colorbox({width:"600px", height:"500px", iframe:true });
	$('.nGallery a').colorbox();
	//$('.news .immagine img').colorbox();	
	
	
	
	
	
	
	
	
	
});

function checkHtml5Avi() {
	var html5Avi = false;
	if(
		(navigator.userAgent.match(/iPhone/i)) || 
		(navigator.userAgent.match(/iPod/i)) || 
		(navigator.userAgent.match(/iPad/i))  || 
		(navigator.userAgent.match(/Safari/i))) {
			html5Avi=true;
	}
	return html5Avi;
}

