$(document).ready(function() {
	// Stuff to do as soon as the DOM is ready;

	// Fix padding for floated images in content
	$('img.alignLeft').parent().addClass('noPadding');
	$('img.alignRight').parent().addClass('noPadding');

	// Search box: on focus
	$('#header #searchFormWidget .inputHolder .inputText').focus(function() {
		// Add class to change the background
		$('#search .inputHolder').parent().addClass('inputActive');
		// Change font-color to blue
		$('#search .inputHolder .inputText').css('color','#333');
	});

	// Search box: on leave
	$('#header #searchFormWidget .inputHolder .inputText').blur(function() {
		// Remove class to put back the original background
		$('#search .inputHolder').parent().removeClass('inputActive');
		// Change font-color to white so text is still readable
		$('#search .inputHolder .inputText').css('color','#A1A1A1');
	});

	// show/hide items
	$('.showhide').click(function()
	{
		// hide all elements bound to buttons like these
		$('.showhide').each(function()
		{
			$($(this).attr('href')).hide();
			$(this).addClass('BigButton');
		});

		// show this element
		$($(this).attr('href')).show();
		$(this).removeClass('BigButton');
	});
});
