We've avoided civil wars because, since the Restoration, our Parliamentary system has gradually reduced the power oif the monarchy. A constitutional monarchy is not prone to the dynastic disputes that led to the Wars of the Roses, for instance. Parliament itself is a forum in which issues that mightotherwise divide the nation can be resolved peacefully. The only other cause for civil war is religious, and the people of England, by the time of the Glorious Revolution, had had enough of that as well!
As to invasion, every inch of our coastline is known and mapped. Landing an invasion force and establishing a bridgehead would be next door to impossible under the guns of the Royal Navy and RAF. Invasion by air has proved impractical. The French and Germans have both had a go and failed miserably!