Random switching on internet loss

Troubleshooting a puzzling problem
My Firewall reboots every evening at Midnight
When it does a few Kasa smart devices randomly switch on. The bedroom lamp is plugged into a Kasa smrt plug and the Upstairs bathroom lights+fan have Kasa Light Switches. Other items may switch on but I can’t see them from bed.
I tried adding conditions to ignore inputs at midnight, didn’t help. so i think it is Kasa
Suggestions? Troubleshooting links? Others with similar problem?

The firmware on some devices allow you to mandate the default start up behavior, like on/off/last state. Check the integration screen to see if these do that.