What’s wrong with Screen Time and having your spouse define the PIN for it? I can request an additional minute myself, but after that only my spouse can grant me an exception.
You can also use an online time-lock service such as lockmeout.online to store the PIN for ScreenTime or assistive access (even better as it dumb down the UI).
Years ago I had this problem, but I didn't know about these services, so I had to keep the PIN data myself without being able to access it on a whim. I developed timelock for this purpose: https://github.com/rayanamal/timelock