You would have to write several different sets of CSS using the @media query.
First one is the general one for all desktop browsers:
input[type="text"] { width: ?px; }
Next one is your tablet device CSS:
@media screen and (min-width: 800px) {
input[type="text"] { width: ?px; }
}
And the third one is for phones:
@media screen and (min-width: 480px) {
input[type="text"] { width: ?px; }
}
You can adjust the min-width values to your liking. Just make sure to wrap the css rules within the parent tags. Meaning: Don’t forget the last } when using the @media screen property.
Hope that helps.