/* The Services tab (js/services/): Online Marketing's job board, rebuilt
   Oct 27, 2026. Only what the Design Queue's styles don't have already:
   its panel uses the queue's components as they are (dq-subtab,
   dq-view-chip, dq-pill, dq-tag, dq-sheet, dq-section, dq-details,
   dq-settings-table, …: css/designQueue.css names #services-panel beside
   the queue's panel). Every colour is one of styles.css's tokens. The
   board's sv- classes are the board before the rebuild's, as the mockups
   draw them (mockups/INDEX.md); what the rebuild adds is pro-. Linked from
   index.html after designQueue.css. */

/* The tab's count: the jobs where the viewer acts next, as the Queue tab's
   badge looks (home.css). */
#tab-services .tab-count {
  display: inline-block; position: relative; min-width: 18px; margin-left: 6px; padding: 0 5px;
  border-radius: 9px; background: var(--panel-alt); color: var(--text); font-size: 11px; line-height: 16px; text-align: center;
}
#tab-services .tab-count.hidden { display: none; }
@media (min-width: 701px) and (max-width: 1699px) {
  .mode-switch:has(#tab-services:not(.hidden)) .mode-btn { padding-left: 7px; padding-right: 7px; }
  #tab-services { position: relative; }
  #tab-services .tab-count { position: absolute; top: -7px; right: -8px; margin: 0; box-shadow: 0 0 0 1.5px var(--bg); }
}

/* Badges: the queue's tag, in its tones. */
.sv-badge { padding: 1px 7px; border: 1px solid var(--border); border-radius: 8px; font-size: 10.5px; color: var(--text-dim); white-space: nowrap; line-height: 1.5; }
.sv-badge-ok { border-color: var(--ok-border); color: var(--ok-fg); }
.sv-badge-warn { border-color: var(--warn-border); background: var(--warn-bg); color: var(--warn-fg-soft); }
.sv-badge-late { border-color: var(--disc-border); background: var(--disc-bg); color: var(--disc-fg); }
.sv-badge-info { border-color: var(--accent-dim); color: var(--accent); }

/* --- The board: its columns scroll sideways in their own box --- */
.sv-board-wrap { overflow-x: auto; padding-bottom: 6px; max-width: 100%; }
.sv-board { display: grid; gap: 10px; align-items: start; }
.sv-col { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); min-width: 0; }
.sv-col-head { display: flex; flex-direction: column; gap: 1px; padding: 8px 10px 7px; border-bottom: 1px solid var(--border); }
.sv-col-name { display: flex; align-items: center; gap: 6px; margin: 0; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-dim); }
.sv-col-name .dq-count { margin-left: 0; }
.sv-col-sum { font-size: 11.5px; color: var(--text-dim); }
.sv-cards { list-style: none; margin: 0; padding: 8px; display: flex; flex-direction: column; gap: 8px; }
.sv-closed-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); padding: 0; }
.sv-card {
  display: flex; flex-direction: column; gap: 4px; width: 100%; padding: 7px 9px 8px; text-align: left;
  background: var(--panel-alt); border: 1px solid var(--border); border-radius: var(--radius); color: var(--text); font-size: 12px;
}
.sv-card:hover { border-color: var(--accent-dim); }
.sv-card.is-late { box-shadow: inset 3px 0 0 var(--danger-text); }
.sv-card.is-waiting { box-shadow: inset 3px 0 0 var(--warn-fg); }
.sv-card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 6px; }
.sv-card-num { color: var(--text-dim); font-size: 11px; font-variant-numeric: tabular-nums; flex: none; }
.sv-card-site { font-size: 13px; font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.sv-card-sub { color: var(--text-dim); line-height: 1.35; overflow-wrap: anywhere; }
.sv-card-next { display: flex; align-items: center; gap: 6px; color: var(--text); }
.sv-card-next .dq-initials { height: 18px; min-width: 22px; font-size: 10px; padding: 0 4px; }
.sv-card-next .sv-when { flex: 1; min-width: 0; }
.sv-card-badges { display: flex; flex-wrap: wrap; gap: 4px; }
.sv-card-badges .sv-badge { white-space: normal; }
.sv-col-empty { color: var(--text-dim); font-size: 12px; padding: 6px 10px; margin: 0; }
.sv-board-foot { margin: 10px 0 0; color: var(--text-dim); font-size: 12.5px; }

/* --- The board: eleven columns, John's order (mockups 01a to 01c) --- */
.pro-board .sv-col-head { min-height: 62px; }
.pro-board-wrap { padding-bottom: 10px; }
.pro-card .sv-card-top { align-items: baseline; }
.pro-card-total { font-variant-numeric: tabular-nums; color: var(--text-dim); font-size: 11.5px; }
.pro-card .sv-card-num { color: var(--text-dim); }
.pro-card-opp { color: var(--text-dim); font-size: 11px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.pro-card.is-closed { background: var(--panel); }
.pro-card.is-closed .sv-card-site { color: var(--text-dim); }
.pro-card-why { color: var(--text-dim); font-size: 11.5px; line-height: 1.35; font-style: italic; }
.pro-col-closed { background: color-mix(in srgb, var(--panel) 70%, var(--bg-deep)); border-style: dashed; }
.pro-col-closed .sv-col-name { color: var(--text-dim); }

.pro-card .sv-card-next { flex-wrap: wrap; }
.pro-card .sv-card-next .sv-when { color: var(--text); }
.dq-toolbar .sv-filters-inline { margin: 0; }

/* --- A job's sheet: a little wider than the queue's (mockups 02, 02b) --- */
.dq-sheet.pro-sheet { width: min(720px, 100vw); }
/* The facts and the stage steps under the sticky head, scrolling with the
   sheet (jobSheet.js header()). */
.pro-head-more { margin-top: 12px; }
.pro-facts { display: grid; grid-template-columns: 86px 1fr; gap: 3px 10px; margin: 2px 0 10px; font-size: 12.5px; }
.pro-facts dt { color: var(--text-dim); }
.pro-facts dd { margin: 0; overflow-wrap: anywhere; }
.pro-facts a, .pro-sheet a, .pro-dialog a, #services-panel a { color: var(--accent); }
.pro-sep { color: var(--text-dim); }
.pro-psa { display: inline-flex; align-items: center; gap: 5px; }
.pro-psa.is-current { color: var(--ok-fg); }
.pro-psa.is-soon, .pro-psa.is-none { color: var(--warn-fg-soft); }
.pro-psa.is-expired { color: var(--disc-fg); }
.pro-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; flex: none; }
.sv-steps { list-style: none; display: grid; margin: 12px 0 2px; padding: 0; }
.sv-steps li { position: relative; padding-top: 16px; text-align: center; font-size: 10.5px; line-height: 1.3; color: var(--text-dim); }
.sv-steps li::before { content: ""; position: absolute; top: 3px; left: 50%; width: 9px; height: 9px; margin-left: -5px; border-radius: 50%; background: var(--panel); border: 1px solid var(--border); z-index: 1; }
.sv-steps li::after { content: ""; position: absolute; top: 7px; left: -50%; right: 50%; height: 1px; background: var(--border); }
.sv-steps li:first-child::after { display: none; }
.sv-steps li.done { color: var(--text-dim); }
.sv-steps li.done::before { background: var(--ok-stroke); border-color: var(--ok-stroke); }
.sv-steps li.done::after, .sv-steps li.now::after { background: var(--ok-border); }
.sv-steps li.now { color: var(--text); font-weight: 600; }
.sv-steps li.now::before { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-dim); }
.sv-steps small { display: block; font-weight: normal; color: var(--text-dim); font-size: 10px; white-space: normal; }
/* A phone's one line under the steps (jobSheet.js steps()). */
.pro-steps-line { display: none; margin: 4px 0 0; text-align: center; font-size: 12px; color: var(--text-dim); }
.pro-src { margin: 0 0 8px; font-size: 12.5px; color: var(--text-dim); line-height: 1.45; }
.pro-lines .dq-report-table th[scope="row"] { font-weight: 600; }
.pro-lines .dq-report-table td, .pro-lines .dq-report-table th { white-space: normal; }
.pro-lines .dq-report-table tfoot th, .pro-lines .dq-report-table tfoot td { background: var(--panel-alt); font-weight: 600; border-top: 1px solid var(--border); }
.dq-report-table th.dq-num, .dq-report-table td.dq-num { text-align: right; }
.pro-need { display: inline-block; margin-left: 6px; padding: 0 7px; border: 1px solid var(--warn-border); border-radius: 8px; background: var(--warn-bg); color: var(--warn-fg-soft); font-size: 11px; line-height: 1.6; }
.pro-files li { padding: 3px 0; font-size: 13px; }
.pro-files .dq-tag { min-width: 40px; text-align: center; }
.pro-tag-link { border-color: var(--accent-dim); color: var(--accent); }
.pro-newer { margin-top: 10px; }
.pro-newer .pro-lines { margin: 8px 0; background: var(--panel); }
.pro-newer .pro-lines td, .pro-newer .pro-lines th { color: var(--text); }
.pro-newer-actions { gap: 10px; align-items: center; flex-wrap: wrap; color: var(--text); }

