I'm looking to design an input element that has a border which changes when the input is focused.
Here's how I want the inputs to behave:
When the user focuses on the input or fills it out, I want the label to move up and the border to be trimmed so that the label isn't hidden by the border.
I attempted to add a background to the before element of the label, but realized this approach wasn't suitable because the input itself doesn't have a background. Depending on the subpage, there could be a different background color and the result ended up like this:
Can anyone assist me with this challenge?