Carolina Mendes and substitute Ana Leite gave Portugal a 2-1 win over Scotland in a clash of newcomers at the women's European championships in Rotterdam on Sunday.
Mendes scored against the run of play on 27 minutes after a cross from Diana Silva which Scotland defender Vaila Barsley comically failed to clear.
Scottish substitute Erin Cuthbert put Scotland level in the 68th minute with a clinical finish after being put through by Caroline Weir.
But Scotland's joy was short-lived as four minutes later, Leite sprinted down the middle and beat goalkeeper Gemma Fay with a low strike.
Scotland are now all but certain to miss out on the knock-out stages after consecutive defeats, but Portugal could reach the quarter-finals with a shock result against England in their final group game next Thursday.
"For now we are not thinking about England, we are enjoying this moment – it is our first time," said Portugal coach Francisco Neto.
"We will try our best, but we know England are in the top three of European teams in the rankings. But Portugal will fight with everything we have, for sure."
Portugal scored from their single shot in the first half, despite Scotland being more threatening up front, with Lana Clelland first firing wide and then seeing her shot tipped onto the post by keeper Patricia Morais.
Scotland found themselves under pressure early in the second half, with Carole Costa and Tatiana Pinto firing wide, just like Weir and Leanne Crichton at the other end.
Mendes then sent her left-footed effort just past the right post and Ana Leite fired over, while Weir hit the upright five minutes from the end as Scotland desperately tried to salvage their campaign.
Scotland coach Anna Signeul bemoaned the missed first-half chances.
"We should have been up 2-0 in the first half, but we could not put the ball in the net unfortunately, and then a counter and the ball takes that bounce off the defender and that was an unfortunate goal which put us on the back foot," she said.
England face Spain in Breda in the other Group D game later on Sunday.