With the rapid spread of marijuana legalization in the US, big law firms are discovering that the tangled web of regulations guiding the rapidly growing industry is a boon for business.As cannabis companies grow, merge, and start getting the attention of Fortune 500 corporations as acquisition targets, they need more sophisticated advice.Numerous big law firms have built out specialized cannabis practice groups to serve the nascent industry.When Joshua Horn and his wife traveled to Colorado about five years ago, they thought they'd check out one of the state's new marijuana dispensaries for fun."The 'budtender' says, 'What I can do for you''" Horn, the cochair of Fox Rothschild's Cannabis Law Practice, told Business Insider in an interview. "We actually didn't buy anythingwe just wanted to see what one of these looked like."After the two left Colorado and returned home to Philadelphia, Horn's wife said he should think about cannabis law as Pennsylvania began moving toward legalizing medicinal marijuana.Read more: Big asset managers like BlackRock are sitting on the sidelines of the $75 billion US marijuana industry because of one big pain point"Five years later, I'm the cochair of a national cannabis practice," Horn said. "And we have clients all over the world."With the rapid spread of marijuana legalization in the US, once reluctant big law firms are discovering that the tangled web of regulations guiding the rapidly growing industry is a boon for business.Following the midterm elections, some form of cannabis is now legal in 33 states, and many in the industry say it's only a matter of time before legalization sweeps the nation.And big money, naturally, has followed.From boutiques to big lawAs cannabis companies grow, merge, and start getting the attention of Fortune 500 corporations as acquisition targets, they need more sophisticated advice on financing, tax planning, and corporate structure."It's one of the few emerging markets with a multibillion-dollar potential," said Seth Goldberg, a partner at Duane Morris who heads up the firm's cannabis practice.While some boutique firms have served the cannabis industry since Colorado legalized the drug in 2012, most small law shops may not be able to negotiate complicated joint ventures or merger agreements, lawyers say.For Christopher Barry, a longtime capital-markets lawyer who is the chair of Dorsey & Whitney's Canada Practice Group, that's exactly what piqued his interest.A few years ago, Barry, who's based in Seattle, picked up the phone and had a representative of a multibillion-dollar Asian investment group on the line.The representative said he was looking at evaluating marijuana investments in the US. But when he went to the fund's regular counsela large, white-shoe law firmthe firm turned them down."So the person said, 'We did a bunch of research about who could do the work and who could provide the level of service we're used too,'" Barry said. "Well, that got my attention."Since then, Dorsey has built up a cannabis practice group across its offices in Denver, Seattle, and Toronto, with about 20 to 25 lawyers.Barry has since helped well-known US cannabis companies like MedMen and Green Thumb Industries execute cross-border mergersin these instances, firms that went public in Canada by merging with a publicly traded shell company.The market for these cross-border mergers is red-hot. According to data from Dealogic, the number of US companies pursuing reverse mergers in Canada has more than doubled in the past five years, to over 16 this year from just 7 in 2013, with cannabis companies leading the charge.Read more: Marijuana companies are using a 'backdoor' strategy to tap the public marketsand it's fueling an M&A boomBen Reznik, a partner at the Los Angeles-based Jeffer Mangels who has spent much of his career working on land-use issues, said he started taking work from cannabis companies in Southern California on an "ad hoc" basis.Many partners at his firm, however, were reluctant to get in with the specter of federal illegality hovering over the industry. "So we didn't jump right into this by any means," Reznik said. He said that as the firm debated the issue internally, about 10% of the partners were "naysayers.""They were more about, why take the risk'" Reznik said. "Do we really want to do that'" Ultimately, Reznik said Jeffer Mangels was an "entrepreneurial firm.""There was just a tremendous need for our services," Reznik said. Now, like Dorsey, the firm earlier this year established a cannabis group.Getting in on the ground floor of a global industryFor younger lawyers, cannabis is a way to get in on the ground floor of what is set to be a global industry.Neeraj Kumar, a New York-based associate at Duane Morris, started his career as a corporate-securities lawyer around partners who had been practicing law for over 20 years.Because cannabis is such a new industryno lawyers have more than five or six years of experience in the field"it definitely presents a unique opportunity to be a thought leader," Kumar said."At least in my career, there hasn't really been an industry with that opportunity," he said.Rachel Gillette, a Denver-based partner at Greenspoon Marder, was one of the earliest practitioners of cannabis law.In 2010, right when Colorado first started regulating medical marijuana, she quit her job as a tax attorney. "I borrowed a little money from my mom and started my own practice focusing only on representing cannabis businesses," Gillette said. "I was probably one of the first attorneys in the nation to do something like that at the time."When she emailed her favorite law professor to tell her about opening her own practice, her professor responded curtly: "She was like: 'You're going to be disbarred.'"Fast forward to 2018, Gillette is now a partner at Greenspoon Marder. That same professor recently reached to invite Gillette to teach a class on cannabis law."A few years ago, you couldn't find a large law firm to touch the area with a 10-foot pole," Gillette said. "But now I'm cool."'More fun than a barrel of monkeys'While many law firms have quickly built up cannabis practices, the biggest white-shoe firms aren't quite there yet. Some of the lawyers Business Insider spoke with speculated that some big firms might steer clear purely for reputational reasons.Others said it's not worth the risk for firms with blue-chip clients.It boils down to this: Recreational marijuana isn't yet legal in New York state, where most of the largest firms are headquartered. Though that may change in 2019, the cannabis industry may still be too small for the largest firms to take the risk of dealing with an industry that's federally prohibited, the lawyers said.Read more: Beverage giants like Heineken and Constellation Brands are duking it out in the billion-dollar market for marijuana-infused drinksBut if the federal government removes cannabis from the list of controlled substancesor if Congress passes legislation like the bipartisan States Actthen "the floodgates will open," Reznik said."I think there'll be a flood of lawyers getting into the field at that point," Reznik said. "It'll be a free-for-all." And when that happens, those who are already experts in the field hope they'll have the first-mover advantage.In any case, being at the forefront of a brand-new, exciting field is just plain fun."This is more fun than a barrel of monkeys," said Barry, the Dorsey & Whitney partner. "Look, I'm 71 years old. I've been practicing for over 40 yearsif I weren't having so much fun with this, I'd be retired."Read more:These execs are leaving behind careers at companies like Coke and Victoria's Secret to tap into the $194 billion marijuana industryA marijuana-focused investment firm started by a pair of Wall Street veterans just closed a $55 million fundA cannabis CEO who led turnarounds at FAO Schwarz and Patagonia explains why he's looking to poach 'nimble' people from small companiesrather than big-name execsSEE ALSO:The top 12 venture-capital firms making deals in the booming cannabis industry that's set to skyrocket to $75 billionJoin the conversation about this storyNOW WATCH: Bernie Madoff was arrested 10 years ago today ' here's what his life is like in prison Click here to read full news..