/* [TFH-312:TFH_FLIGHT_INVOICE_INDEX:CSS-START] */
.tfh-flight-invoice-index-list{min-width:1200px;display:block}
.tfh-flight-invoice-index-table{width:100%;min-width:1200px;border-collapse:separate;border-spacing:0;table-layout:fixed;font-family:"Segoe UI",Arial,sans-serif;font-size:12px}
.tfh-flight-invoice-index-table th{position:sticky;top:0;z-index:4;height:42px;padding:8px 7px;color:#fff;background:linear-gradient(#6f879b,#334d63);text-align:center}
.tfh-flight-invoice-index-table td{height:39px;padding:7px 8px;overflow:hidden;border-right:1px solid #dce3ea;border-bottom:1px solid #dce3ea;text-overflow:ellipsis;white-space:nowrap}
.tfh-flight-invoice-index-table tbody tr:nth-child(even){background:#f4f7fa}.tfh-flight-invoice-index-table tbody tr:hover{background:#eaf3fb}.tfh-flight-invoice-index-table tbody tr.is-selected{background:#dcecf8;box-shadow:inset 4px 0 0 var(--tfh-blue-600)}
.tfh-flight-invoice-index-table td.is-financial{text-align:right;font-variant-numeric:tabular-nums}.tfh-flight-invoice-index-table td.is-net{color:#765700;background:#fff8d8;font-weight:850}
.tfh-flight-invoice-index-table th:nth-child(1){width:105px}.tfh-flight-invoice-index-table th:nth-child(2){width:95px}.tfh-flight-invoice-index-table th:nth-child(3){width:190px}.tfh-flight-invoice-index-table th:nth-child(4){width:130px}.tfh-flight-invoice-index-table th:nth-child(5){width:210px}.tfh-flight-invoice-index-table th:nth-child(6),.tfh-flight-invoice-index-table th:nth-child(7),.tfh-flight-invoice-index-table th:nth-child(8){width:110px}.tfh-flight-invoice-index-table th:nth-child(9){width:110px}.tfh-flight-invoice-index-table th:nth-child(10){width:105px}.tfh-flight-invoice-index-table th:nth-child(11){width:90px}
@media(max-width:900px){.tfh-flight-invoice-header-grid,.tfh-flight-invoice-party-grid,.tfh-flight-invoice-bottom-grid{grid-template-columns:1fr}}
/* [TFH-312:TFH_FLIGHT_INVOICE_INDEX:CSS-END] */
/* [TFH-312:TFH_FLIGHT_INVOICE_INDEX:V031-CSS-START] */
.tfh-invoice-index-filters .tfh-form-field {
  min-width: 0;
  align-content: start;
}

.tfh-invoice-index-filters .tfh-form-field > span {
  min-height: 18px;
  display: flex;
  align-items: center;
}

.tfh-invoice-index-filters input,
.tfh-invoice-index-filters select {
  width: 100%;
  min-width: 0;
  height: 45px;
  padding: 0 12px;
  border: 1px solid rgba(17,49,84,.15);
  border-radius: 11px;
  outline: 0;
  color: var(--tfh-ink-900);
  background: #f9fbfd;
  font: inherit;
  transition:
    border-color 150ms ease,
    box-shadow 150ms ease,
    background 150ms ease;
}

.tfh-invoice-index-filters select {
  padding-right: 34px;
  cursor: pointer;
}

.tfh-invoice-index-filters input:focus,
.tfh-invoice-index-filters select:focus {
  border-color: rgba(47,127,196,.7);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(47,127,196,.10);
}

.tfh-invoice-index-filters select:hover {
  border-color: rgba(47,127,196,.38);
  background: #fff;
}
/* [TFH-312:TFH_FLIGHT_INVOICE_INDEX:V031-CSS-END] */
/* [TFH-312:TFH_FLIGHT_INVOICE_INDEX:CSS-GRID-SPACE-START] */
/*
  Flight Invoice Index - more rows on screen (2026-09-25)
  - Accumulate moved into the filter row; the separate summary strip is gone
    (record count is in the header badge; summary + selection text moved to the footer).
  - Compact filters (38px controls).
  - Single-line rows (~34px): no wrapping, long text truncated with "…" (full text on hover).
  - Column widths tuned so all 14 columns fit a 1366px screen without sideways scrolling.
  - Sortable headers: ⇅ shows every column can be sorted; ▲ / ▼ on the active column.
  Scoped to #tfhFlightInvoiceIndexScreen: other screens are not affected.
*/
#tfhFlightInvoiceIndexScreen .tfh-invoice-index-body {
  padding: 10px 10px;
}

#tfhFlightInvoiceIndexScreen .tfh-invoice-index-panel {
  width: 100%;
  grid-template-rows: auto minmax(0, 1fr);
  border-radius: 12px;
}

/* ---- Filters: one row, Accumulate at the end ---- */
#tfhFlightInvoiceIndexScreen .tfh-invoice-index-filters {
  grid-template-columns:
    repeat(2, minmax(128px, .72fr))
    minmax(150px, .85fr)
    minmax(180px, 1.15fr)
    repeat(3, minmax(130px, .78fr))
    auto;
  align-items: end;
  gap: 9px;
  padding: 10px 12px 11px;
}

#tfhFlightInvoiceIndexScreen .tfh-invoice-index-filters .tfh-form-field {
  gap: 4px;
  min-width: 0;
}

