/* Borderless card (page-specific opt-in) */
.lms-borderless-card {
  border: 0 !important;
}

/* Allow dropdowns inside horizontally scrollable tables */
.lms-table-scroll {
  overflow-x: auto;
  overflow-y: visible;
}

/* Gray table header container (no big rounded corners) */
.lms-rounded-thead {
  position: relative;
}
.lms-rounded-thead::after {
  content: "";
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 0;
  height: 1px;
  background: var(--cui-border);
  pointer-events: none;
}
.lms-rounded-thead th {
  background: rgba(15, 23, 42, 0.04);
  border-bottom: 0;
}

/* Make the header row corners rounder */
.lms-rounded-thead th:first-child {
  border-top-left-radius: var(--cui-radius-xl);
  border-bottom-left-radius: var(--cui-radius-xl);
}

.lms-rounded-thead th:last-child {
  border-top-right-radius: var(--cui-radius-xl);
  border-bottom-right-radius: var(--cui-radius-xl);
}

html[data-theme="dark"] .lms-rounded-thead th {
  background: rgba(255, 255, 255, 0.04);
  border-bottom-color: var(--cui-border);
}

/* Reusable table style (matches batches.php look) */
.lms-table,
.cui-table {
  width: 100%;
  min-width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

.lms-table thead,
.cui-table thead {
  position: relative;
}

.lms-table thead::after,
.cui-table thead::after {
  content: "";
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 0;
  height: 1px;
  background: var(--cui-border);
  pointer-events: none;
}

.lms-table thead th,
.cui-table thead th {
  background: rgba(15, 23, 42, 0.04);
  border-bottom: 0;
  color: var(--cui-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 0.75rem;
  font-weight: 600;
}

.lms-table thead th:first-child,
.cui-table thead th:first-child {
  border-top-left-radius: var(--cui-radius-xl);
  border-bottom-left-radius: var(--cui-radius-xl);
}

.lms-table thead th:last-child,
.cui-table thead th:last-child {
  border-top-right-radius: var(--cui-radius-xl);
  border-bottom-right-radius: var(--cui-radius-xl);
}

html[data-theme="dark"] .lms-table thead th,
html[data-theme="dark"] .cui-table thead th {
  background: rgba(255, 255, 255, 0.04);
}

.lms-table tbody tr,
.cui-table tbody tr {
  position: relative;
}

.lms-table tbody tr:not(:last-child),
.cui-table tbody tr:not(:last-child) {
  background-image: linear-gradient(var(--cui-border), var(--cui-border));
  background-repeat: no-repeat;
  background-position: left 16px bottom;
  background-size: calc(100% - 32px) 1px;
}
