According to the Justice Department’s Office of Juvenile Justice and Delinquency Prevention, approximately 48,000 American kids were incarcerated in a private, state, or federal residential facility in 2015, the last year for which data is currently available. A number of states have already placed restrictions on solitary confinement for youth offenders. Beginning in January, for example, California will only allow it when other, less restrictive options have failed, and then only for four hours at a time.

Enforcement and oversight of these laws, however, vary widely, and so does the education young offenders are offered. It’s nearly impossible to attain an accurate tally of how many kids are in solitary at any given time, let alone how—and if—they’re taught. According to Jessica Feierman, the associate director of the Juvenile Law Center, some of the more extreme circumstances only come to light as the result of a lawsuit or intervention from the federal government. In 2014, for example, the Obama administration filed a “statement of interest” in a case against Contra Costa County Juvenile Hall in California, which alleged that “youthful offenders with disabilities who are confined [there] are often subjected to solitary confinement because of their disabilities and are denied special education, related services, and rehabilitation services.”

For many young offenders, education has long been a struggle. Peter Leone, a professor of behavior disorders at the University of Maryland who specializes in youth incarceration, said that kids who do poorly in school early on are more likely to be truant, or to participate in the sorts of low-level criminal activity that sends many kids to detention facilities. “That’s a really big issue, and it says volumes about the vulnerability of kids with special needs [within] a judicial system that is not very responsive or does not acknowledge the fact that poor kids, kids of color, kids with disabling conditions are much more likely to be detained,” he said. “And then once they’re detained, they’re more likely to be committed and kept in confinement for longer periods of time.” Leone was an expert witness for the plaintiffs in the Contra Costa case filed in 2013, as well as another in Los Angeles County in 2011.

“The question we always ask is, ‘What if this were your kid?’” said Mark Soler, the executive director of the Center for Children’s Law and Policy in Washington, D.C., which is campaigning to end solitary confinement for juvenile offenders nationwide. “After all, almost anyone in America could have their child arrested for possession of marijuana at some point, or shoplifting, or possessing alcohol underage. If we take those three, that probably covers most of the teenagers in America.”

While some kids are sent to solitary for committing violence, others are there for offenses that in a traditional school may not even warrant a teacher’s reprimand, let alone a trip to the principal’s office or a suspension, experts told me: being restless in class, talking back, or refusing to participate if they don’t understand or are frustrated by a lesson. And staffing shortages can influence how many kids are put in solitary: Detention-center workers responsible for a large group of teenagers often opt to simply send away so-called troublemakers—including those with learning disabilities or mental-health issues and those acting out. Depending on the facility and jurisdiction, kids can spend as long as 23 hours a day, seven days a week, for weeks or months on end in solitary. Sometimes, those detained don’t even know what offense they’ve committed, Leone said.