$(document).ready(function(){
	var isRunning;
	$('.pics').cycle({ 
		fx:      'cover', 
		speed:    1500, 
		timeout:  6000
	});
	$('.photos').cycle({ 
		fx:      'cover', 
		speed:    2500, 
		timeout:  6000
	});
	$('a').click(function() {
		this.blur();
	});
	$('#content .title').animate({width: "488px"}, 1500 );
	$('#long .title').animate({width: "805px"}, 1500 );
	$('#leftSide a:not(.sel)').hover(function(){
		$(this).children().stop().animate({width: "34px"}, 500 );
	}, function() {
		$(this).children().stop().animate({width: "5px"}, 500 );
	});
	$('#portfolioMenu a:not(.sel)').hover(function(){
		$(this).children().stop().animate({width: "30px"}, 500 );
	}, function() {
		$(this).children().stop().animate({width: "5px"}, 500 );
	});
	
	$("#thumbnails a").click(function(e) {
		if(!isRunning){
			isRunning = true;
			$(".hide").hide();
			var id =  $(this).attr("rel");
			$("#thumbnails img").css("border","2px solid #fff");
			$("#thumb"+id+" img").css("border","2px solid #cd4104");
			$("#portfolio"+id).fadeIn(1200, function(){ isRunning = false; });
		}
		e.preventDefault();
    });
    
    $('.anythingSlider').anythingSlider({
        easing: "swing",
        autoPlay: false,
        animationTime: 900,
        hashTags: false,
        buildNavigation: true,
        navigationFormatter: null
	});

});