/* BQ Estimator - only what the BQ pages need on top of assets/logistics.css (the Internal Logistics stylesheet, copied
   unchanged so both apps are one product). Colours come from the logistics tokens (--ew-*). */

.brand-teal { color: var(--ew-teal); }
.mono { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: .9em; }
pre.mono { background: var(--ew-soft); border: 1px solid var(--ew-line); padding: 10px; border-radius: 10px; max-height: 420px; overflow: auto; font-size: .78rem; white-space: pre-wrap; }
.yes { color: #166534; font-weight: 600; }
.no { color: #b91c1c; font-weight: 600; }
.na { color: #8a99aa; }
.review { color: #92400e; font-weight: 600; }
.level-FAIL { color: #b91c1c; font-weight: 700; }
.level-WARN { color: #92400e; font-weight: 700; }
.level-OK { color: #166534; }
.level-NOT { color: #8a99aa; }
.cost-col { background: #fff8e6; }
.muted-small { font-size: .8rem; color: var(--ew-muted); }
details > summary { cursor: pointer; color: var(--ew-dark); font-weight: 600; }
details.small > summary { font-weight: 500; }
dl.row dt { font-weight: 600; color: #8a99aa; font-size: 12.5px; }
dl.row dd { margin-bottom: .35rem; color: var(--ew-ink); }

/* ---- BOQ line tables */
.lg tr.band > td, .lg tr.band > th { background: var(--ew-dark) !important; color: #fff !important; font-weight: 600; }
.lg tr.sub > td { background: var(--ew-tint) !important; color: var(--ew-dark) !important; font-weight: 600; }
tr.removed td { color: #999 !important; text-decoration: line-through; }
tr.removed td form, tr.removed td .no-strike { text-decoration: none; }
.lines-table td.edit { white-space: nowrap; }
.lines-table td.edit .form-control-sm, .lines-table td.edit .form-check-label { font-size: .8rem; }
.lines-table .inline { width: 90px; display: inline-block; }
.lg .table .form-control-sm, .lg .table .form-select-sm { font-size: .8rem; }

/* ---- forms */
.lg .form-label.small { font-size: 12.5px; font-weight: 600; color: #3b4a5a; margin-bottom: 4px; }
.form-text { font-size: 12.5px; color: var(--ew-muted); }
.group-box { border: 1.5px dashed #cfe1e8; padding: 12px 14px; border-radius: 13px; margin-bottom: 10px; background: var(--ew-tint2); }
.w-short { max-width: 140px; }

/* ---- item pickers (assets/app.js): the results drop down like the logistics .lg-sugg */
.item-picker { position: relative; }
.item-results { position: absolute; z-index: 1050; left: 0; top: 100%; width: 100%; min-width: 320px; max-width: 640px; max-height: 280px; overflow: auto; background: #fff;
                border: 1px solid var(--ew-line); border-radius: 12px; box-shadow: 0 12px 32px rgba(15, 31, 42, .16); padding: 6px; }
.item-results .list-group-item { cursor: pointer; font-size: 13px; padding: 7px 10px; text-align: left; border: 0; border-radius: 8px; }
.item-results .list-group-item:hover, .item-results .list-group-item:focus { background: var(--ew-tint2); }
.chosen { font-size: 12.5px; color: #166534; display: block; min-height: 1em; }

/* ---- run progress box on the BOQ page */
.run-progress { border-left: 4px solid #d97706 !important; }

/* ---- the discussion panel (lib/thread_ui.php) */
.th-item { border-left: 3px solid var(--ew-teal); padding: 2px 0 2px 14px; margin-bottom: 14px; }
.th-item.reply { margin-left: 26px; border-left-color: #cfe1e8; }
.th-item .who { font-weight: 600; color: var(--ew-ink); }
.th-item .when { font-size: 12px; color: var(--ew-muted); margin-left: 6px; }
.th-item .body { margin-top: 3px; white-space: normal; }
.th-item .acts { font-size: 12.5px; margin-top: 4px; display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.th-file { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--ew-line); border-radius: 9px; padding: 4px 9px; font-size: 12.5px; background: #fff; margin: 3px 6px 3px 0; }
.th-file .sz { color: var(--ew-muted); }
.th-mention { background: var(--ew-tint); color: var(--ew-dark); border-radius: 6px; padding: 0 5px; font-weight: 600; }
.btn-link-plain { border: 0; background: none; padding: 0; color: var(--ew-dark); font-weight: 600; }
.btn-link-plain.danger { color: #b91c1c; }

/* ---- login */
.login-wrap { max-width: 440px; margin: 0 auto; }

/* ---- the header bar on a narrow screen: the BQ bar carries more than the logistics one (preview mark, bell, role),
        so it wraps instead of pushing the page sideways */
.lg-bar { flex-wrap: wrap; row-gap: 8px; }
.lg-user { display: flex; flex-wrap: wrap; align-items: center; row-gap: 4px; }
@media (max-width: 768px) {
    .lg-logo img { height: 40px; }
    .lg-user { margin-left: 0; width: 100%; }
    .lg-user .opacity-75 { display: none; }
}

/* ---- the pipeline board: one column per stage, cards for the enquiries (scrolls sideways inside the page) */
.crm-board { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 8px; margin-bottom: 18px; }
.crm-col { flex: 0 0 250px; background: #fff; border: 1px solid #e6ecf1; border-radius: 16px; box-shadow: var(--ew-shadow); padding: 10px; max-height: 720px; overflow-y: auto; }
.crm-col-hd { position: sticky; top: -10px; background: #fff; padding: 4px 2px 8px; margin: -2px 0 6px; border-bottom: 1px solid #edf1f5; z-index: 1; }
.crm-col-hd .sub { color: var(--ew-muted); font-size: 12px; }
.crm-card { display: block; border: 1px solid #e3e9ef; border-radius: 11px; padding: 8px 10px; margin-bottom: 8px; text-decoration: none; color: var(--ew-text) !important; transition: border-color .15s, box-shadow .15s; }
.crm-card:hover { border-color: #9fd6e2; box-shadow: 0 4px 12px rgba(15, 31, 42, .08); }
.crm-card .t { font-weight: 600; color: var(--ew-ink); font-size: 13px; margin-top: 4px; line-height: 1.3; }
.crm-card .sub { color: var(--ew-muted); font-size: 12px; }
/* bars in the reports */
.crm-bar { height: 8px; background: #e5ebf1; border-radius: 99px; overflow: hidden; min-width: 80px; }
.crm-bar > i { display: block; height: 100%; background: linear-gradient(90deg, var(--ew-teal), var(--ew-dark)); border-radius: 99px; }
/* where an enquiry is: the chain INQ -> BOQ -> QUO -> client -> PO (lib/chain.php). done teal, now amber (red when
   it sat too long), todo grey, skip dashed, bad red */
.chain { display: flex; align-items: flex-start; }
.chain .st { position: relative; flex: 1 1 0; min-width: 52px; text-align: center; font-size: 11px; line-height: 1.25; color: var(--ew-muted); text-decoration: none; }
.chain .st::before { content: ''; position: absolute; top: 9px; left: -50%; width: 100%; height: 2px; background: #dbe3ea; }
.chain .st:first-child::before { display: none; }
.chain .st.done::before, .chain .st.bad::before { background: var(--ew-teal); }
.chain .st .dot { position: relative; display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; border: 2px solid #cbd5e1; background: #fff; font-style: normal; font-size: 11px; color: #fff; }
.chain .st.done .dot { background: var(--ew-teal); border-color: var(--ew-teal); }
.chain .st.now .dot { border-color: #f59e0b; background: #fffbeb; box-shadow: 0 0 0 3px #fde68a; }
.chain .st.now.late .dot { border-color: #dc2626; background: #fef2f2; box-shadow: 0 0 0 3px #fecaca; }
.chain .st.bad .dot { background: #dc2626; border-color: #dc2626; }
.chain .st.skip .dot { border-style: dashed; }
.chain .st .lb { display: block; font-weight: 700; color: var(--ew-ink); margin-top: 2px; }
.chain .st.todo .lb, .chain .st.skip .lb { color: #94a3b8; font-weight: 600; }
.chain .st .sb { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 0 2px; }
.chain .st.now .sb { color: #b45309; font-weight: 600; }
.chain .st.now.late .sb { color: #b91c1c; }
.chain .st.bad .sb { color: #b91c1c; }
.chain.closed .st.now .dot { box-shadow: none; }
.chain.lg .st { font-size: 12px; min-width: 100px; }
.chain.lg .st::before { top: 13px; }
.chain.lg .st .dot { width: 28px; height: 28px; font-size: 14px; }
.chain.lg .st .lb { font-size: 13px; margin-top: 4px; }
.chain.lg .st .sb { white-space: normal; }
.chain.lg .st .who { display: block; color: var(--ew-ink); font-weight: 600; margin-top: 2px; }
.chain.lg .st .who small { color: var(--ew-muted); font-weight: 500; }
.chain.lg .st .since { display: block; color: var(--ew-muted); }
.chain.lg .st.now.late .since { color: #b91c1c; font-weight: 600; }
.chain.lg a.st:hover .lb { text-decoration: underline; }
.chain-ball { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 12px; padding: 10px 12px; border-radius: 12px; background: #fffbeb; border: 1px solid #fde68a; font-size: 13px; }
.chain-ball.late { background: #fef2f2; border-color: #fecaca; }
.chain-ball.done { background: #f1f5f9; border-color: #e2e8f0; }
.chain-ball i.bi { font-size: 18px; color: #b45309; }
.chain-ball.late i.bi { color: #b91c1c; }
.chain-ball.done i.bi { color: var(--ew-muted); }
.lg-table td .chain { width: 300px; min-width: 300px; font-size: 10px; }   /* one compact line in a list; the names under the steps are cut, the With column says them in full */
.lg-table td .chain .st { min-width: 50px; font-size: 10px; }
.crm-card .chain { margin-top: 6px; }
.crm-card .chain .st { min-width: 36px; }
.crm-card .chain .st .lb { font-size: 10px; }
/* a detail page: the wide content first, then the side cards flowing in columns (quote_view, enquiry_view) */
.card-cols { column-count: 3; column-gap: 16px; }
.card-cols > .lg-card, .card-cols > form, .card-cols > div { break-inside: avoid; display: block; }
@media (max-width: 1400px) { .card-cols { column-count: 2; } }
@media (max-width: 900px) { .card-cols { column-count: 1; } }
/* a divider inside the tab bar: entry tabs | overview tabs */
.lg-tabs .sep { display: inline-block; width: 1px; align-self: stretch; margin: 6px 10px; background: rgba(15, 48, 64, .18); }
/* a page's own tabs under the area tabs (the BOQ page: Overview, Lines, Review ...): lighter, one step down */
.lg-tabs.page { margin-top: -4px; margin-bottom: 14px; background: transparent; border-bottom: 1px solid rgba(15, 48, 64, .14); box-shadow: none; }
.lg-tabs.page a { font-size: .85rem; }
.parts-table td, .parts-table th { padding: .2rem .3rem; }
.parts-table .part-stock { font-size: .72rem; }
/* the account's win rate per pillar: five bars in one line, the icon, the name and the rate on the bar itself */
.win-chart { width: 100%; }
.win-chart .cap { font-size: .76rem; color: #35505f; margin: 0 0 4px; }
.win-chart .cap.sub { margin: 4px 0 0; color: #6b7c87; }
.win-chart .cap .tot { color: #6b7c87; }
.win-chart .bars { display: flex; gap: 6px; }
.win-chart .cell { position: relative; flex: 1 1 0; min-width: 0; height: 46px; background: #e6eef2; border-radius: 8px; overflow: hidden; }
.win-chart .cell .fill { position: absolute; top: 0; bottom: 0; left: 0; background: rgba(29, 107, 132, .38); }
.win-chart .cell.on { box-shadow: inset 0 0 0 2px #0f3040; }
.win-chart .cell.on .fill { background: rgba(15, 48, 64, .42); }
.win-chart .cell.none { background: #f1f5f8; color: #8a99a3; }
.win-chart .txt { position: relative; display: flex; flex-direction: column; justify-content: center; height: 100%; padding: 3px 8px; font-size: .74rem; line-height: 1.2; color: #10202b; white-space: nowrap; }
.win-chart .nm { display: inline-flex; align-items: center; gap: 5px; font-weight: 600; }
.win-chart .nm i { font-size: .9rem; color: #0f3040; }
.win-chart .pc { font-size: .82rem; }
.win-chart .pc small { color: #35505f; margin-left: 4px; font-size: .68rem; }
@media (max-width: 700px) { .win-chart .bars { flex-wrap: wrap; } .win-chart .cell { flex: 1 1 30%; } }
/* sections inside one card (the quotation page) */
.qv-tabs .nav-link { padding: 4px 12px; font-size: .84rem; border-radius: 999px; color: #35505f; }
.qv-tabs .nav-link.active { background: #0f3040; color: #fff; }
.scope-table th, .scope-table td { padding: .2rem .4rem; min-width: 150px; }
/* the M&S sheet: sections as rows, totals under */
.ms-sheet tr.ms-sec td { background: #e6eef2; padding: .35rem .5rem; }
.ms-sheet tr.ms-sec .opt { font-weight: 400; color: #5a6b76; font-size: .78rem; }
.ms-sheet tfoot td { font-weight: 700; border-top: 2px solid #0f3040; }
.ms-sheet td { vertical-align: top; }
.ms-sheet [data-out], .ms-sheet [data-total] { white-space: nowrap; }
/* dense lists: one line per record */
.lg-table.compact td, .lg-table.compact th { padding: .35rem .5rem; vertical-align: middle; }
/* the chain inside a dense list: one line under each step, no holder line */
.lg-table.compact .chain .st .who { display: none; }
.lg-table.compact .chain .st .sb { max-height: 1.3em; }
.lg-table.compact .chain .st .sb + .sb { display: none; }
.lg-table.compact td .sub { line-height: 1.2; }
/* the one filter bar of a list */
.lg-filter { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.lg-filter .form-select { width: auto; max-width: 240px; padding-right: 1.9rem; font-size: .82rem; }
.lg-filter .form-select.on { border-color: #1d6b84; background-color: #eef6f8; font-weight: 600; }
.lg-filter .lg-filter-q { display: flex; gap: 4px; }
.lg-filter .lg-filter-q input { width: 200px; font-size: .82rem; }
.lg-table.compact td { white-space: nowrap; }
.lg-table.compact td .text-truncate, .lg-table.compact td.text-truncate { white-space: nowrap; }
/* the Sales section of the dashboard: the flow (enquiries to orders) on the first row, the overview (pipeline, reports) on the second (owner, 2026-10-14) */
.lg-tiles.flow { margin-bottom: 16px; }
.lg-tiles.overview { grid-template-columns: repeat(auto-fill, minmax(228px, 1fr)); }
/* the bar that offers to put unfinished work back into a form */
.lg-autosave { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; padding: 8px 12px; border-radius: 10px; background: #fffbeb; border: 1px solid #fde68a; font-size: .86rem; }
.lg-autosave i { color: #b45309; font-size: 1.1rem; } .lg-autosave > div { flex: 1; }
/* the ROR sheet: the unit, the scope and the parts stacked under the row (owner, 2026-10-14: side by side looked disarranged) */
.ror-detail { background: #f7fafc; border: 1px solid #e3eaf0; border-radius: 10px; padding: 12px 14px; }
.ror-detail .lg-label { margin-top: 2px; }
.ror-detail .ror-scope td { border: 0; }
.ror-detail .parts-table th { font-size: .74rem; }

.ror-sheet { table-layout: fixed; }   /* the header widths hold: the equipment and type selects stay readable */
/* under 1,200 px (small laptop, tablet, phone; review 3.5, owner 2026-10-18/19): an estimate sheet (ROR, M&S, Supply) becomes one card per row, each field under its
   column's name (estimate.js labelCells); the unit's details open full width under the card; a part line is a small card */
@media (max-width: 1199.98px) {
  .card-sheet, .card-sheet > tbody, .card-sheet > tfoot { display: block; width: 100% !important; }
  .card-sheet > thead { display: none; }
  .card-sheet > tbody > tr, .card-sheet > tfoot > tr { display: block; }
  .card-sheet > tbody > tr > td, .card-sheet > tfoot > tr > td { display: block; width: auto !important; border: 0; padding: 0; }
  .card-sheet > tbody > tr.ms-sec > td, .card-sheet > tbody > tr.alt-head > td { padding: 8px 2px 4px; }
  .card-sheet > tbody > tr.ms-sec .btn { white-space: nowrap; }
  .card-sheet > tbody > tr.ms-sec { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; border-bottom: 1px solid #e3eaf0; }
  .card-sheet > tbody > tr.alt-head { display: flex; justify-content: space-between; align-items: center; }
  .card-sheet > tbody > tr.alt-head > td:empty, .card-sheet > tbody > tr.alt-head > td:nth-child(3) { display: none; }
  .card-sheet > tbody > tr.row-main { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px 12px; align-items: end;
    margin: 8px 0; padding: 10px 12px; border: 1px solid #e3eaf0; border-radius: 12px; background: #fff; }
  .card-sheet > tbody > tr.row-main > td[data-label]::before { content: attr(data-label); display: block; font-size: .7rem; font-weight: 600; color: #6c7a84; margin-bottom: 2px; }
  .card-sheet > tbody > tr.row-main > td[data-label="kW"] .dlabel { display: none; }
  .card-sheet > tbody > tr.row-main > td[data-row-index] { grid-column: 1 / -1; font-weight: 700; color: var(--ew-ink) !important; }
  .card-sheet > tbody > tr.row-main > td[data-row-index]:empty, .card-sheet > tbody > tr.row-main > td:empty { display: none; }
  .card-sheet > tbody > tr.row-main > td[colspan] { grid-column: 1 / -1; }
  .card-sheet > tbody > tr.row-main > td:last-child { grid-column: 1 / -1; text-align: left !important; }
  .card-sheet > tbody > tr.row-main > td.text-end, .card-sheet > tbody > tr.row-main > td.num { text-align: left !important; }
  .ror-sheet > tbody > tr.ror-equip > td[data-row-index]::before { content: 'Unit '; display: inline; text-transform: none; font-size: inherit; color: inherit; letter-spacing: 0; }
  .ror-sheet > tbody > tr.row-detail > td:first-child { display: none; }
  .card-sheet > tbody > tr.row-main > td:first-child:not([data-row-index]) { grid-column: 1 / -1; }   /* M&S and Supply: "What" across the card */
  .card-sheet > tbody > tr.row-detail > td { padding: 0 0 8px; }
  .card-sheet > tfoot > tr.ms-tot { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 12px; padding: 10px 2px; border-top: 2px solid #e3eaf0; }
  .card-sheet > tfoot > tr.ms-tot > td:first-child { grid-column: 1 / -1; text-align: left !important; }
  .card-sheet > tfoot > tr.ms-tot > td[data-label]::before { content: attr(data-label); display: block; font-size: .7rem; font-weight: 600; color: #6c7a84; }
  .card-sheet > tfoot > tr.ms-tot > td:empty { display: none; }
  .ror-detail .unit-grid .form-label { white-space: normal; }
  .ror-detail .lib-pick select, .ror-detail .lib-find, .ror-detail .lib-find input { max-width: 100% !important; }
  /* a part line: a small card, the part's name across, then its boxes */
  .ror-detail .parts-table, .ror-detail .parts-table > tbody { display: block; }
  .ror-detail .parts-table > thead { display: none; }
  .ror-detail .parts-table > tbody > tr:not(.d-none) { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 6px 10px; align-items: end;
    padding: 8px 0; border-bottom: 1px solid #e3eaf0; }
  .ror-detail .parts-table > tbody > tr > td { display: block; border: 0; padding: 0 !important; width: auto !important; }
  .ror-detail .parts-table > tbody > tr > td:first-child, .ror-detail .parts-table > tbody > tr > td.position-relative { grid-column: 1 / -1; }
  .ror-detail .parts-table > tbody > tr > td[data-label]:not(:first-child)::before { content: attr(data-label); display: block; font-size: .68rem; font-weight: 600; color: #6c7a84; }
  .ror-detail .parts-table td[data-part-price] { text-align: left !important; }
  .ror-detail .ror-scope, .ror-detail .ror-scope > tbody, .ror-detail .ror-scope tr, .ror-detail .ror-scope td { display: block; width: auto !important; }
  .ror-detail .ror-scope > thead { display: none; }
}
/* the floating total on a phone: one short line of text, the button beside it */
@media (max-width: 575.98px) {
  .lg-save[data-estimate-live] { flex-wrap: nowrap; gap: 10px; padding: 8px 10px; bottom: 8px; }
  .lg-save[data-estimate-live] .sum { font-size: 12px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .lg-save[data-estimate-live] .sum span[style] { display: none; }
  .lg-save[data-estimate-live] .btn { width: auto; padding: 8px 12px; font-size: 13px; }
}
.ror-sheet td, .ror-sheet th { overflow: visible; }
.ror-sheet td[data-out="price"] { white-space: normal; font-size: .78rem; line-height: 1.25; }
/* the ROR unit block: one label size, one field height; the nameplate photo beside its text */
.ror-detail .unit-grid .form-label { font-size: .74rem; color: #475569; margin-bottom: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ror-detail .nameplate-thumb { max-width: 200px; max-height: 130px; border-radius: 6px; border: 1px solid #dbe3ea; object-fit: contain; background: #fff; }
.ror-detail .parts-table td[data-part-price] { white-space: nowrap; }
.ror-sheet td[data-out="price"] div { white-space: nowrap; }
/* the pillar filter: icon buttons in one row (owner, 2026-10-15) */
.lg-filter-icons { display: inline-flex; gap: 2px; padding: 2px; border: 1px solid #dbe3ea; border-radius: 8px; background: #fff; }
.lg-filter-icons .fi { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 6px; font-size: .8rem; color: #475569; cursor: pointer; white-space: nowrap; margin: 0; }
.lg-filter-icons .fi:hover { background: #f1f5f8; }
.lg-filter-icons .fi.on { background: #1d6b84; color: #fff; font-weight: 600; }
.lg-filter-icons .fi small { font-size: .7rem; opacity: .75; }
.lg-filter-icons .fi:focus-within { outline: 2px solid #94c7d6; outline-offset: 1px; }

/* a factor box holds "×1.8" in full (owner, 2026-10-15) */
.ms-sheet input[name$="[factor]"] { min-width: 72px; padding-left: 6px; padding-right: 6px; text-align: center; }
/* the alternative rows share the sheet's columns (owner, 2026-10-15): name under equipment + type, cost and factor under work */
.ror-sheet .alt-factor { width: 72px; flex: none; }
.ror-sheet tr.alt-head td { font-size: .7rem; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; color: var(--bs-secondary-color, #6c757d); padding-top: 4px; padding-bottom: 2px; border-bottom: 0; }
/* a document number in the text opens its item (app.js): the text's own colour, a dotted underline */
a.doclink { color: inherit; text-decoration: underline dotted; text-underline-offset: 2px; }
a.doclink:hover { text-decoration-style: solid; }
/* the source of a cost (estimate.js, owner 2026-10-16): the Accurate document under the box, a typed cost asks for its source */
.cost-ref { font-size: .68rem; color: #6c7a84; line-height: 1.2; margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; cursor: help; }
.cost-ref:empty { display: none; }
.cost-note { margin-top: 2px; font-size: .72rem !important; padding: 1px 6px !important; }
input.cost-unsourced { border-color: #e0a800 !important; box-shadow: 0 0 0 .12rem rgba(224, 168, 0, .2) !important; }
.cost-landed { display: flex; align-items: center; gap: 4px; margin-top: 2px; font-size: .7rem; color: #6c7a84; justify-content: flex-end; }
.cost-landed input { width: 52px; padding: 0 4px !important; font-size: .72rem !important; text-align: center; }
/* the M&S day boxes: each keeps its label under it (owner, 2026-10-16) */
.ms-sheet .dbox { flex: 1 1 0; min-width: 0; }
.ms-sheet .dlabel { font-size: .66rem; color: #6c7a84; text-align: center; line-height: 1.1; margin-top: 1px; white-space: nowrap; }
/* quantity and unit boxes never squeeze below what they hold ("Pcs" showed as "P", "20" as "2(", owner 2026-10-16): the sheet scrolls instead */
.ms-sheet input[name$="[qty]"], .ms-sheet input[name$="[persons]"] { min-width: 58px; }
.ms-sheet input[name$="[unit]"] { min-width: 62px; }
.ms-sheet td[data-out="unit"] { min-width: 62px; white-space: nowrap; }
/* the board card (owner, 2026-10-16: the mini chain was too cramped): number and value, title, client, who has it */
.crm-card .v { font-size: 12px; font-weight: 600; color: var(--ew-ink); white-space: nowrap; }
.crm-card .t { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.crm-card .who { display: flex; align-items: center; gap: 6px; margin-top: 6px; padding-top: 6px; border-top: 1px dashed #e3e9ef; font-size: 12px; color: #4a5a64; }
.crm-card .who i { width: 8px; height: 8px; border-radius: 50%; background: #e0a800; flex: none; }
.crm-card .who.stale { color: #c0392b; font-weight: 600; }
.crm-card .who.stale i { background: #c0392b; }

/* ---- the sales dashboard (pipeline.php, 2026-10-16): one grid, one gap (the cards' own bottom margin off), equal card
        heights per row, the same 22px inner edge everywhere */
.dash { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 18px; margin-bottom: 18px; }
.dash > .span-12 { grid-column: span 12; }
.dash > .span-7 { grid-column: span 7; }
.dash > .span-5 { grid-column: span 5; }
@media (max-width: 1199px) { .dash > .span-7, .dash > .span-5 { grid-column: span 12; } }
.dash .lg-card { margin-bottom: 0; height: 100%; display: flex; flex-direction: column; }
.dash .lg-card > .bd { flex: 1 1 auto; display: flex; flex-direction: column; }
.dash .lg-card > .bd > .dash-key { margin-top: auto; }
.dash .lg-card > .bd:not(.flush) > .dash-key { margin: auto -22px -20px; padding-top: 12px; }
.dash-key { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 18px; padding: 12px 22px; border-top: 1px solid #edf1f5; font-size: 12px; color: var(--ew-muted); }
.dash-key i { display: inline-block; width: 14px; height: 10px; border-radius: 2px; margin-right: 5px; vertical-align: -1px; }
.dash-key .k-won { background: var(--ew-teal); }
.dash-key .k-charge { background: repeating-linear-gradient(135deg, rgba(14,168,192,.5) 0 3px, transparent 3px 6px); border: 1px solid rgba(14,168,192,.5); }
.dash-key .k-pace { width: 0; height: 12px; border-left: 2px dashed var(--ew-ink); border-radius: 0; }
.dash-key .k-ok { background: #16a34a; } .dash-key .k-warn { background: #f59e0b; } .dash-key .k-bad { background: #dc2626; }
.dash-key .k-now { background: #f2fbfd; border: 1px solid #9fd6e2; }
.dash-key .k-cost { background: #dbe3ea; }
.dash-foot { padding: 12px 22px; border-top: 1px solid #edf1f5; font-size: 13px; color: var(--ew-muted); }
.tgt-form { padding: 16px 22px; border-bottom: 1px solid #edf1f5; background: var(--ew-tint2); }
.seg { display: inline-flex; border: 1px solid #d6e2ea; border-radius: 9px; overflow: hidden; background: #fff; }
.seg a { padding: 4px 12px; font-size: 12.5px; color: var(--ew-text); text-decoration: none; }
.seg a + a { border-left: 1px solid #d6e2ea; }
.seg a.on { background: var(--ew-dark); color: #fff; }

/* revenue against target: per pillar a battery whose cells are the quarters (or months), each its share of the target */
.tgt-rows { display: flex; flex-direction: column; }
.tgt-row { display: grid; grid-template-columns: 110px minmax(0, 1fr) 210px; gap: 22px; align-items: center; padding: 14px 22px 12px; border-bottom: 1px solid #f1f5f8; }
.tgt-row.on { background: var(--ew-tint2); }
.tgt-row.dim { opacity: .5; }
.tgt-row.total { background: #fafcfd; border-bottom: 0; }
.tgt-row .nm a { text-decoration: none; }
.tgt-row .fig { font-size: 12.5px; color: var(--ew-muted); display: flex; flex-direction: column; gap: 1px; line-height: 1.35; }
.tgt-row .fig > b { font-size: 15px; color: var(--ew-ink); }
.tgt-row .fig b.yr { color: var(--ew-ink); }
@media (max-width: 991px) { .tgt-row { grid-template-columns: 1fr; gap: 8px; } }
.pace-t { white-space: nowrap; }
.pace-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 5px; vertical-align: 1px; }
.pace-dot.ok { background: #16a34a; } .pace-dot.warn { background: #f59e0b; } .pace-dot.bad { background: #dc2626; }   /* not ".st": the progress chain uses that class */
.batt2 { position: relative; display: flex; gap: 3px; height: 30px; margin-right: 8px; padding: 3px; border: 2px solid #cbd5e1; border-radius: 8px; background: #fff; }
.batt2::after { content: ""; position: absolute; right: -8px; top: 8px; width: 5px; height: 10px; border-radius: 0 3px 3px 0; background: #cbd5e1; }   /* the terminal */
.batt2 .cl { position: relative; flex: 1 1 0; min-width: 0; border-radius: 3px; background: #eef2f6; overflow: hidden; }
.batt2 .cl > i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--c); }
.batt2 .cl > s { position: absolute; top: 0; bottom: 0; background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--c) 50%, transparent) 0 4px, transparent 4px 8px); }
.batt2 .cl.future { background: repeating-linear-gradient(135deg, #f1f5f8 0 4px, #fff 4px 8px); }
.batt2 .cl.now { box-shadow: inset 0 0 0 1.5px var(--ew-ink); }
.batt2 .cl.over > i { box-shadow: inset 0 0 0 2px rgba(255,255,255,.55); }
.batt2 > .pace { position: absolute; z-index: 2; top: -7px; bottom: -7px; width: 0; border-left: 2px dashed var(--ew-ink); opacity: .75; }
.batt2.none { border-style: dashed; }
.batt2-lb { display: flex; gap: 3px; margin: 5px 8px 0 5px; }
.batt2-lb > span { flex: 1 1 0; min-width: 0; text-align: center; font-size: 11.5px; color: var(--ew-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.batt2-lb b { font-weight: 600; color: var(--ew-text); margin-right: 4px; }
.batt2-lb em { font-style: normal; font-weight: 600; }
.batt2-lb .ok em { color: #15803d; } .batt2-lb .warn em { color: #b45309; } .batt2-lb .bad em { color: #b91c1c; } .batt2-lb .now em { color: var(--ew-dark); }
.batt2-lb .future { color: #a3b1bd; } .batt2-lb .future b { color: #a3b1bd; font-weight: 500; }
.tgt-rows.months .batt2-lb > span { display: flex; flex-direction: column; line-height: 1.2; }
.tgt-rows.months .batt2-lb b { margin-right: 0; }
/* revenue mix */
.donut-wrap { display: flex; gap: 24px; align-items: center; flex-wrap: wrap; flex: 1 1 auto; }
.donut { width: 180px; height: 180px; flex: 0 0 180px; }
.donut circle { transition: stroke-width .15s; }
.donut a:hover circle { stroke-width: 24; }
.donut .d-big { font-size: 13px; font-weight: 700; fill: var(--ew-ink); }
.donut .d-sub { font-size: 9px; fill: var(--ew-muted); }
.donut-key { flex: 1 1 160px; display: flex; flex-direction: column; gap: 2px; }
.donut-key a { display: grid; grid-template-columns: 12px 1fr auto; column-gap: 8px; align-items: baseline; padding: 5px 8px; border-radius: 8px; text-decoration: none; color: var(--ew-text); font-size: 13px; }
.donut-key a:hover, .donut-key a.on { background: var(--ew-tint2); }
.donut-key i { width: 10px; height: 10px; border-radius: 3px; }
.donut-key small { grid-column: 2 / 4; color: var(--ew-muted); font-size: 11.5px; }

/* what we keep of what we won: cost (grey) and margin (colour) of each pillar's won orders */
.keep-list { display: flex; flex-direction: column; gap: 8px; }
.keep { display: grid; grid-template-columns: 70px 1fr 112px; gap: 14px; align-items: center; margin: 0 -8px; padding: 6px 8px; border-radius: 10px; text-decoration: none; color: var(--ew-text) !important; }
.keep:hover, .keep.on { background: var(--ew-tint2); }
.keep .nm { font-weight: 600; font-size: 13px; }
.keep .trk { display: flex; height: 28px; border-radius: 7px; overflow: hidden; background: #eef2f6; }
.keep .cost { background: #dbe3ea; color: #475569; font-size: 11.5px; display: flex; align-items: center; padding-left: 9px; white-space: nowrap; overflow: hidden; }
.keep .mg { color: #fff; font-size: 11.5px; font-weight: 600; display: flex; align-items: center; justify-content: flex-end; padding-right: 9px; white-space: nowrap; overflow: hidden; }
.keep .pc { text-align: right; line-height: 1.15; }
.keep .pc b { font-size: 15px; color: var(--ew-ink); }
.keep .pc small { display: block; color: var(--ew-muted); font-size: 11.5px; }
tr.row-link { cursor: pointer; }
/* a name opens what is on that person's plate (person.php) */
a.person-link { color: inherit; text-decoration: none; border-bottom: 1px dotted #94a3b8; }
a.person-link:hover { color: var(--ew-dark); border-bottom-color: var(--ew-teal); }
/* the win chart: a won pillar opens its jobs */
.win-chart .cell.won { cursor: pointer; }
.win-chart .cell.won:hover, .win-chart .cell.won:focus { box-shadow: inset 0 0 0 2px var(--ew-teal); outline: none; }
.win-chart .cell.won .nm { text-decoration: underline dotted; text-underline-offset: 2px; }
.win-pop { position: absolute; z-index: 1080; width: 360px; max-width: calc(100vw - 16px); background: #fff; border: 1px solid #dbe4ea; border-radius: 12px; box-shadow: 0 12px 32px rgba(15, 31, 42, .18); overflow: hidden; }
.win-pop .hd { display: flex; align-items: center; gap: 6px; padding: 9px 12px; font-size: 13px; background: var(--ew-tint2); border-bottom: 1px solid #e6edf2; }
.win-pop .hd .x { margin-left: auto; border: 0; background: none; font-size: 18px; line-height: 1; color: var(--ew-muted); }
.win-pop .ls { max-height: 320px; overflow-y: auto; }
.win-pop .ls a { display: grid; grid-template-columns: 1fr auto; gap: 1px 10px; padding: 8px 12px; border-bottom: 1px solid #f0f4f7; text-decoration: none; color: var(--ew-text); font-size: 12.5px; }
.win-pop .ls a:hover { background: var(--ew-tint2); }
.win-pop .no { font-weight: 600; color: var(--ew-ink); }
.win-pop .v { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.win-pop .t { color: var(--ew-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.win-pop .d { text-align: right; color: var(--ew-muted); }
/* the unit box of an estimate row: wide enough for "Pail (18.9 Litre)" */
.unit-sel { min-width: 118px; }
/* the margin bars: the pillar's best and lowest orders on hover; the finished jobs' planned margin as a tick */
.dash > .span-6 { grid-column: span 6; }
@media (max-width: 1199px) { .dash > .span-6 { grid-column: span 12; } }
.keep { position: relative; outline: none; }
.keep > a.nm { color: var(--ew-ink); text-decoration: none; }
.keep > a.nm:hover { color: var(--ew-dark); text-decoration: underline; }
.keep .trk { position: relative; }
.keep .trk.none { display: flex; align-items: center; padding: 0 10px; font-size: 12px; color: var(--ew-muted); background: repeating-linear-gradient(135deg, #f1f5f8 0 4px, #fff 4px 8px); border: 1px dashed #d6e0e7; }
.keep .trk > .plan { position: absolute; top: 0; bottom: 0; width: 0; border-left: 2px dashed var(--ew-ink); opacity: .8; }
.keep .dl { font-weight: 700; white-space: nowrap; }
.keep .dl.ok { color: #15803d; } .keep .dl.warn { color: #b45309; } .keep .dl.bad { color: #b91c1c; }
.keep-pop { display: none; position: absolute; z-index: 30; top: 100%; left: 78px; width: min(440px, calc(100% - 78px)); min-width: 320px; padding: 6px 0 4px; background: #fff; border: 1px solid #dbe4ea; border-radius: 12px; box-shadow: 0 14px 34px rgba(15, 31, 42, .18); }
.keep:hover > .keep-pop, .keep:focus-within > .keep-pop { display: block; }
.keep-pop { width: 460px; min-width: 0; max-width: calc(100vw - 32px); padding: 0; overflow: hidden; }
.keep-pop .hd { padding: 8px 12px; font-size: 12px; font-weight: 600; color: var(--ew-ink); background: var(--ew-tint2); border-bottom: 1px solid #e6edf2; }
.keep-pop table { width: 100%; table-layout: fixed; border-collapse: collapse; }
.keep-pop th { padding: 6px 10px 4px; font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; text-align: left; }
.keep-pop th.ok { color: #15803d; } .keep-pop th.bad { color: #b91c1c; }
.keep-pop td { padding: 0; vertical-align: top; border-top: 1px solid #f0f4f7; }
.keep-pop td + td, .keep-pop th + th { border-left: 1px solid #eef3f6; }
.keep-pop td a { display: grid; grid-template-columns: 1fr auto; gap: 0 8px; padding: 6px 10px; text-decoration: none; color: var(--ew-text); font-size: 12px; }
.keep-pop td a:hover { background: var(--ew-tint2); }
.keep-pop .no { font-weight: 600; color: var(--ew-ink); white-space: nowrap; }
.keep-pop .v { text-align: right; white-space: nowrap; }
.keep-pop .t { grid-column: 1 / 3; color: var(--ew-muted); font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash > .span-4 { grid-column: span 4; } .dash > .span-8 { grid-column: span 8; }
@media (max-width: 1199px) { .dash > .span-4, .dash > .span-8 { grid-column: span 12; } }
.keep .pc .dl { font-size: 12px; margin-left: 2px; }
.dash > .span-3 { grid-column: span 3; }
@media (max-width: 1199px) { .dash > .span-3 { grid-column: span 6; } }
@media (max-width: 767px) { .dash > .span-3 { grid-column: span 12; } }
.dash-sec { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 14px; padding: 6px 2px 0; }
.dash-sec h2 { font-size: 18px; font-weight: 700; margin: 0; color: var(--ew-ink); }
#analysis .dl { font-weight: 700; font-size: 12px; } #analysis .dl.ok { color: #15803d; } #analysis .dl.warn { color: #b45309; } #analysis .dl.bad { color: #b91c1c; }
.tgt-row { grid-template-columns: 110px minmax(0, 1fr) 190px 190px; }
.tgt-row .pipe { display: flex; flex-direction: column; gap: 1px; font-size: 12.5px; line-height: 1.35; color: var(--ew-muted); padding-left: 16px; border-left: 1px solid #edf1f5; }
.tgt-row .pipe a { color: var(--ew-muted); text-decoration: none; } .tgt-row .pipe a:hover { color: var(--ew-dark); text-decoration: underline; }
.tgt-row .pipe b { color: var(--ew-ink); }
@media (max-width: 1399px) { .tgt-row { grid-template-columns: 110px minmax(0, 1fr) 190px; } .tgt-row .pipe { grid-column: 2 / 4; flex-direction: row; flex-wrap: wrap; gap: 2px 16px; padding-left: 0; border-left: 0; } }
@media (max-width: 991px) { .tgt-row { grid-template-columns: 1fr; } .tgt-row .pipe { grid-column: auto; } }

/* ---- the compressor parts picker (assets/parts_picker.js): the principal's parts list of a model, the same for every brand */
.pp-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding: 12px 22px; border-bottom: 1px solid #edf1f5; }
.pp-tabs { display: flex; flex-wrap: wrap; gap: 4px; flex: 1 1 auto; }
.pp-tab { border: 1px solid #d6e2ea; background: #fff; border-radius: 8px; padding: 4px 10px; font-size: 12.5px; color: var(--ew-text); }
.pp-tab small { color: var(--ew-muted); margin-left: 2px; }
.pp-tab.on { background: var(--ew-dark); border-color: var(--ew-dark); color: #fff; }
.pp-tab.on small { color: rgba(255,255,255,.75); }
.pp-tools { display: flex; gap: 6px; align-items: center; }
.pp-search { width: 260px; }
.pp-list { flex: 1 1 auto; min-height: 0; max-height: 640px; overflow: auto; }
.pp-msg { display: flex; align-items: center; justify-content: center; padding: 24px; color: var(--ew-muted); font-size: 13px; }
.pp-table { font-size: 12.5px; }
.pp-table th { position: sticky; top: 0; z-index: 1; background: #fff; font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: var(--ew-muted); font-weight: 600; }
.pp-table tr[data-id] { cursor: pointer; }
.pp-table tr[data-id]:hover td { background: var(--ew-tint2); }
.pp-table tr.on td { background: #e6f6f9; }
.pp-table td.num { font-variant-numeric: tabular-nums; }
.pp-star { color: #d97706; font-size: 11px; }
.pp-built { padding: 6px 22px; color: var(--ew-muted); border-bottom: 1px solid #edf1f5; background: #fafcfd; }
.pp-table tr.pp-nofit td { opacity: .45; }
.pp-table tr.pp-nofit.on td { opacity: 1; background: #fff4e5; }   /* ticked anyway: the estimator overrides on the plate's word */
.pp-date { color: #92400e; font-weight: 600; }
.pp-tray { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; padding: 12px 22px; border-top: 1px solid #edf1f5; background: #fafcfd; font-size: 13px; }
.pp-sum { flex: 1 1 auto; min-width: 0; }
.pp-chips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.pp-chip { display: inline-flex; align-items: center; gap: 4px; background: #fff; border: 1px solid #d6e2ea; border-radius: 999px; padding: 1px 4px 1px 9px; font-size: 11.5px; }
.pp-chip .x { border: 0; background: none; padding: 0 4px; line-height: 1; font-size: 14px; color: var(--ew-muted); }
.pp-chip .x:hover { color: #b91c1c; }

/* ---- the compressor library on the ROR estimate: brand > model on the unit; the parts picker in a layer */
.lib-pick { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; padding: 8px 12px; background: var(--ew-tint2); border: 1px solid #e3eef2; border-radius: 10px; }
.lib-pick .lg-label { margin: 0; }
.lib-find { display: inline-flex; align-items: center; gap: 6px; }
/* "no charge" beside a priced scope option */
.ror-scope .no-charge { display: inline-flex; align-items: center; gap: 3px; margin-left: 6px; padding: 0 6px; border: 1px solid #d6e2ea; border-radius: 999px; font-size: .72rem; color: #475569; background: #fff; white-space: nowrap; cursor: pointer; }
.ror-scope .no-charge .form-check-input { float: none; margin: 0; width: .8rem; height: .8rem; }
.ror-scope .no-charge.off { opacity: .4; cursor: default; }
.lib-find input { width: 190px; }
.lib-pick select[data-comp-model][data-searching] { position: relative; z-index: 3; min-height: 0; background-image: none; box-shadow: 0 10px 24px rgba(15,31,42,.16); }
.lib-pick select[data-comp-model][data-searching] option { padding: 3px 6px; }
.lib-pick select[data-comp-model][data-searching] optgroup { font-size: 11px; color: var(--ew-muted); }
tr[data-part-lib] td:first-child .sub { font-size: 11.5px; }
.pp-layer { position: fixed; inset: 0; z-index: 1090; background: rgba(15, 31, 42, .55); display: flex; align-items: center; justify-content: center; padding: 16px; }
.pp-sheet { width: min(1080px, 100%); height: min(88vh, 860px); background: #fff; border-radius: 16px; box-shadow: 0 24px 60px rgba(15, 31, 42, .35); display: flex; flex-direction: column; overflow: hidden; }
.pp-head { display: flex; align-items: center; gap: 8px; padding: 12px 22px; border-bottom: 1px solid #edf1f5; font-size: 14px; }
.pp-host { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
.pp-host > [data-parts-picker] { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
.pp-host .pp-list { max-height: none; }
body.pp-open { overflow: hidden; }

/* the vendor quote register (vendor_quote.php) and the other vendors' quotes under an estimate's cost */
.cost-offers { font-size: .72rem; line-height: 1.3; color: var(--bs-secondary-color, #6c757d); margin-top: 2px; white-space: normal; }
.cost-offers span { margin-right: 4px; }
.cost-offers a { margin-right: 6px; text-decoration: none; border-bottom: 1px dotted currentColor; }
.cost-offers a.expired { color: #9aa0a6; }
.vq-preview { max-width: 100%; max-height: 320px; border: 1px solid #dee2e6; border-radius: 6px; }
.vq-lines td { vertical-align: top; }
.vq-lines [data-vq-hint] a { text-decoration: none; border-bottom: 1px dotted currentColor; }
.cost-ask { font-size: .72rem; line-height: 1.3; margin-top: 2px; color: #8a6d1f; white-space: normal; }
.cost-ask a { text-decoration: none; border-bottom: 1px dotted currentColor; }

/* the contract management board (contracts.php) */
.ct-figs { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 12px; }
.ct-fig .lab { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: #6c7a84; }
.ct-fig .val { font-size: 1.35rem; font-weight: 600; margin: 2px 0; }
.ct-board .progress { max-width: 160px; margin-left: auto; }

/* the contract management board, cards and stacked bars (owner, 2026-10-22: "too flat") */
.ct-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 6px 0 10px; }
.ct-stat { background: #fff; border: 1px solid #e3e9ee; border-left: 4px solid #9aa9b3; border-radius: 10px; padding: 10px 12px; }
.ct-stat .lab { font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; color: #60717c; display: flex; gap: 6px; align-items: center; }
.ct-stat .val { font-size: 1.3rem; font-weight: 700; color: #16313d; margin: 2px 0; white-space: nowrap; }
.ct-stat .sub { font-size: .74rem; color: #6c7a84; }
.ct-stat.budget { border-left-color: #3b5b8c; } .ct-stat.won { border-left-color: #16313d; } .ct-stat.inv { border-left-color: #0f5c63; }
.ct-stat.wip { border-left-color: #2aa7a0; } .ct-stat.sent { border-left-color: #f2b134; } .ct-stat.free { border-left-color: #b8c4cc; } .ct-stat.bad { border-left-color: #d64545; }
.ct-summary .ct-stat { background: linear-gradient(180deg, #fff, #f7fafb); }
.ct-stack { position: relative; display: flex; height: 12px; border-radius: 6px; background: #eef2f4; overflow: visible; margin: 10px 0 6px; }
.ct-stack.big { height: 18px; border-radius: 9px; margin: 14px 0 8px; }
.ct-stack > span { display: block; height: 100%; }
.ct-stack > span:first-child { border-radius: 6px 0 0 6px; } .ct-stack > span:last-of-type { border-radius: 0 6px 6px 0; }
.ct-seg-inv { background: #0f5c63; } .ct-seg-wip { background: #2aa7a0; }
.ct-seg-sent { background: repeating-linear-gradient(135deg, #f2b134 0 6px, #f6c869 6px 12px); }
.ct-seg-free { background: #dfe6ea; }
.ct-budget-mark { position: absolute; top: -4px; bottom: -4px; width: 3px; background: #d64545; border-radius: 2px; }
.ct-legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: .74rem; color: #60717c; margin: 2px 0 12px; }
.ct-legend i { display: inline-block; width: 12px; height: 8px; border-radius: 3px; margin-right: 5px; vertical-align: middle; }
.ct-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(420px, 1fr)); gap: 14px; margin-bottom: 14px; }
.ct-card { display: block; color: inherit; text-decoration: none; transition: box-shadow .15s, transform .15s; }
.ct-card:hover { box-shadow: 0 6px 18px rgba(22, 49, 61, .12); transform: translateY(-1px); color: inherit; }
.ct-card-top, .ct-hero-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.ct-client { font-weight: 700; font-size: 1.02rem; margin-top: 4px; color: #16313d; }
.ct-pct { text-align: right; font-size: 1.5rem; font-weight: 700; color: #0f5c63; line-height: 1.1; white-space: nowrap; }
.ct-pct small { display: block; font-size: .7rem; font-weight: 500; color: #6c7a84; }
.ct-pct.warn { color: #b7791f; } .ct-pct.bad { color: #d64545; } .ct-pct.none { font-size: .95rem; color: #8a99a3; }
.ct-mini { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px 12px; margin-top: 6px; }
.ct-mini > div { border-left: 3px solid #dfe6ea; padding-left: 8px; }
.ct-mini span { display: block; font-size: .68rem; text-transform: uppercase; letter-spacing: .04em; color: #6c7a84; }
.ct-mini b { display: block; font-size: .98rem; color: #16313d; white-space: nowrap; }
.ct-mini em { display: block; font-style: normal; font-size: .7rem; color: #8a99a3; }
.ct-mini .won { border-left-color: #16313d; } .ct-mini .inv { border-left-color: #0f5c63; } .ct-mini .wip { border-left-color: #2aa7a0; }
.ct-mini .sent { border-left-color: #f2b134; } .ct-mini .free { border-left-color: #b8c4cc; } .ct-mini .bad { border-left-color: #d64545; } .ct-mini .bad b { color: #d64545; }
.ct-hero .ct-big { font-size: 1.9rem; font-weight: 700; color: #16313d; line-height: 1.1; }
.ct-hero { margin-bottom: 14px; }
@media (max-width: 575.98px) { .ct-grid { grid-template-columns: 1fr; } .ct-mini { grid-template-columns: repeat(2, 1fr); } .ct-pct { font-size: 1.2rem; } }

/* clickable figures (owner, 2026-10-22) */
a.ct-stat.link { display: block; color: inherit; text-decoration: none; cursor: pointer; transition: box-shadow .15s, transform .15s; }
a.ct-stat.link:hover { box-shadow: 0 4px 14px rgba(22, 49, 61, .12); transform: translateY(-1px); }
a.ct-stat.link .lab::after { content: '\F138'; font-family: bootstrap-icons; margin-left: auto; opacity: .45; }
.ct-card-top { color: inherit; text-decoration: none; }
.ct-card-top:hover .ct-client { text-decoration: underline; }
.ct-mini > a { color: inherit; text-decoration: none; border-radius: 4px; }
.ct-mini > a:hover { background: #f2f6f8; }
.ct-mini > a:hover b { text-decoration: underline; }
.ct-card { cursor: default; }
.ct-card-top .sub { color: #6c7a84; }
.ct-card-top .ct-client { color: #16313d; }
/* contracts: every figure opens the list behind it (owner, 2026-10-23) */
.ct-mini > a { border-left: 3px solid #dfe6ea; padding-left: 8px; }
.ct-card-head, a.ct-hero-top, a.ct-pct { color: inherit; text-decoration: none; }
a.ct-pct { color: #0f5c63; } a.ct-pct.warn { color: #b7791f; } a.ct-pct.bad { color: #d64545; } a.ct-pct.none { color: #8a99a3; }
.ct-card-head:hover .ct-client, a.ct-hero-top:hover .ct-big, a.ct-pct:hover { text-decoration: underline; }
/* sales dashboard: active jobs / quotations grouped by division or client (owner, 2026-10-23) */
.grp-list { display: flex; flex-direction: column; gap: 4px; max-height: 520px; overflow-y: auto; }
.grp { border: 1px solid #e3e9ee; border-radius: 8px; background: #fff; }
.grp > summary { display: flex; align-items: center; gap: 10px; padding: 7px 10px; cursor: pointer; list-style: none; }
.grp > summary::-webkit-details-marker { display: none; }
.grp > summary::before { content: '\F285'; font-family: bootstrap-icons; font-size: .7rem; color: #8a99a3; transition: transform .15s; }
.grp[open] > summary::before { transform: rotate(90deg); }
.grp > summary .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; color: #16313d; }
.grp > summary .n { font-size: .75rem; color: #fff; background: #6c7a84; border-radius: 10px; padding: 0 7px; }
.grp > summary .v { font-weight: 700; color: #16313d; white-space: nowrap; }
.grp > summary .go { color: #8a99a3; font-size: .8rem; }
.grp .rows { border-top: 1px solid #eef2f6; }
.grp-row { display: flex; gap: 10px; justify-content: space-between; padding: 6px 10px 6px 26px; color: inherit; text-decoration: none; border-bottom: 1px solid #f2f5f7; }
.grp-row:last-child { border-bottom: 0; } .grp-row:hover { background: #f5f8fa; }
.grp-row .t { min-width: 0; font-size: .85rem; } .grp-row small { display: block; color: #6c7a84; font-size: .72rem; }
.grp-row .v { text-align: right; white-space: nowrap; font-size: .85rem; font-weight: 600; }
.grp-total { display: flex; justify-content: space-between; padding: 8px 10px 0; font-size: .85rem; color: #60717c; } .grp-total b { color: #16313d; }
.grp.empty > summary .nm, .grp.empty > summary .v { opacity: .55; } .grp.empty > summary .n { background: #b8c4cc; }
/* the win likelihood on the active quotations (owner, 2026-10-23): the %, hover for how, click for the model */
.grp-row a.t { flex: 1; min-width: 0; color: inherit; text-decoration: none; font-size: .85rem; }
.grp-row a.t:hover { text-decoration: underline; } .grp-row.gone { opacity: .6; }
.wl { border: 0; border-radius: 12px; padding: 1px 9px; font-size: .78rem; font-weight: 700; line-height: 1.5; cursor: help; white-space: nowrap; align-self: center; text-align: center; }
.wl small { display: block; font-size: .6rem; font-weight: 500; line-height: 1; padding-bottom: 2px; }
.wl.ok { background: #d9f2e6; color: #146c43; } .wl.warn { background: #fff1d1; color: #8a5a00; } .wl.bad { background: #fde2e2; color: #b42318; }
.wl.gone, .wl.none { background: #eef2f6; color: #6c7a84; text-decoration: line-through; } .wl.none { text-decoration: none; }
.grp > summary .ex, .grp-total .ex { font-size: .74rem; color: #146c43; white-space: nowrap; }
.wl-about { position: absolute; z-index: 1080; width: 340px; max-width: calc(100vw - 16px); background: #fff; border: 1px solid #d6dee5; border-radius: 10px; box-shadow: 0 8px 28px rgba(22, 49, 61, .18); padding: 10px 14px; font-size: .82rem; }
.wl-about .hd { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.wl-about ol { padding-left: 18px; margin: 0 0 6px; } .wl-about li { margin-bottom: 4px; } .wl-about .sub { font-size: .72rem; color: #6c7a84; }
/* a contract's gross margin on its board card (owner, 2026-10-23) */
.ct-gm { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; margin-top: 8px; padding: 6px 8px; border-radius: 6px; background: #f2f8f5; color: inherit; text-decoration: none; font-size: .8rem; }
.ct-gm span { color: #60717c; text-transform: uppercase; font-size: .68rem; letter-spacing: .04em; } .ct-gm b { color: #146c43; font-size: .95rem; } .ct-gm em { font-style: normal; color: #6c7a84; font-size: .72rem; }
.ct-gm:hover b { text-decoration: underline; }
/* ---- the sales dashboard as an infographic (owner, 2026-10-23): ring, flow, quote and margin health, year on year.
   The colours of the logo: dark teal #0B6478, teal #0EA8C0, tint #E3F4F8; amber for attention, a soft red only for trouble. */
:root { --ew-dark: #0B6478; --ew-teal: #0EA8C0; --ew-tint: #E3F4F8; --ew-navy: #16313d; --ew-mute: #6c7a84; --ew-amber: #B7791F; --ew-red: #B42318; --ew-green: #1F7A4D; }
.gl-ring { display: flex; align-items: center; gap: 14px; text-decoration: none; color: inherit; padding: 4px 14px 0; }
.gl-ring svg { width: 132px; height: 132px; flex: none; }
.gl-ring .trk { fill: none; stroke: var(--ew-tint); stroke-width: 14; }
.gl-ring .val { fill: none; stroke: var(--ew-teal); stroke-width: 14; stroke-linecap: round; transition: stroke-dasharray .6s; }
.gl-ring .pace { stroke: var(--ew-navy); stroke-width: 2.5; stroke-dasharray: 3 2; }
.gl-ring .big { font-size: 26px; font-weight: 800; fill: var(--ew-dark); }
.gl-ring .sm { font-size: 9.5px; fill: var(--ew-mute); text-transform: uppercase; letter-spacing: .06em; }
.gl-ring-fig b { display: block; font-size: 1.35rem; color: var(--ew-navy); line-height: 1.15; }
.gl-ring-fig span { font-size: .8rem; color: var(--ew-mute); }
.gl-ring:hover .val { stroke: var(--ew-dark); }
.gl-facts { display: flex; flex-direction: column; gap: 6px; padding: 10px 14px 14px; }
.gl-facts a { display: grid; grid-template-columns: 22px 1fr; column-gap: 6px; align-items: center; padding: 7px 10px; border-radius: 8px; background: #f6f9fb; color: inherit; text-decoration: none; border-left: 3px solid #c7d3da; }
.gl-facts a i { grid-row: span 2; color: var(--ew-mute); font-size: 1rem; }
.gl-facts a span { font-weight: 700; color: var(--ew-navy); font-size: .9rem; } .gl-facts a em { font-style: normal; font-size: .72rem; color: var(--ew-mute); }
.gl-facts a.ok { border-left-color: var(--ew-green); } .gl-facts a.ok i, .gl-facts a.ok span { color: var(--ew-green); }
.gl-facts a.warn { border-left-color: var(--ew-amber); } .gl-facts a.warn i, .gl-facts a.warn span { color: var(--ew-amber); }
.gl-facts a.bad { border-left-color: var(--ew-red); } .gl-facts a.bad i, .gl-facts a.bad span { color: var(--ew-red); }
.gl-facts a:hover { background: var(--ew-tint); }
.flow { display: grid; grid-template-columns: repeat(6, 1fr); gap: 0; padding: 14px 14px 6px; }
.flow-step { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 1px; padding: 12px 14px 12px 22px; margin-right: 10px; color: #fff; text-decoration: none; min-height: 112px;
  clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 50%, calc(100% - 14px) 100%, 0 100%, 14px 50%); transition: transform .15s, filter .15s; }
.flow-step.s0 { clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 50%, calc(100% - 14px) 100%, 0 100%); padding-left: 14px; border-radius: 8px 0 0 8px; }
.flow-step.s0 { background: #8FD3E0; color: var(--ew-navy); } .flow-step.s1 { background: #4FBFD3; } .flow-step.s2 { background: var(--ew-teal); }
.flow-step.s3 { background: #0A8BA3; } .flow-step.s4 { background: var(--ew-dark); } .flow-step.s5 { background: var(--ew-navy); margin-right: 0; }
.flow-step i { font-size: 1.05rem; opacity: .85; } .flow-step .lb { font-size: .68rem; text-transform: uppercase; letter-spacing: .06em; opacity: .9; }
.flow-step b { font-size: 1.15rem; line-height: 1.2; white-space: nowrap; } .flow-step em { font-style: normal; font-size: .7rem; opacity: .88; line-height: 1.25; }
.flow-step:hover { filter: brightness(1.08); transform: translateY(-2px); }
.flow-note { display: flex; flex-wrap: wrap; gap: 8px 18px; padding: 4px 16px 14px; font-size: .78rem; }
.flow-note a { color: var(--ew-dark); text-decoration: none; } .flow-note a:hover { text-decoration: underline; } .flow-note i { color: var(--ew-teal); }
@media (max-width: 991.98px) { .flow { grid-template-columns: repeat(3, 1fr); row-gap: 8px; } .flow-step, .flow-step.s0 { clip-path: none; border-radius: 8px; margin-right: 8px; padding-left: 14px; } }
@media (max-width: 575.98px) { .flow { grid-template-columns: repeat(2, 1fr); } }
.qh-head { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 10px; padding: 12px 14px 6px; }
.qh-head > div { padding: 8px 10px; border-radius: 8px; background: #f6f9fb; } .qh-head b { display: block; font-size: 1.1rem; color: var(--ew-navy); white-space: nowrap; }
.qh-head span { font-size: .72rem; color: var(--ew-mute); } .qh-head .hi { background: var(--ew-tint); } .qh-head .hi b { color: var(--ew-dark); font-size: 1.3rem; }
.qh-head .hi.low { background: #fdf3e2; } .qh-head .hi.low b { color: var(--ew-amber); }
.qh-bar { display: flex; height: 22px; margin: 8px 14px 6px; border-radius: 6px; overflow: hidden; background: #eef2f6; }
.qh-bar a { display: block; height: 100%; border-right: 2px solid #fff; transition: filter .15s; } .qh-bar a:last-child { border-right: 0; } .qh-bar a:hover { filter: brightness(1.12); }
.qh-bar a.expired { background-image: repeating-linear-gradient(135deg, rgba(255,255,255,.45) 0 4px, transparent 4px 8px) !important; }
.qh-legend { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 14px; padding: 2px 14px 6px; }
.qh-legend a { display: grid; grid-template-columns: 12px 1fr auto auto; gap: 8px; align-items: center; padding: 3px 4px; border-radius: 4px; font-size: .78rem; color: inherit; text-decoration: none; }
.qh-legend a:hover { background: #f2f6f8; } .qh-legend a.empty { opacity: .45; } .qh-legend i { width: 12px; height: 12px; border-radius: 3px; }
.qh-legend em { font-style: normal; color: var(--ew-mute); } .qh-legend b { color: var(--ew-navy); white-space: nowrap; }
.qh-lines { padding: 4px 14px 6px; border-top: 1px solid #eef2f6; margin-top: 4px; }
.qh-lines a { display: grid; grid-template-columns: 74px 1fr auto auto; gap: 8px; align-items: center; padding: 4px 0; color: inherit; text-decoration: none; font-size: .78rem; }
.qh-lines .tr { position: relative; height: 10px; } .qh-lines .tr i { position: absolute; left: 0; top: 0; height: 100%; border-radius: 3px; }
.qh-lines .tr .lv { background: #e1e8ed; } .qh-lines b { color: var(--ew-navy); white-space: nowrap; } .qh-lines em { font-style: normal; color: var(--ew-mute); white-space: nowrap; }
.qh-lines a:hover b { text-decoration: underline; }
.acts { display: flex; flex-wrap: wrap; gap: 6px; padding: 6px 14px 4px; }
.act { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 14px; font-size: .76rem; font-weight: 600; text-decoration: none; border: 1px solid transparent; }
.act.warn { background: #fdf3e2; color: var(--ew-amber); border-color: #f3dfb8; } .act.bad { background: #fdecea; color: var(--ew-red); border-color: #f6cfcb; }
.act.ok { background: var(--ew-tint); color: var(--ew-dark); border-color: #c4e6ee; } .act.mute { background: #f1f4f6; color: var(--ew-mute); border-color: #e1e7eb; }
.act:hover { filter: brightness(.97); text-decoration: underline; }
.mh-contracts { padding: 6px 14px 4px; border-top: 1px solid #eef2f6; margin-top: 6px; }
.mh-contracts .hd { font-size: .68rem; text-transform: uppercase; letter-spacing: .05em; color: var(--ew-mute); margin-bottom: 2px; }
.mh-contracts a { display: grid; grid-template-columns: auto minmax(0, 1fr) 90px 56px auto; gap: 8px; align-items: center; padding: 3px 0; color: inherit; text-decoration: none; font-size: .78rem; }
.mh-contracts .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .mh-contracts .tr { height: 8px; background: #eef2f6; border-radius: 4px; overflow: hidden; }
.mh-contracts .tr i { display: block; height: 100%; background: var(--ew-teal); } .mh-contracts b { text-align: right; } .mh-contracts b.ok { color: var(--ew-green); } .mh-contracts b.warn { color: var(--ew-amber); } .mh-contracts b.bad { color: var(--ew-red); }
.mh-contracts em { font-style: normal; color: var(--ew-amber); font-size: .7rem; white-space: nowrap; } .mh-contracts a:hover .nm { text-decoration: underline; }
.yoy { padding: 12px 14px 4px; }
.yoy-row { display: grid; grid-template-columns: 74px 1fr 104px 62px; gap: 10px; align-items: center; padding: 6px 4px; border-radius: 6px; color: inherit; text-decoration: none; }
.yoy-row:hover { background: #f4f8fa; } .yoy-row.on { background: var(--ew-tint); }
.yoy-row .bars { position: relative; height: 22px; } .yoy-row .bars i { position: absolute; left: 0; border-radius: 3px; }
.yoy-row .bars .last { top: 0; height: 22px; background: #cdd8df; } .yoy-row .bars .now { top: 5px; height: 12px; }
.yoy-row .bars s { position: absolute; top: -3px; width: 0; height: 28px; border-left: 2px solid var(--ew-navy); opacity: .55; }
.yoy-row b { text-align: right; color: var(--ew-navy); font-size: .85rem; white-space: nowrap; } .yoy-row em, .yoy-total em { font-style: normal; font-weight: 700; font-size: .78rem; text-align: right; }
.yoy-row em.up, .yoy-total em.up { color: var(--ew-green); } .yoy-row em.down, .yoy-total em.down { color: var(--ew-red); }
.yoy-total { display: flex; justify-content: space-between; gap: 10px; padding: 8px 18px 14px; font-size: .8rem; color: var(--ew-mute); border-top: 1px solid #eef2f6; } .yoy-total b { color: var(--ew-navy); }
.jb-flag { display: inline-block; margin-left: 4px; padding: 0 6px; border-radius: 8px; font-size: .66rem; font-weight: 700; vertical-align: middle; }
.jb-flag.low { background: #fdecea; color: var(--ew-red); } .jb-flag.rec { background: #fdf3e2; color: var(--ew-amber); } .jb-flag.nc { background: #f1f4f6; color: var(--ew-mute); }
tr.jb-low td:first-child { box-shadow: inset 3px 0 0 var(--ew-red); } tr.jb-rec td:first-child { box-shadow: inset 3px 0 0 var(--ew-amber); }
tr.q-gone td { opacity: .62; } tr.q-hi td:first-child { box-shadow: inset 3px 0 0 var(--ew-dark); }
/* the flow steps keep their own colours against the card text styles */
.flow .flow-step, .flow .flow-step i, .flow .flow-step .lb, .flow .flow-step b, .flow .flow-step em { color: #fff !important; }
.flow .flow-step.s0, .flow .flow-step.s0 i, .flow .flow-step.s0 .lb, .flow .flow-step.s0 b, .flow .flow-step.s0 em { color: #0B4A5A !important; }
/* the company ring, a portion per division (owner, 2026-10-23): click a portion or its key for how far behind it is */
.gl-ring .seg { fill: none; stroke-width: 14; cursor: pointer; transition: stroke-width .15s, opacity .15s; }
.gl-ring .seg:hover, .gl-ring .seg.sel { stroke-width: 19; } .gl-ring .seg.dim { opacity: .3; }
.ring-key { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 10px; padding: 8px 14px 0; }
.ring-key button { display: grid; grid-template-columns: 10px 1fr auto 10px; gap: 6px; align-items: center; border: 0; background: transparent; padding: 3px 6px; border-radius: 6px; font-size: .78rem; text-align: left; color: inherit; cursor: pointer; }
.ring-key button:hover { background: #f2f6f8; } .ring-key button.sel { background: var(--ew-tint); } .ring-key button.dim { opacity: .45; }
.ring-key button i { width: 10px; height: 10px; border-radius: 3px; } .ring-key button b { color: var(--ew-navy); }
.ring-key .pace-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; background: #b8c4cc; }
.ring-key .pace-dot.ok { background: var(--ew-green); } .ring-key .pace-dot.warn { background: var(--ew-amber); } .ring-key .pace-dot.bad { background: var(--ew-red); }
.ring-div .rd-hd { display: flex; align-items: center; gap: 8px; padding: 0 2px 2px; } .ring-div .rd-hd b { flex: 1; color: var(--ew-navy); font-size: .9rem; }

/* ---- Finance section (2026-10-23): bars drawn to one scale, the timeline of a work order, figure links */
.fin-bars { display: grid; gap: 6px; }
.fin-bars .row-b { display: grid; grid-template-columns: minmax(150px, 190px) 1fr 110px; gap: 10px; align-items: center; color: inherit; text-decoration: none; padding: 2px 0; border-radius: 6px; }
.fin-bars a.row-b:hover { background: #f3f7f9; }
.fin-bars .lbl { font-size: 12.5px; color: #3b4a55; } .fin-bars .lbl small { color: #8a99a3; margin-left: 4px; }
.fin-bars .bar { display: block; height: 12px; background: #eef2f5; border-radius: 3px; overflow: hidden; }
.fin-bars .bar i { display: block; height: 100%; background: #2aa7a0; border-radius: 0 3px 3px 0; }
.fin-bars .bar i.bad { background: #d64545; } .fin-bars .bar i.warn { background: #f2b134; } .fin-bars .bar i.ok { background: #2f9e44; }
.fin-bars .val { font-size: 12.5px; text-align: right; font-variant-numeric: tabular-nums; color: #16313d; white-space: nowrap; }
.fin-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 6px; }
.fin-steps .st { border: 1px solid #e3e9ee; border-radius: 8px; padding: 8px 10px; font-size: 12px; color: #6c7a84; background: #fff; }
.fin-steps .st b { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: #60717c; margin-bottom: 2px; }
.fin-steps .st span { font-variant-numeric: tabular-nums; color: #16313d; }
.fin-steps .st.done { border-left: 4px solid #2f9e44; } .fin-steps .st.due { border-left: 4px solid #f2b134; }
a.num-link { color: inherit; text-decoration: underline dotted; }
.ct-stat.free { border-left-color: #b8c4cc; }
/* the sales dashboard fits one screen to the end of the pillars (owner, 2026-10-23: "in 1 screen, you should see, Over all,
   Sale Flow, and Pillar against target ... so no need to scroll down") */
.dash > .span-9 { grid-column: span 9; }
@media (max-width: 1199px) { .dash > .span-9 { grid-column: span 12; } }
body.slim .lg-top { padding: 8px 0 56px; }
body.slim .lg-bar { margin-bottom: 8px; padding-bottom: 8px; }
body.slim .lg-head { align-items: center; }
body.slim .lg-head .ic { width: 38px; height: 38px; font-size: 18px; border-radius: 11px; }
body.slim .lg-head h1 { font-size: 21px; }
body.slim .lg-head p { font-size: 12.5px; margin-top: 1px; }
body.slim .lg-tabs { margin-bottom: 12px; }
body.slim .dash { gap: 12px; }
.ring-card > .bd { position: relative; }
.ring-card .gl-ring { padding: 6px 12px 0; gap: 10px; }
.ring-card .gl-ring svg { width: 104px; height: 104px; }
.ring-card .gl-ring-fig b { font-size: 1.1rem; }
.gl-ring-fig .rf { display: block; margin-top: 3px; font-size: .74rem; font-weight: 700; text-decoration: none; color: var(--ew-mute); }
.gl-ring-fig .rf.ok { color: var(--ew-green); } .gl-ring-fig .rf.warn { color: var(--ew-amber); } .gl-ring-fig .rf.bad { color: var(--ew-red); }
.gl-ring-fig .rf:hover { text-decoration: underline; }
.ring-card .ring-key { padding: 4px 10px 10px; gap: 0 6px; }
.ring-card .ring-key button { padding: 2px 5px; font-size: .74rem; }
.ring-card .ring-div { position: absolute; inset: 0; z-index: 3; background: rgba(255, 255, 255, .97); padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; border-radius: 0 0 16px 16px; }
.ring-card .ring-div[hidden] { display: none; }
.ring-card .ring-div a { padding: 6px 9px; }
.flow { padding: 10px 12px 4px; }
.flow-step { min-height: 96px; padding: 9px 12px 9px 20px; margin-right: 8px; }
.flow-step b { font-size: 1.05rem; }
.flow-note { padding: 2px 14px 10px; gap: 4px 16px; }
#pillars .tgt-row { padding: 5px 18px; gap: 16px; }
#pillars .batt2 { height: 22px; padding: 2px; }
#pillars .batt2::after { top: 5px; height: 8px; }
#pillars .batt2 > .pace { top: -5px; bottom: -5px; }
#pillars .batt2-lb { margin-top: 2px; }
#pillars .batt2-lb > span { font-size: 10.5px; }
#pillars .tgt-row .fig { font-size: 11.5px; line-height: 1.25; }
#pillars .tgt-row .fig > b { font-size: 13.5px; }
#pillars .tgt-row .pipe { font-size: 11.5px; line-height: 1.25; }
#pillars .dash-key { padding: 5px 18px; font-size: 11px; gap: 4px 14px; }
.ring-card .ring-key { grid-template-columns: repeat(3, 1fr); gap: 0 4px; padding: 2px 8px 8px; }
.ring-card .ring-key button { grid-template-columns: 8px 1fr auto; padding: 2px 3px; font-size: .72rem; } .ring-card .ring-key .pace-dot { display: none; }
.ring-card .ring-key button b { font-size: .72rem; }
.ring-card .gl-ring svg { width: 98px; height: 98px; }
#pillars .tgt-row { padding: 4px 18px; }
#pillars .tgt-row .pipe { font-size: 11px; line-height: 1.2; }
#pillars .tgt-row .fig { line-height: 1.2; }
.ring-card .ring-key { display: flex; flex-wrap: wrap; gap: 0 2px; padding: 4px 8px 8px; }
.ring-card .ring-key button { display: inline-flex; gap: 4px; align-items: center; padding: 2px 5px; }
.ring-card .ring-key button i { width: 8px; height: 8px; }
.ring-card > .hd, .pillar-card > .hd { padding-top: 12px; padding-bottom: 10px; }
.key-i { color: var(--ew-mute); cursor: help; font-size: 1rem; padding: 0 4px; }
.ring-card > .hd .lg-step { display: none; }
/* the dashboard pillars keep the open work as a column down to 992 px, so the rows stay one line high */
@media (min-width: 992px) and (max-width: 1399px) { #pillars .tgt-row { grid-template-columns: 84px minmax(0, 1fr) 168px 168px; gap: 12px; } #pillars .tgt-row .pipe { grid-column: auto; flex-direction: column; gap: 0; padding-left: 10px; border-left: 1px solid #edf1f5; } }
.fin-svg { width: 100%; height: auto; display: block; font-family: Inter, system-ui, sans-serif; }
.fin-svg a { cursor: pointer; } .fin-svg a:hover rect { opacity: .85; }
.fin-info { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; }
.fin-kpi { display: flex; gap: 14px; align-items: center; padding: 10px 12px; border: 1px solid #e3e9ee; border-radius: 10px; background: #fff; color: inherit; text-decoration: none; }
.fin-kpi .ic { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; font-size: 18px; color: #fff; background: #16313d; flex: none; }
.fin-kpi .ic.in { background: #2a78d6; } .fin-kpi .ic.out { background: #eb6834; } .fin-kpi .ic.bad { background: #d64545; } .fin-kpi .ic.ok { background: #2f9e44; }
.fin-kpi .v { font-size: 1.25rem; font-weight: 700; color: #16313d; line-height: 1.1; white-space: nowrap; }
.fin-kpi .l { font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; color: #60717c; }
.fin-kpi .s { font-size: .74rem; color: #6c7a84; }
a.fin-kpi:hover { box-shadow: 0 4px 14px rgba(22, 49, 61, .12); }
.fin-assume { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 8px 14px; align-items: end; }
.fin-assume label { font-size: 11.5px; color: #60717c; display: block; }
/* margin health: done + work in progress = total (owner, 2026-10-23) */
.mh-tot { grid-template-columns: 1fr 1fr 1fr; }
.mh-tot > a { display: block; padding: 8px 10px; border-radius: 8px; background: #f6f9fb; text-decoration: none; color: inherit; transition: box-shadow .15s; }
.mh-tot > a:hover, .mh-tot > a:focus { box-shadow: inset 0 0 0 1px var(--ew-teal); }
.mh-tot em { display: block; font-style: normal; font-size: .66rem; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--ew-mute); }
.mh-tot b { font-size: 1.25rem !important; }
.mh-tot .wip { background: #fff; border: 1px dashed var(--ew-teal); }
.mh-tot .wip b { color: var(--ew-teal); } .mh-tot .wip.low b, .mh-tot .hi.low b { color: var(--ew-amber); }
.mh-tot .tot { background: var(--ew-dark); } .mh-tot .tot b, .mh-tot .tot span, .mh-tot .tot em { color: #fff; } .mh-tot .tot em { opacity: .75; }
.tag.mute { opacity: .55; }
/* the gross margin ladder, one card for the CRM and Finance (owner, 2026-10-26) */
.gm-ladder td.sg { width: 22px; color: var(--ew-mute); font-weight: 700; text-align: center; }
.gm-ladder tr.sum td { border-top: 2px solid var(--ew-dark); background: var(--ew-tint); }
.gm-ladder td:last-child { width: 80px; }
/* client PO check: the file beside the lines read from it (owner, 2026-10-26) */
.cpo-file { width: 100%; height: 78vh; min-height: 520px; border: 1px solid #e3e9ee; border-radius: 8px; background: #f6f9fb; }
.cpo-lines td { vertical-align: top; }
.cpo-lines textarea { min-height: 2.6em; }
