
/* Mista.Boos Creative 2010-2011 */

/******************* ONLOAD : LAVALAMP MENU, FADE LOGO, FADE LINKS, SUBMIT BUTTON, BEAUTYTIPS MENU *******************/
$(function onload()
{	
	// Lavalamp Menu
	$("#menu").lavaLamp(
	{
		fx: "backout",
		speed: 500,
		/*click: function(event, menuItem)
		{
			return false;
		}*/
	});
	
	// Fade Logo
	$("#logo span").hover(
		function()
		{
			$(this).stop().animate({"opacity": "0"}, 400);
		},
		function()
		{
			$(this).stop().animate({"opacity": "1"}, 400);
		});
	
	// Fade Links
	var originalColor = $(".links").css("color"); 
	var fadeColor = "#d10b4c"; 
	
	$(".links").hover( 
		function()
		{ 
			$(this).stop().animate({color:fadeColor}, 400)
		}, 
		function()
		{
			$(this).stop().animate({color:originalColor}, 400)
		}
	);
	
	// Submit Button
	var originalColorSubmit = $("#submit-button").css("color");
	
	$("#submit-button").hover( 
		function()
		{ 
			$(this).stop().animate({color:fadeColor}, 400)
		}, 
		function()
		{
			$(this).stop().animate({color:originalColorSubmit}, 400)
		}
	);
	
	// BeautyTips Menu
	$(function()
	{
		$('nav a[href]').bt(
		{
		  showTip: function(box){
			$(box).fadeIn(300);
		  },
		  hideTip: function(box, callback){
			$(box).animate({opacity: 0}, 300, callback);
		  },
			titleSelector: "attr('href')",
			fill: 'rgba(0, 0, 0, .3)',
			cssStyles: {textTransform:'none', fontSize:'0.7em', textAlign:'center', /*backgroundImage:'url(../img/background-trans-white.png)', backgroundRepeat:'repeat'*/},
			width: 110,
			padding: 7,
			cornerRadius: 0,
			animate: true,
			strokeWidth: 0,
			spikeLength: 15,
			spikeGirth: 12,
			positions: ['top'],
		});
	});
	
	// Scroll To Top
	$().UItoTop({ easingType: 'easeOutQuart' });
	
	// "In progress" links desactivated
	$(".noclick").click( function(){ return false; } );
});
