// JavaScript Document
$(document).ready(function () {
	$("#mainPost").hide();
	$(".sidebar").hide();
	$("#footer").hide();
	contentAppear();
	
	$("#submenu a").hover(
						   
						   function (){
									
								$(this).animate({ 
												
												opacity: 1,
												paddingLeft:"40px"
											  }, "slow" );
						
							},
							function (){
									
								$(this).animate({ 
												
												opacity: 0.5,
												paddingLeft:"20px"
											  }, "slow" );
						
							}
							
							);

});

function contentAppear(){
	$("#mainPost").fadeIn("slow", function(){
												 
												 $(".sidebar").fadeIn("slow", function (){
																						 
																						  $("#footer").fadeIn("slow");
																						 
																						 
																						 });
												 
												 
												 });
}

function defineCssColor(theColor){
	//alert(">"+theColor);
	var theStyle ="<style>";
		theStyle +="#content a, .sidebar a { color:#"+theColor+";}";
		theStyle +=".sidebar #submenu ul .item a{ background-color: #"+theColor+";}";
		theStyle +="#content a:hover, .sidebar a:hover {color:#FFF;}";
		theStyle +="</style>";
	$("#styleManager").html(theStyle);
}