// JavaScript Document

$(document).ready(function(){
			jQuery('ul.sf-menu').superfish({delay:1200,dropShadows : false});
			//jQuery('.sf-menu ul').css({opacity:0.8});
			old_image={opacity: 0.1};
            new_image={opacity: 1.0};
			img_container=$('#level1');
			//msg=$('#menu_comment');
			if($.browser.msie && $.browser.version>7){
				$('#ssd img').css({'margin-left':'-10px'});
			}
			if($.browser.msie && $.browser.version<7){
			}else{
				img_container.css(old_image);
				//msg.css(old_image);
			}
			animation_speed=400;
			speed=250;
			
			$(".mysub").hover(function(){						
				id=$(this).attr('id');
				//img_container.dequeue();
				if($.browser.msie && $.browser.version<7){
					img_container.html("<img src='menu/thumb_"+id+".jpg' />");
				}else{
					img_container.animate(old_image, speed,
					  function() {
						img_container.html("<img src='menu/thumb_"+id+".jpg' />");
						img_container.dequeue();
					  });
					img_container.animate(new_image, speed);					
				}
			});
			$(".ajaxcall").click(function(e){
				e.preventDefault();
				href=$(this).attr("href");
				$.ajax({ 
					url: href,
					success: function(data){
						$("#ajax_content").html(data);
					}
				});
				return false;
			});
			$(".subaTab").css({opacity:0.9});
			$('a.facebox').click(function(e) { 
     		 $.get($(this).attr("rel"), function(data) { $.facebox(data) })
     		})

});
