$(document).ready(function(){
	//nav
	
	$('.navBar .link').mouseenter(function(){
		$(this).addClass('temp_active');
		$(this).find('.drop').stop(0,1).show(400);
	}).mouseleave(function(){
		$(this).removeClass('temp_active');
		$(this).find('.drop').stop(1,1).hide();
	});

	$('.drop .item').mouseenter(function(){
		$(this).addClass('temp_active');})
	.mouseleave(function(){
		$(this).removeClass('temp_active');});

	$('.cleanme').each(function(){
		$(this).cleanForm({
			inputActive:'#b6bdc7',
			textColor: '#000000',
			requiredMessage: '<span class="color">*</span>'
		});
	});

});


/*
$(document).ready(function(){
//nav

$('.navBar .link:last')
.css('border-right','none')
.find('.drop')
.css({'left':'auto','right':'-3px'});


$('.navBar .link:has(.drop)').mouseenter(function(){
		alert('dude');
		$(this).addClass('temp_active');
		$(this).find('.drop').stop(false,true).show(400);})
	.mouseleave(function(){
		$(this).removeClass('temp_active');
		$(this).find('.drop').stop(false,true).hide(200);});

$('.drop').each(function(){
	$(this).find('.item:last').css('border-bottom','none');
});

$('.drop .item').mouseenter(function(){
		$(this).addClass('temp_active');})
	.mouseleave(function(){
		$(this).removeClass('temp_active');});

$('.noFollow').bind('click',function(){
	return false;
});

var qqFormStuff = {'fn':'* First Name','ln':'* Last Name','p':'* Phone Number','ea':'* Email Address'};
$('.sidebar form input.clearText, .homebox_contact form input.clearInput').focus(function(){
		if($(this).attr('value') == qqFormStuff[$(this).attr('name')]) $(this).attr('value','');
	}).blur(function(){
		if($(this).attr('value') == '') $(this).attr('value',qqFormStuff[$(this).attr('name')]);
	});
$('.sidebar form, .homebox_contact form').submit(function(){
	$('.sidebar form input.clearText, .homebox_contact form input.clearInput').each(function(){
		if($(this).attr('value') == qqFormStuff[$(this).attr('name')]) $(this).attr('value','');
	});
});

if($('.sidebar form:visible').length == 1){
	var bar = $('.sidebar');
	var barOffset = bar.offset();
	var upperLimit = 0;
	var lowerLimit = ($('.subbody').outerHeight() - bar.outerHeight() - upperLimit);
	
	if(lowerLimit < 0){
		lowerLimit = bar.outerHeight();
	}

	$(window).scroll(function(){
		var theScroll = $(this).scrollTop();
		var scrollStart = barOffset.top;
		
		if((theScroll > scrollStart) && (theScroll < (scrollStart + lowerLimit))){
			bar.stop().animate({
				marginTop: (upperLimit + (theScroll - scrollStart))+'px'
			},300);
		}
		else if(theScroll >= (scrollStart + lowerLimit)){
			bar.stop().animate({
				marginTop: (lowerLimit + upperLimit) +'px'
			},300);
		}
		else{
			bar.stop().animate({
				marginTop: upperLimit + 'px'
			},300);
		}
	});
}); */
