
.btn-instance-submit .record-edit-text{
    color: #ffffff;
}
.btn-instance-submit .record-edit-text:hover{
    color: #ffffff;
}
.btn-instance-submit .record-edit-text:focus{
    color: #ffffff;
}

.relative {
    position: relative!important;
}
.flex-1 {
    flex: 1 1 0%!important;
}

.flex-col {
    flex-direction: column!important;
}
.flex {
    display: flex!important;
}

/* 修复全局样式.collapse引起的 日期时间选择异常问题 */
.bootstrap-datetimepicker-widget .collapse{
    visibility: visible !important;
}

/* 增加旧表单设计器的宽度 */
.flow-modal .modal-lg{
	width: 100%;
	margin-left: 0px;
	margin-right: 0px;
}

.flow-modal .modal-lg .slds-modal__container{
    width: 90% !important;
    max-width: 90% !important;
    min-width: 90% !important;
}

/*申请单中使用 旧版中的 inline-block样式 */
.instance-wrapper .instance-form .inline-block{
    display: block !important;
}

.instance-print .instance-form .inline-block{
    display: block !important;
}

.instance-box-tree .antd-TreeControl{
    padding: 0;
    background: #ffffff;
}

/* Remove default tree styling to allow custom styling */
.instance-box-tree .antd-Tree-itemLabel-item{
    padding: 0 !important;
    margin: 0 !important;
    display: flex !important;
    align-items: center !important;
    width: 100%; /* Ensure it spans the width */
}

/* Ensure the label container is also flex centered and full width */
.instance-box-tree .antd-Tree-itemLabel {
    display: flex !important;
    align-items: center !important;
    width: 100%;
    padding-right: 4px;
}

/* Tree item wrapper - removed margin to allow full-row background */
/* .instance-box-tree .antd-TreeControl{
    padding: 0;
    border-bottom: 0px;
    border-radius: 0px;
    border-right: 0px;
    max-height: 100%;
    padding-top: 8px;
    padding-left: 4px;
}
.instance-box-tree .antd-Tree {
    max-height: 100%;
}
.instance-box-tree .antd-Tree-itemLabel{
    padding-left: 0;
}

.instance-box-tree .antd-Tree-itemLabel-item{
    padding-left: 0;
}
.instance-box-tree .antd-Tree-itemArrow{
    margin-right: 0;
}
.instance-box-tree .antd-Tree-itemIcon{
    margin-right: 4px;
} */
/* Fix Badge layout: force it to flow naturally in flex layout to display full content for large numbers like 9999 */
/* Also ensures it stays aligned to the right of the text label without overlapping */
.instance-box-tree .antd-Badge {
    height: auto !important;
    width: auto !important;
    position: static !important;
    transform: none !important;
    flex-shrink: 0;
    margin-left: 4px;
    display: flex;
    align-items: center;
}

.instance-box-tree  .antd-Badge-text{
    background: #e5e7eb;
    color: #4b5563;
    font-size: 11px;
    padding: 0px 6px;
    border-radius: 10px;
    font-weight: 500;
    line-height: 18px;
    min-width: 18px;
    display: inline-block;
    text-align: center;
    position: static !important;
    transform: none !important;
}
.instance-box-tree .antd-Tree-item:nth-child(1) .antd-Badge-text{
    background: #ef4444;
    color: #ffffff;
}
/* .instance-box-tree .antd-Tree-itemLabel-item{
    height: 1.6rem;
} */
.instance-box-tree .antd-TplField span{
    /* width: 85%; */
    display: block;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}
.instance-box-tree .antd-Tree-itemText{
    margin: auto;
}


.steedos-table-modal-body{
    display: initial !important;
}

.instance-trace-detail-modal .modal-body{
    display: initial !important;
}

.instance-box-tree .antd-Tree{
    max-height: 100% !important;
}

.instance-box-tree .antd-TreeControl{
    border: none !important;
}

/* Base styling for all menu labels - must be specific enough */
.instance-box-tree .antd-Tree .instance-menu-label {
    font-weight: 400;
    color: #6b7280;
}

/* Tree item spacing for proper layout */
.instance-box-tree .antd-Tree-item {
    margin: 2px 8px;
}

/* Selected state styling - Using robust pseudo-element strategy for cross-browser support */

