/* Base phone field layout */
.phone-field-group {
    display: flex;
    align-items: stretch;
    width: 100%;
    gap: 0;
    min-height: 48px;
}

.phone-country-code {
    flex: 0 0 auto;
    min-width: 76px;
    max-width: 96px;
    padding: 0 12px;
    font-size: inherit;
    font-family: inherit;
    font-weight: 600;
    cursor: pointer;
    appearance: auto;
    -webkit-appearance: menulist;
    line-height: 1.4;
}

.phone-number-input {
    flex: 1 1 auto;
    min-width: 0;
    width: 100%;
}

/* Footer CTA form – match .form-control (purple bottom border) */
section.sec8-cta-form .phone-field-group,
#footer-form .phone-field-group {
    align-items: flex-end;
    border-bottom: 3px solid #d394eb;
    background: none;
    min-height: auto;
    padding-bottom: 4px;
}

section.sec8-cta-form .phone-country-code,
section.sec8-cta-form .phone-number-input,
#footer-form .phone-country-code,
#footer-form .phone-number-input {
    background: none !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    color: #464141 !important;
    font-size: 25px;
    font-family: 'poppinsbold', 'Poppins', sans-serif;
    padding: 0 0 6px 0;
    height: auto;
    min-height: 40px;
    line-height: 1.3;
}

section.sec8-cta-form .phone-country-code,
#footer-form .phone-country-code {
    flex: 0 0 88px;
    max-width: 88px;
    min-width: 88px;
    border-right: 2px solid #d394eb !important;
    margin-right: 14px;
    padding-right: 14px;
    color: #ad49d3 !important;
}

section.sec8-cta-form .phone-number-input::placeholder,
#footer-form .phone-number-input::placeholder {
    color: #888 !important;
    opacity: 1;
}

section.sec8-cta-form .phone-field-group:focus-within,
#footer-form .phone-field-group:focus-within {
    border-bottom-color: #ad49d3;
}

section.sec8-cta-form .phone-number-input:focus,
section.sec8-cta-form .phone-country-code:focus,
#footer-form .phone-number-input:focus,
#footer-form .phone-country-code:focus {
    outline: none;
    color: #000 !important;
}

/* Service signup form – rounded pill inputs */
section.sec2-service-form form.service-cta .phone-field-group {
    align-items: center;
    border-radius: 50px;
    height: 60px;
    min-height: 60px;
    background: #fff;
    box-shadow: rgba(0, 0, 0, 0.26) 0 0 3px;
    overflow: hidden;
    border: none;
}

section.sec2-service-form form.service-cta .phone-country-code,
section.sec2-service-form form.service-cta .phone-number-input {
    height: 100%;
    min-height: 60px;
    border: none !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #333 !important;
    font-size: 1rem;
    font-family: 'poppinsmedium', 'Poppins', sans-serif;
    padding: 0 1rem;
}

section.sec2-service-form form.service-cta .phone-country-code {
    flex: 0 0 88px;
    max-width: 88px;
    min-width: 88px;
    border-right: 1px solid #ddd !important;
    padding-left: 1.5rem;
    color: #ad49d3 !important;
    font-weight: 600;
}

section.sec2-service-form form.service-cta .phone-number-input {
    padding-left: 0.75rem;
}

/* Khaplu popup (main_khaplu_popup) – purple theme, white text like other fields */
.main_khaplu_popup .phone-field-group,
.main_khaplu_popup .phone-field-group--khaplu,
.khaplu_body .phone-field-group,
.khaplu_body .phone-field-group--khaplu {
    display: flex !important;
    flex: 1;
    width: 100%;
    min-width: 0;
    align-items: center;
    padding-left: 40px;
    padding-top: 10px;
    padding-bottom: 5px;
    margin: 0;
    min-height: 36px;
    background: transparent !important;
    border: none !important;
    border-bottom: 1px solid #fff !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    overflow: visible;
    transition: 0.4s linear;
}

.main_khaplu_popup .khaplu_field:focus-within .phone-field-group,
.khaplu_body .khaplu_field:focus-within .phone-field-group {
    border-bottom-color: #d76dff !important;
    box-shadow: inset 2px 2px 2px 0 rgba(255, 255, 255, 0.5), 7px 7px 20px 0 rgba(0, 0, 0, 0.1), 4px 4px 5px 0 rgba(0, 0, 0, 0.1) !important;
}

.main_khaplu_popup .phone-country-code,
.main_khaplu_popup .phone-number-input,
.khaplu_body .phone-field-group .phone-country-code,
.khaplu_body .phone-field-group .phone-number-input,
.phone-field-group--khaplu .phone-country-code,
.phone-field-group--khaplu .phone-number-input {
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    color: #fff !important;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    font-weight: 300;
    letter-spacing: 1px;
    min-height: auto;
    height: auto;
    line-height: 1.4;
}

.main_khaplu_popup .phone-country-code,
.khaplu_body .phone-field-group .phone-country-code,
.phone-field-group--khaplu .phone-country-code {
    flex: 0 0 68px;
    min-width: 68px;
    max-width: 68px;
    padding: 0 10px 0 0;
    margin: 0;
    border-right: 1px solid rgba(255, 255, 255, 0.45) !important;
    color: #fff !important;
    font-weight: 500;
    cursor: pointer;
    -webkit-appearance: menulist;
    appearance: menulist;
}

.main_khaplu_popup .phone-country-code option,
.khaplu_body .phone-country-code option {
    background: #6b2d7a;
    color: #fff;
}

