Ballistic Anti-Ship Missiles
An Inter-Continental Ballistic Missile (ICBM) can hit within 30 meters of a stationary target, and most were built before GPS allowed more accurate results. Satellite targeting and guidance should allow an ICBM launched from North Dakota to destroy any stationary ship on Earth with a conventional warhead. These missiles are expensive, but warships are far more expensive.
ICBM warheads can dive down upon a ship at Mach 6 from outer space using inertial guidance or GPS data. They may be used against moving ships with sensors on their warheads to lock onto the ship during its last few seconds of flight. Ship anti-air radar can provide just couple seconds warning, so it could not even attempt to shoot down these incoming warheads. Just the impact of a Mach 6 missile will obliterate any ship, and even near misses may cause damage even with conventional warheads.
Trident submarines can launch ballistic missiles as well, allowing them to destroy large surface warships at great distances. The USA fires several of these missiles each year to test reliability and rotate inventory, so it will cost little to attempt to hit a slow moving target ship at sea. Dominating the world's oceans from North Dakota will prove much safer and cheaper than using fleets of ships. An aircraft carrier docked at a pier on in dry-dock for repairs is a nice target for a conventional ICBM.
China developed an anti-ship ballistic missiles designed to strike ships at sea, a variant of the DF-21 (CSS-5) intended to counter to carrier task groups. It conducted a successful test (below), which shows the foolishness of basing large American warships in Japan.