$(document).ready(function(){
	
	var ww = $(window).width();
	var hh = $(window).height();
	var posx =  (ww - 960) / 2;
	
	var posxpt = posx + 20;
	
	$(".photo-content").css({'height': hh});
	
	
$("#main-box").click(function(){
							   
			$("#pinfo").animate({left: -1600}, 500);
			$("#partists").animate({left: -1600}, 500);
			$("#phistory").animate({left: -1600}, 500);
			$("#pphoto").animate({left: -1600}, 500);
			$("#pvideo").animate({left: -1600}, 500);
			$("#pfreespeech").animate({left: -1600}, 500);
		
			});

	
	$("#binfo").click(function(){

							   
		$("#pinfo").animate({left: posx}, 500);
			$("#partists").animate({left: -1600}, 500);
			$("#phistory").animate({left: -1600}, 500);
			$("#pphoto").animate({left: -1600}, 500);
			$("#pvideo").animate({left: -1600}, 500);
			$("#pfreespeech").animate({left: -1600}, 500);
		
		
			
			
			});
	
		$("#bartists").click(function(){
								 
			//var content = jQuery.get('dj.php', function(data) {
																				 
   			// jQuery('#partists-content').html(data);
			// $('#partists-content').jScrollPane();
				
				//});	
							   
			$("#pinfo").animate({left: -1600}, 500);
		$("#partists").animate({left: posx}, 500);
			$("#phistory").animate({left: -1600}, 500);
			$("#pphoto").animate({left: -1600}, 500);
			$("#pvideo").animate({left: -1600}, 500);
			$("#pfreespeech").animate({left: -1600}, 500);
		
			});
		
		$("#bhistory").click(function(){
									  
		//$('#phistory-content').jScrollPane();
						   
			$("#pinfo").animate({left: -1600}, 500);
			$("#partists").animate({left: -1600}, 500);
		$("#phistory").animate({left: posx}, 500);
			$("#pphoto").animate({left: -1600}, 500);
			$("#pvideo").animate({left: -1600}, 500);
			$("#pfreespeech").animate({left: -1600}, 500);
		
			});
			
		//$("#bphoto").click(function(){
			   
			
		
			//});
				
		$("#bvideo").click(function(){
			
			var content = jQuery.get('video.php', function(data) {
																				 
   			jQuery('#pvideo-content').html(data);
				});	
							   
			$("#pinfo").animate({left: -1600}, 500);
			$("#partists").animate({left: -1600}, 500);
			$("#phistory").animate({left: -1600}, 500);
			$("#pphoto").animate({left: -1600}, 500);
		$("#pvideo").animate({left: posx}, 500);
			$("#pfreespeech").animate({left: -1600}, 500);
		
			});
			
		$("#bfreespeech").click(function(){
										 		   
		    $("#pinfo").animate({left: -1600}, 500);
			$("#partists").animate({left: -1600}, 500);
			$("#phistory").animate({left: -1600}, 500);
			$("#pphoto").animate({left: -1600}, 500);
			$("#pvideo").animate({left: -1600}, 500);
		$("#pfreespeech").animate({left: posx}, 500);
		
			});
	
	
	
	//////////news
	
	//$(".cb-news").click(function(){
								 
		
		//var content = jQuery.get('news.php', {'id': jQuery(this).attr('alt')}, function(data) {
																				 
   			// jQuery('#news-content').html(data);
				
				//});
	//	}); 
	

		
	////////////////////

		$(".video-side-button").click(function(){
								 
		
		var content = jQuery.get('video.php', {'id': jQuery(this).attr('title')}, function(data) {
																				 
   			 jQuery('#pvideo-content').html(data);
			 

				
				});
		});
		
			////////////////////
			

		
			////////////////////


		$("#partists-viewer").click(function(){
			 $("#partists-viewer").animate({left: -1600}, 500);	
		});

	
		////////////////////


		$(".photo-box").click(function(){
									   
			var data = '<div class="photo-viewer-box"><img src="images/photo/' + jQuery(this).attr('title') + '.jpg" /></div>';
			
								 
			 $("#pphoto-viewer").html(data);
			 $("#pphoto-viewer").css({'visibility': 'visible'});

		});
		
		$("#pphoto-viewer").click(function(){
								 
			 
			 $("#pphoto-viewer").css({'visibility': 'hidden'});
 
		});
				
		$(".photo-side-button").click(function(){

		  $(".photo-tab").css({'visibility': 'hidden'});
		  
		  var st = '#photo-tab' + jQuery(this).attr('title');
		  
		  $(st).css({'visibility': 'visible'});	
		  
		}); 
		
		
		$("#fs-sendbutton").click(function(){
			
			var fs_name = $("#fs_name").val();
			var fs_email = $("#fs_email").val();
			var fs_tel = $("#fs_tel").val();
			var fs_msg = $("#fs_msg").val();
			
		
		 var content = jQuery.get('freespeech.php', {'fs_name': fs_name, 'fs_email': fs_email, 'fs_tel': fs_tel, 'fs_msg': fs_msg}, function(data) {
																								 
   			 jQuery('#freespeech-side').html(data);

				});
		});
		

		
});