
			$(document).ready(function() {	

				//Show Banner
				$(".CSmain_image .desc").show(); //Show Banner
				$(".CSmain_image .block").animate({ opacity: 0.95 }, 1 ); //Set Opacity
				//$(".CSmain_image .block").animate({ opacity: 0.85 }, 1 ); //Set Opacity

				//Click and Hover events for thumbnail list
				$(".CSimage_thumb ul li:first").addClass('active');

				$(".CSmain_image .sliderImage").click(function(){
					doSlideSwitch($(this));
				});

				$(".CSimage_thumb ul li").click(function(){
					//Set Variables
					doSlideSwitch($(this));
				}).hover(function(){
					$(this).addClass('hover');
					}, function() {
					playSlideshow = setInterval( "slideSwitch()", 3000 );
				});

				//Toggle Teaser
				$("a.collapse").click(function(){
					$(".CSmain_image .block").slideToggle();
					$("a.collapse").toggleClass("show");
				});

				$(".CSimage_thumb ul li").hover(function(){
					clearInterval(playSlideshow);
					}, function() {
					$(this).removeClass('hover');
				});


			});//Close Function



			function doSlideSwitch(obj) {
				var $$ = obj;
				var imgAlt = $$.find('img').attr("alt"); //Get Alt Tag of Image
				var imgTitle = $$.find('a').attr("href"); //Get Main Image URL
				var imgDesc = $$.find('.block').html(); //Get HTML of block
				var imgDescHeight = $(".CSmain_image").find('.block').height(); 

				// Calculate height of block	
				if ($(this).is(".active")) {  //If it's already active, then...
					return false; // Don't click through
				} else {
					//Animate the Teaser		
					$(".CSmain_image img").animate({ opacity: 0}, 250 );

					$(".CSmain_image .block").animate({ opacity: 0.95, marginLeft: "-600", marginTop: "-50" }, 250 , function() {
						$(".CSmain_image .block").html(imgDesc).animate({ opacity: 0.95, width:"200px", marginLeft: "0", marginTop: "0" }, 400 );
						$(".CSmain_image .block p").animate({ width:"100%" }, 150 );
						$(".CSmain_image img").attr({ src: imgTitle , alt: imgAlt}).animate({ opacity: 1}, 250 );
					});
				}

				$(".CSimage_thumb ul li").removeClass('active'); //Remove class of 'active' on all lists
				$$.addClass('active');  //add class of 'active' on this list only
				return false;
			};


			function imgSlideSwitch(obj) {
			};


			function slideSwitch() {
				var $active = $('#CSslideshow li.active');
				if ( $active.length == 0 ) $active = $('#CSslideshow li:last');

				// use this to pull the divs in the order they appear in the markup
				var $next =  $active.next().length ? $active.next()
				: $('#CSslideshow li:first');

				// uncomment below to pull the divs randomly
				// var $sibs  = $active.siblings();
				// var rndNum = Math.floor(Math.random() * $sibs.length );
				// var $next  = $( $sibs[ rndNum ] );
				//$active.addClass('last-active');

				doSlideSwitch($next);
			};

			$(function() {
				playSlideshow = setInterval( "slideSwitch()", 4000 );
			});



//			$(function() {
//				setInterval( "slideSwitch()", 5000 );
//			});
		