* C$ at C$1.0368 vs US$, or 96.45 U.S. cents * Shutdown, looming debt ceiling deadline create risk aversion * Canada's trade deficit rises to C$1.31 billion * Bond prices mixed By Leah Schnurr and Alastair Sharp TORONTO, Oct 8 (Reuters) - The Canadian dollar weakened against the greenback on Tuesday after the trade deficit widened more than expected in August and as the government shutdown south of the border dragged on. U.S. President Barack Obama said he would be willing to negotiate with Republicans over budget issues only after they agree to re-open the federal government and raise the debt limit with no conditions. While investors have largely taken the 8-day-old shutdown in stride, the threat that the world's largest economy does not raise its debt threshold and technically defaults later this month has sparked fears of potential global economic havoc. "The U.S. government shutdown has now been tied together with the debt ceiling, because the deadline is looming late next week," said Greg Moore, currency strategist at TD Securities. "If the U.S. does in fact default, your guess is as good as mine on what happens and the U.S. dollar may in fact sell off quite sharply initially," Moore said. While the U.S. currency was flat near eight-month lows against major currencies on Tuesday, it outperformed so-called risk currencies such as the Canadian dollar. Canada's trade deficit rose to C$1.31 billion ($1.27 billion) as imports grew to set a record. The data offset a more upbeat report that showed housing starts jumped in September. "Exports are a large part of the Canadian economy and they are really going to underpin the recovery for us," said Scott Smith, senior market analyst at Cambridge Mercantile Group in Calgary. "So, if they are not progressing as fast or as well as we'd like, then we're going to see some loonie selling on the prospects moving forward for the whole economy." Because of the role it plays in the economy, the export sector is also a significant focal point for the Bank of Canada in terms of when the central bank will raise interest rates, said Smith. The Bank of Canada earlier in the month cut its third-quarter economic growth forecast and said the export sector might recover more slowly than expected. The Canadian dollar ended the day at C$1.0368, or 96.45 U.S. cents, weaker than Monday's close of C$1.0313, or 96.96 U.S. cents. The Canadian currency briefly hit a session high of C$1.0308 shortly after the housing data. The United States has until mid-October before it hits the $16.7 trillion borrowing limit. The impasse was reminiscent of the 2011 showdown over the debt ceiling, which yielded an agreement only at the last minute. "With markets looking back at 2011 and saying an eleventh-hour deal was done then, expectations are we'll get something hammered out before Oct. 17," said Smith. Following a brief spike after the Federal Reserve's decision to stand pat on its economic stimulus on Sept. 18, the Canadian dollar has been trading in a tight range for several sessions. The minutes of that Fed meeting will be released on Wednesday, perhaps offering clues as to how close the bank came to a scaling back of stimulus. "It will be quite interesting to see the tone of that discussion," TD's Moore said. Analysts see the loonie in a range between mid-C$1.02 and mid-C$1.03 for now, baring a resolution or other catalyst. Prices for Canadian government bonds were mixed across the maturity curve. The two-year bond slipped half a Canadian cent to yield 1.190 percent, while the benchmark 10-year bond gained 3 Canadian cents to yield 2.566 percent.