$(document).ready(function(){
	// Show services administration details

	$("a.servicesPanel").click(function(){ $("div.product_main").find("ul.show-menu").fadeOut(1000); });
	$("a.servicesPanel").click(function(){ $("div.product_main").find("div.show-services").fadeIn(3000); });
	$("a.servicesPanelReturn").click(function(){ $("div.product_main").find("div.show-services").fadeOut(300); });	
	$("a.servicesPanelReturn").click(function(){ $("div.product_main").find("ul.show-menu").fadeIn(2000); });	

	// Show project management details

	$("a.pmPanel").click(function(){ $("div.product_main").find("ul.show-menu").fadeOut(1000); });
	$("a.pmPanel").click(function(){ $("div.product_main").find("div.show-projectManagement").fadeIn(3000); });
	$("a.pmPanelReturn").click(function(){ $("div.product_main").find("div.show-projectManagement").fadeOut(300); });	
	$("a.pmPanelReturn").click(function(){ $("div.product_main").find("ul.show-menu").fadeIn(2000); });	

	// Show services administration details

	$("a.designPanel").click(function(){ $("div.product_main").find("ul.show-menu").fadeOut(1000); });
	$("a.designPanel").click(function(){ $("div.product_main").find("div.show-design").fadeIn(3000); });
	$("a.designPanelReturn").click(function(){ $("div.product_main").find("div.show-design").fadeOut(300); });	
	$("a.designPanelReturn").click(function(){ $("div.product_main").find("ul.show-menu").fadeIn(2000); });
	
	// Show technical architecture details
	
	$("a.architecturePanel").click(function(){ $("div.product_main").find("ul.show-menu").fadeOut(1000); });
	$("a.architecturePanel").click(function(){ $("div.product_main").find("div.show-architecture").fadeIn(3000); });
	$("a.architecturePanelReturn").click(function(){ $("div.product_main").find("div.show-architecture").fadeOut(300); });	
	$("a.architecturePanelReturn").click(function(){ $("div.product_main").find("ul.show-menu").fadeIn(2000); });	

	// Show ruby on rails development details

	$("a.rubyPanel").click(function(){ $("div.product_main").find("ul.show-menu").fadeOut(1000); });
	$("a.rubyPanel").click(function(){ $("div.product_main").find("div.show-ruby").fadeIn(3000); });
	$("a.rubyPanelReturn").click(function(){ $("div.product_main").find("div.show-ruby").fadeOut(300); });	
	$("a.rubyPanelReturn").click(function(){ $("div.product_main").find("ul.show-menu").fadeIn(2000); });	
	
	// Show javascript details

	$("a.javascriptPanel").click(function(){ $("div.product_main").find("ul.show-menu").fadeOut(1000); });
	$("a.javascriptPanel").click(function(){ $("div.product_main").find("div.show-javascript").fadeIn(3000); });
	$("a.javascriptPanelReturn").click(function(){ $("div.product_main").find("div.show-javascript").fadeOut(300); });	
	$("a.javascriptPanelReturn").click(function(){ $("div.product_main").find("ul.show-menu").fadeIn(2000); });	

	// Show php details

	$("a.phpPanel").click(function(){ $("div.product_main").find("ul.show-menu").fadeOut(1000); });
	$("a.phpPanel").click(function(){ $("div.product_main").find("div.show-php").fadeIn(3000); });
	$("a.phpPanelReturn").click(function(){ $("div.product_main").find("div.show-php").fadeOut(300); });	
	$("a.phpPanelReturn").click(function(){ $("div.product_main").find("ul.show-menu").fadeIn(2000); });	
	
	// Show xhtml, css development details

	$("a.htmlPanel").click(function(){ $("div.product_main").find("ul.show-menu").fadeOut(1000); });
	$("a.htmlPanel").click(function(){ $("div.product_main").find("div.show-html").fadeIn(3000); });
	$("a.htmlPanelReturn").click(function(){ $("div.product_main").find("div.show-html").fadeOut(300); });	
	$("a.htmlPanelReturn").click(function(){ $("div.product_main").find("ul.show-menu").fadeIn(2000); });	
				
});

// Manage the display of projects
function displayPortfolio(portfolio){
	currentPortfolio = ['display-consupo', 'display-mycast', 'display-myticklerfile', 'display-scb', 'display-comperemedia'];	
	// Hide everything, display the requested portfolio
	for (var i = 0; i < currentPortfolio.length; i++) {
		   document.getElementById(currentPortfolio[i]).style.display = 'none'
	};
	document.getElementById(portfolio).style.display = 'block'
}
