function menuOver(index)
{
	for (var i=1; i<=6; i++)
	{
		if (document.getElementById("sub_menu"+i) != null)
		{
			document.getElementById("sub_menu"+i).style.display = "none";
		}
	}
	
	if (document.getElementById("sub_menu"+index) != null)
	{
		document.getElementById("sub_menu"+index).style.display = "block";
	}
}

function menuOut()
{
	//1,2,3:o, 4,5,6:x
	for (var i=1; i<=6; i++)
	{
		if (document.getElementById("sub_menu"+i) != null)
		{
			if (i<4)
				document.getElementById("sub_menu"+i).style.display = "block";
			else
				document.getElementById("sub_menu"+i).style.display = "none";
		}
	}
}



var selected_id;
function inCell(cell){
	if ( cell.id == selected_id ) return;
	
	cell.style.backgroundColor = "#ffffff";
	cell.style.color = "#333333";
}

function outCell(cell){
	if ( cell.id == selected_id ) return;
	
	cell.style.backgroundColor = "#6d0060";
	cell.style.color = "#dba9d5";
}


function load_page()
{
	selected_id = location.search.substring(1);
	
	if ( selected_id.length > 0 )
	{
		document.getElementById(selected_id).bgColor = "#ffffff";
		document.getElementById(selected_id).style.color = "#000000";
		document.getElementById(selected_id).style.fontWeight = "bold";
	}
	
}


/** products_all select  **/
var selected_id;
function inProd(cell){
	if ( cell.id == selected_id ) return;
	
	cell.style.backgroundColor = "#f1f1f1";
	cell.style.color = "#6d0060";
}

function outProd(cell){
	if ( cell.id == selected_id ) return;
	
	cell.style.backgroundColor = "#ffffff";
	cell.style.color = "#868585";
}

/** bracket select  **/
var selected_id;
function inBracket(cell){
	if ( cell.id == selected_id ) return;
	
	cell.style.backgroundColor = "#f1f1f1";
	cell.style.color = "#6d0060";
}

function outBracket(cell){
	if ( cell.id == selected_id ) return;
	
	cell.style.backgroundColor = "#ffffff";
	cell.style.color = "#666666";
}


/** spec select  **/
var selected_id;
function inSpec(cell){
	if ( cell.id == selected_id ) return;
	
	cell.style.backgroundColor = "#f1f1f1";
}

function outSpec(cell){
	if ( cell.id == selected_id ) return;
	
	cell.style.backgroundColor = "#ffffff";
}
