After driving for more than 20 miles the engine stop running or cut off.
on 2005 Mazda Mazda3

Rookie cbe0621eac06868b3efe0d8d1d3611e23c60d3114864ea2ec19a68cfbd3eebab
Engine will not start till it is cools off. Then, it start on and off continually.
What could be the problem? The Engine turns off when it is hot. The fan is running but the engine still turns off.
(1) Answer
Check for codes and advice us so we can be of more help. From what you say it could be related to a bad sensor of some sort, or eleactrical issue.