
document.observe('dom:loaded', function() {
	if ($('promo')) {
		$$('#promo .promotop div').each(function(el) {
			el.hide().ancestors()[0].setOpacity(0.8);
			el.ancestors()[1].on('mouseover', function(event) {
				el.show().ancestors()[0].setStyle({ height: '149px' });
			});
			el.ancestors()[1].on('mouseout', function(event) {
				el.hide().ancestors()[0].setStyle({ height: 'auto' });
			});
		});
	}
	if ($('right-side')) {
		$$('#right-side .rightboxtop').each(function(el) {
			el.setOpacity(0.9);
		});
	}
	$$('#menu ul ul').each(function(el) {
		if (Prototype.Browser.IE) {
			el.setStyle({ left: el.ancestors()[0].cumulativeOffset().left-4 + 'px' });
		}
		el.hide().ancestors()[0].on('mouseover', function(event) {
			el.show();
		});
		el.ancestors()[0].on('mouseout', function(event) {
			el.hide();
		});
	});
	/* Safari Fix */
	if (Prototype.Browser.WebKit) {
		$$('#menu li li').each(function(el) {
			el.on('mouseover', function(event) {
				this.setStyle({ background: '#008b5d' });
			});
			el.on('mouseout', function(event) {
				this.setStyle({ background: 'transparent' });
			});
		});
	}
});


var marqueewidth=898;var marqueespeed=1;var pauseit=1;var copyspeed=marqueespeed;var pausespeed=(pauseit==0)?copyspeed:0;var actualwidth="";var ticker;

function tickerpopulate(){
	ticker=document.getElementById?document.getElementById("ticker"):document.all.ticker;
	isIE=document.all;ticker.style.left=(marqueewidth+8)+(isIE?"":"px");
	ticker.style.visibility="visible";
	actualwidth=ticker.offsetWidth;
	setInterval("scrollmarquee()",20)
}
	
function scrollmarquee(){
	if(parseInt(ticker.style.left)>(-actualwidth+8)){
		ticker.style.left=(parseInt(ticker.style.left)-copyspeed)+(isIE?"":"px")
	}
	else{
		ticker.style.left=(marqueewidth+8)+(isIE?"":"px")
	}
}


