Nasdaq records best day since May as US stocks rally