Miners are required to provable expend effort in order to become eligible to produce a block. 2nd law of thermodynamics as core security mechanism, as it cannot be reversed.
If you were to improve efficiency by routing excess heat for other purposes, it will gradually spread across the entire mining industry, and eventually you end up right where we started.