It could also be your crank position sensor is going bad or as mentioned, the relays in the RCM are bad.
Symptoms: The car dies when the engine is hot, wait 20 minutes then car starts up.
Both are in expensive repairs.
Send your RCM out to tighed1 to be refurbished. He did mine about a year ago and it works perfect. The horn also works without the key in the ignition.
His price is a 3rd of a new RCM and his turn around is very quick. When I sent mine out, I had a spare RCM that I replaced it with until my original one came back.
When I got the original one back, I put it back in and kept the other one as a spare. I'm going to send that one out to be refurbished as well.
Here's a link to replacing the RCM:
LINK to RCM replacement
While your RCM is out, replace the crankshaft position sensor. Use BOSCH only.
Here's a post on how to replace the CPS:
LINK to CPS replacement