$(document).ready(function(){
	// all divs with solid backgrounds set through CSS will have rounded corners.
	// if you have a div that you DO NOT want rounded, simply add "!important" on the background style
	// or pay Tony $5 to do it for you.
	
	//card slide in effect
	if($.browser.msie && $.browser.version == "6.0" || $.browser.version == "7.0" ) { 
 		$(".card_image_1,.card_image_2,.card_image_3").css("left", -110);
		$("#arrow").css("left", -50);
	}else{
 		$(".card_image_1,.card_image_2,.card_image_3").css("left", -85);
		$("#arrow").css("left", -50);
	}	
	$(".card_image_1,.card_image_2,.card_image_3").animate({left: '+=100px'}, 1000);
	
	// learn buttons fade effect
	$(".learn_more_button, #member_button, #button_login, #submit_button, #filter_button").css("opacity", 0.7);
	$(".learn_more_button, #member_button, #button_login, #submit_button, #filter_button").hover(function(){
		$(this).stop().fadeTo(500, 1.0);
	},function(){
		$(this).stop().fadeTo(500, 0.7);
	});
		
	// card bounce effects
	$("#card_1").hover(function(){
			if ($(".card_image_1:animated").size()){
				return false;
			}else{			
				$("#card_image_1").stop().animate({top: '-10'}, 500);	
			};
	},function(){
				$("#card_image_1").stop().animate({top: '0'}, 500);
	});
	
	
	$("#card_2").hover(function(){
			if ($(",card_image_2:animated").size()){
				return false;
			}else{			
				$("#card_image_2").stop().animate({top: '-10'}, 500);	
			};
	},function(){
				$("#card_image_2").stop().animate({top: '0'}, 500);
	});
	
	
	$("#card_3").hover(function(){
			if ($(".card_image_3:animated").size()){
				return false;
			}else{			
				$("#card_image_3").stop().animate({top: '-10'}, 500);	
			};
	},function(){
				$("#card_image_3").stop().animate({top: '0'}, 500);
	});
	
	// target _blank javascript hack
	$('a.external').attr('target', '_blank'); 

	// clear a text input when focused
	$(".reset").bind("focus",function(){ $(this).val(''); });
});// JavaScript Document

function removeFlashMarkup(){
	if($("#floating_john").size()){
		$("#floating_john").remove();
	}
};
function addArrow(){
	$("#arrow").stop().animate({left: '10'}, 500);
};
function highlightPhone(){
	$('#highlightedPhone').animate({color: "#fff600"},500);
};
