In any election year, Brazilians say Independence Day - Sete de Setembro - is when campaigning really begins. But nobody could have predicted such an explosive start to the long weekend. Festivities took a dark turn on 6 September when populist candidate Jair Bolsanaro was stabbed during a rally.
And this is by no means an isolated incident in a country where violence is widespread and security continues to top the agenda. 2017 saw more murders than ever before - 63,880 were recorded by the Brazilian Public Security Forum. In March, left-wing councillor Marielle Franco was shot dead in her car. The fallout from the Car Wash corruption scandal - Lava Jato - had already led to the impeachment of a former president (Dilma Rousseff) and the imprisonment of another (Luiz Inácio Lula da Silva), making this one of the most fraught elections in Brazil's history.
Bolsanaro established a lead in the polls, appealing to concerns about crime and corruption. But, he's alienated many with calls to loosen gun laws and inflammatory rhetoric about women, gay rights and race.
A run-off looks likely between Bolsanaro and former São Paulo mayor Fernando Haddad, who replaced Lula on the ballot paper after the former president was barred from running due to a corruption conviction. Which candidate absorbs Lula's votes is a key factor in this election.
Lula gained huge popularity with women for his efforts to reduce inequality and expand the welfare programme, Bolsa Familia, which lifted millions out of poverty and gave many women financial autonomy for the first time. While the campaign has been dominated by vows to tackle crime, security, corruption, unemployment and to enact tax reform, pledges on social issues, such as improving welfare and reducing inequality, resonate with the electorate, particularly women.
Whether a female candidate can succeed is another matter. A 2009 law stipulates that at least 30 per cent of candidates must be women. In the event, just 30.6 per cent of those registered to run for office this year are women. Marina Silva, born into a mixed-race family in the Amazon and Lula's former environment minister, is the most prominent. An estimated 50 per cent of the female electorate remain undecided.
Social media has galvanised considerable support for the Vote Nela (Vote for Her) campaign to sway undecided voters towards female candidates. 147.3 million people are eligible to vote in Brazil - where voting is mandatory - and 52% are women...