/* =========================================================
   CONTACT FORM
========================================================= */

.contact-form {
    width: 100%;
    max-width: 472px;
    margin: 0 auto;
    font-family: Arial, sans-serif;
    box-sizing: border-box;
}


/* =========================================================
   FORM GROUP
========================================================= */

.form-group {
    width: 100%;
    margin-bottom: 5px;
    box-sizing: border-box;
}

.form-group label {
    display: block;
    margin-bottom: 5px;

    font-size: 14px;
    font-weight: 500;
    color: #292929;
}


/* =========================================================
   REQUIRED *
========================================================= */

.required {
    color: #e53935;
    font-size: 13px;
    font-weight: 600;
    margin-left: 2px;
}


/* =========================================================
   NORMAL INPUTS
========================================================= */

.form-group > input:not([type="hidden"]) {
    display: block;

    width: 100%;
    height: 24px;

    padding: 0 1px;

    border: none;
    border-bottom: 1px solid #e5e5e5;

    outline: none;

    background: transparent;

    font-family: Arial, sans-serif;
    font-size: 13px;
    color: #333;

    box-sizing: border-box;
}

.form-group > input:not([type="hidden"])::placeholder {
    color: #b8b8b8;
    opacity: 1;
}

.form-group > input:not([type="hidden"]):focus {
    border-bottom-color: #2997f5;
}


/* =========================================================
   PHONE GROUP
========================================================= */

.phone-group {
    width: 100%;
    box-sizing: border-box;
}


/* =========================================================
   INTL TEL INPUT WRAPPER
========================================================= */

.phone-group .iti {
    display: block;
    position: relative;

    width: 100%;

    box-sizing: border-box;

    overflow: visible;
}


/* =========================================================
   PHONE NUMBER INPUT
========================================================= */

.phone-group .iti input[type="tel"] {
    display: block;

    width: 100% !important;
    height: 36px !important;

    /*
     * Space for:
     *
     * flag
     * arrow
     * country dial code
     *
     * Phone number starts after them.
     */
    padding: 0 5px 0 100px !important;

    border: none !important;
    border-bottom: 1px solid #e5e5e5 !important;

    outline: none !important;

    background: transparent !important;

    font-family: Arial, sans-serif !important;
    font-size: 13px !important;
    font-weight: 400 !important;

    color: #333 !important;

    box-sizing: border-box !important;
}

.phone-group .iti input[type="tel"]::placeholder {
    color: #999;
    opacity: 1;
}


/* =========================================================
   SELECTED COUNTRY
========================================================= */

.phone-group .iti__selected-country {
    height: 40px !important;

    padding: 0 5px 0 5px !important;

    border: 0 !important;

    background-color: transparent !important;

    box-sizing: border-box;

    cursor: pointer;

    z-index: 5 !important;
}

.phone-group .iti__selected-country:hover {
    background-color: transparent !important;
}


/* =========================================================
   COUNTRY PRIMARY CONTAINER
========================================================= */

.phone-group .iti__selected-country-primary {
    background-color: transparent !important;
    border: 0 !important;
}


/* =========================================================
   FLAG
========================================================= */

/*
 * IMPORTANT:
 *
 * Do NOT set:
 *
 * background
 * background-image
 * background-size
 * background-position
 *
 * on .iti__flag.
 *
 * intlTelInput uses its own flag sprite.
 */

.phone-group .iti__selected-country .iti__flag {
    flex-shrink: 0 !important;

    opacity: 1 !important;
    visibility: visible !important;
}


/* =========================================================
   COUNTRY DIAL CODE
========================================================= */

.phone-group .iti__selected-dial-code {
    margin-left: 1px;

    font-family: Arial, sans-serif;
    font-size: 13px;
    font-weight: 400;

    color: #555;

    white-space: nowrap;
}


/* =========================================================
   COUNTRY ARROW
========================================================= */

.phone-group .iti__arrow {
    margin-left: 2px;
}


/* =========================================================
   PHONE FOCUS
========================================================= */

.phone-group .iti:focus-within input[type="tel"] {
    border-bottom-color: #2997f5 !important;
    border-bottom-width: 1px !important;
}


/* =========================================================
   COUNTRY DROPDOWN
========================================================= */

.phone-group .iti__country-list {
    width: 100%;
    max-width: 360px;

    max-height: 260px;

    margin-top: 6px;
    padding: 4px 0;

    background: #ffffff;

    border: 1px solid #dedede;
    border-radius: 6px;

    box-shadow: 0 5px 18px rgba(0, 0, 0, 0.12);

    overflow-y: auto;

    z-index: 99999 !important;

    box-sizing: border-box;
}


/* =========================================================
   COUNTRY SEARCH
========================================================= */

.phone-group .iti__search-input {
    display: block;

    width: calc(100% - 20px) !important;
    height: 30px !important;

    margin: 0px !important;
    padding: 0 12px !important;

    border: 1px solid #d8d8d8 !important;
    border-radius: 5px !important;

    outline: none !important;

    background: #ffffff !important;

    font-family: Arial, sans-serif !important;
    font-size: 14px !important;

    color: #333 !important;

    box-sizing: border-box !important;
}

