
//var categoryID = "keralade";

$(document).ready(function(){
	$("#slide").css("visibility","visible");					
	// Menu
	if($("#slide")) {
		
		$("#slide dd").hide();
		
		/// Highlight current Navigation
		
		
		//$("#"+categoryID).css({'opacity': '.3'});
		//$("#"+categoryID).before('<b>');
		//$("#"+categoryID).after('</b>');
		//$("#"+categoryID).wrapInner(document.createElement("strong"));
		
		$("#"+categoryID).parents("dd").prev().children("b").addClass("clicked");
		
		$("#"+categoryID).css({'font-weight': 'bold'});
		$("#"+categoryID).css("color","#8080C0");
		
		//font-weight:bold;
				
		//Show Sub-Navigation Container
		$("#"+categoryID).parents("dd").show();
		$("#"+categoryID).parent().next().show();
		
		// Highlight current Sub-Navigation
		$("#"+categoryID).addClass("clicked");	
		
		
		
		$("#slide dt b").click(function() {
			if(this.className.indexOf("clicked") != -1) {
				$(this).parent().next().slideUp(200);
				$(this).removeClass("clicked");
			}
			else {
				$("#slide dt b").removeClass();
				$(this).addClass("clicked");		
				$("#slide dd:visible").slideUp(200);
				$(this).parent().next().slideDown(500);
			}
			return false;
		});
		
		var itemClicked = categoryID;
		
		
		$("#slide a").click(function() {
			
			itemClicked = $(this).attr("id");
			$("#slide a").each(function(){
				$(this).css("color","#fff");
				$(this).css({'font-weight': 'normal'});
			});
			
			$(this).css("color","#8080C0");
			$(this).css({'font-weight': 'bold'});
		});
		
		$("#slide a").mouseover(function() {
			
			/*$("#slide a").each(function(){
				$(this).css("color","#fff");
				$(this).css({'font-weight': 'normal'});
			});*/
			//alert($(this).attr("id"));
			$(this).css("color","#8080C0");
			$(this).css({'font-weight': 'bold'});
		});
		
		$("#slide a").mouseout(function() {
			if(itemClicked != $(this).attr("id") || typeof $(this).attr("id") == "undefined"){
				$(this).css("color","#fff");
				$(this).css({'font-weight': 'normal'});
				
			}
			
			
		});
		
		
		
		
		
		//$(".open").css({'display': 'block'});
		$("#open").css({'display': 'block'});
		
		//$(".openArrow").parent().addClass("clicked");
		//$("#openArrow").parent().addClass("clicked");
		//$("#openArrow").css({'background': 'url(http://kerala.de/kerala_de/css/navigation/down_last.png) no-repeat scroll 13px 50% transparent'});
		
		
		
		//$(".openArrow").css({'background': 'url(http://kerala.de/kerala_de/css/navigation/out_neu__alternativeWithSub.png) no-repeat scroll 13px 50% transparent'});
		//$("#openArrow").css({'background': 'url(http://kerala.de/kerala_de/css/navigation/last_out_alternativeWithSub.png) no-repeat scroll 13px 50% transparent'});
		
		
	}
	

});

