// jQuery

$(function(){
	
	$('ul.abandu-ads li:odd').addClass('odd'); // Add the odd class to every 2nd ad
	$('.widget:last, ul#menu ul li:last-child').css('border-bottom', 'none'); // Remove the border on the last sidebar widget
	$('.related-posts-thumbs li:last, .footer-col:nth-child(4n+1)').css('margin-right', '0'); // Remove the right margin on the last related post thumbnail and every 4th footer col
	
	
	// Hover effect in sidebar on list elemets without the <img> tag within
	$("#sidebar li:not(:has(img))").hover(function(){
		$(this).stop().animate({
			paddingLeft: "25px"
		}, 400);
	}, function() {
		$(this).stop().animate({
			paddingLeft: "15px"
		}, 400);
	});
	
	
	// Dropdown menu
	$("ul#menu li").hover(function(){
    	$(this).addClass("current");
        $('ul:first',this).css('visibility', 'visible');
	}, function(){
    	$(this).removeClass("current");
        $('ul:first',this).css('visibility', 'hidden');
	});
	
	// prettyPhoto on all links with rel=prettyPhoto
	$("a[rel^='prettyPhoto']").prettyPhoto();

});