

$(function(){
	
	/*--------------------------------------------------------------------------------------- TOP SLIDER */
	var speed = 1000,
		fast = speed/2,
		topSlider = $('.slider-top'),
		topSliderMenu = topSlider.find('.slider-menu a'),
		topSliderCurrent = topSliderFirst = topSliderMenu.filter(':first');
		counter = 0,
		topSliderOver = false;
		
	topSliderMenu.each(function(){
		this.rel = ++counter;
	});
	topSliderCurrent.addClass('current');
		
	topSlider.jcarousel({
		scroll:1,
		animation:speed,
		easing:'easeInOutCubic',
		initCallback:function(c){
			topSliderMenu.click(function(e){
				c.scroll($.jcarousel.intval(this.rel));
				topSliderMenu.removeClass('current');
				topSliderCurrent = $(this);
				topSliderCurrent.addClass('current');
				e.preventDefault();
			});
			if($.browser.msie){
				topSlider.find('li:first').hide().show(1);
			}
		},
		buttonPrevHTML:null,
		buttonNextHTML:null
	}).hover(function(){ topSliderOver = true; }, function(){ topSliderOver = false; });
	
	setInterval(function(){
		if(topSliderOver===false){
			var next = topSliderCurrent.next();
			if(next.length==0) next = topSliderFirst;
			next.click();
		}
	},5000);
	
	/*------------------------------------------------------------------------------------ BOTTOM SLIDER */
	var bottomSlider = $('.slider-bottom');
	bottomSlider.jcarousel({
		scroll:1,
		animation:fast,
		easing:'swing'
	});

});


