/* browser snifer */
dom=(document.getElementById)?1:0;
ns6=(dom&&!document.all)?1:0;
if(!dom) alert('This site is not compatible with your browser!');
/* window positioning */
winw=(ns6)? window.innerWidth:document.body.offsetWidth;
if(winw<760)	document.write('<style>div.content{left:380px;}</style>')
onresize=function(){self.location.reload()}
/* dynlite layer */
obj=function(id,ob)
{ 	var el=document.getElementById(id);
	if(ob) el.ob=ob;
	el.on=function(){el.style.display='block';}
	el.off=function(){el.style.display='none';}
return el;
}
/* popup window managing */
popupWin=0;
popupOpen=function(file,w,h) 
{	this.popupW=w||610;
	this.popupH=h||510;
	this.popupX=parseInt(((ns6)? window.innerWidth:document.body.offsetWidth)/2-this.popupW/2)||100;			
	this.popupY=parseInt(((ns6)? window.innerHeight:document.body.offsetHeight)/2-this.popupH/2)||50;
	if(this.popupWin)
	{	this.popupWin.close();
		this.popupWin=0;
	} 
	this.popupWin=window.open(file,'popupWindow','left='+this.popupX+',top='+this.popupY+',width='+this.popupW+',height='+this.popupH+',scrollbars=0');
	this.popupWin.focus();
};

function openPopUp(par)
{popupWin=window.open('popUp.html?'+par,'','left=10,top=10,width=780,height=550,scrollbars=1,resizable=yes');}


/* div popup class */
function divPopup(id,cont,img)
{	this.id=id;
	this._img=new Image();
	this._contName=cont;
	this._imgName=img;
	this.cont=0;
	this.img=0;
}
/* div popup methods */
/* private */
_dp=divPopup.prototype;
_dp._show=function()
{	this.img.src=this._img.src;
	this.cont.style.width=this._img.width;
	this.cont.style.height=this._img.height;
	(ns6)? this.cont.style.MozOpacity="1":this.cont.filters.alpha.opacity="100";
	setTimeout("obj('enlargeBottom').on()",450);
}
/* public */
_dp.show=function(src)
{	if(!this.cont) this.cont=obj(this._contName);
	if(!this.img) this.img=obj(this._imgName);
	this._img.defsrc=this.img.getAttribute("defsrc",false);
	this._img.src=src;
	this._img.onload=function(){dp._show()};
	obj('enlargeBottom').off();
	this.cont.on();
}
_dp.close=function()
{	this.cont.off();
	this.img.src=this._img.defsrc;
	(ns6)? this.cont.style.MozOpacity=".7":this.cont.filters.alpha.opacity="70";
}
/* static object creation */
dp=new divPopup('dp','enlarge','enlargePic');

function picOnload()
{ 	imobj.src=im.src;
	cont.style.width=im.width;
	cont.style.height=im.height;
	(ns6)? cont.style.MozOpacity="1":cont.filters.alpha.opacity="100";
}

function init()
{	try{
		obj('jsHref').style.visibility="visible";
	}catch(e){}
	try{
		page.css.attr("a.cartButtonsMargin","display","block")
	}catch(e){}
}