$(document).ready(function(){
	var leftMenu = {
		"about" : "/images/aboutus_menu.png",
		"studio" : "/images/studio_menu.png",
		"gallery" : "/images/gallery_menu.png",
		"community" : "/images/community_menu.png",
		"product" : "/images/product_menu.png",
		"service" : "/images/service_menu.png"
	};
	var leftMenuOn = {
		"about" : "/images/aboutus_menu_on.png",
		"studio" : "/images/studio_menu_on.png",
		"gallery" : "/images/gallery_menu_on.png",
		"community" : "/images/community_menu_on.png",
		"product" : "/images/product_menu_on.png",
		"service" : "/images/service_menu_on.png"
	};
	$('.acc_container').hide(); //Hide/close all containers
	//$('.acc_trigger:first').addClass('active').next().show(); //Add "active" class to first trigger, then show/open the immediate next container

	$('.acc_trigger').mouseover(function() {
		//menuImg = $(this).find("img");
		//oldMenu = $(this).find("img").attr('src');
		var newMenuId = $(this).attr("id");
		$(this).find("img").attr("src", leftMenuOn[$(this).attr("id")]);
	}).mouseout(function() {
		var newMenuId = $(this).attr("id");
		//alert(leftMenu.about);
		$(this).find("img").attr("src", leftMenu[$(this).attr("id")]);
	});
	$('.acc_trigger').click(function(){
		if( $(this).next().is(':hidden') ) { //If immediate next container is closed...
			$('.acc_trigger').removeClass('active').next().slideUp(); //Remove all .acc_trigger classes and slide up the immediate next container
			$(this).toggleClass('active').next().slideDown(); //Add .acc_trigger class to clicked trigger and slide down the immediate next container
		}
		return false; //Prevent the browser jump to the link anchor
	});

});
