// JavaScript Document

(function($){
	
    $(document).ready(function() {		
		$('#slides').cycle({
			fx: 'fade',
			speed: 'slow',
			timeout: 10000,
			containerResize: 0,
			cleartype: true,
			cleartypeNoBg: true,
			pager: '#carousel ul',
			pagerAnchorBuilder: function(idx, slide) { 
				return '#carousel ul li:eq(' + idx + ') a'; 
			} 
		}); 
        $('#carousel ul:first').children().hover(
    		function(){$(this).addClass('hover');},
    		function(){$(this).removeClass('hover');}
    	);
		
		$('#carousel ul li').css('padding-left', function(){
			var liCount = $('#carousel ul li').length;
			var width = 754;
			width -= (liCount * 62);
			liCount += 1;
			return width/liCount;
		});
    });
})(jQuery);
