$(document).ready(function() {

// Cufon!
Cufon.replace('ul#mainnav li',{hover:true,hoverables:{a:true}});
Cufon.replace('span.izq',{hover:true,hoverables:{a:true}});
Cufon.replace('span.warah',{hover:true,hoverables:{a:true}});
Cufon.replace('div#descripcion h1, div#descripcion h2, div#descripcion h3',{hover:true,hoverables:{a:true}});
$("img.thumb").fadeTo(300, 0.6);


$("img.thumb").hover(function() {
	 $(this).stop().css("backgroundColor","#222").fadeTo(200, 1 );
 }, function() {
	$(this).stop().css("backgroundColor","#000").fadeTo(300, 0.6);
}); 

$("#next2 img, #prev2 img").hover(function() {
	 $(this).stop().css("cursor","pointer").fadeTo(200, 0.8 );
 }, function() {
	$(this).stop().css("cursor","default").fadeTo(300, 1);
}); 

$('div#contenido').cycle({ 
				fx:     'scrollLeft',
				easing: 'easeInExpo',
				speed: 800,
				timeout: 0,
				delay: 2000,
				next:   '#next2', 
			    prev:   '#prev2',
				startingSlide: 0 
			});

$("a[rel='golden-palace-san-luis']").colorbox({transition:"fade"});
$("a[rel='casino-gala']").colorbox({transition:"fade"});
$("a[rel='tragamonedas-new-york']").colorbox({transition:"fade"});
$("a[rel='casino-flamingo']").colorbox({transition:"fade"});
$("a[rel='casino-golden-palace']").colorbox({transition:"fade"});
$("a[rel='amerian-gala']").colorbox({transition:"fade"});
$("a[rel='amerian-golden']").colorbox({transition:"fade"});
$("a[rel='bingo-ciudadela']").colorbox({transition:"fade"});
$("a[rel='tragamonedas-flamingo']").colorbox({transition:"fade"});
$("a[rel='dos-venados']").colorbox({transition:"fade"});
$("a[rel='bingo-merlo']").colorbox({transition:"fade"});
$("a[rel='bingo-golden-palace']").colorbox({transition:"fade"});
$("a[rel='bingo-hurlingham']").colorbox({transition:"fade"});
$("a[rel='hipodromo-lapunta']").colorbox({transition:"fade"});
$("a[rel='bingo-bahia']").colorbox({transition:"fade"});
$("a[rel='paso-de-los-libres']").colorbox({transition:"fade"});
$("a[rel='winland-casino']").colorbox({transition:"fade"});

			$(".thumb").eq(0).click(function() { $('div#contenido').cycle(1);  return false;  });
			$(".thumb").eq(1).click(function() { $('div#contenido').cycle(2);  return false;  });
			$(".thumb").eq(2).click(function() { $('div#contenido').cycle(3);  return false;  });
			$(".thumb").eq(3).click(function() { $('div#contenido').cycle(4);  return false;  });
			$(".thumb").eq(4).click(function() { $('div#contenido').cycle(5);  return false;  });
			$(".thumb").eq(5).click(function() { $('div#contenido').cycle(6);  return false;  });
			$(".thumb").eq(6).click(function() { $('div#contenido').cycle(7);  return false;  });
			$(".thumb").eq(7).click(function() { $('div#contenido').cycle(8);  return false;  });
			$(".thumb").eq(8).click(function() { $('div#contenido').cycle(9);  return false;  });
			$(".thumb").eq(9).click(function() { $('div#contenido').cycle(10);  return false;  });
			$(".thumb").eq(10).click(function() { $('div#contenido').cycle(11);  return false;  });
			$(".thumb").eq(11).click(function() { $('div#contenido').cycle(12);  return false;  });
			$(".thumb").eq(12).click(function() { $('div#contenido').cycle(13);  return false;  });
			$(".thumb").eq(13).click(function() { $('div#contenido').cycle(14);  return false;  });
			$(".thumb").eq(14).click(function() { $('div#contenido').cycle(15);  return false;  });
			$(".thumb").eq(15).click(function() { $('div#contenido').cycle(16);  return false;  });
			$(".thumb").eq(16).click(function() { $('div#contenido').cycle(17);  return false;  });
			$(".thumb").eq(17).click(function() { $('div#contenido').cycle(18);  return false;  });

			$("span.titulo").eq(0).click(function() { $('div#contenido').cycle(1);  return false;  });
			$("span.titulo").eq(1).click(function() { $('div#contenido').cycle(2);  return false;  });
			$("span.titulo").eq(2).click(function() { $('div#contenido').cycle(3);  return false;  });
			$("span.titulo").eq(3).click(function() { $('div#contenido').cycle(4);  return false;  });
			$("span.titulo").eq(4).click(function() { $('div#contenido').cycle(5);  return false;  });
			$("span.titulo").eq(5).click(function() { $('div#contenido').cycle(6);  return false;  });
			$("span.titulo").eq(6).click(function() { $('div#contenido').cycle(7);  return false;  });
			$("span.titulo").eq(7).click(function() { $('div#contenido').cycle(8);  return false;  });
			$("span.titulo").eq(8).click(function() { $('div#contenido').cycle(9);  return false;  });
			$("span.titulo").eq(9).click(function() { $('div#contenido').cycle(10);  return false;  });
			$("span.titulo").eq(10).click(function() { $('div#contenido').cycle(11);  return false;  });
			$("span.titulo").eq(11).click(function() { $('div#contenido').cycle(12);  return false;  });
			$("span.titulo").eq(12).click(function() { $('div#contenido').cycle(13);  return false;  });
			$("span.titulo").eq(13).click(function() { $('div#contenido').cycle(14);  return false;  });
			$("span.titulo").eq(14).click(function() { $('div#contenido').cycle(15);  return false;  });
			$("span.titulo").eq(15).click(function() { $('div#contenido').cycle(16);  return false;  });
			$("span.titulo").eq(16).click(function() { $('div#contenido').cycle(17);  return false;  });
			$("span.titulo").eq(17).click(function() { $('div#contenido').cycle(18);  return false;  });			

 $('div.port').hover(function(){
	 $("span.titulo", this).stop().css("cursor","pointer").animate({bottom:'-20px',opacity:'0.75'},{queue:false,duration:300});
	 }, function() {
	 $("span.titulo", this).stop().css("cursor","default").animate({bottom:'-100px'},{queue:false,duration:600});
 }); 
	 $('span.titulo').hover(function(){
	 $(this).css("cursor","pointer");
	 }, function() {
	 $(this).css("cursor","default");
 }); 		
		

	$("ul#menu-principal li").hover(function() {
		$(this).find('a').stop().animate({backgroundPosition: "-8px -2px"}, 300, 'easeOutExpo'); // .animate({paddingLeft: "12px"}, 300, 'easeOutExpo')
	  }, function() {	
		$(this).find('a').stop().animate({backgroundPosition: "-20px -2px"}, 300, 'easeInBack'); // .animate({paddingLeft: "7px"}, 400, 'easeOutExpo');
	});

// Roll overs
$("div#tapa-abajo ul li a").hover(function() {
	 $(this).stop().fadeTo(100,0.2).fadeTo(300, 0.8 );
 }, function() {
	$(this).stop().fadeTo(300, 1);
}); 
 
// Campos
$("input[name='email']").focus(function () {
	$(this).css( "color", "#000" );
	$(this).attr("value", "");
	return true;
});


$("input[name='email']").blur(function() {
	$(this).css('color', '#838383');
	var value = $(this).attr("value");
	
	   			if (this.value == '') {
        			$(this).attr("value", "E-mail");
      			}	

	return true;
});
$("input[name='nombre']").focus(function () {
	$(this).css( "color", "#000" );
	$(this).attr("value", "");
	return true;
});


$("input[name='nombre']").blur(function() {
	$(this).css('color', '#838383');
	var value = $(this).attr("value");
	
	   			if (this.value == '') {
        			$(this).attr("value", "Nombre y Apellido");
      			}	

	return true;
});




});


