/* General ledger screens (gl-*.js): chart, journal, invoices, reports, settings */
.gl { display: flex; flex-direction: column; gap: var(--bo-3, 12px); }
.gl-bar { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; }
.gl-grow { flex: 1 1 220px; }
.gl .in, .gl-form .in {
  min-height: var(--bo-ctrl-h-sm); padding: 0 .7rem; border: 1px solid var(--bo-line); border-radius: var(--bo-r-sm);
  background: var(--bo-surface); font: inherit; color: var(--bo-ink); min-width: 0;
}
.gl .in:focus, .gl-form .in:focus { outline: 2px solid rgba(41, 171, 226, .35); border-color: var(--bo-blue); }
.gl-tbl { width: 100%; border-collapse: collapse; }
.gl-tbl th, .gl-tbl td { padding: 8px 10px; border-bottom: 1px solid var(--bo-line); text-align: start; }
.gl-tbl .num, .gl-lines .num { font-variant-numeric: tabular-nums; text-align: end; white-space: nowrap; }
.gl-tbl td.num, .gl-tbl th.num, .gl-lines td.num, .gl-lines th.num { display: table-cell; direction: ltr; }
.gl-tbl tfoot th { background: var(--bo-bg); }
.gl-click { cursor: pointer; transition: background .15s; }
.gl-click:hover { background: var(--bo-bg); }
.gl-ind { display: inline-block; width: calc((var(--lv, 1) - 1) * 16px); }
.gl-lv3 td { font-weight: 600; }
.gl-off td { opacity: .55; }
.gl-lv1 td { font-weight: 800; background: var(--bo-bg); }
.gl-lv2 td { font-weight: 700; }
.gl-tag { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: .75rem; background: #e8f6ee; color: var(--bo-green); }
.gl-tag--bad { background: #fdecec; color: var(--bo-red); }
.gl-bad { color: var(--bo-red); }
.gl-bal { margin-inline-start: auto; font-variant-numeric: tabular-nums; }
.gl-form { display: flex; flex-direction: column; gap: 12px; padding: 4px 2px; }
.gl-narrow { max-width: 520px; }
.modal__card:has(.gl-wide) { width: min(980px, 100%); }
.modal__card > .gl-form { padding: 1.1rem 1.3rem; overflow: auto; flex: 1 1 auto; min-height: 0; }
.gl-form .tablewrap, .gl-lines { max-width: 100%; overflow-x: auto; }
.gl-lines { width: 100%; border-collapse: collapse; }
.gl-lines th { font-size: .78rem; color: var(--bo-muted); text-align: start; padding: 4px; }
.gl-lines td { padding: 4px; }
.gl-lines .in { width: 100%; }
.gl-tabs { display: flex; flex-wrap: wrap; gap: 6px; border-bottom: 1px solid var(--bo-line); }
.gl-tab { border: 0; background: none; padding: 8px 14px; font: inherit; font-weight: 600; color: var(--bo-muted); cursor: pointer; border-bottom: 2px solid transparent; transition: color .15s, border-color .15s; }
.gl-tab:hover { color: var(--bo-ink); }
.gl-tab.on { color: var(--bo-ink); border-bottom-color: var(--bo-orange); }
.gl-inv__head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; }
.gl-inv__head h2 { margin: 0 0 4px; }
.gl-inv__head p { margin: 2px 0; }
.gl-qr svg { width: 132px; height: 132px; display: block; }
.gl-inv__tot { display: flex; justify-content: flex-end; gap: 22px; font-variant-numeric: tabular-nums; }
@media (max-width: 720px) {
  .gl-lines thead { display: none; }
  .gl-lines tr { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 6px 0; border-bottom: 1px solid var(--bo-line); }
}
@media print {
  body.gl-printing > *:not(.modal):not(#modal) { display: none !important; }
  .gl-noprint, .modal__x { display: none !important; }
}
