.filter-title {
  background-color: $color-primary;
  padding: 2px;
  color: $color-primary-fg;
  font-size: 13px;
}

.sql-icon-lg {
  font-size: 0.875rem;
  line-height: 1.3;
}

.sql_textarea {
  height: 100%;
}

.sql_textarea .CodeMirror-scroll {
  z-index: 0;
}

.connection_status {
  background-color: $sql-title-bg;
  color: $sql-title-fg;
  border-right: $border-width solid $border-color;
}

.editor-title {
  padding: $sql-title-padding;
  background: $sql-title-bg;
  color: $sql-title-fg;
}

.connection-info {
  background: $sql-title-bg;
  color: $sql-title-fg;
  width:100%;
  display: inherit;
}

.conn-info-dd {
  padding-top: 0.3em;
  padding-left: 0.2em;
  cursor: pointer;
}

.connection-data {
  display: inherit;
  cursor: pointer;
  width: auto;
}


#editor-panel {
  z-index: 0;
  position: absolute;
  top: $sql-editor-panel-top;
  bottom: 0;
  left: 0;
  right: 0;
}

#editor-panel .CodeMirror-activeline-background {
  background: $color-primary-light;
}


.ajs-body .warn-icon {
  color: $color-warning;
  font-size: 2em;
  margin-right: 20px;
  padding-top: 10px;
}

.connection_status_wrapper {
  width: 100%;
  border-top: $panel-border;
  border-bottom: $panel-border;
}

li.CodeMirror-hint-active {
  background: $color-primary-light;
  color: $color-primary-fg;
}

.filter-container {
  position: relative;
  background-color: $color-bg;
  border: 1px solid $border-color;
  padding-bottom: 30px;
  top: 10px;
  z-index: 1;
  margin: auto;
  width: 60%;
}

.limit-enabled {
  background-color: $color-bg;
}



.CodeMirror-hint {
  margin: 0;
  padding: 0 4px;
  border-radius: 2px;
  overflow: hidden;
  white-space: pre;
  color: $color-fg;
  cursor: pointer;
}

.grid-header .ui-icon.ui-state-hover {
  background-color: $color-bg;
}

.slick-cell.selected span[data-cell-type="row-header-selector"] {
  color: $color-primary-fg;
}

.slick-cell.cell-move-handle {
  font-weight: bold;
  text-align: right;
  border-right: solid  $border-color;
  background: $color-gray-lighter;
  cursor: move;
}

.cell-move-handle:hover {
  background: $color-gray-light;
}

.slick-row.selected .cell-move-handle {
  background: $color-warning-light;
}

.slick-row.complete {
  background-color: $color-success-light;
  color:  $color-gray-dark;
}

.cell-selection {
  border-right-color: $border-color;
  border-right-style: solid;
  background: $color-gray-lighter;
  color:  $color-gray;
  text-align: right;
  font-size: 10px;
}

#datagrid .slick-header .slick-header-columns {
  background: $sql-grid-title-cell-bg;
  color: $sql-grid-title-cell-fg;
  height: 40px;
  border-bottom: $panel-border;
}

#datagrid .slick-header .slick-header-column.ui-state-default {
  padding: 4px 0 3px 6px;
  border-bottom: $panel-border;
  border-right: $panel-border;
}

.slick-row:hover .slick-cell{
  border-top: $table-hover-border;
  border-bottom: $table-hover-border;
  background-color: $table-hover-bg-color;
}

#datagrid .slick-header .slick-header-column.selected {
  background-color: $color-primary;
}
.slick-row .slick-cell {
  border-bottom: $panel-border;
  border-right: $panel-border;
  z-index: 0;
}

#datagrid {
  background: none;
  background-color: $datagrid-bg;
}

.ui-widget-content.slick-row {
  &.even,  &.odd {
    background: none;
    background-color: $table-bg;
  }
}

/* Remove active cell border */
.slick-cell.active {
  border: 1px solid transparent;
  border-right: 1px solid $color-gray-light;
  border-bottom-color: $color-gray-light;
}

