The following only applies if you, or someone helping you, are very comfortable troubleshooting live 120/240 vac power.
Next time you lose power, disconnect your power cord FROM THE BACK of the trailer (leaving it plugged into the pedestal). Using a volt meter verify you have or do not have 120/240 vac at that end of the cord. That should prove the problem is either from the cord back to the pedestal (i.e. not the trailer) or in the trailer itself. See link below.
https://www.rvtravel.com/rv-electric...p-shore-power/