The American Civil War, fought from 1861 to 1865 over the secession of the Confederacy, began after the election of Abraham Lincoln, whose Republican Party opposed the expansion of slavery. Eleven southern slave states declared secession and formed the Confederate States of America, while the other 25 states supported the federal government. Hostilities opened on April 12, 1861, when Confederate forces attacked Fort Sumter in South Carolina, and Lincoln called for volunteers to recapture federal property. Early fighting in the East was inconclusive, though Confederate forces defended Richmond and later saw their Maryland campaign end at Antietam in September 1862, discouraging British intervention. Soon afterward, Lincoln issued the Emancipation Proclamation, making the ending of slavery a war goal. In 1863, Robert E. Lee's invasion north ended at Gettysburg, while in the West the Union gained control of the Mississippi River after Shiloh and the Siege of Vicksburg, splitting the Confederacy. In 1864, Ulysses S. Grant took command in the East and coordinated offensives by William Tecumseh Sherman, Philip Sheridan, and others. Grant pressed Lee through the Overland Campaign and the Siege of Petersburg, while Sherman captured Atlanta and marched to the sea, destroying Confederate infrastructure. After Petersburg fell, Lee retreated and was pursued until he surrendered to Grant at Appomattox Court House on April 9, 1865. The war, one of the earliest true industrial wars, made extensive use of railroads, the telegraph, steamships, and mass-produced weapons, and its trench warfare and total war tactics foreshadowed later conflicts. It was the deadliest war in American history, causing an estimated 750,000 soldier deaths and an unknown number of civilian casualties. Union victory ended the Confederacy and slavery in the United States, strengthened the federal government, and left social, political, economic, and racial issues that shaped Reconstruction until 1877.