window.size = function()
{
	var w = 0;
	var h = 0;

	//IE
	if(!window.innerWidth)
	{
		//strict mode
		if(!(document.documentElement.clientWidth == 0))
		{
			w = document.documentElement.clientWidth;
			h = document.documentElement.clientHeight;
		}
		//quirks mode
		else
		{
			w = document.body.clientWidth;
			h = document.body.clientHeight;
		}
	}
	//w3c
	else
	{
		w = window.innerWidth;
		h = window.innerHeight;
	}
	return {width:w,height:h};
}

window.center = function()
{
	var hWnd = (arguments[0] != null) ? arguments[0] : {width:0,height:0};

	var _x = 0;
	var _y = 0;
	var offsetX = 0;
	var offsetY = 0;

	//IE
	if(!window.pageYOffset)
	{
		//strict mode
		if(!(document.documentElement.scrollTop == 0))
		{
			offsetY = document.documentElement.scrollTop;
			offsetX = document.documentElement.scrollLeft;
		}
		//quirks mode
		else
		{
			offsetY = document.body.scrollTop;
			offsetX = document.body.scrollLeft;
		}
	}
	//w3c
	else
	{
		offsetX = window.pageXOffset;
		offsetY = window.pageYOffset;
	}

	_x = ((this.size().width-hWnd.width)/2)+offsetX;
	_y = ((this.size().height-hWnd.height)/2)+offsetY;

	return{x:_x,y:_y};
}

var height = this.size().height;
//alert("window height is " + height +"px");
document.write('<style type="text/css">');
		document.write('<!--');
		if (height >= 665 && height < 800)
		{
				//alert(myHeight);
				document.write('body {font-size: 55%;}');
		}
		else if (height >= 615 && height < 664)
		{
				//alert(myHeight);
				document.write('body {font-size: 50%;}');
		}
		else if (height < 614)
		{
				//alert(height);
				document.write('body {font-size: 45%;}');
				document.write('.container { width: 859px; }');
				document.write('.imgArea, .imgArea .slideshow, .imgArea .artwork { width: 859px; height: 508px; }');
				document.write('.about, .testimonials, .projDetails { height: 494px; }');
		}
		else
		{
				document.write('body {font-size: 62.5%;}');
		}
		document.write('-->');
		document.write('</style>');