.rdg-cell{
    border-inline-end: 0px !important;
}

.rdg-cell:last-child {
    border-right: 1px solid rgb(224, 224, 224) !important;
}

.rdg-checkbox {
    height: 12px !important;
    width: 12px !important;
    outline: 0px !important;
}

.rdg-cell-drag-handle {
    block-size: 0px !important;
}

/*** START : React Grid Data Table ***/
.react-grid-HeaderCell  {
    border-bottom: 0px solid rgb(224, 224, 224) !important;
    border-left: 0px solid rgb(224, 224, 224) !important;
    background-color: #fff !important;
    line-height: 2;
    font-size: 13px !important;
    text-transform: uppercase !important;
    font-weight: normal !important;
    color: rgb(25, 25, 25);
    border-bottom: 1px solid #ddd !important;
    outline: 0px !important;
  }
  
  .react-grid-HeaderCell-sortable {
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
    font-weight: bold;
    text-transform: capitalize;
    font-size: 14px;
    color: #333;
  }
  
  .react-grid-Cell__value div {
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
    font-size:14px;
    color: #666;
  }
  
  
  .react-grid-Row--odd .react-grid-Cell {
    /* background-color: #fafafa !important; */
    background-color: #fff !important;
  }
  
  .react-grid-Cell {
      background-color: #fff;
      padding-left: 8px;
      padding-right: 8px;
      border-right: 0px solid #eee !important;
      border-bottom: 1px solid #ddd
  }
  .react-grid-Cell:nth-last-of-type(2) {
      border-right: 1px solid #eee !important;
  }
  .react-grid-Cell:focus {
      /*
      outline: 2px solid #66afe9;
      outline-offset: -2px
      */
      outline: none !important;
  }
  .react-grid-Cell--locked:focus {
      z-index: 100
  }
  .react-grid-Cell:focus .drag-handle {
      position: absolute;
      bottom: -5px;
      right: -4px;
      background: #66afe9;
      width: 8px;
      height: 8px;
      border: 1px solid #fff;
      border-right: 1;
      border-bottom: 0;
      z-index: 8;
      cursor: crosshair;
      cursor: -webkit-grab
  }
  .react-grid-item  {
      border:0 !important;
  }
  .dragCancel  {
      background-color: inherit !important;
      margin-top: 0px !important;
      padding-top: 0px !important;
  }
  .react-grid-item > div  {
      background-color: #fff;
      border-radius:5px 5px 0 0;
      padding:15px 10px 0px 15px !important;
  }
   .react-grid-item > div span h4 {
      font-family: "Helvetica Neue","Segoe UI",Roboto,Helvetica,Arial,Tahoma,Verdana,sans-serif;
      font-size: 14px;
      line-height: 1.42857;
      color: #000;
   }
  .react-grid-Cell:not(.editing) .react-grid-Cell__value {
      white-space: nowrap;
      text-overflow: ellipsis;
      overflow: hidden
  }
  .react-grid-Cell:not(.editing):not(.rdg-child-cell) .react-grid-Cell__value {
      position: relative;
      top: 50%;
      transform: translateY(-50%);
      font-size: 13px !important;
  }
  .rdg-child-cell .react-grid-Cell__value {
      line-height: 35px
  }
  .react-grid-Cell.readonly {
      background-color: #000
  }
  .react-grid-Cell.copied {
      background: rgba(0, 0, 255, .2)!important
  }
  .react-grid-Cell--locked:last-of-type {
      border-right: 1px solid #ddd;
      box-shadow: none
  }
  .react-grid-Cell:hover:focus .drag-handle .glyphicon-arrow-down {
      display: block;
  }
  .react-grid-Cell.is-dragged-over-down{
    border-right:1px dashed #000;border-left:1px dashed #000;border-bottom:1px dashed #000
  }
  .react-grid-Cell.is-dragged-over-up{
    border-right:1px dashed #000;border-left:1px dashed #000;border-top:1px dashed #000
  }
  .react-grid-Cell.is-dragged-over-up .drag-handle{
    top:-5px
  }
  .react-grid-Cell:hover{
    background:#fff !important;
  }
  .react-grid-Cell--odd:hover{
    background:#fafafa !important;
  }
  .react-grid-cell .form-control-feedback{
    color:#a94442;
    position:absolute;
    top:0;
    right:10px;
    z-index:1000000;
    display:block;
    width:34px;
    height:34px
  }
  .react-grid-Cell.was-dragged-over{
    border-right:1px dashed #000;
    border-left:1px dashed #000
  }
  .react-grid-Cell:hover:focus .drag-handle{
    position:absolute;
    bottom:-8px;
    right:-7px;
    background:#fff;
    width:16px;
    height:16px;
    border:1px solid #66afe9;
    z-index:8;
    cursor:crosshair;
    cursor:-webkit-grab
  }
  .react-grid-Row.row-selected .react-grid-Cell{
    background-color:#dbecfa
  }
  .react-grid-Cell.editing{
    padding:0;
    overflow:visible!important
  }
  .react-grid-Cell--locked.editing{
    z-index:100
  }
  .react-grid-Cell.editing .has-error input{
    border:2px solid red!important;
    border-radius:2px!important
  }.react-grid-Cell__value ul {
      margin-top: 0;
      margin-bottom: 0;
      display: inline-block
  }
  .react-grid-Cell__value .btn-sm {
      padding: 0
  }
  .cell-tooltip {
      position: relative;
      display: inline-block
  }
  .cell-tooltip .cell-tooltip-text {
      visibility: hidden;
      width: 150px;
      background-color: #000;
      color: #fff;
      text-align: center;
      border-radius: 6px;
      padding: 5px 0;
      position: absolute;
      z-index: 1;
      bottom: -150%;
      left: 50%;
      margin-left: -60px;
      opacity: 1s
  }
  .cell-tooltip:hover .cell-tooltip-text {
      visibility: visible;
      opacity: .8
  }
  .cell-tooltip .cell-tooltip-text:after {
      content: " ";
      position:absolute;
      bottom:100%;
      left:50%;
      margin-left:-5px;
      border-width:5px;
      border-style:solid;
      border-color:transparent transparent #000
  }
  .react-grid-Canvas.opaque .react-grid-Cell.cell-tooltip:hover .cell-tooltip-text {
      visibility: hidden
  }
  .rdg-cell-expand {
      top: 0;
      right: 20px;
      position: absolute;
      cursor: pointer
  }
  .rdg-child-row-action-cross-last:before,
  .rdg-child-row-action-cross:before,
  .rdg-child-row-action-cross-last:after,
  .rdg-child-row-action-cross:after {
      content: "";
      position:absolute;
      background:grey;
      height:50%
    }
    .rdg-child-row-action-cross:before{
      left:21px;
      width:1px;
      height:35px
    }
    .rdg-child-row-action-cross-last:before {
      left: 21px;
      width: 1px
  }
  .rdg-child-row-action-cross-last:after,
  .rdg-child-row-action-cross:after {
      top: 50%;
      left: 20px;
      height: 1px;
      width: 15px;
      content: "";
      position:absolute;
      background:grey
  }
  .rdg-child-row-action-cross:hover{
    background:red
  }
  .rdg-child-row-btn{
    position:absolute;
    cursor:pointer;
    border:1px solid grey;
    border-radius:14px;
    z-index:3;
    background:#fff
  }
  .rdg-child-row-btn div {
      font-size: 12px;
      text-align: center;
      line-height: 19px;
      color: grey;
      height: 20px;
      width: 20px;
      position: absolute;
      top: 60%;
      left: 53%;
      margin-top: -10px;
      margin-left: -10px
  }
  .rdg-empty-child-row:hover .glyphicon-plus-sign,
  .rdg-empty-child-row:hover a {
      color: green
  }
  .rdg-child-row-btn .glyphicon-remove-sign:hover {
      color: red
  }
  .last-column .cell-tooltip-text {
      right: 100%;
      left: 0!important
  }
  .radio-custom,
  .react-grid-checkbox {
      opacity: 0;
      position: absolute
  }
  .radio-custom,
  .radio-custom-label,
  .react-grid-checkbox,
  .react-grid-checkbox-label {
      display: inline-block;
      vertical-align: middle;
      cursor: pointer
  }
  .radio-custom-label,
  .react-grid-checkbox-label {
      position: relative
  }
  .radio-custom+.radio-custom-label:before,
  .react-grid-checkbox+.react-grid-checkbox-label:before {
      content: "";
      background:#fff;
      border:2px solid #ddd;
      display:inline-block;
      vertical-align:middle;
      width:13px !important;
      height:13px !important;
      text-align:center;
      margin-top:5px !important;
  }
  .react-grid-checkbox:checked+.react-grid-checkbox-label:before {
      background: #556775 !important;
      box-shadow: inset 0 0 0 0px #fff  !important
  }
  .radio-custom:focus+.radio-custom-label,
  .react-grid-checkbox:focus+.react-grid-checkbox-label {
      outline: 1px solid #ddd
  }
  .react-grid-HeaderCell input[type=checkbox] {
      z-index: 99999
  }
  .react-grid-HeaderCell>.react-grid-checkbox-container {
      padding: 0 10px;
      height: 100%
  }
  .react-grid-HeaderCell>.react-grid-checkbox-container>.react-grid-checkbox-label {
      margin: 0;
      position: relative;
      top: 50%;
      transform: translateY(-50%)
  }
  .radio-custom+.radio-custom-label:before {
      border-radius: 50%
  }
  .radio-custom:checked+.radio-custom-label:before {
      background: #ccc;
      box-shadow: inset 0 0 0 4px #fff
  }
  .checkbox-align {
      text-align: center
  }
  .react-grid-Container {
      clear: both;
      margin-top: 0;
      padding: 0;
      width: 100% !important;
  }
  .react-grid-Main {
      background-color: #fff;
      color: inherit;
      padding: 0;
      outline: 1px solid #e7eaec;
      clear: both
  }
  .react-grid-Grid {
      border: 1px solid #ddd
  }
  .react-grid-Canvas,
  .react-grid-Grid {
      background-color: #fff;
      width: 100% !important;
  }
  .react-grid-Cell input.editor-main,
  select.editor-main {
      display: block;
      width: 100%;
      height: 34px;
      padding: 6px 12px;
      font-size: 14px;
      line-height: 1.42857143;
      color: #555;
      background-color: #fff;
      background-image: none;
      border: 1px solid #ccc;
      border-radius: 4px;
      -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
      box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075)
  }
  input.editor-main:focus,
  select.editor-main:focus {
      border-color: #66afe9;
      border: 2px solid #66afe9;
      background: #eee;
      border-radius: 4px
  }
  .react-grid-Cell input.editor-main::-moz-placeholder,
  select.editor-main::-moz-placeholder {
      color: #999;
      opacity: 1
  }
  .react-grid-Cell input.editor-main:-ms-input-placeholder,
  select.editor-main:-ms-input-placeholder {
      color: #999
  }
  .react-grid-Cell input.editor-main::-webkit-input-placeholder,
  select.editor-main::-webkit-input-placeholder {
      color: #999
  }
  .react-grid-Cell input.editor-main[disabled],
  .react-grid-Cell input.editor-main[readonly],
  fieldset[disabled] .react-grid-Cell input.editor-main,
  fieldset[disabled] select.editor-main,
  select.editor-main[disabled],
  select.editor-main[readonly] {
      cursor: not-allowed;
      background-color: #eee;
      opacity: 1
  }
  textarea.react-grid-Cell input.editor-main,
  textareaselect.editor-main {
      height: auto
  }
  .react-grid-ScrollShim {
      z-index: 10002
  }
    .react-grid-Header {
      box-shadow: 0 0 4px 0 #ddd;
      background: #ffffff !important;
  }
  .react-grid-Header--resizing {
      cursor: ew-resize
  }
  .react-grid-HeaderCell,
  .react-grid-HeaderRow {
      -webkit-user-select: none;
      -moz-user-select: none;
      -ms-user-select: none;
      user-select: none
  }
  .react-grid-HeaderCell {
      background: #f9f9f9;
      padding: 0px 8px 0px 8px !important;
      font-weight: 700;
      border-right: 1px solid #ddd;
      border-bottom: 1px solid #ddd
  }
  .react-grid-HeaderCell__value {
      white-space: nowrap;
      text-overflow: ellipsis;
      overflow: hidden;
      position: relative;
      top: 50%;
      transform: translateY(-50%)
  }
  .react-grid-HeaderCell__resizeHandle:hover {
      cursor: ew-resize;
      background: #ddd
  }
  .react-grid-HeaderCell--locked:last-of-type {
      box-shadow: none
  }
  .react-grid-HeaderCell--resizing .react-grid-HeaderCell__resizeHandle {
      background: #ddd
  }
  .react-grid-HeaderCell__draggable {
      cursor: col-resize
  }
  .rdg-can-drop>.react-grid-HeaderCell {
      background: #ececec
  }
  .react-grid-HeaderCell .Select {
      max-height: 30px;
      font-size: 12px;
      font-weight: 400
  }
  .react-grid-HeaderCell .Select-control {
      max-height: 30px;
      border: 1px solid #ccc;
      color: #555;
      border-radius: 3px
  }
  .react-grid-HeaderCell .is-focused:not(.is-open)>.Select-control {
      border-color: #66afe9;
      outline: 0;
      -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 8px rgba(102, 175, 233, .6);
      box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 8px rgba(102, 175, 233, .6)
  }
  .react-grid-HeaderCell .Select-control .Select-placeholder {
      line-height: 20px;
      color: #999;
      padding: 4px
  }
  .react-grid-HeaderCell .Select-control .Select-input {
      max-height: 28px;
      padding: 4px;
      margin-left: 0
  }
  .react-grid-HeaderCell .Select-control .Select-input input {
      padding: 0;
      height: 100%
  }
  .react-grid-HeaderCell .Select-control .Select-arrow-zone .Select-arrow {
      border-color: gray transparent transparent;
      border-width: 4px 4px 2.5px
  }
  .react-grid-HeaderCell .Select-control .Select-value {
      padding: 4px;
      line-height: 20px!important
  }
  .react-grid-HeaderCell .Select--multi .Select-control .Select-value {
      padding: 0;
      line-height: 16px!important;
      max-height: 20px
  }
  .react-grid-HeaderCell .Select--multi .Select-control .Select-value .Select-value-icon,
  .react-grid-HeaderCell .Select--multi .Select-control .Select-value .css-12jo7m5 {
      max-height: 20px
  }
  .react-grid-HeaderCell .Select-control .Select-value .css-12jo7m5 {
      color: #555!important
  }
  .react-grid-HeaderCell .Select-menu-outer .Select-option {
      padding: 4px;
      line-height: 20px
  }
  .react-grid-HeaderCell .Select-menu-outer .Select-menu .Select-option.is-focused,
  .react-grid-HeaderCell .Select-menu-outer .Select-menu .Select-option.is-selected {
      color: #555
  }
    .react-grid-Row.row-context-menu .react-grid-Cell,
  .react-grid-Row:hover .react-grid-Cell {
      background-color: transparent !important;
  }
  /*.react-grid-Row--odd:hover .react-grid-Cell {
      background-color: #fafafa !important;
  }*/
  .react-grid-Row:hover .rdg-row-index {
      display: none
  }
  .react-grid-Row:hover .rdg-actions-checkbox {
      display: none !important;
  }
  .react-grid-Row:hover .rdg-drag-row-handle {
      cursor: move;
      cursor: grab;
      cursor: -moz-grab;
      cursor: -webkit-grab;
      width: 12px;
      height: 30px;
      margin-left: 0;
      /*background-image: url(\"data:image/svg+xml;base64, PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIj8+Cjxzdmcgd2lkdGg9IjlweCIgaGVpZ2h0PSIyOXB4IiB2aWV3Qm94PSIwIDAgOSAyOSIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIj4KICAgIDwhLS0gR2VuZXJhdG9yOiBTa2V0Y2ggMzkgKDMxNjY3KSAtIGh0dHA6Ly93d3cuYm9oZW1pYW5jb2RpbmcuY29tL3NrZXRjaCAtLT4KICAgIDx0aXRsZT5kcmFnIGljb248L3RpdGxlPgogICAgPGRlc2M+Q3JlYXRlZCB3aXRoIFNrZXRjaC48L2Rlc2M+CiAgICA8ZGVmcz48L2RlZnM+CiAgICA8ZyBpZD0iQWN0dWFsaXNhdGlvbi12MiIgc3Ryb2tlPSJub25lIiBzdHJva2Utd2lkdGg9IjEiIGZpbGw9Im5vbmUiIGZpbGwtcnVsZT0iZXZlbm9kZCI+CiAgICAgICAgPGcgaWQ9IkRlc2t0b3AiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0xNS4wMDAwMDAsIC0yNjIuMDAwMDAwKSIgZmlsbD0iI0Q4RDhEOCI+CiAgICAgICAgICAgIDxnIGlkPSJJbnRlcmFjdGlvbnMiIHRyYW5zZm9ybT0idHJhbnNsYXRlKDE1LjAwMDAwMCwgMjU4LjAwMDAwMCkiPgogICAgICAgICAgICAgICAgPGcgaWQ9IlJvdy1Db250cm9scyIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMC4wMDAwMDAsIDIuMDAwMDAwKSI+CiAgICAgICAgICAgICAgICAgICAgPGcgaWQ9ImRyYWctaWNvbiIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMC4wMDAwMDAsIDIuMDAwMDAwKSI+CiAgICAgICAgICAgICAgICAgICAgICAgIDxjaXJjbGUgaWQ9Ik92YWwtMzAiIGN4PSIyIiBjeT0iMiIgcj0iMiI+PC9jaXJjbGU+CiAgICAgICAgICAgICAgICAgICAgICAgIDxjaXJjbGUgaWQ9Ik92YWwtMzAiIGN4PSI3IiBjeT0iMiIgcj0iMiI+PC9jaXJjbGU+CiAgICAgICAgICAgICAgICAgICAgICAgIDxjaXJjbGUgaWQ9Ik92YWwtMzAiIGN4PSIyIiBjeT0iNyIgcj0iMiI+PC9jaXJjbGU+CiAgICAgICAgICAgICAgICAgICAgICAgIDxjaXJjbGUgaWQ9Ik92YWwtMzAiIGN4PSI3IiBjeT0iNyIgcj0iMiI+PC9jaXJjbGU+CiAgICAgICAgICAgICAgICAgICAgICAgIDxjaXJjbGUgaWQ9Ik92YWwtMzAiIGN4PSIyIiBjeT0iMTIiIHI9IjIiPjwvY2lyY2xlPgogICAgICAgICAgICAgICAgICAgICAgICA8Y2lyY2xlIGlkPSJPdmFsLTMwIiBjeD0iNyIgY3k9IjEyIiByPSIyIj48L2NpcmNsZT4KICAgICAgICAgICAgICAgICAgICAgICAgPGNpcmNsZSBpZD0iT3ZhbC0zMCIgY3g9IjIiIGN5PSIxNyIgcj0iMiI+PC9jaXJjbGU+CiAgICAgICAgICAgICAgICAgICAgICAgIDxjaXJjbGUgaWQ9Ik92YWwtMzAiIGN4PSI3IiBjeT0iMTciIHI9IjIiPjwvY2lyY2xlPgogICAgICAgICAgICAgICAgICAgICAgICA8Y2lyY2xlIGlkPSJPdmFsLTMwIiBjeD0iMiIgY3k9IjIyIiByPSIyIj48L2NpcmNsZT4KICAgICAgICAgICAgICAgICAgICAgICAgPGNpcmNsZSBpZD0iT3ZhbC0zMCIgY3g9IjciIGN5PSIyMiIgcj0iMiI+PC9jaXJjbGU+CiAgICAgICAgICAgICAgICAgICAgICAgIDxjaXJjbGUgaWQ9Ik92YWwtMzAiIGN4PSIyIiBjeT0iMjciIHI9IjIiPjwvY2lyY2xlPgogICAgICAgICAgICAgICAgICAgICAgICA8Y2lyY2xlIGlkPSJPdmFsLTMwIiBjeD0iNyIgY3k9IjI3IiByPSIyIj48L2NpcmNsZT4KICAgICAgICAgICAgICAgICAgICA8L2c+CiAgICAgICAgICAgICAgICA8L2c+CiAgICAgICAgICAgIDwvZz4KICAgICAgICA8L2c+CiAgICA8L2c+Cjwvc3ZnPg==\");*/
      background-repeat: no-repeat
  }
  .react-grid-Row.row-selected,
  .react-grid-Row .row-selected {
      /* background-color: #F89270 !important;  ; */
      background-color: #dadada !important;
  }
  .react-grid-row-group .row-expand-icon:hover {
      color: #777
  }
  .react-grid-row-index {
      padding: 0 18px
  }
  .rdg-row-index {
      display: block;
      text-align: center
  }
  .rdg-row-actions-cell {
      padding: 0
  }
  .rdg-actions-checkbox {
      display: none;
      text-align: center
  }
  .rdg-actions-checkbox.selected {
      display: block
  }
  .rdg-dragging {
      cursor: -webkit-grabbing;
      cursor: -moz-grabbing;
      cursor: grabbing
  }
  .rdg-dragged-row {
      border-bottom: 1px solid #000
  }
  
  .drag-handle { display: none; }
  /*** END : React Grid Data Table ***/
  
  .react-grid-Main{
      height: 100%;
  }
      
  .react-grid-Container{
      height: 100%;
  }
  
  .react-grid-Grid{
      min-height: 100% !important;
  }
  
  .react-grid-Canvas{
      height: 100% !important;
  }
  
  .react-grid-HeaderCell-formatter {
      text-overflow: ellipsis;
      white-space: nowrap;
      overflow: hidden;
      font-weight: bold;
      text-transform: capitalize;
      font-size: 14px;
      color: #333;
    }
  
  .rdg-sort-arrow {
        height: 35;
        width: 15;
  }

