mac=(navigator.appVersion.indexOf('Mac')!=-1)?true:false;
ie=(navigator.appName.charAt(0)=="M")?true:false;

document.write("<STYLE TYPE='text/css'><!--");
if(mac){
	if(ie){
		//Macintosh版IE用の記述
		document.write(".t1{font-Size:12px;line-height:16px}");
		document.write(".t2{font-Size:12px;line-height:16px}");
		document.write(".t3{font-Size:10px;line-height:14px}");
		document.write(".t4{font-Size:9px}");
		document.write(".t1w{font-Size:10px;line-height:14px;letter-spacing:1px}");
		document.write(".t2w{font-Size:12px;line-height:16px; letter-spacing:1px}");
	}
	else{
		//Macintosh版Neとその他用の記述
		document.write(".t1{font-Size:12px;line-height:17px}");
		document.write(".t2{font-Size:12px;line-height:17px}");
		document.write(".t3{font-Size:10px;line-height:15px}");
		document.write(".t4{font-Size:9px}");
		document.write(".t1w{font-Size:10px;line-height:15px;letter-spacing:1px}");
		document.write(".t2w{font-Size:12px;line-height:17px; letter-spacing:1px}");
	}
}
else{
		//Win版IE用の記述
	if(ie){
		document.write(".t1{font-Size:12px;line-height:17px}");
		document.write(".t2{font-Size:12px;line-height:17px}");
		document.write(".t3{font-Size:11px;line-height:15px}");
		document.write(".t4{font-Size:10px}");
		document.write(".t1w{font-Size:11px;line-height:15px;letter-spacing:1px}");
		document.write(".t2w{font-Size:12px;line-height:17px; letter-spacing:1px}");
	}
	else{
		//Win版Neとその他の用の記述
		document.write(".t1{font-Size:12px;line-height:18px}");
		document.write(".t2{font-Size:12px;line-height:18px}");
		document.write(".t3{font-Size:11px;line-height:16px}");
		document.write(".t4{font-Size:10px}");
		document.write(".t1w{font-Size:11px;line-height:16px;letter-spacing:1px}");
		document.write(".t2w{font-Size:12px;line-height:18px; letter-spacing:1px}");
	}	
}
document.write("--></STYLE>");

//ロードスター
var vNum = navigator.appVersion.charAt(0);
var bName = navigator.appName.charAt(0);
function openRoadster()
{
	if(navigator.appVersion.indexOf("Mac") > -1)
	{
		if( bName == "M")
		{
			// MAC IE
			openWin(784,588)
		}
		else
		{
			if( vNum < 5 )
			{
				// MAC NETSCAPE 4.x
				openWin(800,600)
	 		}
	 		else
	 		{
				// MAC NETSCAPE 6.x~
				openWin(800,600)
	 		}
	 	}
	}
	else
	{
		if( bName == "M")
		{
			// WIN IE
			openWin(800,600)
		}
		else
		{
			if( vNum < 5 )
			{
				// WIN NETSCAPE 4.x
				openWin(800,600)
			}
			else
			{
				// WIN NETSCAPE 6.x~
				openWin(800,600)
			}
		}
	}
}
function openWin(winWidth,winHeight)
{
	window.open('http://www.smart-j.com/roadster/index.html','roadster','width='+winWidth+',height='+winHeight+',left='+(Math.round(screen.availWidth-800)/2)+',top='+(Math.round(screen.availHeight-600)/3))
}
//roadster final edition
function openFinal()
{
	if(navigator.appVersion.indexOf("Mac") > -1)
	{
		if( bName == "M")
		{
			// MAC IE
			openWin_final(784,588)
		}
		else
		{
			if( vNum < 5 )
			{
				// MAC NETSCAPE 4.x
				openWin_final(800,600)
	 		}
	 		else
	 		{
				// MAC NETSCAPE 6.x~
				openWin_final(800,600)
	 		}
	 	}
	}
	else
	{
		if( bName == "M")
		{
			// WIN IE
			openWin_final(800,600)
		}
		else
		{
			if( vNum < 5 )
			{
				// WIN NETSCAPE 4.x
				openWin_final(800,600)
			}
			else
			{
				// WIN NETSCAPE 6.x~
				openWin_final(800,600)
			}
		}
	}
}
function openWin_final(winWidth,winHeight)
{
	window.open('http://www.smart-j.com/lineup/roadster/final/index.html','final','width='+winWidth+',height='+winHeight+',resizable=yes,scrollbars=yes,location=no,menubar=no')
}

