Ted Cruz, Beto O'Rourke spar in first debate of key Texas race This was the first face-off in one of the cycle's marquee U.S. Senate races.

DALLAS, Texas --

The first debate in the Texas Senate race between GOP Sen. Ted Cruz and Democratic Congressman Beto O'Rourke was marked by tense exchanges between the two high-profile Texas politicians that are now front and center in one of the country's most-watch matchups this fall.

In an hourlong debate that took place at Southern Methodist University in Dallas, the men traded barbs on a host of issues from immigration, gun control, police brutality and support for President Donald Trump.

Cruz repeatedly cast the 45-year-old El Paso Congressman, who has quickly become a rising star in Democratic politics for his unvarnished campaign style, as out of step with the people of Texas, saying he is someone who holds "extreme left-wing positions" that are "further to the left" than U.S. Sens. Elizabeth Warren or Bernie Sanders.

"We have a real race in the state of Texas, the hard left is energized, they are angry, many of them are filled with hatred for President Trump," Cruz, who has had to fend off questions that he may lose his re-election bid in recent days, said.

O'Rourke consistently defended himself from Cruz's attacks and slammed Cruz for pursuing his presidential ambitions so soon after he was first elected to the Senate in 2012.

"Only one of us has been to each county in Texas and would have an idea of what Texas values and interests are," O'Rourke said, "Within months of being sworn in to serve your senator, Ted Cruz, was not in Texas — he was in Iowa. He visited every single one of the 99 counties of Iowa. He went to New Hampshire, he went to South Carolina, he went to the Republican presidential primary states instead of being here."

One of the most intense exchanges of the night was on gun control, a heated issue in a state with a large number of gun owners, but has also fallen victim to multiple mass shootings in recent months.

"Thoughts and prayers, Senator Cruz, are just not going to cut it anymore. The people of Texas, the children of Texas deserve action," O'Rourke said.

"Let me be very clear, more armed police officers in our schools is not thoughts and prayers. I’m sorry that you don’t like thoughts and prayers, I will pray for anyone in harm's way. But I’ll also do something about it," Cruz responded.

Cruz also responded to questions about President Trump's nominee to the U.S. Supreme Court, Brett Kavanaugh, whose nomination has been upended by allegations of sexual assault.

"I very much hope Dr. Ford comes next week and testifies before the judiciary committee, I publicly called for her to be given an opportunity to testify," Cruz said.

"The allegations she raised are serious, and they deserve to be treated with respect, and I hope that she comes and has a full opportunity to tell her story in a way that is respectful. But I also think Judge Kavanaugh should have a full opportunity to defend himself and to let the American people listen and come to an assessment of what happened," he continued.

When asked if his decision to work with President Trump despite the insults and harsh words the two men flung at each other during the 2016 election, Cruz said he made a decision to work with the president on issues of "substance."

"I could have chosen to make it about myself and be selfish and say you know what, my feelings are hurt, so I’m going to take my marbles and go home. But I think that would have been not doing the job I was elected to do,"

O'Rourke responded that how someone responds to personal attacks is their own decision, but said Cruz has not stood up to President Trump on numerous occasions where it matters most, and referenced accusations of collusion with Russia that have consistently dogged the Trump presidency.

"Listen, if the president attacks you personally, your wife, your father, how you respond is your business," O'Rourke, "But when the president attacks our institutions in this country, allows a foreign power to invade our democracy — that is our business. We need a U.S. Senator who will stand up to this president where we must and work with him where we can."

The two men also offered sharply different visions on the issues of immigration and healthcare. Cruz emphasized his efforts to repeal the Affordable Care Act and said that everything humanly possible needs to be done to "protect the border," adding, "that means building a wall."

O'Rourke said he supports a path to citizenship for DREAMERs, young immigrants under the Deferred Action for Childhood Arrivals program, and said that repealing the ACA was not a permanent solution to the nation's healthcare woes.

"I don't know how you're going to repeal every single word of the Affordable Care Act and keep protections for pre-existing conditions," O'Rourke said.

One of the debates' most memorable moments came near its conclusion, when both candidates were asked to say something they admire about each other.

O'Rourke said he believes Cruz works "very hard" and respects the sacrifices he makes having a high-profile career with two young daughters. Cruz in turn called O'Rourke "sincere" and "passionate" in his beliefs, and again compared the congressman to Senator Bernie Sanders, bringing the conversation back to politics.

The Democrat responded only by saying: "True to form."

O'Rourke's candidacy has generated widespread enthusiasm among national Democrats, but his chances of defeating Cruz, one of the GOP's most high-profile and controversial figures, remain unclear. A recent poll conducted by Quinnipiac University showed Cruz leading O'Rourke by nine points.

However national Republicans have become increasingly skittish about the race. The New York Times reported earlier this month that Mick Mulvaney, a top official in the Trump administration, warned a room of top Republican donors this month that Cruz could lose his re-election bid because he's not "likeable" enough.

The upscale University Park area surrounding the serene college campus where Friday night's debate took place is exactly the type of battleground that both Cruz and O'Rourke need to perform well to emerge victorious in November. The congressional district where the debate is located is represented by a Republican, Rep. Pete Sessions, but was won by Hillary Clinton by five points in the 2016 election.

Alternating yard signs for Cruz and O'Rourke line the front lawns in the neighborhood, which is not unlike other areas of the country where Republicans find themselves on defense in 2018, facing voters that have traditionally voted Republican but may be disillusioned with the first years of the Donald Trump presidency.

"This race is most likely to be determined in suburban districts of Dallas, Austin, Houston, San Antonio," Matthew Wilson, a professor of political science at SMU, told ABC News. "If Beto O’Rourke is going to win he’s going to have to persuade a lot of moderate, traditional Republicans to cross party lines."

"You see a lot more O’Rourke signs in affluent Republican-leaning areas than you might typically see for a Democratic candidate. I think this is by design for the O’Rourke campaign. They’ve wanted to create that visual sense that they are making inroads in hostile territory," Wilson added.

The El Paso Congressman has capitalized on the national attention, appearing on the Late Show with Stephen Colbert and NBC host Ellen Degeneres' eponymous program in recent days, but has also made a point to take his pitch not just to Texas' big cities, but more rural and conservative parts of the state. His campaign touts that he has visited all of Texas' 254 counties.

Cruz has been making his pitch directly to Texas' more conservative-leaning electorate, trying to paint O'Rourke as an out-of-touch liberal, saying at a recent campaign rally that the Democrat is trying to turn Texas into California, "right down to the tofu and silicon and dyed hair."

And even after tonight's debate, President Trump still looms over the race, as he has promised to campaign in the state for Cruz next month.

A truck sporting a billboard plastered with a negative tweet from Trump about Cruz during the presidential campaign was parked outside the debate hall hours before the two men were set to face off.