Conditional Form Error Messages?

Hi - I know it’s possible to add custom error messages (https://documentation.unbounce.com/hc/en-us/articles/360001198903-Modifying-Form-Validation-Error-Messages)

But is it possible to display an inline error message based on conditional selection of either an a) dropdown item or b) radio selection?

Anyone have experience with the Javascript for this?