By Gina Cherelus

NEW YORK (Reuters) - Three suspected burglars who stole millions of dollars from two New York banks were caught after using a personal credit card to buy the tools of their trade, authorities said.

The trio were charged on Tuesday with using blowtorches to cut through the roofs of the banks in Brooklyn and Queens to access the vaults and steal cash and valuables in April and May of this year, local and federal law enforcement officials said.

They were captured thanks to surveillance footage and cellphone data, authorities said, as well as records showing they bought plywood from Home Depot and blowtorches from a local welder in order to carry out the crimes.

"These heists resembled scenes from the movie Heat – the work of a crew that was well organized, meticulous, and elusive to law enforcement," New York City Police Commissioner Bill Bratton said in a statement. "The picture slowly came into focus, resulting in today's arrests and charges."

The three Brooklyn men, named as Michael Mazzara, Charles Kerrigan and Anthony Mascuzzio, allegedly stole more than $5 million in cash and valuables, including jewelry and baseball cards. Each faces up to 20 years in prison if found guilty of bank burglary and conspiracy to commit bank burglary.

(Reporting by Gina Cherelus; Editing by Daniel Wallis and Marguerita Choy)