/* All layout rules are scoped to the booking ledger. */
#ledgerTab .booking-ledger-heading,
#ledgerTab .booking-ledger-results-heading { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
#ledgerTab .booking-ledger-heading { margin-bottom: 20px; }
#ledgerTab .booking-ledger-heading p { margin-top: 7px; max-width: 780px; color: var(--muted); font-size: 14px; line-height: 1.7; }
#ledgerTab .booking-ledger-scope { padding: 6px 12px; color: var(--brand-strong); background: #eaf5f3; border-radius: 6px; white-space: nowrap; font-size: 13px; }
#ledgerTab .booking-ledger-scope:empty { display: none; }
#ledgerTab .booking-ledger-filters { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px 16px; padding: 20px; background: var(--soft); border: 1px solid var(--line); border-radius: 8px; }
#ledgerTab .booking-ledger-filters label { display: grid; gap: 7px; min-width: 0; font-size: 13px; color: #394555; }
#ledgerTab .booking-ledger-filters input,
#ledgerTab .booking-ledger-filters select { width: 100%; min-width: 0; margin: 0; background-color: #fff; font-size: 14px; }
#ledgerTab .ledger-wide { grid-column: span 2; }
#ledgerTab .booking-ledger-filter-footer { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 6px; }
#ledgerTab .booking-ledger-filter-footer p { color: var(--muted); font-size: 13px; line-height: 1.6; }
#ledgerTab .booking-ledger-filter-footer > div { display: flex; gap: 8px; flex-shrink: 0; }
#ledgerTab .booking-ledger-status { color: var(--muted); font-size: 14px; line-height: 1.6; margin: 12px 0; }
#ledgerTab .booking-ledger-status:empty { margin: 0; }
#ledgerTab .booking-ledger-results-heading { padding: 20px 0 14px; }
#ledgerTab .booking-ledger-results-heading h3 { font-size: 16px; }
#ledgerTab #bookingLedgerCount { margin-left: 6px; color: var(--brand); }
#ledgerTab .booking-ledger-results-heading p { margin-top: 6px; font-size: 13px; color: var(--muted); line-height: 1.6; }
#ledgerTab .booking-ledger-results-heading button { flex-shrink: 0; }
#ledgerTab .booking-ledger-empty { padding: 32px 18px; text-align: center; color: var(--muted); background: var(--soft); border: 1px dashed var(--line); border-radius: 8px; line-height: 1.7; }
#ledgerTab .booking-ledger-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; }
#ledgerTab .booking-ledger-table { width: 100%; min-width: 0; border-collapse: collapse; font-size: 13px; line-height: 1.6; table-layout: fixed; }
#ledgerTab .booking-ledger-table th { padding: 12px; background: var(--soft); color: #475467; font-weight: 500; text-align: left; }
#ledgerTab .booking-ledger-table td { padding: 14px 12px; vertical-align: top; overflow-wrap: anywhere; border-top: 1px solid var(--line); }
#ledgerTab .booking-ledger-table th:first-child { width: 25%; }
#ledgerTab .booking-ledger-table th:nth-child(2) { width: 13%; }
#ledgerTab .booking-ledger-table th:nth-child(3) { width: 20%; }
#ledgerTab .booking-ledger-table th:nth-child(4) { width: 18%; }
#ledgerTab .booking-ledger-table th:nth-child(5) { width: 14%; }
#ledgerTab .booking-ledger-table th:last-child { width: 10%; }
#ledgerTab .booking-ledger-table strong { font-weight: 500; color: var(--ink); }
#ledgerTab .booking-ledger-table small { display: block; color: var(--muted); font-size: 12px; margin-top: 4px; }
#ledgerTab .booking-ledger-status-tag { display: inline-block; padding: 3px 6px; background: #f0f3f7; border-radius: 4px; color: #475467; }
#ledgerTab .booking-ledger-status-tag.is-approved { background: #eaf5ed; color: var(--ok); }
#ledgerTab .booking-ledger-pagination { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 12px; padding-top: 20px; color: var(--muted); font-size: 13px; }
@media (max-width: 760px) {
  #ledgerTab .booking-ledger-heading { align-items: flex-start; flex-direction: column; gap: 8px; margin-bottom: 16px; }
  #ledgerTab .booking-ledger-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding: 14px; }
  #ledgerTab .ledger-room-filter { grid-column: span 2; }
  #ledgerTab .booking-ledger-filter-footer { align-items: stretch; flex-direction: column; gap: 12px; }
  #ledgerTab .booking-ledger-filter-footer > div button { flex: 1; }
  #ledgerTab .booking-ledger-results-heading { align-items: flex-start; gap: 12px; }
  #ledgerTab .booking-ledger-results-heading button { padding: 10px 12px; }
  #ledgerTab .booking-ledger-table-wrap { border: 0; overflow: visible; }
  #ledgerTab .booking-ledger-table,
  #ledgerTab .booking-ledger-table tbody { display: block; }
  #ledgerTab .booking-ledger-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  #ledgerTab .booking-ledger-table tr { display: block; border: 1px solid var(--line); border-radius: 8px; padding: 14px; margin-bottom: 12px; }
  #ledgerTab .booking-ledger-table td { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 10px; border: 0; padding: 5px 0; font-size: 14px; }
  #ledgerTab .booking-ledger-table td::before { content: attr(data-label); color: var(--muted); font-size: 13px; }
  #ledgerTab .booking-ledger-table small { font-size: 13px; }
}
