From the day he was picked up three years ago by Border Patrol agents in Texas, Dora Beltrán’s son has cycled through shelters and detention centers in five states as his mother fights to bring him home.

The family’s immigration standing is not at issue: She is a legal permanent resident and an immigration judge decided he would not be deported.

Yet the teen remains locked up as his mother and the government battle over when federal officials can keep a parent from her troubled child.

The rare and complicated case is set to be heard this week in federal court in Northern Virginia where Beltrán is challenging the role of federal officials in child custody matters.

Her son had lived with her in Texas for years but was a runaway when he was spotted by agents at age 14 near the Mexican border. Before Beltrán could get to her son, authorities detained him as an unaccompanied minor.

Dora Beltran’s teenage son has not been sentenced to jail by a judge, but he has been locked in juvenile detention facilities in three states as his mother fights to bring him home in a dispute about the role of the federal government in child custody matters. (Dora Beltran/Family Photo)

Even after an immigration judge determined that the boy did not have to be deported, federal officials decided he should remain in a detention center. They said his history — with the teen describing himself as a runaway, drug user and associate of criminal gangs — raised questions about his mother’s ability to supervise him and keep him safe.

But Beltrán’s lawyers say that once an immigration judge closed out her son’s case, he should have been released to her.

On Thursday, her lawyers will argue that she is entitled to a formal custody hearing similar to what she would receive in a state or local child welfare system.

Federal officials and a recent appeals court ruling say her son was an “unaccompanied minor” when he was detained and cannot be released without the government fully vetting the adult sponsor who would care for him.

The Office of Refugee Resettlement within the Department of Health and Human Services is responsible for finding adult sponsors for unaccompanied migrant children as their immigration cases are processed.

The office does not track how many children with parents in the United States remain in custody after their immigration proceedings are complete.

Beltrán’s son is among asmall group — less than 1 percent — of the nearly 60,000 unaccompanied children this fiscal year held in secure juvenile detention facilities. Still a minor at 17, he is referred to by his initials in court filings.

Government lawyers involved in the case of Beltrán’s son say parents are not automatically entitled to a hearing when the resettlement office assumes custody. Requiring that kind of hearing would “overwhelm the entire system,” according to the government’s most recent filing in U.S. District Court in Alexandria.

Instead, the office has an extensive process that can include a home visit and interview for parents seeking to be reunited with their children.

Mark Weber, an HHS spokesman, declined to talk specifically about Beltrán’s case. In general, he said the office “does not release children considered to be a threat to the community.”

However, immigrant advocates say the recent decision by the U.S. Court of Appeals for the 4th Circuit gives too much power to the resettlement office.

“It puts the federal government in the position of deciding who is a good parent,” said attorney Michael J. Dell, who worked on Beltrán’s case.

Under the split decision in June, any undocumented child could be separated from a parent without a hearing if a government official deems the parent “unfit,” Dell said.

In Beltrán’s case, the resettlement office said she could not have her son because he “requires an environment with a high level of supervision and structure” that it did not appear she could provide.

But the appeals court said the resettlement office’s current process may not be enough and said Beltrán could go back to federal court to ask for a formal hearing, as she is doing Thursday.

‘So much pain’

Beltrán, 36, has seen her son only once since he was transferred out of Texas in early 2014 after being picked up 100 miles from their Corpus Christi home. She talks with him by phone several times a week as he has bounced to secure juvenile centers in Virginia, New Jersey and California.

She has not received copies of his medical, mental health or educational records from the detention centers.

“I feel so much pain about what my son has been through, and our separation over the last several years has only made it worse,” she wrote in a statement to the court. The government, she said, has kept her from her son “when he needed his mother to help him heal and overcome some very traumatic experiences. I don’t understand how locking him up in jail is helping him.”

By his own account, Beltrán’s son’s path was traumatic in the years after the family moved to the border town of Rio Bravo, Tex., from Guatemala in 2005.

He ran away from home, was recruited to smuggle people and drugs for several cartels and got hooked on heroin, according to his lengthy statement filed in court last month. He was placed on probation by a juvenile court in 2012 for making a “terroristic threat.”

When Beltrán’s son tried to cut off ties to one cartel, he was drugged and sexually assaulted by cartel associates, according to his statement.

“I understand that what I say here will be available to the public,” he wrote. But as he nears 18, he said he was no longer “ashamed, embarrassed or afraid” and wanted to tell his story.

Dora Beltrán had lost custody of her children for five months in 2012 when they were removed by Child Protective Services after she left them alone at home while she gave a ride to a neighbor.

In 2013, Beltrán moved the family to Corpus Christi to try to get her son out of trouble. But he returned to the border, he told the court, drawn to the drugs and money.

When he was arrested in December 2013, Beltrán jumped in her car. She told the agent she was on her way, and that she and her son had some immigration protections under the Violence Against Women Act, which allows victims of domestic violence who are not citizens to obtain lawful status.

Beltrán was at least 30 miles into the trip when an agent returned her call. Beltrán was told she would be arrested if she came to the station.

In early 2014, after the study of Beltrán’s home and family interviews, the resettlement office refused to release her son.

Her home, according to court filings, was safe, orderly and stocked with food, but did not appear to “provide the structure and supervision necessary for the safety of your son,” in part because of the spousal abuse the court documents say she endured and her son’s problematic past.

After the case was filed, HHS told Beltrán in a July 2015 letter that the office would not release her son because of the concerns about her home and her son’s self-destructive behavior and failure to work with clinicians.

Now in a secure center in California, Beltrán’s son said he sleeps in a locked concrete cell in what he describes as a real jail with youths facing criminal charges.

“I know I’ve had behavior issues while I’ve been detained, but being locked up, moved around and not really listened to has made me even more frustrated and angry about everything than I was when they first took me,” he wrote.

Even so, Beltrán’s son said he is trying to prepare for a different life, for college and a career. He is practicing yoga and passed the high school equivalency test, he wrote.

He also wrote that he wants the court to know his mother has not been given clear guidance about what she can improve to get him back.

“I know I’m just a kid, and I don’t understand everything about the law,” he wrote, “but that doesn’t seem like justice to me.”

Court’s assessment

In June, the 4th Circuit sided with the resettlement office in a 2-to-1 decision in Beltrán’s case, saying that even after her son’s immigration proceedings ended, the government was “not entitled to release him to anyone unless it first determined that the proposed custodian was capable of providing for his physical and mental well-being.”

The judge who disagreed, Henry F. Floyd, said Congress had not empowered the office to “seize children from bad parents.” He also disputed the government’s assertion that Beltrán’s son could be categorized as “unaccompanied” given that his mother is a permanent resident and wants him home.

If federal authorities consider Beltrán an unfit mother, her attorneys said, they could turn him over to a state welfare agency. If they consider him a juvenile delinquent, they can prosecute him. But to keep him in custody indefinitely with no court hearing is unconstitutional, his attorneys argued.

“You don’t take children from their parents if the children are incorrigible,” said Susan Watson, who is representing Beltrán, along with Catherine Norris of Texas RioGrande Legal Aid. States step in if the parents present a danger to the child, she added, citing past legal decisions in state child welfare cases.

Beltrán’s lawyers are not certain what will happen to her son if he is in detention when he turns 18.

In general, the resettlement office transfers custody of 18-year-olds back to Department of Homeland Security officials — where Beltrán started three years ago.