$(document).ready(function()
{
	$('#nav-about').click(function(e)
	{
		// Disable button's default behavior (making a # link)
		e.preventDefault();
		
		// Fuckin' move that shit from original margin of -266px; doing it live!
		if ($('#main-container').css('margin-left') == '-266px')
		{
			$('#main-container').animate({
				marginLeft: 0
			}, 500);
			$('#nav-about').css('background', 'url(images/about-active-state.png) no-repeat 2px 21px');
		}
		else
		{
			$('#main-container').animate({
				marginLeft: -266
			}, 500);
			$('#nav-about').css('background', 'url(images/about-inactive-state.png) no-repeat 2px 21px');
		}
    });

		$("a.lightbox").fancybox({
				'hideOnContentClick': true,
				'padding': 0,
				'overlayColor': '#333',
				'overlayOpacity': 0.5,
				'titleShow': true,
				'showCloseButton': true
			});
			
			// cache container
			var $container = $('#content');
			// initialize isotope
			$container.isotope({
			  // options...
			itemSelector : '.work',
			animationOptions: {
			     duration: 500,
			     easing: 'linear',
			     queue: false
			   }
			});

			$container.isoSelective({ 
			  	linkSelector: '#filters a', 
			  	attrSelector: 'data-filter', 
			  	activeClass: 'selected' 
			 });
	
});

