/* Q94J: payment is an action near the original fees, not below their timeline. */
@media screen {
 body.classic #app .expense-book-detail { min-width:0; }
 body.classic #app .expense-book-detail :is(p,strong,h3,.form-error) { overflow-wrap:anywhere; }
 body.classic #app .expense-book-detail .expense-totals { display:flex; flex-wrap:wrap; gap:12px 28px; margin:12px 0; }
 body.classic #app .expense-book-detail .expense-totals span { display:flex; gap:8px; align-items:baseline; }
 body.classic #app .expense-book-detail .expense-list-head { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:8px; }
 body.classic #app .expense-book-detail .expense-record { display:grid; grid-template-columns:minmax(0,1fr) minmax(150px,auto); gap:6px 18px; border-top:1px solid #d6dce1; padding:10px 0; overflow-wrap:anywhere; }
 body.classic #app .expense-book-detail .expense-record p { margin:4px 0; }
 body.classic #app .expense-book-detail .expense-payment-history { grid-column:1/-1; }
 body.classic #app .expense-book-detail .expense-payment-history summary { cursor:pointer; padding:6px 0; }
 body.classic #app .expense-book-detail .expense-action { margin:12px 0; padding:12px; border:1px solid #cbd1d8; background:#fff; }
 body.classic #app .expense-book-detail .expense-action:empty { display:none; }
 body.classic #app #expensePayForm { display:grid; grid-template-columns:minmax(150px,.65fr) minmax(160px,.7fr) minmax(200px,1.65fr); align-items:start; gap:10px 16px; padding:0; max-width:none; }
 body.classic #app #expensePayForm > label { display:flex; flex-direction:column; gap:4px; min-width:0; }
 body.classic #app #expensePayForm :is(input,textarea) { width:100%; min-width:0; box-sizing:border-box; }
 body.classic #app #expensePayForm textarea { min-height:60px; }
 body.classic #app #expensePayForm > :is(button,.form-error) { grid-column:1/-1; justify-self:start; margin:0; }
 body.classic #app #expensePayForm .form-error:empty { display:none; }
}
@media screen and (min-width:701px) and (max-width:1099px) {
 body.classic #app #expensePayForm { grid-template-columns:repeat(2,minmax(0,1fr)); }
 body.classic #app #expensePayForm > label:has([name=remarks]) { grid-column:1/-1; }
}
@media screen and (max-width:700px) {
 body.classic #app #expensePayForm { grid-template-columns:minmax(0,1fr); }
 body.classic #app #expensePayForm > button { width:100%; min-height:44px; }
 body.classic #app .expense-book-detail .expense-record { grid-template-columns:minmax(0,1fr); }
 body.classic #app .expense-book-detail .expense-action { padding:8px; }
 body.classic #app .expense-worksheet table.expense-sheet-table textarea[data-field=remarks] { min-height:44px; font-size:16px; }
}
/* Q80: common document presentation. Screen-only; no accounting or print changes. */
@media screen {
 body.classic {--erp-field-height:30px;--erp-text-size:13px;font-size:13px;background:#f2f3f5;color:#30343a}
 body.classic .workspace {padding:0 14px 18px}
 body.classic #app {padding-top:10px}
 body.classic :is(button,.sheet-button) {min-height:30px;font-size:13px;padding:4px 10px}
 body.classic :is(input:not([type=checkbox]):not([type=radio]):not([type=hidden]),select,textarea) {min-height:30px;font-size:13px;border-radius:2px;padding:4px 6px}
 body.classic label,body.classic input::placeholder,body.classic textarea::placeholder {font-size:13px}
 body.classic :is(h2,h3) {font-size:16px;font-weight:600}
 body.classic .sidebar nav :is(button,.erp-nav-heading span),body.classic .sidebar-footer button {font-size:13px}
 body.classic .sidebar nav button {min-height:30px}
 body.classic .sidebar .erp-nav-chevron {flex:0 0 14px;width:14px;height:14px;line-height:14px;pointer-events:none;text-align:center}
 body.classic .topbar {min-height:36px}
 body.classic .document-tabs {flex-wrap:wrap;min-height:34px;gap:2px;overflow:visible}
 body.classic .document-tab {flex:0 0 auto}
 body.classic .document-tab button {min-height:30px;font-size:13px;padding:5px 9px;white-space:nowrap}
 body.classic .document-open-switcher {display:none}
 /* The sidebar is the sole module/view menu. Document status, original-draft
    actions, filters, process-row actions and detail return buttons stay visible. */
 body.classic #app :is(.classic-expense-tabs,.receipt-kind-tabs,.material-entry-links,#financeDesk .fd-tabs) {display:none!important}
 body.classic #app .document-modebar>:is(strong,#sheetHistory,#sheetNew),body.classic #app :is(#stockSummary,#stockLots,#matHistory,#sheetMaterialEntry) {display:none!important}
 body.classic #app .document-modebar {min-height:0;border:0;background:transparent;margin:0 0 6px;padding:0;gap:8px}
 body.classic #app .document-modebar:empty,body.classic #app .document-modebar:not(:has(>span,>#sheetReturnNew)) {display:none}
 body.classic #app .document-modebar>span {display:block;margin:0;color:#65717b;font-size:12px}
 body.classic #app .document-modebar>#sheetReturnNew {margin-left:auto}
 body.classic #app :is(.sheet-toolbar,.material-document-toolbar,.expense-document-toolbar) {display:flex;justify-content:flex-start;align-items:center;flex-wrap:wrap;gap:7px;padding:0 0 8px;margin:0 0 8px;border-bottom:1px solid #d6dce1}
 body.classic #app :is(.sheet-toolbar,.material-document-toolbar,.expense-document-toolbar)>h2 {margin:0 auto 0 0;font-size:16px;flex:0 1 auto}
 body.classic #app :is(.sheet-toolbar,.material-document-toolbar,.expense-document-toolbar)>button {min-height:30px;font-size:13px}
 body.classic #app.sheet-page .sheet-fields {grid-template-columns:repeat(3,minmax(0,1fr));gap:8px 18px;padding:8px 0 12px}
 body.classic #app.sheet-page .sheet-fields label {grid-template-columns:76px minmax(0,1fr);font-size:13px}
 body.classic #app.sheet-page :is(input:not([type=hidden]),select,textarea) {height:30px;min-height:30px;font-size:13px}
 body.classic #app :is(#masterForm,#foundationForm,#uomForm)>label {font-size:13px}
 body.classic #app :is(#masterForm,#foundationForm,#uomForm) :is(input:not([type=checkbox]):not([type=radio]),select,textarea) {font-size:13px;min-height:30px;height:30px}
 body.classic #app .material-page .mat-fields :is(label,input) {font-size:13px;min-height:30px}
 body.classic #app .material-page .mat-editbar textarea {min-height:30px;font-size:13px}
 body.classic #app #financeDesk .fd-toolbar {justify-content:flex-end;margin:0 0 8px;border:0}
 body.classic #app #financeDesk #fd-refresh {min-height:30px;font-size:13px;margin:0}
 body.classic #app #financeDesk .fd-pane {padding:12px}
 body.classic #app #financeDesk .fd-pane h2 {font-size:16px;margin:0 0 10px}
 body.classic #app #financeDesk .fd-document-form {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px 16px;align-items:start}
 body.classic #app #financeDesk .fd-document-form>label {grid-area:auto;min-width:0;display:flex;flex-direction:column;gap:4px;font-size:13px}
 body.classic #app #financeDesk :is(#cashForm,#chargeForm)>label {grid-row:auto}
 body.classic #app #financeDesk #cashForm>label:has(#cashDocument) {grid-column:span 2}
 body.classic #app #financeDesk #cashForm>label:has(#cashRemarks) {grid-column:span 2}
 body.classic #app #financeDesk #chargeForm>label:has(#chargeShipment),body.classic #app #financeDesk #chargeForm>label:has(#chargeParty),body.classic #app #financeDesk #chargeForm>label:has(#chargeRemarks) {grid-column:span 2}
 body.classic #app #financeDesk .fd-document-form>:is(button[type=submit],.form-error) {grid-column:1/-1;justify-self:start}
 body.classic #app #financeDesk .fd-document-form>button[type=submit] {min-width:100px;min-height:30px;margin-top:2px}
 body.classic #app #financeDesk .fd-document-toolbar {grid-column:1/-1;grid-row:1;display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px;margin:0 0 2px;padding:0 0 8px;border-bottom:1px solid #d6dce1}
 body.classic #app #financeDesk .fd-document-toolbar h2 {margin:0}
 body.classic #app #financeDesk .fd-document-toolbar>button {min-width:100px;min-height:30px;margin:0}
 body.classic #app #financeDesk .fd-document-form :is(input:not([type=hidden]),select,textarea) {height:30px;min-height:30px;font-size:13px;padding:4px 7px}
 body.classic #app #financeDesk :is(.editable-choice,.editable-choice input) {height:auto;min-height:30px;--choice-control-height:30px;font-size:13px}
 body.classic #app #financeDesk :is(small,#cashDocumentSearchHint,.fd-search,.fd-table-footer) {font-size:12px;line-height:1.5}
 body.classic #app #financeDesk :is(.fd-summary span,.fd-grid,.fd-grid th,.fd-grid td,button) {font-size:13px}
 body.classic #app #financeDesk .fd-summary strong {font-size:18px}
 body.classic #app #financeDesk .fd-grid :is(th,td) {padding:6px 8px}
 body.classic #app #financeDesk #purchasePaymentRecovery {font-size:13px}
 body.classic #app .expense-sheet-page {container-type:inline-size;container-name:classic-expense}
 body.classic #app .expense-sheet-page .expense-sheet-context {grid-template-columns:repeat(3,minmax(0,1fr));gap:10px 18px}
 body.classic #app .expense-sheet-page .expense-sheet-context label {font-size:13px;display:flex;align-items:center;gap:8px}
 body.classic #app .expense-sheet-page .expense-sheet-context label>:is(input,select,.editable-choice) {flex:1;min-width:0;width:0;font-size:13px;min-height:30px;height:auto}
 body.classic #app .expense-sheet-page .expense-sheet-context .editable-choice input {font-size:13px;min-height:30px;height:30px}
 body.classic #app .expense-worksheet .classic-expense-categories :is(button,span) {font-size:13px;min-height:30px}
 body.classic #app .expense-worksheet table.expense-sheet-table :is(th,td,input:not([type=hidden]),select,.editable-choice,.editable-choice input) {font-size:13px;line-height:1.45}
 body.classic #app .expense-worksheet table.expense-sheet-table :is(input:not([type=hidden]):not(.editable-choice-native),select:not(.editable-choice-native)) {min-height:30px;height:30px}
 body.classic #app .expense-worksheet table.expense-sheet-table .editable-choice {--choice-control-height:30px}
 body.classic #app .expense-worksheet table.expense-sheet-table .expense-cell-category {min-width:0}
 body.classic #app .expense-worksheet table.expense-sheet-table :is([data-field=quantity],[data-field=unitPrice],[data-field=amount]) {text-align:right;font-variant-numeric:tabular-nums}
 body.classic #app .document-row-inspector {font-size:12px;line-height:1.5}
 body.classic #app .document-row-inspector input {height:30px;min-height:30px;font-size:13px}
}
@media screen and (min-width:1100px) {
 body.classic #app table.ledger-entry-table:not(.expense-sheet-table) :is(th,td) {font-size:13px!important;height:32px!important}
 body.classic #app table.ledger-entry-table:not(.expense-sheet-table) :is(input:not([type=hidden]):not(.editable-choice-native),select:not(.editable-choice-native),textarea) {font-size:13px!important;height:30px!important;min-height:30px!important}
 body.classic #app table.ledger-entry-table:not(.expense-sheet-table) .editable-choice {--choice-control-height:30px;min-height:30px!important}
}
@container classic-expense (min-width:1491px) {
 body.classic #app .expense-worksheet table.expense-sheet-table thead th {width:auto!important;white-space:normal!important}
 body.classic #app .expense-worksheet table.expense-sheet-table thead th:first-child {width:36px!important}
 body.classic #app .expense-worksheet table.expense-sheet-table thead th:nth-child(2) {width:190px!important}
 body.classic #app .expense-worksheet table.expense-sheet-table thead th:nth-child(4) {width:128px!important}
 body.classic #app .expense-worksheet table.expense-sheet-table thead th:nth-child(8) {width:110px!important}
 body.classic #app .expense-worksheet table.expense-sheet-table thead th:last-child {width:65px!important}
}
@media screen and (min-width:701px) and (max-width:1099px) {
 body.classic #app.sheet-page .sheet-fields,body.classic #app #financeDesk .fd-document-form {grid-template-columns:repeat(2,minmax(0,1fr))}
 body.classic #app .expense-sheet-page .expense-sheet-context {grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media screen and (max-width:700px) {
 body.classic {--erp-field-height:44px;--erp-text-size:16px}
 body.classic .workspace {padding:0 8px 14px}
 body.classic .sidebar nav button.erp-nav-heading:not([hidden]) {display:flex!important;text-align:left;min-height:44px;justify-content:space-between;align-items:center}
 body.classic .document-tabs {overflow:visible;flex-wrap:wrap}
 body.classic .document-tabs .document-open-switcher {display:flex;flex:1 1 145px;margin-left:auto;justify-content:flex-end}
 body.classic .document-open-switcher>span {display:none}
 body.classic .document-open-switcher select {width:150px;min-height:40px}
 body.classic #app :is(input:not([type=checkbox]):not([type=radio]):not([type=hidden]):not(.editable-choice-native),select:not(.editable-choice-native),textarea,button) {min-height:44px;font-size:16px;height:auto}
 body.classic #app :is(.sheet-toolbar,.material-document-toolbar,.expense-document-toolbar)>h2 {flex-basis:100%}
 body.classic #app.sheet-page .sheet-fields,body.classic #app .expense-sheet-page .expense-sheet-context,body.classic #app #financeDesk .fd-document-form {grid-template-columns:minmax(0,1fr)}
 body.classic #app.sheet-page .sheet-fields label {grid-template-columns:76px minmax(0,1fr)}
 body.classic #app #financeDesk .fd-document-form>label {grid-column:1/-1!important;grid-row:auto!important}
 body.classic #app #financeDesk .fd-document-form>button[type=submit] {width:100%;min-height:44px}
 body.classic #app #financeDesk .fd-document-form :is(input:not([type=hidden]):not(.editable-choice-native),select:not(.editable-choice-native),textarea) {height:auto;min-height:44px;font-size:16px}
 body.classic #app #financeDesk .fd-document-toolbar>button {min-height:44px;font-size:16px}
 body.classic #app #financeDesk :is(.editable-choice,.editable-choice input) {min-height:44px;--choice-control-height:44px;font-size:16px}
 body.classic #app #financeDesk #fd-refresh {min-height:44px}
 body.classic #app .expense-sheet-page .expense-sheet-context label {display:block}
 body.classic #app .expense-sheet-page .expense-sheet-context label>:is(input,select,.editable-choice) {display:block;flex:none;width:100%;margin-top:4px;min-height:44px}
 body.classic #app .expense-sheet-page .expense-sheet-context .editable-choice input {min-height:44px;font-size:16px}
 body.classic #app .expense-worksheet table.expense-sheet-table :is(input:not([type=hidden]):not(.editable-choice-native),select:not(.editable-choice-native)) {min-height:44px;height:44px;font-size:16px}
 body.classic #app .expense-worksheet table.expense-sheet-table .editable-choice {--choice-control-height:44px}
 body.classic #app .expense-worksheet .classic-expense-categories button {min-height:44px}
}
