$(document).ready(
	function() {
		$("a.fancy").fancybox({
			'overlayShow': true,
			'overlayOpacity': .5,
			'width': 640,
			'height': 480
		});
		$("a.iframe").fancybox({
			'overlayShow': true,
			'overlayOpacity': .5,
			'width': 800,
			'height': 640
		});
	
			
		function mycarousel_initCallback(carousel)
		{
			// Disable autoscrolling if the user clicks the prev or next button.
			carousel.buttonNext.bind('click', function() {
				carousel.startAuto(0);
			});
		
			carousel.buttonPrev.bind('click', function() {
				carousel.startAuto(0);
			});
		
			// Pause autoscrolling if the user moves with the cursor over the clip.
			carousel.clip.hover(function() {
				carousel.stopAuto();
			}, function() {
				carousel.startAuto();
			});
		};
		jQuery('#mycarouseltop').jcarousel({
			auto: 0,
			scroll:1,
			wrap: 'both',
			initCallback: mycarousel_initCallback
		});
		jQuery('#mycarouselbottom').jcarousel({
			auto: 0,
			scroll:1,
			wrap: 'both',
			initCallback: mycarousel_initCallback
		});

		externalLinks();
		stripeAllTables();
		
		$("#selection").mouseover(function() {
			if ( $('.selection-box').is(':hidden') ) $(".selection-box").show();
			
		});
		$("#selection").mouseout(function() {
			if ( $('.selection-box').is(':visible') ) $(".selection-box").hide();
		});
	}
); 
