/*Slider*/

$(function(){
	$('#slides').slides({
		preload: true,
		preloadImage: 'img/loading.gif',
		play: 5000,
		pause: 2500,
		hoverPause: true,
		animationStart: function(current){
			$('.caption').animate({
				bottom:-35
			},100);
			if (window.console && console.log) {
				// example return of current slide number
				console.log('animationStart on slide: ', current);
			};
		},
		animationComplete: function(current){
			$('.caption').animate({
				bottom:0
			},200);
			if (window.console && console.log) {
				// example return of current slide number
				console.log('animationComplete on slide: ', current);
			};
		},
		slidesLoaded: function() {
			$('.caption').animate({
				bottom:0
			},200);
		}
	});
});

//trocar texto 
$(document).ready(function(){
	$("#submit").val('Deixe seu comentário');
	$("#respond h3").text('Comentários');
});



//hover imagem
$(document).ready(function(){
	//To switch directions up/down and left/right just place a "-" in front of the top/left attribute
	
	//Caption Sliding (Partially Hidden to Visible)
	$('.boxgrid.caption').hover(function(){
		$(".cover", this).stop().animate({top:'20px'},{queue:false,duration:190});
	}, function() {
		$(".cover", this).stop().animate({top:'120px'},{queue:false,duration:190});
	});
});

$(document).ready(function(){     
	
	//Default Action
	$(".tab_content").hide(); //Hide all content
 	$("ul.tabs li:first").addClass("active").show(); //Activate first tab
	$(".tab_content:first").show(); //Show first tab content

	//On Click Event
	$("ul.tabs li").click(function() {
		$("ul.tabs li").removeClass("active"); //Remove any "active" class
		$(this).addClass("active"); //Add "active" class to selected tab
		$(".tab_content").hide(); //Hide all tab content
		var activeTab = $(this).find("a").attr("href"); //Find the rel attribute value to identify the active tab + content
		$(activeTab).fadeIn('slow'); //Fade in the active content
		return false;
	});
});


//colorbox

$(document).ready(function(){
	//Examples of how to assign the ColorBox event to elements
	$("a[rel='colorbox']").colorbox({transition:"fade"});

});