/* --- Dialogs --- */
.pro-dialog .dq-field { margin-top: 10px; }
.pro-dialog .dq-field input[type="text"], .pro-dialog .dq-field input[type="date"], .pro-dialog .dq-field textarea, .pro-dialog .dq-field select { width: 100%; box-sizing: border-box; }
.pro-req { margin-left: 4px; color: var(--warn-fg-soft); font-size: 10.5px; }
.pro-two { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.pro-box { margin: 10px 0 0; padding: 9px 12px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--panel-alt); font-size: 13px; line-height: 1.45; }
.pro-box.is-ok { border-color: var(--ok-border); background: color-mix(in srgb, var(--ok-bg) 70%, var(--panel)); }
.pro-box.is-warn { border-color: var(--warn-border); background: var(--warn-bg); color: var(--warn-fg-soft); }
.pro-box.is-bad { border-color: var(--disc-border); background: var(--disc-bg); color: var(--disc-fg); }
.pro-box p { margin: 0; }
.pro-box p + p { margin-top: 4px; }
.pro-box .dq-check { margin-top: 8px; }
.pro-readonly { margin: 10px 0 0; display: grid; grid-template-columns: 110px 1fr; gap: 4px 10px; font-size: 13px; }
.pro-readonly dt { color: var(--text-dim); }
.pro-readonly dd { margin: 0; }
.pro-dialog .dq-combo-list { position: static; margin-top: 3px; }
.pro-dialog .dq-combo-list li { display: flex; justify-content: space-between; gap: 10px; }
.pro-dialog .dq-combo-list li .dq-hint { white-space: nowrap; }
.pro-dialog .dq-combo-list li.pro-add { border-top: 1px solid var(--border); color: var(--accent); }
/* New job's Design: its list over what's below, so nothing moves when it
   closes on a click elsewhere (Add job, Add a line); each design's name
   over its Design # and Opp #. */
