The loss of market share has nothing to do with the browser in itself. Mozilla simply has no reach. Chrome is shipped via Android and on the desktop via services having a billion+ users, like Youtube and Gmail.
Mozilla has no reach or push. It's not an engineering problem.
You can install FF on Android in a second on the Play Store, it's easier than it's ever been on the desktop; but you have to want to install it in the first place. Some of this want can be generated by feature excellence, some by peer pressure; but for a long time now, FF has lagged in producing the former and its leadership has actively sabotaged the community that can provide the latter.
Obviously FF was helped by MS dropping the ball in a way Google has not (yet), but in my opinion what happened then could be done again. Antitrust action is coming for both Apple and Google, Mozilla should be ready to pounce right there and then - but it cannot happen if the leadership does not understand that there is a problem.
This vacuum no longer exists. The competition isn't stagnant, they're speeding away.
Now people don't care, because Mozilla is seen as Just Another Silicon Valley Corp, with overpaid execs doing shady deals to push shit down our throat. At that point, "they are all the same" so might as well use the browser that works more often (Chrome). This can change, but it needs a positive shock.
Casual users don't care about technical differences, but they will care about "install this browser and see no ads nor cookie banners ever". The Enterprise will be happy to pay for this because of the security benefits.
Hell, I'm talking about casual users but the truth is that Mozilla has even managed to alienate power users with stupid & useless UI changes and "features".
This happened at the time when no other browser vendor drove any kind of serious marketing campaign. Even so, Firefox only reached 30% market share at its peak.
Then Chrome shot out, backed by Google's marketing budget, bundled with popular software installers and featured at the "Internet home page": "Still running Firefox? Upgrade to Chrome now!" (quote is approximate, but very close)
At one time Lenovo was bundling Firefox on their computers.
Google and Apple aren't making that same mistake, at least not to that same level. The developers are happy with the tooling, and the fact that ECMAScript and HTML API's keep evolving faster than much of the ecosystem can keep up with. The casual public is happy about a fresh coat of paint, or putting tabs in a different place every few years.
There just isn't the same opportunity due to incumbent vulnerability today.