I've been using this system with Win 7 for a couple of years. I've always had frequent blue-screen crashes when booting and during Win 7 normal operations, but this seems to be new. I left it on to retry over and over a couple of days ago. It did come up during the night and I was able to use it for awhile before it crashed.
I would try a BIOS recovery:
You can find the latest BIOS here: https://downloadcenter.intel.com/download/22828/BIOS-Update-GAZ7711H-86A-?product=63247 Download BIOS Update [GAZ7711H.86A]
And, I would replace the CMOS battery, just in case.
Another possible cause could be your hard drive going bad. I would definitely run a disk check. And, check the system event log as well.
I agree with Al, seeing POST code 0x31 is an indication that a Crisis Recovery has occurred as a result of corruption being detected in the BIOS/firmware (flash component). Restoration of the BIOS/firmware via the Recovery Method is the thing to do. Replacing the CR2032 battery on the board may be needed as well; this board is approaching 5 years in age.
Thank you Al Hill and N. Scott Pearson for contributing on this thread.
JIFrederick in case you need some help locating the battery on this motherboard you can check this link: