$(document).ready(function() {
	$('#b-service .servicenav a').click(function(){
		if(!$(this).parent().hasClass('active')){
			$('#b-service .servicenav li.active').removeClass('active');
			$(this).parent().addClass('active');
            if(this.blur) this.blur(); // FireFox Fix
			$('#b-service div.servicewrap').scrollTo('li'+$(this).attr('href'), 1000);
		}
		return false;
	});
    $('#b-event .servicenav a').click(function(){
		if(!$(this).parent().hasClass('active')){
			$('#b-event .servicenav li.active').removeClass('active');
			$(this).parent().addClass('active');
            if(this.blur) this.blur(); // FireFox Fix
			$('#b-event div.servicewrap').scrollTo('li'+$(this).attr('href'), 1000);
		}
		return false;
	});
    
    $('.newsinner-wrap').serialScroll({
		//target:'',
		items:'li', // Selector to the items ( relative to the matched elements, '#sections' in this case )
		next:'span.newsrefresh',// Selector to the 'prev' button (absolute!, meaning it's relative to the document)
		axis:'y',
		duration:700,// Length of the animation (if you scroll 2 axes and use queue, then each axis take half this time)
		force:true
    });
    //$('.menu1').css('margin-right', '50%');

    //$('#top').scrollTo('div.menu3', 1000, {axis:'x'});
});
