Apple TV automation turn off or disconnect, possible?

I am running HA 2021 on Ubuntu with Apple TV and Unifi integration already setup.

With unifi integration I setup a binary switch for Apple TV Mac address, I tested and it works, when I turn off it disconnect internet to Apple TV.

My goal is write an automation where when Apple TV is turned on, it waits for an hour and if its still on then disconnect its internet. (Its a parental control to allow my kids to watch tv only for certain time). I could set another automation to turn it on back next day.

possible? of if you have any other ideas or advice I greatly appreciate. thanks.