// Dropdown menu
$(document).ready(function(){
	$('.nav ul ul').css({display: 'none'});
	$('.nav ul a').wrapInner('<span></span>');
	$('.nav ul a span').addClass('navstyle');
	$('.nav ul ul a span').removeClass('navstyle');
	$('.nav ul li').hover(function(){
	$(this).find('ul:first').css({
	visibility: 'visible',
	display: 'none'
	}).fadeIn('1000');
	},
	function(){
	$(this).find('ul:first').css({
	visibility: 'hidden'
	});
	});
	});

// List item animation
	$(document).ready(function(){
	$("#sidebar li a").wrapInner("<span></span>");
	$("#sidebar li a").hover(function(){
	$(this).find('span').stop().animate({marginLeft:'10px'},{queue:false, duration:300, easing: 'easeOutQuart'})
	},function(){
	$(this).find('span').stop().animate({marginLeft:'0px'},{queue:false, duration:300, easing: 'easeOutQuart'})
	});
	});

$(window).load(function() {
	$('#slider').nivoSlider({
	effect:'fade',
	slices:15,
	animSpeed:300,
	pauseTime:4000,
	startSlide:0, //Set starting Slide (0 index)
	directionNav:true, //Next and Prev
	directionNavHide:false, //Only show on hover
	controlNav:true, //1,2,3...
	controlNavThumbs:false, //Use thumbnails for Control Nav
	controlNavThumbsSearch: '.jpg', //Replace this with...
	controlNavThumbsReplace: '_thumb.jpg', //...this in thumb Image src
	keyboardNav:true, //Use left and right arrows
	pauseOnHover:false, //Stop animation while hovering
	manualAdvance:false, //Force manual transitions
	captionOpacity:0.8, //Universal caption opacity
	beforeChange: function(){},
	afterChange: function(){},
	slideshowEnd: function(){} //Triggers after all slides have been shown
	});
	});
