When I was working with Linux kernel and coreboot I digged into the datasheet of my motherboard chipset to troubleshoot my unresponsive power button. It was pretty complicated, the kernel driver of the power button (yes, it's a thing!) actually first communicates to the EC/keyboard controller, and setup a GPIO input for the button to the appropriate mode and then hook an interrupt handler to it, finally it reroutes the interrupt of the EC to southbridge to generate an ACPI power-managerment event (PME), which triggers the actual hardware wakeup from suspend (it's not a standard x86-compatible machine although it uses x86 peripheral chips). If UEFI/ACPI is involved, the whole process would occur at a different layer.
So I started to think often since then: "What happens when you press the power button" can be the hardware-equivalent to that interview question. It seems to be a good question for a variety of hardware engineering fields, including simple embedded systems and complex computer systems.