// ruraq
var ison;
function calib(){
	
	var tempp = '<table width="50" align="center" cellspacing="0" cellpadding="0" class="bars" style="border:0px">';
	tempp+= '<tr onMouseOver="isStat()">';
	tempp+= '<td width="11px" style="height:4px;background-color:#B0B0B0" onMouseOver="this.style.backgroundColor='+"'#FF0000'"+';yy()" onMouseOut="this.style.backgroundColor='+"'#B0B0B0'"+';ison=null;"></td>';
	tempp+= '<td width="11px" style="background-color:#FFFFFF" onMouseOver="this.style.backgroundColor='+"'#FF0000'"+';xx()" onMouseOut="this.style.backgroundColor='+"'#FFFFFF'"+';ison=null;"></td>';
	tempp+= '<td width="11px" style="background-color:#000000" onMouseOver="this.style.backgroundColor='+"'#FF0000'"+';xy()" onMouseOut="this.style.backgroundColor='+"'#000000'"+';ison=null;"></td>';
	tempp+= '<td width="11px" style="background-color:#B0B0B0" onMouseOver="this.style.backgroundColor='+"'#FF0000'"+';yy()" onMouseOut="this.style.backgroundColor='+"'#B0B0B0'"+';ison=null;"></td>';
	tempp+= '</tr>';
	tempp+= '</table>';
	//document.getElementById("calib-dots").innerHTML = tempp;
	document.writeln(tempp);
}

function isStat(){
	if(document.getElementById('status')){statusIn(unescape('%B7%20\u2039%20%A0')+'RURAQ LIGHTS'+unescape('%A0%20\u203A%20%B7'));}
}

function xx(){
	ison = true;
	if((document.cookie.indexOf('ruraq')==-1))return; //si no existe cook es blanco, clarines
setTimeout(function(){if(ison)selectStyle('ruraq', 'ruraq-yuraq');checkiframes();opera();},200);
}

function yy(){
	ison = true;
	if(readCookie('ruraq')=='ruraq-uqi')return;
setTimeout(function(){if(ison)selectStyle('ruraq', 'ruraq-uqi');checkiframes();opera()},200);
}

function xy(){
	ison = true;
	if(readCookie('ruraq')=='ruraq-yana')return;
setTimeout(function(){ if(ison)selectStyle('ruraq', 'ruraq-yana');checkiframes();opera()},200);

}

// CHECK IFRAME IN INTRO.PHP TO MATCH THE COLOR
function checkiframes(){
	//if(document.getElementById('framis')){document.getElementById('framis').src = document.getElementById('framis').src;}
	color = readCookie('ruraq')
	if (color == undefined)color = 'ruraq-yuraq';
	if (window.frames.framis){window.frames.framis.selectStyle('ruraq', color);}
}

calib()