jQuery(document).ready(function(){
	// Lightbox : Correctif pour les images en positionnement flottant disposant de loupe
  if(jQuery('a[rel^=lightbox]').length > 0)
  {
		jQuery('a[rel^=lightbox]')
		.addClass('zoomable')
		.fancybox({ Speed:1000, hideOnContentClick: false }) // on applique la fancybox
		.filter(':has(img)') // uniquement dans les liens ayant des images
		.append('<span class="zoom"></span>') // on ajoute un span contenant une image zoom
		.each(function() {
			var $this = $(this);
			// on définit les options css selon le type d'image
			if ($this.find('.illustr')) {
				$this.addClass('linkIllustr');
				$this.css({
					// width: $this.find('img').width()
				});
			} else if ($this.find('.illustr2')) {
				$this.css({
					position: 'relative',
					width: $this.find('img').width(),
					height: $this.find('img').height()
				});
			}
		});
  }
  
  //timer
  if(jQuery("#carousel_nav2 a").length > 0)
  {
  	jQuery("#carousel_nav2 a").everyTime(10000, function() {
    	jQuery(this).click();
  	});
	}
});

