body {
  margin: 0;
  background: #f5f7fb;
  color: #1b2430;
}

#cashier-section {
  display: grid;
  gap: 12px;
}

#cashier-workspace[hidden],
#cashier-empty-panel[hidden] {
  display: none !important;
}

.cashier-placeholder-title {
  margin: 0 0 6px;
  font-size: 1.1rem;
}

.cashier-placeholder-copy {
  margin: 0;
  color: #5f6b7a;
}

.page-shell {
  padding: 12px;
}

.settlement-grid {
  display: grid;
  grid-template-columns: minmax(280px, 340px) minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  min-height: 0;
}

.stacked-panels {
  display: grid;
  gap: 12px;
}

.panel {
  background: #fff;
  border: 1px solid #d8dee6;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(10, 30, 60, 0.08);
  overflow: hidden;
}

.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: #fbfcfe;
  border-bottom: 1px solid #d8dee6;
}

.panel-head h2,
.panel-head h3 {
  margin: 0;
  font-size: 1.05rem;
}

.panel-head-actions {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.panel-subtle {
  color: #5f6b7a;
  font-size: 0.92rem;
}

.panel-body {
  padding: 10px 12px 12px;
}

.primary-button,
.secondary-button,
.payment-button,
.modal-button {
  font: inherit;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.primary-button,
.payment-button,
.modal-button-primary {
  border: 1px solid #0f62fe;
  background: #0f62fe;
  color: #fff;
}

.secondary-button,
.modal-button {
  border: 1px solid #cbd5df;
  background: #fff;
  color: #1b2430;
}

.primary-button,
.secondary-button {
  padding: 6px 10px;
}

.payment-button {
  padding: 7px 10px;
  min-height: 38px;
}

.primary-button:hover,
.payment-button:hover,
.modal-button-primary:hover {
  background: #0b4ecc;
  border-color: #0b4ecc;
}

.secondary-button:hover,
.modal-button:hover {
  background: #f4f7fa;
}

.primary-button:disabled,
.secondary-button:disabled,
.payment-button:disabled,
.modal-button:disabled,
#payButtons.disabled .payment-button {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

.summary-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  align-items: center;
  padding: 8px 12px;
  border: 1px solid #d8dee6;
  border-radius: 10px;
  background: #fbfcfe;
}

.summary-card {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
}

.summary-card-label {
  color: #5f6b7a;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0;
}

.summary-card-value {
  font-size: 1rem;
  font-weight: 700;
}

.detail-layout {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.detail-sections {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.detail-section + .detail-section {
  margin-top: 0;
}

.detail-heading {
  margin: 0 0 10px;
  font-size: 0.95rem;
}

.section-total {
  margin-top: 8px;
  padding: 9px 12px;
  border: 1px solid #d8dee6;
  border-radius: 10px;
  background: #fbfcfe;
  font-weight: 600;
  text-align: right;
}

.lot-preview-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.lot-preview-thumb {
  margin: 0;
  display: grid;
  gap: 6px;
}

.lot-preview-thumb img,
.lot-preview-thumb-more {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  border: 1px solid #d8dee6;
  background: #eef3f8;
}

.lot-preview-thumb img {
  display: block;
  object-fit: cover;
}

.lot-preview-thumb figcaption,
.lot-preview-thumb-more {
  color: #5f6b7a;
  font-size: 0.78rem;
  text-align: center;
}

.lot-preview-thumb-more {
  display: grid;
  place-items: center;
  padding: 8px;
  font-weight: 700;
}

.table-wrap {
  border: 1px solid #e7ebf0;
  border-radius: 10px;
  overflow: hidden;
  max-width: 100%;
  min-width: 0;
}

table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

th,
td {
  padding: 8px 10px;
  border-top: 1px solid #e7ebf0;
  vertical-align: top;
}

thead th {
  border-top: 0;
  color: #5f6b7a;
  font-size: 0.84rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  text-align: left;
  background: #fbfcfe;
}

tbody tr:first-child td {
  border-top: 0;
}

.bidder-row {
  cursor: pointer;
}

.bidder-row:hover {
  background: #f8fbff;
}

.bidder-row.sel {
  background: #dbe8ff;
}

.bidder-paid {
  background: #eef8f1 !important;
  color: #486256;
}

.bidder-part-paid {
  background: #fff8df !important;
  color: #6f5815;
}

.bidder-negative {
  background: #fff4ef !important;
  color: #9a4521;
}

#bidderTable th:first-child,
#bidderTable td:first-child {
  width: 88px;
}

#bidderTable th:last-child,
#bidderTable td:last-child {
  text-align: right;
  white-space: nowrap;
}

#lotsTable th:first-child,
#lotsTable td:first-child {
  width: 72px;
}

