* {
    margin: 0;
    padding: 0;
}

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

body {
    -moz-osx-font-smoothing: grayscale;
    -webkit-font-smoothing: antialiased;
    font-family: 'PingFang SC', AlibabaPuHuiTi !important;
    font-size: 14px;
    font-style: normal;
    font-weight: 500;
    height: 100%;
    margin: 0;
    padding: 0;
    color: var(--app-text-color);
}

#app {
    height: 100%;
}

:focus {
    outline: none;
}

a:active {
    outline: none;
}

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

div:focus {
    outline: none;
}

ul {
    list-style: none;
    margin: 0;
    padding: 0;
}


/* 滚动条整体部分 */

::-webkit-scrollbar {
    width: 6px; // 纵向滚动条宽度
    height: 6px; // 横向滚动条高度
}


/* 滑块 */

::-webkit-scrollbar-thumb {
    border-radius: 5px;
}


/* 轨道 */

::-webkit-scrollbar-track {
    border-radius: 5px;
    background-color: transparent;
}

.clearfix:after {
    content: '';
    display: block;
    clear: both;
}

h1 {
    font-size: 24px;
}

h2 {
    font-size: 20px;
    font-weight: 500;
}

h3 {
    font-size: 18px;
}

h4 {
    font-size: 16px;
}

h5 {
    font-size: 14px;
    font-weight: 500;
}

.bold {
    font-weight: 600;
}

.lighter {
    font-weight: 400;
}

.w-full {
    width: 100%;
}

.h-full {
    height: 100%;
}

.w-120 {
    width: 120px;
}

.w-240 {
    width: 240px;
}

.w-280 {
    width: 280px;
}

.w-500 {
    width: 500px;
}

.max-w-200 {
    max-width: 200px;
}

.gap-2{
    gap: .5rem;  
}

.max-w-350 {
    max-width: 350px;
}

.mt-4 {
    margin-top: calc(var(--app-base-px) - 4px);
}

.mt-8 {
    margin-top: var(--app-base-px);
}

.mt-12 {
    margin-top: calc(var(--app-base-px) + 4px);
}

.mt-16 {
    margin-top: calc(var(--app-base-px) * 2);
}

.mt-20 {
    margin-top: calc(var(--app-base-px) * 2 + 4px);
}

.mt-24 {
    margin-top: calc(var(--app-base-px) * 3);
}

.mb-4 {
    margin-bottom: calc(var(--app-base-px) - 4px);
}

.mb-8 {
    margin-bottom: var(--app-base-px);
}

.mb-12 {
    margin-bottom: calc(var(--app-base-px) + 4px);
}

.mb-16 {
    margin-bottom: calc(var(--app-base-px) * 2);
}

.mb-24 {
    margin-bottom: calc(var(--app-base-px) * 3);
}

.ml-4 {
    margin-left: calc(var(--app-base-px) - 4px);
}

.ml-8 {
    margin-left: var(--app-base-px);
}

.ml-12 {
    margin-left: calc(var(--app-base-px) + 4px);
}

.ml-16 {
    margin-left: calc(var(--app-base-px) * 2);
}

.ml-24 {
    margin-left: calc(var(--app-base-px) * 3);
}

.ml-30 {
    margin-left: calc(var(--app-base-px) * 4 - 2px);
}

.mr-4 {
    margin-right: calc(var(--app-base-px) - 4px);
}

.mr-6 {
    margin-right: calc(var(--app-base-px) - 2px);
}

.mr-8 {
    margin-right: var(--app-base-px);
}

.mr-12 {
    margin-right: calc(var(--app-base-px) + 4px);
}

.mr-16 {
    margin-right: calc(var(--app-base-px) * 2);
}

.mr-24 {
    margin-right: calc(var(--app-base-px) * 3);
}

.p-8 {
    padding: var(--app-base-px);
}

.p-16 {
    padding: calc(var(--app-base-px) * 2);
}

.p-24 {
    padding: calc(var(--app-base-px) * 3);
}

.p-8-12 {
    padding: calc(var(--app-base-px)) calc(var(--app-base-px) + 4px);
}

.p-12-16 {
    padding: calc(var(--app-base-px) + 4px) calc(var(--app-base-px) * 2);
}

.p-12-24 {
    padding: calc(var(--app-base-px) + 4px) calc(var(--app-base-px) * 3);
}

.p-16-24 {
    padding: calc(var(--app-base-px) * 2) calc(var(--app-base-px) * 3);
}

.pt-0 {
    padding-top: 0;
}

.pb-0 {
    padding-bottom: 0;
}

.float-right {
    float: right;
}

.flex {
    display: flex;
}

.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

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

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

.flex-direction-column {
    display: flex;
    flex-direction: column;
}

.align-center {
    align-items: center;
}

.align-baseline {
    align-items: baseline;
}

