From schiffer.tech
DefShutdown is a shutdown software that forces your device to turn off straightaway. After granting the required permissions DefShutdown will force your device to turn off after six hours of running. You can manually extend the shutdown countdown for an hour by clicking the tile once.

Requires Android 6 or newer.
You can download it here: DefShutdown for Android™ - schiffer.tech

Information: This app requires root access!
Warning: An instant shutdown might cause data loss! Use at your own risk!

We hope for feedback on possible errors so that we can further improve the product.