// Instance Count
//================================================== //

.card-content.has-instance-count {
  display: flex;
  justify-content: center;
  text-align: center;
  flex-flow: wrap;
}

.instance-count {
  display: inline-block;
  margin: 20px 10px;
  position: relative;
  width: 120px;
  padding: 0 24px 32px;

  .count {
    background: transparent;
    border: 1px solid;
    border-radius: 50%;
    color: $ids-color-font-base;
    display: inline-block;
    font-weight: $ids-number-font-weight-bold;
    height: 80px;
    line-height: 80px;
    margin-bottom: 8px;
    text-align: center;
    vertical-align: middle;
    width: 80px;

    @include font-size(16);
    @include colorPalettesProperty(border-color);
  }

  svg.icon {
    background: $cardlist-bg-color;
    height: 19px;
    position: absolute;
    right: 23px;
    top: 0;
    width: 20px;

    @include colorPalettesProperty(color);

    &.icon-alert {
      right: 22px;
      top: -3px;
    }
  }

  // No Color Class.
  .count[class='count'] {
    background-color: transparent;
  }

  .title {
    @include antialiased();

    color: $font-color;
    font-size: $ids-size-font-base;
    line-height: 20px;
    text-align: center;
    width: auto;
    text-overflow: ellipsis;
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }
}

.count-info {
  margin: 15px 20px;
  text-align: center;
  width: auto;
}

.object-count.personalize-text {
  color: $counts-personalize-text-color;
}

.object-count {
  color: $font-color-descriptive;
  display: inline-block;
  min-width: 150px;
  text-align: center;

  &.hyperlink {
    margin: -1px 0 0;
    padding: 0 0 8px;
    text-decoration: none;
    line-height: normal;
  }

  span,
  .xl-text {
    color: inherit;
    display: block;
  }

  .xl-text {
    @include font-size(48);
  }
}

.form-layout-compact {
  .object-count {
    .xl-text {
      font-size: $ids-size-font-px-40;
    }
  }
}

html.is-firefox {
  .instance-count {
    .title {
      -moz-orient: vertical;
      width: 120px;
      height: 40px;
    }
  }
}

// RTL Styles
html[dir='rtl'] {
  .instance-count {
    .title {
      padding-left: inherit;
      padding-right: 0;
      text-align: center;
    }
  }
}
