/*!
 * (c) WebMechanic.biz, some rights reserved.
 * Code licensed under CC BY-SA 3.0-de http://creativecommons.org/licenses/by-sa/3.0/deed.de
 */
var Krumedia = {};

Krumedia.equalize = function (qry) {
		qry = qry||'#wrapper .colgroup';
		var maxh = 0;
		$(qry)
			.each(
				function(i, elt) {
					maxh = (maxh < parseInt(elt.offsetHeight)) ? parseInt(elt.offsetHeight) : maxh;
					return this;
				})
			.each(
				function(i, elt) {
					if (maxh > 0) $(elt).css({'height':maxh+'px','minHeight':maxh+'px'});
					return this;
				}
			);
		// trigger reflow in IE
		if (maxh > 0 && !window.opera && document.all && window.resizeBy) {
			window.resizeBy(1,0);
			window.resizeBy(-1,0);
		}
	};

$(function(){	
	$('a[href="brief"]').each(function(i,e){
	  var output = '';
	  var input = $(e).html();
	  for (i=0; i<input.length; i+=2) {
	    output += String.fromCharCode(parseInt(input.substr(i, 2),16));
	  }
	  $(e).attr('href','mailto:'+output).html(output);
	});
});
