Belgium and the Netherlands claimed Groups B and C respectively at Euro 2020 with victories over Finland and North Macedonia while Denmark and Austria took the runners-up spots.
The Belgians, the world's top ranked team, wore down Finland in Saint Petersburg and scored twice in the last 15 minutes. Finland goalkeeper Lucas Hradecky had kept his side in the match with a series of fine saves.
But he was unfortunately credited with an own-goal after Thomas Vermaelen's header hit the post and rebounded off him into the net.
Romelu Lukaku doubled the score nine minutes from time with a record- extending 63rd international goal.
Finland, who finished third in their first major international competition. still have an outside chance of advancing to the last 16 as one of the four best third-place teams.
Denmark claimed second spot in Group B following a 4-1 destruction of Russia in Copenhagen.
Mikkel Damsgaard opened the scoring for Denmark just before half-time and Yussuf Poulsen increased the advantage after 59 minutes.
Artem Dzyuba pulled one back for the Russians from the penalty spot 10 minutes later to give them hope of a draw and finishing second.
But Andreas Christensen's thunderbolt from 25 metres restored the two goal advantage and Joakim Maehle slotted in the fourth after 82 minutes.
Denmark boss Kasper Hjulmand said: "I'm out of words regarding my admiration for this team. They are so strong. I want to thank all of Denmark ... the love and care that the whole of Denmark has shown us helped the boys' power go into their legs and out in this stadium."
The Danes will take on Wales in Amsterdam on Saturday in the last 16.
Austria got the second spot in Group C after edging past Ukraine 1-0 at the Arena Nationala in Bucharest.
Christoph Baumgartner grabbed the only goal of the game mid-way through the first half to advance to the knockout stages at the Euros for the first time.
The Netherlands are, by contrast, old hands at the latter stages of the tournament.
And they reached the knockout rounds after cruising past North Macedonia 3-0 in Amsterdam courtesy of a goal from Memphis Depay's and a brace from skipper Georginio Wijnaldum.