@use '../../../../styles/typography';

:host {
  display: flex;
  flex-direction: column;
  align-items: start;
  height: 100%;

  .header,
  .filter,
  .no-providers-label,
  table {
    padding: 1rem;
    width: 100%;
    box-sizing: border-box;
  }

  .header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;

    h2 {
      @extend %heading-400;
      margin: 0;
      padding: 0;
    }

    .close-btn {
      mat-icon {
        font-size: 16px;
        width: 16px;
        height: 16px;
      }
    }
  }

  .filter {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
    padding-block: 0;

    label,
    select,
    input {
      display: block;
      width: 100%;
    }

    label {
      padding-left: 0.75rem;
      margin-bottom: 0.25rem;
      color: var(--quaternary-contrast);
    }

    .token-filter {
      position: relative;
      flex: 1;

      input {
        padding-right: 2rem;
      }

      .clear-filter {
        position: absolute;
        right: 0.75rem;
        bottom: 0.15rem;

        mat-icon {
          $icon-size: 16px;
          font-size: $icon-size;
          width: $icon-size;
          height: $icon-size;
        }
      }
    }

    .type-filter {
      width: 9rem;
    }
  }

  .no-providers-label {
    padding-block: 0.5rem;
    text-align: center;
  }

  table {
    padding-top: 0;
    overflow-y: auto;
    scrollbar-width: thin;
    display: block;
    flex: 1;

    .token-cell {
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
      width: 100%;
      max-width: 0;
    }
  }
}
