The Sandinista government became consumed with fighting a war of survival. They were up against the biggest superpower in the world.
What happened in America in the 1860s was a war of secession a war of independence no different in principle from what happened in America in the 1770s and 1780s.