$(document).ready(function(){
	$('#texto-twitter').css('left','290px');
	$('#contacto-left-side ul > li div')
	.click(function(e){
		e.stopPropagation();
	})
	.filter(':not(:first)')
	.hide();
	$('#contacto-left-side ul > li').click(function(){
		var selfClick = $(this).find('div:first').is(':visible');
		if(!selfClick){
			if($(this).attr('title')=='mty'){
                $('.ver-ubicacion').show();
				$('#mapa').html('<iframe width="430" height="422" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="http://maps.google.com.mx/maps/ms?msa=0&amp;msid=204099433496659429542.0004ac4c7f81f54828334&amp;ie=UTF8&amp;vpsrc=6&amp;ll=25.661411,-100.305862&amp;spn=0.018258,0.018411&amp;z=15&amp;output=embed"></iframe>');
				$('#oculto').val('mty');
			}else if($(this).attr('title')=='cabo'){
			    $('.ver-ubicacion').show();
				$('#mapa').html('<iframe width="430" height="422" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="http://maps.google.com.mx/maps/ms?msa=0&amp;ie=UTF8&amp;vpsrc=6&amp;msid=204099433496659429542.0004ac4c93783af8e4647&amp;ll=22.891516,-109.912076&amp;spn=0.016684,0.018454&amp;z=15&amp;output=embed"></iframe>');
				$('#oculto').val('cabo');
			}else if($(this).attr('title')=='cancun'){
                $('.ver-ubicacion').show();
				$('#mapa').html('<iframe width="430" height="422" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="http://maps.google.com.mx/maps/ms?msa=0&amp;ie=UTF8&amp;vpsrc=6&amp;msid=204099433496659429542.0004ac4cd6fa2461401a4&amp;ll=21.140068,-86.833062&amp;spn=0.016891,0.018411&amp;z=15&amp;output=embed"></iframe>');
				$('#oculto').val('cacun');
			}else if($(this).attr('title')=='victoria'){
                $('#google-maps').animate({
        			top: '0px'
        		},500);
			    $('.ver-ubicacion').hide();
				$('#mapa').html('<iframe width="430" height="422" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="http://maps.google.com.mx/maps/ms?msa=0&amp;ie=UTF8&amp;vpsrc=6&amp;msid=204099433496659429542.0004ac4cd6fa2461401a4&amp;ll=21.140068,-86.833062&amp;spn=0.016891,0.018411&amp;z=15&amp;output=embed"></iframe>');
				$('#oculto').val('victoria');
			}else if($(this).attr('title')=='sanantonio'){
			    $('.ver-ubicacion').show();
				$('#mapa').html('<iframe width="430" height="422" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="http://maps.google.com.mx/maps?f=q&amp;source=embed&amp;hl=en&amp;geocode=&amp;q=10423+Gulfdale+San+Antonio+TX+78216&amp;sll=23.644524,-102.568359&amp;sspn=45.281264,72.246094&amp;ie=UTF8&amp;hq=&amp;hnear=10423+Gulfdale+St,+San+Antonio,+Bexar,+Texas+78216,+United+States&amp;ll=29.534856,-98.487282&amp;spn=0.054517,0.098619&amp;t=m&amp;z=14&amp;vpsrc=6&amp;output=embed"></iframe>');
				$('#oculto').val('cacun');
			}
			
			
			$(this)
			.parent()
			.find('> li div:visible')
			.slideToggle('slow','easeInBack');
		}
		$(this)
		.find('div:first')
		.slideToggle('slow','easeOutBack');
	});
	
	$('#ver-google').click(function(){
		$('#google-maps').animate({
			top: '-=512px'
		},500);
	});
	
	$('#cerrar-google').click(function(){
		$('#google-maps').animate({
			top: '+=512px'
		},500);
	});
});
