@import "~@/asset/style/var";

.rg-header,
.rg-search {
    padding: 2px 10px 0;
    background-color: $--color-white;
}

.rg-header {
    h3 {
        padding: 6px;
        margin: 0;
        color: $--color-text-primary;
        font-size: 16px;
    }

    button {
        position: absolute;
        -webkit-appearance: none;
        padding: 0;
        cursor: pointer;
        background: 0 0;
        border: 0;
        outline: none;
        color: $--color-text-secondary;
        top: 9px;

        i {
            font-size: 16px;
        }

        &:hover {
            color: $--color-text-regular;
        }

        &.rg-removeall-button {
            right: 32px
        }

        &.rg-done-button {
            right: 8px;
        }
    }
}

.rg-level-tabs {
    margin-top: 10px;

    ul {
        padding: 0;
        margin: 0;
        line-height: 1.5;
        border-bottom: $--border-base;

        li {
            display: inline-block;
            position: relative;

            a {
                display: block;
                padding: 0.2rem 1rem 0.6rem;
                font-size: 14px;
                color: $--color-text-secondary;
                text-decoration: none;
                cursor: pointer;
                line-height: 1.43;
            }

            &.active {
                a {
                    color: $--color-text-primary;
                    font-weight: 600;
                }

                &::after {
                    content: "";
                    display: block;
                    position: absolute;
                    bottom: 0;
                    height: 0.2rem;
                    width: 100%;
                    background-color: $--color-text-placeholder;
                }
            }
        }
    }
}

.rg-results-container {
    .rg-results {
        margin: 0;
        padding: 5px;
        width: 384px;
        line-height: 1.5;

        li {
            overflow: hidden;
            padding: 3px 10px;
            font-size: 14px;
            cursor: pointer;

            &.rg-item {
                display: inline-block;
                color: $--color-text-secondary;

                &:hover:not(.active) {
                    color: $--color-text-primary;
                    background-color: rgba($--color-text-placeholder,.2);
                }

                &.active {
                    color: $--color-text-primary;
                    background-color: rgba($--color-text-placeholder,.6);
                }
            }

            &.rg-message-box {
                height: 30px;
                line-height: 30px;
                text-align: center;
                cursor: default;
            }
        }
    }
}

.rg-input {
    background-color: rgba($--color-text-placeholder,.2);
    border: 0;
    width: 100%;
    font-size: 14px;
    padding: 6px;
    outline: none !important;
    border-radius: 2px;

    &::-webkit-input-placeholder {
        color: $--color-text-placeholder;
    }
}
