An earthquake in Afghanistan's east and flash floods in the north killed at least 33 people on Wednesday as hundreds of traditional mud-brick homes collapsed, officials said.