South Africa 342 and 49 for 4 (Markram 35*, Joseph 2-17, Holder 1-0) lead West Indies 212 (Reifer 62, Blackwood 37, Nortje 5-36, Rabada 2-44) by 179 runs
Eleven wickets fell in the final session of the day as both teams suffered collapses in the 28.1 overs that were bowled. But it was West Indies slumping from 169 for 3 to 212 all out that turned the game around after two sessions of slow burn.
South Africa started their second innings with a 130-run lead, and Aiden Markram took off from where he left in the first innings, this time, with more aggression from the start. He drove, cut and pulled with ease to finish the day on 35 not out off just 33 balls.
His flyer took the hosts to 31 in under four overs, but Alzarri Joseph had Dean Elgar fall into the deep-third trap for the second time in this game, to re-open the wicket-flow gate. Kemar Roach and Joseph went jaffa for jaffa in the next two overs to have Tony de Zorzi and Temba Bavuma - who bagged a pair on captaincy debut - caught behind.
Keegan Petersen got one of the two boundaries in the seventh over and another quiet over later, a safe end to the day was in sight. But Jason Holder came in and took his 150th Test wicket off his first ball. It hit a length and stayed low to trap Petersen lbw to end the day.
Earlier, Anrich Nortje, with 5 for 36, was the chief destructor with the ball for South Africa. He oversaw West Indies go from 136 for 3 at tea to 212 all out, including a collapse of 7 for 43. South Africa's pacers ripped through the middle and lower order, with every batter after the top six dismissed for single-digit scores.
Kagiso Rabada and Marco Jansen were responsible for drying up the runs, particularly in the second session, when the hosts picked up just one wicket
Jansen initiated the second final-session collapse in two days by getting Raymon Reifer - the highest scorer of the innings - to knick off for 62, with a length ball that straightened off the pitch. Rabada had Roston Chase caught in the crease and squared up to find the outside edge off the next ball.
It was then Nortje's time to strike. A short and wide loosener from him led to the soft dismissal of Joshua Da Silva, who found point on the cut shot. Jason Holder was also squared up and caught at slip for a duck. Sixteen balls of frenetic action accounted for four wickets, and at 179 for 7, put the visitors in an irrecoverable position.
Nortje had Alzarri Joseph caught at point in a dismissal similar to that of Da Silva's. Kyle Mayers looked to counterattack but it came too late. He creamed a cover drive and nailed a couple of pulls but almost found deep point on the cut shot before holing out to deep fine leg on the pull. It completed Nortje's five-for and was the third 'c Jansen b Nortje' that appeared on the scorecard.
A frustrating 31-ball stand between Kemar Roach and Shannon Gabriel kept the hosts out for a few extra minutes but the innings was wrapped up in 69 overs.
Before their collapse, West Indies did get a decent start to their innings. Kraigg Brathwaite saw through six overs of the new ball before getting knocked over by a delivery that straightened off the pitch.
Tagenarine Chanderpaul mixed compact defence against good balls with an opportunistic attack of the looseners. Chanderpaul's percentage play earned him 22 runs and allowed Reifer to settle in before it cost his wicket. He slashed an off drive to Senuran Muthusamy at gully. But Blackwood joined Reifer to put up 64, the highest partnership of the innings.
The pacers continued to apply pressure in the second session to ensure only 65 runs were scored. Rabada started and Nortje took over the aggressor's role in the afternoon. Nortje cut Blackwood in half to beat the bat in the 35th over. Twenty-one balls and six runs later, he did it again. This time, the full ball took the inside edge of the full-faced drive and Heinrich Klaasen took the catch.
Compact defence and resilience from the batters meant only one wicket fell but with a session run rate of 2.24, the game was still in the balance.
Reifer reached fifty early in the session, Chase was beaten and hit by Rabada in the 52nd over but moved forward. He got two boundaries in successive overs and the singles and twos came by to ease the pressure. That was until collapse 2.0 took over proceedings.
South Africa had started the day on 314 for 8. Rabada, Coetzee and Jansen made 28 in 27, they punished full balls but could not stop Joseph from registering his first Test five-for.