If your Ryzen-powered PC has an AM5 ASRock motherboard and sometimes just won't boot, then rescue is at hand in the form of a new BIOS update
Modern gaming PCs are relatively easy to build and use, but underneath that friendly exterior, they're still incredibly complicated things. So when they start doing weird stuff like refusing to boot after being used for a while, it can be really hard to solve the issue. However, if your PC is doing precisely that and uses an AM5 Ryzen processor in an ASRock motherboard, then the fix is actually very simple.
Specifically, all you need to do is update the BIOS to ASRock's newly announced beta version 4.07.AS01...