$(document).ready(function () {

	// Toggle help menu
	//
	$('#nav_help li.help_menu_button').hover(
		function () {
			//show submenu
			$('#help_menu').stop(false,true).show(150);
			//maintain hover state of the help button
			$('span a', this).attr('class', 'showhover');
   		},
		function () {
			//hide submenu
			$('#help_menu').stop(false,true).hide();			
			//restore hover state of help button to normal
			$('span a', this).removeAttr("class");
		}
	);

	
	// Make icons show hover state when hovering over respective help menu links
	//
	// Home
	$('.help_home').hover(
		function () {
			//show hover state for respective icon
			$('.link_home a').attr('class', 'showhover');
   		},
		function () {
			//remove hover state for respective icon
			$('.link_home a').removeAttr("class");
		}
	);

	// Archive
	$('.help_archive').hover(
		function () {
			//show hover state for respective icon
			$('.link_archive a').attr('class', 'showhover');
   		},
		function () {
			//remove hover state for respective icon
			$('.link_archive a').removeAttr("class");
		}
	);

	// Random
	$('.help_random').hover(
		function () {
			//show hover state for respective icon
			$('.link_random a').attr('class', 'showhover');
   		},
		function () {
			//remove hover state for respective icon
			$('.link_random a').removeAttr("class");
		}
	)

	// Previous
	$('.help_previous').hover(
		function () {
			//show hover state for respective icon
			$('.link_previous a').attr('class', 'showhover');
   		},
		function () {
			//remove hover state for respective icon
			$('.link_previous a').removeAttr("class");
		}
	)
	
	// Next
	$('.help_next').hover(
		function () {
			//show hover state for respective icon
			$('.link_next a').attr('class', 'showhover');
   		},
		function () {
			//remove hover state for respective icon
			$('.link_next a').removeAttr("class");
		}
	)	

});




