// JavaScript Document

    $(function () {
        if ($.browser.msie && $.browser.version < 7) return;
        
        $('#navigation li')
            .removeClass('highlight')
            .find('a')
            .append('<span class="hover" />').each(function () {
                    var $span = $('> span.hover', this).css('opacity', 0);
                    $(this).hover(function () {
                        // on hover
                        $span.stop().fadeTo(500, 1);
                    }, function () {
                        // off hover
                        $span.stop().fadeTo(500, 0);
                    });
                });
                
    });


jQuery(document).ready(function() {
  
  
  
  $(".closing a").simpletip({ fixed: true, position: [-250, -30], content: 'You too think I am funny! Great, click me for a speedy back to top!' }); 
  
  $.localScroll();
  
  

easing = 'Back';
		
		function loadEasing(e) {
			location.href = 'index.html'+e;
		}
		
		function setEasing(e) {
			loadLamps(e);
		}




$("#smallthumb a, .enlargejq a").fancybox({
		'zoomSpeedIn'			: 600,
		'zoomSpeedOut'			: 500,
		'frameWidth'			: 600,
		'frameHeight'			: 500,		
		'easingIn'				: 'easeOutBack',
		'easingOut'				: 'easeInBack',
		'hideOnContentClick'	: false
	});




// for dynamic easing changes		
		function loadLamps(easing) {
            $(".lavaLamp").lavaLamp({
                fx: "easeIn"+easing,
                speed: 600,
                click: function() {return true;}
            });
           
		}
		
// jquery initialize:
        $(function() {
			loadLamps('Back');
			$(".easingLabel").text(easing);
		
        });


if ( $(".first-and-second-carousel").length > 0 ) {
	jQuery('.first-and-second-carousel').jcarousel({scroll: 2});
	
} 

	
	
	  $(".column  a, .leftlinks a, .readmore a").hover(
						   
	   function () {
      $(this).animate({paddingLeft: "10px"}, {queue:false, duration:220});
						   },
		function () {
      $(this).animate({paddingLeft: "0px"}, {queue:false, duration:220});
						   }				   
						   
    );

		$('.myGallery').cycle({ 
    delay:  4000, 
	timeout: 5000,
    speed:  1200, 
	cleartype: 0,
    before: onBefore 
}); 
		
		
		
		
//$('.myGallery img').css(function (){$(this).css({"z-index:","-1"})};
 
function onBefore() { 
    $('.title') 
        .html(this.alt); 
}; 
								
								
								

	


	
	
});	