Machine learning of microstructure--property relationships in materials with robust features from foundational vision transformers