Ramsey Quantifiers over Automatic Structures: Complexity and Applications to Verification