When South Africans go to the polls on May 8 it will be the most important election since the black majority shook off the shackles of apartheid in 1994 and installed Nelson Mandela as the nation’s first black president. That election ended a half-century of brutal segregation and ushered in an era that promised equal opportunities for all.

The African National Congress was brought into democratic power by a global icon who’d paid for his belief in a free South Africa with almost three decades in jail. It was a time of hope and reconciliation.

The ANC has ruled the country for 25 years now. What’s at stake this time is just as important: rescuing what little is left of the gains South Africans have made since the end of apartheid. The nine-year rule of Jacob Zuma, which ended with his resignation last year, saw the willful dismantling of the country’s once-respected legal and regulatory institutions and the deterioration of a host of state companies as ANC leadership became a byword for corruption.

This isn’t about a transfer of power: The ANC is expected to win a majority in the National Assembly. Instead, it’s about tilting the balance in the war within the ruling party. Reform depends on how strong a mandate is won by Zuma’s successor, Cyril Ramaphosa, 66, a man Mandela had wanted to be his heir.

A solid share of the popular vote would give him the political capital to push through changes that would reignite growth and investor confidence. A narrow victory would embolden his ANC foes—who want to preserve the status quo.

The ANC has to recover from a severe battering: The 2016 municipal elections were its worst showing in the post-apartheid era. The party won just 54% of the popular vote—compared with 62% in the last national elections in 2014—and lost control of Johannesburg, the country’s biggest and richest city, and Pretoria, the capital.

The election served as a referendum on Zuma—and accelerated his exit.

With that powerful but despised president gone, the party’s hopes are pinned on Ramaphosa. Since he assumed office in February 2018, the ANC has experienced a resurgence. “In the last month of Zuma’s rule, the ANC had slipped below the 50% mark,” says Susan Booysen, director of research at the Johannesburg-based Mapungubwe Institute for Strategic Reflection.

Ramaphosa “has turned around the ANC fortunes in the face of virtually guaranteed electoral defeat.” He’s also been helped by disarray in the two biggest opposition parties, the Democratic Alliance and the Economic Freedom Fighters.

But Ramaphosa needs a solid victory that convinces opponents in his own party that he has the country’s backing. Cristian Maggio, head of emerging-markets strategy at Canada’s TD Securities, says winning 58% of the vote or more would be a strong mandate for Ramaphosa while anything less than 52% would be a weak one.

An Ipsos poll in April predicted the party will get 61% of the vote. “The elections are particularly important as they are expected to open a season of sweeping reforms,” wrote Maggio in a note to clients in March.

“Moreover, the depth of such reforms is likely to be a function of the electoral outcome, with a stronger victory assuring a higher chance that important announcements are made shortly after the vote.”

A solid showing would also give Ramaphosa the clout to pick his own cabinet. At the moment, he presides over a factionalized administration. His ascension to power at a 2017 ANC electoral conference was anything but guaranteed.

Ramaphosa won just 52% of the vote after a hard battle against Nkosazana Dlamini-Zuma, Zuma’s protégé and ex-wife. After the dust cleared, the Zuma faction retained its influence and Ramaphosa has been saddled with two of the former president’s allies in powerful ANC posts, deputy president and secretary general.

The test of whatever mandate he receives may come if he decides to fire Zuma allies such as women’s minister Bathabile Dlamini. In her previous role as social development minister, Dlamini was blamed for bringing the $11 billion-a-year welfare system, on which 1 in 3 South Africans depends, to the brink of collapse.

“The incoming administration should not look like the outgoing administration,” says Martin Kingston, the executive chairman of Rothschild & Co.’s South African unit and vice president of the country’s main business lobby.

“We need to see whether we have surviving members of the cabinet or we have new members of the cabinet who have the integrity, experience, and authority to implement challenging agendas.”

Forming a government may be the easy part. Ramaphosa and the ANC have a mountain to climb to restore the party’s reputation. Under Thabo Mbeki, who ruled from 1999 until 2008, the economy grew at an annual average of 3.9%, and millions of black South Africans joined the middle class. As the ANC went into the 2009 elections with Zuma at its helm, South Africa had weathered the 2008 global financial crisis better than most countries.

But during Zuma’s rule, average annual economic growth fell to 1.6%, barely outpacing population growth. The country became mired in corruption. The state power company Eskom Holdings SOC Ltd. accumulated more than $30 billion in debt, and electricity outages are regular occurrences. The unemployment rate has risen to 27.1%, from 21.5% in 2008, belying Zuma’s pledge on taking office that he would create 5 million jobs in his first term.

A model that includes a range of social, economic, and governance measures shows the country slipped to 88th out of 178 countries from 31st in 2006, according to Eunomix Business & Economics Ltd. “We shouldn’t underestimate how impaired the economy has been by the action and inaction over the past 10 years,” says Kingston.

“It has acted as a constraint on the business community making the long-term investments needed to underpin economic growth.” He adds, “Many of us had underestimated the sheer magnitude of the problem.”

Politics, business, and the economy come together in the mess at Eskom. It’s unable to generate sufficient revenue to meet its running costs and finance the completion of two of the world’s biggest coal-fired power plants.

In February, when Ramaphosa announced plans to split the company into three, he drew an immediate backlash from the ANC’s union allies, including the National Union of Mineworkers, which the president had founded while an anti-apartheid activist. Eskom’s budget—which provides for 47,000 workers, a number the World Bank says is 66% too large—needs to be reduced if the company is to survive and keep the country’s mines and factories supplied with power.

While Ramaphosa has said he doesn’t plan to trim the workforce, unions have threatened to bring the country to a halt if their members are fired.

Ramaphosa must also figure whether he can sustain the 1.2 million state workers who account for 35% of the national budget. And then there are the government-owned companies—from the national roads agency and the state broadcaster to an arms manufacturer—with enormous debts.

And Ramaphosa is committed to change the constitution to allow land seizure without compensation, which the ANC resolved to do at its 2017 conference, and will have to navigate that process carefully so investors won’t be spooked.

While Ramaphosa’s past as an anti-apartheid activist has helped his popularity, he’s left those roots far behind. In 1997, after being passed over by the ANC as Mandela’s successor in favor of Mbeki, Ramaphosa, a lawyer, went into business and amassed a fortune of several hundred million dollars in a range of activities from coal-mining joint ventures with Glencore Plc to running the South African franchise of McDonald’s Corp.

That’s won him the backing of business and broadened his appeal in a country where wealth is often delineated along racial lines. The experience underlies his promise to reform the economy and turn it around.

So far, Ramaphosa can blame the country’s ills on corrupt foes in the party who’ve gotten in his way. But if he wins big and still fails, he’ll have no one to blame but himself—and that may finally precipitate the ANC’s fall from power.

“When the president comes here and sees how angry we are, how angry and desperate our children are, they have to consider the consequences of doing nothing,” says Emily Mashazi, 52, who relies on occasional work as a house cleaner in Johannesburg and lives in the impoverished township of Alexandra. Across the highway from her home is Sandton, a business district described as Africa’s richest square mile.

“We will keep the ANC in power, but this is the last time I’m voting if they shame themselves once more by letting us live in worse conditions than captive animals.”

Read: Latest election poll shows the DA and ANC in trouble