.c-user-tags{
    background-color: #e8e8e0;
    font-weight: normal;
    line-height: 1.3;
    position: relative;
    min-height: 32px;
}

.c-user-tags::after{
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}
.c-user-tags.m-state_loading::after,
.c-user-tags.m-state_ajax-loading::after{
    background-image: linear-gradient(135deg,rgba(0,0,0,.05) 25%, transparent 25%, transparent 50%, rgba(0,0,0,.05) 50%, rgba(0,0,0,.05) 75%, transparent 75%, transparent);
    background-size: 32px 32px;

    -webkit-animation: state-loading 2s linear infinite;
    animation: state-loading 2s linear infinite;
}

.c-user-tags.m-mode_edit::after{
    bottom: 40px;
}

@-webkit-keyframes state-loading{
    from {
        background-position: 0 0
    }
    to {
        background-position: 32px 0
    }
}
@keyframes state-loading{
    from {
        background-position: 0 0
    }
    to {
        background-position: 32px 0
    }
}

.c-user-tags__content{
    position: relative;
    z-index: 1;
    min-height: 32px;
    padding: 5px 0;
    background-color: #e8e8e0;

    -moz-box-sizing: border-box;
    box-sizing: border-box;
    opacity: 1;
}
.c-user-tags.m-state_loading .c-user-tags__content{
    opacity: 0;
}
.c-user-tags.m-state_ajax-loading .c-user-tags__content{
    background-color: transparent;
}

.c-user-tags.m-has-tags_false .c-user-tags__content{
    display: none;
}


.c-user-tags__element-list{
    display: inline;
    font-size: 0;
}

.c-user-tags__list-element{
    position: relative;
    font-size: 13px;
    display: inline-block;
    line-height: 21px;
    margin-right: 6px;
    padding-right: 7px;
}
.c-user-tags__list-element.m-state_hidden{
    display: none;
}
.c-user-tags__list-element.m-type_disabled{
    opacity: .5;
    cursor: default;
}

.c-user-tags__list-element::after{
    content: "";
    border-right: 1px solid #b3b3af;
    height: 11px;
    position: absolute;
    right: 0;
    top: 50%;
    margin-top: -5px;
}

.c-user-tags__list-element-text{
    display: inline-block;
    margin-top: -1px;
    color: #000;
    line-height: 12px;
    vertical-align: middle;
    border-bottom: 1px solid transparent;
}


/* .c-user-tags */

.c-user-tags.m-mode_edit .c-user-tags__tag:last-child::after{
    display: none;
}

.c-user-tags__tag-link:hover{
    text-decoration: none;
    border-bottom: 1px solid;
}

.c-user-tags__tag[draggable="true"],
.c-user-tags__tag[draggable="true"] .c-user-tags__tag-link{
    cursor: move;
    border-bottom: 1px solid transparent;
}
.c-user-tags__tag-remove-button{
    display: none;
}

.c-user-tags.m-mode_edit .c-user-tags__tag-remove-button{
    display: inline;
}

.c-user-tags__tag-remove-button::after{
    content: "";
    display: inline-block;
    width: 8px;
    height: 8px;
    background: url("data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE3LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPgo8c3ZnIHZlcnNpb249IjEuMSIgaWQ9IkxheWVyXzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IgoJIHZpZXdCb3g9IjAgMCAxNiAxNiIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMTYgMTYiIHhtbDpzcGFjZT0icHJlc2VydmUiPgo8cG9seWdvbiBmaWxsPSIjOUIwMDIzIiBwb2ludHM9IjEzLjMsMCAxNiwyLjcgMTAuNyw4IDE2LDEzLjMgMTMuMywxNiA4LDEwLjcgMi43LDE2IDAsMTMuMyA1LjMsOCAwLDIuNyAyLjcsMCA4LDUuMyAiLz4KPC9zdmc+") center no-repeat;
    background-size: 100%;

    -webkit-transition: all 200ms ease-in-out;
    transition: all 200ms ease-in-out;
}
.c-user-tags__tag-remove-button:hover::after{
    -webkit-transform: scale(1.25);
    transform: scale(1.25);
}

