$(document).ready(function(){
// Registracion Modalidad 
/*
$("#pais").change(function(){
	$('#notita').jGrowl('ekoparty has real-time english-spanish & spanish-english translations.', {
		life: 6000,
		theme: 'magenta',
		header: 'Languages:',
		sticky: false,
		closer: false,
		closerTemplate: '<div>[ cerrar ]</div>'
	});
});
*/
if($.browser.msie && $.browser.version=="6.0") $(document).pngFix();

// Links externos en vent nueva
$("a[href^='http']").attr({ target: "_blank" });

// Opcidad del sub-Menu
$('.menu ul li span').css({'opacity':'.9'});
$('.menu ul li span a').hover(function() { //mouse in
	$(this).animate({ paddingLeft: 20 },{queue:false,duration:350});
	//$(this).parent().parent().next().addClass('activo');
}, function() { //mouse out
	$(this).animate({ paddingLeft: 11 },{queue:false,duration:500});
	//$(this).parent().parent().removeClass('activo');
});

$('.menu ul li span').hover(function() {
	$(this).parent().find('a:eq(0)').addClass('activo');
}, function() {
	$(this).parent().find('a:eq(0)').removeClass('activo');
});

//Scroll suave
var Velocidad = 900;
function filterPath(string) {
	return string
	.replace(/^\//,'')
	.replace(/(index|default).[a-zA-Z]{3,4}$/,'')
	.replace(/\/$/,'');
}
var locationPath = filterPath(location.pathname);
$('a[href*=#]').each(function() {
	var thisPath = filterPath(this.pathname) || locationPath;
	if (  locationPath == thisPath && (location.hostname == this.hostname || !this.hostname) && this.hash.replace(/#/,'') ) {
		var $target = $(this.hash), target = this.hash;
		if (target) {
			var targetOffset = $target.offset().top;
		$(this).click(function(event) {
			event.preventDefault();
			$('html, body').animate({scrollTop: targetOffset}, Velocidad, "easeOutExpo", function() {
				location.hash = target;
		    });
		});
	}
}
});


// fin JS
});

