You don't list your motherboard model...it should have some kind of thermal protection for the cpu socket and read here
http://communities.intel.com/message/152129
and read this
http://www.thetomorrowtimes.com/2009/12/intel-core-i7-8...
the thermal protection for the cpu should've kicked in to prevent catastrophic damage to the cpu and components...by kicked in...I mean the system should've shut down if thermal protection kicked in which from what you posted...that's exactly what it did.
From there...since you rebooted successfully and was using the machine to play games...there should be no damage incurred.
Then you stated that you removed the stock heatsink and fan and then you reinstalled it without...changing the paste? or removed the paste and didn't put any on the cpu when you reinstalled the cooler?
Depending on which it was...thermal protection circuitry and sensors should've kicked in at some point....one a bit quicker than the other...and shut down the machine again.
You are now experiencing idle temps of 40C on the stock Heatsink and Fan or HSF?
First when you overclocked...I would say your temps at your overclocked speeds overwhelmed your stock HSF...thus creating a thermal overload and the thermal protection bsod the machine...the stock hsf is woefully poor as an air cooler at stock speeds much less overclocked speeds...so I looked here
http://www.sevenforums.com/performance-maintenance/7258...
and it seems that 40C isn't out of the normal range for idle on these processors.
I guess the next question would be is 40C way higher than before you began overclocking?
Also...I would say that the reason it's bsoding and acting up is because you either
A. didn't apply the paste correctly, or used too much, or used too little.
B. or you haven't got the cooler locked down fully or you smeared the paste when reinstalling the heatsink and fan.
C. You didn't mention what TIM paste you used so if you didn't get a quality paste and apply it correctly you have created a thermal interface that isn't performing as well as the original paste between your ? stock heatsink and fan? and since the stock HSF isn't able to deal with the heat from the cpu at stock OR OCed speeds now...I would say the paste you applied hasn't "cured" yet. All thermal paste has a "burn in" period where over time the interface performs better after curing and achieving lower temps...but usually we are talking anywhere from 20hrs to 200+ hours to achieve optimal conditions for the lowest temps and efficient performance out of the HSF and paste!
If it was me...and I truly believe you are having thermal issues here...I would invest about $35 and purchase this...
http://www.newegg.com/Product/Product.aspx?Item=N82E168...
The absolute most bang for the buck and this thing performs like mad...
I believe you will see your issues resolve themselves and rather quickly especially when attempting to game and this "Could" allow you to overclock successfully. I say "could" because each processor and motherboard and HSF combo performs "uniquely" or differently...the amount "if any" of achievable overclock is dependent on many different factors..but "HEAT REMOVAL" has to be effecient and effective no matter what...and the stock HSF isn't worth a hoot!!
Recheck that the HSF was reinstalled correctly and that you have good contact between the cpu top and the bottom of your HSF with a "very thin" layer of paste covering the entire top of the cpu and that the top of the cpu and the bottom are in "full" contact for even and efficient heat transference from the cpu to the cooler!!!
One of the best ways to spread the paste in an "EVEN AND PAPER THIN" layer is to use a single edged razor blade to lightly apply the paste over the entire top of the cpu heat spreader..."the top of the cpu itself".
Respectfully,
tekman42