Even though the sun is highest at noon and furthest away at midnight (up to time zone discretization and daylight savings), a typical day is not hottest at noon and not coldest at midnight. This is because, for example, after noon passes, the sun continues to heat up the earth more, and the temperature only begins dropping once the rate at which the sun warms the surface of the earth has fallen back below the rate at which the earth radiates heat back out. A typical day demonstrates a diurnal lag.
Likewise, the summer and winter solstices, despite having the respective longest and shortest amounts of sunshine hours, are typically not the hottest and coldest days of the year. There is a usually a seasonal lag, that is, the hottest and coldest days of the year usually fall many days after the solstice.
Many topographical features affect the degree of seasonal lag, and often amounts of summer and winter lag are different, and differently different across different locations.

This chart displays several statistics together. For each of 32 cities in the continental United States, the average hottest day and average coldest day of the year for each city are marked, and each mark spans from the average low to the average high for that city on that day.
In parentheses next to each city name are the average numbers of days of lag past the solstice in summer and winter.
Some marks are wider than other marks to make ranges clearer for cities that have the same amount of a particular seasonal lag and thus may have overlapping marks.