/* Author: Kamaal Aboothalib

*/

$(document).ready(function(){
	$('.thumb-name',this).fadeOut('slow');
	$('.thumb-stripe a').hover(function(){
		$('.thumb-mask-left',this).stop(true,true).animate({'background-position': '170px 0px'});
		$('.thumb-mask-right',this).stop(true,true).animate({'background-position': '-170px 0px'});
		$('.thumb-name',this).stop(true,true).fadeIn('slow');
	},function(){
		$('.thumb-mask-left',this).animate({'background-position': '85px 0px'});
		$('.thumb-mask-right',this).animate({'background-position': '-85px 0px'});
		$('.thumb-name',this).stop(true,true).fadeOut('slow');
		
	});
	
	$('.thumb-stripev a').hover(function(){
		$('.thumb-mask-left',this).stop(true,true).animate({'background-position': '270px 0px'});
		$('.thumb-mask-right',this).stop(true,true).animate({'background-position': '-270px 0px'});
		$('.thumb-name',this).stop(true,true).fadeIn('slow');
	},function(){
		$('.thumb-mask-left',this).animate({'background-position': '135px 0px'});
		$('.thumb-mask-right',this).animate({'background-position': '-135px 0px'});
		$('.thumb-name',this).stop(true,true).fadeOut('slow');
		});
	var thisA = $('.thumb-striper a');
	$(thisA).hover(function(){
		$('.thumb-mask-left',this).stop(true,true).animate({left:'580px'},'slow');
		$('.thumb-mask-right',this).stop(true,true).animate({left:'-290px'},'slow');
		//$('.thumb-name',this).stop(true,true).fadeIn('slow');
	},function(){
		$('.thumb-mask-left',this).stop(true,true).animate({left:'290px'},'slow');
		$('.thumb-mask-right',this).stop(true,true).animate({left:'0px'},'slow');
		//$('.thumb-name',this).stop(true,true).fadeOut('slow');
		
		});
	
	
	
	//Nevo
	$('#slider').nivoSlider({
				effect:'boxRain',
				directionNav:false,
				controlNav:false
	});
	
});