#tfhFlightInvoiceIndexScreen .tfh-invoice-index-filters .tfh-form-field > span {
  color: #3b5167;
  font-size: .66rem;
  font-weight: 700;
  letter-spacing: .06em;
  line-height: 1.2;
  text-transform: uppercase;
}

#tfhFlightInvoiceIndexScreen .tfh-invoice-index-filters input,
#tfhFlightInvoiceIndexScreen .tfh-invoice-index-filters select {
  width: 100%;
  height: 38px;
  min-height: 38px;
  padding: 0 10px;
  border-radius: 7px;
  font-size: .86rem;
  font-weight: 600;
}

#tfhFlightInvoiceIndexScreen .tfh-invoice-index-accumulate {
  height: 38px;
  min-height: 38px;
  padding: 0 22px;
  border-radius: 7px;
  font-size: .88rem;
  white-space: nowrap;
}

/* ---- Grid ----
   2026-09-25 refinement 2 (as requested):
   Invoice No. 120px | Date 100px (01-JAN-2025) | Client 300px, word-wrapped |
   all text columns word-wrap with flexible row height |
   the remaining width is shared equally by the five financial columns. */
#tfhFlightInvoiceIndexScreen .tfh-invoice-index-scroll {
  padding: 0;
}

#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-list {
  min-width: 1446px;
}

#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table {
  width: 100%;
  min-width: 1446px;
  table-layout: fixed;
  font-size: .8rem;
}

#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table thead th {
  height: auto;
  min-height: 38px;
  padding: 0;
  vertical-align: middle;
}

#tfhFlightInvoiceIndexScreen .tfh-invoice-sort-button {
  min-height: 38px;
  height: 100%;
  gap: 5px;
  padding: 3px 8px;
  font-size: .72rem;
  line-height: 1.15;
  white-space: normal;
}

#tfhFlightInvoiceIndexScreen .tfh-invoice-sort-label {
  min-width: 0;
  overflow: visible;
  text-overflow: clip;
  overflow-wrap: normal;
}

/* Rows grow with their content; everything top-aligned */
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table td {
  height: auto;
  min-height: 34px;
  padding: 8px 8px 7px;
  vertical-align: top;
  line-height: 1.3;
  white-space: normal;
  overflow: visible;
  overflow-wrap: anywhere;
  text-overflow: clip;
}

/* Financial values stay on one line, right-aligned */
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table td.is-financial {
  white-space: nowrap;
  overflow-wrap: normal;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* Invoice number and date on one line */
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table td:nth-child(1),
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table td:nth-child(2) {
  white-space: nowrap;
  overflow-wrap: normal;
  font-variant-numeric: tabular-nums;
}

/* Column widths: Invoice No. | Date | Client | Wing | Additional Detail | Amount | Administration | Net Payable | Invoice Status | Receipt No. | Status
   Fixed text columns = 1,116px; Amount / Administration / Net Payable (auto) share the rest, minimum 110px each. */
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table th:nth-child(1) { width: 120px; }
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table th:nth-child(2) { width: 100px; }
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table th:nth-child(3) { width: 300px; }
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table th:nth-child(4) { width: 120px; }
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table th:nth-child(5) { width: 210px; }
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table th:nth-child(6) { width: auto; }
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table th:nth-child(7) { width: auto; }
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table th:nth-child(8) { width: auto; }
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table th:nth-child(9) { width: 96px; }
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table th:nth-child(10) { width: 90px; }
#tfhFlightInvoiceIndexScreen .tfh-flight-invoice-index-table th:nth-child(11) { width: 80px; }

/* ---- Footer: message + summary stacked in the centre ---- */
#tfhFlightInvoiceIndexScreen .tfh-invoice-index-footer-status {
  min-width: 0;
  display: grid;
  justify-items: center;
  gap: 2px;
  text-align: center;
}

#tfhFlightInvoiceIndexScreen .tfh-invoice-index-footer-summary {
  min-height: 0;
  display: flex;
  justify-content: center;
  gap: 14px;
  padding: 0;
  border: 0;
  background: none;
  color: #6a7a8b;
  font-size: .7rem;
}

@media (max-width: 1180px) {
  #tfhFlightInvoiceIndexScreen .tfh-invoice-index-filters {
    grid-template-columns: repeat(4, minmax(130px, 1fr));
  }

  #tfhFlightInvoiceIndexScreen .tfh-invoice-index-accumulate {
    width: 100%;
  }
}

@media (max-width: 720px) {
  #tfhFlightInvoiceIndexScreen .tfh-invoice-index-filters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #tfhFlightInvoiceIndexScreen .tfh-invoice-index-accumulate {
    grid-column: 1 / -1;
  }

  #tfhFlightInvoiceIndexScreen .tfh-invoice-index-footer-summary {
    display: none;
  }
}
/* [TFH-312:TFH_FLIGHT_INVOICE_INDEX:CSS-GRID-SPACE-END] */
