In their quest for an icon, someone to lift their spirits and usher them out of the wilderness, Democrats were shown the way this week by an unlikely guide: Texas Republicans.

The state GOP identified a rock star in a faded monochrome from the 1990s. A floral-print getup (perhaps a dress or tunic), cut wide at the neck, hangs over his lean frame. His hair is parted down the middle, the rest disappearing behind his head in what looks like a loose ponytail. His square jaw accentuates his long, angular face.

The man gazing out from the black-and-white image is college-aged Beto O’Rourke. An electric bassist, he toured the United States and Canada in the early 1990s with his punk rock band, “Foss,” meaning “waterfall” in Icelandic and Norwegian.

The photograph might have collected dust in an obscure corner of rock history were it not for an attempt this week by Texas Republicans to showcase skeletons in O’Rourke’s closet. The El Paso native has hung up his guitar and is now a three-term Democratic congressman taking on Republican Sen. Ted Cruz in the midterm elections this fall. The campaign leaves time for only occasional musical interludes, such as a Fourth of July performance with Willie Nelson.

The maneuver by the state party had its drawbacks. The evidence dredged up and circulated on Twitter, rather than incriminating O’Rourke, made him appear, well, downright seductive to some. It turned the congressman into a symbol of the connection between music and politics, expressed in everything from patriotic hymns to antiwar ballads to contemporary hip-hop.

The more offbeat side of the candidate revealed this week seemed especially alluring to those most staunchly opposed to President Trump and his legislative allies, including Cruz. Lauren Duca of Teen Vogue asked: “are we all dating Beto now?”

Others opined that O’Rourke’s more colorful past — and specifically his outfit in the photograph of the band — would prove divisive in Texas. “He wouldn’t dare!” wrote Jeff Roe, a Republican strategist who managed Cruz’s 2016 presidential campaign.

The congressman’s campaign didn’t return a request for comment on Wednesday.

O’Rourke, 45, is a rising Democratic star. Town & Country called him “Kennedyesque.” The Texas Democrat has captured the attention of celebrities, from Ellen DeGeneres to LeBron James. “Is Beto O’Rourke the left’s Obama-like answer to Trump in 2020?” asked Vanity Fair this week, quoting a Texas journalist noting, “It seems like Iowa in 2007.”

His popularity on the national stage was elevated by a viral video clip from a town hall last week in Houston, where O’Rourke defended football players who kneel during the national anthem to protest police violence. His eloquent delivery and ease in drawing on the nation’s civil rights history recalled the oratory of the underdog Democrat who promised hope and change a decade ago.

The anthem issue has become a fault line in what is likely to be a bitter race. An Emerson College poll this week showed Cruz, a 2016 Republican presidential contender who is seeking his second term in the Senate, leading O’Rourke by a single point. Cruz, 47, has made the NFL — one of President Trump’s favorite topics — a focal point of his strategy against O’Rourke, who is trying to become the first Democrat to win statewide office in Texas since 1994.

Apparently incensed by the congressman’s refusal to debate Cruz on Friday in Dallas, the state GOP took to Twitter to launch a series of attacks in the form of theories about why “Beto has been ducking debates with Senator Ted Cruz.”

“Sorry, I’m going to have to skate on the debate Friday,” read the white text superimposed on an image of O’Rourke holding a skateboard. “I just got this killer board. I’m sure the voters won’t mind.”

Earlier this month, O’Rourke zipped around the parking lot of a Whataburger, the San Antonio-based chain, on a skateboard borrowed from a supporter. After hours on the campaign trail, O’Rourke told a Dallas Morning News reporter at the time, “you need a little, like, moment.” He said the board offered him “zen.”

The congressman seemed relatively at ease on wheels, bending his knees and spreading his arms out like wings as he made a “whoosh” noise. When he gave a passerby a high-five, he wobbled just a bit. No tricks were attempted.

The Texas GOP had additional explanations for his absence from the proposed debate.

“There’s always the chance,” the party observed on Twitter, that O’Rourke can’t show up to the debate “because he got into a hazy situation.” The tweet included a decades-old mugshot highlighting the congressman’s criminal record, which O’Rourke has acknowledged. He was twice arrested in the 1990s, according to public records and the candidate’s own statements — in 1995 for trespassing when he attempted to sneak past a fence at the University of Texas at El Paso and again in 1998 for driving under the influence of alcohol. The first charge was dropped and the second later dismissed.

