// cufon
Cufon.replace('h1');
Cufon.replace('.home-box h1');
Cufon.replace('.content-title-h1 h1');

// slider
$(document).ready(function(){
	$("#slider").click(function(){
		$("#hidden-slider").slideToggle("slow");
		$(this).toggleClass("hidden-slider"); return false;
	});
	
	$('.hide').hide();
    $('.slider').children('h5').click(function() {
		$(this).next('.hide').slideToggle('slow');
		//alert($(this).next('.hide').attr("href"));
	});
});

// gallery
$(document).ready(function() {
	$("a[rel=gallery_group]").fancybox({
		'transitionIn'	: 'elastic',
		'transitionOut'	: 'elastic',
		'titlePosition'	: 'inside',
		'overlayColor'		: '#fdfcfa',
		'overlayOpacity'	: 0.9,
		'titleFormat'		: function(title, currentArray, currentIndex, currentOpts) {
			return '<span id="fancybox-title-over">Zdjęcie ' + (currentIndex + 1) + ' / ' + currentArray.length + (title.length ? ' &nbsp; ' + title : '') + '</span>';
		}
	});
	$("a.fancybox").fancybox({
		'transitionIn'	: 'elastic',
		'transitionOut'	: 'elastic',
		'titlePosition'	: 'inside',
		'overlayColor'		: '#fdfcfa',
		'overlayOpacity'	: 0.9
	});
});

// formularz
function showIt() {
  document.getElementById("formMess").style.visibility = "hidden";
}