.pro-dialog .pro-design-combo .dq-combo-list { position: absolute; margin-top: 2px; }
.pro-dialog .pro-design-combo .dq-combo-list li { flex-direction: column; align-items: flex-start; gap: 1px; }
.pro-dialog .pro-design-combo .dq-combo-list li .dq-hint { white-space: normal; overflow-wrap: anywhere; }
/* Its dialog's buttons over the list (z-index 5, designQueue.css), on the
   dialog's colour: with no line yet the list reaches them, and a click
   there is the button's, never a design's. A phone's opens upward (the
   phone block). */
.pro-dialog:has(.pro-design-combo) .dq-dialog-actions { position: relative; z-index: 6; background: var(--panel); }

/* --- Dealers (the PSA register: mockups 04a, 04b) --- */
.pro-page { max-width: 1180px; }
.pro-page .dq-section { margin: 0 0 24px; }
.pro-dealers td, .pro-dealers th { white-space: nowrap; }
.pro-dealers .pro-psa { font-size: 12.5px; }
.pro-dealers tbody th { font-weight: 600; }
.pro-wrap { white-space: normal !important; }
.pro-voided td { color: var(--text-dim); text-decoration: line-through; }
.pro-foot { margin: 8px 0 0; color: var(--text-dim); font-size: 12.5px; }
.pro-dealer-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 12px; margin: 0 0 10px; }
.pro-dealer-head h3 { margin: 0; font-size: 17px; }
.pro-back { font-size: 12.5px; }