.justify-center {
    justify-content: center;
}

.text-left {
    text-align: left;
}

.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.vertical-middle {
    vertical-align: middle;
}

.line-height-22 {
    line-height: 22px;
}

.border {
    border: 1px solid var(--el-border-color);
}

.border-l {
    border-left: 1px solid var(--el-border-color);
}

.border-b {
    border-bottom: 1px solid var(--el-border-color);
}

.border-r {
    border-right: 1px solid var(--el-border-color);
}

.border-t {
    border-top: 1px solid var(--el-border-color);
}

.border-b-light {
    border-bottom: 1px solid var(--el-border-color-lighter);
}

.border-r-4 {
    border-radius: 4px;
}

.border-r-8 {
    border-radius: 8px;
}

.border-t-dashed {
    border-top: 1px dashed var(--el-border-color);
}

.border-primary {
    border: 1px solid var(--el-color-primary);
    color: var(--el-color-primary);
}

.border-none {
    border: none;
}

.cursor {
    cursor: pointer;
}

.notAllowed {
    cursor: not-allowed;
}


/*
  超出省略号
*/

.ellipsis {
    display: inline-block;
    max-width: 130px;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
}


/*
  双行超出省略号，其他行数自定义 -webkit-line-clamp
*/

.ellipsis-2 {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}

.ellipsis-1 {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 1;
    overflow: hidden;
}

.break-all {
    word-break: break-all;
}

.pre-wrap {
    white-space: pre-wrap;
}


/*
  内容部分 自适应高度
*/

.main-calc-height {
    height: var(--app-main-height);
    box-sizing: border-box;
}


/*
  标题前带竖线样式
*/

.title-decoration-1 {
    position: relative;
    padding-left: 12px;
    &:before {
        position: absolute;
        left: 2px;
        top: 50%;
        transform: translate(-50%, -50%);
        width: 2px;
        height: 80%;
        content: '';
        background: var(--el-color-primary);
    }
}


/* tag */

.default-tag {
    background: var(--el-color-primary-light-8);
    color: var(--el-color-primary);
    border: none;
}

.danger-tag {
    background: var(--tag-danger-bg);
    color: #d03f3b;
    border: none;
}

.success-tag {
    background: var(--tag-success-bg);
    color: var(--el-color-success);
    border: none;
}

.warning-tag {
    background: var(--tag-warning-bg);
    color: var(--el-color-warning);
    border: none;
}

.info-tag {
    background: var(--app-text-color-light-1);
    color: var(--app-text-color-secondary);
    border: none;
}

.purple-tag {
    background: #f2ebfe;
    color: #7f3bf5;
    border-color: #e0d7f0;
}

.blue-tag {
    background: #ebf1ff;
    color: #3370ff;
    border-color: #d6e2ff;
}


/*
  card 无边框无阴影 灰色背景
*/

.card-never {
    background: var(--app-layout-bg-color);
    border: none;
}


/*
   图标旋转90度
*/

.rotate-90 {
    transform: rotateZ(90deg);
}

.rotate-180 {
    transform: rotateZ(180deg);
}


/*
  表格第一行插入自定义行
*/

.table-quick-append {
    background: #ffffff;
    .el-table__append-wrapper {
        position: absolute;
        top: 0;
        border-bottom: var(--el-table-border);
        width: 100%;
        height: 49px;
        box-sizing: border-box;
        align-items: center;
        display: flex;
        padding: 0 12px;
        background: #ffffff;
        cursor: pointer;
        z-index: 2;
        &:hover {
            background: var(--el-color-primary-light-9);
            z-index: 1;
        }
    }
    .el-table__body {
        margin-top: 49px;
    }
}

// checkbox-group 文字在左 input在右
.app-custom-checkbox-group {
    line-height: normal;
    .el-checkbox__label {
        display: none;
    }
}


/*
  头像渐变背景
*/

.avatar-gradient {
    background: var(--app-avatar-gradient-color);
}

.avatar-light {
    background: var(--el-color-primary-light-3);
}

.avatar-purple {
    background: #7f3bf5;
}

.avatar-blue {
    background: #3370ff;
}

.avatar-green {
    background: #34c724;
}

.avatar-grey {
    background: #bbbfc4;
}

.success {
    color: var(--el-color-success);
}

.danger {
    color: var(--el-color-danger);
}

.warning {
    color: var(--el-color-warning);
}

.primary {
    color: var(--el-color-primary);
}

.info {
    color: var(--el-color-info);
}

.color-secondary {
    color: var(--app-text-color-secondary);
}

.layout-bg {
    background: var(--app-layout-bg-color);
}

.white-bg {
    background: #ffffff;
}

.app-warning-icon {
    font-size: 16px;
    color: var(--app-text-color-secondary);
}

