$(document).ready(function () {

function se() {
		$("#sel_Area").change(function(){
			var sel = $('#sel_Area option:selected').val();
				if (sel > 49 && sel < 100) {
					setname = "a-min";
					sel = 50;
					$("#sel_Area").attr("name", setname);
					$('#fiftyfifty').remove();
					$('#moreee').remove();
					$('#rowjs').append('<input id="fiftyfifty" type="hidden" name="a-max" value="100" />')
					} else {
					}
				if (sel > 100) {
					setname = "a-min";
					$("#sel_Area").attr("name", setname);
					$('#fiftyfifty').remove();
					$('#moreee').remove();
					$('#rowjs').append('<input id="moreee" type="hidden" name="a-max" value="999999" />')
					}
		});
	}
se();
			
$("#menu-menyu-sleva crumblinkli:has(ul.sub-menu)").hover(function () {
     $(this).children("a").click(function () {
        return false;
     });
  });
 $("#menu-item li:has(ul.sub-menu)").hover(function () {
     $(this).children("a").click(function () {
        return false;
     });
  });
  
  
  
  
$(".left_menu ul ul").hide();
$(".one_house p").css('text-align','justify');


var _clfl = false;
// click menu 1st sublevel
$(".full").click(function(e){
	var _this = $(this);
	setTimeout(function(){
		if(!_clfl){
			if($(e.target).parent().parent().find('ul').length) {
				_this.find(".sub-menu").slideToggle(150);
			}	
		}
	},150);
});



$(".crumblink").hover(function () {
     $(this).click(function () {
        return false;
     });
  });

		$('#menu-menyu-sleva ul ul li a').prepend("- ");
		$('.special_block:first').append("<i></i>");
		
	
	$(".main_photo").hover(
	  function () {
	    $(this).prepend('<i class="zoom"></i>');
	  },
	  function () {
	    $(this).find("i").remove();
	  }
	);
	
	$(".r_photo").hover(
	  function () {
	    $(this).prepend('<i class="zoom2"></i>');
	  },
	  function () {
	    $(this).find("i").remove();
	  }
	);

	$('.ngg-widget a').css('width','161px');
	$('.ngg-widget a').css('height','110px');
	$('.ngg-widget a').css('padding','12px 12px 14px 12px');
	$('.ngg-widget a').css('background','url(http://estate-montenegro.ru/wp-content/themes/Invest-V/images/special_block.gif)');
	$('.ngg-widget a').css('display','block');
	$('.ngg-widget a').css('border','0');
	$('.ngg-widget a img').css('border','0');
	$('#ngg-webslice h3').css('display','none');
	
});