/* --- My emails, Settings (mockups 10a, 10b, 11) --- */
.pro-narrow { max-width: 820px; }
.pro-switches { list-style: none; margin: 0; padding: 0; border: 1px solid var(--border); border-radius: var(--radius); background: var(--panel); max-width: 820px; }
.pro-switches li { display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; gap: 2px 10px; align-items: start; padding: 10px 14px; border-bottom: 1px solid var(--border); }
.pro-switches li:last-child { border-bottom: none; }
.pro-switches input { margin: 3px 0 0; width: 16px; height: 16px; }
.pro-switches b { font-weight: 600; font-size: 13.5px; }
.pro-switches .dq-hint { grid-column: 2; line-height: 1.4; }
.pro-switches .pro-default { grid-column: 3; grid-row: 1; font-size: 11.5px; color: var(--text-dim); white-space: nowrap; }
.pro-switches .pro-default.is-changed { color: var(--warn-fg-soft); }
.pro-settings .dq-settings-table td { white-space: nowrap; }
.pro-radio { display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
.pro-radio label { display: flex; align-items: baseline; gap: 8px; }

/* --- The board on a phone: one column at a time (mockup 12) --- */
.pro-phone { display: none; }
.pro-stage-picker { display: flex; align-items: center; gap: 8px; margin: 0 0 10px; }
.pro-stage-picker select { flex: 1; font-size: 15px; padding: 9px 10px; }
.pro-stage-picker button { min-width: 44px; min-height: 40px; font-size: 16px; }
.pro-phone-col { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.pro-phone-col .sv-card { padding: 10px 12px; font-size: 13px; }
.pro-phone-col .sv-card-site { font-size: 15px; }
.pro-phone-next { display: flex; justify-content: space-between; margin: 12px 0 0; font-size: 13px; }

/* The sub-tabs never give their height up to a long page below them (a
   phone's calendar list: the nav scrolls sideways, so it could). */
#services-panel .dq-subtabs { flex-shrink: 0; }

/* --- The calendar (mockups 06b, 06c) --- */
.pro-calendar { max-width: none; }
.pro-cal-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 10px; }
.pro-cal-bar h3 { margin: 0 6px; font-size: 16px; min-width: 150px; }
.pro-cal-bar .pro-spacer { flex: 1; }
.pro-cal-layout { display: grid; grid-template-columns: minmax(0, 1fr) 270px; gap: 14px; align-items: start; }
.pro-month { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border: 1px solid var(--border); border-radius: var(--radius); background: var(--panel); overflow: hidden; }
.pro-month .pro-dow { padding: 6px 8px; font-size: 11px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.05em; background: var(--panel-alt); border-bottom: 1px solid var(--border); }
.pro-day { min-height: 104px; padding: 4px 0 6px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); min-width: 0; }
.pro-day:nth-child(7n) { border-right: none; }
.pro-day.is-other { background: color-mix(in srgb, var(--panel) 60%, var(--bg-deep)); }
.pro-day.is-other .pro-daynum { color: var(--text-dim); }
.pro-day.is-weekend { background: color-mix(in srgb, var(--panel) 85%, var(--bg-deep)); }
.pro-daynum { display: inline-block; margin: 0 0 3px 8px; font-size: 12px; color: var(--text-dim); font-variant-numeric: tabular-nums; }
.pro-day.is-today .pro-daynum { background: var(--accent); color: var(--on-accent); border-radius: 10px; padding: 0 7px; margin-left: 4px; font-weight: 600; }
.pro-chip {
  display: flex; align-items: center; gap: 5px; width: calc(100% - 8px); margin: 0 4px 3px; padding: 2px 6px; border-radius: 4px; text-align: left;
  background: var(--accent-dim); border: 1px solid var(--accent); color: var(--text); font-size: 11px; line-height: 1.35; overflow: hidden; white-space: nowrap; cursor: pointer;
}
.pro-chip-gap { display: block; height: 20px; margin: 0 4px 3px; }
.pro-chip b { font-weight: 600; font-variant-numeric: tabular-nums; }
.pro-chip .pro-chip-name { overflow: hidden; text-overflow: ellipsis; min-width: 0; flex: 1; }
.pro-chip .pro-chip-who, .pro-chip .pro-chip-dealer { color: var(--text-dim); font-size: 10px; flex: none; }
.pro-chip .pro-chip-time { color: var(--text-dim); font-size: 10.5px; flex: none; }
.pro-chip.is-past { background: var(--panel-alt); border-color: var(--border); color: var(--text-dim); }
.pro-chip.is-cont { border-top-left-radius: 0; border-bottom-left-radius: 0; margin-left: -1px; width: calc(100% - 3px); border-left-style: dashed; }
.pro-chip.is-more { border-top-right-radius: 0; border-bottom-right-radius: 0; margin-right: -1px; border-right: none; }
.pro-side { border: 1px solid var(--border); border-radius: var(--radius); background: var(--panel); padding: 10px 12px; }
.pro-side h4 { margin: 0 0 8px; font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-dim); }
.pro-side ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.pro-side li { font-size: 12.5px; line-height: 1.4; padding: 7px 9px; background: var(--panel-alt); border: 1px solid var(--border); border-radius: var(--radius); }
.pro-side-job { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; width: 100%; padding: 0; border: 0; background: none; color: var(--text); text-align: left; cursor: pointer; }
.pro-side-job b { font-weight: 600; }
.pro-side .sv-card-num { font-size: 11px; color: var(--text-dim); }
.pro-side .sv-badge { display: inline-block; margin-top: 4px; }
.pro-legend { display: flex; flex-wrap: wrap; gap: 14px; margin: 8px 0 0; font-size: 12px; color: var(--text-dim); }
.pro-legend span { display: inline-flex; align-items: center; gap: 6px; }
.pro-legend i { display: inline-block; width: 16px; height: 10px; border-radius: 3px; background: var(--accent-dim); border: 1px solid var(--accent); }
.pro-legend i.is-past { background: var(--panel-alt); border-color: var(--border); }
.pro-week { border: 1px solid var(--border); border-radius: var(--radius); background: var(--panel); overflow: hidden; }
.pro-wk-row { display: grid; grid-template-columns: 160px repeat(7, minmax(0, 1fr)); border-bottom: 1px solid var(--border); }
.pro-wk-row:last-child { border-bottom: none; }
.pro-wk-head { padding: 6px 8px; background: var(--panel-alt); font-size: 12px; color: var(--text-dim); }
.pro-wk-head b { color: var(--text); font-weight: 600; }
.pro-wk-head.is-today, .pro-wk-head.is-today b { color: var(--accent); }
.pro-wk-tech { grid-column: 1; padding: 8px 10px; display: flex; align-items: center; gap: 8px; font-size: 13px; background: var(--panel-alt); border-right: 1px solid var(--border); }
.pro-wk-cell { min-height: 64px; border-right: 1px solid var(--border); }
.pro-wk-cell:last-child { border-right: none; }
.pro-wk-cell.is-weekend { background: color-mix(in srgb, var(--panel) 85%, var(--bg-deep)); }
.pro-wk-cell.is-today { background: color-mix(in srgb, var(--accent-dim) 14%, var(--panel)); }
.pro-wk-row .pro-chip { position: relative; z-index: 1; align-self: start; margin: 6px 4px; width: auto; white-space: normal; flex-direction: column; align-items: flex-start; gap: 0; padding: 4px 7px; }
.pro-wk-row .pro-chip .pro-chip-name { white-space: nowrap; width: 100%; }
.pro-cal-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.pro-cal-list h4 { margin: 0 0 4px; font-size: 13px; }
.pro-cal-list li.is-today h4 { color: var(--accent); }
.pro-cal-list .pro-chip { width: 100%; margin: 0 0 6px; white-space: normal; flex-wrap: wrap; font-size: 13px; padding: 6px 9px; }

