Cristiano Ronaldo powered-home a fourth-minute header to give Portugal a 1-0 World Cup victory over Morocco that took them top of Group B and meant the unlucky North African side become the first to be eliminated from the tournament.
Ronaldo's fourth goal of Russia 2018, following his hat-trick in the 3-3 draw with Spain, took the European champions to four points.
Morocco, who had a real go at the Luzhniki Stadium but failed to convert their chances, are pointless having also lost 1-0 to Iran and cannot progress to the second round.
Portugal struggled to impose themselves and ended up defending for long spells, leaving coach Fernando Santos unimpressed. "We have to look at this, we lost control of the game," he said.
"We misplaced a lot of passes, we lost confidence... it was inexplicable. If in a match against players like they have, if you don't have the ball, they wear you down and you get into trouble."
Despite their battling display, Morocco will rue the unforgivable defending that made all their subsequent good work irrelevant.
They qualified for the finals without conceding a goal in six matches yet somehow opted against marking the most dangerous attacker at the tournament in the six yard box when Joao Moutinho swung in a cross from a short corner and Ronaldo duly buried the header.
It was his 85th international goal, taking him beyond Hungarian Ferenc Puskas's European record, with only Iran's Ali Daei ahead of him on 109.
Morocco, in their first finals appearance for 20 years, regrouped well and showed some real positivity in attack with Hakim Ziyech and Nordin Amrabat seeing plenty of the ball and Amrabat furious at not being awarded a penalty after wrestling with Raphael Guerreiro.
The midfielder had begun the game with head protection after being seemingly knocked unconscious against Iran five days ago in a sight that will have left medical professionals fuming about football's feeble concussion protocols.
When they managed to stop appealing and resumed play, Morocco looked dangerous and were the dominant side in the second half.
Portugal goalkeeper Rui Patricio made a fantastic diving low save to touch clear Younes Belhanda's sharp header but Medhi Benatia's blazed effort over the bar was more typical of their finishing from half-a-dozen reasonable chances.
"I'm not disappointed about the performance, I'm happy with it and very proud of my players," emotional Morocco coach Herve Renard told reporters.
"As in the first game, we had a lot of chances and I won't criticise anyone."
Portugal complete their first-round against Iran while Morocco face Spain, both on June 25