.affi_hidden {
  display: none !important;
}

.cp-color-picker {
  z-index: 999999;
}

.affi-tag {
  padding: 2px 10px;
  border-radius: 5px;
  font-size: 15px;
  z-index: 9;
  position: relative;
}

.affi_item_icon {
  position: relative;
  bottom: unset;
  left: unset;
  margin: 0 !important;
  background: transparent;
}

.affi-email-event-row {
  margin-bottom: 20px;

  .title {
    display: flex;
    align-items: center;

    .header {
      margin: 0;
    }

    .affi_icon_status_email_event {
      margin-left: 10px;
    }
  }
}

.affi_wrap_icons {
  box-shadow: 0 1px 2px 0 rgb(34 36 38 / 15%);
  padding: 15px;
  border-radius: 6px;
  border: 1px solid rgba(34, 36, 38, 0.15);
  display: flex;
  flex-wrap: wrap;

  .affi_choose_icon {
    position: relative;
    font-size: 20px !important;
    padding: 5px !important;
    margin: 5px !important;
    opacity: 0.4;
    display: flex !important;
    justify-content: center;
    align-items: center;
    border: solid 1px transparent !important;
    border-radius: 4px !important;

    &.affi_icon_selected {
      background: unset;
      opacity: 1;
      transform: scale3d(1.2, 1.2, 1.2);
      border: solid 1px #000000 !important;
    }

    .affi_item_icon {
      left: unset !important;
    }
  }
}

#affi-settings-form {
  padding-right: 20px;

  * {
    box-sizing: border-box;
  }

  select {
    max-width: 100%;
  }

  .affi-rank-update-time {
    display: none;
  }

  .affi-rank-update-now {
    margin-bottom: 8px;
  }

  .affi-setting-hidden {
    display: none;
  }

  .affi-field-line-flex {
    display: flex;
    margin-bottom: 5px;

    :first-child {
      align-content: space-evenly;
    }

    input {
      width: 80px;
      margin: 0 10px;
    }

    .affi-st-inline-suffix {
      align-content: space-evenly;
    }
  }
}

* {
  box-sizing: border-box;
}

.affi_wrap_admin_page {
  padding-right: 20px;
  position: relative;

  .affi_content_wrapper {
    border: none;
    box-shadow: 0 0 3px 0 #a4b0be;
    border-radius: 5px;
    padding: 15px;
    box-sizing: border-box;
    background-color: #fff;
  }
}

.affi-wrap-filter {
  display: flex;
  margin: 0 -10px;

  .filters-group {
    padding: 0 10px;
    flex: 0 0 200px;

    .input-group-prepend {
      font-weight: bold;

    }

    .form-control {
      width: 100%;
    }
  }
}

button.dt-button:hover:not(.disabled),
div.dt-button:hover:not(.disabled),
a.dt-button:hover:not(.disabled),
input.dt-button:hover:not(.disabled),
button.dt-button:focus:not(.disabled),
div.dt-button:focus:not(.disabled),
a.dt-button:focus:not(.disabled),
input.dt-button:focus:not(.disabled),
button.dt-button:active:not(.disabled):hover:not(.disabled),
button.dt-button.active:not(.disabled):hover:not(.disabled),
div.dt-button:active:not(.disabled):hover:not(.disabled),
div.dt-button.active:not(.disabled):hover:not(.disabled),
a.dt-button:active:not(.disabled):hover:not(.disabled),
a.dt-button.active:not(.disabled):hover:not(.disabled),
input.dt-button:active:not(.disabled):hover:not(.disabled),
input.dt-button.active:not(.disabled):hover:not(.disabled) {
  border: unset !important;
  background-color: #198f35;
  color: #fff;
  text-shadow: none;
}

button.dt-button:hover:not(.disabled),
div.dt-button:hover:not(.disabled),
a.dt-button:hover:not(.disabled),
input.dt-button:hover:not(.disabled) {

}

.affi-edit-container-wrap {

  .affi-rank-name-wrap {
    margin-bottom: 20px;
  }

  .affi-setting-label {
    align-self: center;
  }

  .affi-rank-detail-line-label {
    align-self: center;
  }
}

