var supersizedImage;

$(document).ready(function() {

	// shadows
	/*
	if (!$.browser.msie) {
		$('div#navigationLayer').dropShadow({left: 2, top: 2, opacity: 0.33, blur: 3, color: 'black'});
		$('div#contentLayer').dropShadow({left: 2, top: 2, opacity: 0.33, blur: 3, color: 'black'});
	}
	*/

	if(typeof document.body.style.maxHeight === "undefined") {
		//alert('ie6');
	} else {

		// png transparency
		$(document).pngFix();

		// background image
		if (supersizedImage==null || supersizedImage=="") supersizedImage = "bg-5.jpg";
		$.supersized({
			slides : [ { image : '/5_images/3_backgrounds/' + supersizedImage } ]
		});

	}

	// layout height
	$('div#layoutWrapper').height($('div#contentLayer').outerHeight() + 150 + 30);

	// for-step-navigation
	$("div.stepClass").not('div.actClass').bind({
		click: function(){
			//$(this).children("a").trigger('click');
			window.location.href = $(this).children('a').attr('href');
		},
		mouseenter: function(){
			$(this).addClass("actClass");
			$(this).css("cursor","pointer");
		},
		mouseleave: function(){
			$(this).removeClass("actClass");
			$(this).css("cursor","auto");
		}
	});

	// pict zoom
	$("div.pict315Class").bind({
		mouseenter: function(){
			$(this).children('div.pict315ZoomClass').hide();
		},
		mouseleave: function(){
			$(this).children('div.pict315ZoomClass').show();
		}
	});

	// fadeslideshow
	if ($('div#fadeslideshowWrapper').length != 0) {
		$('div#fadeslideshowWrapper').fadeSlideShow({
			width: 700,
			height: slideshowH,
			speed: 1500,
			interval: 4000,
			PlayPauseElement: false,
			NextElement: false,
			PrevElement: false,
			ListElement: false
		});
	}

	// lightbox
	if ($('a.lightbox').length != 0) {
		$("a.lightbox").fancybox({
			'padding'			: 10,
			'margin'			: 50,
			'showCloseButton'	: true,
			'showNavArrows'		: true,
			'titleShow'			: true,
			'titlePosition'		: 'outside',
			'cyclic'			: false,
			//'overlayColor'	: '#185775',
			'overlayColor'		: '#666',
			'overlayOpacity'	: 0.85,
			'centerOnScroll'	: true
			//'titleFormat'		: formatTitle
		});
	}

});

