$(document).ready(function(){
               
               
				
                $.fn.qtip.styles.mystyle = { // Last part is the name of the style
                   width: 280,
                   background: '#e8ecf7',
                   color: 'black',
                   border: {
                      width: 1,
                      radius: 1,
                      color: '#666'
                   },
                   
                   
                   name: 'dark' // Inherit the rest of the attributes from the preset dark style
                }
				/*
				
				border: {
                      width: 7,
                      radius: 5,
                      color: '#e8ecf7'
                   },
				tip: 'topMiddle',
				*/
				
                $(".pobocka").each(function(){
                   $(this).qtip({
                      content: $(this).html(),
                      style: {
                          name: 'mystyle' // Inherit from preset style
                       },
                       position: {
                      corner: {
                         target: 'bottomMiddle',
                         tooltip: 'topMiddle'
                      }
                   },
                       show: {
                            when: 'click',
                            // Show it on click...
                            solo: true // ...and hide all others when its shown
                        },
                       hide: {
                           when: { event: 'unfocus' }
                        }
                   });
                });
			
              $("area").each(function(){
                   var name=$(this).attr("href");
				   if(name!=='#') {
					   var content=$(name).html();
					   if (content){
					   $(this).qtip({
									api: {
							  onRender: function() {
								 this.elements.content.find('.gallery_map a').fancybox().click(this.hide); // Something like this
							  }
						   },
						  content: content,
						  style: {
							  name: 'mystyle' // Inherit from preset style
						   },
						   position: {
						  corner: {
							 target: 'topMiddle',
							 tooltip: 'topMiddle'
						  }
					   },
						   show: {
								when: 'click',
								// Show it on click...
								solo: true // ...and hide all others when its shown
							},
						   hide: {
							   when: { event: 'unfocus' }
							}
					   });
					  }
				   }
               });
			  
                        $( ".tabs" ).tabs({
			cookie: {
				// store cookie for a day, without, it would be a session cookie
				expires: 1
			}
		});
               

               $("#window").slideDown(1000);
               $("#close_button").show(1000);
			   $("#close_button_sk").show(1000);
			   $("#close_button_en").show(1000);
			   
			   $.fn.maphilight.defaults = {
                        fill: true,
                        fillColor: '000000',
                        fillOpacity: 0.2,
                        stroke: false,
                        strokeColor: 'ff0000',
                        strokeOpacity: 1,
                        strokeWidth: 1,
                        fade: true,
                        alwaysOn: false,
                        neverOn: false,
                        groupBy: false
                }
               $('img[usemap]').maphilight();
			   
			   $(".gallery a").fancybox({
						'overlayShow'	: true,
						'transitionIn'	: 'elastic',
						'transitionOut'	: 'elastic'
				});
			    $('#slider').nivoSlider({
        effect:'fold', // Specify sets like: 'fold,fade,sliceDown'
        slices:1, // For slice animations
        boxCols: 8, // For box animations
        boxRows: 4, // For box animations
        animSpeed:500, // Slide transition speed
        pauseTime:10000, // How long each slide will show
        startSlide:0, // Set starting Slide (0 index)
        directionNav:false, // Next & Prev navigation
        directionNavHide:true, // Only show on hover
        controlNav:true, // 1,2,3... navigation
        controlNavThumbs:false, // Use thumbnails for Control Nav
        controlNavThumbsFromRel:false, // Use image rel for thumbs
        controlNavThumbsSearch: '.jpg', // Replace this with...
        controlNavThumbsReplace: '_thumb.jpg', // ...this in thumb Image src
        keyboardNav:true, // Use left & right arrows
        pauseOnHover:true, // Stop animation while hovering
        manualAdvance:false, // Force manual transitions
        captionOpacity:0.8, // Universal caption opacity
        prevText: 'Predchozí', // Prev directionNav text
        nextText: 'Další', // Next directionNav text
        beforeChange: function(){}, // Triggers before a slide transition
        afterChange: function(){}, // Triggers after a slide transition
        slideshowEnd: function(){}, // Triggers after all slides have been shown
        lastSlide: function(){}, // Triggers when last slide is shown
        afterLoad: function(){} // Triggers when slider has loaded
    });
             });
