// JavaScript Document

(function($) {
	$(function() {
		var width, height;
		$('a.mo > img').each(function() {
			width = $(this).width();
			height = $(this).height();
			src = $(this).attr('src');
			
			if (width && height) {
				$(this).hide().parent('a').css({
					display: 'block',
					width: width,
					height: parseInt(height / 2, 10),
					backgroundImage: 'url(' + src + ')',
					backgroundPosition: 'left top',
					backgroundRepeat: 'no-repeat'
				}).mouseover(function() {
					$(this).css({ backgroundPosition: 'left bottom' });
				}).mouseout(function() {
					$(this).css({ backgroundPosition: 'left top' });
				});
			}
		});
	});
})(jQuery);