$(document).ready(function(){ 
	
		//Set custom configurations for top navigation megaHover
		var config = {
			 sensitivity: 2, // number = sensitivity threshold (must be 1 or higher)
			 interval: 1, // number = milliseconds for onMouseOver polling interval
			 over: megaHoverOver, // function = onMouseOver callback (REQUIRED)
			 timeout: 1, // number = milliseconds delay before onMouseOut
			 out: megaHoverOut // function = onMouseOut callback (REQUIRED)
		};
		
		$("ul#topnav li .sub").css({'opacity':'0'}); //Fade sub nav to 0 opacity on default
		$("ul#topnav li").hoverIntent(config); //Trigger Hover intent with custom configurations	
		
		// homepage cycle slideshow configurations
	    $('#cycle-slideshow').cycle({
			fx:     'fade',
			speed:  '1000',
			timeout: 3000,
			pager:  '#cycle-nav',
			slideExpr: 'img',
			pause: 1
		});
		
		
		// rollover thumbnail popup. eg. natural stone section
		$("ul.thumb li").hoverIntent(function() {
			   $(this).css({'z-index' : '20'}); /*Add a higher z-index value so this image stays on top*/ 
			   $(this).find('img').addClass("hover").stop() /* Add class of "hover", then stop animation queue buildup*/
				.animate({
				 marginTop: '-150px', /* The next 4 lines will vertically align this image */ 
				 marginLeft: '0',
				 width: '250px', /* Set new width */
				 height: '250px' /* Set new height */
				}, 150); /* this value of "200" is the speed of how fast/slow this hover animates */
			  
			   } , function() {
			   $(this).css({'z-index' : '0'}); /* Set z-index back to 0 */
			   $(this).find('img').removeClass("hover").stop()  /* Remove the "hover" class , then stop animation queue buildup*/
				.animate({
				 marginTop: '0', /* Set alignment back to default */
				 marginLeft: '0',
				 width: '100px', /* Set width back to default */
				 height: '100px' /* Set height back to default */
				}, 200);
		   });
		
		// jQuery UI Tabs call 
		$('#rotate').tabs({fxFade: true, fxSpeed: 'fast'});

		$('ul#reviews-quotes').quote_rotator({rotation_speed: 6000});
	
		$("ul#ticker01").liScroll(); 

});
