LISBON, Portugal – Deep inside the Rock of Gibraltar is a room known as The Vault. Dug by the British army in World War Two, the room now houses servers that power the websites of dozens of international online gambling companies.
Those companies were lured to this speck of British territory on Spain's southern tip by its low taxes and its unimpeded access to the European Union's single market of around 500 million people.
It's a flourishing and hugely important business for Gibraltar, accounting for around 25 percent of the economy, some 40 percent of corporate tax revenues and almost 3,000 of its 26,000 jobs.
And the European market is only set to get bigger. According to market data company H2 Gambling Capital, it could be worth around 30 billion euros ($32.5 billion) a year by 2021, nearly double current levels.
Britain's looming departure from the EU, therefore, has cast a cloud over Gibraltar's future because Brexit could see it shut off from the rest of the EU. That possibility is already having an indirect impact on Gibraltar, by magnifying the appeal of other low-tax jurisdictions such as Malta.
Nobody is panicking yet, and no gambling company has said it intends to leave Gibraltar while EU and British officials negotiate Brexit — in March, before calling an early general election for June 8, Prime Minister Theresa May formally triggered the two-year Brexit process.
Senior executives of 888, which runs one of the world's biggest online casinos, have already sounded the alarm about potential dangers, however.
Earlier this year, they warned that 888's reach into the EU's other 27 member countries could be limited in the event of a so-called "hard Brexit" scenario whereby Gibraltar, like the rest of Britain, sees trade disrupted by the imposition of tariffs and businesses potentially becomes ineligible for regulatory licenses in some EU countries.
In its full-year financial report, 888 said it "would reconsider the appropriateness of remaining registered, licensed and operational in Gibraltar in these circumstances" and added that "Malta may be considered as an alternative 'dot com' licensing jurisdiction."
Malta, a small island nation in the middle of the Mediterranean Sea, stands ready to attract Gibraltar's gambling firms. The Maltese government is another champion of the online gambling sector, which represents 11 percent of the nation's GDP and employs 8,000 people.
Two other gambling industry big-hitters, Ladbrokes Coral Group and William Hill, say they are monitoring the Brexit negotiations — and, like 888, have no plans at the moment to depart.
William Hill has set up a Brexit Working Group to assess Brexit's possible financial, operational and regulatory consequences and make sure that "suitable arrangements are in place should there be disruption to the Gibraltar (border) crossing or the availability of any services offered through Gibraltar."
For those working in the sector, the coming two years are likely to be a worrisome period. After all, 1,800 staff — nearly 60 percent of the sector — commute from Spain to their workplaces, which are often located in smart office blocks overlooking the Bay of Gibraltar where elegant yachts bob on the calm waters.
Their fate, and the industry's, depends to a large degree on whether Madrid opts post-Brexit to hinder cross-border traffic, as it has occasionally in the past.
That is the "real worry" for employees, says Mark Jordan, the head of gambling industry analysis at PwC in London: "How difficult will Spain be?"
Gibraltar has been a thorn in the side of U.K.-Spain relations for decades. In 1969, Spanish dictator Gen. Francisco Franco slammed the border shut in an attempt to wreck its economy and snatch the territory from Britain.
Brexit, some fear, might achieve what Franco couldn't.
The Gibraltar government has made no secret of the importance of the EU. On its website, it still lauds the benefits of EU membership as one reason why firms should set up on The Rock. The people of Gibraltar clearly think it's important — nearly 96 percent of Gibraltarians voted to remain in the EU in last June's referendum.
No wonder — the territory has prospered under Britain's rule and free trade with the EU.
For now, Gibraltar officials are holding their nerve.
Phill Brear, the territory's Gambling Commissioner, says it is "sensible, prudent management" for the online gambling industry to be making arrangements for potential Brexit outcomes.
"They're hedging their bets," he told the Associated Press, noting how many are taking out Malta licenses alongside their Gibraltar ones.
Brear notes that Gibraltar will still have access to U.K. customers, who account for around 40 percent of the entire EU market in financial terms, according to H2 Gambling Capital data.
Brear has not given up hope of working around any future regulatory constraints.
One fear has already come true, though: Gibraltar's worry, he says, "was that if you open this Pandora's box of Brexit, who knows what it'll look like."