/* 1. Reset positions to ensure clean background layering */
.instance-box-tree .antd-Tree-item {
    margin: 2px 8px; /* Maintain standard margin */
    position: relative !important; /* Context for absolute positioning */
    z-index: 0; /* Create stacking context so -1 doesn't go behind the white container */
}

/* 2. Remove ANY positioning from the label so it doesn't trap the pseudo-element */
.instance-box-tree .antd-Tree-itemLabel.is-checked {
    background-color: transparent !important;
    position: static !important;
}

/* 3. Helper to make label static if checked is on item */
.instance-box-tree .antd-Tree-item.is-checked > .antd-Tree-itemLabel {
    background-color: transparent !important;
    position: static !important;
}

/* 4. The background pseudo-element */
.instance-box-tree .antd-Tree-itemLabel.is-checked::before,
.instance-box-tree .antd-Tree-item.is-checked > .antd-Tree-itemLabel::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 0; /* Cover full height (margin handles the spacing) */
    bottom: 0;
    background-color: var(--color-brand-50, #dbeafe);
    border-radius: 6px;
    z-index: -1; /* Behind text */
}

.instance-box-tree .antd-Tree-itemLabel.is-checked .instance-menu-label,
.instance-box-tree .antd-Tree-item.is-checked .instance-menu-label {
    color: var(--Menu-light-fontColor-onHover, #1e40af) !important;
}

.instance-box-tree .antd-Tree-itemLabel.is-checked .antd-Tree-itemIcon,
.instance-box-tree .antd-Tree-item.is-checked .antd-Tree-itemIcon {
    color: var(--Menu-light-fontColor-onHover, #1e40af) !important;
}

/* Hover state - entire row with light gray background */
.instance-box-tree .antd-Tree-item:hover {
    background-color: #f3f4f6;
    border-radius: 6px;
    margin: 2px 8px;
}

.instance-box-tree .antd-Tree-item.is-checked:hover {
    background-color: var(--color-brand-50, #dbeafe) !important;
}

/* Group title styling - larger and bolder */
.instance-box-tree .antd-Tree .antd-Tree-item[aria-level="1"] .instance-menu-label {
    font-size: 13px !important;
    font-weight: 600;
    color: #374151;
}
--isL
/* Child item (non-leaf) styling - normal size and weight */
.instance-box-tree .antd-Tree .antd-Tree-item[aria-level="2"]:not(.is-leaf) .instance-menu-label {
    font-size: 13px !important;
    font-weight: 400;
    color: #6b7280;
}

/* Leaf node styling - darker and larger for prominence */
.instance-box-tree .antd-Tree .antd-Tree-item--isLeaf .instance-menu-label {
    font-size: 14px !important;
    font-weight: 600 !important;
    color: rgb(71 85 105 / var(--tw-text-opacity, 1)) !important;
}

/* Override leaf node color when selected */
.instance-box-tree .antd-Tree .antd-Tree-item--isLeaf .antd-Tree-itemLabel.is-checked .instance-menu-label {
    color: var(--Menu-light-fontColor-onHover, #1e40af) !important;
    font-weight: 600 !important;
}

/* Fix alignment and spacing for the custom menu template wrapper */
.instance-box-tree .antd-Tree-itemText > div {
    padding-top: 0px !important; /* Reduced from 4px to fix "text too low" */
    padding-bottom: 0px !important;
    padding-right: 0px !important; /* Reduced to move content closer to right edge */
    line-height: 24px; /* Explicit line height to ensure centering */
    display: flex;
    align-items: center;
}

/* Ensure the text container takes available width */
.instance-box-tree .antd-Tree-itemText {
    flex: 1;
    display: flex;
    align-items: center;
    position: relative; /* Ensure z-index works if needed */
    z-index: 1;
    min-width: 0; /* Enable truncation */
}

/* Icon styling */
.instance-box-tree .antd-Tree-itemIcon{
    color: #6b7280;
    margin-right: 0px;
}

/* Hide icons for leaf nodes at level >= 3 (final menu items within category groups) */
.instance-box-tree .antd-Tree .antd-Tree-item--isLeaf[style*="calc(2 *"] .antd-Tree-itemIcon,
.instance-box-tree .antd-Tree .antd-Tree-item--isLeaf[style*="calc(3 *"] .antd-Tree-itemIcon,
.instance-box-tree .antd-Tree .antd-Tree-item--isLeaf[style*="calc(4 *"] .antd-Tree-itemIcon,
.instance-box-tree .antd-Tree .antd-Tree-item--isLeaf[style*="calc(5 *"] .antd-Tree-itemIcon {
    display: none;
    margin-right: 0px;
}

/* Reduce left padding for leaf nodes to compensate for hidden icon */
.instance-box-tree .antd-Tree .antd-Tree-item--isLeaf .antd-Tree-itemLabel{
    padding-left: 0;
}

/* Hide arrow placeholder for leaf nodes at level >= 3 to align text left without shifting container */
.instance-box-tree .antd-Tree .antd-Tree-item--isLeaf[style*="calc(2 *"] .antd-Tree-itemArrowPlaceholder,
.instance-box-tree .antd-Tree .antd-Tree-item--isLeaf[style*="calc(3 *"] .antd-Tree-itemArrowPlaceholder,
.instance-box-tree .antd-Tree .antd-Tree-item--isLeaf[style*="calc(4 *"] .antd-Tree-itemArrowPlaceholder,
.instance-box-tree .antd-Tree .antd-Tree-item--isLeaf[style*="calc(5 *"] .antd-Tree-itemArrowPlaceholder {
    width: 22px;
}

/* Arrow styling */
.instance-box-tree .antd-Tree-itemArrow{
    color: #9ca3af;
    transition: transform 0.2s ease;
    margin-right: 4px;
}

.instance-box-tree .antd-Tree-item.is-expanded > .antd-Tree-itemArrow{
    transform: rotate(90deg);
}



.steedos-instance-wrapper input[disabled], input:disabled, input.disabled, input.is-disabled {
    -webkit-text-fill-color: inherit !important;
}


.instance-trace-detail-modal .weui-input{
    color: #777;
}

tbody .color-priority-danger *{
    color: red !important;
}

tbody .color-priority-warning *{
    color: purple !important;
}

tbody .color-priority-muted *{
    color: blue !important;
}

.instance-tasks-list .unread-instance .antd-Table-checkCell {
    position: relative
}

/* PC端未读列表蓝色圆点 */
.instance-tasks-list .unread-instance .antd-Table-checkCell:before {
    content: " ";
    position: absolute;
    right: -6px;
    width: 10px;
    height: 10px;
    background-color: #1890ff;
    border-radius: 6px;
    top: 50%;
    margin-top: -6px;
}

.instance-tasks-list .unread-instance .steedos-listview-item {
    position: relative
}

/* 手机端未读列表蓝色圆点 */
.instance-tasks-list .unread-instance .steedos-listview-item:before {
    content: " ";
    position: absolute;
    left: -5px;
    width: 8px;
    height: 8px;
    background-color: #1890ff;
    border-radius: 4px;
    top: 10px;
}

#instanceAmisView fieldset{
    width: 100%;
}


#serverList{
    display: none !important;
}

.instance-suggestion{
    background: #ffffff !important;
}

.instance .form-group select.form-control{
    height: 34px;
}



.af-steedos-field .antd-FileControl-dropzone.disabled{
    display: none;
}

.af-steedos-field .antd-ImageControl-addBtn.is-disabled{
    display: none;
}

#instanceform .antd-ImageControl-item{
    border: none;
    padding: 0px;
    margin-bottom: 6px;
    margin-right: 6px;
}


.instance-print #instanceAmisView .antd-Table-placeholder{
    display: none;
}

