function floatNav(float_nav_id, float_hover_out, float_hover_in, float_run_time, float_multiplier, float_click_effect, float_clicked_color)
{
	var list_elements = float_nav_id + " li";
	var link_elements = list_elements + " a";
	
	var timer = 0;
	
	$(list_elements).each(function(i)
	{
		timer = (timer * float_multiplier + float_run_time);
		
		$(this).css("margin-left","-180px");
		$(this).animate({ marginLeft: "0" }, timer);
		$(this).animate({ marginLeft: float_hover_out }, timer);
		$(this).animate({ marginLeft: "0" }, timer);
	});

	var link_hover_width = $(link_elements).width();	
	$(link_elements).hover(
		function()
		{
			$(this).animate({ paddingLeft: float_hover_out, opacity: 1, width: link_hover_width-(float_hover_out-float_hover_in) }, float_run_time);
		},		
		function()
		{
			$(this).animate({ paddingLeft: float_hover_in, opacity: float_multiplier, width: link_hover_width }, float_run_time);
		}
	);
	
	$(link_elements).click(
		function()
		{
			$(this).fadeOut(float_click_effect);
			$(this).fadeIn((float_click_effect/2));
			if ( float_clicked_color != "" )
			{
				$(this).css("color", float_clicked_color);
			}
		}
	);
}

$(document).ready(function()
{
	floatNav("ul#yellow", 25, 15, 150, .7, 500, "#fff");
	floatNav("ul#blue", 25, 15, 150, .7, 500);
});
