// cover some element-ui styles
.el-alert {
    &--info.is-light {
        color: #606266;
        background-color: #f0faff;
        border: 1px solid #abdcff;

        .el-icon-info {
            color: $--color-primary;
        }
    }
}

.el-button {
    [class*="el-icon-"] + span {
        margin-left: 7px;
    }

    //按钮新增类型type=dashed
    &.el-button--dashed {
        border-style: dashed;
    }

    &.el-button--small {
        font-size: 14px;
        padding: 8px 15px;

        &.is-circle {
            padding: 8px;
        }
    }
}

.el-card {
    overflow: visible;

    .el-card__body {
        height: 100%;

        @include clearfix;
    }

    .el-card__header + .el-card__body {
        height: calc(100% - 55px);
    }
}

.el-date-editor.el-input,
.el-date-editor--daterange {
    width: 100% !important;
}

.el-dialog {
    @include deep-shadow;

    margin-bottom: 0;
    min-width: 384px;

    .el-dialog__header {
        border-bottom: 1px solid #EBEEF5;
        padding: 17px;

        .el-dialog__title {
            line-height: inherit;
            color: inherit;
            font-size: inherit;
        }

        .el-dialog__headerbtn {
            top: 18px;
        }
    }

    .el-dialog__footer {
        border-top: 1px solid #EBEEF5;
        padding: 10px 16px;
    }

    .el-scrollbar__wrap {
        //53 for dialog header,53 for dialog footer
        max-height: calc(100vh - 53px - 53px - #{$dialog-top * 2});
    }
}

.el-drawer {
    &__body {
        overflow-y: overlay;
    }
}

.el-loading-mask {
    background: #fff;
    color: $--color-primary;
}

.el-menu {
    border: none;
    height: 100%;
    width: 100%;

    &::-webkit-scrollbar {
        display: none;
    }

    .el-menu-item,
    .el-submenu__title {
        //文字超出截断
        > span {
            display: inline-block;
            white-space: nowrap;
            text-overflow: ellipsis;
            overflow: hidden;
            word-break: break-all;
        }
    }

    //子级菜单激活时，父级同样高亮
    .el-menu-item.is-active,
    .is-active > .el-submenu__title {
        color: $--color-primary !important;
    }

    //箭头图标与字体同色
    .el-submenu__title i {
        color: inherit;
    }

    //弹出菜单
    &.el-menu--popup {
        max-height: 88vh;
        min-width: 160px;
        padding: 0;
        margin-bottom: 0.5vh;
        overflow-y: overlay;

        .el-menu-item,
        .el-submenu__title {
            padding: 0 20px;
        }
    }
}

.el-message {
    @include deep-shadow;
    @include max-width-on-mobile;
    border-width: 0;

    .el-message__icon, .el-message__content {
        color: #ffffff !important;
    }

    &.el-message--success {
        background: $--color-success;
    }

    &.el-message--info {
        background: $--color-primary;
    }

    &.el-message--warning {
        background: $--color-warning;
    }

    &.el-message--error {
        background: $--color-danger;
    }
}

.el-message-box {
    position: relative;
    @include deep-shadow;
    @include max-width-on-mobile;
}

.el-notification {
    @include deep-shadow;

    .el-notification__icon.el-icon-info {
        color: $--color-primary;
    }
}

.el-pagination {
    text-align: right;

    .el-pagination__editor.el-input {
        margin: 0 5px;
    }

    .el-table + & {
        padding-top: 20px;
    }
}

.el-scrollbar {
    height: 100%;

    .el-scrollbar__wrap {
        -webkit-overflow-scrolling: touch;
    }
}

.el-select {
    width: 100%;
}

.el-steps {
    &.el-steps--horizontal {
        .el-step__line {
            left: 57%;
            right: -43%;
        }
    }
}

.el-table {
    thead {
        color: #303133
    }

    thead > tr > th {
        background: #fbfbfb;
    }
}

.el-textarea {
    .el-input__count {
        background: transparent;
    }
}

.el-upload {
    $size: 100px;

    &-list__item-thumbnail {
        object-fit: cover;
    }

    &.el-upload--picture-card {
        height: $size;
        width: $size;
        line-height: $size;
    }

    &-list .el-upload-list__item {
        height: $size;
        width: $size;
    }
}