//クロスブレード
function opencrossb()
{
	if(navigator.appVersion.indexOf("Mac") > -1)
	{
		if( bName == "M")
		{
			// MAC IE
			openWin2(640,500)
		}
		else
		{
			if( vNum < 5 )
			{
				// MAC NETSCAPE 4.x
				openWin2(640,500)
	 		}
	 		else
	 		{
				// MAC NETSCAPE 6.x~
				openWin2(640,500)
	 		}
	 	}
	}
	else
	{
		if( bName == "M")
		{
			// WIN IE
			openWin2(640,500)
		}
		else
		{
			if( vNum < 5 )
			{
				// WIN NETSCAPE 4.x
				openWin2(640,500)
			}
			else
			{
				// WIN NETSCAPE 6.x~
				openWin2(640,500)
			}
		}
	}
}
function openWin2(winWidth,winHeight)
{
	window.open('http://www.smart-j.com/cb/index.html','cb','width='+winWidth+',height='+winHeight+',left='+(Math.round(screen.availWidth-640)/2)+',top='+(Math.round(screen.availHeight-500)/3))
}

//フォ−フォー
function openforfour()
{
	if(navigator.appVersion.indexOf("Mac") > -1)
	{
		if( bName == "M")
		{
			// MAC IE
			openWin3(800,600)
		}
		else
		{
			if( vNum < 5 )
			{
				// MAC NETSCAPE 4.x
				openWin3(800,600)
	 		}
	 		else
	 		{
				// MAC NETSCAPE 6.x~
				openWin3(800,600)
	 		}
	 	}
	}
	else
	{
		if( bName == "M")
		{
			// WIN IE
			openWin3(800,600)
		}
		else
		{
			if( vNum < 5 )
			{
				// WIN NETSCAPE 4.x
				openWin3(800,600)
			}
			else
			{
				// WIN NETSCAPE 6.x~
				openWin3(800,600)
			}
		}
	}
}
function openWin3(winWidth,winHeight)
{
	window.open('http://www.smart-j.com/forfour/index.html','forfour','width='+winWidth+',height='+winHeight+',left='+(Math.round(screen.availWidth-800)/2)+',top='+(Math.round(screen.availHeight-600)/3))
}

//スマートカフェ
function opencafe()
{
	window.open('http://www.smart-j.com/cafe/index.html','cafe','width=800,height=600,scrollbars=yes,resizable=yes,toolbar=yes,location=yes,status=yes')
}
function opencafe2()
{
	window.open('http://www.smart-j.com/cafe/demo/index.html','cafe','width=800,height=600,scrollbars=yes,resizable=yes,toolbar=yes,location=yes,status=yes')
}
function opencafe3()
{
	window.open('http://www.smart-j.com/cafe/world/index.html','cafe','width=800,height=600,scrollbars=yes,resizable=yes,toolbar=yes,location=yes,status=yes')
}
function opencafe4()
{
	window.open('http://www.smart-j.com/cafe/gallery/index.html','cafe','width=800,height=600,scrollbars=yes,resizable=yes,toolbar=yes,location=yes,status=yes')
}
function opencafe5()
{
	window.open('http://www.smart-j.com/cafe/topic/index.html','cafe','width=800,height=600,scrollbars=yes,resizable=yes,toolbar=yes,location=yes,status=yes')
}
function opencafe6()
{
	window.open('http://www.smart-j.com/cafe/d_gift/index.html','cafe','width=800,height=600,scrollbars=yes,resizable=yes,toolbar=yes,location=yes,status=yes')
}
//ロードスターインテリア
function rpop01()
{
	window.open('pop01.html','popWindow','width=500,height=350,scrollbars=no,resizable=no,toolbar=no,location=no,status=no')
}
function rpop02()
{
	window.open('pop02.html','popWindow','width=500,height=350,scrollbars=no,resizable=no,toolbar=no,location=no,status=no')
}
//ENGLISH
function openenglish()
{
	window.open('http://www.smart-j.com/e/index.html','english','width=660,height=485,scrollbars=yes,resizable=yes,toolbar=yes,location=yes,status=yes')
}

//ヒストリー
function openhistory()
{
	window.open('http://www.smart-j.com/brand/history.html','history','width=800,height=486,scrollbars=no,resizable=yes,toolbar=no,location=no,status=no')
}


