// jQuery effects for Wedel, a theme for Dotclear 2
$(document).ready(function(){
	$("body.dc-archive-month .content-inner h2").removeClass('post-title').addClass('archive-title');
	$("#blogextra h2,#search span").css("cursor","pointer");

	$("#search h2,#search input").hide();
	$("#search").appendTo("#top-inner");
	$("#search p").prepend("<span>&nbsp;</span>");
	$("#search span").toggle(function(){
		$("#search input").fadeIn("8000");$(this).show();
		},function(){
		$("#search input").fadeOut("8000");$(this).show();
	});

	$("#blogextra h2").nextAll().hide();
	$("#blogextra h2").click(function(){
		var target = $(this).nextAll();
		$("#blogextra h2 ~ *").not(target).slideUp();
		target.slideToggle();
		$("#footer").blur();
		});

	$("p.day-date").remove();

	$("h2.post-title ~ *").hide();
	$("body.dc-post h2.post-title ~ *,body.dc-page h2.post-title ~ * ").show();
	$("h2.post-title a").click(function(){return false;});
	$("h2.post-title a").click(function(){
		var target = $(this).parent().nextAll();
		$(" h2.post-title ~ *").not(target).slideUp();
		target.slideToggle();
	});
	$("h2.post-title a").hoverIntent((function () {
		$(this).css("cursor","pointer")
		.animate( { backgroundColor:'#1f1c17' }, 500);
	}),(function () {
		$(this).animate( {backgroundColor:'#2D2821' }, 500);
	}));
});
