jQuery(document).ready(function(){
	
	// HANDLES THE NAVIGATION DROP DOWNS
	// Wordpress automagically places the following classes on nav elements:
	
	// current_page_item: reflects the current page being viewed
	// current_page_parent: reflects the parent of the page being viewed
	
	//jQuery(".menu-main-nav-container ul li li").css({display: "none"}); // Opera Fix
	
	// The menu is generated by Wordpress 3.0's Menu option under Appearance.

	// Tag the parent menu item with class 'current-page-parent'	
	jQuery("li.current-menu-item").parents("li.menu-item").addClass("current-page-parent");
	jQuery("li.current-page-parent ul li").css({visibility: "visible", display: "inline", opacity: 1, filter:"alpha(opacity=100)"});
	
	// Fades the menus in and out
	if(jQuery(this).parents("li.menu-item").not(".current-page-parent")){
		if(jQuery.support.opacity){
			jQuery(".menu-main-nav-container li").hover(
				function(){ // fade in
					jQuery(this).find('li').animate({
						opacity:1
					}, 200, function(){
						// Called when animation is done, if needed
					});
				},
				function(){ //fade out
					jQuery(this).find('li').animate({
						opacity:0
					}, 200, function(){
						// Called when animation is done, if needed
					});
				}
			);
		} else { // special just for IE
			jQuery(".menu-main-nav-container li").hover(
				function(){
					jQuery(this).find('ul').fadeIn(200);
					jQuery(this).find('ul').style.removeAttribute('filter');
				},
				function(){
					jQuery(this).find('ul').fadeOut(200);
				}
			);
		}
	}

		
	// Shows & highlights the active page's menu item & handles children
	jQuery("li.current-menu-item").css({visibility: "visible", display: "inline", opacity: 1, filter:"alpha(opacity=100)"});
	
	jQuery("li.current-menu-item a").css({color: "#eb6e1f"});
	jQuery("li.current-menu-item ul li a").css({color: "#fff"});
	
	// Handles rollover colors for sub-menu items
	jQuery("li.current-menu-item ul li a").hover(
		function(){
			jQuery(this).css({color: "#eb6e1f"});
		},
		function(){
			jQuery(this).css({color: "#fff"});
		}
	);
		
});