Sounds like it's was over heating due to dust :) whether or not the heat damage has affected things is unknown , the hdmi isue is a new symptom I take it ....
i can understand the rebuild of the hdd , and or a complete reinstall of everything dew to ps4 crashing while it is running will have the potential to currupet the data on the Hdd :)
for hdmi isues , first look at the connections on the cable and on the ps4 , to see if any pins are miss lined as there was isues on the first ps4 that this may occur . And try a diffrent hdmi cable :)
the other thing I would do is run it in safe mode to see if the screen keeps on ......