#lotsTable th:last-child,
#lotsTable td:last-child {
  width: 110px;
  text-align: right;
  white-space: nowrap;
}

#payTable th:first-child,
#payTable td:first-child {
  width: 72px;
}

#payTable th:nth-child(2),
#payTable td:nth-child(2) {
  width: 170px;
}

#payTable th:nth-child(3),
#payTable td:nth-child(3) {
  width: 140px;
}

#payTable th:nth-child(4),
#payTable td:nth-child(4) {
  width: 110px;
  text-align: right;
  white-space: nowrap;
}

#payTable th:last-child,
#payTable td:last-child {
  width: 88px;
  text-align: center;
}

.pay-list td {
  font-size: 0.9rem;
}

.refund-button {
  border: 1px solid #cbd5df;
  background: #fff;
  color: #1b2430;
  border-radius: 8px;
  padding: 5px 8px;
  cursor: pointer;
  font: inherit;
}

.refund-button:hover {
  background: #fff4ef;
  border-color: #efc2af;
  color: #9a4521;
}

#fingerprintDisplay {
  color: #5f6b7a;
  font-family: "Courier New", monospace;
  font-size: 0.85rem;
  word-break: break-all;
}

.payment-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
  margin-top: 12px;
  min-width: 0;
}

.payment-state-hint,
.modal-field-hint {
  margin-top: 8px;
  color: #5f6b7a;
  font-size: 0.9rem;
}

.payment-state-hint {
  padding: 8px 10px;
  border: 1px solid #e3d49c;
  border-radius: 8px;
  background: #fff8df;
  color: #6f5815;
}

.modal-warning {
  margin-bottom: 16px;
  padding: 10px 12px;
  border: 1px solid #e3b341;
  border-radius: 8px;
  background: #fff8df;
  color: #6f4d0b;
  font-size: 0.92rem;
  line-height: 1.4;
}

.pending-payments-panel {
  margin-top: 12px;
  padding: 10px;
  border: 1px solid #e3d49c;
  border-radius: 8px;
  background: #fffaf0;
  color: #3d3120;
  transition: box-shadow 0.18s ease, border-color 0.18s ease;
}

.pending-payments-panel-compact {
  margin-top: 0;
  margin-bottom: 10px;
}

.pending-payments-panel-highlight {
  border-color: #b7791f;
  box-shadow: 0 0 0 3px rgba(183, 121, 31, 0.22);
}

.pending-payments-heading,
.pending-payment-card-main {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.pending-payments-heading {
  align-items: center;
  margin-bottom: 8px;
  font-weight: 700;
}

.pending-payments-heading strong,
.pending-bidder-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 20px;
  padding: 2px 7px;
  border-radius: 999px;
  background: #b7791f;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  white-space: nowrap;
}

.pending-payment-list {
  display: grid;
  gap: 6px;
}

.pending-payment-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  font-size: 0.88rem;
}

.pending-payment-link {
  border: 0;
  background: transparent;
  color: #24436b;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  padding: 0;
  text-align: left;
  text-decoration: underline;
}

.pending-payment-card + .pending-payment-card {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid #ead384;
}

.pending-payment-title {
  font-weight: 700;
}

