d = document;
var inf3
var mow
var moh
var dirloc
var filnm
var ftype
var mov
var moviestring
var movieflag=true
function loadwin() {
moviestring='<html><body bgcolor=\"#000000\"></body></html>';
window.movframe.document.open("text/html");
window.movframe.document.write(moviestring);
window.movframe.document.close();
}

function getmovie(movie, me) {
	if (movieflag==true) {
loadwin()
d.getElementById('movframe').style.borderColor='#ffffff';
var loc=this.location.href;/////parsing out Location Section Name
from=loc.lastIndexOf('/')+1;
to=loc.lastIndexOf('.html');
dirloc=loc.slice(from,to);

fr2=movie.lastIndexOf('x')-3;/////parsing out movie W x H
to2=movie.lastIndexOf('x');
frm=movie.lastIndexOf('x')+1;
toh=movie.lastIndexOf('.');
mov=movie;
moh=Number(movie.slice(frm,toh));//height
mow=movie.slice(fr2,to2);//////////width

ps2 =movie.lastIndexOf('x')+4;
filnm=movie.slice(0,ps2);
filstr='assets/'+dirloc+'/'+filnm;

ft1 =movie.lastIndexOf('x')+5;
ftype=movie.slice(ft1,movie.length);


	if (ftype=='swf')
	{
	mow/=2;
	moh/=2;
	}else{moh+=16;}

//if (mow<=190)/////////////////if the movie is narrow add right margin
//{d.getElementById('movframe').style.marginRight=mow+'px';}
//else{d.getElementById('movframe').style.marginRight='10px';}


//  gets no initial width value :
//  alert(d.getElementById('movframe').style.width.replace(/px/,""))
if (mow<d.getElementById('movframe').style.width.replace(/px/,""))//sets the expansion/contraction 
{w="-"}else{w="+"}
if (moh<d.getElementById('movframe').style.height.replace(/px/,""))
{h="-";}else{h="+";}

G=5

//remw=moh-d.getElementById('movframe').style.height.replace(/px/,"")
//remh=mow-d.getElementById('movframe').style.width.replace(/px/,"")

if (moh>mow)
	{gr=moh;sm=mow;}
	else
	{sm=moh;gr=mow;}
x = 1/(sm/gr)
if (moh<mow)
	{rat=(x*G).toPrecision(2)+':'+(1*G)}
	else
	{rat=(1*G)+':'+(x*G).toPrecision(2)}

wh=w+h+'_'+rat;

	theID = me;
	d.getElementById("info2").innerHTML=inf3;//description
	d.getElementById('preinfo').innerHTML="";
	d.getElementById('popinfo').innerHTML=d.getElementById('poptime').innerHTML;
	timepop(me, "popinfo")

		if (ftype=='swf')
		{
		
		
		
		}else{
		 moviestring='<html><body style=margin:0; bgcolor=\"#000000\">'+
		'<OBJECT WIDTH='+mow+' HEIGHT='+(moh)+' ID=movieX>'+
					'<PARAM Name=Autoplay Value=true>'+
					'<PARAM NAME=src VALUE=assets/'+dirloc+'/'+movie+'>'+
					'<PARAM NAME=loop VALUE=false>'+
					'<PARAM NAME=controller VALUE=true>'+
					'<PARAM NAME=bgcolor VALUE=#000000>'+
			   '<EMBED WIDTH='+mow+' HEIGHT='+(moh)+' SRC=assets/'+dirloc+'/'+movie+' TYPE=video/quicktime NAME=movieX EnableJavaScript=true BGCOLOR=#000000 CONTROLLER=true Autoplay=true loop=false PLUGINSPAGE=http://quicktime.apple.com/quicktime/>'+
				   '</OBJECT>'+
					'</body></html>';
		}

d.getElementById('option1').innerHTML = '<div class=\"optbuts\">&nbsp;</div>'
movieflag=false
frmanme = setInterval('frameanime(wh)',1)	
}
}

