A second-half strike from Sunderland’s Wahbi Khazri ensured Tunisia ended their World Cup Group G campaign with a victory, as Panama finished bottom.
The north African side, who had 14 chances, fell a goal behind when Jose Luis Rodriguez’s effort deflected in off Yassine Meriah.
Fakhreddine Ben Youssef equalised when he tapped home Khazri’s low ball.
The provider of that goal then scored his second of the tournament when he fired home Oussama Haddadi’s cross.
Khazri leads way for Tunisia
In the build-up to this match, Tunisia coach Nabil Maaloul had said his team were “two generations” from reaching the level needed be competitive against the best sides in world football.
Aside from the 5-2 defeat by Belgium, that assessment is perhaps a little harsh as his side almost earned a point against England before this deserved victory.
They often overwhelmed their opponents in attack inside Mordovia Arena, with Khazri the heartbeat of their attack.
His pinpoint cross for Ben Youssef helped Tunisia draw level, before he settled the contest with a close-range finish – the 2,500th in World Cup tournament history.
Khazri was denied a second goal, his third of the tournament, by a exceptional one-handed stop by keeper Jaime Penedo.
The 27-year-old midfielder might be a man in demand after his displays in Russia – Sunderland say they have already rejected offers, and may now have to consider more.
More to follow.