.pending-payment-meta,
.pending-payment-status,
.sumup-waiting-meta,
.sumup-waiting-status,
.sumup-waiting-elapsed {
  color: #5f6b7a;
  font-size: 0.9rem;
}

.pending-payment-status {
  margin-top: 4px;
}

.pending-payment-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.pending-bidder-badge {
  margin-left: 4px;
  vertical-align: middle;
}

.sumup-waiting-card {
  width: min(100%, 420px);
  text-align: center;
}

.sumup-spinner {
  width: 42px;
  height: 42px;
  margin: 2px auto 14px;
  border: 4px solid #d8dee6;
  border-top-color: #0f62fe;
  border-radius: 50%;
  animation: sumup-spin 0.9s linear infinite;
}

.sumup-waiting-amount {
  font-size: 1.25rem;
  font-weight: 700;
}

.sumup-waiting-status {
  margin: 12px 0 4px;
}

.sumup-waiting-elapsed {
  margin-bottom: 4px;
}

@keyframes sumup-spin {
  to {
    transform: rotate(360deg);
  }
}

.modal-input:disabled {
  background: #eef3f8;
  color: #5f6b7a;
  cursor: not-allowed;
}

#lotsTable tbody tr.payment-state-paid,
#lotsSection.payment-state-paid .section-total {
  background: #eef8f1;
}

#lotsTable tbody tr.payment-state-part-paid,
#lotsSection.payment-state-part-paid .section-total {
  background: #fff8df;
}

#lotsTable tbody tr.payment-state-overpaid,
#lotsSection.payment-state-overpaid .section-total {
  background: #fff4ef;
}

#lotsSection.payment-state-paid .table-wrap,
#lotsSection.payment-state-paid .section-total {
  border-color: #b9e4c5;
}

#lotsSection.payment-state-part-paid .table-wrap,
#lotsSection.payment-state-part-paid .section-total {
  border-color: #ead384;
}

#lotsSection.payment-state-overpaid .table-wrap,
#lotsSection.payment-state-overpaid .section-total {
  border-color: #efc2af;
}

.receipt-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
}

.fingerprint-chip {
  display: inline-flex;
  align-items: center;
  max-width: min(100%, 520px);
  padding: 6px 10px;
  border: 1px solid #d8dee6;
  border-radius: 999px;
  background: #fbfcfe;
}

.empty-state {
  color: #5f6b7a;
  font-style: italic;
  padding: 12px 0;
}

.modal-overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(16, 24, 40, 0.35);
  z-index: 9999;
}

.modal-card {
  width: min(100%, 340px);
  background: #fff;
  border: 1px solid #d8dee6;
  border-radius: 12px;
  box-shadow: 0 18px 48px rgba(10, 30, 60, 0.18);
  padding: 18px;
}

.modal-title {
  margin: 0 0 12px;
  font-size: 1.05rem;
}

.modal-label {
  display: block;
  margin-top: 8px;
  margin-bottom: 4px;
  font-size: 0.92rem;
  font-weight: 600;
}

.modal-input {
  width: 100%;
  box-sizing: border-box;
  padding: 8px 10px;
  border: 1px solid #cbd5df;
  border-radius: 8px;
  font: inherit;
}

.inline-detail-button {
  margin-left: 8px;
  min-height: 30px;
  padding: 4px 10px;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 14px;
}

body.buyer-display-page {
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(15, 98, 254, 0.08), transparent 34%),
    linear-gradient(180deg, #f4f7fb 0%, #edf2f8 100%);
}

.buyer-display-shell {
  box-sizing: border-box;
  min-height: 100vh;
  padding: 18px;
}

.buyer-display-card {
  max-width: 1100px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid #d8dee6;
  border-radius: 18px;
  box-shadow: 0 18px 40px rgba(10, 30, 60, 0.12);
  overflow: hidden;
}

