$(document).ready(function(){

	$('.btnLeerMas').hover(function() {
		srcValue = 'images/btnLeerMas' + $(this).attr('id') + '.gif';
		$(this).attr('src', srcValue);
	},function() {
		$(this).attr('src', 'images/btnLeerMas.gif');
	}).click(function() {
		$(this).parent(".newsItem").find('.newsMore').slideDown(300);
		$(this).parent(".newsItem").find('.btnCerrar').css("display", "block");
		$(this).css("display", "none");
	});
	
	
	$('.btnVerEvento').hover(function() {
		srcValue = 'images/btnVerEvento' + $(this).attr('id') + '.gif';
		$(this).attr('src', srcValue);
	},function() {
		$(this).attr('src', 'images/btnVerEvento.gif');
	}).click(function() {
		$(this).parent(".newsItem").find('.newsMore').slideDown(300);
		$(this).parent(".newsItem").find('.btnCerrar').css("display", "inline");
		$(this).css("display", "none");
	});
	
	
	$('.btnTrackList').hover(function() {
		$(this).attr('src', 'images/btnTrackListBlue.gif');
	},function() {
		$(this).attr('src', 'images/btnTrackList.gif');
	}).click(function() {
		$('.albumTrackList').slideUp(300);
		$('.btnCloseTrackList').css("display", "none");
		$('.btnTrackListWrapper').css("background", "none");
		$('.btnTrackList').css("display", "block");
		
		$(this).parent('.btnTrackListWrapper').next('.albumTrackList').slideDown(300);
		$(this).css("display", "none");
		$(this).next('.btnCloseTrackList').css("display", "block");
		$(this).parent('.btnTrackListWrapper').css("background", "#00ffff");
	});
	
	$('.btnCloseTrackList').hover(function() {
		$(this).attr('src', 'images/btnCloseTrackListBlue.gif');
	},function() {
		$(this).attr('src', 'images/btnCloseTrackList.gif');
	}).click(function() {
		$(this).parent('.btnTrackListWrapper').next('.albumTrackList').slideUp(300);
		$(this).css("display", "none");
		$(this).prev('.btnTrackList').css("display", "block");
		$(this).parent('.btnTrackListWrapper').css("background", "none");
	});
	
	
	$('.btnVerGalleria').hover(function() {
		$(this).attr('src', 'images/btnVerGalleriaGreen.gif');
	},function() {
		$(this).attr('src', 'images/btnVerGalleria.gif');
	});


	$('.btnCerrar').hover(function() {
		srcValue = 'images/btnCerrar' + $(this).attr('id') + '.gif';
		$(this).attr('src', srcValue);
	},function() {
		$(this).attr('src', 'images/btnCerrar.gif');
	}).click(function() {
		if ($(this).attr('id') == "Red")
			window.close();
		else {
			$(this).parent(".newsItem").find('.newsMore').slideUp(300);
			$(this).parent(".newsItem").find('.btnLeerMas').css("display", "block");
			$(this).parent(".newsItem").find('.btnVerEvento').css("display", "inline");
			$(this).css("display", "none");
		}
	});
	
	
	$('#btnSubmit').hover(function() {
		$(this).attr('src', 'images/btnEnviarRed.gif');
	},function() {
		$(this).attr('src', 'images/btnEnviar.gif');
	});
	

});