function MoveBlocks()
{
	Cont = document.getElementById("layer");
	Targ = document.getElementById("main");

	TMain = document.getElementById("main");
	TLeft = document.getElementById("left_from_main");
	TRight = document.getElementById("right_from_main");
	TTopLeft = document.getElementById("lefttop_from_main");
	TTopRight = document.getElementById("righttop_from_main");
	TTop = document.getElementById("top_from_main");
	
	Logo = document.getElementById("logo");
	Menu = document.getElementById("submenu_block");

	WHeight = document.body.clientHeight;
	WWidth = document.body.clientWidth;
	
	TMain.style.backgroundImage = Images[4];
	
	if(WHeight > 670)
	{
		Cont.style.height = WHeight;
		Targ.style.top = WHeight - 670;
		TTop.style.backgroundImage = Images[1];
		
		Logo.style.top = (WHeight - 670) * -1 + 10;
		Menu.style.top = (WHeight - 670) * -1 + 10;
		
		Cont.style.overflow = "hidden";
	}
	else
	{
		Cont.style.height = 670;
		Targ.style.top = 0;
		TTop.style.backgroundImage = "";
		
		Logo.style.top = 10;
		Menu.style.top = 10;
		
		Cont.style.overflow = "visible";
	}
	
	if(WWidth < 800)
	{
		TLeft.style.width = 0;
		TRight.style.width = 0;
		TTopLeft.style.width = 0;
		TTopRight.style.width = 0;
		TLeft.style.backgroundImage = "";
		TRight.style.backgroundImage = "";
	}
	else
	{
		TLeft.style.width = 560;
		TRight.style.width = 560;
		TTopLeft.style.width = 560;
		TTopRight.style.width = 560;
		TLeft.style.backgroundImage = Images[3];
		TRight.style.backgroundImage = Images[5];
	}
	
	if(WWidth > 800)
	{
		Cont.style.overflow = "hidden";
		Cont.style.paddingLeft = "50%";
		Cont.style.paddingRight = "50%";
		Targ.style.margin = "0px -400px";
	}
	else
	{
		Cont.style.overflow = "visible";
		Cont.style.paddingLeft = "0";
		Cont.style.paddingRight = "0";
		Targ.style.margin = "0px 0px";
	}
	
	if((WWidth > 800)&&(WHeight > 670))
	{
		TTopLeft.style.backgroundImage = Images[0];
		TTopRight.style.backgroundImage = Images[2];
		//Cont.style.overflow = "hidden";
		//Cont.style.paddingLeft = "50%";
		//Cont.style.paddingRight = "50%";
		//Targ.style.margin = "0px -400px";
	}
	else
	{
		TTopLeft.style.backgroundImage = "";
		TTopRight.style.backgroundImage = "";
		//Cont.style.overflow = "visible";
		//Cont.style.paddingLeft = "0";
		//Cont.style.paddingRight = "0";
		//Targ.style.margin = "0px 0px";
	}
}

function ScrollBake()
{
	//alert(window.pageYOffset);
	document.cookie = "scroll_cook="+window.pageYOffset;
}

function ScrD(pos)
{
	window.scroll(0,pos);
}
