jQuery.noConflict();

jQuery(document).ready(function() {

	function equalHeight(group) {
		var tallest = 0;
		group.each(function() {
			var thisHeight = jQuery(this).height();
			if(thisHeight > tallest) {
				tallest = thisHeight;
			}
		});
		group.height(tallest);
	}

    equalHeight(jQuery(".column"));
	
	/* drop down nav */	
	jQuery('#nav ul li').hover(
		function() { jQuery('ul', this).addClass('hover'); jQuery('ul', this).css('display','block'); },
		function() { jQuery('ul', this).css('display','none'); });
	
	/* img swap on yearly graphic */
	jQuery('#yearly').hover(function() {
		jQuery(this).attr("src","/wp-content/themes/3psports/images/yearly-plan-on.gif");
		}, function() {
		jQuery(this).attr("src","/wp-content/themes/3psports/images/yearly-plan-off.gif");
	});
	
	/* img swap on monthly graphic */
	jQuery('#monthly').hover(function() {
		jQuery(this).attr("src","/wp-content/themes/3psports/images/monthly-plan-on.gif");
		}, function() {
		jQuery(this).attr("src","/wp-content/themes/3psports/images/monthly-plan-off.gif");
	});
	
	/* if left nav exists, shorten social media bar */
	var leftNavHeight = jQuery('#left-nav').height();
	if (leftNavHeight) {
		jQuery('	div.sociable').css("width","57%");
		jQuery('	div.sociable').css("margin-left","178px");
	}
	
});

