Event.observe(window, 'load', function() {
	if($('nav-home') != undefined) {
		Event.observe('nav-home', 'mouseover', function() { $('nav-home').setStyle({ backgroundPosition: '-9px -40px' }); });
		Event.observe('nav-home', 'mouseout', function() { $('nav-home').setStyle({ backgroundPosition: '-9px 0px' }); });
	}
	
	if($('nav-foundation') != undefined) {
		Event.observe('nav-foundation', 'mouseover', function() { $('nav-foundation').setStyle({ backgroundPosition: '-65px -40px' }); });
		Event.observe('nav-foundation', 'mouseout', function() { $('nav-foundation').setStyle({ backgroundPosition: '-65px 0px' }); });
	}
	
	if($('nav-progress') != undefined) {
		Event.observe('nav-progress', 'mouseover', function() { $('nav-progress').setStyle({ backgroundPosition: '-225px -40px' }); });
		Event.observe('nav-progress', 'mouseout', function() { $('nav-progress').setStyle({ backgroundPosition: '-225px 0px' }); });
	}
	
	if($('nav-partnerships') != undefined) {
		Event.observe('nav-partnerships', 'mouseover', function() { $('nav-partnerships').setStyle({ backgroundPosition: '-360px -40px' }); });
		Event.observe('nav-partnerships', 'mouseout', function() { $('nav-partnerships').setStyle({ backgroundPosition: '-360px 0px' }); });
	}
	
	if($('nav-cpr-training') != undefined) {
		Event.observe('nav-cpr-training', 'mouseover', function() { $('nav-cpr-training').setStyle({ backgroundPosition: '-490px -40px' }); });
		Event.observe('nav-cpr-training', 'mouseout', function() { $('nav-cpr-training').setStyle({ backgroundPosition: '-490px 0px' }); });
	}
	
	if($('nav-events') != undefined) {
		Event.observe('nav-events', 'mouseover', function() { $('nav-events').setStyle({ backgroundPosition: '-624px -40px' }); });
		Event.observe('nav-events', 'mouseout', function() { $('nav-events').setStyle({ backgroundPosition: '-624px 0px' }); });
	}
	
	if($('nav-photos') != undefined) {
		Event.observe('nav-photos', 'mouseover', function() { $('nav-photos').setStyle({ backgroundPosition: '-709px -40px' }); });
		Event.observe('nav-photos', 'mouseout', function() { $('nav-photos').setStyle({ backgroundPosition: '-709px 0px' }); });
	}
	
	if($('nav-contact') != undefined) {
		Event.observe('nav-contact', 'mouseover', function() { $('nav-contact').setStyle({ backgroundPosition: '-850px -40px' }); });
		Event.observe('nav-contact', 'mouseout', function() { $('nav-contact').setStyle({ backgroundPosition: '-850px 0px' }); });
	}
	
	var cur_url = window.location.href;
	
	if(cur_url.search("about-the-darius-jones-foundation.php") != -1) {
		$('intro-container').setStyle({ backgroundImage: 'url(/assets/img/about.png)'});
		$('intro-text').setStyle({ display: 'none'});
	}
});