function frameanime(wh)///////////////////////////animates the movie frame size //////////////////////////////////////
{
rat1 = Number(wh.slice(wh.indexOf('_')+1,wh.indexOf(':')))
rat2 = Number(wh.slice(wh.indexOf(':')+1,wh.length))
	if (d.getElementById('movframe').style.height.replace(/px/,"")==moh && d.getElementById('movframe').style.width.replace(/px/,"")==mow)
		{
		clearInterval(frmanme)
		movieflag=true
		if (ftype=='swf')
			{
			ifstr='ac1.html?'+mov
			window.open(ifstr, 'movframe')
			}else{
			window.movframe.document.open("text/html");
			window.movframe.document.write(moviestring);
			window.movframe.document.close();	
			}
		d.getElementById('option1').style.top="21px";
		d.getElementById('option1').style.right=(Number(d.getElementById('movframe').style.marginRight.replace(/px/,''))+40)+"px";
		d.getElementById('option1').style.display='block';
		if (ftype=='swf')
			{d.getElementById('option1').innerHTML = "&nbsp;";// '<div onClick=\"context()\" class=\"optbuts\" onMouseOver=\"this.style.cursor=\'pointer\';\">View in Context</div>'
			}else{d.getElementById('option1').innerHTML = '<div onClick=\"larger()\" class=\"optbuts\" onMouseOver=\"this.style.cursor=\'pointer\';\">View @ 2x Size</div>'}
		return
		}
if (wh.slice(0,1)=='+')
{
	if (d.getElementById('movframe').style.width.replace(/px/,"")<mow) 
	{d.getElementById('movframe').style.width=(Number(d.getElementById('movframe').style.width.replace(/px/,''))+rat1)+"px";}
	 else {d.getElementById('movframe').style.width=mow+"px";}
}else if (wh.slice(0,1)=='-'){
	if (d.getElementById('movframe').style.width.replace(/px/,"")>mow) 
	{d.getElementById('movframe').style.width=(Number(d.getElementById('movframe').style.width.replace(/px/,''))-rat1)+"px";}
	else{d.getElementById('movframe').style.width=mow+"px";}
}
if (wh.slice(1,2)=='+')
{
	if (d.getElementById('movframe').style.height.replace(/px/,"")<moh) 
	{d.getElementById('movframe').style.height=(Number(d.getElementById('movframe').style.height.replace(/px/,''))+rat2)+"px";}
	else{ d.getElementById('movframe').style.height=moh+"px";}
}else if (wh.slice(1,2)=='-'){
	if (d.getElementById('movframe').style.height.replace(/px/,"")>moh) 
	{d.getElementById('movframe').style.height=(Number(d.getElementById('movframe').style.height.replace(/px/,''))-rat2)+"px";}
	else{d.getElementById('movframe').style.height=moh+"px";}
}
}


function highlight(hot)
{zq=d.getElementsByName('img');//delivers name attribute for the pages: "img" the list is zq
  for (i=0;i<=zq.length-1;i++)
  { 
	if (zq[i].id != hot) 
	{
	d.getElementById(zq[i].id).className = "icons"
	}else{
	d.getElementById(hot).className = "iconsHot"
  	}
  }
}


//function larger() {
//window.movframe.document.movieX.Stop()
//
//wid=mow*2
//hei=(moh-16)*2
//numov=mov.replace(mow,wid).replace(moh-16,hei)
//
////moh=Number(movie.slice(frm,toh));//height
////mow=movie.slice(fr2,to2);//////////width
//
//var moviestring='<html><body style=\"margin:0px;\" bgcolor=\"#000000\">'+
//		'<OBJECT WIDTH=\"'+(mow*2)+'\" HEIGHT=\"'+(moh*2)+'\" ID=\"movieY\">'+
//					'<PARAM Name=\"Autoplay\" Value=\"true\">'+
//					'<PARAM NAME=\"src\" VALUE=\"assets/'+dirloc+'/'+numov+'\">'+
//					'<PARAM NAME=\"loop\" VALUE=\"false\">'+
//					'<PARAM NAME=\"controller\" VALUE="true\">'+
//					'<PARAM NAME=\"bgcolor\" VALUE=\"#000000\">'+
//			   '<EMBED WIDTH=\"'+(mow*2)+'\" HEIGHT=\"'+(moh*2)+'\" SRC=\"assets/'+dirloc+'/'+numov+'\" TYPE=\"video/quicktime\" NAME=\"movieY\" EnableJavaScript=\"true\" BGCOLOR=\"#000000\" CONTROLLER=\"true\" Autoplay=\"true\" loop=\"false\" PLUGINSPAGE=\"http://quicktime.apple.com/quicktime/\">'+
//				   '</OBJECT>'+
//					'</body></html>';
//mywin=window.open('','','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,copyhistory=no,width='+ (mow*2) +',height='+ (moh*2) );
//mywin.document.write(moviestring);
//mywin.focus()
//
////window.movframe.document.close();
////if (!PopupWindow.opener)
//// PopupWindow.opener = self;
//}


