S&P 500, Nasdaq post 5-day losing streak as rate fears upend AI trade