@ Rob and Wraper:
Heat inside the enclosure is not causing nearby components to fail. It is causing failure of the parts creating the heat, in this case the 7805, because of reduced temp gradient to cool it.
This why power resistor is better solution where applicable. Despite inside of case same temp as before it is still a huge improvement. Resistor can run at much higher temp with zero decrease to regulator max output.Two regulators helps, but not as much.
Despite same internal temp in enclosure, the parts dissipating heat are the hottest. Make hottest part a passive resistor with positivery coefficient of resistance to temp and can operate at tremendous temp without longterm failure is most foolproof with built-in safety/limiting in case of change in ambient temp.
Two regulator also is improvement.
Bigger heatsink, alone, is for sucker. Not best solution. Least efficient for space and cost per equivalent improvement in output and longterm reliability. You will never match improvement of series power resistor with heatsink, alone, until heatsink is huge and costly. And using smaller heatsink with power resistor, and pow, you are destroying heatsink-only solution by a huge margin that can't be touched. If overhead voltage was closer to 3 or 4 volts, then heatsink is fine. With over 7V overhead, heatsink alone is dumb brute-force method that is quite limited. In fact, OP never stated supply voltage, which is obviously at least 15V if he run 7812 on it. So at least 10V of overhead; at this point, bigger heatsink should not even be considered a solution, by itself. Even if current draw is very, very low, a small power resistor is more compact and cheaper than small heatsink. In such case, you do not need heatsink on the 7805, at all.
OP. To use series power resistor, start with max current draw and use kirchoff law to calculate value of power resistor. Leaving about 2V of overhead for the 7805 Regulator. So the 7805 needs minimum of 7V supply voltage. Rest can be dissipated by the series resistor when current is at max. At less than max draw, the series resistor won't drop as much share of the voltage, but that won't matter.