window.onresize=load2;

function load(){
 userAgent=navigator.userAgent.toLowerCase();
 browsers=true;
 if(userAgent.indexOf("opera")>=0){browsers=false;}
 load2()
}
	function load2(){
	if(browsers){
	w=document.documentElement.clientWidth;
	h=document.documentElement.clientHeight;
	}
	else{
	w=self.innerWidth;
	h=self.innerHeight;
	}
	W=(w-773)/2;
	H=(h-590)/2;
	if(W<5){
	document.getElementById("body").style.left=5+"px";
	document.getElementById("vertex").style.left=5+"px";
	}else{
	document.getElementById("body").style.left=W+"px";
	document.getElementById("vertex").style.left=W+"px";
	}
	if(H<5){
	document.getElementById("body").style.top=5+"px";
	document.getElementById("vertex").style.top=587+"px";
	}else{
	document.getElementById("body").style.top=H+"px";
	document.getElementById("vertex").style.top=(H+582)+"px";
	}
	if(!browsers){
	if(H<5){document.getElementById("vertex").style.top=592+"px";}
	else{document.getElementById("vertex").style.top=(H+587)+"px";}
	}
	document.getElementById("body").style.display="block";
	document.getElementById("vertex").style.display="block";	
	}
	
	function butover(x){
	document.getElementById("ar"+x).style.visibility="visible";
	if(x==6){
	document.getElementById("fincur").style.display="block";
	}else{
	document.getElementById("fincur").style.display="none";
	}
	}
	
	function non(){
	document.getElementById("fincur").style.display="none";
	}
	
	function butover2(x){
	document.getElementById("ar"+x).style.visibility="visible";
	}
	
	function butout(x){
	document.getElementById("ar"+x).style.visibility="hidden";
	}
	
	masref=new Array()
	masref[1]="news.php";
	masref[2]="organization.php";
	masref[3]="history.php";
	masref[4]="laws.php";
	masref[5]="competitions.php";
	masref[6]="";
	masref[7]="articles.php";
	masref[8]="publications.php";
	masref[9]="filmprojects.php";
	masref[10]="natarchive.php";
	masref[11]="ideabasket.php";
	masref[12]="statistics.php";
	masref[13]="previous.php";
	masref[14]="filmorganizations.php";
	masref[15]="links.php";
	masref[16]="contact.php";
	masref[17]="films0.php";
	masref[18]="films1.php";