.instance-print #instanceAmisView .antd-Table-table > thead > tr{
    border-bottom: none;
}

.instance-print #instanceAmisView .antd-Table-table > thead > tr > th{
    background: #ffffff;
    border-color: #000000;
    border-bottom: none;
    padding-left: 4px;
    padding-right: 4px;
}


.instance-print #instanceAmisView .antd-Table-table td {
    border-bottom: #000000 1px solid;
    padding-top: 0px;
    padding-bottom: 0px;
    margin: 0px;
}

.instance-print #instanceAmisView .antd-Table-table tr:last-child td {
    border-bottom: none;
   }

.instance-print #instanceAmisView .antd-Table-table > thead > tr:not(:last-child) {
    border-bottom: #000000 1px solid;
}

.instance-print #instanceAmisView .antd-Table-table > tbody > tr:last-child {
    border-bottom: none;
}

.instance-print #instanceAmisView .antd-Table-table > tbody > tr > td:not(:last-child) {
    border-right: #000000 1px solid;
}

.instance-print #instanceAmisView .antd-Table-table > tbody > tr:first-child {
    border-top: #000000 1px solid;
}

.instance-print #instanceAmisView .antd-Table-table > tbody > tr:not(:last-child) {
    border-bottom: #000000 1px solid;
}

