Your automation’s design appears to have been based on ideal operating conditions and overlooked to mitigate failure scenarios such as:
- the controlled device becomes unavailable
- the transmitted command isn’t received
- there’s a restart while the automation is executing its actions
- there’s a restart when a Time Trigger was supposed to fire
Your suggestion to automatically resume from wherever it was interrupted isn’t optimal; the conditions that originally triggered the automation may no longer be applicable after a restart.
You will have better control by simply adding a trigger to the automation that detects a restart and then proceeds to handle the situation appropriately. I have several critical automations that use this technique to make them more fault-tolerant.
The following (old) post offers a few ideas on how to mae an automation more robust.