<!--

dom = (document.getElementById) ? true : false;
ns5 = ((navigator.userAgent.indexOf("Gecko")>-1) && dom) ? true: false;
ie5 = ((navigator.userAgent.indexOf("MSIE")>-1) && dom) ? true : false;
ns4 = (document.layers && !dom) ? true : false;
ie4 = (document.all && !dom) ? true : false;
nodyn = (!ns5 && !ns4 && !ie4 && !ie5) ? true : false;
var winHt;
function initNavLyr(lyr) {
	if (nodyn) return;
	winHt = (ie4||ie5)? document.body.clientHeight: window.innerHeight;
	navLyr = new Object();
	navLyr.yOff=0;
	navLyr.xOff=0;
	navLyr.glide_dur=1000;
	navLyr.lyr = (ns4)? document.layers[lyr]: (ie4)? document.all[lyr]:  document.getElementById(lyr);
	navLyr.css = (ns4)? navLyr.lyr: navLyr.lyr.style;	
	navLyr.obj = lyr + "Object"; 	eval(navLyr.obj + "=navLyr"); 
	navLyr.checkNavLyr=checkNavLyr;
	navLyr.glideInit=navGlideInit; navLyr.glide=navGlide;
	navLyr.css.left = (ns4)? navLyr.xOff: navLyr.xOff+"px";	
	navLyr.css.top=(ns4)? navLyr.yOff: navLyr.yOff+"px";
	navLyr.css.visibility = "visible";
	navLyr.checkNavLyr();
}
function checkNavLyr() {
	var yScroll=(ie4||ie5)? document.body.scrollTop: window.pageYOffset;
	this.curTop = parseInt(this.css.top);
	this.newDestY = yScroll + this.yOff;
	if (this.newDestY!=this.curTop) {
		if (this.newDestY!=this.destY) {
			this.destY = this.newDestY;
			this.glideInit();
		} 
		this.glide();
	}
	var t=setTimeout(this.obj+".checkNavLyr()",20);
}
function navGlideInit() {
	var now = new Date();
	this.a = this.destY-this.curTop;
	this.b = Math.PI/(2*this.glide_dur);
	this.c = now.getTime();
	if (Math.abs(this.a)>winHt) {
		this.d = (this.a>0)? this.destY-winHt: this.destY+winHt;
		this.a = (this.a>0)? winHt : -winHt;
	} else this.d = this.curTop;
}
function navGlide() {
	var now = new Date();
	var t = now.getTime()-this.c;
	var y = Math.round(this.d+this.a*Math.sin(this.b*t));
	if ((this.a>0&&y>this.curTop)||(this.a<0&&y<this.curTop)) 
		(ns4)? this.css.top=y: this.css.top=y+"px";
}

//-->

