$(document).ready(function(){
	
	// $(function() {
	// 	  $('a[@href^=http]').not('[@href*=http://s26374.gridserver.com/]').addClass('external-link').click(function() {
	// 	      window.open(this.href, '_blank');
	// 	      return false;
	// 	    	});
	// 		});
	
	$("input#email_address").focus( function() { $(this).val(""); } );
	
	
	$("#header li").hover(function(){ $(this).addClass("over"); },function(){ $(this).removeClass("over"); });	
	
	$("ul.dropdown").hover(function(){ $(this).parent().find("a").addClass("over"); },function(){ $(this).parent().find("a").removeClass("over"); });		

	if (jQuery.browser.safari) { $("ul.dropdown").mouseout(function(){ $(this).parent().find("a").removeClass("over"); }); }
	
	
	
	
	//$("#searchform").hide;
	//$("#search a").click(function() { $("#searchform").toggle(); return false; });
	$("a.close").click(function() { $("#searchform").hide(); return false; });
	
$("#search a").click(function(){
  $("#overlay").show();
  $("#searchform").show();
	
	
  $("#overlay").click(function(){
    $("#overlay").hide();
    $("#searchform").hide();
//alert("woot");
  });
});
	 

/*  $("#search").click(function() {
        $("#searchform").show();
        $("#s").focus();
    
    
    
        $("#wrapper").children().not("#searchform").click(function(){
          $("#searchform").hide();
        });
    
        return false;
      });
*/
}); //doc ready...

var helv = {
	src: '/type/helveticathin.swf',
	ratios: [7,1.32,11,1.31,13,1.24,14,1.25,19,1.23,27,1.2,34,1.19,42,1.18,47,1.17,48,1.18,69,1.17,74,1.16,75,1.17,1.16]
	};
	
sIFR.useStyleCheck = true;
sIFR.activate(helv);
sIFR.replace(helv, { 
	selector: '.site #main h1',
	wmode: 'transparent'
	,css: [
    '.sIFR-root { color: #69392a; }'
    ,'a { text-decoration: none; }'
    ,'a:link { color: #69392a; }'
    ,'a:hover { color: #8e766d; }'
  ]
});

sIFR.replace(helv, { 
	selector: '.blog #main h1',
	wmode: 'transparent'
	,css: [
    '.sIFR-root { color: #f71791; }'
    ,'a { text-decoration: none; }'
    ,'a:link { color: #f71791; }'
    ,'a:hover { color: #c41274; }'
  ]
});

sIFR.replace(helv, { 
	selector: '#homecontent li',
	wmode: 'transparent'
	,css: [
    '.sIFR-root { color: #69392a; text-align: right; }'
    ,'a { text-decoration: none; }'
    ,'a:link { color: #69392a; }'
    ,'a:hover { color: #8e766d; }'
  ]
});


function nospam(user,domain) {
	locationstring = 'mailto:' + user + '@' + domain;
	window.location = locationstring;
	}