$().ready(function(){
	smartRollover();
//	if($("#pageTop").size() > 0) pageTop();
/*	if(/a/.__proto__=='//') $("body").css("font-size", "11px");*/
});
function smartRollover(){
	$("img, input").each(function (){
		if($(this).attr("src"))
		{
			if($(this).attr("src").match("_default."))
			{
				$('<img/>').attr( 'src', $(this).attr("src").replace("_default.", "_over.") );
				$(this).mouseover(
					function() {
						$(this).attr("src", $(this).attr("src").replace("_default.", "_over."));
					}
				);
				$(this).mouseout(
					function() {
						$(this).attr("src", $(this).attr("src").replace("_over.", "_default."));
					}
				);
			}
		}
	});
}
function pageTop()
{
	var offset = $("#pageTop").offset();
	var topPadding = $(window).height()/2;
	$(window).scroll(function() {
		if ($(window).scrollTop() < 100) {
			$("#pageTop").fadeOut("fast");
		}else{
			$("#pageTop").show();
			if($(window).scrollTop() > 900 )
			{
				$("#pageTop").stop().animate({marginTop: 0});
			}
			else
			{
				$("#pageTop").stop().animate({marginTop: $(window).scrollTop() - offset.top + topPadding});
			}
		}
		
	});
}





/*
 * Google Analytics
*/
 var _gaq = _gaq || [];
 _gaq.push(['_setAccount', 'UA-22936838-2']);
 _gaq.push(['_trackPageview']);

(function() {
	var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
	ga.src = ('https:' == document.location.protocol ? 'https://ssl' :'http://www') + '.google-analytics.com/ga.js';
	var s = document.getElementsByTagName('script')[0];
	s.parentNode.insertBefore(ga, s);
})();

