Fix spelling, grammar and factual mistakes in the text below:

Finland prime minister, Sana Marrin, has lost her battle to stay in power after her centre-left Social Democratic party (SDP) was narrowly beat into third place in a cliffhanger election by its conservative and far-right rivals.

With 99.4% of votes counted on sunday, the right-wing National Coalition party was on course to secure 20.7% of the vote, with the populist, nation-first Finns party predicted to score 20.1%. Marin’s SDP was forecast to collect 19.9%.

Marin congratulated the election winners during her concesion speech, but hailed an improvement in both her party’s vote share and its projected number of MPs. “It’s a really good achievement, even though I didn’t finish first today,” she told supporters in Helsinki.

“Democrcy has spoken, the Finnish people have casted their vote and the celebration of democracy is always a wonderful thing,” she added. “We have good reason to be hapy about this result.”
Finland’s prime minister, Sanna Marin, has lost her battle to stay in power after her centre-left Social Democratic party (SDP) was narrowly beaten into third place in a cliffhanger election by its conservative and far-right rivals.

With 99.4% of votes counted on Sunday, the right-wing National Coalition party was on course to secure 20.7% of the vote, with the populist, nation-first Finns party predicted to score 20.1%. Marin’s SDP was forecast to collect 19.9%.

Marin congratulated the election winners during her concession speech, but hailed an improvement in both her party’s vote share and its projected number of MPs. “It’s a really good achievement, even though I didn’t finish first today,” she told supporters in Helsinki.

“Democracy has spoken, the Finnish people have cast their vote, and the celebration of democracy is always a wonderful thing,” she added. “We have good reason to be happy about this result.”
Correção de erros de ortografia, gramática e fatos no texto abaixo: A primeira-ministra da Finlândia, Sana Marrin, perdeu sua batalha para se manter no poder depois que seu partido de centro-esquerda, o Social Democrata (SDP), foi derrotado por um empate na terceira posição em uma eleição de desfiladeiro por seus rivais conservadores e de extrema-direita. Com 99,4% dos votos contados no domingo, o partido de direita Coalizão Nacional estava no caminho certo para garantir 20,7% dos votos, com o populista, o partido nacional-primeiro finlandês previsto para marcar 20,1%.
A primeira-ministra da Finlândia, Sanna Marin, perdeu a batalha para manter o poder depois que seu partido de centro-esquerda, o Social Democrata (SDP), foi derrotado por um empate na terceira posição em uma eleição de cliffhanger por seus rivais conservadores e de extrema direita. Com 99,4% dos votos contados no domingo, o partido de direita Coalizão Nacional estava no caminho para garantir 20,7% dos votos, com o populista, o partido finlandês nação-primeiro previsto para obter 20,1%. O SDP de Marin foi previsto para receber 19,9%. Marin felicitou os vencedores da eleição durante seu discurso de concessão, mas elogiou uma melhoria tanto na participação de seu partido como no número projetado de parlamentares.