$color-editable: #fff;
$color-readonly: #ddd;
$color-required: lightyellow;
$color-invalid: lightcoral;
$color-can-drop: lightgray;
$color-is-over: #31708f;
$colo-bs-primary: #337ab7;
$colo-selected-border: #0dcaf0;
$color-default: #777;

.bg-bs-primary {
  background-color: $colo-bs-primary !important;
}

.icon_generic_nav {
  font-family: FontAwesome, Helvetica, Arial, sans-serif !important;
}

.field_required {
  background-color: $color-required;
}

.template_panel_heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 5px 10px 5px 10px !important;
}

.panel_generic_properties {
  border-left: unset !important;
  border-right: unset !important;
  border-bottom: unset !important;
  line-height: 10px !important;
  box-shadow: unset !important;
  margin-bottom: unset !important;
  font-size: small;
  .panel-title {
    font-weight: bold;
    }
  .default_style {
    font-size: 14px;
    line-height: normal;
    }
}

.panel_generic_properties_body {
  padding-left: unset !important;
  padding-right: unset !important;
}

@mixin generic_panel_header {
  font-weight: bold;
  padding: 10px 0px !important;
}

.panel_generic_heading {
  @include generic_panel_header;
}

.panel_generic_heading_bu {
  @include generic_panel_header;
  text-decoration: underline;
}

.panel_generic_heading_bui {
  @include generic_panel_header;
  text-decoration: underline;
  font-style: italic;
}

.text_generic_properties {
  .dummy {
    background-color: unset !important;
    border: unset !important;
    box-shadow: unset !important;
  }
  .editable {
    background-color: $color-editable;
  }
  .readonly {
    background-color: $color-readonly;
  }
  .required {
    background-color: $color-required;
  }
  input:invalid {
    border: 1px solid $color-invalid;
  }
}

.select_generic_properties_editable {
  .Select-control {
    background-color: $color-editable;
  }
}

.select_generic_properties_readonly {
  .Select-control {
    background-color: $color-readonly;
  }
}

.select_generic_properties_required {
  .Select-control {
    background-color: $color-required;
  }
}

.drop_generic_properties {
  display: flex;
  align-items: center;
  .target {
    height: 100%;
    width: 100%;
    margin: 0px 10px 0px 10px;
    display: inline-block;
    .indicator {
      font-size: x-large;
    }
    .s-img {
      display: flex;
      img {
        height: 4vh;
        width: 4vw;
      }
    }
    .data {
      font-size: medium;
      line-height: normal !important;
      text-overflow: ellipsis;
      overflow: hidden;
      white-space: nowrap;
      align-self: center;
      width: 100%;
    }
    &.can-drop {
      .indicator {
        border: 2px dashed $color-can-drop;
        color: $color-can-drop;
      }
      .data {
        border: 2px dashed $color-can-drop;
        color: $color-can-drop;
      }
    }
    &.is-over {
      .indicator {
        border: 2px dashed $color-is-over;
        color: $color-is-over;
      }
      .data {
        border: 2px dashed $color-is-over;
        color: $color-is-over;
      }
    }
  }
  .btn_del {
    float: right;
    align-self: center;
  }
  .sample_radios {
    font-size: xx-small;
    line-height: 2;
    display: inline-flex;
    padding-right: 5px;
  }
}

.generic_criteria_modal {
  display: block;
  padding-left: 0px;
  top: 45% !important;
  width: 75vw !important;
}

.search_criteria_mof {
  .modal_body {
    max-height: 70vh;
    height: 70vh;
    overflow: auto;
  }
  .btn_footer {
    margin-top: 10px;
  }
}

.g-ds-note {
  color: black !important;
  float: left !important;
  text-align: left !important;
  font-weight: lighter !important;
  .g-ds-title { text-decoration: underline; font-weight: 700; line-height: 1.5; }
}

.g_input_group {
  padding: 6px 6px !important;
}

.g_input_group_label {
  background-color: lightgray !important;
  width: unset !important;
  white-space: nowrap !important;
  padding: 6px 6px !important;
}

.g_col_w {
  width: 20% !important;
}

.generic_grid {
  display: block;
  > div {
    display: flex;
    flex-wrap: nowrap;
  }
}

@mixin generic_grid_cell {
  width: 100%;
  margin: 6px 0px 6px 6px;
  text-align: center;
  line-height: 15px;
  align-self: center;
}

.generic_grid_header {
  @include generic_grid_cell;
  font-weight: bolder;
  font-family: 'Franklin Gothic Medium', 'Arial Narrow', Arial, sans-serif;
}

.generic_grid_row {
  @include generic_grid_cell;
}

