Objective: I have 2 nos of same fields in a field - editor. (AADHAR Status)

- When the Value is Y (Field 1 should get display) - This has a CSS - Green

- When the Value is not Y (Field 2 should get display) - This has a CSS - Red

The desired output: Only one Field should be visible at a time. If the value in Y then the 1st one (with Green CSS) and when the value is not Y then the 2nd one (with Red CSS)
But, I am unable to render the fields properly. Instead, I am getting the following Result.

Any help will be highly appreciated.
Thanks