$(document).ready(function(){	
	/* Funcion para el flash */
	
	$(function() {
		$('.media').media({ 
			autoplay:  true,
			width: 987,
			height: 146,
			flashvars: { autostart: 'true' } , 
			params:    { wmode: 'transparent', quality: 'high' }, // object params/embed attrs 
			caption:   false // supress caption text 
		}); 
	});
	Shadowbox.init();
	
	if($('#ok-request'))
		$('#ok-request').click();
});

 /*****************************************************************************
    The sIFR configuration should typically go in `sifr-config.js`, but in order to
    keep the config file clean, and to give a quick overview, it's done here instead.
    *****************************************************************************/


 var helvetica_bold = {
      src: '/swf/fuentes/HelveticaLTCondensed.swf'
    };
	
  var helvetica_narrow= {
      src: '/swf/fuentes/HelveticaNarrow.swf'
    };

    // You probably want to switch this on, but read <http://wiki.novemberborn.net/sifr3/DetectingCSSLoad> first.
    // sIFR.useStyleCheck = true;
    sIFR.activate(helvetica_bold);

   sIFR.replace(helvetica_bold, {
      selector: '#seccion h3'
	  ,css: {'.sIFR-root': { 'color': '#717171', 'font-size' : '24px','background-color' : 'transparent','letter-spacing': -0.5} }
	  ,offsetTop : 6
	  ,wmode : 'transparent'
	  ,forceSingleLine : true
    });

	 sIFR.replace(helvetica_bold, {
      selector: '.tituloContacto'
	  ,css: {'.sIFR-root': { 'color': '#FFFFFF', 'font-size' : '16px','background-color' : 'transparent'} }
	  ,offsetLeft: 6
	  ,wmode : 'transparent'
    });
	
	 sIFR.replace(helvetica_narrow, {
      selector: 'h5'
	  ,css: {'.sIFR-root': { 'color': '#58585a', 'font-size' : '16px','background-color' : 'transparent','font-weight': 'bold','padding-bottom':'8px'} }
	  ,offsetLeft: 12
	  ,offsetTop : 8
	  ,tuneHeight : 4
	  ,wmode : 'transparent'
    });


/* Ver producto */
	function desplegar(){
		$('#seccion0 div.contenidoSeccion').slideDown('normal');
		$('#seccion0 div.tituloSeccion a.ampliar').css('visibility','hidden');
	}
	
	function desplegarSeccion(p){
		
	$("*").find("div.contenidoSeccion").each(function(){
				if($(this).css('display') == 'block')
					$(this).slideUp('normal');
            });
			
	$("*").find("a.ampliar").each(function(){
				$(this).css('visibility','visible');
            });	
		
		if ($(p).parent().next().css('display') == 'none') {
			$(p).css('visibility','hidden');
			$(p).parent().next().slideDown('normal');
		}
	
	}	