/* ====================================================
   DataGrid v7 — Enterprise visual enhancements
   ==================================================== */

/* Card wrapper: border + shadow + rounded corners */
.rdg {
  border: 1px solid #dde0e5 !important;
  border-radius: 10px !important;
  overflow: auto !important;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04) !important;
}

/* Scrollbar — clean minimal style */
.rdg::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

.rdg::-webkit-scrollbar-track {
  background: #F7F8FA;
}

.rdg::-webkit-scrollbar-thumb {
  background: #DDE0E5;
  border-radius: 4px;
}

.rdg::-webkit-scrollbar-thumb:hover {
  background: #A8A49C;
}

.rdg::-webkit-scrollbar-corner {
  background: #F7F8FA;
}

/* Firefox scrollbar */
.rdg {
  scrollbar-width: thin;
  scrollbar-color: #DDE0E5 #F7F8FA;
}

/* Header row: surface-2 background matching List-view.html */
.rdg-header-row {
  background: #ECEEF1 !important;
}

.rdg-header-row .rdg-cell {
  background: #ECEEF1 !important;
  color: #a8a49c !important;
  font-size: 11px !important;
  font-family: 'Inter', sans-serif !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.06em !important;
  border-bottom: 1px solid #dde0e5 !important;
  padding: 0 14px !important;
  white-space: nowrap !important;
  user-select: none !important;
  display: flex !important;
  align-items: center !important;
}

