Mozambique scored two goals in the stoppage time to hold Ghana to a 2-2 draw while Ivory Coast were thrashed by Equatorial Guinea, to leave both clubs on the brink of early exits at the Africa Cup of Nations.
In Group B, two penalties from Jordan Ayew had Ghana comfortably ahead and looking well placed to finish second in the group behind the Cape Verde Islands, but a late rally handed Mozambique a share of the spoils.
It was not enough for Mozambique, who finished bottom of the group, but only behind Ghana on goal-difference.
Two points from three matches is not likely to be enough for Ghana to qualify for the knockout rounds as one of four best third-placed finishers.
Meanwhile, Equatorial Guinea produced the biggest upset in Africa Cup of Nations history with a 4-0 thumping of hosts Ivory Coast that put the small country into the last 16 as Group A winners and left the hosts facing potential elimination.
Emilio Nsue scored two goals to take his tournament tally to five and Pablo Gannet and Yannick Buyla added two more as the country of 1.6 million swept aside the home team with a sensational result.
The former Spanish colony finished top with seven points, ahead of Nigeria on goal difference.
Ivory Coast could still go through to the knockout phase as one of the best third-placed finishers but face an anxious wait over the next days to see whether they make it.


Lionel Messi, Miami score four in second half to upend Orlando
Arsenal claim nervy win over Chelsea, Man Utd go third
Samson guides India to T20 World Cup semis; South Africa beat Zimbabwe
Daniil Medvedev handed Dubai title after Griekspoor withdrawal
England beat New Zealand to keep Pakistan's T20 World Cup hopes alive
