Scots in northern parts of the country could wake up to frosty conditions on January 1 as a weather warning has been issued for snow and ice.