The S&P 500 and Nasdaq Composite tallied fresh record closing highs on Thursday, buoyed by a stronger-than-expected jobs report that helped dampen expectations for a Federal Reserve interest-rate cut in July.