Maybe install a TOF (time of flight) sensor on the wall to measure exactly how much toilet paper is still left. Just to remove the human factor…
What happens when you press that button?
The SO gets a notification about missing toilet paper?
Does it have a motion sensor?