In 1952, Eisenhower ran as an Independent in South Carolina, while in 1956 he ran as a Republican. For 1952 "From the time Eisenhower announced he would run on an independent slate nominated by the many dissident Democrats, he gained substantial support, most especially in the small black-majority rural counties where only whites voted."
https://en.wikipedia.org/wiki/1952_United_States_presidential_election_in_South_Carolina#Vote In 1956, a Dixiecrat electors slate actually beat Eisenhower for second place. So the Republican brand in the 1950s may have still been a significant liability in South Carolina. As for SC being close in 1960, that was could be due to Kennedy's Catholicism, as well as a general trend away from Democrats there.