Shrinking type on navbar when scrolling?

So I’m trying to learn webflow by doing and I want to create a sticky navbar like this one here

I’ve managed to set it up and have it be sticky except I don’t know how to shrink the type like this person did on their website when you scroll down? If I could get some help on that, that would be awesome, thanks!