When there is a configuration change, such as uiMode, Locale, etc., the fragments are not restored correctly. Then simply put the application in the background, and then return to the foreground, and everything is restored.
The problem does not arise in a systematic way, but without a rule, it does not arise until version 10 of Android. Apparently it also depends on the devices, for example with two different brands of phones, with Android 11 installed, on one it will happen and on another it will not happen.
In the attached video you can see the problem when it occurs.
https://drive.google.com/file/d/1nRXG9fqttc8TtTL4tLF0o8haru8A1YNg/view?usp=drive_web (Screen_Recording_20220530-231647_Call Blocker - Phone.mp4)