@use '@/styles/variables' as *;
@use '@/styles/mixins' as *;

.pagination {
  @include flex-between;
  gap: $spacing-base;
  flex-wrap: wrap;

  &__total {
    font-size: $font-size-sm;
    color: $text-secondary;

    strong {
      color: $text-primary;
      font-weight: $font-weight-medium;
    }
  }

  &__controls {
    @include flex-start;
    gap: $spacing-xs;
  }

  &__item {
    @include flex-center;
    min-width: 32px;
    height: 32px;
    padding: 0 $spacing-sm;
    border: 1px solid $border-color;
    border-radius: $border-radius-sm;
    background-color: $card-background;
    color: $text-primary;
    font-size: $font-size-sm;
    @include transition-fast;

    &:hover:not(&--active) {
      border-color: $primary-color;
      color: $primary-color;
    }

    &--active {
      background-color: $primary-color;
      border-color: $primary-color;
      color: #ffffff;
    }
  }

  &__arrow {
    @include flex-center;
    width: 32px;
    height: 32px;
    border: 1px solid $border-color;
    border-radius: $border-radius-sm;
    background-color: $card-background;
    color: $text-primary;
    @include transition-fast;

    svg {
      width: 16px;
      height: 16px;
    }

    &:hover:not(&--disabled) {
      border-color: $primary-color;
      color: $primary-color;
    }

    &--disabled {
      color: $text-disabled;
      cursor: not-allowed;
    }
  }

  &__ellipsis {
    @include flex-center;
    width: 32px;
    height: 32px;
    color: $text-secondary;
    font-size: $font-size-sm;
  }

  &__sizeChanger {
    min-width: 110px;
  }
}
