Cellphone type power button

Seatch for arduino turn itself off with transistor.

You can have power to the arduino controled by a transistor.
The arduino itself controls the transistor.

You press and hold a button.
The button temporarily powers the transistor.
The arduino turns on
The arduino then maintains power to the transistor and from that point is in control
Later you press and hold the power button.
The arduino sees that and removes power from itself