$(document).ready(function() {

	$(".search-text").searchvalue("à?àÎàÈá?àÊ");
	$("#login").defaultvalue("à?àÎàÃàÈàÍ");
	$("#password").defaultvalue("à?àÀá?àÎàËá?");

	$("a#authorization-open").toggle(function(){
		$("div#authorization").animate({top:"0px"});
		$(this).html("à?àÀàÊá?á?á?á? àÀàÂá?àÎá?àÈàÇàÀá?àÈá?");
	},
	function(){
		$("div#authorization").animate({top:"-110px"});
		$(this).html("à?àÂá?àÎá?àÈàÇàÀá?àÈá?");
	});

	$("ul#menu-main>li>a").click(function(){
		if( !$(this).is(".active") )
		$("ul#menu-main>li>a.active").each(function(){
			$(this).removeClass("active")
			$(this).parent().find("ul").slideUp("fast");
		});
		$(this).addClass("active").parent().find("ul").slideDown("fast");
	});
	
	$("#for-students").tooltip({delay:500});
	$("#for-teachers").tooltip({delay:500});
	$("#for-aspirants").tooltip({delay:500});
	$("#for-abiturients").tooltip({delay:500});
	
	$("div.scrollable").scrollable({
        size: 1, 
        items: '#thumbs',   
        hoverClass: 'hover' 
    });
    
    $("#thumbs div").hover(function(){
    	$(this).find(".img-name").animate({opacity: .5});
    }, function(){
    	$(this).find(".img-name").animate({opacity: 0});
    })
    $("#thumbs div").each(function(){
      $(this).find(".img-name").animate({opacity: 0});
    });
	// àÏàÎàÄá?àÂàÅá?àÊàÀ á?á?á?àÎàÊ àÂ á?àÀàÁàËàÈá?àÀá? (àÄàËá? IE6; àÄàËá? àÍàÎá?àÌàÀá?àÍá?á? àÁá?àÀá?àÇàÅá?àÎàÂ àÄá?àÁàËàÈá?àÎàÂàÀàÍàÎ á?àÅá?àÅàÇ CSS)
	/*	$("tr").hover(
			function () {$(this).addClass("tabletr-act");},
			function () {$(this).removeClass("tabletr-act");}
		);
	*/
});
