The contract to bring trams back to Edinburgh was an "extremely poor deal for the council" which should never have been made, an inquiry has heard.
Douglas Fairley, a lawyer representing directors of the tram delivery company Tie, said it allowed the contractor to hold the employer to ransom.
Edinburgh's trams were delivered years late, hundreds of millions of pounds over budget on a shortened route.
Lord Hardie will hear further closing speeches on Thursday.
The eventual £776m tram bill was more than double the sum earmarked at the outset.
The cost of the tram inquiry has now reached £9m, Transport Scotland has confirmed.
Mr Fairley said the contract "tended to encourage disputes" and the pricing information within it was confusing.
The Edinburgh tram inquiry further heard claims from the main contractor that work to deal with utilities in the ground was the "critical delaying factor" throughout the project.
Mr Fairley, representing several ex-Tie employees, accepted some of those he spoke for "may on occasion have made errors of judgment".
He insisted that was against a backdrop of "extreme difficulty created by others who either preceded them or in some cases were senior to them within the organisation".
"Nowhere was that more so than in the context of the contract," he said.
"If I may paraphrase a recent pronouncement by President Trump, this was a contract which was ridiculous and which should never have been made.
"It was a terrible contract for Tie and, by extension, a terrible contract for City of Edinburgh Council."
He agreed with a view expressed by others "that the way in which the contract was constructed tended to encourage disputes".
He described one aspect of the document as "clunky", "cumbersome" and "at best productive of extensive delays".
"An unintended effect of that was to allow a contractor, if it had a mind to do so, to hold its employer to ransom," he said.
Pricing details in the contract were described as "confusing and opaque".
He said: "It would be fair to say that any contract which left the door open to an argument by the contractor that something as basic and fundamental as the employer's requirements for the construction of the tram network was an extra over and above that which had been priced was an extremely poor deal for the council."
Mr Fairley further claimed the decision to withdraw Transport Scotland from the governance structure of the project was "particularly ill-judged".
Garry Borland, of contractor Bilfinger Construction UK Ltd, said the utility works (known as Mudfa works) - over which they had no control - were "very far from complete" in the run-up to the contract between Tie and the infrastructure consortium (Infraco) being concluded.
He argued that the utility work should have been completed before the summer of 2008 and the start of construction work, but was actually finished "years late".
He said: "Bilfinger's position is that the Mudfa issue was the critical delaying factor throughout the project up to the mediation at Mar Hall and indeed it continued to have effect thereafter."
Mr Borland also said the design of the project, which they had no control over, was "to a very significant degree incomplete" in the run-up to the execution of the contract. By December 2007 around 40% of the detailed design was lacking, he argued.
A number of third-party approvals, necessary for the construction work to progress, had also not been issued by others, it was claimed.