Cufon.replace('#nav_top a', { hover: true }, { fontFamily: 'Futura' }) ('#nav a', { hover: true }, { fontFamily: 'Futura' }) ('#footer_nav a', { hover: true }, { fontFamily: 'Futura' }) ('.categ_title', { fontFamily: 'Futura' });

jQuery(function(){

// breadcrumbs

$(".breadcrumb-list li:last-child").addClass("current");

// logo fading
$('#logo').hover(function() {
					// on mouse over
					$(this).find(".hover").stop().fadeTo('fast', 1);
					
					}, 
					function() {
					// on mouse out
					$(this).find(".hover").stop().fadeTo('fast', 0);
					});
// end logo fading

//nav fade init
function init_main_nav() {
	$(".main_nav > li").each(function() {
		$link = $(this).find("a");
		var link_hoverer = '<a href="'+$link.attr("href")+'" class="hover">'+$link.html()+'</a>';
		$link.after(link_hoverer);
	});
}
init_main_nav();
// nav fading
$('.main_nav li').hover(function() {
								// on mouse over
								$(this).find('.hover').stop().fadeTo('fast', 1);
								}, 
								function() {
								// on mouse out
								$(this).find('.hover').stop().fadeTo('fast', 0);
								});

// end fading

//inputur	Search
$('.search-input').focus(function(){ 
	if($(this).val() == $(this).attr('defaultValue'))
	{
		$(this).val('');
	}
});

$('.search-input').blur(function(){
	if($(this).val() == '')
	{
		$(this).val($(this).attr('defaultValue'));
	} 
});

//inputur	Newsletter
$('.news-box input[type=text]').focus(function(){ 
	if($(this).val() == $(this).attr('defaultValue'))
	{
		$(this).val('');
	}
});

$('.news-box input[type=text]').blur(function(){
	if($(this).val() == '')
	{
		$(this).val($(this).attr('defaultValue'));
	} 
});

// end inputr newsletter

// for vezi harta
    $('#display-vezi-harta').dialog({ autoOpen: false, width: 700, modal: true });
    $('.btn_vezi_harta, .btn_vezi_harta_nostyle').click(function () {
        $('#display-vezi-harta').fadeIn(200).dialog('open');
        return false;
    });

// for panoramas
    $('#display-panorama1').dialog({ autoOpen: false, width: 700, modal: true });
    $('.panorama1').click(function () {
        $('#display-panorama1').fadeIn(200).dialog('open');
        return false;
    });
	
	$('#display-panorama2').dialog({ autoOpen: false, width: 700, modal: true });
    $('.panorama2').click(function () {
        $('#display-panorama2').fadeIn(200).dialog('open');
        return false;
    });
	
	// categ childs hover effects 
	$(".child-banners li a").hover(
	function ()	{
		$(this).addClass("hover");
		$('.child-banners li a').not('.child-banners li a.hover').stop().animate({
				opacity: 0.8
		}, {
				duration: 200
		});
	},
	function () {
		$(this).removeClass("hover")
		$('.child-banners li a').stop().animate({
				opacity: 1
		}, {
				duration: 200
		});
	});
	
});
