$(document).ready(function()
{		
	//Entry Slider
    $(".entry").slideDown("800");
    
	//Submit an Article Slider
	$(".button_submit_an_article").click(function () {
	if ($("#submit_an_article").is(":hidden")) {
      $("#submit_an_article").slideDown("800");
      } else {
        $("#submit_an_article").slideUp("800");
      }
    });	
    
    //Posting Policy Slider
    $("a.posting_policy").click(function () {
	if ($("#posting_policy").is(":hidden")) {
      $("#posting_policy").slideDown("800");
      } else {
        $("#posting_policy").slideUp("800");
      }
    });
    
	//Expand and Collapse
	var entryState = $.cookie("entryState");
	
	if (entryState == "hide") {
		$(".short_entry").css("display","none");
	};
			
	$(".button_expand").click(function(){
		$(".short_entry").slideDown("slow");
		$.cookie("entryState", "show", { path: "/" });
	});
	
	$(".button_collapse").click(function(){
		$(".short_entry").slideUp("slow");
		$.cookie("entryState", "hide", { path: "/" });
	});
	
	//Dropdown Menus		
    $("ul.dropdown").superfish({ 
        delay:       0,                           
        animation:   {height:'show'},  
        speed:       'fast',  
        autoArrows:  false
    });
    
    $("ul.member_site").superfish({ 
        delay:       0,                           
        animation:   {height:'show'},  
        speed:       'fast',  
        autoArrows:  false
    });
    
    $("ul.category_dropdown").superfish({ 
        delay:       0,                           
        animation:   {opacity:'show'},  
        speed:       'fast',  
        autoArrows:  false
    });
	  $("tr:even").css("background-color", "#f6f6f6");
	  $("tr:odd").css("background-color", "#ffffff");
	  
	  $("#emphasis th:nth-child(3n)").addClass("emphasis");
	  $("#emphasis th:nth-child(6n)").removeClass("emphasis");
	  $("#emphasis td:nth-child(3n)").addClass("emphasis");
	  $("#emphasis td:nth-child(6n)").removeClass("emphasis");
	  
});