Or use Linux, the highly advanced MPRIS protocol is capable of tracking multiple media applications and presenting their playback controls. It's like space-age tech!
In recent versions, the "default" is just whatever last played media—if you were watching a YouTube video yesterday, and the tab is still open, pressing the play/pause key will start it playing again. There's even a little menu bar widget (it's called the Now Playing menu, and you can find it under Control Center in the system settings) that shows all the instances of actively- or recently-playing media the system knows about. Whatever is on top (IIRC) is what will automatically be controlled by the media keys.