/* qb-sync.css — QuickBooks sync furniture (package QB-SYNC, 2026-10-20).
 * The round "qb" badge uses Billdr's colours, not the house gold: green = successfully synchronized,
 * grey = not synchronized, orange = error. Gold stays reserved for each surface's one main action. */
/* wave42: the badge carries the real QuickBooks SYMBOL (the white qb ligature,
 * /logo-quickbooks-glyph.svg) inside the state-coloured disc — never the typed
 * letters "qb". The glyph sits at ~60% of the disc, Billdr's badge padding
 * (measured from Micheal's 2026-10-21 screenshots: glyph 0.71w × 0.63h of disc). */
.qb-badge { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; border-radius: 50%;
  vertical-align: middle; margin: 0 4px; cursor: default; flex: 0 0 auto; }
.qb-badge-glyph { width: 12px; height: 11px; display: block; }
.qb-b-ok { background: #2CA01C; }   /* wave41 parity: the official QuickBooks green — the same green logo-quickbooks.svg carries, and Billdr's badge */
/* wave41 parity: the Contacts "Import from QuickBooks" / "Sync from QuickBooks" tools carry the real
 * QuickBooks mark before the words, the way Billdr's Contacts links do (green qb mark + link text).
 * The mark greys out while the tool is disabled, matching the badge's grey = not-synchronized state. */
.qb-tool { display: inline-flex; align-items: center; gap: 6px; }
.qb-tool-mark { width: 16px; height: 16px; display: block; flex: 0 0 auto; }
.qb-tool:disabled .qb-tool-mark { filter: grayscale(1); opacity: .5; }
.qb-b-off { background: #a3abb4; }
.qb-b-err { background: #e8871e; }
.qb-small { font-size: 12.5px; }
.qb-note { font-size: 12.5px; color: var(--ink, #1d2733); background: #f4f6f8; border-radius: 6px; padding: 8px 10px; margin: 8px 0 0; }
.qb-warn { font-size: 12.5px; color: #8a4b08; background: #fdf1e3; border-radius: 6px; padding: 8px 10px; margin: 8px 0; }
.qb-bad { color: #a12d1f; }
.qb-pill { display: inline-block; font-size: 11.5px; padding: 2px 8px; border-radius: 999px; background: #eef1f4; color: #4a5562; margin-left: 6px; }
.qb-pill-on { background: #e3f4ea; color: #1f6b3e; }

/* The connection home, under the QuickBooks card's buttons */
.qb-home { margin-top: 10px; border-top: 1px solid var(--line, #e3e7ec); padding-top: 10px; }
.qb-h-title { margin: 0 0 4px; }
.qb-h-switch { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.qb-switch { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; }
.qb-switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.qb-switch-ui { width: 34px; height: 20px; border-radius: 999px; background: #c9d0d7; position: relative; transition: background .15s; flex: 0 0 auto; }
.qb-switch-ui::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .15s; box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.qb-switch input:checked + .qb-switch-ui { background: var(--navy, #0B2235); }
.qb-switch input:checked + .qb-switch-ui::after { transform: translateX(14px); }
.qb-switch input:focus-visible + .qb-switch-ui { outline: 2px solid var(--navy, #0B2235); outline-offset: 2px; }
.qb-switch input:disabled + .qb-switch-ui { opacity: .55; cursor: not-allowed; }
.qb-switch-sm .qb-switch-ui { width: 28px; height: 16px; }
.qb-switch-sm .qb-switch-ui::after { width: 12px; height: 12px; }
.qb-switch-sm input:checked + .qb-switch-ui::after { transform: translateX(12px); }
.qb-h-sec { margin-top: 10px; border: 1px solid var(--line, #e3e7ec); border-radius: 8px; padding: 8px 10px; }
.qb-h-sec > summary { cursor: pointer; font-weight: 600; font-size: 13.5px; }
.qb-h-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px 14px; margin-top: 8px; }
.qb-field { display: flex; flex-direction: column; gap: 3px; font-size: 13px; }
.qb-field select, .qb-field input { padding: 6px 8px; border: 1px solid var(--line, #d5dbe1); border-radius: 6px; font: inherit; background: #fff; }
.qb-h-acts { margin-top: 10px; }
.qb-toggle { display: flex; align-items: flex-start; gap: 10px; flex-wrap: wrap; padding: 6px 0; border-bottom: 1px dashed var(--line, #e3e7ec); font-size: 13.5px; }
.qb-toggle:last-of-type { border-bottom: 0; }
.qb-help { font-size: 12.5px; flex: 1 1 260px; }
.qb-help > summary { cursor: pointer; color: var(--navy, #0B2235); }
.qb-help p, .qb-help ul { margin: 4px 0; }
.qb-h-msg { margin: 8px 0 0; font-size: 12.5px; }

/* Records, rows, toolbars */
/* wave484: the record's standalone QuickBooks line (.qb-recline) is gone — its rule with it. The record view's
 * action-row item carries the state in small words after its label. */
.qb-recact small { margin-left: 4px; font-weight: 400; }
.qb-proj > .muted:first-child { font-weight: 600; }
.qb-proj { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin: 6px 0; font-size: 13px; }
/* wave48-schedule (item 16): the project header line's mark — the
 * genuine green roundel at reading size. */
.qb-proj-mark { display: block; flex: none; }
.qb-paysend { font-size: 12px; margin-left: 4px; }
.qb-ts-btn { display: inline-flex; align-items: center; justify-content: center; padding: 2px 5px; }
.qb-ts-btn img { display: block; }
/* wave680-tsqbsync: the Timesheets sync summary line under the page strip — the round
 * mark in the week's own state colour, then the counts in plain words. */
.ts-qb-summary { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0 0 12px; font-size: 13.5px; }
.ts-qb-summary .qb-badge { flex: none; }
.qb-menu-item small { margin-left: 6px; }
.qb-codes-acts { display: inline-flex; gap: 6px; flex-wrap: wrap; }
.qb-codes-count { margin-left: 12px; font-size: 12.5px; color: var(--muted, #5b6672); }
.qb-divmap { display: inline-flex; gap: 8px; flex-wrap: wrap; margin-left: 8px; }
.qb-map { display: inline-flex; flex-direction: column; font-size: 11px; color: var(--muted, #5b6672); }
.qb-map select { font-size: 12.5px; padding: 3px 6px; border: 1px solid var(--line, #d5dbe1); border-radius: 6px; max-width: 220px; background: #fff; }
.qb-map-warn select { border-color: #e8871e; background: #fdf1e3; }
.qb-codeown { margin: 2px 0 6px 84px; font-size: 12px; color: var(--muted, #5b6672); }

/* The preview / review dialogs */
.qb-dlg .qb-prev { max-height: 60vh; overflow: auto; }
.qb-prev-group h4 { margin: 12px 0 0; font-size: 14px; }
.qb-prev-list { list-style: none; margin: 6px 0; padding: 0; }
.qb-prev-list li { display: flex; align-items: flex-start; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--line, #eef1f4); font-size: 13px; }
.qb-prev-list li > span { flex: 1 1 auto; }
.qb-prev-dot { width: 8px; height: 8px; border-radius: 50%; background: #c9d0d7; margin-top: 6px; flex: 0 0 auto; }
.qb-codein { width: 90px; margin-left: 6px; padding: 3px 6px; border: 1px solid var(--line, #d5dbe1); border-radius: 6px; }

@media (max-width: 560px) {
  .qb-h-grid { grid-template-columns: 1fr; }
  .qb-divmap { margin-left: 0; width: 100%; }
  .qb-map select { max-width: 100%; }
  .qb-codeown { margin-left: 0; }
}

/* wave51-qbsandbox: production + sandbox side by side. The sandbox wears an amber SANDBOX pill on every panel that
 * can act, and its connection block sits inside the one QuickBooks card under a dashed amber rule — never the
 * production colours, never the house accent. */
.qb-pill-sandbox { background: #fff4e5; color: #8a4b00; border: 1px solid #f0c78a; font-weight: 700; letter-spacing: .04em; }
.int-subblock { margin-top: 14px; padding: 12px 14px; border: 1px dashed #f0c78a; border-radius: 10px; background: #fffaf2; }
.int-sub-head { display: flex; align-items: center; gap: 8px; margin: 10px 0 4px; }
.int-sub-head .int-status { margin-left: auto; }
.qb-env-seg { margin: 14px 0 8px; }
.qb-home-sandbox { border-left: 4px solid #f0c78a; padding-left: 12px; }

/* wave360-sbxmap: the sandbox home's cost-code mapping rows */
.qb-sbxmap { margin-top: 12px; border-top: 1px solid var(--ds-hair, #eef1f5); padding-top: 10px; }
.qb-maprow { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; margin: 8px 0; }
.qb-mapseries { font-weight: 700; min-width: 92px; padding-bottom: 8px; }
.qb-maprow .qb-field { flex: 1 1 220px; }

/* wave435-qbtslink: the badge is a door — a synced mark opens its QuickBooks record */
.qb-badge { cursor: pointer; }