.c-user-tags__tag.m-type_placeholder{
    opacity: .2;
}

.c-user-tags__tag.m-type_handler{
    position: absolute;
    left: 0;
    border: none;
    z-index: -1;
    font-weight: normal;
    background: #c8c8c0;
    padding: 0 6px;
    border-radius: 3px;
}
.c-user-tags__tag.m-type_handler .c-user-tags__tag-remove-button{
    display: none;
}


/* .c-user-tags__controls */

.c-user-tags__controls{
    white-space: nowrap;
}
.c-user-tags__control:last-child::after{
    display: none;
}
.c-user-tags__control .c-user-tags__list-element-text{
    cursor: pointer;
    color: #8B8B8B;
}
.c-user-tags__control .c-user-tags__list-element-text:hover{
    border-bottom: 1px dotted;
}
.c-user-tags__control.m-type_disabled{
    display: none;
}


.c-user-tags__edit-panel{
    position: relative;
    margin-top: -40px;
    opacity: 0;

    clear: both;
    min-height: 40px;
    background-color: #dbdbd4;
    padding: 9px 0;

    -webkit-transition: margin 300ms ease-in-out, opacity 200ms ease-in-out;
    transition: margin 300ms ease-in-out, opacity 200ms ease-in-out;

    -moz-box-sizing: border-box;
    box-sizing: border-box;
}
.c-user-tags.m-mode_edit .c-user-tags__edit-panel{
    margin-top: 0;
    opacity: 1;

    -webkit-transition: margin 300ms ease-in-out, opacity 400ms ease-in-out;
    transition: margin 300ms ease-in-out, opacity 400ms ease-in-out;
}

.c-user-tags.m-has-tags_false .c-user-tags__edit-panel{
    -webkit-transition-duration: 0ms;
    transition-duration: 0ms;
}

.c-user-tags__save-button{
    float: right;
    padding-left: 10px;
    padding-right: 10px;

    visibility: visible;
    opacity: 1;

    -webkit-transition-delay: 0ms;
    transition-delay: 0ms;
}
.c-user-tags__save-button.m-state_disabled{
    visibility: hidden;
    opacity: 0;

    -webkit-transition: visibility 0ms linear 100ms, opacity 100ms linear;
    transition: visibility 0ms linear 100ms, opacity 100ms linear;
}

.c-user-tags .c-auto-complete{
    margin-left: 5px;
    margin-right: 5px;
}

.c-user-tags__recommendations{
    position: relative;
    display: inline-block;
    width: 470px;
    white-space: nowrap;
    overflow: hidden;
    vertical-align: middle;

    visibility: hidden;
    opacity: 0;

    -webkit-transition: visibility 0ms linear 100ms, opacity 100ms linear;
    transition: visibility 0ms linear 100ms, opacity 100ms linear;
}
.c-user-tags__recommendations.m-state_shown{
    visibility: visible;
    opacity: 1;

    -webkit-transition-delay: 0ms;
    transition-delay: 0ms;
}

.c-user-tags__recommendations::after{
    content: "";
    display: block;
    position: absolute;
    z-index: 1;
    width: 20px;
    top: 0;
    right: 0;
    bottom: 0;
    background: -webkit-linear-gradient(to right, rgba(219,219,212,0) 0%, rgba(219,219,212,1) 60%);
    background: linear-gradient(to right, rgba(219,219,212,0) 0%, rgba(219,219,212,1) 60%);
}

.c-user-tags__recommendations-list{
    white-space: nowrap;
}
.c-user-tags__recommendations-list-item:last-child::after{
    display: none;
}
.c-user-tags__recommendations-list .c-user-tags__list-element-text{
    text-decoration: none;
    border-bottom: 1px dotted;
}
