$(document).ready(function () {  
  var top = $('#sidebar-scroller').offset().top;
  $(window).scroll(function (event) {
    // what the y position of the scroll is
    var y = $(this).scrollTop();
  
    // whether that's below the form
    if (y >= top) {
      // if so, ad the fixed class
      $('#sidebar-scroller').addClass('fixed');
    } else {
      // otherwise remove it
      $('#sidebar-scroller').removeClass('fixed');
    }
  });


// Lazyload
$("img").lazyload({
     placeholder : "http://megamagro.com/wp-content/themes/Gridzine/images/lload.gif",       
     effect      : "fadeIn"
 });

// Scroll to top animation
$('a.scroll-top').click(function(){ 
	$('html, body').animate({scrollTop:0}, 'slow'); return false; 
});

// Uniform
$("select, input:checkbox, input:radio, input:file").uniform();

// Interviews Dropdown
	// Show Navigation Menu
	$(document).ready(function() {
	 // hides the slickbox as soon as the DOM is ready
	 // (a little sooner than page load)
	  $('#menu-featured-artists').hide();
	
	 
	 // toggles the slickbox on clicking the noted link  
	  $('a#toggle-interviews').click(function() {
	    $('#menu-featured-artists').slideToggle(300);
	    return false;
	  });
	});
	
// Playlist Dropdown
	// Show Navigation Menu
	$(document).ready(function() {
	 // hides the slickbox as soon as the DOM is ready
	 // (a little sooner than page load)
	  $('#menu-mixtapes').hide();
	
	 
	 // toggles the slickbox on clicking the noted link  
	  $('a#toggle-playlists').click(function() {
	    $('#menu-mixtapes').slideToggle(300);
	    return false;
	  });
	});

});


