/* Listagens — cabeçalho fixo, tabela rolável, paginação fixa */

.list-shell {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  height: 100%;
}

.list-header {
  flex-shrink: 0;
  padding: 16px 24px 0;
}

.list-header .toolbar {
  margin-bottom: 12px;
}

.list-header .card {
  margin-bottom: 12px;
}

.table-scroll {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 0 24px;
  -webkit-overflow-scrolling: touch;
}

.table-scroll > .card {
  margin: 0;
  min-height: min-content;
}

.table-scroll .table-wrap {
  overflow: visible;
}

.table-scroll table.data thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--surface);
  box-shadow: 0 1px 0 var(--border);
}

.list-footer {
  flex-shrink: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 12px 24px 16px;
  background: var(--surface);
  border-top: 1px solid var(--border);
  box-shadow: 0 -2px 12px rgba(15, 23, 42, .04);
}

.list-footer-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  min-width: 0;
  justify-self: start;
}

.list-footer-aside {
  justify-self: end;
  min-width: 0;
}

.list-count {
  font-size: 14px;
  white-space: nowrap;
}

@media (max-width: 860px) {
  .list-header {
    padding: 16px 16px 0;
  }

  .table-scroll {
    padding: 0 16px;
  }

  .list-footer {
    grid-template-columns: 1fr;
    padding: 10px 16px 14px;
    gap: 10px;
  }

  .list-footer-meta {
    align-items: center;
    text-align: center;
    width: 100%;
  }

  .list-footer-aside {
    justify-self: center;
    width: 100%;
  }

  .pagination-per-page {
    justify-content: center;
  }
}