//function increment(me)//checks for the end of the video and replaces it with the default video
//{
//////d.getElementById("info").innerHTML= d.movieX.GetTime() +'_'+ d.movieX.GetEndTime();  <-shows current time vs. total time in a text area
//	if (d.movieX.GetTime() == d.movieX.GetEndTime())
//	{
		//d.movieX.SetIsLooping(true)
//	clearInterval(int);
//	d.movieX.SetURL("base.mov");	
		//if (d.movieX.GetTime() == d.movieX.GetEndTime())
		//{d.movieX.Stop()}
//	d.getElementById(me).className = "icons"
//	d.getElementById("info3").style.top='-1000px'
//	d.getElementById("info1").innerHTML="&nbsp;";
//	d.getElementById("info2").innerHTML="&nbsp;";
//	}
//}
function timepop(me, n)
{
	d.getElementById(n).style.left=d.getElementById(me).style.left;
	d.getElementById(n).style.top=d.getElementById(me).style.top;	
}






var movie;
function twoX(me, thee) {
var meNum = me.replace(/Vid/,"");
movie = d.getElementById(me);
if (movie.style.width == "400px") {
		var newVid = movie.currentSrc.replace(/400x300/,"640x480");
		movie.src = newVid;
		movie.style.width="640px";
		movie.style.height="480px";
		thee.innerHTML = "Normal Size";
		thee.style.backgroundImage="url(assets/1x.png)";
		d.getElementById('inf'+meNum).childNodes[1].style.backgroundImage="url(assets/pause.png)";
		d.getElementById('inf'+meNum).childNodes[1].innerHTML = "Pause Video";
		movie.load();
		movie.play();
	} else {
		var newVid = movie.currentSrc.replace(/640x480/,"400x300");
		movie.src = newVid;
		movie.style.width="400px";
		movie.style.height="300px";
		thee.innerHTML = "Full Size";
		thee.style.backgroundImage="url(assets/2x.png)";
		d.getElementById('inf'+meNum).childNodes[1].style.backgroundImage="url(assets/pause.png)";
		d.getElementById('inf'+meNum).childNodes[1].innerHTML = "Pause Video";
		movie.load();
		movie.play();
		}
}


t = window.setInterval(function() { ///polling timer for play pause ended
		if (rolHist) {
			var N = rolHist.replace(/pre/,"");
			if (d.getElementById('inf'+N)) {
				var inf = d.getElementById('inf'+N).childNodes[1];
			
			if (!movie) {
				var mo = 'Vid'+N;
				movie = d.getElementById(mo);
			}
			if (movie) {
				if (movie.paused == true || movie.ended == true) {
					if (inf.innerHTML !== "Play Video") {
						inf.innerHTML = "Play Video";
						inf.style.backgroundImage="url(assets/play.png)";
						}	
				} else {
					if (inf.innerHTML !== "Pause Video") {
						inf.innerHTML = "Pause Video";
						inf.style.backgroundImage="url(assets/pause.png)";
						}
					}
				}
			}
		}
	},1000);



function  Vcon(me) {
	movie = d.getElementById(me);
var inf = 'inf'+me.replace(/Vid/,"");
if (movie.paused) {
	movie.play();
	d.getElementById(inf).childNodes[1].innerHTML = "Pause Video";
	d.getElementById(inf).childNodes[1].style.backgroundImage="url(assets/pause.png)";
	} else {
	movie.pause();
	d.getElementById(inf).childNodes[1].innerHTML = "Play Video";
	d.getElementById(inf).childNodes[1].style.backgroundImage="url(assets/play.png)";
	//movie="";
	}
}


