I want a group to scroll normally until it hits the top of the page, at which point it sticks like a floating group

I am trying to create a menu bar for a subsection of a page. As the user scrolls to that subsection, I want the group to scroll normally along with all other elements until it touches the top of the screen. At that point, I want it to remain there like a floating group as the user continues scrolling. How can I accomplish this?

Here you go