$(document).ready(function () {
  // find the elements and hook the hover event
  $('.tooltip').hover(function() {
    var tip = $('> div', this);
    tip.fadeIn(500);
    $(this).css('z-index', '400');
  }, function() {
    var tip = $('> div', this);
    tip.fadeOut(500);
    $(this).css('z-index', '');
  });
});
