@import "~normalize.css/normalize.css";
@import "./var.scss";
@import "./cover/var.scss";
@import "./mixin.scss";
@import "~element-ui/packages/theme-chalk/src/index.scss";
@import "~@ele/style/index.scss";
@import "./cover/element-ui.scss";
@import './display.scss';
@import "./transition.scss";
@import "./nprogress.scss";

html {
    height: 100%;
    box-sizing: border-box;
}

body {
    height: 100%;
    -moz-osx-font-smoothing: grayscale;
    -webkit-font-smoothing: antialiased;
    font-family: -apple-system, BlinkMacSystemFont, Segoe UI, PingFang SC, Hiragino Sans GB, Microsoft YaHei, Helvetica Neue, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol;
    -webkit-tap-highlight-color: transparent;
}

#app {
    height: 100%;
}

*,
*:before,
*:after {
    box-sizing: inherit;
}

a:focus,
a:active,
div:focus {
    outline: none;
}

a,
a:focus,
a:hover {
    cursor: pointer;
    color: inherit;
    text-decoration: none;
}

//非移动端的滚动条样式修改
@include pc {
    ::-webkit-scrollbar {
        width: 6px;

        &:horizontal {
            height: 6px;
        }

        &-thumb {
            width: 6px;
            //border-radius: 5px;
            background-color: rgba($--color-primary, 0.8);

            &:hover {
                background-color: $--color-primary;
            }
        }
    }
}

.clearfix {
    @include clearfix;
}

.overflow-hidden {
    overflow: hidden !important;
}

.flex {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-content: space-between;
}


/*----------路由页面的最大高度开始----------*/
//可能达到的最大高度
$max-height: '100vh - #{$page-view-margin * 2}';

.max-view-height {
    max-height: calc(#{$max-height});
}

//即使高度不够也占满
.max-view-height.full {
    height: 100vh;
}

//有导航栏
.has-nav .max-view-height {
    max-height: calc(#{$max-height} - #{$nav-height});
}

//有多页签栏
.has-tags-view .max-view-height {
    max-height: calc(#{$max-height} - #{$tags-view-height});
}

//有页头
.has-page-header .max-view-height {
    max-height: calc(#{$max-height} - #{$page-header-height});
}

//有页脚
.has-page-footer .max-view-height {
    max-height: calc(#{$max-height} - #{$page-footer-height});
}

//同时有导航栏和多页签栏
.has-nav.has-tags-view .max-view-height {
    max-height: calc(#{$max-height} - #{$nav-height} - #{$tags-view-height});
}

//同时有导航栏和页头
.has-nav .has-page-header .max-view-height {
    max-height: calc(#{$max-height} - #{$nav-height} - #{$page-header-height});
}

//同时有导航栏和页脚
.has-nav .has-page-footer .max-view-height {
    max-height: calc(#{$max-height} - #{$nav-height} - #{$page-footer-height});
}

//同时有导航栏、多页签栏、页头
.has-nav.has-tags-view .has-page-header .max-view-height {
    max-height: calc(#{$max-height} - #{$nav-height} - #{$tags-view-height} - #{$page-header-height});
}

//同时有导航栏、多页签栏、页脚
.has-nav.has-tags-view .has-page-footer .max-view-height {
    max-height: calc(#{$max-height} - #{$nav-height} - #{$tags-view-height} - #{$page-footer-height});
}

//同时有导航栏、多页签栏、页头、页脚
.has-nav.has-tags-view .has-page-header.has-page-footer .max-view-height {
    max-height: calc(#{$max-height} - #{$nav-height} - #{$tags-view-height} - #{$page-header-height} - #{$page-footer-height});
}

/*----------路由页面的最大高度结束----------*/


.table-container {
    margin-top: 10px;
}

.table-image {
    cursor: pointer;
    display: inline-block;
    height: 32px;
    width: 32px;
    border-radius: 50%;
    vertical-align: middle;
    overflow: hidden;
}

.card-container {
    position: relative;

    .el-scrollbar__wrap {
        overflow-x: hidden;
    }
}

//仅用于演示用例
.tip-row {
    position: relative;
    z-index: 1;
    background-color: #fafafa;
    padding: 8px 24px;
    margin-bottom: 20px;
    border-radius: 2px;
    display: block;
    line-height: 32px;
    font-size: 16px;
    font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica Neue, sans-serif;
    color: #337ab7;
    user-select: none;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;

    * + & {
        margin-top: 40px;
    }

    a {
        color: #337ab7;
        cursor: pointer;
        text-decoration: underline;
    }
}

//小圆点
.dot {
    width: 6px;
    height: 6px;
    display: inline-block;
    border-radius: 50%;
    vertical-align: middle;
    position: relative;
    top: -1px;
    margin-right: 11px;
    background-color: $--color-info;

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

    &.primary {
        background-color: $--color-primary;
    }

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

.button-group {
    .el-button {
        margin-top: 10px;
        margin-right: 10px;

        & + .el-button {
            margin-left: 0;
        }
    }
}

.table-add-btn {
    margin: 8px 0;

    .el-button {
        width: 100%;
    }
}

.el-form-item__content {
    > .el-tree {
        margin-top: 8px;
    }

    > .el-switch {
        vertical-align: baseline;
    }
}

.el-table a {
    color: $--color-primary;
}
