/*** TAB NAVIGATION ***/
$(function() {
	$('.hTab').each(function () {
		if ($(this).children('.hTabDrop').index() != -1 || $(this).children('.hTabDropR').index() != -1) {
			/*** HAS A DROP DOWN ***/
			$('.hTabDrop').each(function () {
				$(this).parent().hoverIntent({
					over: function () {
						$(this).removeClass("hTab");
						$(this).addClass("hTabOn");
						$(this).children('.hTabDrop').slideDown(100);
					},
					out: function () {
						$(this).removeClass("hTabOn");
						$(this).addClass("hTab");
						$(this).children('.hTabDrop').fadeOut(200);
					}
				});
	
			});	
			/*** HAS A DROP DOWN ***/
			$('.hTabDropR').each(function () {
				$(this).parent().hoverIntent({
					over: function () {
						$(this).removeClass("hTab");
						$(this).addClass("hTabOn");
						$(this).children('.hTabDropR').slideDown(100);
					},
					out: function () {
						$(this).removeClass("hTabOn");
						$(this).addClass("hTab");
						$(this).children('.hTabDropR').fadeOut(200);
					}
				});
	
			});	
		}else{
			/*** DEFAULT HOVER EFFECT ***/
			$(this).eq(0).hover(function () {
				$(this).removeClass("hTab");
				$(this).addClass("hTabOn");
			}, function () {
				$(this).removeClass("hTabOn");
				$(this).addClass("hTab");
			});
		}
	});
});
/** HOME ROTATION **/
$(function() { 
	 if ($('#homeRotNav').length) {
		 $("#homeRotNav").tabs(".homeRotImages > div", { 
		       // enable "cross-fading" effect 
		       effect: 'fade', 
		       fadeOutSpeed: 'slow', 
			   autoplay: true,
		       // start from the beginning after the last tab 
		       rotate: true
		   }).slideshow({
                prev: "#homeRotNavPrev",
                next: "#homeRotNavNext",  
			    autoplay: true,
			    autopause: true,
		        interval: 6000
		   });
	}
});	

/** HOME TABBED FEATURED PRODUCT ZONE **/
$(function() { 
	$("ul.pdTabbedZoneNav").tabs("div.pdTabbedZoneContent > div.pdTabbedZonePane", {tabs:false});
});
/** HOME SCROLLABLE PRODUCT ZONE **/
$(function() { 
	$(".pdScrollable").scrollable({items:'pdItems',next:'.pdNext',prev:'.pdPrev',disabledClass:'disabled',circular:false,easing:'swing'});
});
