$(document).ready(function(){  

//Menu Dropdown Action

	$(".dropdown").hover(function() {
		$(this).parent().find("ul.sub_menu").slideDown("fast").show();
		$(this).addClass("active");
		$(this).parent().hover(function() {}, function(){
			$(this).parent().find("ul.sub_menu").slideUp("fast");
			$(".dropdown").removeClass("active");
		});
	});

//Contact Form Dropdown

	$("#contact_us").click(function(){
		$("#contactbox").slideToggle("slow");
		$(this).toggleClass("active");
		return false;
	});

	$(".contact_link").click(function(){
		$("#contactbox").slideToggle("slow");
		$(this).toggleClass("active");
		return false;
	});

});

//NivoSlider Setup

$(window).load(function() {
	$('#banner-slider').nivoSlider({
		effect:						'fade', //Specify sets like: 'fold,fade,sliceDown'
		slices:						1,
		animSpeed:					200, //Slide transition speed
		pauseTime:					4000,
		startSlide:					0, //Set starting Slide (0 index)
		directionNav:				true, //Next & Prev
		directionNavHide:			false, //Only show on hover
		controlNav:					false, //1,2,3...
		controlNavThumbs:			false, //Use thumbnails for Control Nav
		controlNavThumbsFromRel:	false, //Use image rel for thumbs
		controlNavThumbsSearch:		'.png', //Replace this with...
		controlNavThumbsReplace:	'_thumb.png', //...this in thumb Image src
		keyboardNav:				true, //Use left & right arrows
		pauseOnHover:				true, //Stop animation while hovering
		manualAdvance:				false, //Force manual transitions
		captionOpacity:				0, //Universal caption opacity
	});
});

$(window).load(function() {
	$('#portfolio-slider').nivoSlider({
		effect:						'fade', //Specify sets like: 'fold,fade,sliceDown'
		slices:						1,
		animSpeed:					200, //Slide transition speed
		pauseTime:					5000,
		startSlide:					0, //Set starting Slide (0 index)
		directionNav:				true, //Next & Prev
		directionNavHide:			false, //Only show on hover
		controlNav:					false, //1,2,3...
		controlNavThumbs:			false, //Use thumbnails for Control Nav
		controlNavThumbsFromRel:	false, //Use image rel for thumbs
		controlNavThumbsSearch:		'.png', //Replace this with...
		controlNavThumbsReplace:	'_thumb.png', //...this in thumb Image src
		keyboardNav:				true, //Use left & right arrows
		pauseOnHover:				true, //Stop animation while hovering
		manualAdvance:				false, //Force manual transitions
		captionOpacity:				1, //Universal caption opacity
	});
});

