jQuery.noConflict();
jQuery(document).ready(function () {
  
    jQuery('#slideshow').cycle({ 
        fx:     'fade', 
        timeout: 5000
    });
    
    jQuery("a.gallery").fancybox({
        'transitionIn'	:	'elastic',
        'transitionOut'	:	'elastic',
        'speedIn'	:	600,   
        'speedOut'	:	400,
        'overlayShow'	:	true,
        'hideOnContentClick':   true,
        'hideOnOverlayClick':   true,
        'titlePosition' :      'outside'
    });
    // find the elements to be eased and hook the hover event
    jQuery('div.jimgMenu ul li a').hover(function() {  
        // if the element is currently being animated
        if (jQuery(this).is(':animated')) {
            jQuery(this).addClass("active").stop().animate({
                height: "200px"
            }, {
                duration: 450, 
                easing: "easeOutQuad", 
                complete: "callback"
            });
        } else {
            // ease in quickly
            jQuery(this).addClass("active").stop().animate({
                height: "200px"
            }, {
                duration: 400, 
                easing: "easeOutQuad", 
                complete: "callback"
            });
        }
    }, function () {
        // on hovering out, ease the element out
        if (jQuery(this).is(':animated')) {
            jQuery(this).removeClass("active").stop().animate({
                height: "45px"
            }, {
                duration: 400, 
                easing: "easeInOutQuad", 
                complete: "callback"
            });
        } else {
            // ease out slowly
            jQuery(this).removeClass("active").stop(':animated').animate({
                height: "45px"
            }, {
                duration: 450, 
                easing: "easeInOutQuad", 
                complete: "callback"
            });
        }
    });
    jQuery('.link-img').hover(
        function(){
            jQuery(this).parent('.img-div').children('.img-block-link').css('color','#F5EADD')
            },
        function(){
            jQuery(this).parent('.img-div').children('.img-block-link').css('color','#1e1101')
            })

    jQuery('.img-block-link').hover(
        function(){
            jQuery(this).parent('.img-div').children('.img-block-link').css('color','#F5EADD')
            },
        function(){
            jQuery(this).parent('.img-div').children('.img-block-link').css('color','#1e1101')
            })

    jQuery("#kontakt_tel[title]").tooltip();
    jQuery("#kontakt_mail[title]").tooltip();
});
