Border Patrol agent Emmanuel Santos searches for illegal immigrants trying to hide in the undergrowth along the Rio Grande border near Laredo, Tex., on Thursday. (Matthew Busch/For The Washington Post)

— This scrappy city of rickety homes on the U.S.-Mexico border cannot afford an ambulance or a gas pump. The mayor earns $100 a month. The nearest supermarket is a half-hour drive.

Yet El Cenizo is leading the charge to block a tough new Texas immigration law that requires police to hold criminal suspects for possible deportation, before the measure takes effect Sept. 1. The lawsuit filed by the city pits Mayor Raul Reyes and his tiny outpost of Democrats against the state’s powerful Republican Party. Almost everyone in town is an immigrant from Mexico — or is related to one — and many are here illegally.

“People have been posting that they should make an example out of me and that they should lock me up,” Reyes , who helped draft the federal lawsuit, said in an interview at City Hall. “It’s a sacrifice I’m willing to make for this cause. I know I will be on the right side of history.”

The mayor’s move puts this city of 3,300 residents at the heart of a new war raging in Texas over an old issue: illegal immigration.

On one side is Gov. Greg Abbott (R) and the GOP-led state legislature. Emboldened by President Trump’s blunt rhetoric on illegal immigration, they passed a law in May that forces “sanctuary cities” such as El Cenizo to help detain and deport those who are in the country unlawfully. Uncooperative local governments face large fines, police chiefs and sheriffs could be jailed, and elected officials could lose their jobs.

El Cenizo Mayor Raul Reyes in City Hall. (Matthew Busch/For The Washington Post)

On the other side are progressive activists such as Reyes, part of a fast-growing younger generation that is largely Hispanic and U.S. born but lacks the political power of conservative white voters. With him are advocates who have pressured Dallas, Houston and other cities to resist cooperating with Immigration and Customs Enforcement because they fear it will lead to racial profiling or deportations for minor offenses.

Tensions boiled over in Austin on May 29, as protesters gathered outside the state capitol. Lawmakers nearly came to blows after a Republican from the Dallas area boasted to several Democratic colleagues of calling immigration authorities to come arrest demonstrators.

Rep. Matt Rinaldi (R) said he made the call because some protesters held signs openly declaring their undocumented status. The Democrats say there were no such signs and accused Rinaldi of racial profiling. Democrats said that proved the anti-sanctuary city law will result in the unfair targeting of Latinos.

Appearing with Neil Cavuto on Fox News on Thursday, Rinaldi defended the law as simply keeping “criminal aliens — murderers, rapists, child abusers — from being shielded from federal authorities.”

In an interview with The Washington Post, Rinaldi called the sanctuary city law a “very strong policy” that “deals particularly with criminal aliens or illegals” responsible for thousands of crimes. The law forbids law enforcement authorities from racially profiling suspects, he said.

In a video statement on Facebook to announce that he had signed the law, Abbott singled out for criticism the sheriff of Travis County, which includes the liberal city of Austin, who won her seat last year promising not to honor requests from ICE to hold people in the local jail for federal immigration violations.

“This law cracks down on policies like the Travis County sheriff, who declared she would not detain known criminals accused of violent crimes,” Abbott said in the video. “Those policies are sanctuary city policies and won’t be tolerated in Texas.”

Andrea Morales, 45, left, and Julieta Lopez, 48, who work for Webb County, pass out food to residents outside of the Webb County El Cenizo Community Center in El Cenizo, Tex. (Matthew Busch/For The Washington Post)

Reyes, El Cenizo’s 34-year-old mayor, has gotten mixed reactions from residents of this impoverished enclave on the humid banks of the Rio Grande. It sprung from a shantytown of landscapers, farmworkers and house cleaners who could not afford the rent in nearby Laredo, a bustling hub of 250,000 people about 17 miles to the north.

For down payments as small as $50, they bought plots of land and built trailers and, later, cinder-block houses. Some are patched together with duct tape, tarps and aluminum foil to block the searing sun.

“He’s trying to defend us,” said Maria Magdalena Rangel, a 72-year-old immigrant from Mexico who arrived at a local Lutheran church Thursday for a weekly ration of bread and tomatoes. “He sees the injustices that are happening with the people.”

Others say they fear the mayor’s defiance will irritate the U.S. Border Patrol and inspire them to make more arrests.

A horse feeds on grass in a front yard in El Cenizo. (Matthew Busch/For The Washington Post)

The divisions underscore how illegal immigration has evolved as an issue in Texas, home to an estimated 1.6 million undocumented immigrants.

Latinos are expected to outnumber whites in the state over the next few years and already comprise a majority of the public school student population. Political scientists saw a modest jump in Latino voter turnout in the 2016 presidential election, although Hispanics remain significantly less engaged in politics than whites.

