	var menunormal = 385;
	var menustart = 490;
	var mozopacity = 0;
	var ieopacity = 0;
	var gotolink = '';
	var fadeing = 1;
	var moz = (navigator.appName.indexOf("Netscape")!=-1);
	
	function moveup(t) {
		menuaktuell = parseInt(document.getElementById("menu").style.top);
		if (t<100) {
			menuaktuell=menuaktuell-2;
			menuaktuell= menustart - easeOutQuad(t,0,menustart-menunormal,100);
			document.getElementById("menu").style.top=menuaktuell+"px";
			setTimeout("moveup("+(t+1)+")",20);
		} else {
			fadein();
		}
		return false;
	}  

	function movedown(t) {
		menuaktuell = parseInt(document.getElementById("menu").style.top);
		if (t<100) {
			menuaktuell=menuaktuell+2;
			menuaktuell = easeOutQuad(t,0,menustart-menunormal,100)+menunormal;
			// alert(menuaktuell);
			document.getElementById("menu").style.top=menuaktuell+"px";
			setTimeout("movedown("+(t+1)+")",20);
		} else {
			location.href=gotolink;
		}
		return false;
	} 	

	
	function fadeout3() {
		if (moz) mozopacity = parseFloat(document.getElementById("fliess").style.MozOpacity);
		if (!moz) ieopacity = parseInt(document.getElementById("fliess").filters.alpha.opacity);
		if (moz) { if (mozopacity>0) { document.getElementById("fliess").style.MozOpacity=mozopacity-0.015 } }
		if (!moz) { if (ieopacity>0) { document.getElementById("fliess").filters.alpha.opacity=ieopacity-2; } }

		if (ieopacity>0 || mozopacity>0) {
			setTimeout("fadeout3()",10);
		} 
		return false;
	}
	
	function fadein2() {
		
			if (moz) mozopacity = parseFloat(document.getElementById("fliess").style.MozOpacity);
			if (!moz) ieopacity = parseInt(document.getElementById("fliess").filters.alpha.opacity);
			if (!moz && ieopacity<100 || moz && mozopacity<1) {
				if (moz)  if (mozopacity<1) document.getElementById("fliess").style.MozOpacity=mozopacity+0.015;
				if (!moz) if (ieopacity<100) document.getElementById("fliess").filters.alpha.opacity=ieopacity+2;
				setTimeout("fadein2()",10);
			} else {
				setTimeout("fadeout3()",20000);
			}

	}
	
	function fadeipad() {
		document.getElementById("mainmenu").style.display='block';
		document.getElementById("skipintro").style.display='none';
		document.getElementById("mainmenu").style.opacity=1.0;
		
			return false;
	}
	
	function fadein() {
		document.getElementById("mainmenu").style.display='block';
		document.getElementById("skipintro").style.display='none';
		
		if (fadeing==1) {
			if (moz) mozopacity = parseFloat(document.getElementById("mainmenu").style.opacity);
			if (!moz) ieopacity = parseInt(document.getElementById("mainmenu").filters.alpha.opacity);
			if (!moz && ieopacity<100 || moz && mozopacity<1) {
				if (moz)  if (mozopacity<1) document.getElementById("mainmenu").style.opacity=mozopacity+0.015;
				if (!moz) if (ieopacity<100) document.getElementById("mainmenu").filters.alpha.opacity=ieopacity+2;
				setTimeout("fadein()",10);
			} else {
				
			}
		}
			return false;
	}
	
	function openNav() {
	
		document.getElementById("mainmenu").style.display='block';
		document.getElementById("skipintro").style.display='none';
		
		
		
			return false;
	}
	
	function fadeout2() {
		if (moz) mozopacity = parseFloat(document.getElementById("menulinks").style.MozOpacity);
		if (!moz) ieopacity = parseInt(document.getElementById("menulinks").filters.alpha.opacity);
		if (moz) { if (mozopacity>0) { document.getElementById("menulinks").style.MozOpacity=mozopacity-0.015 } }
		if (!moz) { if (ieopacity>0) { document.getElementById("menulinks").filters.alpha.opacity=ieopacity-2; } }

		if (ieopacity>0 || mozopacity>0) {
			setTimeout("fadeout2()",10);
		} else {
			movedown(0);
		}
		return false;
	} 
	
	function linkto(link) {
		fadeing=0;
		gotolink = link;
		fadeout2();
		return false;
	}
	
	
	function easeOutCubic(t, b, c, d) {
		t = t/d-1;
		return c*((t)*t*t + 1) + b;
	}
	
	function easeOutQuad(t, b, c, d) {
        t = t / d;
        return -c*(t)*(t-2)+b;
	}
	
	function easeInBounce(t, b, c, d) {
		return c - easeOutBounce (d-t, 0, c, d) + b;
	}

	function easeOutBounce(t, b, c, d) {
    t = t / d;

		if ((t) < (1/2.75)) {
			return c*(7.5625*t*t) + b;
		} else if (t < (2/2.75)) {
			
			return c*(7.5625*(t-=(1.5/2.75))*t + 0.75) + b;
		} else if (t < (2.5/2.75)) {
			
			return c*(7.5625*(t-=(2.25/2.75))*t + 0.9375) + b;
		} else {
			
			return c*(7.5625*(t-=(2.625/2.75))*t + 0.984375) + b;
		}
	}
	
	function easeInOutBounce(t,b,c,d) {
		if (t < d/2) easeInBounce (t*2, 0, c, d) * .5 + b;
		return easeOutBounce (t*2-d, 0, c, d) * .5 + c*.5 + b;
	}