rolHist="";
samp=true;
function roll(me) {
//d.getElementById(me).style.cursor='pointer';
var currentId = me.replace(/mmg/,"pre");
var CURRID = d.getElementById(currentId);
if (rolHist != currentId) {	
if (samp==true) {
	samp=false;
	//inf4=dat.substring(0, dat.indexOf(':')+3);
	//inf5=dat.substring(dat.indexOf(':')+3, dat.indexOf('_'));
	//inf3=dat.substring(dat.indexOf(':')+3, dat.length).replace(/_/, " ");
//	timepop(me, 'poptime');
		
		//CURRID.style.top="12px";
		//CURRID.style.right="50px";
		
		if (movie) {
			movie.pause();
			var infNum = movie.id.replace(/Vid/,"inf")
			d.getElementById(infNum).childNodes[1].innerHTML = "Play Video";
			d.getElementById(infNum).childNodes[1].style.backgroundImage="url(assets/play.png)";
			movie="";
			}
		
		
		//CURRID.style.backgroundColor="#777777";
		//CURRID.style.borderTop="#999999 solid 1px";
		//CURRID.style.borderLeft="#999999 solid 1px";
		//d.getElementById(currentId).childNodes[0].style.backgroundColor="#003300";
		//d.getElementById(currentId).innerHTML='<div class="underHot"></div><div style="font-size:20px;color:#ffffff;background-color:#555555;padding:2px;">'+inf5+'</div><img src="assets/samp'+currentId.replace(/pre/,"")+'.png" align="right" width="320" height="240"><div style="font-size:14px;width:150px;padding:4px;">'+inf3+"</div>"+'<iframe frameborder="0" id="movframe" name="movframe" class="movieframe" scrolling="no" marginwidth="0" marginheight="0"></iframe>';
		//CURRID.childNodes[0].style.backgroundColor="#777777";
		//CURRID.childNodes[0].style.borderTop="#999999 solid 1px";
		//CURRID.childNodes[0].style.borderLeft="#999999 solid 1px";
		
		//d.getElementById(currentId).childNodes[0].style.boxShadow="30px 30px 25px #000000";
		//d.getElementById(currentId).childNodes[0].style.display="block";
		
		//CURRID.childNodes[0].style.top=80*me.replace(/mmg/,"")-1+"px";
		//CURRID.style.boxShadow="25px 35px 20px #000000";
		//CURRID.childNodes[4].id="movframe";
		CURRID.style.top="12px";
		CURRID.style.zIndex="8";
		//CURRID.style.display='block';
		d.getElementById(me).style.border="#ffffff solid 1px";
		d.getElementById(me).style.boxShadow="2px 2px 2px #000000";
		if (rolHist) {
			var resrol = rolHist.replace(/pre/,"mmg");
			d.getElementById(resrol).style.border="transparent solid 1px";
			d.getElementById(resrol).style.boxShadow="none";
			}
		var t3 = new parent.OpacityTween(CURRID,parent.Tween.strongEaseOut,0,100,.75);
		var	t4 = new parent.Tween(CURRID.style,'left', parent.Tween.strongEaseOut,0,130,.75,'px');
		var	par1 = new parent.Parallel();
		par1.addChild(t3);
		par1.addChild(t4);
		if (rolHist) {
			
			d.getElementById(rolHist).style.zIndex="4";
			var t8 = new parent.OpacityTween(d.getElementById(rolHist),parent.Tween.strongEaseOut,100,0,.75);
		//	var	t9 = new parent.Tween(d.getElementById(rolHist).style,'top', parent.Tween.regularEaseOut,12,50,.5,'px');
			par1.addChild(t8);
			//par1.addChild(t9);
			}
		par1.start();
		par1.onMotionFinished = function() {
			//d.getElementById(rolHist).style.display='none';
			rolHist = currentId;
			
			samp = true;
			}
	}
}
}
function hide() {
	if (rolHist && samp == true) {
		var resrol = rolHist.replace(/pre/,"mmg");
			d.getElementById(resrol).style.border="transparent solid 1px";
			d.getElementById(resrol).style.boxShadow="none";
		samp = false;
	var tHc = new parent.OpacityTween(d.getElementById(rolHist),parent.Tween.strongEaseOut,100,0,.75);
		tHc.start();
		rolHist = '';
		tHc.onMotionFinished = function() {
			samp = true;
			}
		}
	}