.buyer-display-head {
  padding: 18px 22px 14px;
  background: linear-gradient(135deg, #0f62fe 0%, #3a7fff 100%);
  color: #fff;
}

.buyer-display-kicker {
  margin: 0 0 6px;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.86;
}

.buyer-display-auction {
  margin: 0;
  font-size: clamp(1.5rem, 3vw, 2.4rem);
  line-height: 1.1;
}

.buyer-display-body {
  padding: 18px 22px 24px;
}

.buyer-display-paddle {
  margin: 0 0 14px;
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1;
  letter-spacing: -0.03em;
}

.buyer-display-section + .buyer-display-section {
  margin-top: 18px;
}

.buyer-display-empty {
  padding: 22px;
  border: 1px dashed #cbd5df;
  border-radius: 14px;
  background: #f9fbfd;
  color: #5f6b7a;
  font-size: 1.05rem;
}

.buyer-display-table {
  min-width: 0;
}

.buyer-display-table table {
  min-width: 0;
}

.buyer-display-table th,
.buyer-display-table td {
  font-size: 1rem;
}

.buyer-display-table th:first-child,
.buyer-display-table td:first-child {
  width: 82px;
}

.buyer-display-table th:last-child,
.buyer-display-table td:last-child {
  width: 120px;
  text-align: right;
  white-space: nowrap;
}

.buyer-display-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.buyer-display-summary .summary-card {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
  border: 1px solid #d8dee6;
  border-radius: 14px;
  background: #fbfcfe;
}

.buyer-display-summary .summary-card-label {
  font-size: 0.82rem;
}

.buyer-display-summary .summary-card-value {
  font-size: clamp(1.2rem, 2vw, 1.7rem);
}

.buyer-display-thumbnails {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

.buyer-display-thumb {
  margin: 0;
  display: grid;
  gap: 6px;
}

.buyer-display-thumb img,
.buyer-display-thumb-more {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  border: 1px solid #d8dee6;
  background: #eef3f8;
}

.buyer-display-thumb img {
  display: block;
  object-fit: cover;
}

.buyer-display-thumb figcaption,
.buyer-display-thumb-more {
  color: #5f6b7a;
  font-size: 0.78rem;
  text-align: center;
}

.buyer-display-thumb-more {
  display: grid;
  place-items: center;
  padding: 8px;
  font-weight: 700;
}

@media (max-width: 720px) {
  .buyer-display-shell {
    padding: 12px;
  }

  .buyer-display-body,
  .buyer-display-head {
    padding-left: 16px;
    padding-right: 16px;
  }

  .buyer-display-summary {
    grid-template-columns: 1fr;
  }

  .buyer-display-thumbnails {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .settlement-grid {
    grid-template-columns: 1fr;
    min-height: auto;
  }
}

@media (max-width: 720px) {
  .page-shell {
    padding: 10px;
  }

  .summary-grid {
    align-items: flex-start;
    gap: 6px 14px;
  }

  .panel-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .panel-head-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  table {
    min-width: 640px;
  }

  .panel-body,
  .detail-layout,
  .detail-sections,
  .detail-section {
    min-width: 0;
  }

  .detail-section .table-wrap {
    max-width: 100%;
  }

  #bidderTable {
    width: 100%;
    min-width: 100%;
    table-layout: fixed;
  }

  #bidderTable th,
  #bidderTable td {
    white-space: nowrap;
  }

  #bidderTable th:first-child,
  #bidderTable td:first-child {
    width: auto;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  #bidderTable th:last-child,
  #bidderTable td:last-child {
    width: 7.5rem;
  }

  .lot-preview-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .payment-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .payment-button {
    min-width: 0;
    padding-left: 8px;
    padding-right: 8px;
  }

  .pending-payment-card-main,
  .pending-payment-row {
    display: grid;
    grid-template-columns: 1fr;
  }

  .pending-payment-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 480px) {
  /* Override legacy admin styles that hide the bidder label column on small screens. */
  #bidderTable thead th:first-child,
  #bidderTable tbody td:first-child {
    display: table-cell !important;
  }

  #bidderTable th,
  #bidderTable td {
    color: #1b2430;
  }

  #bidderTable th:first-child,
  #bidderTable td:first-child {
    width: auto;
  }

  #bidderTable th,
  #bidderTable td {
    padding-left: 8px;
    padding-right: 8px;
  }

  #bidderTable th:last-child,
  #bidderTable td:last-child {
    width: 6.5rem;
  }

  #lotsTable {
    min-width: 520px;
  }

  #payTable {
    min-width: 620px;
  }

  .payment-actions {
    grid-template-columns: 1fr;
  }
}