.affi-affiliates-tabblenav-form {

  .toplevel_page_affi-affiliates-setting {

    .affi-row-actions {

      a {
        cursor: pointer;
      }
    }

    .column-earning {

      .affi-user-balance-payout {
        display: none;
      }

      &:hover {

        .affi-user-balance-payout {
          display: block;
        }
      }
    }

    .affi-approved-status-label {
      width: fit-content;
      padding: 2px 10px;
      border-radius: 5px;
      color: #5b841b;
      background-color: #c6e1c6;
    }

    .affi-pending-status-label {
      width: fit-content;
      padding: 2px 10px;
      border-radius: 5px;
      color: #94660c;
      background-color: #f8dda7;
    }

    .affi-reject-status-label {
      width: fit-content;
      padding: 2px 10px;
      border-radius: 5px;
      color: #f1f1f1;
      background-color: #f5180b;
    }
  }
}

.vi-ui.modals {

  .affi-affiliates-popup-wrap {
    box-sizing: border-box !important;
  }

  .affi-hidden {
    display: none;
  }

  .select2-search__field {
    width: 100% !important;
  }

  .select2-container.select2-container--default {
    width: 100% !important;
    min-width: 100% !important;
    margin-left: 0 !important;
    line-height: 0 !important;
  }

  .select2-selection.select2-selection--multiple {
    margin-left: 0 !important;
  }

  .select2-selection.select2-selection--single {
    margin-left: 0 !important;
    height: unset !important;
    border-color: #dedede;
  }

  .select2-selection__choice__remove {
    margin-left: 0 !important;
  }

  .select2-selection__placeholder {
    margin-left: 0 !important;
  }

  .select2-selection__rendered .select2-search.select2-search--inline {
    width: 100%;
  }

  .select2-selection__rendered#select2-affi_set_user_input-container {
    padding-top: 8px;
    padding-bottom: 8px;
  }

  .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 100%;
    padding: 0.9em;
    width: 40px;
  }

  #select2-bopobb_bpi_default_product-container {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

}

.affi-rank-tabblenav-form {

  .affi-rank-badge-table {
    position: relative;
    display: inline-flex;
    width: 50px;
    height: 50px;
    cursor: pointer;
    text-align: center;
  }
}

.affi-affiliate-rank-edit {

  .affi-hidden {
    display: none;
  }

  .affi-upload-badge-wrap {
    position: relative;
    display: inline-flex;
    width: 102px;
    height: 102px;
    cursor: pointer;
    text-align: center;
  }

  .affi-upload-badge-preview {
    border: 1px solid #d5d5d5;
    display: inline-flex;
    margin: auto;
    max-width: 100%;
    max-height: 100%;
  }

  .affi-upload-badge-wrap:hover .affi-upload-badge-preview {
    opacity: .5;
  }

  .affi-upload-badge-preview img,
  .affi-bill-logo-preview img {
    max-width: 100px;
    max-height: 100px;
    width: 100px;
    height: 100px;
    margin: auto;
  }

  .affi-bill-logo-preview img {
    max-height: 80px;
    max-width: 80px;
    border-radius: 100%;
  }


  .affi-upload-badge-remove {
    position: absolute;
    right: -10px;
    top: -10px;
    margin: 0 !important;
    font-size: 20px !important;
    z-index: 2;
    background: transparent;
    color: #bdbcbc;
  }

  .affi-upload-badge-add-new {
    position: absolute;
    margin: auto;
    font-size: 15px;
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: 500;
    text-transform: uppercase;
    visibility: hidden;
    transition: all .3s linear;
  }

  .affi-upload-badge-wrap:hover .affi-upload-badge-add-new {
    visibility: visible;
  }
}

.affi-reports-control-bar {
  margin-right: 20px;
  border-top-left-radius: 5px;
  padding: 10px 0;

  > a {
    text-decoration: none;
    color: black;
  }

  .item.active {
    border: 1px solid #d4d4d5;
    border-bottom-color: white;
    border-top-left-radius: 5px;
    border-top-right-radius: 5px;
    font-weight: bold;
    background-color: white;
  }

  .item {
    padding: 12px 20px;
  }
}