/* --- Schedule, Work done, My calendar link (mockups 06a, 06d, 06e) --- */
.pro-when-time { display: flex; align-items: center; gap: 10px; margin-top: 6px; }
.pro-when-time input[type="time"] { width: 120px; }
.pro-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.pro-pick { padding: 4px 12px; border: 1px solid var(--border); border-radius: 14px; background: var(--panel-alt); color: var(--text); font-size: 13px; }
.pro-pick[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-dim); }
.pro-pick[aria-pressed="true"]::before { content: "✓ "; }
.pro-pick:disabled { cursor: default; opacity: .8; }
.pro-pick-kept { margin-left: 4px; color: var(--text-dim); }
.pro-taken { margin-top: 12px; }
.pro-taken td, .pro-taken th { vertical-align: middle; }
.pro-dialog input.pro-num { width: 90px; text-align: right; }
.pro-feed-copy { display: flex; gap: 8px; }
.pro-feed-copy .pro-feed-url { flex: 1; min-width: 0; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; }
.pro-feed-actions { gap: 8px; margin-top: 12px; justify-content: flex-end; }

/* --- New job: a job added by hand (SPEC 32) --- */
.pro-hand-lines { max-width: none; margin-top: 4px; }
.pro-hand-lines td, .pro-hand-lines th { vertical-align: middle; }
.pro-hand-lines select { max-width: 240px; }
.pro-dialog .pro-hand-lines input.pro-num { width: 90px; text-align: right; }
.pro-hand-lines tfoot th, .pro-hand-lines tfoot td { background: var(--panel-alt); font-weight: 600; border-top: 1px solid var(--border); }
.pro-hand-remove { width: 28px; text-align: right; }
.pro-hand-add { margin-top: 6px; font-size: 12.5px; }

/* --- Billing: each line quoted and billed, the breakdown (SPEC 30; mockup 07a) --- */
/* Hours and times typed, as the queue's own fields look (its rule leaves
   these two types out). */
:where(#services-panel, .pro-sheet, .pro-dialog) :is(input[type="number"], input[type="time"]) {
  background: var(--bg); border: 1px solid var(--border); color: var(--text); border-radius: 4px; padding: 6px 8px; font: inherit; font-size: 13px; min-width: 0;
}
.pro-head-buttons { display: inline-flex; gap: 14px; font-size: 12.5px; }
.pro-bill-head { margin: 0 0 8px; font-size: 13px; }
.pro-bill-head select { margin-left: 6px; }
.pro-bill-wrap { max-width: none; margin-bottom: 10px; }
.pro-bill-table th[scope="row"] { font-weight: 500; white-space: nowrap; }
.pro-bill-table.no-money th[scope="row"] { width: 230px; }
.pro-bill-table td { vertical-align: middle; }
.pro-bill-table thead th { font-size: 11.5px; }
.pro-bill-table .pro-num { width: 70px; text-align: right; font-variant-numeric: tabular-nums; padding: 4px 6px; }
.pro-rate, .pro-entry { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; color: var(--text-dim); }
.pro-rate-fixed { color: var(--text-dim); font-variant-numeric: tabular-nums; }
.pro-bill-table tr.pro-rest > * { background: color-mix(in srgb, var(--accent-dim) 22%, var(--panel)); }
.pro-bill-table tr.pro-rest b { font-size: 14px; font-variant-numeric: tabular-nums; }
.pro-bill-table tr.pro-changed th[scope="row"] { color: var(--accent); }
.pro-bill-table tfoot th, .pro-bill-table tfoot td { background: var(--panel-alt); font-weight: 600; border-top: 1px solid var(--border); }
.pro-check { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; }
.pro-check.is-ok { color: var(--ok-fg); }
.pro-check.is-ok::before { content: "✓"; }
.pro-check.is-bad { color: var(--disc-fg); }
.pro-bill-actions { gap: 12px; flex-wrap: wrap; align-items: center; font-size: 12.5px; }
.pro-expenses { display: inline-flex; flex-wrap: wrap; gap: 6px; }
/* An expense: its words, and only its × removes it. */
.pro-expense { display: inline-flex; align-items: center; gap: 2px; padding-left: 8px; border: 1px solid var(--border); border-radius: 4px; background: var(--panel-alt); color: var(--text); }
.pro-expense .dq-remove { border: none; background: transparent; }
.pro-expense .dq-remove:hover { background: var(--danger-fill); }
/* Bill actual hours and Add line (admins, Ready to Bill), under the lines;
   a line added at billing reads "Not quoted". */
.pro-line-actions { margin: 0 0 10px; }
.pro-bill-table tr.pro-added td[data-label="Quoted"] { color: var(--text-dim); }
.pro-bill-table tr.pro-added .dq-remove { margin-left: 2px; }
.pro-line-price { margin: 4px 0 0; }

