Flexible three-dimensional nanoporous metal-based energy devices.