/* Header sort cell — flex alignment for sort icon */
.rdg-header-sort-cell {
  display: flex !important;
  align-items: center !important;
  width: 100% !important;
}

.rdg-header-sort-name {
  flex: 1 !important;
}

.rdg-header-row .rdg-cell:hover {
  color: #1a1917 !important;
}

/* Row separator */
.rdg-row .rdg-cell {
  border-bottom: 1px solid #E8EAED !important;
  font-size: 13px !important;
  font-family: 'Inter', sans-serif !important;
  vertical-align: middle !important;
}

/* Row hover */
.rdg-row:hover .rdg-cell {
  background: #F7F8FA !important;
}

/* CSS var overrides for fill-grid (theme-aware) */
.fill-grid {
  --rdg-background-color: #ffffff;
  --rdg-header-background-color: #ECEEF1;
  --rdg-row-hover-background-color: #F7F8FA;
  --rdg-row-selected-background-color: color-mix(in srgb, var(--primary-color, #2563eb) 8%, white);
  --rdg-checkbox-color: var(--primary-color, #2563eb);
  --rdg-border-color: #dde0e5;
  --rdg-summary-border-color: #dde0e5;
  --rdg-selection-color: var(--primary-color, #2563eb);
  --rdg-frozen-cell-box-shadow: 2px 0 5px rgba(0,0,0,0.06);
  --rdg-font-size: 14px;
  max-height: none !important;
}

/* ====================================================
   DataGrid v7 — Cell content styling (List-view.html)
   ==================================================== */

/* ── LINK CELLS (DetailLink renders <a> via react-router <Link>) ── */
/* Company names, emails, phones, URLs — blue accent with medium weight */

.rdg-row .rdg-cell a {
  color: #2563EB !important;
  font-weight: 500 !important;
  text-decoration: none !important;
  transition: color 0.1s !important;
}

.rdg-row .rdg-cell a:hover {
  color: #1D55D4 !important;
  text-decoration: underline !important;
}

/* ── GENERAL CELL TEXT ──────────────────────────────── */
/* Default text color for non-link cells */

.rdg-row .rdg-cell {
  color: #706D65 !important;
  padding: 0 14px !important;
  display: flex !important;
  align-items: center !important;
}

/* Ensure cell content div fills the flex cell (prevents collapse on empty values) */
.rdg-row .rdg-cell > div {
  flex: 1 !important;
  min-width: 0 !important;
}

/* ── INLINE EDIT MODE — revert cell to block layout (matching react18-dev) ── */
/* display:flex on .rdg-cell breaks editor sizing and Popper positioning.
   When a cell contains an editor, switch back to block layout with no padding
   so the editor fills the cell naturally and anchors the Popper correctly.   */
.rdg-row .rdg-cell:has(.sf-auto-complete-root),
.rdg-row .rdg-cell:has(.MuiFormControl-root),
.rdg-row .rdg-cell:has(.MuiTextField-root) {
  display: block !important;
  padding: 0 !important;
  overflow: visible !important;
}

/* Fallback: selected cell also gets editor-friendly layout
   (covers timing edge case where :has() hasn't matched yet) */
.rdg-row .rdg-cell[aria-selected="true"] > div {
  overflow: visible !important;
  white-space: normal !important;
}

/* ── CELL VALUE CONTAINERS ──────────────────────────── */
/* rdg-cell-value class used by DetailLink tree views */

.rdg-cell-value {
  display: flex !important;
  align-items: center !important;
}

/* ── HEADER SORTED COLUMN ──────────────────────────── */
/* Active sort indicator — accent color for the sorted header */

.rdg-header-row .rdg-cell .rdg-header-sort-cell[aria-sort="ascending"] span,
.rdg-header-row .rdg-cell .rdg-header-sort-cell[aria-sort="descending"] span {
  color: var(--primary-color, #2563EB) !important;
}

/* Sorted column header — theme color highlight */
.rdg-header-row .rdg-cell:has(.rdg-header-sorted) {
  color: var(--primary-color, #2563EB) !important;
  background: color-mix(in srgb, var(--primary-color, #2563EB) 8%, #ECEEF1) !important;
}

.rdg-header-sorted .rdg-header-sort-name {
  color: var(--primary-color, #2563EB) !important;
}

.rdg-header-sorted span {
  color: var(--primary-color, #2563EB) !important;
}

/* ── CHECKBOX STYLING ──────────────────────────────── */
/* Match the design's checkbox appearance */

.rdg-checkbox-input:checked + .rdg-checkbox {
  border-color: var(--primary-color, #2563EB) !important;
  background-color: var(--primary-color, #2563EB) !important;
}

.rdg-checkbox {
  border-radius: 4px !important;
  border: 1.5px solid #DDE0E5 !important;
  transition: all 0.15s !important;
}

.rdg-checkbox:hover {
  border-color: color-mix(in srgb, var(--primary-color, #2563EB) 50%, white) !important;
}

/* ── ALL CHECKBOX CELLS — NO OUTLINE WHEN UNCHECKED ── */
.rdg-cell[aria-selected="true"]:has(.rdg-checkbox-input:not(:checked)) {
  outline: none !important;
}

/* ── ROW SELECTION HIGHLIGHT ───────────────────────── */

.rdg-row[aria-selected="true"] .rdg-cell {
  background: color-mix(in srgb, var(--primary-color, #2563EB) 6%, white) !important;
}

/* ── ROW HOVER ACCENT ──────────────────────────────── */
/* Subtle left accent line on hover — matching List-view.html tr.row:hover */

.rdg-row:hover .rdg-cell:first-child {
  box-shadow: inset 3px 0 0 var(--primary-color, #2563EB) !important;
}

/* ── DATE CELLS ────────────────────────────────────── */
/* Date/time spans — muted color matching List-view.html .date-cell */

.rdg-row .rdg-cell span[title*="/"],
.rdg-row .rdg-cell span[title*="-"] {
  font-size: 13px !important;
}

/* ── STATUS CHIP BADGES ───────────────────────────── */
/* Colored pill badges for t_status fields — matches List-view.html .status-badge */

.sf-status-chip {
  display: inline-flex !important;
  align-items: center !important;
  gap: 5px !important;
  padding: 2px 9px !important;
  border-radius: 20px !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  white-space: nowrap !important;
  line-height: 1.6 !important;
}

.sf-status-chip-dot {
  width: 5px !important;
  height: 5px !important;
  border-radius: 50% !important;
  flex-shrink: 0 !important;
}

/* Chip inside a link — underline on hover to indicate clickability */
.sf-status-chip-link {
  cursor: pointer !important;
}

.sf-status-chip-link:hover {
  text-decoration: underline !important;
  text-underline-offset: 2px !important;
}

/* ── CELL TEXT ELLIPSIS ──────────────────────────────── */
/* Cell children must fill flex parent width and truncate long text */
/* Exclude status chips (.sf-status-chip) which have their own layout */

.rdg-row .rdg-cell > span:not(.sf-status-chip) {
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  min-width: 0 !important;
  flex: 1 1 auto !important;
}

.rdg-row .rdg-cell > div:not(.rdg-checkbox-label-container) {
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  min-width: 0 !important;
  width: 100% !important;
  flex: 1 1 auto !important;
}

/* ── INLINE EDIT — CELL OVERRIDE ─────────────────────── */
/* When a cell is in edit mode, remove all constraints so the
   editor and its Popper can render at the correct size/position */

.rdg .rdg-cell[aria-selected="true"] {
  overflow: visible !important;
}

/* Editor wrapper div — override ellipsis rules */
.rdg-row .rdg-cell:has(.sf-auto-complete-root) > div,
.rdg-row .rdg-cell:has(.MuiFormControl-root) > div {
  overflow: visible !important;
  white-space: normal !important;
  text-overflow: unset !important;
}

/* Editor containers must fill the cell */
.rdg-cell .sf-auto-complete-root {
  width: 100% !important;
}

.rdg-cell .sf-auto-complete-root .auto-complete-area {
  width: 100% !important;
}

.rdg-cell .MuiFormControl-root {
  width: 100% !important;
  min-width: 0 !important;
}

/* Autocomplete Popper — rendered at document.body via portal */
.auto-complete-poper-container {
  min-width: 140px !important;
}

/* MUI elements inside grid cells — z-index above grid rows */
.rdg-cell .MuiSelect-root,
.rdg-cell .MuiAutocomplete-popper,
.rdg-cell .MuiPopover-root {
  z-index: 1300 !important;
}

/* Grid cell in edit mode — font and input styling */
.rdg-cell .sf-auto-complete-root input {
  font-size: 13px !important;
}

.rdg-cell .MuiSelect-select {
  font-size: 13px !important;
}