/* --- Accounting: the emails sent and their buttons --- */
.pro-sends { list-style: none; margin: 0; padding: 0; font-size: 13px; }
.pro-sends li { padding: 4px 0; display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; }
.pro-button-state { padding: 0 7px; border: 1px solid var(--border); border-radius: 8px; font-size: 11.5px; color: var(--text-dim); }
.pro-button-state.is-waiting { border-color: var(--accent-dim); color: var(--accent); }
.pro-button-state.is-expired { border-color: var(--warn-border); color: var(--warn-fg-soft); }
.pro-said { flex-basis: 100%; margin: 6px 0 0; padding: 10px 12px; max-height: 360px; overflow: auto; border: 1px solid var(--border); border-radius: var(--radius); background: var(--panel-alt); font-size: 12px; line-height: 1.45; white-space: pre-wrap; }
.pro-addr { list-style: none; margin: 4px 0 0; padding: 0; border: 1px solid var(--border); border-radius: var(--radius); background: var(--panel-alt); }
.pro-addr li { display: flex; align-items: center; gap: 8px; padding: 6px 10px; border-bottom: 1px solid var(--border); font-size: 13px; }
.pro-addr li:last-child { border-bottom: 0; }
.pro-addr li .dq-hint { margin-left: auto; }
/* A row's words and box in one label, so a tap anywhere on it ticks the
   box; its parts laid out as the row's own (dialogs.js, settings.js). */
.pro-row-label { display: contents; }

/* --- The accounting email's Billing complete page (the sign-in card) --- */
.pro-billed .pro-job { margin: 0 0 14px; padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--panel-alt); font-size: 13.5px; line-height: 1.5; text-align: left; }
.pro-billed .pro-job b { font-weight: 600; }
.pro-billed .email-signin-actions { display: flex; gap: 10px; justify-content: center; margin-top: 16px; }
.pro-billed .email-signin-actions button { min-width: 140px; padding: 9px 16px; font-size: 14px; }

/* --- A design request moved to Services (the queue's sheet) --- */
.sv-moved { border-color: var(--accent-dim); background: color-mix(in srgb, var(--accent-dim) 22%, var(--panel)); color: var(--text); }

/* --- My jobs: a technician's phone home (myJobs.js; approved Oct 31). Cards
   a thumb can work: the job's name and days large, the site a maps link,
   three steps a finger wide; Log hours a sheet of − box + rows. --- */
.pro-my { max-width: 720px; width: 100%; }
.pro-my-group + .pro-my-group { margin-top: 18px; }
.pro-my-head { display: flex; align-items: center; margin: 4px 0 8px; font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-dim); }
.pro-my-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.pro-my-card { padding: 12px 14px; background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); }
/* Its days passed and it isn't marked done. */
.pro-my-group.is-earlier .pro-my-head { color: var(--disc-fg); }
.pro-my-group.is-earlier .pro-my-card { border-color: var(--disc-border); }
.pro-my-num { margin: 0 0 2px; font-size: 12px; color: var(--text-dim); font-variant-numeric: tabular-nums; }
.pro-my-name { margin: 0; font-size: 17px; line-height: 1.3; color: var(--text); overflow-wrap: anywhere; }
.pro-my-dealer { margin: 2px 0 0; font-size: 13.5px; color: var(--text-dim); overflow-wrap: anywhere; }
.pro-my-when { margin: 8px 0 0; font-size: 14.5px; font-weight: 600; color: var(--text); }
.pro-my-site { display: flex; align-items: center; gap: 8px; min-height: 40px; margin-top: 4px; font-size: 14.5px; line-height: 1.3; color: var(--accent); overflow-wrap: anywhere; }
/* A map pin, drawn: a ring with one square corner, turned to point down. */
.pro-my-site::before { content: ""; flex: none; width: 9px; height: 9px; margin: 0 1px 3px; border: 2.5px solid currentColor; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); }
.pro-my-logged { margin: 2px 0 0; font-size: 13px; color: var(--text-dim); }
.pro-my-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 12px; }
.pro-my-steps.is-two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
#services-panel .pro-my-step { min-height: 52px; padding: 6px 8px; font-size: 15px; font-weight: 600; }
.pro-my-more { display: flex; gap: 24px; margin: 4px 0 0; }
#services-panel .pro-my-link { min-height: 44px; font-size: 14px; }
.pro-my-said { margin: 0; font-size: 13px; color: var(--ok-fg); }
.pro-my-said:empty { display: none; }
.pro-my-said.error { color: var(--danger-text); }
#services-panel .pro-my-board { width: 100%; min-height: 48px; margin-top: 18px; font-size: 15px; }
.pro-log-rows { display: flex; flex-direction: column; outline: none; }
/* The label's column takes what's left, so every row's − box + lines up. */
.pro-log-row { display: grid; grid-template-columns: minmax(0, 1fr) auto 40px; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--border); }
.pro-log-row:last-child { border-bottom: 0; }
.pro-log-label { display: flex; flex-direction: column; font-size: 15px; font-weight: 600; line-height: 1.25; }
.pro-log-label small { font-size: 12.5px; font-weight: 400; color: var(--text-dim); }
.pro-stepper { display: flex; align-items: center; gap: 4px; }
.pro-log .pro-step { width: 44px; height: 48px; padding: 0; font-size: 22px; line-height: 1; }
/* 16px and over, so a phone doesn't zoom into the box as it's tapped. */
.pro-log input.pro-step-in { width: 56px; height: 48px; padding: 0 4px; font-size: 18px; text-align: center; box-sizing: border-box; }
.pro-log-unit { font-size: 13px; color: var(--text-dim); }
.pro-log-who { margin: 0 0 4px; font-size: 13px; line-height: 1.35; color: var(--text-dim); }
/* .pro-dialog.pro-log: above the phone's 40px for a dialog's buttons. */
.pro-dialog.pro-log .dq-dialog-actions button { min-height: 48px; min-width: 104px; font-size: 15px; }

