@use "../../../../styles/abstracts/variables";
@use "../../../../styles/abstracts/mixins";  

.invests {
  @include mixins.adminPageIntro;
  margin-top: 1.2rem;
  width: 100%;
  overflow-x: hidden;

  @media only screen and (max-width: 1000px) {
    margin-top: -0.5rem;
  }

  &__tab {
    background: variables.$col-active-btn-bg;
    border-radius: 6px;
    display: flex;
    width: 100%;
    gap: 30px;
    padding: 0.5rem 0.7rem;
    align-items: center;
    font-size: 0.85rem;
    overflow-x: auto;
    flex: auto;
    color: variables.$col-active-btn-color;

    @media only screen and (max-width: 1000px) {
      padding: 0.5rem 0.6rem !important;
    }

    &--item {
      text-align: center;
      cursor: pointer;
      font-weight: 400;
      color: variables.$col-white;

      @media only screen and (max-width: 1000px) {
        display: flex;
        flex: 0 0 150px;
      }

      &--active {
        background: variables.$col-orange;
        color: variables.$col-dark;
        border-radius: 6px;
        padding: 0.5rem 1.5rem;
        cursor: pointer;
        font-size: 0.85rem;
        font-weight: 600 !important;

        @media only screen and (max-width: 1000px) {
          padding: 0.6rem 1.5rem;
          font-size: 0.7rem;
          flex: 0 0 170px;
          gap: 30px;
          margin-right: 1rem;
        }
      }
    }
  }

  &__content {
    margin-top: 1rem;
  }
}

// ========== Table Skeleton Styles ==========

.skeleton-table {
  width: 100%;
  overflow-x: auto;
  border: 1px solid variables.$col-border-lining;
  border-radius: 6px;
  background: #181818;
  padding: 1rem;

  .skeleton-header {
    display: grid;
    grid-template-columns: 2fr 2fr 2fr 1fr 1fr;
    gap: 1rem;
    padding-bottom: 0.5rem;
    font-size: 0.85rem;
    color: #ccc;
    border-bottom: 1px solid #333;
  }

  .skeleton-row {
    display: grid;
    grid-template-columns: 2fr 2fr 2fr 1fr 1fr;
    gap: 1rem;
    margin: 1rem 0;

    .skeleton-cell {
      height: 16px;
      background: #2a2a2a;
      border-radius: 4px;
      animation: pulse 1.5s infinite ease-in-out;
    }

    .wide {
      width: 100%;
    }

    .small {
      width: 60%;
    }

    .action {
      width: 40px;
      height: 16px;
      border-radius: 4px;
      background: #2a2a2a;
      animation: pulse 1.5s infinite ease-in-out;
    }
  }
}

// Pulse animation
@keyframes pulse {
  0% {
    background-color: #2a2a2a;
  }
  50% {
    background-color: #3b3b3b;
  }
  100% {
    background-color: #2a2a2a;
  }
}
