I had this problem with a Lenovo legion 5 15ARH05H. It would freeze almost daily then I would have to manually shut down from the power button.
I solved it by getting a new M2 SSD, installing Windows 10 21H2 and booting from it.
It's been 3 weeks now with no crash, the old SSD / windows installation was the problem for me. I still use the old SSD for extra storage but no longer booting from it.
In the months before this, I tried every possible fix and nothing worked: disabling hardware acceleration, windows10 repair, updating bios/video card/motherboard drivers, changing startup programs & services, looking at event logs etc.
I also advise you guys to consider disabling the hidden battery setting "Processor performance boost mode", it will make your CPU temperature drop from 90 to 70 degrees max while gaming with no noticeable impact on performance. You only have to modify a registry key to make this option visible, you will find many guides on the internet.