Nicola Sturgeon's key achievements and challenges as First Minister and SNP leader
Nicola Sturgeon left office as the longest-serving First Minister in Scotland's history and the first woman to hold the post.
Yesterday, her successor as the next leader of the SNP Humza Yousaf was named after a fiery five-week contest.
But Ms Sturgeon's eight years in office spanned some of the most important and divisive periods in UK politics, including Brexit and the Covid-19 pandemic.
As with any political leader, Ms Sturgeon's tenure encompasses both successes and triumphs.
Here are some of the key events of her time in Bute House:
Election supremacy
In the eight years since taking office, Nicola Sturgeon showed herself to be one of the most adept political leaders at the ballot box in Scotland's history.
After 2014, her party won two Holyrood elections, three Westminster elections, two local elections and a European vote, cementing the SNP as the premier political force in Scotland.
While her leadership was in its infancy, the First Minister oversaw an election that rode the wave of independence support, returning 56 of 59 seats at Westminster.
Social security
Following the 2014 independence referendum, the Smith Commission - set up to look into giving the Scottish Parliament more powers - recommended some social security responsibilities be devolved to Holyrood.
A bill creating Social Security Scotland, the country's first benefits agency, was passed in 2016, with a raft of new payouts set up in the following years, including the Scottish Child Payment - a £25 per child per week benefit given to poorer families.
It has been heralded as "game-changing" by poverty campaigners but figures released last week indicate 24% of children are still in poverty.
Bute House Agreement
Following the 2021 election, Ms Sturgeon announced her party was in talks with the Scottish Greens about a potential power-sharing deal.
That August, she announced what has since become known as the Bute House Agreement - named for the First Minister's official residence in Edinburgh.
The parties agreed a common policy platform, with some specific areas where dissent was allowed, and Green co-leaders Patrick Harvie and Lorna Slater were given ministerial posts.
The agreement enshrined the pro-independence majority in Holyrood, and all but guaranteed the passage of the vast majority of the Government's policy pledges.
Covid-19
Coronavirus changed everything about public life for two years, claiming the lives of - as of March 12 2023 - 17,001 people in Scotland, according to National Records of Scotland where the virus was mentioned on death certificates.
The performance of the First Minister and the Scottish Government was mixed throughout the pandemic.
Ms Sturgeon fronted the Government's response, giving near-daily briefings to update the public on the situation, as well as taking questions from the media.
She was widely seen as being more competent in her response to the virus than the UK Government, repeatedly favouring a more cautious approach than then prime minister, Boris Johnson.
But she was also criticised over the handling of care homes in the early days of the pandemic, with 78 people who had tested positive for the virus being discharged from hospital to care homes.
Independence
The fight for Scottish independence is often described as the First Minister's defining mission, but as she leaves office for the backbenches, she will be frustrated not to have taken further strides towards it.
Despite repeated election wins and requests for a Section 30 order to grant Scotland the powers to hold another referendum, the UK Government consistently rejected calls for another vote.
In a change in strategy, the First Minister asked Lord Advocate Dorothy Bain KC, who said she was not confident a proposed Bill for another vote was within Holyrood's competence, to test if Scotland had the power within the devolution settlement to hold its own referendum.
The argument went before the UK Supreme Court last year, where it was struck down by judges, backing the party - and Ms Sturgeon - into a political corner.
Her favoured path ahead of her shock resignation was what she described as a "de facto referendum", meaning the SNP would consider a majority of pro-independence votes at the next UK general election a mandate to begin negotiations for secession.
Salmond inquiry
For the best part of a decade, Nicola Sturgeon was Alex Salmond's most trusted deputy, but then the former first minister was accused of sexual misconduct by two women from his time in office.
The Court of Session ruled the Scottish Government's investigation into the claims was "tainted with apparent bias" by the investigating officer's prior contact with the complainants, with Mr Salmond receiving more than £500,000 in damages.
A separate investigation by police led to Mr Salmond being charged with sexual offences, including attempted rape, before being acquitted at trial.
What followed was one of the most extraordinary parliamentary inquiries in UK political history, with Mr Salmond and Ms Sturgeon called before a Holyrood committee set up to look into the botched handling of the harassment complaints.
In evidence, Mr Salmond called for the resignations of the Lord Advocate and Permanent Secretary, while Ms Sturgeon said she regretted the "very serious mistake" which led to the botching of the investigation.
However, she claimed an assertion of a plot against her predecessor was "absurd".
The committee eventually found Ms Sturgeon had "misled" MSPs over comments about two meetings with Mr Salmond while the Government was investigating the complaints, but she was cleared of breaching the ministerial code.
Gender reforms
In the waning months of her premiership, Nicola Sturgeon was locked in a fight with the UK Government over the decision to block controversial gender reforms.
The Gender Recognition Reform (Scotland) Bill was passed by MSPs from all parties in December, despite the bitter debate over the issue.
The bill would make it easier for trans people to gain a gender recognition certificate (GRC), dropping the need for medical approval in a process known as self-ID.
Critics claim it would negatively impact women and girls, putting single-sex spaces at risk, while proponents claimed it would be a simple, administrative change.
Some of the most vociferous criticism of the bill came from within the SNP, with minister Ash Regan stepping down in protest - only to run to replace Ms Sturgeon months later - and along with eight other MSPs rebelling against the party whip to vote against the legislation.
In a coincidence of timing, transgender double rapist Isla Bryson was convicted just weeks after the UK Government moved to block the legislation.
Bryson - formerly Adam Graham - transitioned after being charged, and set off a firestorm amongst politicians and the public after being sent to Cornton Vale - Scotland's only all-female prison - upon conviction.
Bryson would be moved out of the female estate and a revamp of prison service policy followed, but the controversy fuelled fears that dangers to vulnerable women and girls could result from the implementation of self-ID, despite the bill not being in force.
Want a quick and expert briefing on the biggest news stories? Listen to our latest podcasts to find out What You Need To Know...