.instance-print #instanceAmisView .steedos-field-section{
    font-weight: 700;
    font-size: 15px;
}

.instance-print #instanceAmisView .antd-Table {
    margin-bottom: 0px;
}

.instance-print #instanceAmisView .antd-Table-table > thead > tr > th:first-child {
    text-align: center;
}

.instance-print #instanceAmisView .antd-Table-table > tbody > tr > td:first-child {
    text-align: center;
}

.instance-print #instanceAmisView .antd-Form-item {
    padding: 0px !important;
}

/* 平台内的table表头都变成了无边框，审批王内的打印需要边框 */
.instance-print #instanceAmisView .antd-Table-table thead > tr > th {
    border-right: var(--Table-thead-borderWidth) solid #000000;
}

/* 最后一列不需要边框 */
.instance-print #instanceAmisView .antd-Table-table thead > tr > th:last-child {
    border-right: none;
}

/* 实际的打印中service层未撑满 */
@media print {
    .instance-print #instanceAmisView .steedos-input-table>.antd-Service {
        width: 100%;
    }
}

/* 审批王的打印中的td需要换行，否则会撑出页面 */
.instance-print #instanceAmisView .antd-Table-table tbody > tr > td{
    white-space: normal;
}

/* 统一审批详细页的amisbutton样式 */
.instance-wrapper .instance-left-buttons .slds-button-group .steedos-amis-button button.antd-Button{
    padding: 0;
    margin: 0;
    color: #1890ff;
}
.instance-wrapper .instance-left-buttons .slds-button-group .steedos-amis-button button.antd-Button:hover{
    color: #40a9ff
}

.steedos-instance-print-wrapper .liquid-amis-container{
    width: 190mm;
}

@media (max-width: 768px){
    /* 审批单详细页手机端附件预览按钮样式 */
    .instance-wrapper .instance_attachments .steedos-amis-button-instance-preview li.steedos-amis-button{
        width: -webkit-fill-available;
    }
}

/* amis 弹出窗口，包括弹出drawer中的审批单详细界面不显示左上角返回按钮 */
.amis-dialog-widget .instance-detail-service-wrapper .btn-instance-back{
    display: none;
}


.instance-table .inbox{
    width: auto !important;
    height: auto !important;
    display: block;
    box-shadow: none;
}

.steedos-instance-style-table .antd-RadiosControl{
    margin-left: 0.5rem !important;
}

.steedos-instance-style-table .antd-CheckboxesControl{
    margin-left: 0.5rem !important;
}

.instances-sidebar .steedos-listview-change-button > button > .fa-caret-down{
    display: none;
}

.instance-form-view .antd-Table-placeholder{
    display: none;
}

.steedos-amis-instance-view{
    background: #fff;
}

.steedos-amis-instance-view .instance-name{
    font-weight: 700;
}

.instance-applicant-view .inline-left {
    display: inline;
    float: left;
    line-height: 32px;
}

.steedos-instance-detail-wrapper{
    height: calc(100vh - 101px);
}

@media (max-width: 768px){
    .steedos-instance-detail-wrapper{
        height: calc(100vh - 64px);
    }
}

.steedos-amis-instance-view-body .antd-Panel-title{
    font-size: 14px;
    font-weight: 500;
}

.steedos-amis-instance-view-body .approve-button{
    z-index: 900;
}

/* Sidebar wrapper - no scrolling as parent handles it */
.instances-sidebar-wrapper{
    /* Removed overflow and height - parent layer handles scrolling */
}

.instances-sidebar-wrapper::-webkit-scrollbar {
    width: 6px;
}

.instances-sidebar-wrapper::-webkit-scrollbar-track {
    background: transparent;
}

.instances-sidebar-wrapper::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 3px;
}

.instances-sidebar-wrapper::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

.steedos-instance-related-view-wrapper{
    .antd-Page-header{
        display: none;
    }
}

.instance-form pre{
  white-space: pre-wrap;      /* 保留空白符，允许换行 */
  word-wrap: break-word;      /* 长单词或URL换行 */
  overflow-wrap: break-word;  /* 更现代的属性 */
}


.instance-form,.instance-template .td-title{
  text-align: center;
}

.instance-form .td-childfield{
    text-align: left;
}

