Is there distance requirement for the service panel to be X" away from the edge of a in ground swimming pool?
Added: The only thing that I can find is 60" but not necessarily related to service panel.
You won't find anything related to service panel distance from the pool. All you will find is distances for underground wiring, receptacles, transformers, junction boxes, etc.
Generally, nothing closer than 5' but a few exceptions which limit how you need to run underground wiring in raceways.
The equipment should not be within 5 feet of the pool minimum, IMO...10 feet would be better like in 680.22(D). Maybe a code rule is needed to address this.
Also the chlorine water would corrode the panel...so it would have to be suitable for the environment.