/*
 * This file should contain all the info for positioning things in response to page size.
 */

html
{
	padding: 0px;
	margin: auto;
	border: 0px;
	text-align: center;
}

body
{
	border: 0px;
	margin: auto;
	padding: 0px;
	min-width:320px;
	max-width:910px;
}

#title
{
	position:absolute;
	left:10px;
}

#topright
{
	float:right;
}

#topbar 
{
	position:relative;
	border-style:solid;
	border-width: 0px 0px 1px 0px;
	padding: 10px;
	height: 45px;
}


#sitebody
{
	position:relative;
	display:inline-block;
	width:100%;
	padding: 0px;
}

#menu
{
	width: 150px;
	float: left;
	clear:left;
	margin:10px 0px 10px 8px;
	padding: 10px 0px 0px 0px;
}

#menuad
{
	width: 120px;
	height: 240px;
	float: left;
	clear:left;
	margin:8px 20px 20px 23px;
	padding: 0px;
}

#searchform
{
	border: 0px solid #000;
	padding: 5px 0px 0px 20px;
	text-align:left;
	margin-top: 0px;
	margin-bottom:20px;
}
#searchbox
{
	position:relative;
	left:-7px;
}

.menu1
{
	display:inline;
}
.menu2
{
	display:none;
}

#menu ul
{
	padding-left: 30px;
	margin:0px 0px 15px 0px;
}

#menu li
{
	margin: 0px 0px 3px 0px;
	padding:0px;
	clear: both;
	text-indent:-4px;
	text-align: left;
	border-width:0px;
	border-style:solid;
}

#menusel div
{
	position:absolute;
	top:0px;
	left:0px;
}

#bannerad
{
	width:728px;
	height:90px;
	float:right;
}

#banneradouter
{
	position:absolute;
	top:10px;
	right:0px;
	left:170px;
	height:90px;
	margin-right:10px;
	overflow:hidden;
}

#rightad
{
	position:absolute;
	top:110px;
	right:0px;
	margin-right:10px;
	width:160px;
	height:600px;
}

#maintext
{
	margin:110px 180px 10px 170px;
	min-height:600px;
	padding:2px;
}

#footer
{
	border-style:solid;
	margin-top:0px;
	padding: 10px;
	clear: both;
	overflow:hidden;
}

#copyright
{
	padding: 10px;
	Font-Size: 65%;
	text-align: center;
}

@media all and (max-width: 907px) 
{
/* move left menu down */
	#menu
	{
		margin-top:110px;
	}
	#banneradouter
	{
		left:5px;
	}
	#bannerad
	{
		float:left;
	}
}


@media all and (max-width: 764px) 
{
/* remove padding between main elements */
	#sitebody div
	{
		border-radius:0px;
	}
	#banneradouter
	{
		top:0px;
		right:0px;
		left:0px;
		margin-right:0px;
		width:inherit;
	}

	#menu
	{
		margin: 0px;
		margin-top:90px;
	}

	#menuad
	{
		margin:0px;
	}

	#rightad
	{
		top:90px;
		right:0px;
		margin-right:0px;
	}
	#maintext
	{
		margin:90px 160px 0px 152px;
	}
}

@media all and (max-width: 700px) 
{
/* move menu to top, disable small ad unit, change top banner ad to smaller size */
	.menumore:before,
	#searchbox:before
	{
		content:""; /*for early iOS*/
		content:none;
	}
	#searchform
	{
		float:right;
	}
	#bannerad
	{
		width:468px;
		height:60px;
	}
	#banneradouter
	{
		height:60px;
	}
	#topright
	{
		display:none;
	}
	#rightad
	{
		top:96px;
	}
	.menu1
	{
		display:none;
	}
	.menu2
	{
		display:inline;
	}
	#menu
	{
		position:relative;
		border-width:0px;
		width: 100%;
		height:36px;
		margin:0px;
		margin-top:60px;
		padding: 0px;
		overflow:hidden;
		background:none;
		z-index:1;
	}
	#menugrad, #menugrad2
	{
		position:absolute;
		top:0px;
		left:0px;
		width: 100%;
		height:36px;
	}
	#menu ul
	{
		list-style:none;
		padding:0px;
		margin:0px;
		margin-left:0px;
		z-index:100;
	}
	#menu ul li
	{
		display: block;
		position: relative;
		float: left;
		border-left-width:1px;
		padding:0px;
		text-align:center;
		margin:0px;
		clear:none;
		text-indent:0px;
		font-size:95%;
	}
	#menu ul li a
	{
		position:relative;
		display: block;
		padding: 10px;
		height: 16px;
	}
	#menu ul:first-of-type li:first-of-type
	{
		border-left-width:0px;
	}
	#menu ul:last-of-type li:last-of-type
	{
		border-right-width:1px;
	}
	#menusel div
	{
		width:100%;
		height:100%;
	}
	#maintext
	{
		margin:96px 160px 0px 0px;
	}
	#menuad
	{
		position:absolute;
		left:-500px;
	}
}

@media all and (max-width: 620px) 
{
/* convert right-hand column ad to banner above the footer */
	#maintext
	{
		margin-right:0px;
		min-height:100px;
	}
	#rightad
	{
		position:relative;
		top:0px;
		left:0px;
		margin:0px;
		width:100%;
		height:101px;
		float:right;
		overflow:hidden;
	}
}

@media all and (max-width: 580px) 
{
/* spread horizontal menu over two lines */
	#menu
	{
		height:72px;
	}
	#menu ul li
	{
		border-right-width:1px;
		border-left-width:0px;
		border-bottom-width:1px;
	}
	#menugrad
	{
		height:72px;
	}
	#maintext
	{
		margin:132px 0px 0px 0px;
	}
	#logo
	{
		display:none;
	}
	#title
	{
		left:10px;
	}
	#topbar H1
	{
		Font-Size: 160%;
	}
	#topbar H2
	{
		Font-Size: 110%;
	}
	#searchform
	{
		margin-bottom:36px;
	}
}
