Gold gave up early gains on Monday as a robust dollar outweighed safe-haven demand after Greeks rejected the terms of a bailout package in a referendum. The failure to sustain the rally shows gold's struggle amidst prospects of higher US interest rates despite the uncertainty over Athens' financial situation and its future in the euro zone, a situation that would typically garner safety bids for bullion. Spot gold was flat at $1,167.50 an ounce by 0652 GMT, after earlier jumping by as much as 0.6 percent. US gold climbed nearly 1 percent in its biggest daily gain in about two weeks to $1,174.40 before paring some gains to trade up 0.3 percent. Silver, platinum and palladium all declined. "Gold's deterioration is evidence of the market discounting wider contagion risk from a Greek default and increasing certainty of a US rate hike this year," Barclays analysts said in a note on Monday. In a referendum on Sunday, Greeks overwhelmingly rejected conditions of a rescue package from creditors. Official figures showed 61 percent of Greeks had rejected a deal that would have imposed more austerity measures on an already ravaged economy. The vote leaves Greece in uncharted waters: risking a banking collapse that could force it out of the euro. Without more emergency funding from the European Central Bank, Greece's banks could run out of cash within days. Gold, typically seen as an alternative investment during times of financial and economic uncertainties, rallied early in Asian hours as the euro slumped and US equity futures fell on risk-averse sentiment in the market. But the precious metal failed to hold the gains, even as other safe havens such as the yen rallied and the dollar climbed to its highest in a month. "Its safe-haven property does not appear to be carrying much weight," said Howie Lee, an analyst at Phillip Futures.