	function def_overout(i){
		isIE6 = navigator.userAgent.toLowerCase().indexOf('msie 6') != -1;
		if (isIE6){
			sp=0;
		}else sp=500;
	
	
		$("#cert"+i+"").mouseover(
			function(){
				$("#cert"+i+" .info").show(sp);
				
				for (var k=1;k<12; k++ ){
					if (i!=k) $("#cert"+k+" .info").hide();
				}
			      
				
			}
		);
		
		$("#cert"+i+" ").mouseleave(
			function(){
				$("#cert"+i+" .info").hide(sp);				
			}
		);
	}
	
		
	$(document).ready(function(){
		for (var i=1; i<12; i++){
	   		def_overout(i);	   	
	   	}				
			aktual_init();
			nw_vzad();									
		});			



var news=Array();
var max=0;
var slide_on=true;


function aktual_init(){
	var i=0;

	$("#aktuality li").each(function(){
		news[i++]=$( this ).html();
		max=i;
	});
		
	
	$("#left").click(function(){
		slide_on=false;
		nw_vpred();
	});
	
	$("#right").click(function(){
		slide_on=false;
		nw_vzad();
	});
	
}

var j=0;

function nw_vpred(){
	$("#p2").html(news[j]);
	j--;
	if (j<0) j=max-1;	
	$("#p1").html(news[j]);
	
	$('#vozik').css('left','-550px');
	$('#vozik').animate({left:'0px' }, 1200);
	if (slide_on) setTimeout(nw_vpred, 8000);
}



function nw_vzad(){
	$("#p1").html(news[j]);
	j++;
	if (j>=max) j=0;	
	$("#p2").html(news[j]);
	
	
	$('#vozik').css('left','0px');
	$('#vozik').animate({left:'-550px' }, 1200);
	if (slide_on) setTimeout(nw_vzad, 8000);
}








