//
// Component: Small Box
//

.small-box {
  @include border-radius($border-radius-xl);
  position: relative;
  display: block;
  --bs-link-color-rgb: none;
  --bs-link-hover-color-rgb: none;
  --bs-heading-color: none;

  > .overlay {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    background-color: rgb(0, 0, 0, 0.5);
    @include border-radius($border-radius-xl);

    > i {
      font-size: 2rem;
      animation: spin 2s linear infinite;
    }
  }

  // content wrapper
  > .inner {
    padding: 10px;
  }

  > .small-box-footer {
    position: relative;
    z-index: 10;
    display: block;
    padding: 3px 0;
    text-align: center;
    text-decoration: none;
    background-color: rgb(var(--bs-black-rgb), 0.07);
    border-bottom-right-radius: $border-radius-xl;
    border-bottom-left-radius: $border-radius-xl;

    &:hover {
      background-color: rgb(var(--bs-black-rgb), 0.1);
    }
  }

  h3 {
    @include font-size(2.2rem);
    padding: 0;
    margin: 0 0 10px;
    font-weight: 700;
    white-space: nowrap;
  }

  p {
    font-size: 1rem;

    > small {
      display: block;
      margin-top: 5px;
      font-size: 0.9rem;
      color: $gray-100;
    }
  }

  h3,
  p {
    z-index: 5;
  }

  // the icon
  .small-box-icon {
    position: absolute;
    top: 15px;
    right: 15px;
    z-index: 0;
    height: 70px;
    font-size: 70px;
    color: rgb(var(--bs-black-rgb), 0.15);
  }

  // Small box hover state
  &:hover {
    // Animate icons on small box hover
    .small-box-icon {
      transform: scale(1.1);
    }
  }
}
