$(function () {
  /*freshvision.pl*/
  var splash = $('<div>').attr('id', 'splash').css({'position': 'absolute', 'top': -400, 'opacity': 0, 'left': 0, 'z-index': 20000})
  var wrapper = $('<div>').attr('id', 'splash-wrapper').css({'position': 'relative', 'z-index': 20000}).appendTo(splash)
  var img = new Image()
  img.src = '/_p/gfx/snowball.gif'
  img.onload = function () {
	$(splash).click(function () { window.location = 'http://www.victoriacenter.pl/szkola/211/zimowisko-jezykowe-w-murzasichle-2012.html'; return false })
    $('<a>').attr('id', 'btn-splash-close').attr('href', '#').click(function () {
      $(splash).animate({top: -400, 'opacity': 0}, 500, function () {
        $('#splash').remove()
      })
      $(this).blur()
      return false
    }).html('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;').css({'position': 'absolute', 'top': 0, 'right': 0, 'width': 30, 'height': 30}).appendTo(wrapper)
    $(splash).css({'left': $('body').width()/2-img.width/2, cursor: 'pointer'})
    $(img).appendTo(wrapper)
    $(splash).appendTo('body')
    $(splash).animate({top: 100, 'opacity': 1}, 1200)
  }
})