.main_khaplu_popup .phone-number-input,
.khaplu_body .phone-field-group .phone-number-input,
.phone-field-group--khaplu .phone-number-input,
#web-popup .phone-number-input {
    flex: 1 1 auto;
    width: 100%;
    min-width: 100px;
    padding: 0 0 0 10px !important;
}

/* Placeholder – match other khaplu inputs on homepage book form */
.khaplu_body .khaplu_field input.phone-number-input::placeholder,
.khaplu_body .phone-field-group .phone-number-input::placeholder,
.phone-field-group--khaplu .phone-number-input::placeholder,
.main_khaplu_popup .phone-number-input::placeholder,
#web-popup .phone-number-input::placeholder {
    color: #fff !important;
    opacity: 1 !important;
    font-weight: 100 !important;
    letter-spacing: 1px !important;
    -webkit-text-fill-color: #fff !important;
}

.main_khaplu_popup .phone-number-input:focus,
.main_khaplu_popup .phone-country-code:focus,
.khaplu_body .phone-field-group .phone-number-input:focus,
.khaplu_body .phone-field-group .phone-country-code:focus,
#web-popup .phone-number-input:focus {
    outline: none !important;
    background: transparent !important;
    color: #fff !important;
}

.main_khaplu_popup .phone-number-input:-webkit-autofill,
.main_khaplu_popup .phone-number-input:-webkit-autofill:hover,
.main_khaplu_popup .phone-number-input:-webkit-autofill:focus,
.khaplu_body .phone-number-input:-webkit-autofill,
.khaplu_body .phone-number-input:-webkit-autofill:hover,
.khaplu_body .phone-number-input:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0 1000px transparent inset !important;
    box-shadow: 0 0 0 1000px transparent inset !important;
    -webkit-text-fill-color: #fff !important;
    transition: background-color 9999s ease-in-out 0s;
}

/* Override .khaplu_field input rules on phone row */
.khaplu_body .khaplu_field .phone-field-group input,
.khaplu_body .khaplu_field .phone-field-group select,
.main_khaplu_popup .khaplu_field .phone-field-group input,
.main_khaplu_popup .khaplu_field .phone-field-group select {
    border-bottom: none !important;
    width: auto;
}

.khaplu_body .khaplu_field .phone-field-group .phone-number-input,
.main_khaplu_popup .khaplu_field .phone-field-group .phone-number-input {
    padding-left: 10px !important;
}

.khaplu_body .khaplu_field .phone-field-group .phone-country-code,
.main_khaplu_popup .khaplu_field .phone-field-group .phone-country-code {
    padding-left: 0 !important;
}

/* Book embed form (homepage banner) */
.khaplu_body .khaplu_field .phone-field-group {
    width: 100%;
}

/* Discount popup form */
.popup-form .phone-field-group,
.popupInput .phone-field-group {
    width: 100%;
    align-items: center;
    border: 1px solid #a09f9f;
    border-radius: 10px;
    background: #fff;
    min-height: 42px;
    margin: 5px 0;
    overflow: hidden;
}

.popup-form .phone-country-code,
.popup-form .phone-number-input,
.popupInput .phone-country-code,
.popupInput .phone-number-input {
    border: none !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: #333 !important;
    font-family: 'poppinsmedium', 'Poppins', sans-serif;
    font-size: 1rem;
    padding: 10px 8px;
    min-height: 42px;
    height: auto;
    box-shadow: none !important;
}

.popup-form .phone-country-code,
.popupInput .phone-country-code {
    flex: 0 0 76px;
    min-width: 76px;
    max-width: 76px;
    border-right: 1px solid #a09f9f !important;
    color: #ad49d3 !important;
    font-weight: 600;
    padding-left: 10px;
}

/* Generic fallback for other forms (LP, etc.) – NOT khaplu popup */
form .phone-field-group:not(.phone-field-group--khaplu) {
    /* border: 1px solid #ced4da; */
    border: none;
    border-radius: 0.375rem;
    background: #fff;
    overflow: hidden;
    align-items: center;
    min-height: 42px;
}

form .phone-field-group:not(.phone-field-group--khaplu) .phone-country-code {
    border: none;
    /* border-right: 1px solid #ced4da; */
    border-right: 1px solid #d394eb;
    background: transparent;
    color: #333;
    height: 100%;
    min-height: 42px;
}

form .phone-field-group:not(.phone-field-group--khaplu) .phone-number-input.form-control,
form .phone-field-group:not(.phone-field-group--khaplu) .phone-number-input {
    border: none !important;
    border-radius: 0 !important;
    color: #333 !important;
    background: #fff !important;
    min-height: 42px;
}

@media (max-width: 991px) {
    section.sec8-cta-form .phone-country-code,
    section.sec8-cta-form .phone-number-input,
    #footer-form .phone-country-code,
    #footer-form .phone-number-input {
        font-size: 15px;
    }

    section.sec8-cta-form .phone-country-code,
    #footer-form .phone-country-code {
        flex: 0 0 72px;
        min-width: 72px;
        max-width: 72px;
    }
}

@media (max-width: 576px) {
    .phone-country-code {
        min-width: 68px;
        max-width: 76px;
        padding: 0 8px;
        font-size: 0.9rem;
    }

    section.sec2-service-form form.service-cta .phone-field-group {
        height: 52px;
        min-height: 52px;
    }

    section.sec2-service-form form.service-cta .phone-country-code,
    section.sec2-service-form form.service-cta .phone-number-input {
        min-height: 52px;
    }
}
