The American Civil War caught both sides unprepared.  How didn't the war effect both sides?