/* To highlight all newly inserted rows */
.grid-canvas .new_row {
  background: $color-success-light !important;
}

/* To highlight all the updated rows */
.grid-canvas .updated_row {
  background: $color-gray-lighter;
}

/* To highlight row at fault */
.grid-canvas .new_row.error, .grid-canvas .updated_row.error {
  background: $color-danger-light !important;
}

/* Disabled row */
.grid-canvas .disabled_row {
  background: $color-gray-lighter;
}

/* Disabled cell */
.grid-canvas .disabled_cell {
  color: $text-muted;
}

/* Highlighted (modified or new) cell */
.grid-canvas .highlighted_grid_cells {
  background: $color-gray-lighter;
  font-weight: bold;
}


/* Override selected row color */
#datagrid .slick-row .slick-cell.selected {
    background-color: $table-bg-selected;
    color: $datagrid-selected-color;
}

/* color the first column */

#datagrid .slick-row {
    .slick-cell {
        background-color: $sql-grid-data-cell-bg;
        color: $sql-grid-data-cell-fg;
    }

    .slick-cell.l0.r0 {
        background-color: $sql-grid-title-cell-bg;
        color: $sql-grid-title-cell-fg;
    }
}

#datagrid div.slick-header.ui-state-default {
  background-color: $sql-grid-title-cell-bg;
  color: $sql-grid-title-cell-fg;
  border-bottom: none;
  border-right: none;
  border-top: none;
}

#datagrid .slick-row .slick-cell.l0.r0.selected {
  background-color: $color-primary;
  color: $color-primary-fg;
}

#datagrid .slick-row > .slick-cell:not(.l0):not(.r0).selected {
  background-color: $table-hover-bg-color;
  border-top: $table-hover-border;
  border-bottom: $table-hover-border;
}

.pg-text-editor {
  z-index:10000;
  position:absolute;
  background: $color-bg;
  padding: 0.25rem;
  border: $panel-border;
  box-shadow: $dropdown-box-shadow;


  & .pg-textarea {
    width:250px;
    height:80px;
    border:0;
    outline:0;
    resize: both;
  }

  & .pg-text-invalid {
    background: $color-danger-lighter;
  }
}

.sql-editor-message {
  white-space:pre-wrap;
  font-family: $font-family-editor;
  padding-top: 5px;
  padding-left: 10px;
  overflow: auto;
  height: 100%;
  font-size: 0.925em;
  -webkit-user-select: text;
  -moz-user-select: text;
  -ms-user-select: text;
  user-select: text;
}

.view-geometry-property-table .td-disabled{
  color: $color-gray-lighter;
}

/* For leaflet map background */
.geometry-viewer-container-plain-background {
  background: $color-bg;
}


div.strikeout:before {
  content: " ";
  position: absolute;
  top: 50%;
  left: 0;
  border-top: 1px solid $color-danger;
  width: 100%;
  font-weight: 900;
}

div.strikeout:after {
  content: "\00B7";
  font-size: 1px;
  font-weight: 900;
}

.sql-scratch {
  width: 100%;
  height: 100%;
  box-sizing: border-box;
  overflow-y: hidden;

  textarea {
    width: 100%;
    height: 100%;
    box-sizing: border-box;
    border: none;
    resize: none;
  }
}

.connection_status .obtaining-conn {
  background-image: $loader-icon-small !important;
  background-position: center center;
  background-repeat: no-repeat;
  &:before {
    content:'';
  }
  min-width: 50%;
  min-height: 100%;
}

.sql-editor-grid-container {
  height: 100%;
  overflow: auto;

  .ui-widget-content {
    background-color: $input-bg;
    color: $input-color;
  }

  .ui-state-default {
    color: $color-fg;
  }
}

.sql-editor-grid-container.has-no-footer {
  height: 100%;
}

.selected-connection {
  background-color: $color-primary-light;
}

/* Setting it to hardcoded white as the SVG generated is having white bg
 * Need to check what can be done.
 */