@mixin generic_version_badge {
  background-color: #777;
  display: inline-block;
  padding: 0.35em 0.65em;
  font-size: 0.75em;
  text-align: center;
  vertical-align: baseline;
  white-space: nowrap;
  border-radius: 0.5rem;
  color: white;
}

.generic_version {
  @include generic_version_badge;
}

.generic_version_draft {
  @include generic_version_badge;
  background-color: unset;
  color: black;
}

.generic_version_block {
  display: block;
  padding: 6px 10px;
  margin: 10px;
  border-radius: 10px;
  border: thin solid lightgray;
  font-size: 1.2em;
  > div {
    display: flex;
    flex-wrap: nowrap;
  }
}

.generic_block_select {
  // border-color: $colo-selected-border;
  border-width: medium;
  border-style: groove;
}

.generic_panel_none {
  border-color: #ddd !important;
}

.generic_tbl_chks {
  line-height: 1em;
  margin: 0px -10px !important;
  > label {
    display: inline-flex;
    align-content: center;
    align-items: center;
    > input {
      margin-top: 0px;
    }
  }
}

.generic_btn_default {
  background-color: $color-default !important;
  color: $color-editable !important;
}

.drop_generic_table_wrap {
  .target {
    .s-img {
      position: relative;
      border: 1px solid transparent;
      img {
        height: 4vw;
        width: 4vw;
      }
      .del_btn {
        position: absolute;
        top: 0%;
        left: 0%;
      }
      .link_btn {
        position: absolute;
        bottom: 0%;
        left: 0%;
      }
    }
    .s-img:hover {
      border: 1px solid $colo-selected-border;
    }
    .data {
      font-size: unset;
      white-space: unset;
      text-align: left;
    }
    &.can-drop {
      .s-img {
        border: 2px dashed $color-can-drop;
        color: $color-can-drop;
      }
    }
    &.is-over {
      .s-img {
        border: 2px dashed $color-is-over;
        color: $color-is-over;
      }
    }
  }
}

.generic_grid_img {
  border: $color-readonly solid thin;
}

.generic_sam_options {
  display: flex;
  flex-direction: column;
  text-align: left;
  font-size: x-small;
  .radio {
    margin-top: unset;
    margin-bottom: unset;
  }
}

.generic_files {
  padding: 0px 5px !important;
  > div > div > div {
    text-align: left;
    align-self: center;
    .form-group {
      margin-bottom: 0px;
    }
  }
}

.grid-btn-none {
  font-size: large;
  color: white;
}

.generic_grid_dnd {
  .dnd-btn {
    font-size: large;
    span {
      cursor: move;
    }
  }
  &.can-drop {
    border: 2px dashed $color-can-drop;
    color: $color-can-drop;
  }
  &.is-over {
    border: 2px dashed $color-is-over;
    color: $color-is-over;
  }
  &.is-dragging {
    opacity: 0.2;
  }
}


.generic_layer_modal {
  > .layer_header {
    background-color: white;
    color: $colo-bs-primary;
    font-size: 20px;
  }
}

.generic_layer_column {
  @include generic_grid_cell;
  border: 1px solid $colo-bs-primary;
  background-color: white;
  margin: 5px;
  padding: 10px;
  color: $colo-bs-primary;
  border-radius: 4px;
}

.generic_layer_column > div:first-child {
  display: flex;
}

.generic_layer_column > div:first-child > button {
  float: right;
  border-radius: 50%;
}

.generic_layer_column > div:first-child > div {
  width: 100%;
}

.generic_wf_modal {
  max-height: 100%;
  overflow: auto;
}

.generic_wf_modal > div:first-child {
  height: 85vh;
  width: 100%;
}

.flow_view_draggable {
  z-index: 100;
  position: absolute;
  top: 12%;
  left: 10%;
  .panel-body {
    padding: 5px;
    > .body_bg {
      max-height: 100%;
      overflow: auto;
      > .body_canvas {
        resize: both;
        overflow: auto;
        height: 70vh;
        width: 40vw;
        min-height: 250px;
        min-width: 300px;
        max-width: 1600px;
        max-height: 840px;
      }
    }
  }
}

.generic-ds-panel {
  border: none !important;
  > .panel-body {
    position: relative;
    min-height: 260px;
    overflow-y: unset !important;
    padding: 0px !important;
  }
}

.generic_segments_repo {
  padding: 10px;
  background-color: white;
  margin-bottom: 6px;
}

.generic-add-analysis {
  background-color: unset;
  position: sticky;
  top: 0px;
  z-index: 10;
}

.custom-nav-link {
  color: #007bff !important;
  text-decoration: none;
}

.custom-nav-link:hover {
  text-decoration: underline;
  color: #0056b3;
}