//if(document.location.href.match('video.html') != null)
//	{
//	alert(document.location.href)
//	}
//d.getElementById('preinfo').style.visibility="hidden"
//d.getElementById(me).style.border="2px solid #000000";
////////////////////from old index/////////////////////////////////////////////////
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() {
siz();
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}
function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

//var hinscale = null
//var hinsz = null
//var winscale = null
//var winsz = null
//var bgloc = null
//var browser=navigator.appName;

function goto() {
bgloc = winsz/2;
winscale = winsz-160;

d.body.style.backgroundPosition=bgloc+"px";
d.body.style.backgroundImage="url(assets/btile.gif)";
d.getElementById('pg1').style.backgroundColor="transparent";
intslide = setInterval("slide()",1);
d.getElementById('ringneg').style.display="inline";
d.getElementById('rollring').style.display="none";
}
function slide()
{
	if (bgloc >= 10) {
	d.body.style.backgroundPosition=(bgloc-=30)+"px";
	}else{
	clearInterval(intslide);
	d.body.style.backgroundImage="url(assets/btile2.jpg)";
	//d.body.style.backgroundColor="#565624";
	d.body.style.backgroundPosition="-280px 0px";
	d.body.style.backgroundRepeat="repeat-y";
	d.getElementById('underight1').style.backgroundImage="url(assets/btile2.jpg)";
	//d.body.style.backgroundPosition="20px";
	d.getElementById('pg2').style.display="block";
	d.getElementById('nam').style.fontSize="14px";
	d.getElementById('ema').style.fontSize="10px";
	d.getElementById('nam').style.display="inline";
	d.getElementById('ema').style.display="inline";
	d.getElementById('ringneg').style.display="none";
	intshapeup = setInterval('shapeup()',75);
		for (i=1;i<=MenuLoopCt;i++) {//// de hard code me :
		d.getElementById('p'+i).style.width=(winscale)+'px';
		}
		intbutt = setInterval('buttup()',20);

}
}
function buttup()////    /////  first button stretch   ///////   ///////
{ 
 	if (winscale >= 100) { 
		for (q=1;q<=MenuLoopCt;q++) {
			d.getElementById('p'+q).style.width=(winscale-=20)+'px';
		}
	}else{
		for (r=1;r<=MenuLoopCt;r++) {
			d.getElementById('p'+r).style.width='90px';
		}
	clearInterval(intbutt);
	winscale = winsz-190
	}
}
var shapeLoop = 0
function shapeup(){
	switch(shapeLoop){
case 0:
var itemz = "p"+ MenuLoopCt;
	d.getElementById('shape2').style.backgroundImage="url(assets/frsk.png)";
	d.getElementById('shape2').style.backgroundPosition="250px -70px";
//	d.getElementById('shape1').style.backgroundImage="url(assets/frsk.png)";
//	d.getElementById('shape1').style.backgroundPosition="300px 300px";

	zip(itemz)
	d.getElementById('shape2').style.display="inline";
	d.getElementById('shape2').style.borderColor="#5f584d";
	d.getElementById('shape2').style.height="50px";
	d.getElementById('shape2').style.width="500px";
	d.getElementById('shape2').style.top="155px";////////////////////////////////////////
	d.getElementById('shape2').style.left="-50px";
	d.getElementById('shape1').style.display="inline";
	//d.getElementById('shape1').style.backgroundColor="transparent";
	d.getElementById('shape1').style.border="1px #000000 solid";
	//d.getElementById('shape1').style.left=(winsz-100)+"px";
	d.getElementById('shape1').style.left="450px";
	d.getElementById('shape1').style.width="10px";
	d.getElementById('shape1').style.height="23px";
	d.getElementById('shape1').style.top="50px";////////////////////////////////////////	
	shapeLoop++
	break; 
case 1:
	shapeLoop++
	d.getElementById('shape2').style.backgroundPosition="250px -71px";
	break; 
case 2:
	d.getElementById('shape1').style.background="transparent";
	d.getElementById('shape1').style.border="1px #ffffff solid";
	d.getElementById('shape1').style.height="90px";
	d.getElementById('shape1').style.width="600px";
	d.getElementById('shape1').style.top="50px";
	d.getElementById('shape1').style.left="57px";	
	d.getElementById('shape2').style.backgroundPosition="250px -72px";
	shapeLoop++
	break;
case 3:
	zip("p2")
	d.getElementById("shape1").style.display='inline';
	d.getElementById("shape1").style.height='10px';
	d.getElementById("shape1").style.width='600px';
	d.getElementById("shape1").style.top="50px";
	
	shapeLoop++
	break;
case 4:
	d.getElementById('shape1').style.border="1px #ffffff solid";
	d.getElementById('shape1').style.height="30px";
	d.getElementById('shape1').style.width="70px";
	d.getElementById("shape1").style.left='357px';
	d.getElementById('shape2').style.backgroundPosition="250px -73px";
	shapeLoop++
	break;
case 5:
	d.getElementById('smltxt').innerHTML = "&nbsp";
	d.getElementById('smltxt').style.border="none";
	d.getElementById('shape1').style.height="100px";
	d.getElementById('shape1').style.width="50px";
	d.getElementById("shape1").style.left='257px';
	
	shapeLoop++
	break; 
case 6:
	d.getElementById("shape1").style.left='100px';
	d.getElementById("shape1").style.height='100px';
	d.getElementById("shape1").style.width='100px';
	d.getElementById("shape1").style.top='60px';////////////////////////////////
	d.getElementById('shape2').style.backgroundPosition="250px -74px";
	shapeLoop++
	break;
case 7:
	d.getElementById('shape1').style.top="40px";////////////////////////////////
	d.getElementById('shape1').style.width="90px";
	d.getElementById('shape1').style.height="50px";	
	d.getElementById('shape1').style.left="15px";	
	d.getElementById('shape2').style.backgroundPosition="250px -75px";
	shapeLoop++
	break;
case 8:
	clearInterval(zint);
	clearInterval(intshapeup);
	d.getElementById('shape2').style.display="none";
	d.getElementById('shape1').style.top="30px";////////////////////////////////
	d.getElementById('shape1').style.width="90px";
	d.getElementById('shape1').style.height="30px";	
	d.getElementById('shape1').style.left="15px";
	shapeLoop = 0
		d.getElementById('shape2').style.backgroundImage="none";//"url(assets/videoBg.png)";
		d.getElementById('shape2').style.backgroundPosition="0px 0px";
	break;
	}
}



