/*-----------------------------------------------------------------------
Featured Clients
------------------------------------------------------------------------*/

$(function() {
	
	$('#feature-clients').cycle({ 
		fx: 'scrollUp',
    timeout: 0,
		//pause: true,
		next: '#fn-next a',
		prev: '#fn-prev a',
    speed:   1100,
    startingSlide: 6
    });
	
});

/*-----------------------------------------------------------------------
Showcase Clients
------------------------------------------------------------------------*/

$(function() {		   
						   
	$.fn.cycle.updateActivePagerLink = function(pager, currSlideIndex) { 
     
	$(pager).find('a').removeClass('active') 
        .filter('a:eq('+currSlideIndex+')').addClass('active'); 
    }; 
	
	$('#showcase-clients').cycle({ 
		fx: 'scrollUp',
    timeout: 0,
		pause: true,
		next: '#pn-next a',
		prev: '#pn-prev a',
		height: '367px',
		pager: '#pager-numbers',
    speed:   1100,
    startingSlide: 0
    });
	
    $('#pn-one a').click(function() {$('#showcase-clients').cycle(0); return false;});	
    $('#pn-two a').click(function() {$('#showcase-clients').cycle(1); return false;});
	  $('#pn-three a').click(function() {$('#showcase-clients').cycle(2); return false;});
	  $('#pn-four a').click(function() {$('#showcase-clients').cycle(3); return false;});
	$('#pn-five a').click(function() {$('#showcase-clients').cycle(4); return false;});
	$('#pn-six a').click(function() {$('#showcase-clients').cycle(5); return false;});
	$('#pn-seven a').click(function() {$('#showcase-clients').cycle(6); return false;});
	$('#pn-eight a').click(function() {$('#showcase-clients').cycle(7); return false;});	
    $('#pn-nine a').click(function() {$('#showcase-clients').cycle(8); return false;});
    $('#pn-ten a').click(function() {$('#showcase-clients').cycle(9); return false;});
	
});

/*-----------------------------------------------------------------------
Selected Client
------------------------------------------------------------------------*/

$(function() {		   
						   
	$.fn.cycle.updateActivePagerLink = function(pager, currSlideIndex) { 
     
	$(pager).find('a').removeClass('active') 
        .filter('a:eq('+currSlideIndex+')').addClass('active'); 
    }; 
	
	$('#featured-client').cycle({ 
		fx: 'scrollUp',
        timeout: 0,
		pause: true,
		next: '#pn-next a',
		prev: '#pn-prev a',
		height: '468px',
		pager: '#pager-numbers',
        speed:   1100,
        startingSlide: 0
    });
	
    $('#pn-one a').click(function() {$('#featured-client').cycle(0); return false;});	
    $('#pn-two a').click(function() {$('#featured-client').cycle(1); return false;});
    $('#pn-three a').click(function() {$('#featured-client').cycle(2); return false;});	
    $('#pn-four a').click(function() {$('#featured-client').cycle(3); return false;});
    $('#pn-five a').click(function() {$('#featured-client').cycle(4); return false;});	
    $('#pn-six a').click(function() {$('#featured-client').cycle(5); return false;});
    $('#pn-seven a').click(function() {$('#featured-client').cycle(6); return false;});	
    $('#pn-eight a').click(function() {$('#featured-client').cycle(7); return false;});
    $('#pn-nine a').click(function() {$('#featured-client').cycle(8); return false;});	
    $('#pn-ten a').click(function() {$('#featured-client').cycle(9); return false;});
	
});

/*-----------------------------------------------------------------------
Tabbing System
------------------------------------------------------------------------*/

$(function() {

	$(".tab li a").click(function () {
	 
	 $(".tab li a.active").removeClass("active");
	 $(this).addClass("active");
	 
	 $("#content-wrapper div").hide();
	 
	 var content_show = $(this).attr("rel");
	 $("#"+content_show).show();
	 
	 return false;
	 	 	  
	});	

});