Try thishttps://docs.opnsense.org/troubleshooting/password_reset.html
If you enabled TOTP, you cannot login without it and you are obviously relying on the correct time setting, so that is a risk.If the internet access is gone, NTP may be running, but how do you know if the time is right? See?You should either have an SSH login ready with an SSH key (this does not need TOTP) or have the console accessible without a login in order to be able to fix things in case the time goes wrong.