Cape Town - Dale Steyn took his second five-wicket-haul of the series to contain India to 364 all out but he could not prevent Sachin Tendulkar from reaching his second Test century at Newlands, the 51st of his career.
Using the second new ball to his advantage, Steyn took two wickets in four balls after lunch and another two after tea on the third-day of the third and final Test at Newlands on Tuesday.
Not to be outdone, Harbhajan Singh retaliated at the end of the day, taking two quick wickets in five balls as South Africa were 52 for two when stumps were drawn with Alviro Petersen on 29 and Hashim Amla yet to score.
The wily spinner trapped both Graeme Smith (29) and nightwatchman Paul Harris (0) leg before wicket which brought Amla to the crease.
In a day full of action, Steyn produced a fine display of swing bowling to finish with 75 for five from 31 overs, the 16th Test "five-for" of his career.
"It was more fulfilling because (Jacques) Kallis was not there to bowl for us so we had to do all the extra work and it was really hot out there," said Steyn.
His first scalp of the day was Cheteshwar Pujara (2) trapped lbw to a ball, which pitched around leg stump, swung away late and hit him on the back leg.
In his next over, Steyn bowled another perfect out- swinger to Mahendra Singh Dhoni, who played it straight to Ashwell Prince at third slip for a duck.
The excitement continued when Harbhajan Singh survived a peach of a ball from Steyn which deviated on its way through to the keeper. There was a huge appeal but television replays showed that the ball glanced the off-stump, however, the bails remained intact.
After tea, a well-directed bouncer from Steyn ended Harbhajan's punchy innings of 40. He was caught by substitute fielder JP Duminy at deep square leg.
Added to Virender Sehwag's wicket on Monday, Steyn's final wicket came from a bouncer which Ishant Sharma should have resisted but instead skied into the gloves of Mark Boucher.
Steyn downplayed his number one world ranking and stressed that statistics didn't help when you were on the field.
"As you saw today, even Zaheer Khan can hit me for six," he said.
"You just have to put the ball in the right area and hope for the best.
"The most important thing now is that we bat well and get into a position where we can't lose this game."
Sachin Tendulkar, oblivious to all the drama unfolding around him, marched on to achieve his second century of the series. He had been at the crease for five-and-a-half hours and brought up his 100 with a six off Morne Morkel, which he top-edged over Boucher's head.
It took a great ball from Morkel to remove Tendulkar's off stump. His 146 came off 313-balls, which included 17 fours and two sixes.
Zaheer Khan made a quick 23 from 22-balls until he gifted Morkel his second wicket.
The partnership of the day was 176 runs off 363 balls, shared between Gautam Gambhir and Tendulkar who resumed India's innings on 234/2.
Gambhir had led a charmed life for his 93, however but his luck came to an end when he edged Harris to the wicketkeeper.
The fluke dismissal of VVS Laxman (15) was the second time in the innings a non-striking batsman was run out following a dropped catch.
Tendulkar went down the track to Harris and smashed the ball back towards the bowler. Harris got a right hand to it but it went on to hit the stumps at the other end with Laxman out of his crease.
Rahul Dravid had suffered a similar fate on Monday when Gambhir was dropped by Petersen but AB de Villiers was quick to pick up the ball and fire it at the stumps as the batsmen set off for a run.
Harbhajan said he thought India had a slight edge but they still needed to bowl well on Wednesday.
"Our first target is to get them out. There's still a lot of help for the bowlers but you have to hit the right areas.
"If we can get the two key wickets of Amla and Kallis early, then we'll be in the driving seat," he said. Harbhajan was thrilled with his partnership of 76 with Tendulkar, of which he contributed 40 of the runs.
"I always enjoy my batting. I'll never be a Tendulkar or a Dravid but I hit two sixes today and I was really happy with that. I'm also very pleased I contributed to the batting today.
"Of course, it would have been nice to get another 50 or 60 runs - I'm always greedy for more."
Gautam Gambhir c Boucher b Harris 93
Virender Sehwag c Smith b Steyn 13
Rahul Dravid run out (De Villiers) 5
Sachin Tendulkar b Morkel 146
VVS Laxman run out (Harris) 15
Cheteshwar Pujara lbw b Steyn 2
Mahendra Singh Dhoni c Prince b Steyn 0
Harbhajan Singh c sub (JP Duminy) b Steyn 40
Zaheer Khan c Prince b Morkel 23
Ishant Sharma c Boucher b Steyn 1
Shanthakumaran Sreesanth not out 4
Extras: (20lb, 1w, 1nb) 22
TOTAL: (all out) 364
Fall of wickets: 1-19, 2-28, 3-204, 4-235, 5-237, 6-247, 7-323, 8-341, 9-350, 10-364.
Bowling: Dale Steyn 31-11-75-5, Morne Morkel 29.1-7-106-2 (1nb, 1w), Lonwabo Tsotsobe 26-5-82-0, Paul Harris 29-8-72-1, Alviro Petersen 2-0-9-0. ^South Africa 2nd Innings=
Graeme Smith lbw b Harbhajan 29
Alviro Petersen not out 22
Paul Harris lbw b Harbhajan 0
Hashim Amla not out 0
Extras: (1nb) 1
TOTAL: (for 2 wickets) 52
Fall of wickets: 1-50, 2-52.
Still to bat: Jacques Kallis, AB de Villiers, Ashwell Prince, Mark Boucher, Dale Steyn, Morne Morkel, Lonwabo Tsotsobe.
Bowling: Zaheer Khan 5-0-25-0 (1nb), Shanthakumaran Sreesanth 5-1-20-0, Ishant Sharma 3-0-3-0, Harbhajan Singh 3-0-4-2.
Series: Three-match series level at 1-1.
Umpires: Ian Gould, England, and Simon Taufel, Australia.
TV umpire: Brian Jerling, South Africa. Match referee: Andy Pycroft, Zimbabwe.
South Africa - Graeme Smith (capt), Alviro Petersen, Hashim Amla, Jacques Kallis, AB de Villiers, Ashwell Prince, Mark Boucher (wk), Lonwabo Tsotsobe, Dale Steyn, Paul Harris, Morne Morkel.
India - Gautam Gambhir, Virender Sehwag, Rahul Dravid, Sachin Tendulkar, Vangipurappu Laxman, Cheteshwar Pujara, Mahendra Singh Dhoni (capt, wk), Harbhajan Singh, Zaheer Khan, Ishant Sharma, Shanthakumaran Sreesanth.