I’m used to audio stopping as soon as I switch to another app. Is it possible to do the same with Firefox?

The audio keeps playing, so I have to go back to the app and manually stop the video.

Edit: just realized this also happens if I close the app (not just switching apps). Is this really the desired behavior? I want to give Firefox a shot but I may have to back to DuckDuckGo if this can’t be changed :(

Thabks.