@import "./var.scss";


$font-size:14Px;
$bar-height:30Px;
$button-min-width:60Px;
$sp-width:10Px;

.miao-search-bar {
    display: flex;
    align-items: center;
    overflow: hidden;
    box-sizing: border-box;

    &__input-cnt {
        position: relative;
        flex: 1;
        width: 100%;
        height: $bar-height;
        overflow: hidden;
        display: flex;
    }

    &__placeholder-wrap {

        display: flex;
        align-self: center;
        align-items: center;
        justify-content: center;
        height: $bar-height;
        line-height: 0;
        vertical-align: middle;
        opacity: 1;
        transition: flex 0.3s;


        .at-icon {
            flex-shrink: 0;
        }
    }



    &__input {
        position: absolute;
        display: block;
        top: 0;
        left: 0;
        width: 100%;
        height: $bar-height !important;
        padding: 0 $sp-width;
        color: $grey;
        font-size: $font-size !important;
        text-align: left;
        transition: width 0.3s;
        box-sizing: border-box;
    }

    &__clear {
        position: absolute;
        display: flex;
        align-items: center;
        justify-content: center;
        top: 0;
        right: $sp-width;
        font-size: $font-size;
        height: $bar-height;
        line-height: 1;
        vertical-align: middle;
    }

    &__icon {
        flex: none;
        display: block;
        margin-right: $sp-width;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    &__action {
        flex: none;
        display: block;
        margin-left: $sp-width;
        font-size: $font-size;
        line-height: $bar-height;
        min-width: $button-min-width;
        text-align: center;
        transition: margin-right 0.3s, opacity 0.3s;
        opacity: 0;
    }

    /* modifiers */
    &--fixed {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 99;
    }
}


.miao-search-history {
    transition: opacity 0.9s, ;
    position: absolute;
    left: 0;
    right: 0;
    z-index: 9;
    padding: 15Px;


    .clear-view {
        width: 100%;
        text-align: center;
    }


}