$().ready(function() {
	if ($(".outer").height() < $(window).height()) {
		$(".outer").height($(window).height());
	}
	if ($(".inp").length > 0) {
		$(".inp, textarea").focus(function() {
			$(this).addClass("focus");
		});
		
		$(".inp, textarea").blur(function() {
			$(this).removeClass("focus");
		});
	}

	if($(".videolayer").length > 0) {
		$(".videolayer").click(function(){
			$(window).scrollTop("0px");
			var youtubeid = $(this).attr("rel");
			$(".video_inner").html('<object width="600" height="395"><param name="movie" value="http://www.youtube.com/v/'+youtubeid+'&hl=en_US&fs=1&color1=0x3a3a3a&color2=0x999999"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/'+youtubeid+'&hl=en_US&fs=1&color1=0x3a3a3a&color2=0x999999" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="600" height="395"></embed></object>');
			$("#overlay").css("display", "block");
			return false;
		});
		$("#closeVideo").click(function(){
			$(".video_inner").html('');
			$("#overlay").css("display", "none");
			return false;
		});
	}


});