.phone-group .iti__search-input::placeholder {
    color: #999;
    opacity: 1;
}

.phone-group .iti__search-input:focus {
    border-color: #2997f5 !important;

    box-shadow:
        0 0 0 2px rgba(41, 151, 245, 0.08);
}


/* =========================================================
   COUNTRY LIST
========================================================= */

.phone-group .iti__country {
    min-height: 32px;

    padding: 8px 12px;

    display: flex;
    align-items: center;

    font-family: Arial, sans-serif;
    font-size: 14px;

    box-sizing: border-box;

    cursor: pointer;
}

.phone-group .iti__country:hover {
    background: #f5f8fc;
}

.phone-group .iti__country--highlight {
    background: #f5f8fc;
}

.phone-group .iti__country-name {
    margin-left: 1px;

    color: #333;

    white-space: nowrap;
}

.phone-group .iti__dial-code {
    margin-left: 1px;

    color: #888;

    white-space: nowrap;
}


/* =========================================================
   HIDDEN PHONE FIELDS
========================================================= */

.phone-group input[type="hidden"] {
    display: none !important;
}


/* =========================================================
   SUBMIT BUTTON
========================================================= */

.submit-wrapper {
    display: flex;
    justify-content: flex-end;

    margin-top: 5px;
}

.submit-btn {
    display: inline-flex;

    align-items: center;
    justify-content: center;

    gap: 8px;

    width: 138px;
    height: 31px;

    padding: 0;

    border: none;
    border-radius: 7px;

    background: #2997f5;
    color: #fff;

    font-family: Arial, sans-serif;
    font-size: 13px;
    font-weight: 600;

    line-height: 1;

    cursor: pointer;

    transition: background 0.2s ease;
}

.submit-btn:hover {
    background: #1685e5;
}

.submit-btn .arrow {
    display: inline-flex;

    align-items: center;

    margin: 0;

    font-size: 18px;
    font-weight: 400;

    line-height: 1;
}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 480px) {

    .contact-form {
        width: 100%;
        max-width: 100%;

        padding: 0 10px;

        margin: 0 auto;

        box-sizing: border-box;
    }


    .form-group {
        width: 100%;
        margin-bottom: 20px;
    }


    .form-group label {
        margin-bottom: 1px;
        font-size: 14px;
    }


    .form-group > input:not([type="hidden"]) {
        width: 100%;
        height: 18px;

        padding: 0 5px;

        font-size: 13px;
    }


    /* Phone */

    .phone-group .iti {
        width: 100%;
    }


    .phone-group .iti input[type="tel"] {
        width: 100% !important;
        height: 40px !important;

        /*
         * Keep cursor and phone number
         * after flag + dial code.
         */
        padding-left: 100px !important;
        padding-right: 5px !important;

        font-size: 14px !important;
    }


    .phone-group .iti__selected-country {
        height: 40px !important;

        padding: 0 5px 0 5px !important;

        background-color: transparent !important;
    }


    .phone-group .iti__selected-dial-code {
        font-size: 13px;
    }


    /*
     * Leave intlTelInput flag sprite untouched.
     */
    .phone-group .iti__selected-country .iti__flag {
        opacity: 1 !important;
        visibility: visible !important;

        flex-shrink: 0 !important;
    }


    /* Country dropdown */

    .phone-group .iti__country-list {
        width: 100%;
        max-width: 100%;

        max-height: 250px;

        margin-top: 5px;
    }


    /* Search */

    .phone-group .iti__search-input {
        width: calc(100% - 20px) !important;

        height: 20px !important;

        margin: 1px !important;

        font-size: 14px !important;
    }


    /* Countries */

    .phone-group .iti__country {
        min-height: 24px;

        padding: 9px 12px;

        font-size: 14px;
    }


    .phone-group .iti__country-name {
        margin-left: 5px;
    }


    .phone-group .iti__dial-code {
        margin-left: 5px;
    }


    /* Submit */

    .submit-wrapper {
        width: 100%;

        justify-content: flex-end;

        margin-top: 2px;
    }

    .submit-btn {
        width: 138px;
        height: 31px;
    }
}

/*
#arabyads-form-message.success {
    color: #198754;
    margin-top: 15px;
}

#arabyads-form-message.error {
    color: #dc3545;
    margin-top: 15px;
}
*/

#arabyads-contact-form #arabyads-form-message {
    display: none !important;
    width: 100%;
    margin-top: 18px;
    padding: 13px 16px;
    border-radius: 6px;
    font-size: 14px;
    line-height: 1.5;
    font-weight: 500;
    box-sizing: border-box;
}

/* Success */
#arabyads-contact-form #arabyads-form-message.success {
    display: block !important;
    color: #176b3a;
    background-color: #eef9f2;
    border: 1px solid #b7e4c7;
}

/* Error */
#arabyads-contact-form #arabyads-form-message.error {
    display: block !important;
    color: #a61b1b;
    background-color: #fff1f1;
    border: 1px solid #f0b8b8;
}

