It's time to tear down the U.S. Border Patrol. And I mean tear it down entirely: Fire its staff, close its detention centers, and start over from scratch.

Why? Because new details confirm that this agency is fraught with problems. And extreme problems often require extreme solutions.

This week put the agency under an unflattering spotlight. A ProPublica investigation into a Facebook group composed of current and former Border Patrol agents revealed these people "joked about the deaths of migrants, discussed throwing burritos at Latino members of Congress visiting a detention facility in Texas on Monday, and posted a vulgar illustration depicting Rep. Alexandria Ocasio-Cortez engaged in oral sex with a detained migrant."

Awful. Disgusting. Reprehensible. But then things got worse.

A group of congressional Democrats, including Ocasio-Cortez (N.Y.), visited migrant detention centers in Texas and found "appalling" conditions, operated by a staff apparently hostile to congressional oversight, where migrant women "were held in cells without water and told by officers to drink out of the toilet."

"This has been horrifying so far," Ocasio-Cortez tweeted. "It is hard to understate the enormity of the problem. We're talking systemic cruelty w/ a dehumanizing culture that treats them like animals."

The agency's defenders accused Ocasio-Cortez of misconduct. Other Democrats who made the visit, however, corroborated her account:

So yeah, this is a disaster for the Border Patrol. Let's shut it down.

Even before President Trump arrived on the scene with his anti-immigrant agenda, the agency gave every sign of being a moral and ethical mess. In 2014, the former head of internal affairs for Customs and Border Protection — the Border Patrol is a subdivision of that agency — went public with accusations that Border Patrol leaders tried to change or distort facts to exonerate agents involved in more than two dozen deadly clashes since 2010. "In nearly every instance, there was an effort by Border Patrol leadership to make a case to justify the shooting versus doing a genuine, appropriate review of the information and the facts at hand," James F. Tomsheck said at the time. Nothing seems to have changed: As recently as last year, court filings in the case of an agent accused of killing a migrant revealed racist text messages between the defendant and other agents.

Despite that record, the Border Patrol's budget more than doubled from 2003 to 2015 — thanks to a post-9/11 emphasis on border security, plus efforts by former Presidents George W. Bush and Barack Obama to crack down on undocumented migrants in the vain hopes they could get conservatives in Congress to meet them halfway on immigration reform. Thousands of new agents were hired — critics said many were unfit for the job — and deportations increased dramatically, but an immigration compromise never materialized.

Instead, the National Border Patrol Council — the union representing three-quarters of the Border Patrol's 21,000 agents — enthusiastically endorsed Trump for president in 2016. It had never made an endorsement before, but Trump and his nativist rhetoric proved attractive. "If we do not secure our borders, American communities will continue to suffer at the hands of gangs, cartels, and violent criminals preying on the innocent," the union said in a statement at the time. Border Patrol agents aren't just enforcing American immigration policy; they used their collective political muscle to elect a president who would give them more power and resist reining them in. They got what they wanted.

How should we rebuild and replace the Border Patrol? Very carefully. WOLA, a non-governmental agency that advocates for human rights in the Americas, has offered suggestions for revamping the nation's border security. Its agenda includes requiring border agents to wear body cameras, increasing the staff of internal affairs investigators, and adopting a new approach that makes detention a last resort. It suggests expanding a program that once used caseworkers to keep in frequent touch with asylum-seeking families. Such an approach would require rethinking immigration policy with humanitarian concerns in mind, instead of continually finding new and more troubling ways to deter migrants.

Admittedly, these would be challenging times for a well-run agency with a good, redeemable culture, regardless of Trump's efforts to blockade the border: Poverty and violence have inspired massive migration northward from parts of Latin America. "What bothers me immensely as an American is the ire that's directed toward CBP as opposed to directing it to the problem," Acting CBP Commissioner John Sanders said at a recent forum. "I spend a lot of time educating Congress about the great job the men and women of CBP are doing to uphold the laws of this country."

It's tempting to sympathize. But there has long been a growing pile of evidence that the agency's culture is saturated with racism and indifference to human life. There's no reason to believe the Border Patrol, as presently constituted, is culturally capable of handling its duties in a professional or humane fashion. This week's events should be the tipping point. It's time to dissolve the agency and start over.