.instance-template .table-page-body .antd-Form-label{
    display: none !important;
}

.instance-form .form-table {
    border-collapse: collapse;
    border: 2px solid black;
}
.instance-form .form-table td {
    border: 1px solid black;
    padding: 4px 6px;
    border-collapse: collapse;
}

.instance-form .td-childfield{
    padding: 0 !important;
    border: none !important;
}

.steedos-instance-style-table .instance-form .td-childfield {
    padding: 0 !important;
    border: 1px solid black !important;
}
.steedos-instance-style-table .instance-form .td-childfield .antd-Table{
    margin-bottom: 0px !important;
}

.steedos-instance-style-table .instance-form .td-childfield .antd-Table .antd-Table-operationCell {
    border: none !important;
}

.steedos-instance-style-table .instance-form .td-childfield .antd-Table td:first-child {
    border-right: none !important;
}
.steedos-instance-style-table .antd-Select-value{
    white-space: unset !important;
}


/* 1. 基础设置：合并边框并去掉表格容器的外边框 */
.instance-form .antd-Table-table {
  border-collapse: collapse;
  border: none !important; /* 强制移除最外层边框 */
}

/* 2. 给所有单元格添加边框（内部边框） */
.instance-form .antd-Table-table th,
.instance-form .antd-Table-table td {
  border: 1px solid #000; /* 这里可以修改你想要的颜色，比如 #000 */
  padding: 8px; /* 适当增加间距更美观 */
}

/* 3. 移除最左侧和最右侧的垂直边框 */
.instance-form .antd-Table-table tr th:first-child,
.instance-form .antd-Table-table tr td:first-child {
  border-left: none;
}
.instance-form .antd-Table-table tr th:last-child,
.instance-form .antd-Table-table tr td:last-child {
  border-right: none;
}

/* 4. 移除最顶部和最底部的水平边框 */
.instance-form .antd-Table-table thead tr:first-child th {
  border-top: none;
}
.instance-form .antd-Table-table tbody tr:last-child td {
  border-bottom: none;
}

.instance-form .steedos-input-table .antd-Service>.antd-Form-item {
    margin-bottom: 0px !important;
}

.instance-form .ant-select-selector{
    background: transparent !important;
    border: none !important;
}

.instance-form .antd-FileControl-selectBtn{
    border: none;
    background: transparent;
    color: #000;
}


.instance-form .antd-ImageControl-addBtn{
    border: none;
    background: transparent;
    color: #000;
}

.instance-form .steedos-input-table .antd-Table-table colgroup col:nth-child(2) {
    width: 0px !important;
    min-width: 0px !important;
}

.instance-form .steedos-input-table .antd-Table-table thead tr th:first-child {
    width: 60px;
}

.instance-form .steedos-input-table .antd-Table-table thead .antd-Table-operationCell {
    width: 0px !important;
}

.instance-form .steedos-input-table .antd-Table-table .steedos-input-table-column-operation {
    border: none !important;
}

.instance-form .steedos-input-table .antd-Table-table .steedos-input-table-column-operation .antd-OperationField {
    margin-left: -55px;
}

.instance-form td .loading {
    display: none !important;
}


.instance-form .antd-Table-headToolbar{
    display: none !important;
}

.table-page-title{
    border: none !important;
}

.instance-name .page-title{
    text-align: center;
    border: none !important;
}


.page-page_instance_print .instance-approve-history{
    width: 190mm;
}

/* 公共打印隐藏样式 */
@media print {
  .no-print {
    display: none !important;
    visibility: hidden !important;
  }
  .antd-Form-item{
    border: none !important;
    content: none !important;
  }
  .antd-Form-item::after{
    border: none !important;
  }
  .steedos-amis-instance-view-body{
    margin: 20px 0 0 0 !important;
  }

  a[href]:after {
    content: none !important;
  }

  .font-normal{
    border: none !important;
  }
}

.antd-Combo-form .antd-Form-row .antd-Form-col{
    margin-bottom: 0.75rem !important;
}
.antd-Combo-form .antd-Form-row .antd-Form-col .antd-Form-rowInner > div{
    flex: 1;
}


  /* .steedos-instance-detail-wrapper{
        height: auto !important;
    }

    .steedos-amis-instance-view-body{
        height: auto !important;
    }
    .creator-content-wrapper{
        overflow: unset !important;
    }

    body{
        overflow: auto !important;
    } */