This code makes the menu stick to top when the menu hits the top of viewport - you will need to add fixed in CSS
<script>
$(window).bind("load", function(){
var bottom = $('#menu').offset().top;
$(window).scroll(function(){
if ($(this).scrollTop() > bottom){
$('#menu').addClass('sticky');
}
else{
$('#menu').removeClass('sticky');
}
});
});
</script>