After three group matches, Morocco secured seven points, while Croatia had five points after their goalless draw with Belgium in the second group match.
The winger, though, earned all three points for the Club World Cup Champions in the 89th minute as he smashed in a Marcos Alonso cross at the back post.