Johannesburg - South Africa moved ever closer to victory as Pakistan were teetering on 104 for four at tea on the third day of the first Test at the Wanderers on Sunday.
Still needing 375 runs to avoid defeat, Pakistan lost three wickets in the afternoon session while adding 57 runs.
After doing all the hard work against a fierce pace attack, opening batsman Nasir Jamshed pulled a delivery from Dale Steyn straight to Robin Peterson at mid-on. It was a soft dismissal for the Test debutant after playing so well for his 46 runs.
Live scorecard from the Wanderers
VIDEO: SA vs Pakistan 1st Test day 2, highlightsHis partnership with Azhar Ali lasted for 107 deliveries and yielded 57 runs, including nine boundaries.
Ali lasted a couple more overs before he was trapped lbw to Jacques Kallis for 18.
Younis Khan survived a review by the South Africans for a similar call. Despite the HawkEye camera showing the ball would have shaved leg stump, the umpire’s not-out call stood because more than 50 percent of the ball had to be hitting the stump.
He was less fortunate when he got a faint edge to a wider delivery from Morne Morkel - which could be argued was also a no-ball - providing wicketkeeper AB de Villiers with his eighth catch of the match.
It was a key wicket for the hosts as partnerships and time at the crease had become paramount for the Pakistanis and Younis would have done better to leave the wide delivery alone.
Misbah-ul-Huq and Asad Shafiq went into the tea break on 8 and 13 respectively.
Earlier, South Africa declared their second innings on 275 for three, midway through the morning session, with a lead of 479 runs.
They continued to dominate the match as Hashim Amla and AB de Villiers surpassed their own previous best fourth-wicket stand of 147 at the Wanderers. They added 176 runs, off 217 balls, before skipper Graeme Smith waved them back into the pavilion.
Smith waited for De Villiers to complete his 15th Test century - which came off 117 balls and included 11 boundaries - while Amla remained on 74 not out.
While Pakistan survived some hostile bowling from Dale Steyn, it was Vernon Philander who made the breakthrough in the fourth over of their second innings.
Mohammad Hafeez (2), looking to play Philander down the leg side, got an edge and De Villiers took an outstanding catch to dismiss him.
While the ball kept low at times, Nasir Jamshed and Azhar Ali both played some magnificent shots and steered their side to 47/1 in the 14 overs Pakistan faced before lunch.