A trader at leading Swiss bank UBS "gambled away" $2.3 billion (1.75 billion euros) causing "chaos and disaster", his trial in London heard on Friday.
Kweku Adoboli, 32, traded beyond his permitted limits at the bank's offices in London because he was trying to earn a bigger bonus and wanted to boost his ego, a prosecution lawyer told a court.
Adoboli thought he had the "magic touch" but his actions rocked UBS, lawyer Sasha Wass told the 12-person jury as she outlined the case against the Ghanaian-born son of a former United Nations official.
"He is on trial because he lost his bank 2.3 billion US dollars. He fraudulently gambled it away. He also in doing so wiped around 10 percent or about 4.5 billion US dollars off the bank's share price," Wass said.
"He did all of this by exceeding his trading limits, by inventing fictitious deals to conceal this, and then he lied to his bosses.
"Mr Adoboli's motive for this behaviour was to increase his bonus, his status within the bank, his job prospects and of course his ego.
"Like most gamblers, he believed he had the magic touch. Like most gamblers, when he lost, he caused chaos and disaster to himself and all of those around him."
Adoboli denies two charges of fraud and two charges of false accounting relating to a period between October 2008 and September last year.
Southwark Crown Court heard that on 14 September Adoboli said he had to leave the office because he had a doctor's appointment.
Later that day he sent an email to his employers admitting he had tried to hide his mammoth losses, and was arrested.
Wass said the trading loss was enough to buy six new hospitals.
UBS, Switzerland's largest bank, is not represented in the trial, but is bracing itself for potentially awkward revelations about its supervision of staff.
The jury was told that the trader managed to hoodwink the bank due to the "extensive knowledge" of its systems gained during his time working in the back office.
Adoboli graduated to the front office, where the trading team operates, in 2005, before moving up to the exchange traded funds desk in 2006.
This desk deals in securities which track certain market indices and are traded like ordinary shares.
He fooled the bank's double entry accounting system, in which each entry is balanced by an equal entry elsewhere in the records, by inventing fictitious deals, the jury heard.
Traders mitigate risk during a transaction by carrying out a similar deal in the opposite direction, hedging any unfavourable market fluctuations.
According to the prosecutor, Adoboli faked hedge deals by inventing clients, leaving the bank exposed to huge losses when the market turned against him.
Despite the colossal losses, UBS's chief executive at the time, Oswald Gruebel, refused to step down.
The bank's honorary chairman Nikolaus Senn, however, said that adequate checks had not been implemented and criticised Gruebel for his over-reliance on the controls system to uncover problems.
Gruebel eventually left UBS. His replacement, Sergio Ermotti, admitted in a statement to staff this month that the case would be "uncomfortable" for the bank.