jQuery(document).ready(function(){
	/* MAIN NAVIGATION DROP DOWN
		*/
		jQuery('li.dropdownlink').hover(
			function() { jQuery('#submenu', this).css('display', 'block'); },
			function() { jQuery('#submenu', this).css('display', 'none'); }
		);

		jQuery('#submenu, #main_nav ul li.dropdownlink a#shows').hover(
			function(){
				if(jQuery.browser.msie && jQuery('div#game_wrapper_container').length){
					jQuery('div#game_wrapper_container').css('display','none');
				}
				jQuery('#main_nav ul li.dropdownlink a#shows').css(); 
				},
			function(){
				if(jQuery.browser.msie && jQuery('div#game_wrapper_container').length){
					jQuery('div#game_wrapper_container').css('display','block');
				}
				jQuery('#main_nav ul li.dropdownlink a#shows').css();
			}
		);


	/* ADD FIRST/LAST TO LI
			adds a class 'first' to the first LI, and a 'last' to the last LI and 'first last' to a single LI
		*/
		jQuery('ul').each(function(i){
			jQuery(this).children('li:first').addClass('first');
			jQuery(this).children('li:last').addClass('last');
		});
	/* ADD FIRST/LAST TO DT/DD
			adds a class 'first' to the first DT and DD, and a 'last' to the last DT and DD and 'first last' to a single DT and DD
		*/
		jQuery('dl').each(function(i){
			jQuery(this).children('dt:first').addClass('first');
			jQuery(this).children('dt:last').addClass('last');
			jQuery(this).children('dd:first').addClass('first');
			jQuery(this).children('dd:last').addClass('last');
		});
})
