JOHANNESBURG – Nelson Mandela was seriously ill but has steadily improved over the last few days after being diagnosed with a lung infection and undergoing gallstone surgery, South African President Jacob Zuma said Thursday.

It was the first official acknowledgement that Mandela’s condition had been grave, and came 13 days after the anti-apartheid icon was brought to a hospital in the capital, Pretoria. The government initially said 94-year-old Mandela was undergoing medical tests, and the information that followed was terse and sometimes contradictory.

“His condition was serious but he is responding well to treatment and he steadily improved over the last few days,” Zuma said at the close of a conference of the African National Congress, the governing political party.