/* ============================================================
   Numbered pagination — shared by the public marketplace lists
   (.il-pager) and the account dashboard tables (.table-pager).

   Both use the same neutral surface + accent-on-current language so
   a page control looks identical everywhere. Colours come from the
   theme tokens, so dark mode follows the rest of the app.
   ============================================================ */

.il-pager,
.table-pager {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px;
  padding: 20px 8px 4px;
  font-family: inherit;
}

.il-pager[hidden],
.table-pager[hidden] {
  display: none;
}

.il-page-btn,
.table-page-btn {
  min-width: 38px;
  height: 38px;
  padding: 0 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--color-border, rgba(15, 39, 66, 0.16));
  border-radius: 9px;
  background: var(--color-surface, #fff);
  color: var(--color-on-muted, #5b6b80);
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease,
    color 0.15s ease, transform 0.15s ease;
}

.il-page-btn:hover:not(:disabled),
.table-page-btn:hover:not(:disabled) {
  border-color: var(--brand-orange-500, #ff6a00);
  color: var(--color-on-surface, #24344a);
  transform: translateY(-1px);
}

.il-page-btn:focus-visible,
.table-page-btn:focus-visible {
  outline: 2px solid var(--brand-orange-500, #ff6a00);
  outline-offset: 2px;
}

.il-page-btn.is-active,
.table-page-btn.is-active {
  border-color: transparent;
  background: var(--brand-orange-500, #ff6a00);
  color: #fff;
  cursor: default;
}

.il-page-btn:disabled,
.table-page-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
}

.il-page-step,
.table-page-step {
  font-size: 1.6rem;
  font-weight: 500;
}

.il-page-gap {
  min-width: 24px;
  text-align: center;
  color: var(--color-on-muted, #8fa4b8);
  font-weight: 700;
}

/* Small-screens: keep the control tappable, drop fixed min-widths a bit. */
@media (max-width: 480px) {
  .il-page-btn,
  .table-page-btn {
    min-width: 34px;
    height: 34px;
    font-size: 1.15rem;
  }
}

[data-theme="dark"] .il-page-btn,
[data-theme="dark"] .table-page-btn {
  background: var(--color-surface, #1a2238);
}

@media (prefers-reduced-motion: reduce) {
  .il-page-btn,
  .table-page-btn {
    transition: none;
  }
  .il-page-btn:hover:not(:disabled),
  .table-page-btn:hover:not(:disabled) {
    transform: none;
  }
}
