// JavaScript Document
jQuery(document).ready(function() {

	jQuery('.job-opportunity .content-wrapper').hover(
		function() { 
			jQuery(this).children('div.job-listing').stop().animate({ opacity: 0.4 }, 50);
		},	
		function() { 
			jQuery(this).children('div.job-listing').stop().animate({ opacity: 1 }, 50);
		}
	);

	jQuery('div.job-listing').hover(
			function() { 
				jQuery(this).stop().animate({ opacity: 1 }, 150);
			},
			function() {
				jQuery(this).stop().animate({ opacity: 0.4 }, 150);
			}
	);
	
	$(function() {
		var $placeholder = $('input[placeholder]');
		if ($placeholder.length > 0) {
			var attrPh = $placeholder.attr('placeholder');
			$placeholder.attr('value', attrPh)
			  .bind('focus', function() {
				var $this = $(this);
				if($this.val() === attrPh)
					$this.val('').css('color','#171207');
			}).bind('blur', function() {
				var $this = $(this);
				if($this.val() === '')
					$this.val(attrPh).css('color','#333');
			});
		}
	});
	
	jQuery('.job-join div').each(function() { 
		jQuery(this).height(jQuery('div.job-join').height() - (jQuery(this).outerHeight() - jQuery(this).height()));	
	});
	
	jQuery('.job-join div').hover(
		function() { jQuery(this).siblings('div').stop().animate({ opacity:0.3 }, 150); },
		function() { jQuery(this).siblings('div').stop().animate({ opacity:1 }, 150); } 
	);
	
});
