The official framework mainboard 3d printed case uses a compliant mechanism to push the power button, you can take at look at the open source STL files to see how they designed it for inspiration/reference.
https://github.com/FrameworkComputer/Framework-Laptop-13/tree/main/Mainboard/Printable Case
For those who don’t know much about him, I recommend watching the movie Revolution OS. It does a good job showing what he was working towards.