An interior hallway at the Shenandoah Valley Juvenile Center, a detention facility in Staunton. (Shenandoah Valley Juvenile Center/AP)

Juliene James is a director of criminal justice at the Laura and John Arnold Foundation. Susan Mangold is the chief executive officer of Juvenile Law Center.

Navigating the juvenile justice system can be daunting for any family. After absorbing the shock of a child’s arrest, families often face an intricate, pernicious economy of fines and fees, all while making critical decisions about their child’s case. And if a juvenile defendant’s family can’t afford the fees, they may pay a far steeper price: loss of freedom until the debt is settled.

State and local governments have started to recognize the harmful effects of court-related fees, including in California, where lawmakers have banned juvenile justice fees altogether. But little attention has been paid to another form of financial exploitation: fees and reimbursements for court-appointed lawyers.

Though the Supreme Court ruled in 1967 that courts must provide lawyers to juvenile defendants, a stunning report from Juvenile Law Center found that 40 states have policies that require or permit courts to charge juvenile defendants — and in reality, their families — for “free” court-appointed lawyers, including public defenders. For those who work in the juvenile justice system, it is a maddening yet familiar cycle.

One of the most troubling aspects of these fees is that they tie the amount of time minors spend on probation to their families’ incomes. That’s because release from probation is typically only offered with the condition that a child avoids delinquency on payments.

“The child thinks, ‘Even though I’m being good, I can’t get off probation because I’m poor,’ ” said Gar Blume, a criminal defense lawyer in Alabama. “There’s no hope.”

Years ago, Blume represented a mother of an adjudicated delinquent. The family faced administrative fees, juvenile discretionary-fund fees and restitution. On top of that, the mother had to reimburse the court for a lawyer to defend her son — all while struggling to keep a roof over their heads and food on the table, relying on federal assistance to stitch together a living.

Now, the court is charging Blume’s client with contempt and is threatening jail time because she still can’t afford to pay. This is the second time she has been charged with contempt. In 2014, she narrowly avoided jail time because Blume convinced the court that her nonpayment was a result of poverty, not willful disobedience. The court put her on a $25-per-month payment plan, but even that was beyond her means.

Her son can’t contribute because he is now in prison. While on probation, he faced fees that crippled his family, as well as community supervision that watched him for the slightest slip-up. Like many kids subject to the unrelenting justice system, he eventually was sent to prison.

In many states, courts demand these payments even after they’ve determined a child’s family is living in poverty. On top of lawyer fees, states such as Georgia, Tennessee, Delaware and Florida charge administrative fees just to apply for a lawyer. In many cases, these fees are required even if the child is never adjudicated delinquent. Tennessee can charge up to $200, a backbreaking amount for a family struggling to make ends meet.

When children and their families are faced with these costs, they often forgo legal representation or choose to plead guilty.

Waiving right to counsel or pleading guilty has obvious and far-reaching negative consequences. The financial strain caused by legal costs does, too. More than half of the families that the Juvenile Law Center interviewed have gone into debt because of court fees. This, in turn, severs family relationships and keeps youths under justice-system supervision until the debt is paid.

Court systems are drowning poor families in financial burdens, and for what? Collecting fees is supposed to pay for court systems, yet Blume has no doubt that the Alabama court, in chasing his client for her $25 a month, has spent far more than what’s owed. Researchers from Juvenile Law Center and University of California at Berkeley have also documented this phenomenon in counties across the country: It often costs more to collect the fees than is gained by the collection.

There is a clear path forward on this issue. State legislatures, judiciaries and individual judges should stop charging for counsel. To do any less infringes upon children’s constitutional rights, squanders the potential of thousands of kids who deserve a fair trial ,and harms countless families who are already struggling.