(CNN) -- Its coach, Lucio Antunes, is an air-traffic controller, but not even he would have predicted that the tiny island of Cape Verde would soar into the quarterfinals of the Africa Cup of Nations Sunday.
The smallest ever nation to score and win at the tournament, Cape Verde defeated Angola 2-1 in Port Elizabeth, South Africa.
There are 10 islands -- with a population of just half a million -- which make up Cape Verde's archipelago.
But in its first ever appearance at the finals, where most were expecting it to fail, the 'Blue Sharks' have captured the imagination of the watching world with its fairytale story.
Antunes, whose side defeated the might of Cameroon in the qualifying playoff, had drawn with host South Africa and Morocco in its previous two group games.
And despite trailing 1-0 through an own-goal, the 'Blue Sharks' hit back with two strikes in the final nine minutes to see off Angola.
"My team and I dedicate this victory to the wonderful people of the Cape Verde Islands," he told reporters.
"Our objective at this tournament has been achieved. We wanted to reach the quarterfinals."
After earning independence from Portugal in 1975, Cape Verde had to wait 17 years before being able to play a competitive match.
But Antunes, who revealed before the tournament in an interview with CNN's Human to Hero series that he had received advice from Real Madrid coach Jose Mourinho, has created a team which is keen to make up for lost time.
And it showed all its fighting qualities after falling behind in the 33rd minute when skipper Neves put the ball into his own goal.
That setback appeared to rouse Antunes' side and after Gege had headed home an 81st minute equalizer, Heldon popped up at the death to fire home a dramatic winner.
Cape Verde progresses to the last eight along with host nation South Africa, which claimed a 2-2 draw against Morocco in an entertaining game in Durban.
Issam El Adoua and Abdelilah Hafidi put the Atlas Lions ahead only for May Mahlangu and Siyabonga Sangweni to level and condemn Morocco to a fourth consecutive first round exit.
It means the host, which has only won a single game in the past nine years at the tournament, finishes top of Group A, much to the delight of coach Gordon Igesund.
He told reporters: "We feel very, very proud to have achieved our first objective. I must thank the players and the fans.
"Morocco was a very tough team. I do not want to point out mistakes, but we conceded two goals we should not have done. There are now two games to the final and I believe in my players."
Rival coach Rachid Taoussi said: "I am very disappointed with the result, but we fought with dignity and honor. I am satisfied. We did not lose a game and the tournament was a positive one for me."