$(document).ready(function() 
{
	
	$('.social').css({'opacity': .5});
	
	$('.social').hover(
		function() { $(this).animate({'opacity': 1}, 250)},
		function() { $(this).animate({'opacity': .5}, 100)}
	)
	
	$('#nav_taylormade_color').css('opacity', 0);
	$('#nav_ashworth_color').css('opacity', 0);
	
	$('#nav_taylormade').hover(function() {
		$('#nav_ashworth_color').animate({'opacity': 0}, 100);
		$('#nav_taylormade_color').animate({'opacity': 1}, 250);
	}, function() {
		$('#nav_ashworth_color').animate({'opacity': 0}, 100);
		$('#nav_taylormade_color').animate({'opacity': 0}, 100);
	})
	
	$('#nav_ashworth').hover(function() {
		$('#nav_ashworth_color').animate({'opacity': 1}, 250);
		$('#nav_taylormade_color').animate({'opacity': 0}, 100);
	}, function() {
		$('#nav_ashworth_color').animate({'opacity': 0}, 100);
		$('#nav_taylormade_color').animate({'opacity': 0}, 100);
	})
	
	$('#search_field').focus(function() { $(this).attr({value: ''}); })
	$('#newsletter_signup').focus(function() { $(this).attr({value: ''}); })


	drops('ad_mens');
	drops('ad_womens');
	drops('ad_youth');
	drops('ad_footwear');
	drops('ad_collections');
	drops('ad_sale');
	drops('ad_outlet');
	
	$('#navigation_adidas li ul li:even').css('background-color', '#bf3700');
	$('#navigation_adidas li ul li:odd').css('background-color', '#ce3c00');
	
	$('.switch_color:even').css('background-color', '#FFFFFF');
	$('.switch_color:odd').css('background-color', '#FFFFFF');
	
	$('#signup_btn').css('display', 'none');
	$('#signup_btn_dis').css('display', 'block');
// END
});

function drops(s_class) {
	$('li.' + s_class).hover(
		function() { $('ul', this).css('display', 'block'); },
		function() { $('ul', this).css('display', 'none'); }
	);
}

function swap_color(id, img_name) {
	$('.image_swap_'+ id).children('a').children('img').attr({'src' : 'assets/images/' + img_name});
}

function w_popup(url) {
	window.open (url, "window","location=0,status=0,scrollbars=1,resizable=1,width=1000");
}



// ADDED FOR IMAGE ROTATOR.