/********************************************************************
 *     Laat de tekst langzaam opkomen van oranje naar wit. 			*
 *                                                                  *
 ********************************************************************/

loop = "up";

function fading_text() { 

	if (document.getElementById('fading_text')) {
		if (loop == "up") {
/*				document.getElementById('fading_text').style.color="rgb(192,2,2)"; */
			document.getElementById('fading_text').style.backgroundColor = "rgb(192,2,2)";
			loop = "down"
		} else {
/*			document.getElementById('fading_text').style.color="rgb("+r+","+g+","+b+")"; */
			document.getElementById('fading_text').style.backgroundColor = "rgb(11,126,2)";
			loop="up"
		}	
		setTimeout("fading_text()", 500); 	
	}
}


r = 234;
g = 183;
b = 4;


r2 = 192;
g2 = 2;
b2 = 2;


function fading_text_vloeiend() { 

	if (document.getElementById('fading_text')) {
		if (loop == "up") {
			if (b<255)   {
				r+=1;
				g+=20;
				b+=25;
				
				r2-=18;
				g2+=12;
				b2-=0;
				
				document.getElementById('fading_text').style.color="rgb("+r+","+g+","+b+")"; 
				document.getElementById('fading_text').style.backgroundColor = "rgb("+r2+","+g2+","+b2+")";
			}
			else {
				loop = "down"
			}
		} else {
			if (b>0) {
				r-=1;
				g-=20;
				b-=25;
				
				r2+=18;
				g2-=12;
				b2+=0;
				
				document.getElementById('fading_text').style.color="rgb("+r+","+g+","+b+")"; 
				document.getElementById('fading_text').style.backgroundColor = "rgb("+r2+","+g2+","+b2+")";
			} else {
				loop="up"
			}
		}	
		setTimeout("fading_text()", 100); 	
	}
}
