﻿/***************************/
//@Author: Adrian "yEnS" Mato Gondelle & Ivan Guardado Castro
//@website: www.yensdesign.com
//@email: yensamg@gmail.com
//@license: Feel free to use it, but keep this credits please!					
/***************************/

jQuery(document).ready(function(){
	jQuery(".tab-menu > li").click(function(e){
		switch(e.target.id){
			case "highlights":
				//change status & style menu
				jQuery("#colors").removeClass("active");
				jQuery("#pricing").removeClass("active");
				jQuery("#highlights").addClass("active");
				jQuery("#details").removeClass("active");
				//display selected division, hide others
				jQuery("div.highlights").fadeIn();
				jQuery("div.colors").css("display", "none");
				jQuery("div.pricing").css("display", "none");
				jQuery("div.details").css("display", "none");
			break;
			case "pricing":
				//change status & style menu
				jQuery("#colors").removeClass("active");
				jQuery("#pricing").addClass("active");
				jQuery("#highlights").removeClass("active");
				jQuery("#details").removeClass("active");
				//display selected division, hide others
				jQuery("div.pricing").fadeIn();
				jQuery("div.colors").css("display", "none");
				jQuery("div.highlights").css("display", "none");
				jQuery("div.details").css("display", "none");
			break;
			case "colors":
				//change status & style menu
				jQuery("#colors").addClass("active");
				jQuery("#pricing").removeClass("active");
				jQuery("#highlights").removeClass("active");
				jQuery("#details").removeClass("active");
				//display selected division, hide others
				jQuery("div.colors").fadeIn();
				jQuery("div.pricing").css("display", "none");
				jQuery("div.highlights").css("display", "none");
				jQuery("div.details").css("display", "none");
			break;
			case "details":
				//change status & style menu
				jQuery("#colors").removeClass("active");
				jQuery("#pricing").removeClass("active");
				jQuery("#highlights").removeClass("active");
				jQuery("#details").addClass("active");
				//display selected division, hide others
				jQuery("div.details").fadeIn();
				jQuery("div.colors").css("display", "none");
				jQuery("div.pricing").css("display", "none");
				jQuery("div.highlights").css("display", "none");
			break;
		}
		//alert(e.target.id);
		return false;
	});
});
