Union officials Jack O'Connor and Dave Begg discuss the implications

IN the end the two sides were agonisingly close to a deal. And that they got so close, rather than their ultimate failure, is probably the big surprise of the talks between the government and the unions.

The extraordinary fact that the unions were willing to agree to a cut in the public-sector pay bill of €1bn-plus has been almost entirely forgotten amid all the furore over the 12 days unpaid leave.

And if the talks had taken place in a bubble, free from outside influences until agreement was reached, there is no question a deal would have been done.

But ultimately these outside influences were what scuppered the negotiations. Nobody realised it at the time but the talks were doomed from the point on Tuesday when it became clear that Thursday's day of action had been cancelled and a deal was very much on.

The popular view in government circles is that the unions oversold what they had on Tuesday night with an almost triumphalist reaction to what was emerging as the likely basis for an agreement.

It's easy to say with hindsight but the unions in their anxiety to justify the cancelling of the strike day forgot there was another constituency that they had to sell any deal to – the general public.

In some ways that is not surprising. Over the past two decades, public opinion has been largely irrelevant when it came to negotiating deals between the social partners.

In the good times, nobody paid too much attention to the various gymnastics performed and nuances emphasised in order to reach a deal. But these are no longer good times and the public backlash against what was being proposed shocked everybody associated with the talks and ultimately made a deal impossible.

The unpaid leave days may indeed have been "a minor part of the deal", as unions leaders argued last week, but in the public debate it became absolutely central, with the apparently genuinely transformative nature of the reforms agreed for the public service largely ignored.

"What was on offer was that the unions were willing to offer over €1bn for next year [in a temporary reduction in pay] and then for 2011 come up with a different way [through reforms and natural wastage] of getting that €1bn-plus. Then they were asking that if they delivered that, would the government in return give 12 days' leave over a number of years. If it had been sold like that, it would have been different. But instead the unions linked the pay to the days leave and that drove people apoplectic. Once that was done the deal was screwed," said a source close to the negotiations.

There is also an acceptance in government circles that perhaps "we didn't do enough to dampen down" speculation of an imminent deal on Tuesday but sources say they were constrained by a reluctance "not to you-know-what all over the unions, who had just announced the calling off of their strike".

Given the public mood, however, it might not have mattered how the deal was sold. "This is a new era and people want straight talking. There isn't going to be any softening of the blow for social- welfare recipients or those who have been made unemployed. There's no room for fudge any more. The old language of social partnership doesn't wash any more. It's about pounds, shillings and pence and there's no room for nonsense," said another close observer.

It didn't help that in the wake of the benchmarking fiasco, the public is also sceptical of promises of public sector reform which have been included in previous social partnership deals and delivered close to nothing. A little like the taxi drivers a few years back making a conversion to the merits of more taxi plates only after de-regulation, the unions probably – in relation to public opinion – left it too late with their commitment to public-sector reform.

Much less justifiably, the unpaid leave proposal fed into the stereotype of a pampered and cosseted public sector. Fianna Fáil TDs were reportedly inundated with complaints from the public which prompted last week's extraordinary hardline stand from backbenchers who last summer had no stomach for taking on the extremely privileged pharmacists.

The word this weekend was that the "totality" of the unions' final offer of savings – which is believed to be "north of €1bn" – wasn't enough. But it's hard to believe that the talks broke down over €200m. It's much more credible that the public response dramatically shifted the goal posts. The unions' subsequent refusal to budge from the hugely unpopular unpaid leave option and a real uncertainty as to whether the €1bn-plus in savings would be delivered for 2011 meant the government felt it couldn't sign off on a deal.

The fall-out has left both sides damaged – largely unfairly as there is no doubt all parties were genuinely trying to do a deal that would have avoided a long-damaging winter of discontent. The unions' negotiating position has been hugely weakened because they have now very publicly accepted the need to reduce the public-sector pay bill by more than €1bn; the only point of difference with the government is over how this should be achieved.

Cowen, meanwhile, has been accused of first caving into the unions and then rowing back because of a combination of public opinion and angry members of his parliamentary party.

It didn't take long last week for the old rumour about tensions between the Taoiseach and his minister for finance Brian Lenihan to re-emerge.

There is little doubt that Cowen was more enthusiastic about a deal than Lenihan, but that is to be expected. The minister for finance's main concern is in relation to book-keeping, the Taoiseach has to take a wider view.

However, Lenihan is also a politician to his fingernails and he would have seen the political advantages of a deal with the public-sector unions and the potential prize on offer in terms of public-service reform.

There would have been serious scepticism in the Department of Finance that the unpaid leave could deliver the requisite savings but if a deal could have been agreed that would have secured somewhere north of €1bn, Lenihan would have gone along with it.

Well-placed sources dismiss out of hand any suggestion of Lenihan threatening to walk over this issue, but he would certainly have pointed out at cabinet that the numbers had to add up and that, for example, €800m – the figure initially being mooted in the negotiations – was not enough.

Those close to Cowen say that this would also have been in line with the Taoiseach's own thinking and that, although he was keen to do a deal, he "wasn't willing to lie down". There is also a body of opinion that the unions misread Cowen and believed he would be so happy to get them onside, he wouldn't be too concerned about the detail of the deal or how it would deliver the savings in a year's time.

Certainly Cowen is very different from Bertie Ahern and, because of the economic crisis, the days are gone when doing a deal is more important than what's in it. But there is little doubt that Cowen and the government's line in the negotiations hardened considerably as it became clear public opinion was against the concept of unpaid leave, particularly for frontline staff. And it's difficult to believe that the deal on offer from the unions on Friday wouldn't have been enough if there hadn't been all of the hullabaloo in the previous few days.

Whether or not that deal would have been a good one or not for the country depends on one's viewpoint. Sources on both sides of the negotiations say that the reform element of the deal was genuine and would have seriously changed the restrictive way in which the public service operates. There also appears to have been some late movement from the unions on pay cuts for higher-paid civil servants.

But all of that progress now goes by the wayside, for this budgetary process at least. In terms of the budget numbers, cutting the public-sector pay bill is now a straightforward exercise in cutting pay by an average of 5-7%.

But that cut, along with the hostile reaction to the proposed deal, will understandably be bitterly resented by public sector workers. Politically, the opportunity for Fianna Fáil to woo back the tens of thousands of public sector workers who have switched allegiance to the opposition, particularly Labour, is gone.

And the implications for industrial relations could yet be significant. The union leadership may find it a lot more difficult now to rein in more militant members.

Against that, public sector workers are not immune to public opinion and after a demoralising week, there may not be the appetite to return to the fray regardless of what happens in Wednesday's budget.

In keeping with the crisis mode of the past 18 months, attention will now quickly shift from the collapsed pay talks to what Lenihan has in store in terms of cutbacks. There was opposition speculation that the rebellious noises coming from the government backbenches over the unpaid leave mean that the safe passage of the budget cannot be guaranteed.

That looks like wishful thinking, but the whole pay talks exercise is a reminder, if one were needed, that it is simply not possible to come up with €4bn in cutbacks without stepping on a few landmines.

Don't be surprised if there are a few more explosions this week.