// JavaScript Document


	$(document).ready(function(){	

	$('.subnav').each(function () {
		$(this).parent().eq(0).hoverIntent({
			timeout: 200,
			over: function () {
				var current = $('.subnav:eq(0)', this);
				current.slideDown(100);
			},
			out: function () {
				var current = $('.subnav:eq(0)', this);
				current.slideUp(200);
			}
		});
	});
	
	$('.subnav a').hover(function () {
		$(this).stop(true).animate({paddingLeft: '15px'}, {speed: 200, easing: 'easeOutBack'});
		}, function () {
		$(this).stop(true).animate({paddingLeft: '5px'}, {speed: 200, easing: 'easeOutBounce'});
	});   

	});

    $(document).ready(function(){
	
		$("ul.top_nav li a.nav_tie").click(function() { 
													
			$(this).parent().find("div.tie_login").animate({height: "140px" }, "fast").animate({height: "130px" }, "fast").show();
			$(".nav_tie").css("background-position","bottom");
		});
		
		$("ul.top_nav li div.hide").click(function() {
												   
			$("div.tie_login").animate({height: "140px" }).animate({height: "0px" }).slideUp("fast");
			$(".nav_tie").css("background-position","top");
		  
		});
	
	});
	

	$(document).ready(function(){
		
		$('#banner') 
			.before('<ul id="selector">') 
			.cycle({ 
			fx:     'cover', 
			speed:  'slow', 
			timeout: 6000, 
			pager:  '#selector',
			pause:	 1,
			
			pagerAnchorBuilder: function(idx, slide) { 
       		return '#nav li:eq(' + (idx) + ') a'; 
    		} 
			});
		
	});
	
	
	
	// Opinions
	
	$(document).ready(function(){
	
		$('#comments').cycle({ 
		fx:     'fade', 
		speed:  'slow', 
		timeout: 0,
		next:   '#comment_next', 
		prev:   '#comment_prev'
		});
	
	});
	

