your battery settings are putting firefox to sleep. adb shell cmd deviceidle whitelist +org.mozilla.firefox fixes that until the next restart.
Isn't this the same as setting Firefox's Battery Optimization to Unrestricted, except more difficult and not permanent?