Chennai, Oct. 28:South Africa clung on to beat Pakistan by one wicket in the best game of the World Cup so far.
Chasing 271 in Chennai, the Proteas were in charge while Aiden Markram was at the crease, only for Markram to fall for 91 in a slide from 235-5 to 250-8.
Time was not an issue, but the South African tail was tasked with finding 21 runs against a pumped up Pakistan attack.
Keshav Maharaj and Lungi Ngidi edged South Africa closer, before Ngidi was athletically held by Haris Rauf in his follow-through with 11 still needed.
Amid incredible tension, Pakistan reviewed an lbw shout against number 11 Tabraiz Shamsi from the final ball of Haris' spell. The not-out decision was upheld by the narrowest of margins, despite the ball being shown to be hitting leg stump.
With the pacemen bowled out, Pakistan had to return to spin and Maharaj pulled Mohammad Nawaz for the winning boundary with 22 balls to spare.
South Africa, who go top of the table, had earlier bowled out Pakistan for 270 thanks mainly to an enchanting spell of 4-60 by left-arm wrist-spinner Shamsi.
The Proteas' only defeat in six games was a shock loss to the Netherlands. They join India on 10 points, but go above the hosts on net run-rate, albeit having played a game more.
Victory against New Zealand in Pune on Wednesday will probably be enough to secure a spot in the last four.
For Pakistan, a fourth defeat in six games makes it incredibly difficult to reach the semi-finals.
Even if they win their final three matches, they will need some unlikely results to go their way.
Proteas pull one out
South Africa have a history of impressing in the early stages of World Cups, only to then find bizarre ways to be eliminated.
So far in India, bar the aberration against the Dutch, they have looked an all-round package. This win was noteworthy for it being their first victory batting second at this tournament. It is their first defeat of Pakistan in any World Cup - 50-over or T20 - since 1999.
Still, they came incredibly close to throwing it away. From 136-4, the unflappable Markram had an ally in David Miller. The fifth-wicket pair added 70 to put the game within South Africa's grasp.
But Miller's dismissal, edging Shaheen Afridi behind, began nervy moments, especially for new arrival Marco Jansen. Markram began a counter-attack. Jansen joined in, launching Haris for a straight six, then was dismissed next ball with 36 still needed.
Even then, Markram was in control, but played a wild hack at leg-spinner Usama Mir, brought into the game as a concussion replacement for Shadab Khan. When Gerald Coetzee edged Shaheen without further addition to the score, Pakistan were favourites.
Maharaj and Ngidi played and missed, and were uncertain with their running between the wickets. Shaheen charged in, but exhausted his 10-over allocation, while fellow pace bowler Mohammad Wasim battled cramp.
Haris, though, had one over to bowl and energy in reserve. When Ngidi chipped the ball back, Haris swooped to take a spectacular catch.
Then came the decisive moment. Shamsi was struck on the pads by his second ball from Haris.