jQuery(document).ready(function($){
	$('.doc-marches a').attr('target','_blank');
	
	$('#header #nav a')
	.css( {backgroundPosition: "0 28px"} )
	.mouseover(function(){
		$(this).stop().animate(
			{backgroundPosition:"(0 0)"}, 
			{duration:200})
		})
	.mouseout(function(){
		$(this).stop().animate(
			{backgroundPosition:"(0 28px)"}, 
			{duration:200})
	})
	
	$('#nav li.active a')
	.css( {backgroundPosition: "0 0"} )
	.mouseover(function(){
		$(this).stop().animate(
			{backgroundPosition:"(0 0)"})
		})
	.mouseout(function(){
		$(this).stop().animate(
			{backgroundPosition:"(0 0)"})
	})
	
	$('.widgetRaccourcisD a')
	.css( {backgroundPosition: "0 25px"} )
	.mouseover(function(){
		$(this).stop().animate(
			{backgroundPosition:"(0 0)"}, 
			{duration:200})
		})
	.mouseout(function(){
		$(this).stop().animate(
			{backgroundPosition:"(0 25px)"}, 
			{duration:200})
	})
	
	var contenu = $.trim($(".result").html());
	if (contenu == ""){
		$("#affiche").prev(function(){
			$(this).remove();
		});
	}

	$(".widgetRecher .row option:first").prepend('Type de logement');
	
	var listProducts = $.trim($(".listProducts").html());
	if (listProducts == ""){
		$('.dispo .listProducts').prepend('<p>Aucun logement disponible</p>');
		$('.marches-publics .listProducts').prepend('<p>Aucun marché public disponible</p>');
	}
	
	$.localScroll();
	
});