/* --- A phone --- */
@media (max-width: 700px) {
  /* Log hours sits at the foot of the screen, where a thumb is. */
  .dq-dialog.pro-log { margin-bottom: 8px; }
  .pro-board-wrap { display: none; }
  .pro-phone { display: block; }
  .dq-toolbar .sv-filters-inline { flex-basis: 100%; order: 4; }
  #services-panel .dq-subtabs { flex-wrap: nowrap; overflow-x: auto; }
  #services-panel .dq-subtab { flex: none; }
  /* With My jobs, a technician's five tabs fit at 390 (12px a side ran My
     emails off the edge), and an admin's sixth shows its edge. */
  #services-panel .dq-subtabs .dq-subtab { padding-left: 10px; padding-right: 10px; }
  .pro-two { grid-template-columns: 1fr; }
  .pro-facts { grid-template-columns: 78px 1fr; }
  /* minmax(0, …): a long dealer's name (one line, cut with an ellipsis)
     never widens the column past the screen. */
  .pro-cal-layout { grid-template-columns: minmax(0, 1fr); }
  .pro-cal-bar h3 { flex-basis: 100%; order: -1; margin: 0; }
  .pro-feed-copy { flex-direction: column; }
  /* Nine labels in ~40px columns ran into each other: dots only, and the
     line under them names the step. */
  .pro-steps li { font-size: 0; }
  .pro-steps small { display: none; }
  .pro-steps-line { display: block; }
  /* A table's empty spacer cell, no card row of its own. */
  .pro-bill-table td:empty { display: none; }
  /* New job's lines as cards: the item's picker the card's width, the
     figures beside their names, the total on one line. */
  .pro-hand-lines td:empty { display: none; }
  .pro-hand-lines td { align-items: center; }
  .pro-hand-lines select { max-width: none; flex: 1; min-width: 0; }
  .pro-dialog .pro-hand-lines input.pro-num { width: 120px; flex: none; }
  .pro-hand-lines .pro-hand-remove { width: auto; justify-content: flex-end; }
  .pro-hand-lines tfoot tr { display: flex; justify-content: space-between; align-items: baseline; }
  .pro-hand-lines tfoot th, .pro-hand-lines tfoot td { background: none; border-top: none; padding: 0; }
  /* New job's Design list opens upward, over the fields above it (one
     column here, ~270px of them): below, with no line, it covered Add a
     line, Add job and Cancel, and a tap on one picked a design. With the
     dialog scrolled down, the dialog scrolls back as it opens to show all
     of it (dialogs.js, drawDesigns). */
  .pro-dialog .pro-design-combo .dq-combo-list { top: auto; bottom: 100%; margin: 0 0 2px; }
  /* Each billing table keeps its name over its cards (Quoted and billed,
     Breakdown (internal), Actual breakdown): the cards' heads are hidden, and
     without it the hours entered read as the hours billed. */
  .pro-bill-table thead { display: block; }
  .pro-bill-table thead tr { margin: 0; padding: 0; border: none; background: none; }
  .pro-bill-table thead th { display: none; }
  .pro-bill-table thead th:first-child { display: block; padding: 2px 0 6px; border: none; background: none; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-dim); }
  /* Work done's table keeps its name ("Actual breakdown") the same way. */
  .pro-taken .dq-report-table thead { display: block; }
  .pro-taken .dq-report-table thead tr { margin: 0; padding: 0; border: none; background: none; }
  .pro-taken .dq-report-table thead th { display: none; }
  .pro-taken .dq-report-table thead th:first-child { display: block; padding: 2px 0 6px; border: none; background: none; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-dim); }
  /* 16px, so a phone doesn't zoom into a field as it's tapped (the queue's
     Ask form does the same); the hour boxes wide enough for 2500.00. */
  :is(#services-panel, .pro-sheet, .pro-dialog) :is(input:not([type="checkbox"], [type="radio"]), select, textarea) { font-size: 16px; }
  /* My jobs's Log hours boxes keep their 18px (as specific as the rule
     above, and after it). */
  :is(#services-panel, .pro-sheet, .pro-dialog) input.pro-step-in { font-size: 18px; }
  .pro-bill-table .pro-num, .pro-bill-head .pro-num { width: 84px; }
  .pro-bill-table td, .pro-taken td { align-items: center; }
  /* The email's text as it goes, its table lines whole: wider than the
     phone, it scrolls sideways; the dialog scrolls it down. */
  .pro-said { white-space: pre; overflow-x: auto; font-size: 11px; max-height: none; }
  .pro-addr li { min-height: 44px; }
  /* A finger's room: 40px at the least for what's tapped, 44px for a
     menu's rows (the queue's menus too). */
  #services-panel :is(.dq-subtab, .dq-view-chip, .dq-toolbar button, .pro-cal-bar button), .pro-sheet :is(.dq-sheet-actions button, .dq-sheet-close, .dq-note-form button, .pro-line-actions button), .pro-dialog .dq-dialog-actions button, .pro-pick { min-height: 40px; }
  .pro-sheet .dq-link-button, .pro-dialog .dq-link-button { min-height: 40px; padding: 8px 0; text-align: left; }
  .pro-phone-next .dq-link-button { min-height: 40px; }
  .pro-sheet .dq-remove { min-width: 40px; min-height: 36px; }
  /* Add line's item and quantity, Work done's hours and the rest of a
     Services dialog's pickers and number boxes, and a line added's ×:
     40px too (34px, 32px and 36px at 390 px). */
  .pro-dialog :is(select, input.pro-num), .pro-bill-table .dq-remove { min-height: 40px; box-sizing: border-box; }
  .pro-dialog .dq-check { min-height: 36px; }
  .pro-dialog .dq-combo-list li { padding: 11px 10px; }
  .dq-menu button { min-height: 44px; }
  /* Long names wrap or end in an ellipsis, never past the screen's edge;
     a dealer's card has no empty rows. */
  .pro-files .dq-link-button { text-align: left; overflow-wrap: anywhere; flex: 1 1 calc(100% - 60px); min-width: 0; }
  .pro-files a { display: inline-block; padding: 11px 0; overflow-wrap: anywhere; flex: 1 1 calc(100% - 60px); min-width: 0; }
  .pro-cal-list .pro-chip .pro-chip-dealer { flex: 1 1 100%; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .pro-dealers td:empty { display: none; }
  /* A dialog within the screen with Safari's toolbars showing (100vh is
     its height without them); a browser without dvh keeps the queue's
     100vh. */
  .pro-dialog { max-height: calc(100dvh - 16px); }
}

/* A job's visits (John, Nov 3, 2026): the sheet's list (each visit's
   technicians with their own hours, a visit not needed struck through),
   the Schedule dialog's blocks, the calendar's "2/3", My jobs' visit line,
   Log hours' and Work done's Whose hours, and the Billing box's By
   technician. */
.pro-visits { list-style: none; margin: 0 0 10px; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.pro-visit { padding: 10px 12px; border: 1px solid var(--border); border-left: 3px solid var(--accent); border-radius: var(--radius); background: var(--panel); }
.pro-visit.is-done { border-left-color: var(--ok-border); background: var(--panel-alt); }
.pro-visit.is-not-needed { border-left-color: var(--border); background: var(--panel-alt); }
.pro-visit.is-not-needed .pro-visit-when, .pro-visit.is-not-needed .pro-visit-note { text-decoration: line-through; color: var(--text-dim); }
.pro-visit.is-now { box-shadow: 0 0 0 1px var(--accent-dim); }
.pro-visit-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.pro-visit-n { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--accent); }
.pro-visit.is-done .pro-visit-n { color: var(--ok-fg); }
.pro-visit.is-not-needed .pro-visit-n { color: var(--text-dim); }
.pro-visit-when { font-size: 14px; font-weight: 600; color: var(--text); }
.pro-visit-state { margin-left: auto; font-size: 12.5px; color: var(--text-dim); }
.pro-visit-state.is-done { color: var(--ok-fg); }
.pro-visit-note { margin: 2px 0 0; font-size: 13px; color: var(--text); }
.pro-visit-who { list-style: none; margin: 4px 0 0; padding: 0; font-size: 13px; color: var(--text-dim); }
.pro-visit-who li { display: flex; flex-wrap: wrap; gap: 0 8px; }
.pro-visit-tech { color: var(--text); }
.pro-visit-hours { font-variant-numeric: tabular-nums; }
.pro-visit-steps { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.pro-visit-steps:empty { display: none; }
.pro-visit-list { display: flex; flex-direction: column; gap: 10px; }
.pro-visit-fields { margin: 0; padding: 8px 12px 4px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--panel-alt); min-width: 0; }
.pro-visit-legend { display: flex; align-items: center; gap: 8px; padding: 0 4px; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--accent); }
.pro-add-visit { margin: 8px 0 4px; font-size: 14px; }
.pro-visits-done { list-style: none; margin: 0 0 8px; padding: 0; font-size: 13px; color: var(--text-dim); }
.pro-visits-done li + li { margin-top: 2px; }
.pro-chip .pro-chip-visit { flex: none; padding: 0 4px; border-radius: 3px; background: var(--panel); color: var(--accent); font-size: 10px; font-weight: 700; font-variant-numeric: tabular-nums; }
.pro-chip.is-past .pro-chip-visit { color: var(--text-dim); }
.pro-my-visit { margin-left: 8px; padding: 1px 7px; border-radius: 10px; background: var(--accent-dim); color: var(--text); font-size: 11.5px; font-weight: 600; }
.pro-my-note { margin: 2px 0 0; font-size: 13.5px; color: var(--text); }
.pro-whose { margin-bottom: 6px; }
.pro-log .pro-whose .pro-chips { gap: 6px; }
.pro-log-hours { margin-top: 4px; }
@media (max-width: 700px) {
  .pro-visit-steps > button { flex: 1 1 calc(50% - 8px); min-height: 44px; }
  .pro-visit-state { margin-left: 0; width: 100%; }
  .pro-whose .pro-pick { min-height: 40px; }
  .pro-log-hours { width: 100%; min-height: 44px; }
}
