jQuery(document).ready(function(){
			
			$("a").simpletooltip();
			$("a.popup").fancybox({
				'titleShow'		: true,
				'transitionIn'	: 'elastic',
				'transitionOut'	: 'elastic',
				'titlePosition' 	: 'over',
				'titleFormat'       : function(title, currentArray, currentIndex, currentOpts) {
				return '<span id="fancybox-title-over">Imaginea ' +  (currentIndex + 1) + ' / ' + currentArray.length + '  ' + title +'</span>';
			}
			});
			$("a.main_img").fancybox({
				'titleShow'		: true,
				'transitionIn'	: 'elastic',
				'transitionOut'	: 'elastic'
			});
			$(".img_prod a[rel=galerie]").fancybox({
			'transitionIn'		: 'none',
			'transitionOut'		: 'none',
			'titlePosition' 	: 'over',
			'titleFormat'       : function(title, currentArray, currentIndex, currentOpts) {
				return '<span id="fancybox-title-over">Imaginea ' +  (currentIndex + 1) + ' / ' + currentArray.length + '</span>';
			}
		});
			
			
		$('.articole_primapagina').vTicker({
			   speed: 500,
			   pause: 5000,
			   showItems: 4,
			   animation: 'fade',
			   mousePause: false,
			   height: 0,
			   direction: 'up'
			});	
		
		//Cufon.replace('h1');
		
		//Cufon.replace('h2.titlu');
		//Cufon.replace('#siteInfoSt h2');
		//Cufon.replace('#siteInfoDr h2');
		

		//$("#start").datepicker();
		//$("#start").datepicker({ dateFormat: 'yy-mm-dd' });
		//$("#start").datepicker( "option", "dateFormat", 'yy-mm-dd' );
		//$("#end").datepicker();	
		//$("#end").datepicker({ dateFormat: 'yy-mm-dd' });
		//$("#end").datepicker( "option", "dateFormat", 'yy-mm-dd' );
		//$("#btnCautareSus").button();
		
		function addMega(){
        $(this).addClass("hovering");
        }

      function removeMega(){
        $(this).removeClass("hovering");
        }

    var megaConfig = {
         interval: 100,
         sensitivity: 3,
         over: addMega,
         timeout: 100,
         out: removeMega
    };

    $("#siteContainer #siteHeader #siteMainMnu ul li.mega").hoverIntent(megaConfig);

	$("#intrebari_frecvente").accordion();
	$("#accordion").accordion();


id=$("#frmPetitie select#selTipPers option:selected").attr("value");
		  if (id == 1)
			  {
			  $("#frmPetitie #lblNume").html("Numele *");
			  $("#frmPetitie #lblPrenume").html("Prenume *");
			  }
		  else if (id == 2)
			  {
			  $("#frmPetitie #lblNume").html("Denumire *");
			  $("#frmPetitie #lblPrenume").html("CUI ");
			  }

	$("#frmPetitie select#selTipPers").change(function () {
		//var id = "";
		 id=$("#frmPetitie select#selTipPers option:selected").attr("value");
		  if (id == 1)
			  {
			  $("#frmPetitie #lblNume").html("Numele *");
			  $("#frmPetitie #lblPrenume").html("Prenume *");
			  }
		  else if (id == 2)
			  {
			  $("#frmPetitie #lblNume").html("Denumire *");
			  $("#frmPetitie #lblPrenume").html("CUI ");
			  }
		});



		});
