jQuery(document).ready(function($) {
								
	    $("form").addClass("inlabel-form"); //Add an extra class to any form with a class of inlabel-form
	
		$("form .data").each(
			function(){
				if($(this).val() !== ""){
					$(this).parent().find("strong").fadeTo("fast",0);
				}
			}
		);
	
	
		$("form .data").focus(
			function(){
				if($(this).val() === ""){
					$(this).parent().find("strong").fadeTo("fast",0.45);
				}
			}
		);
	
		$("form .data").keyup(
			function(event){
				if($(this).val() !== ""){
					$(this).parent().find("strong").fadeTo("fast",0);
				}else{
					$(this).parent().find("strong").fadeTo("fast",0.45);
				}
			}
		);
		
		$("form .data").click(
			function(event){
				if($(this).val() !== ""){
					$(this).parent().find("strong").fadeTo("fast",0);
				}
			}
		);
	
		$("form .data").blur(
			function(){
				if($(this).val() === ""){
					$(this).parent().find("strong").fadeTo("fast",1);
				}
			}
		);
		
		
		$("#slider").easySlider({
			auto: false, 
			continuous: true
		});
		
		//form-validators
		$("#contact-form").validate();
		$("#subscribe-email").validate();
		
		
		// fix layout if fail to load
		$(".group-3 div:nth-child(3n+1)").addClass("first");
   		$(".group-4 div:nth-child(4n+1)").addClass("first");
		
		
		$('.more-deals').hover(
			function(){
				$("div.description",this).stop(true,true).animate({"top": 50+"px"}, 200);
				},
			function(){
				$("div.description",this).stop(true,true).animate({"top": 320+"px"}, 200);
				//$("span.description",this).stop(true,true).animate({"top": 320+"px"}, 50);
				}
		);
   
		
});
