Tech losses drag down Nasdaq and S&P