/* DisbursementAccount.razor — the rules that couldn't move into its DisbursementAccount.razor.css:
   anything applied via a Telerik component's Class/HeaderClass parameter (TelerikGrid, TelerikCard,
   TelerikStackLayout) or reaching into Kendo's own generated markup never receives this file's scope
   attribute even when scoped, since that parameter is consumed inside Telerik's own component rather than
   DisbursementAccount.razor's own literal markup — see that scoped file's own header comment for the
   full rule. */

/* Port Expenses grid — same two-table drift fix as the main vessel-files grid (dashboard-grid.css), but
   its own column set. Fixed layout + an explicit table width equal to the sum of every visible GridColumn
   Width (Service 240 + Vendor 200 + Notes 300 + PDA 130 + Post-DA 130 + FDA 130 + actions 150 = 1280) plus
   the leading group-indent cell Telerik adds when grouped (~32px) keeps the header, body, and
   aggregate-footer tables identically sized as the page resizes. Category is the group key, not a column.
   If a column Width changes, update this sum. */
.lh-da-grid .k-grid-header-table.k-table,
.lh-da-grid .k-grid-footer-table.k-table,
.lh-da-grid .k-grid-table.k-table {
    table-layout: fixed;
    width: 1312px;
}

/* Right-align the numeric columns' header titles to match their right-aligned data cells
   (ColumnTextAlign.Right only aligns the data cells). Applied via the column's HeaderClass, so it lands on
   Telerik's own generated header cell, not this component's markup — the header uses a flex .k-cell-inner,
   so it needs justify-content rather than text-align. */
.lh-da-num-cell {
    text-align: right;
}

.lh-da-num-cell .k-cell-inner {
    justify-content: flex-end;
}

/* Zero the group-header cell's own inline padding so the flex row (.lh-da-group-row, scoped in
   DisbursementAccount.razor.css) spans the full column width and its right-anchored subtotals align with
   the columns rather than being inset by the cell padding. */
.lh-da-grid .k-grouping-row > .k-table-td,
.lh-da-grid .k-grouping-row > td {
    padding-inline: 0;
}

/* Advance/Credit + Subtotals row: two fixed-width cards side by side, leaving whitespace to the
   right (the Subtotals card is a placeholder for a later task). Same equal-share squash as
   .lh-card-header-row so the cards keep their own widths instead of splitting the row.
   Full-width row: Advance/Credit card pinned left, Subtotals card pinned right so its right edge
   lines up with the full-width Port Expenses card above; the gap between them flexes. */
.lh-advance-credit-row {
    width: 100%;
    justify-content: space-between;
}

.lh-advance-credit-row>* {
    flex: 0 0 auto;
}

.lh-advance-credit-card.k-card {
    width: 520px;
}

.lh-advance-credit-subtotals-card.k-card {
    width: 280px;
}

/* Tight advance/credit table — same two-table drift fix as .lh-da-grid, its own column sum
   (120+180+100+110). Update this width if a column Width changes. */
.lh-advance-credit-grid .k-grid-header-table.k-table,
.lh-advance-credit-grid .k-grid-table.k-table {
    table-layout: fixed;
    width: 510px;
}