:root[data-theme="dark"] body {
  background: transparent;
  color: var(--admin-text);
}

:root[data-theme="dark"] body.buyer-display-page {
  background:
    radial-gradient(circle at top left, rgba(95, 159, 255, 0.08), transparent 34%),
    linear-gradient(180deg, #0a111c 0%, var(--admin-page-bg) 100%);
}

:root[data-theme="dark"] .panel,
:root[data-theme="dark"] .buyer-display-card {
  background: var(--admin-panel-bg);
  border-color: var(--admin-panel-border);
  box-shadow: var(--admin-panel-shadow);
}

:root[data-theme="dark"] .panel-head,
:root[data-theme="dark"] .summary-grid,
:root[data-theme="dark"] .section-total,
:root[data-theme="dark"] thead th,
:root[data-theme="dark"] .buyer-display-summary .summary-card {
  background: #162234;
  border-color: #253349;
}

:root[data-theme="dark"] .secondary-button,
:root[data-theme="dark"] .modal-button,
:root[data-theme="dark"] .modal-input,
:root[data-theme="dark"] .lot-preview-thumb img,
:root[data-theme="dark"] .lot-preview-thumb-more,
:root[data-theme="dark"] .buyer-display-thumb img,
:root[data-theme="dark"] .buyer-display-thumb-more {
  background: #121d2d;
  border-color: #31425c;
  color: var(--admin-text);
}

:root[data-theme="dark"] .secondary-button:hover,
:root[data-theme="dark"] .modal-button:hover {
  background: #1b2a41;
}

:root[data-theme="dark"] .primary-button,
:root[data-theme="dark"] .payment-button,
:root[data-theme="dark"] .modal-button-primary {
  color: #fff;
}

:root[data-theme="dark"] .table-wrap,
:root[data-theme="dark"] th,
:root[data-theme="dark"] td,
:root[data-theme="dark"] .summary-grid,
:root[data-theme="dark"] .section-total,
:root[data-theme="dark"] .buyer-display-empty {
  border-color: #253349;
}

:root[data-theme="dark"] .bidder-row:hover {
  background: rgba(95, 159, 255, 0.08);
}

:root[data-theme="dark"] .bidder-row.sel {
  background: rgba(95, 159, 255, 0.18);
}

:root[data-theme="dark"] .bidder-paid {
  background: #13251e !important;
  color: #9fe3bc;
}

:root[data-theme="dark"] .bidder-part-paid {
  background: #2b2612 !important;
  color: #f2d479;
}

:root[data-theme="dark"] .bidder-negative {
  background: #2a1d14 !important;
  color: #f5bc8a;
}

:root[data-theme="dark"] #lotsTable tbody tr.payment-state-paid,
:root[data-theme="dark"] #lotsSection.payment-state-paid .section-total {
  background: #13251e;
}

:root[data-theme="dark"] #lotsTable tbody tr.payment-state-part-paid,
:root[data-theme="dark"] #lotsSection.payment-state-part-paid .section-total {
  background: #2b2612;
}

:root[data-theme="dark"] #lotsTable tbody tr.payment-state-overpaid,
:root[data-theme="dark"] #lotsSection.payment-state-overpaid .section-total {
  background: #2a1d14;
}

:root[data-theme="dark"] #lotsSection.payment-state-paid .table-wrap,
:root[data-theme="dark"] #lotsSection.payment-state-paid .section-total {
  border-color: #28583c;
}

:root[data-theme="dark"] #lotsSection.payment-state-part-paid .table-wrap,
:root[data-theme="dark"] #lotsSection.payment-state-part-paid .section-total {
  border-color: #6f5b1f;
}

