Boot order and other early settings are stored in the bootloader EEPROM, out of sight of config.txt. A single command prints them, so you can look before you change anything.
The Raspberry Pi documentation covers the tool in its bootloader section. Reading the current configuration needs no options:
rpi-eeprom-config
It prints the settings as text. You can also read the configuration from a bootloader image file, which is useful to compare what is on the board with what a new image would bring:
rpi-eeprom-config pieeprom.bin
To change something, the docs use an editor session:
sudo rpi-eeprom-config --edit
sudo reboot
According to the page, when the editor is closed, the tool applies the updated configuration to the latest available bootloader release, and the change takes effect at the reboot. A saved file can be applied the same way with sudo rpi-eeprom-config --apply boot.conf.
My advice is to start with the read-only form and save the output somewhere before you edit:
rpi-eeprom-config > ~/bootloader-before.txt
If a change makes things worse, you then know exactly what the settings were. Putting the file under your home folder is fine, since it holds no secrets, but check it before you paste it in a forum post anyway.
The caveat is that this is firmware configuration. A wrong value in the boot settings can leave the board unable to find its drive until you fix it with another medium, so change one thing at a time and keep a second way to boot nearby. I’d also run sudo rpi-eeprom-update first, since the edit is applied to the latest available release, not to the one that happens to be installed.
Further reading: Raspberry Pi documentation: bootloader configuration