Apache has had some horrific problems operating in an marine (as in ocean) environment, for starters. The AH-64A was evaluated in a naval role by multiple countries including the UK, Canada and Japan as well as the US. While the US program was cut short by lack of funding, none of the other countries found the chopper held up well in a seaborne environment and scrapped the idea.
The AH-64D version has had some interest in trying it again - the US has trialed it on multiple Navy ships in 2013 and the Brits flew them off HMS Ocean in 2011 during their operations in Libya, but again nobody seems to think this would be a good idea long term. The Brit version that’s built under license/from kits is even navalized and has folding rotor blades for use and storage on RN vessels, but that hasn’t worked out that well in practice.
Another issue is logistics - the Viper has commonality with the current Huey variant in service today (which itself is recent) and a lot of other USMC rotorcraft. Less parts to stock or haul around.
Golly, I assume the Cobra had to be modified for seaborne ops too, seeing it started life as an Army platform too...
Not too sure how one jet engine powered rotor craft would fare better than another in similar environments, with proper protections and treatments.
As far as operating in a seaborne condition, I saw lots of AH64s in Panama, Korea, Kuwait and several other near shore situations, so sea air is not an issue. What is? Folding rotor- build a mod .
Bottom line is the USMC doesn’t want (another) Army machine.