ANKARA, Turkey — Once jailed for reciting a poem at a political rally, President Recep Tayyip Erdogan has styled himself throughout his rise as a champion of freedom and justice, and his early push for judicial reforms were widely hailed.

Yet after nearly two decades of Mr. Erdogan’s rule, the state of the judiciary in Turkey is in such crisis that the lives of millions of citizens are tied up in tortuous legal procedures, and public trust in justice has fallen as low as it has ever been in Turkey’s long, uneven record.

Across the public sector in Turkey — the economy, education and labor — opponents of Mr. Erdogan say that his authoritarian management style and cronyism within the ruling party are undermining confidence and performance.

The country’s courts may be the most urgent example. Purges and a persistent brain drain have rotted out the judiciary, and those judges still in their jobs are paralyzed by a climate of fear, legal professionals say.