$(document).ready(function() {
	$('#hide > ol.spip ul.subrub').hide();  
	$('a.cur').next('ul.subrub').show();
	$('#hide li a.mainrub').click(function() {
		var $themeon = $(this);
		var $siblingRubs = $themeon.parent('li').siblings().children('a.mainrub');
		var $visibleSubmenus = $themeon.parent('li').siblings().children('ul:visible');		
		var $isVisibleList = $themeon.next('ul:visible');
		if($visibleSubmenus.length) {
			$siblingRubs.removeClass("cur");
			$visibleSubmenus.slideUp('fast', function() {
				$themeon.next('ul').slideToggle('fast');
				$themeon.addClass("cur");
			});
		} else {
			$siblingRubs.removeClass("cur");
			if($isVisibleList.length) {
				$themeon.next('ul').slideToggle();
				$themeon.removeClass("cur");
			} else {
				$themeon.next('ul').slideToggle();
				$themeon.addClass("cur");
			}
		}
		return false;
	});
});

$(document).ready(function(){

   $(".nav-sub li a:hover").hover(
   function(over) {
     $(this).animate({borderWidth: "2px"},  
"slow");
   },
   function(out) {
     $(this).animate({borderWidth: "1px"},   
"slow");
   });

}); 
