$(document).ready(function(){
	$('body').addClass('hasJS');
	
	$('body #nav > ul > li').each(function(){
		var $this=$(this);
		$this.hover(function(){
			$this.addClass('open');
		},function(){
			$this.removeClass('open');
		});
	});	
	
	// Expander
	$('.expand-art').each(function(){
		var $this = $(this);
		var $hd = $('.article-title', $this);
		var $bd = $('.article-text', $this);
		
		$hd.click(function(){
			if ($this.hasClass('opener-article')) {
				$bd.slideUp();
			} else {
				$('.expand-art .article-text').slideUp();
				$('.expand-art').removeClass('opener-article');
				$bd.slideDown();
			}
			$this.toggleClass('opener-article');
		});
	});		

});