.dotting {
    display: inline-block;
    width: 10px;
    min-height: 2px;
    padding-right: 2px;
    margin-left: 2px;
    padding-left: 2px;
    border-left: 2px solid currentColor;
    border-right: 2px solid currentColor;
    background-color: currentColor;
    background-clip: content-box;
    box-sizing: border-box;
    -webkit-animation: dot 0.8s infinite step-start both;
    animation: dot 0.8s infinite step-start both;
    &:before {
        content: '...';
    }
    &::before {
        content: '';
    }
}

@-webkit-keyframes dot {
    25% {
        border-color: transparent;
        background-color: transparent;
    }
    50% {
        border-right-color: transparent;
        background-color: transparent;
    }
    75% {
        border-right-color: transparent;
    }
}

@keyframes dot {
    25% {
        border-color: transparent;
        background-color: transparent;
    }
    50% {
        border-right-color: transparent;
        background-color: transparent;
    }
    75% {
        border-right-color: transparent;
    }
}

.file-List-card {
    border-radius: 4px;
    .el-card__body {
        padding: 8px 16px 8px 12px;
    }
}

.card__radio {
    width: 100%;
    display: block;
    line-height: 22px;
    .el-radio {
        white-space: break-spaces;
        width: 100%;
        height: 100%;
        line-height: 22px;
        color: var(--app-text-color);
    }
     :deep(.el-radio__label) {
        padding-left: 30px;
        width: 100%;
    }
     :deep(.el-radio__input) {
        position: absolute;
        top: 16px;
    }
    .active {
        border: 1px solid var(--el-color-primary);
    }
    .el-card__body {
        padding: calc(var(--app-base-px) + 4px) calc(var(--app-base-px) * 2);
    }
}

// 段落card
.paragraph-source-card {
    height: 210px;
    width: 100%;
    .active-button {
        position: absolute;
        right: 16px;
        top: 16px;
    }
}

// 分段 dialog
.paragraph-dialog {
    padding: 0 !important;
    .el-scrollbar {
        height: auto !important;
    }
    .el-dialog__header {
        padding: 16px 24px;
    }
    .el-dialog__body {
        border-top: 1px solid var(--el-border-color);
    }
    .el-dialog__footer {
        padding: 16px 24px;
        border-top: 1px solid var(--el-border-color);
    }
    .title {
        color: var(--app-text-color);
    }
}

// card 选中样式
.selected {
    border: 1px solid var(--el-color-primary) !important;
    &:before {
        content: '';
        position: absolute;
        right: 0;
        top: 0;
        border: 14px solid var(--el-color-primary);
        border-bottom-color: transparent;
        border-left-color: transparent;
    }
    &:after {
        content: '';
        width: 3px;
        height: 6px;
        position: absolute;
        right: 5px;
        top: 2px;
        border: 2px solid #fff;
        border-top-color: transparent;
        border-left-color: transparent;
        transform: rotate(35deg);
    }
    &:hover {
        border: 1px solid var(--el-color-primary);
    }
}

.app-card {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0px 2px 4px 0px rgba(31, 35, 41, 0.12);
}

.app-radio-button-group {
    border: 1px solid var(--app-border-color-dark);
    border-radius: var(--el-border-radius-base);
    .el-radio-button {
        padding: 3px;
    }
    .el-radio-button__inner {
        border: none !important;
        border-radius: var(--el-border-radius-base) !important;
        padding: 5px 8px;
        font-weight: 400;
    }
    .el-radio-button__original-radio:checked+.el-radio-button__inner {
        color: var(--el-color-primary) !important;
        background: var(--el-color-primary-light-9) !important;
        border: none !important;
        box-shadow: none !important;
        font-weight: 500;
    }
}

// 自定义主题
.custom-header {
    background: var(--el-color-primary-light-9) !important;
}

.edit-avatar {
    position: relative;
    .edit-mask {
        position: absolute;
        left: 0;
        background: rgba(0, 0, 0, 0.4);
    }
}

.record-tip-confirm {
    max-width: 800px !important;
}

//企业微信
.wwLogin_qrcode_head {
    padding: 20px 0 !important;
}

// 复合搜索框
.complex-search {
    border: 1px solid var(--el-border-color);
    border-radius: var(--el-border-radius-base);
    .el-select__wrapper {
        box-shadow: none !important;
    }
    .el-input__wrapper {
        box-shadow: none !important;
    }
    &__left {
        border-right: 1px solid var(--el-border-color);
    }
}

@media only screen and (max-width: 768px) {
    .responsive-dialog {
        width: 90% !important;
    }
}

// 指定容器加滚动条
.scroll-container {
    /* 强制显示横向滚动条（覆盖全局隐藏设置） */
    &::-webkit-scrollbar {
        display: block;
        height: 2px;
        /* 横向滚动条高度‌:ml-citation{ref="3" data="citationList"} */
    }
    &::-webkit-scrollbar-thumb {
        background: #ebf1ff;
        /* 滚动条滑块颜色‌:ml-citation{ref="3" data="citationList"} */
    }
}