.affi-general-reports-container {
  padding: 20px;
  background-color: white;
  margin-right: 20px;
  border: 1px solid #d4d4d5;
  border-bottom-left-radius: 5px;
  border-bottom-right-radius: 5px;

  .affi-select-time-range {

    .affi-select-time-group {
      display: flex;

      .affi-select-time-title {
        margin: 5px 0;
      }
    }

    .affi-custom-time-range {
      display: none;

      input, .affi-view-reports {
        /*width: 120px;*/
        margin-left: 5px;
      }
    }

    .affi-select-time-1 {
      width: 170px;
      max-width: 100%;

      .affi-select-time-report {
        width: 100%;
      }
    }
    
    .affi-custom-time-range-flex-layer {
      width: 100%;
      display: flex;
      font-size: 14px;
    }
  }

  .affi-general-reports-group {
    margin-top: 20px;
    margin-bottom: 10px;
    display: flex;

    table {
      width: 100%;
      text-align: center;
      border-collapse: separate;
      border-spacing: 20px;
    }

    .affi-report-cell {
      text-align: center;
      width: 100%;
      border: 1px solid #ccc;
      border-radius: 3px;
      background: linear-gradient(to bottom, white, #fafbfc);
      padding: 10px;

      &:not(:first-child) {
        margin-left: 15px;
      }
    }

    h5 {
      font-weight: 500;
      margin: 0;
      margin-bottom: 5px;
    }

    table td div {
      margin: 0.5rem 0;
    }
  }

  .affi-chart-container {
    margin: auto;
    max-width: 100% !important;
    padding: 10px 0;
  }
}

.affi-affiliate-payout-edit {
  * {
    box-sizing: border-box;
  }

  .affi-hidden {
    display: none;
  }

  .select2-search__field {
    width: 100% !important;
  }

  .select2-container.select2-container--default {
    width: 100% !important;
    min-width: 100% !important;
    margin-left: 0 !important;
    line-height: 0 !important;
  }

  .select2-selection.select2-selection--multiple {
    margin-left: 0 !important;
  }

  .select2-selection.select2-selection--single {
    margin-left: 0 !important;
    height: unset !important;
    border-color: #dedede;
  }

  .select2-selection__choice__remove {
    margin-left: 0 !important;
  }

  .select2-selection__placeholder {
    margin-left: 0 !important;
  }

  .select2-selection__rendered .select2-search.select2-search--inline {
    width: 100%;
  }

  .select2-selection__rendered#select2--affi-referral-user-container {
    padding-top: 4px;
    padding-bottom: 4px;
  }

  .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 100%;
    padding: 0.9em;
    width: 40px;
  }

  #select2-bopobb_bpi_default_product-container {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

}

.affi-payout-tabblenav-form {

  .affi-affiliate-marketing-for-woocommerce_page_affi-request-payout {

    .affi-row-actions {

      a {
        cursor: pointer;
      }
    }

    .affi-approved-status-label {
      width: fit-content;
      padding: 2px 10px;
      border-radius: 5px;
      color: #5b841b;
      background-color: #c6e1c6;
    }

    .affi-pending-status-label {
      width: fit-content;
      padding: 2px 10px;
      border-radius: 5px;
      color: #94660c;
      background-color: #f8dda7;
    }

    .affi-admin-type-label {
      width: fit-content;
      padding: 2px 10px;
      border-radius: 5px;
      color: #fffdfd;
      background-color: #475347;
    }

    .affi-affiliate-type-label {
      width: fit-content;
      padding: 2px 10px;
      border-radius: 5px;
      color: #f5180b;
      background-color: #e2f8e8;
    }
  }
}

.affi-rank-detail-wrap {

  .affi-affi-icon-badge-field-media-icon-block {
    display: flex;
    gap: 10px;
    justify-content: space-between;
    align-items: center;
  }
  
}
