I have a wordpress site and I'm using a contact form on this particular page. Each input field has a heading, such as "Name", "Email", etc. It looks great on any desktop browser. But when viewing it from a iphone, the text goes too far and doesn't line up with it's input box. So I tried the following:
.page-id-1656 .entry-content-p {
width:40% !important;
}
And that works for the text, but the problem is that shrinks all my other fields. So the input boxes are no longer the size I want them. Is there a way to target only the text?
If this helps, here is the CSS for the input fields:
.page-id-1656 .wpcf7-textarea {
width:40% !important;
height:100px !important;
font-size:15px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
border-radius: 5px 5px 5px 5px;
border-color:#adadad !important;
outline:none !important;
}
Or is there a way to use what I tried but make it block out .wpcf7-textarea
EDIT: View source gave me this as the class: wpcf7-form-control wpcf7-text
EDIT 2: Font scaling based on width of container appears to be the answer I'm looking for. I'm leaving the question up as it may be helpful to others. The answer was changing font-size to 1vw instead of 15px. Changing the unit to vw allowed the font to adjust based on the device using it.