.mr-10 {
    margin-right: 10px;
}

.primary-text {
    color: var(--el-color-primary);
}

.res_el-dialog__footer {
    display: block;
    padding-bottom: 30px;
    padding-right: 30px;
    padding-top: 4px;
}

.pl-10 {
    padding-left: 10px;
}

.el-text--info {
    font-size: 12px;
    color: #8C8C8C;
}

.mb-20 {
    margin-bottom: 20px;
}

.mr-5 {
    margin-right: 5px;
}


/** 加载动画 **/

.el-loading-spinner .circular {
    background-image: url('../assets/loading.svg');
    /* 使用外部SVG文件 */
    width: 80px;
    height: 80px;
}

.el-loading-spinner .path {
    stroke: url('../assets/loading.svg');
    /* 使用渐变 */
}

.container-min-height {
    min-height: calc(100vh - var(--app-header-height) - 50px) !important;
    position: relative;
}

.del-Warning-ico {
    width: 20px;
    color: #e6a23c;
    vertical-align: bottom;
}

.res-dropdown-menu {
    ul {
        li.el-dropdown-menu__item {
            background-color: #fff;
        }
        li.el-dropdown-menu__item:hover,
        li.el-dropdown-menu__item:focus {
            color: #6489e3;
            background-color: #F4F8FF;
        }
    }
}


/** docs-main */
#app .webapp-main {
    .el-menu.el-menu--vertical,
    .el-menu.el-menu--inline {
        border: none;
        background: none;
    }
    .el-menu.el-menu--inline .el-menu-item {
        color: rgba(0, 0, 0, 0.6);
    }
    .el-menu-item {
        border-radius: 12px;
        margin-bottom: 6px;
        .sidebar-icon {
            // color: #333;
            fill: currentColor;
        }
    }
    .el-menu-item.is-active {
        color: #3067ef !important;
        background: #ECF2FF !important;
        .sidebar-icon {
            color: #3067ef !important;
            fill: currentColor !important;
        }
    }
    .sidebar-icon {
        font-size: 16px;
        margin-right: 8px;
        padding-top: 2px;
    }
}


/* 重置tabs */

.res-el-tab {
    --el-tabs-header-height: 60px;
    height: 100%;
    .el-tabs__nav-wrap:after {
        height: 0 !important;
    }
    .el-tabs__active-bar {
        height: 4px;
        border-radius: 4px 4px 0 0;
    }
}

.no-shadow .el-textarea__inner{
    box-shadow: none;
}

/* 对话自定义样式 */
.custom-demo{
    border-radius: 4px;
    padding: 0 6px;
    margin:  0 2px;
    display: inline-block;
    vertical-align: middle;
    cursor: pointer;
    color: rgba(0, 0, 0, 0.6);
    background-color: #EBEBEB;
}

/*提示词-自定义tag输入样式 */
.tag-input-wrapper-span{
    border-radius: 4px;
    background: rgba(48,103,239,0.06);
    border: 1px solid rgba(48,103,239,0.5);
    color: #3067EF;
    .el-tag__close{
        background-color: var(--el-tag-hover-color);
        color: var(--el-color-white);
    }
}

/** 定制化弹框 */
.el-message-box.msg-box-custom{
    padding: 0;
    border-radius: 6px;
    .el-message-box__header{
        height: 48px;
        background: linear-gradient( 90deg, #E7EEFF 0%, #DAEAFF 48%, #DAF4FF 100%);
        border-radius: 0px 0px 0px 0px;
        box-sizing: border-box;
        display: flex;
        align-items: center;
        padding: 0 30px;
        .el-message-box__title{
            padding-left: 34px;
        }
        .el-message-box__headerbtn{
            right: 15px;
            top: 3px
        }
        .el-message-box__headerbtn::after{
            background: url('@/assets/icons/guanbi.svg') no-repeat;
            background-size: cover;
            position: absolute;
            content: '';
            width: 13px;
            height: 13px;
            top:13px;
            left: 13px;
            z-index: 1;
        }

        .el-icon.el-message-box__close {
            display: none;
        }
    }
    .el-message-box__header::after{
        width: 24px;
        height: 24px;
        background: url('@/assets/icons/chaoshi.svg') no-repeat;
        background-size: 100% 100%;
        content: '';
        position: absolute;
    }
    .el-message-box__content {
        padding: 15px 30px;
        color: #666;

    }
    .el-message-box__btns{
        padding: 0 30px 20px 30px;
    }

    .el-message-box__btns > *:first-child{
        color: #3067EF;
        background: #fff;
        border: 1px solid #3067EF;
    }

}