// /**
//  * Copyright Â© Magento, Inc. All rights reserved.
//  * See COPYING.txt for license details.
//  */

.link-copyright {
    display: none;
}

.mage-suggest {
    text-align: left;
    box-sizing: border-box;
    position: relative;
    display: inline-block;
    vertical-align: top;
    width: 100%;
    background-color: @color-white;
    border: 1px solid #ada89e;
    border-radius: 2px;

    &:after {
        position: absolute;
        top: 3px;
        right: 3px;
        bottom: 0;
        width: 22px;
        text-align: center;
        font-family: 'MUI-Icons';
        font-style: normal;
        speak: none;
        font-weight: normal;
        -webkit-font-smoothing: antialiased;
        content: '\e01f'; // search icon
        font-size: 18px;
        color: #b2b2b2;
    }

    input[type="search"],
    input.search {
        width: 100%;
        border: none;
        background: none;
        padding-right: 30px;
    }

    &.category-select {
        input[type="search"],
        input.search {
            height: 26px;
        }
    }
}

.search-global-field .mage-suggest {
    position: static;
    display: block;
    width: auto;
    background-color: transparent;
    border: none;
    border-radius: 0;

    &:after {
        display: none;
    }
}

.mage-suggest-dropdown {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    margin: 1px -1px 0 -1px;
    border: 1px solid #cac2b5;
    background: @color-white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, .2);
    z-index: 990;

    ul {
        margin: 0;
        padding: 0;
        list-style: none;
    }

    li {
        border-bottom: 1px solid #e5e5e5;
        padding: 0;

        a {
            display: block;

            &.ui-state-focus {
                background: #f5f5f5;
            }
        }
    }

    li a,
    .jstree li a:hover,
    .jstree .jstree-hovered,
    .jstree .jstree-clicked {
        padding: 6px 12px 5px;
        text-decoration: none;
        color: #333;
        height: inherit !important;
    }

    .jstree {
        li a:hover,
        .jstree-hovered,
        .jstree-clicked {
            border: none;
        }

        li {
            border-bottom: 0;

            a {
                display: inline-block;
            }
        }

        .mage-suggest-selected > a {
            color: @color-black;
            background: #F1FFEB;
        }
    }
}

.field-category_ids .mage-suggest-dropdown,
.field-new_category_parent .mage-suggest-dropdown {
    max-height: 200px;
    overflow: auto;
}

.mage-suggest-dropdown .jstree .mage-suggest-selected > a:hover,
.mage-suggest-dropdown .jstree .mage-suggest-selected > .jstree-hovered,
.mage-suggest-dropdown .jstree .mage-suggest-selected > .jstree-clicked,
.mage-suggest-dropdown .jstree .mage-suggest-selected.mage-suggest-not-active > .jstree-hovered,
.mage-suggest-dropdown .jstree .mage-suggest-selected.mage-suggest-not-active > .jstree-clicked {
    background: #E5FFD9;
}

.mage-suggest-dropdown .jstree .mage-suggest-not-active > a {
    color: #D4D4D4;
}

.mage-suggest-dropdown .jstree .mage-suggest-not-active > a:hover,
.mage-suggest-dropdown .jstree .mage-suggest-not-active > .jstree-hovered,
.mage-suggest-dropdown .jstree .mage-suggest-not-active > .jstree-clicked {
    background: #F5F5F5;
}

.mage-suggest-dropdown .category-path {
    font-size: 11px;
    margin-left: 10px;
    color: #9ba8b5;
}

.suggest-expandable {
    .action-dropdown .action-toggle {
        display: inline-block;
        max-width: 500px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        background: none;
        border: none;
        box-shadow: none;
        color: #676056;
        font-size: 12px;
        padding: 5px 4px;
        filter: none;

        span {
            display: inline;
        }

        &:before {
            display: block;
            float: right;
            margin-left: 4px;
            font-size: 13px;
            color: #b2b0ad;
        }

        &:hover:before {
            color: #7e7e7e;
        }
    }

    .dropdown-menu {
        margin: 1px 0 0;
        left: 0;
        right: auto;
        width: 245px;
        z-index: 4;
    }

    .mage-suggest {
        border: none;
        border-radius: 3px 3px 0 0;

        &:after {
            top: 10px;
            right: 8px;
        }
    }

    .mage-suggest-inner {
        .title {
            margin: 0;
            padding: 0 10px 4px;
            text-transform: uppercase;
            color: #a6a098;
            font-size: 12px;
            border-bottom: 1px solid #e5e5e5;
        }

        > input[type="search"],
        > input.search {
            position: relative;
            margin: 6px 5px 5px;
            padding-right: 20px;
            border: 1px solid #ada89e;
            width: 236px;
            z-index: 1;
        }

        > input.ui-autocomplete-loading,
        > input.mage-suggest-state-loading {
            background: @color-white url("@{baseDir}mui/images/ajax-loader-small.gif") no-repeat 190px 50%;
        }
    }

    .mage-suggest-dropdown {
        margin-top: 0;
        border-top: 0;
        border-radius: 0 0 3px 3px;
        max-height: 300px;
        overflow: auto;
        width: 100%;
        float: left;

        ul {
            margin: 0;
            padding: 0;
            list-style: none;
        }
    }
}

.suggest-expandable .action-show-all {
    &:hover,
    &:active,
    &:focus,
    &[disabled] {
        border-top: 1px solid #e5e5e5;
        display: block;
        width: 100%;
        padding: 8px 10px 10px;
        text-align: left;
        font: 12px/1.333 Arial, Verdana, sans-serif;
        color: #676056;
    }
}

.product-actions .suggest-expandable {
    max-width: 500px;
    float: left;
    margin-top: 1px;
}

.page-actions.fixed #product-template-suggest-container {
    display: none;
}
