/* Center form */
.salesforce_w2l_lead form.w2llead {
    text-align: center;
    clear: both;
    max-width: 400px;
    background: #f9f9f9;
    border-radius: 10px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1);
}

/* Fix input fields - square corners, proper size */
.salesforce_w2l_lead .w2linput.text,
.salesforce_w2l_lead .w2linput.text.captcha,
.salesforce_w2l_lead input[type="text"],
.salesforce_w2l_lead input[type="email"] {
    height: 40px;
    padding: 8px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 0 !important; /* Force square corners */
    box-sizing: border-box;
    display: block;
    margin: 0 auto 10px auto;
}

/* Fix CAPTCHA container spacing */
.salesforce_w2l_lead .captcha-container {
    align-items: center;
    justify-content: center;
    margin-top: 0px;
}

/* Resize CAPTCHA image */
.salesforce_w2l_lead .w2limg {
    display: block;
    width: 150px; /* Adjust image width */
    height: auto; /* Maintain aspect ratio */
    margin-bottom: 10px; /* Space between image and input */
}

/* Adjust CAPTCHA input field */
.salesforce_w2l_lead .w2linput.text.captcha {
    width: 150px;
    height: 40px;
    font-size: 18px;
    text-align: center;
    font-family: 'Times New Roman', serif;
    font-weight: bold;
    border-radius: 0 !important; /* Force square corners */
}

/* Fix Submit button alignment */
.salesforce_w2l_lead .w2lsubmit {
    align-items: center;
    margin-top: 0px;
}

/* Style the submit button */
.salesforce_w2l_lead input[type="submit"],
.salesforce_w2l_lead .w2linput.submit {
    display: block;
    width: auto;
    padding: 12px 20px;
    background: #ff3366;
    color: white;
    font-size: 16px;
    border: none;
    border-radius: 0 !important; /* Force square corners */
    cursor: pointer;
    transition: background 0.3s ease;
    margin: auto; /* Centers the button */
    margin-top: 15px;
    align-self: center;
}

/* Hover effect for Submit button */
.salesforce_w2l_lead input[type="submit"]:hover {
    background: #cc2955;
}

/* Ensure required field indicators are clear */
.salesforce_w2l_lead .required {
    color: red;
    font-weight: bold;
}

.salesforce_w2l_lead .error_message {
    color: red;
    font-size: 12px;
    margin-top: 5px;
}

/* Override global styles */
.salesforce_w2l_lead input,
.salesforce_w2l_lead button {
    all: unset;
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 0 !important; /* Force square corners */
    font-size: 16px;
}

/* Responsive fixes */
@media (max-width: 600px) {
    .salesforce_w2l_lead form.w2llead {
        max-width: 90%;
    }
    .salesforce_w2l_lead .captcha-container {
        width: 100%;
    }
    .salesforce_w2l_lead .w2linput.text.captcha {
        width: 100%;
    }
}