:root[data-theme="dark"] #lotsSection.payment-state-overpaid .table-wrap,
:root[data-theme="dark"] #lotsSection.payment-state-overpaid .section-total {
  border-color: #764226;
}

:root[data-theme="dark"] .empty-state,
:root[data-theme="dark"] .cashier-placeholder-copy,
:root[data-theme="dark"] .panel-subtle,
:root[data-theme="dark"] .modal-field-hint,
:root[data-theme="dark"] .summary-card-label,
:root[data-theme="dark"] .buyer-display-thumb figcaption,
:root[data-theme="dark"] .buyer-display-thumb-more,
:root[data-theme="dark"] .lot-preview-thumb figcaption,
:root[data-theme="dark"] .lot-preview-thumb-more {
  color: var(--admin-muted);
}

:root[data-theme="dark"] .payment-state-hint {
  background: #2b2612;
  border-color: #6f5b1f;
  color: #f2d479;
}

:root[data-theme="dark"] .modal-warning {
  background: #2b2612;
  border-color: #8a6b1f;
  color: #f2d479;
}

:root[data-theme="dark"] .pending-payments-panel {
  background: #2b2612;
  border-color: #6f5b1f;
  color: #f7e2a3;
}

:root[data-theme="dark"] .pending-payments-heading strong,
:root[data-theme="dark"] .pending-bidder-badge {
  background: #a66d18;
  color: #fff;
}

:root[data-theme="dark"] .pending-payment-link {
  color: #9ec6ff;
}

:root[data-theme="dark"] .pending-payment-card + .pending-payment-card {
  border-color: #6f5b1f;
}

:root[data-theme="dark"] .pending-payment-meta,
:root[data-theme="dark"] .pending-payment-status,
:root[data-theme="dark"] .sumup-waiting-meta,
:root[data-theme="dark"] .sumup-waiting-status,
:root[data-theme="dark"] .sumup-waiting-elapsed {
  color: var(--admin-muted);
}

:root[data-theme="dark"] .sumup-spinner {
  border-color: #31425c;
  border-top-color: #5f9fff;
}

:root[data-theme="dark"] .modal-overlay {
  background: rgba(3, 8, 15, 0.72);
}

@media (max-width: 480px) {
  :root[data-theme="dark"] #bidderTable th,
  :root[data-theme="dark"] #bidderTable td {
    color: var(--admin-text);
  }
}

:root[data-theme="dark"] .modal-card {
  background: #121d2d;
  border-color: #31425c;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.38);
}

:root[data-theme="dark"] .modal-input:disabled {
  background: #182437;
  color: var(--admin-muted);
}

:root[data-theme="dark"] .modal-label {
  color: var(--admin-muted);
}

.summary-modal-card {
  width: min(100%, 560px);
}

.summary-breakdown-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.summary-breakdown-table th,
.summary-breakdown-table td {
  border-top: 1px solid #e7ebf0;
  padding: 8px 10px;
  vertical-align: top;
}

.summary-breakdown-table .summary-column-headings th {
  border-top: 0;
  background: #fbfcfe;
  color: #5f6b7a;
  font-size: 0.82rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.summary-breakdown-table td:nth-child(2),
.summary-breakdown-table td:nth-child(3),
.summary-breakdown-table th:nth-child(2),
.summary-breakdown-table th:nth-child(3) {
  text-align: right;
  white-space: nowrap;
}

.summary-modal-group-title td {
  background: #f8fbff;
  color: #24436b;
  font-weight: 700;
}

.summary-modal-total td {
  font-weight: 700;
}

.summary-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 14px;
}

:root[data-theme="dark"] .summary-breakdown-table th,
:root[data-theme="dark"] .summary-breakdown-table td {
  border-color: #253349;
}

:root[data-theme="dark"] .summary-breakdown-table .summary-column-headings th,
:root[data-theme="dark"] .summary-modal-group-title td {
  background: #162234;
  color: #dfeaff;
}
