/*
 * Shoppy Product Search
 *
 * Scoped and reinforced to override Hello Elementor / Elementor styles.
 */

.elementor-widget-shoppy-product-search .shoppy-product-search {
    --shoppy-search-input-height: 48px;
    --shoppy-search-button-width: 40px;
    --shoppy-search-button-height: 38px;
    --shoppy-search-icon-size: 18px;
    --shoppy-search-border-color: #dfe3e8;
    --shoppy-search-border-width: 1px;
    --shoppy-search-radius: 50px;

    --shoppy-mobile-trigger-size: 40px;
    --shoppy-mobile-trigger-icon-size: 20px;

    position: relative;

    width: 100%;

    z-index: 100;
}


/* =========================
   FORM
   ========================= */

.elementor-widget-shoppy-product-search
.shoppy-product-search__form {
    width: 100% !important;

    margin: 0 !important;
    padding: 0 !important;

    border: 0 !important;

    background: transparent !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__field {
    position: relative;

    width: 100%;
}


/* =========================
   INPUT
   ========================= */

.elementor-widget-shoppy-product-search
.shoppy-product-search__field
input.shoppy-product-search__input[type="search"] {
    width: 100% !important;

    height: var(--shoppy-search-input-height) !important;
    min-height: 0 !important;

    margin: 0 !important;

    padding-top: 0 !important;
    padding-right: calc(var(--shoppy-search-button-width) + 18px) !important;
    padding-bottom: 0 !important;
    padding-left: 18px !important;

    border-style: solid !important;
    border-width: var(--shoppy-search-border-width) !important;
    border-color: var(--shoppy-search-border-color) !important;

    border-radius: var(--shoppy-search-radius) !important;

    background-color: #fff;

    color: #111;

    font-family: "Manrope", sans-serif;
    font-size: 14px;
    font-weight: 500;

    line-height: normal !important;

    outline: 0 !important;
    outline-offset: 0 !important;

    box-shadow: none !important;

    appearance: none !important;
    -webkit-appearance: none !important;

    transition: none !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__field
input.shoppy-product-search__input[type="search"]:hover,

.elementor-widget-shoppy-product-search
.shoppy-product-search__field
input.shoppy-product-search__input[type="search"]:focus,

.elementor-widget-shoppy-product-search
.shoppy-product-search__field
input.shoppy-product-search__input[type="search"]:focus-visible,

.elementor-widget-shoppy-product-search
.shoppy-product-search__field
input.shoppy-product-search__input[type="search"]:active {
    border-style: solid !important;
    border-width: var(--shoppy-search-border-width) !important;
    border-color: var(--shoppy-search-border-color) !important;

    outline: 0 !important;
    outline-offset: 0 !important;

    box-shadow: none !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__input::-webkit-search-decoration,

.elementor-widget-shoppy-product-search
.shoppy-product-search__input::-webkit-search-cancel-button,

.elementor-widget-shoppy-product-search
.shoppy-product-search__input::-webkit-search-results-button,

.elementor-widget-shoppy-product-search
.shoppy-product-search__input::-webkit-search-results-decoration {
    display: none !important;

    -webkit-appearance: none !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__input::placeholder {
    color: #8f96a0;

    opacity: 1 !important;
}


/* =========================
   SEARCH BUTTON
   ========================= */

.elementor-widget-shoppy-product-search
.shoppy-product-search__field
button.shoppy-product-search__submit {
    position: absolute !important;

    top: 50% !important;
    right: 5px !important;
    left: auto !important;

    width: var(--shoppy-search-button-width) !important;
    min-width: var(--shoppy-search-button-width) !important;

    height: var(--shoppy-search-button-height) !important;
    min-height: var(--shoppy-search-button-height) !important;

    margin: 0 !important;
    padding: 0 10px !important;

    display: inline-flex !important;

    flex-direction: row !important;

    align-items: center !important;
    justify-content: center !important;

    gap: 7px;

    transform: translateY(-50%) !important;

    border: 0 !important;

    background-color: #fff;

    color: #111;

    line-height: 1 !important;

    cursor: pointer !important;

    outline: 0 !important;

    box-shadow: none !important;

    appearance: none !important;
    -webkit-appearance: none !important;

    z-index: 3;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__field
button.shoppy-product-search__submit:hover,

.elementor-widget-shoppy-product-search
.shoppy-product-search__field
button.shoppy-product-search__submit:focus,

.elementor-widget-shoppy-product-search
.shoppy-product-search__field
button.shoppy-product-search__submit:focus-visible,

.elementor-widget-shoppy-product-search
.shoppy-product-search__field
button.shoppy-product-search__submit:active {
    border: 0 !important;

    outline: 0 !important;

    box-shadow: none !important;
}


/* =========================
   ICONS
   ========================= */

.elementor-widget-shoppy-product-search
.shoppy-product-search__button-icon {
    width: var(--shoppy-search-icon-size) !important;
    height: var(--shoppy-search-icon-size) !important;

    min-width: var(--shoppy-search-icon-size) !important;

    display: inline-flex !important;

    align-items: center !important;
    justify-content: center !important;

    color: currentColor !important;

    line-height: 1 !important;

    pointer-events: none;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__button-icon i {
    display: inline-block !important;

    color: currentColor !important;

    font-size: var(--shoppy-search-icon-size) !important;

    line-height: 1 !important;

    opacity: 1 !important;
    visibility: visible !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__button-icon svg {
    width: var(--shoppy-search-icon-size) !important;
    height: var(--shoppy-search-icon-size) !important;

    display: block !important;

    color: currentColor !important;

    fill: currentColor !important;

    opacity: 1 !important;
    visibility: visible !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__button-icon svg path {
    fill: currentColor !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__button-text {
    display: inline-block !important;

    margin: 0 !important;
    padding: 0 !important;

    color: currentColor !important;

    font-size: 14px;
    font-weight: 600;

    line-height: 1 !important;

    white-space: nowrap;
}


/* =========================
   LOADER
   ========================= */

.elementor-widget-shoppy-product-search
.shoppy-product-search__loader {
    position: absolute;

    top: 50%;
    right: calc(var(--shoppy-search-button-width) + 12px);

    width: 16px;
    height: 16px;

    margin-top: -8px;

    border: 2px solid #dfe3e8;
    border-top-color: #111;

    border-radius: 50%;

    opacity: 0;
    visibility: hidden;

    pointer-events: none;

    z-index: 2;

    animation: shoppy-product-search-spin 0.65s linear infinite;
}


.elementor-widget-shoppy-product-search
.is-loading
.shoppy-product-search__loader {
    opacity: 1;

    visibility: visible;
}


@keyframes shoppy-product-search-spin {
    to {
        transform: rotate(360deg);
    }
}


/* =========================
   DROPDOWN
   ========================= */

.elementor-widget-shoppy-product-search
.shoppy-product-search__dropdown {
    position: absolute;

    top: calc(100% + 8px);
    left: 0;
    right: 0;

    overflow: hidden;

    background: #fff;

    border: 1px solid #e4e8ec;

    border-radius: 14px;

    box-shadow:
        0 18px 45px rgba(0, 0, 0, 0.10),
        0 4px 14px rgba(0, 0, 0, 0.04);

    z-index: 9999;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__dropdown[hidden] {
    display: none !important;
}


/* =========================
   RESULTS
   ========================= */

.elementor-widget-shoppy-product-search
.shoppy-product-search__items {
    max-height: 470px;

    overflow-y: auto;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__item {
    display: grid !important;

    grid-template-columns: 64px minmax(0, 1fr);

    gap: 13px;

    padding: 12px 14px !important;

    color: inherit !important;

    text-decoration: none !important;

    border: 0 !important;
    border-bottom: 1px solid #f0f2f4 !important;

    background: #fff;

    box-shadow: none !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__item:last-child {
    border-bottom: 0 !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__item:hover,

.elementor-widget-shoppy-product-search
.shoppy-product-search__item:focus,

.elementor-widget-shoppy-product-search
.shoppy-product-search__item.is-active {
    background: #f7f9fb !important;

    color: inherit !important;

    text-decoration: none !important;

    outline: 0 !important;

    box-shadow: none !important;
}


/* PRODUCT IMAGE */

.elementor-widget-shoppy-product-search
.shoppy-product-search__image {
    width: 64px;
    height: 64px;

    overflow: hidden;

    display: flex;

    align-items: center;
    justify-content: center;

    background: #f7f7f7;

    border-radius: 9px;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__image img {
    width: 100% !important;
    height: 100% !important;

    display: block !important;

    margin: 0 !important;

    object-fit: contain;
}


/* PRODUCT CONTENT */

.elementor-widget-shoppy-product-search
.shoppy-product-search__content {
    min-width: 0;

    display: flex;

    flex-direction: column;

    justify-content: center;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__brand {
    margin: 0 0 3px !important;

    color: #9097a0;

    font-family: "Manrope", sans-serif;

    font-size: 10px;
    font-weight: 700;

    line-height: 1.2;

    letter-spacing: 0.08em;

    text-transform: uppercase;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__name {
    margin: 0 !important;

    color: #171717;

    font-family: "Manrope", sans-serif;

    font-size: 13px;
    font-weight: 600;

    line-height: 1.35;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__price {
    margin: 5px 0 0 !important;

    color: #111;

    font-family: "Manrope", sans-serif;

    font-size: 13px;
    font-weight: 700;

    line-height: 1.2;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__price del {
    margin-right: 4px;

    color: #a1a7af;

    font-weight: 500;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__price ins {
    text-decoration: none !important;
}


/* =========================
   VIEW ALL
   ========================= */

.elementor-widget-shoppy-product-search
.shoppy-product-search__all {
    display: block !important;

    padding: 13px 16px !important;

    border: 0 !important;
    border-top: 1px solid #edf0f2 !important;

    background: #f7f9fb !important;

    color: #111 !important;

    font-family: "Manrope", sans-serif;

    font-size: 12px;
    font-weight: 700;

    line-height: 1.3;

    text-align: center;

    text-decoration: none !important;

    box-shadow: none !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__all:hover,

.elementor-widget-shoppy-product-search
.shoppy-product-search__all:focus {
    background: #eef3f7 !important;

    color: #111 !important;

    text-decoration: none !important;
}


/* =========================
   EMPTY
   ========================= */

.elementor-widget-shoppy-product-search
.shoppy-product-search__empty {
    padding: 20px;

    color: #686f78;

    font-family: "Manrope", sans-serif;

    font-size: 13px;

    line-height: 1.4;

    text-align: center;
}


/* =========================
   MOBILE TRIGGER
   ========================= */

.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-trigger {
    display: none !important;

    width: var(--shoppy-mobile-trigger-size) !important;
    min-width: var(--shoppy-mobile-trigger-size) !important;

    height: var(--shoppy-mobile-trigger-size) !important;
    min-height: var(--shoppy-mobile-trigger-size) !important;

    margin: 0 !important;
    padding: 0 !important;

    align-items: center !important;
    justify-content: center !important;

    border: 0 !important;

    border-radius: 50% !important;

    background: transparent;

    color: #111;

    outline: none !important;

    box-shadow: none !important;

    cursor: pointer !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-trigger-icon {
    width: var(--shoppy-mobile-trigger-icon-size);

    height: var(--shoppy-mobile-trigger-icon-size);

    display: inline-flex;

    align-items: center;
    justify-content: center;

    color: currentColor;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-trigger i {
    font-size: var(--shoppy-mobile-trigger-icon-size) !important;

    color: currentColor !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-trigger svg {
    width: var(--shoppy-mobile-trigger-icon-size) !important;

    height: var(--shoppy-mobile-trigger-icon-size) !important;

    display: block !important;

    color: currentColor !important;

    fill: currentColor !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-trigger svg path {
    fill: currentColor !important;
}


/* =========================
   MOBILE OVERLAY
   ========================= */

.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-overlay {
    position: fixed !important;

    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    left: 0 !important;

    display: none;

    z-index: 999999 !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-overlay.is-open {
    display: block !important;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-backdrop {
    position: absolute;

    inset: 0;

    background: rgba(0, 0, 0, 0.32);
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-panel {
    position: relative;

    width: 100%;

    max-height: 90vh;

    overflow-y: auto;

    padding: 18px 16px 22px;

    background: #fff;

    border-radius: 0 0 18px 18px;

    box-shadow:
        0 18px 60px rgba(0, 0, 0, 0.20);

    z-index: 2;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-header {
    display: flex;

    align-items: center;
    justify-content: space-between;

    gap: 20px;

    margin-bottom: 16px;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-title {
    color: #111;

    font-family: "Manrope", sans-serif;

    font-size: 18px;
    font-weight: 700;

    line-height: 1.2;
}


.elementor-widget-shoppy-product-search
button.shoppy-product-search__mobile-close {
    width: 38px !important;
    min-width: 38px !important;

    height: 38px !important;
    min-height: 38px !important;

    margin: 0 !important;
    padding: 0 !important;

    display: inline-flex !important;

    align-items: center !important;
    justify-content: center !important;

    border: 0 !important;

    border-radius: 50% !important;

    background: #f4f5f6 !important;

    color: #111 !important;

    outline: 0 !important;

    box-shadow: none !important;

    cursor: pointer;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-close svg {
    width: 18px !important;

    height: 18px !important;

    display: block;

    fill: currentColor;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-search {
    position: relative;
}


.elementor-widget-shoppy-product-search
.shoppy-product-search__mobile-search
.shoppy-product-search__dropdown {
    position: static !important;

    width: 100%;

    margin-top: 10px;

    border-radius: 12px;

    box-shadow: none;
}


body.shoppy-product-search-open {
    overflow: hidden !important;
}


/* =========================
   MOBILE
   ========================= */

@media (max-width: 767px) {

    /*
     * Popup mode:
     * hide the normal search field and show only the trigger.
     */
    .elementor-widget-shoppy-product-search
    .shoppy-product-search--mobile-popup
    .shoppy-product-search__desktop {
        display: none !important;
    }


    .elementor-widget-shoppy-product-search
    .shoppy-product-search--mobile-popup
    .shoppy-product-search__mobile-trigger {
        display: inline-flex !important;
    }


    /*
     * Inline mode:
     * retain normal search bar.
     */
    .elementor-widget-shoppy-product-search
    .shoppy-product-search--mobile-inline
    .shoppy-product-search__desktop {
        display: block !important;
    }


    .elementor-widget-shoppy-product-search
    .shoppy-product-search {
        --shoppy-search-input-height: 46px;
    }


    .elementor-widget-shoppy-product-search
    .shoppy-product-search__field
    input.shoppy-product-search__input[type="search"] {
        padding-left: 16px !important;

        font-size: 13px;
    }


    .elementor-widget-shoppy-product-search
    .shoppy-product-search__items {
        max-height: 55vh;
    }


    .elementor-widget-shoppy-product-search
    .shoppy-product-search__item {
        grid-template-columns: 56px minmax(0, 1fr);

        gap: 11px;

        padding: 10px 12px !important;
    }


    .elementor-widget-shoppy-product-search
    .shoppy-product-search__image {
        width: 56px;
        height: 56px;
    }


    .elementor-widget-shoppy-product-search
    .shoppy-product-search__name {
        font-size: 12px;
    }


    .elementor-widget-shoppy-product-search
    .shoppy-product-search__price {
        font-size: 12px;
    }
}


/* =========================
   DESKTOP / TABLET
   ========================= */

@media (min-width: 768px) {

    .elementor-widget-shoppy-product-search
    .shoppy-product-search__mobile-trigger,

    .elementor-widget-shoppy-product-search
    .shoppy-product-search__mobile-overlay {
        display: none !important;
    }

}