Problem styling contact form 7

Hi there,

I installed contact form 7 and centered the form with this code:

.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 textarea { float : none; margin: 0 auto; }
.wpcf7 { text-align: center; }

Everything works fine, except that the form is with small size. If I change the size of the fields (width), it is not responsive on mobile.

Is there a way to fix this, or Sydney do not support contact form 7?

Thanks in advance!

Hello there,

You might need to define max-width: 100% to make their width adaptable on smaller screen. So the code would look like this:


.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 textarea { 
   float : none; 
   margin: 0 auto; 
   width: 400px;
   max-width: 100%; 
}

Regards,
Kharis

Kharis Sulistiyono Thanks it worked! Best theme and support ever ! :slight_smile:

You’re welcome!

I am glad to have an opportunity to assist you.

Please let us know in a new topic if you have any further questions, or if we can provide you with any other assistance.

Regards,
Kharis