$(document).ready(function() {

var tween = new TweenMax.to($([".menu_1", ".menu_2", ".menu_3", ".menu_4", ".menu_5"]), 1, {rotationY:-180, repeat:1, yoyo:true}, 0.1);

var tween = new TweenMax.set([".menu_1", ".menu_2", ".menu_3", ".menu_4", ".menu_5"], {transformStyle:"preserve-3d"});

var tween = new TweenMax.set([".kontener_1", ".kontener_2", ".kontener_3", ".kontener_4", ".kontener_5"], {perspective:800});

var tween = new TweenMax.set(".tyl", {rotationY:-180});

var tween = new TweenMax.set([".tyl", ".przod"], {backfaceVisibility:"hidden"});

$(".kontener_1").hover(
  function() {
    TweenMax.to($(".menu_1"), 1.2, {rotationY:180, ease:Back.easeOut});
  },
  function() {
    TweenMax.to($(".menu_1"), 1.2, {rotationY:0, ease:Back.easeOut});  
  }
);

$(".kontener_2").hover(
  function() {
    TweenMax.to($(".menu_2"), 1.2, {rotationY:180, ease:Back.easeOut});
  },
  function() {
    TweenMax.to($(".menu_2"), 1.2, {rotationY:0, ease:Back.easeOut});  
  }
);

$(".kontener_3").hover(
  function() {
    TweenMax.to($(".menu_3"), 1.2, {rotationY:180, ease:Back.easeOut});
  },
  function() {
    TweenMax.to($(".menu_3"), 1.2, {rotationY:0, ease:Back.easeOut});  
  }
);

$(".kontener_4").hover(
  function() {
    TweenMax.to($(".menu_4"), 1.2, {rotationY:180, ease:Back.easeOut});
  },
  function() {
    TweenMax.to($(".menu_4"), 1.2, {rotationY:0, ease:Back.easeOut});  
  }
);

$(".kontener_5").hover(
  function() {
    TweenMax.to($(".menu_5"), 1.2, {rotationY:180, ease:Back.easeOut});
  },
  function() {
    TweenMax.to($(".menu_5"), 1.2, {rotationY:0, ease:Back.easeOut});  
  }
);

});
