@import '../../styles/common.less';
@import '../../IconButton/styles/index.less';
@import '../../Tooltip/styles/index.less';

.rs-stat {
  display: flex;
  gap: 10px;
  align-items: center;

  &-icon {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
  }

  &-body {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    margin: 0;
  }

  &-bordered {
    border: 1px solid var(--rs-border-primary);
    background-color: var(--rs-stat-body-bg);
    border-radius: 6px;
    padding: 16px;
  }

  &-label {
    font-weight: 100;
    display: inline-flex;
    align-items: center;
    color: var(--rs-text-secondary);
    gap: 6px;

    &-uppercase {
      text-transform: uppercase;
    }
  }

  &-value {
    display: flex;
    gap: 4px;
    align-items: baseline;
    font-size: 24px;
    font-weight: 600;
    line-height: 1;
    margin: 0;
  }

  &-value-unit {
    font-size: 12px;
    font-weight: 400;
  }

  &-trend {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 12px;
    line-height: 1;

    &-up {
      color: var(--rs-green-900);
    }

    &-down {
      color: var(--rs-red-900);
    }

    &-default {
      padding: 2px 6px;
    }

    &-default&-up {
      background-color: var(--rs-green-100);
    }

    &-default&-down {
      background-color: var(--rs-red-100);
    }

    &-subtle&-up {
      color: var(--rs-green-600);
    }

    &-subtle&-down {
      color: var(--rs-red-600);
    }
  }

  &-help-text {
    color: var(--rs-text-secondary);
  }

  .rs-progress-line {
    padding: 0;
  }
}