var spinkloop = 0;
function twink2() {//spark1()////    ///// text TWINKLE///   ///////
spink=setInterval('sparkle(spinkloop)',500);
}
function sparkle() {////    ///// text TWINKLE///   ///////
switch(spinkloop)
	{
case 0:
	d.getElementById('smltxt').style.backgroundColor="#000000";
	spinkloop++
	break;
case 1:
	d.getElementById('smltxt').style.backgroundColor="transparent";
	d.getElementById('txt4').style.color="ffffff";
	spinkloop++
	break;
case 2:
	d.getElementById('txt4').style.color="000000";
	spinkloop++
	break;
case 3:
	clearInterval(spink);
	spink2();
	spinkloop=0;
	break;
	}
}



var t = true;
var r = 255;
var g = 255;
var b = 255;


function twink1() {
	//alert("");////    ///// text TWINKLE///   ///////
	if (t !== false) {	
	
		if (d.getElementById('box').style.display !== "none") {
			
		r=255, g=255, b=255;
		d.getElementById('txt3').style.color="rgb(0,0,0)";
		twink=setInterval('twinkle()',50);
		t = false;
		}
	}
}


function twinkle() { 
 	if (r >= 10) {
	d.getElementById('txt3').style.color="rgb("+(r-=12)+','+(g-=12)+','+(b-=8)+")";
	}else {
	clearInterval(twink);
	t=true;
	d.getElementById('txt3').style.color="rgb(0,0,0)";
	}
} 