The incidents have come up occasionally during election season. O’Rourke told the El Paso Times in 2005, when he was first running for city council, that he has “owned up to it and . . . taken responsibility for it.”

The most popular image circulated by the state Republicans, according to the authoritative metric of Twitter “likes,” was the photograph of O’Rourke’s band. An excuse was scrawled on the bottom, “Sorry, can’t debate. We have a gig.”

Foss is described by the music magazine Spin as an “all-but-forgotten Texas post-hardcore band.” Roll Call labeled the group a “veteran of the ’90s emo-progressive invasion.” Its drummer, Cedric Bixler-Zavala, went on to greater musical fame than did the band’s bassist. Bixler-Zavala was the lead singer and lyricist of the Grammy Award-winning The Mars Volta and has been the only consistent member of At the Drive-In, for which he sings vocals. Both are cult favorites. O’Rourke has said that the bandmates were grade school and high school friends.

Streaming services don’t carry Foss tunes, but YouTube clips preserve several gigs, including a 1993 performance at the music venue Wild Hare’s in El Paso and a 1994 appearance on a talk show, “Let’s Get Real.” On the talk show, O’Rourke sported a T-shirt and a matching knit hat and jumped up and down as he plucked vigorously at his guitar.

The image circulated by the Texas Republicans is drawn from the band’s 1993 record, “The El Paso Pussycats.” The band toured North America, but O’Rourke’s foray into punk rock was short-lived. He was finishing an undergraduate degree in English at Columbia University at the time.

“I wasn’t that good at it,” he told The Washington Post last year, saying he felt pressure from his father to move on from the punk scene. “He won’t say it, but the expectation is: We didn’t take out loans for you to go to Columbia and then [play] in a punk band your whole life.”

O’Rourke is hardly alone among politicians in pursuing music. Martin O’Malley, the former governor of Maryland, returned to his band, “O’Malley’s March,” after ending his 2016 presidential bid. Mike Huckabee, the former governor of Arkansas, took his band, “Capitol Offense,” on the road with him during his 2008 campaign for the White House. Some, like O’Rourke, left their bands when they were young. Former secretary of state John Kerry performed with “The Electras” when he was in prep school in New Hampshire.

Cruz, for his part, has said that his music tastes have shifted over time. He came of age listening to classic rock but turned away from the genre because he didn’t like how its musicians responded to the Sept. 11 attacks, he said.

“I actually find this intellectually curious, but on 9/11, I didn’t like how rock music responded,” Cruz told CBS News in 2015. In contrast, he said, “country music collectively, the way they responded, it resonated with me, and I just have to say just at a gut level, I had an emotional reaction that said these are my people.”

The Texas senator has chosen other means of connecting with voters. He frequently quotes movies and TV shows. He has also tried sports. Campaigning in Indiana in 2016, he likened his candidacy to the underdog basketball team in the film “Hoosiers.” Yet he raised eyebrows when he referred to the hoop as the “basketball ring.” He took to the court to reclaim some credibility in June, challenging late-night host Jimmy Kimmel to a charity match. Cruz won 11-9, though neither was especially graceful.

O’Rourke supporters responded to the jabs from the Texas GOP by hauling out old footage of Cruz struggling on the basketball court. Others noted that the images of O’Rourke were more flattering than comparable material from Cruz’s past.

According to The Daily Dot, an Austin-based media company, an image of Cruz in white face paint came from a high school yearbook, that documented a performance in which he acted out the biblical creation story, playing Adam in a stage adaptation of the Book of Genesis.

The website created a catalogue of positive reactions to the images shared by the Texas GOP, arguing that the party’s strategy had backfired. Vice said the “humiliating evidence” showed only that the country “might be interested in dating Beto O’Rourke.” GQ observed that the only “scandal” unearthed by Republicans was that “Beto O’Rourke has friends, is cool.”

The state party dug in its heels, dismissing those who looked favorably on the images as irrelevant to Texas politics.

More from Morning Mix:

Detroit public schools shut off drinking water due to ‘elevated levels’ of lead, copper

Orson Welles died before finishing his final film. It will debut this weekend after years of legal battles.

Trump, Carl Bernstein tangle on Twitter over CNN story