Despite the recent immigration crack down, Texas has taken a nuanced — at times progressive — approach. Under then-Gov. Rick Perry (R), Texas was the first state to allow undocumented students to qualify for in-state college tuition. In 2012, the state Republican Party, backed by business interests, called for a national guest-worker program, although the plank was later removed from the platform.

The state GOP’s attitude has shifted further to the right, more closely mirroring the national party and its hard-line illegal immigration stance; Trump tried to punish sanctuary cities with an executive order in January that was temporarily blocked by a federal judge.

“The whole attitude toward immigration and illegal immigrants residing in Texas has changed and hardened since the early 2000s,” said Ray Sullivan, a Republican operative who advised former Texas governors Perry and George W. Bush. Sullivan credited concerns about crime, a sense that the border is still not secure, and the rise of Trump for the shift.

Many Texas liberals also have staked out a more radical position, quietly pushing officials in Democratic-leaning cities to keep federal immigration authorities at arm’s length. The anti-sanctuary city law is in some ways a backlash to their success.

They contend that the federal government’s failure to enact comprehensive immigration reform has forced local governments to act on their own to protect communities in which citizens and unlawful residents live interdependently, often within the same family.

Liberals argue that communities suffer when local law enforcement works closely with immigration officials, sowing a fear that can discourage people from reporting crimes or cooperating with investigations. ICE sometimes leaves people to languish in local jails for weeks before picking them up, which they argue violates their constitutional rights.

El Cenizo declared itself a sanctuary in 1999 and vowed to fire any city official who reported an immigrant to authorities. The city holds its council meetings in Spanish, the predominant language. And when outside volunteers tried to patrol the border with Mexico, the city created a $500 park usage fee to keep them out of El Cenizo.

Reyes said crime is rare. He said the city has not had a single homicide during his seven terms in office, dating to 2004.

Residents of El Cenizo — from left, Hilario Reyes, 76, Jose Pacheco, 76, Jose Alvarez, 64, and Alberto Martinez, 62 — play dominoes in the Webb County El Cenizo Community Center. (Matthew Busch/ For The Washington Post)

At the community center Thursday, Jose Guadalupe Alvarez shrugged as he played dominoes over popcorn and hot coffee. The 64-year-old retired construction worker said he worries that the mayor’s defiance will make Border Patrol agents more aggressive.

“Where are you going to hide so many people? This is a small town,” said Alvarez, a legal permanent resident who helped build hospitals in other towns, although his own does not have one. “It’s taunting the immigration agents. Most of us are illegal. Thank God I fixed my papers.”

Border Patrol Assistant Chief Patrol Agent Gabriel Acosta radios to his unit as he searches along an area of the Rio Grande where a sensor tripped signaling movement along the border. (Matthew Busch/For The Washington Post)

U.S. Border Patrol agents say there is value in working closely with state and local police, including in El Cenizo, to prevent public safety threats and to bust drug traffickers and human smuggling rings operating along the border.

Gabriel Acosta, the assistant chief patrol agent in charge of the Laredo sector, acknowledged that immigrants whose only offense is the civil violation of being in the United States illegally are sometimes deported, but he said they have some recourse because they can go before a judge.

“I totally sympathize and understand what they’re going through, but at the end of the day, it’s the law,” Acosta said as he patrolled Thursday night. “All we’re doing is enforcing the law.”

Angel Garza Reyna, 18, shown in his room in El Cenizo, just received a full scholarship to Duke University in Durham, N.C. (Matthew Busch/For The Washington Post)

To federal officials, illegal immigrants are lawbreakers. But in El Cenizo, they are Margarita, who cleans houses and sells tamales on the side; Maria, whose son graduates from high school Friday and will join the Army; and Angel Garza Reyna, 18, the pride of El Cenizo, who just received a full scholarship to Duke University, according to the mayor and a letter he provided to The Washington Post.

Angel, brought to the United States illegally at 11 months old, has Deferred Action for Childhood Arrivals, a temporary reprieve from deportation instituted under President Barack Obama that, for the teenager, expires next year. He rises before dawn to catch a ride to a magnet school in Laredo. His bedroom wall is plastered with academic medals. Crammed into one corner is a donated Hamilton upright piano, on which he taught himself to play Chopin.

He wants to be a doctor, because El Cenizo doesn’t have one.

Undocumented residents here worry that authorities will soon go door-to-door to root them out. The mayor said he has heard that domestic violence victims are afraid to report crimes. And people fret that going to the supermarket or buying gas could put at risk the lives they have built in the United States.

“This is worse than the wall,” said Ricardo Molina, a school board member. “Scaring people to death.”

A car is parked in the grass in El Cenizo. (Matthew Busch/For The Washington Post)

Somashekhar reported from Washington.