Argentina's hopes of making it into the last 16 were hanging by a thread after a 0-0 draw with Austria in Wellington but sitting on two points in Group B leaves it on the edge of the abyss, waiting on results elsewhere.
New Zealand's win over Myanmar later in the day sealed its fate as it could not gain one of the four spots reserved for third-placed teams.
The pre-tournament favourite threw all it could at a red sea of defenders separating it from its target of a top two place in the group.
The Austrians stood strong to qualify in second spot behind the Ghanaians and book a trip to Whangarei in the round of 16.
Panama, which exited the tournament as a result of the Ghana defeat, was undone by a solitary Emmanuel Boateng goal 10 minutes from time and missed a late penalty through Fidel Escobar.
Substitute Boateng gave Ghana the lead when he drove forward, twisted away from the challenge of Francisco Narbon and curled a superb 20-metre shot just inside the right-hand post.
Panama weren't done yet though and, after Jesus Araya had rattled the crossbar, they earned an 89th-minute penalty but Escobar - the man fouled - slipped on his run-up and sent a wayward kick high and well wide.
In the later games a superb second-half hat-trick from Viktor Kovalenko saw Ukraine leapfrog opponent United States to top Group A and reach the last 16 in style.
After a tight first 45 minutes the Europeans got into gear with Kovalenko dominating proceedings and sending himself to the top of the tournament's scorers chart.
New Zealand came from behind to defeat Myanmar 5-1 to give itself hope of reaching the knockout stages as one of four best third-placed teams.
The excellent Noah Billingsley equalised Aung Thu's superb opener before Monty Patterson pushed the Junior All Whites ahead minutes after the break.
A late collapse from the Asian side saw Joel Stevens, Sam Brotherton and Clayton Lewis score to bring the Kiwi goal difference back to zero and finally give the home fans something to cheer about.