/* FUNCTIONS */
/* po nacteni dokumentu */
$(document).ready(function(){

  /* aplikuj prepinani tabulek na homepage */
	$('#main #tabs UL').superSimpleTabs();

  /* zavri #flags */
  $("#flags A.close").click(function () {
    $("#flags").hide();
  });   

  /* otevri #flags */
  $("A.flags").click(function () {
    $("#flags").show();
    return true;
  });   

  /* zavri #texy_syntax */
  $("A.texy_syntax_in_close").click(function () {
    $("#texy_syntax_in").hide();
    $("#texy_syntax_in_close").hide();
  });

  /* otevri #texy_syntax */
  $("A.texy_syntax_in").click(function () {
    $("#texy_syntax_in").show();
    $("#texy_syntax_in_close").show();
    return true;
  });
  
  $(function() {
  	var zIndexNumber = 1000;
  	$('div').each(function() {
  		$(this).css('zIndex', zIndexNumber);
  		zIndexNumber -= 10;
  	});
  });

    /* menu */
    $(document).ready(function(){
        $("ul.sf-menu").superfish({
            delay:       500,                            // one second delay on mouseout
            animation:   {opacity:'show',height:'show'},  // fade-in and slide-down animation
            speed:       1,                               // faster animation speed
            autoArrows:  false,                           // disable generation of arrow mark-up
            dropShadows: false                            // disable drop shadows
        });
    });


});	
