Dow, S&P 500 close at record highs