$(document).ready(function() {
			$("a[rel=video_tour]").fancybox({
				'width'             : 815,
				'height'            : 615,
				'transitionIn'		: 'elastic',
				'transitionOut'		: 'fade',
				'titlePosition' 	: 'over',
				'titleFormat'		: function(title, currentArray, currentIndex, currentOpts) {
					return '<span id="fancybox-title-over">Image ' + (currentIndex + 1) + ' / ' + currentArray.length + (title.length ? ' &nbsp; ' + title : '') + '</span>';
				}
			});
			$(".iframe_review").fancybox({
				'width'				: 400,
				'height'			: 250,
				'autoScale'			: false,
				'transitionIn'		: 'elastic',
				'transitionOut'		: 'fade',
				'type'				: 'iframe'
			});
			$(".iframe_require").fancybox({
				'width'				: 400,
				'height'			: 210,
				'autoScale'			: false,
				'transitionIn'		: 'elastic',
				'transitionOut'		: 'fade',
				'type'				: 'iframe'
			});
			$(".iframe_improve").fancybox({
				'width'				: 740,
				'height'			: 515,
				'autoScale'			: false,
				'transitionIn'		: 'elastic',
				'transitionOut'		: 'fade',
				'type'				: 'iframe'
			});
			$(".iframe_key").fancybox({
				'width'				: 730,
				'height'			: 340,
				'autoScale'			: false,
				'transitionIn'		: 'elastic',
				'transitionOut'		: 'fade',
				'type'				: 'iframe'
			});
			$('.slideshow').cycle({
		fx: 'fade',
		speed:    500, 
        timeout:  3000 
	});
		$('.features_box').cycle({
		fx: 'fade',
		speed:    500, 
        timeout:  0,
		pager: '.nav_cat',
		width: 550,
		height: 445,
		pagerAnchorBuilder: paginate
    });
		function paginate(ind, el){
			if (ind == 0) return '<div class="features">Features <span style="font-size: 10px;">(Page 1)</span></div>';
			else if (ind == 1) return '<div class="features">Features <span style="font-size: 10px;">(Page 2)</span></div>';
}

});


