:root,
body.hcp-dark-body {
  --bg: #070b14;
  --panel: #0f172a;
  --panel2: #162033;
  --panel3: #1e293b;
  --text: #f8fafc;
  --tx: #f8fafc;
  --tx-sec: #cbd5e1;
  --mut: #94a3b8;
  --line: rgba(148, 163, 184, 0.16);
  --acc: #7c5cff;
  --acc2: #22d3ee;
  --ok: #10b981;
  --warn: #f59e0b;
  --bad: #f43f5e;
}

body.hcp-light-body {
  --bg: #f4f5f7;
  --panel: #ffffff;
  --panel2: #f8fafc;
  --panel3: #f1f5f9;
  --text: #0f172a;
  --tx: #0f172a;
  --tx-sec: #334155;
  --mut: #64748b;
  --line: #e2e8f0;
  --acc: #006aff;
  --acc2: #0284c7;
  --ok: #16a34a;
  --warn: #d97706;
  --bad: #dc2626;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font: 13.5px/1.45 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: radial-gradient(1100px 600px at 85% -10%, rgba(34, 211, 238, 0.09), transparent 60%),
    radial-gradient(900px 500px at 15% 0%, rgba(124, 92, 255, 0.13), transparent 55%),
    var(--bg);
  min-height: 100vh;
  transition: background-color 0.18s ease, color 0.18s ease;
}

body.hcp-light-body {
  background: var(--bg);
}

.v2-layout,
.hcp-shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  width: 100%;
}

/* ==========================================================================
   1-TO-1 HOUSECALL PRO 56PX TOP NAVIGATION BAR (DARK & LIGHT AWARE)
   ========================================================================== */

.hcp-topnav {
  height: 56px;
  background: rgba(11, 17, 32, 0.94);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
  padding: 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.28);
}

body.hcp-light-body .hcp-topnav {
  background: #ffffff;
  border-bottom: 1px solid #e2e8f0;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.hcp-topnav-left {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 100%;
  flex: 0 0 auto;
  overflow: visible;
}

.hcp-brand-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 4px 9px 4px 5px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--panel2);
  cursor: pointer;
  text-align: left;
  flex-shrink: 0;
  transition: 0.15s;
}

body.hcp-light-body .hcp-brand-btn {
  background: #ffffff;
  border-color: #e2e8f0;
}

.hcp-brand-btn:hover {
  border-color: var(--acc2);
}

.hcp-brand-badge {
  width: 32px;
  height: 32px;
  border-radius: 7px;
  background: linear-gradient(135deg, #10b981, #059669);
  color: #ffffff !important;
  font-weight: 800;
  font-size: 11.5px;
  display: grid;
  place-items: center;
  letter-spacing: -0.02em;
  box-shadow: 0 3px 10px rgba(16, 185, 129, 0.3);
}

.hcp-brand-text b {
  display: block;
  font-size: 12.5px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.15;
}

.hcp-brand-text small {
  display: block;
  font-size: 10px;
  font-weight: 700;
  color: var(--ok);
  line-height: 1.15;
}

.hcp-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  height: 100%;
}

.hcp-nav-link,
.v2-nav-btn.hcp-nav-link {
  height: 56px;
  padding: 0 9px;
  flex-shrink: 0;
  border: 0;
  border-bottom: 3px solid transparent;
  border-radius: 0;
  background: transparent;
  color: var(--mut);
  font: 600 13px 'Inter', sans-serif;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: color 0.14s, border-color 0.14s, background 0.14s;
  white-space: nowrap;
}

.hcp-nav-link:hover,
.v2-nav-btn.hcp-nav-link:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}

body.hcp-light-body .hcp-nav-link:hover,
body.hcp-light-body .v2-nav-btn.hcp-nav-link:hover {
  color: #006aff;
  background: rgba(0, 106, 255, 0.04);
}

.hcp-nav-link.active,
.v2-nav-btn.hcp-nav-link.active {
  color: var(--acc2);
  border-bottom-color: var(--acc2);
  font-weight: 700;
  background: rgba(34, 211, 238, 0.07);
  box-shadow: none;
}

body.hcp-light-body .hcp-nav-link.active,
body.hcp-light-body .v2-nav-btn.hcp-nav-link.active {
  color: #006aff;
  border-bottom-color: #006aff;
  background: transparent;
}

.hcp-nav-badge {
  background: var(--acc);
  color: #ffffff !important;
  font-size: 11px;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: 999px;
  line-height: 1.35;
}

.hcp-more-menu {
  position: relative;
  height: 56px;
  display: flex;
  align-items: center;
}

.hcp-more-summary {
  list-style: none;
  user-select: none;
}

.hcp-more-summary::-webkit-details-marker {
  display: none;
}

.hcp-more-dropdown {
  position: absolute;
  top: 54px;
  left: 0;
  min-width: 265px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 6px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  display: flex;
  flex-direction: column;
  gap: 2px;
  z-index: 80;
}

body.hcp-light-body .hcp-more-dropdown {
  background: #ffffff;
  border-color: #cbd5e1;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.14);
}

.hcp-more-item {
  width: 100%;
  text-align: left;
  padding: 9px 11px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text);
  font: 600 12.5px 'Inter', sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
}

.hcp-more-item:hover {
  background: var(--panel2);
  color: var(--acc2);
}

body.hcp-light-body .hcp-more-item:hover {
  background: #f1f5f9;
  color: #006aff;
}

.hcp-topnav-right {
  display: flex;
  align-items: center;
  flex: 0 1 auto;
  min-width: 0;
  gap: 6px;
  justify-content: flex-end;
}

.hcp-top-search,
#v2-search {
  width: 175px;
  padding: 6px 11px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--panel2);
  color: var(--text);
  font-size: 12px;
  transition: 0.15s;
}

body.hcp-light-body .hcp-top-search,
body.hcp-light-body #v2-search {
  background: #f1f5f9;
  border-color: #cbd5e1;
  color: #0f172a;
}

.hcp-top-search:focus,
#v2-search:focus {
  border-color: var(--acc2);
  width: 205px;
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.16);
}

.hcp-new-btn {
  background: linear-gradient(135deg, var(--acc), #4f46e5) !important;
  color: #ffffff !important;
  border: 1px solid rgba(124, 92, 255, 0.6) !important;
  border-radius: 999px;
  padding: 7px 15px;
  font: 700 12.5px 'Inter', sans-serif;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(124, 92, 255, 0.3);
}

body.hcp-light-body .hcp-new-btn {
  background: #111827 !important;
  border-color: #111827 !important;
  box-shadow: none;
}

.hcp-theme-toggle-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(34, 211, 238, 0.45);
  background: rgba(34, 211, 238, 0.12);
  color: #67e8f9;
  font: 700 12px 'Inter', sans-serif;
  cursor: pointer;
  white-space: nowrap;
  transition: 0.15s;
}

.hcp-theme-toggle-btn:hover {
  background: rgba(34, 211, 238, 0.22);
  transform: translateY(-1px);
}

body.hcp-light-body .hcp-theme-toggle-btn {
  border-color: #cbd5e1;
  background: #f8fafc;
  color: #0f172a;
}

body.hcp-light-body .hcp-theme-toggle-btn:hover {
  background: #e2e8f0;
}

.hcp-icon-btn {
  position: relative;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid transparent;
  background: transparent;
  color: var(--tx-sec);
  font-size: 16px;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.hcp-icon-btn:hover {
  background: var(--panel2);
  border-color: var(--line);
}

.hcp-icon-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  background: var(--acc);
  color: #ffffff !important;
  font-size: 10px;
  font-weight: 800;
  padding: 0 5px;
  border-radius: 999px;
  border: 2px solid var(--panel);
}

.hcp-jarvis-pill {
  padding: 6px 11px;
  border-radius: 999px;
  border: 1px solid rgba(124, 92, 255, 0.5);
  background: rgba(124, 92, 255, 0.16);
  color: #c4b5fd;
  font: 700 12px 'Inter', sans-serif;
  cursor: pointer;
  white-space: nowrap;
}

body.hcp-light-body .hcp-jarvis-pill {
  border-color: #bae6fd;
  background: #f0f9ff;
  color: #0284c7;
}

.hcp-operator-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 8px 3px 4px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--panel2);
}

.hcp-operator-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--acc), var(--acc2));
  color: #ffffff !important;
  font-size: 10.5px;
  font-weight: 800;
  display: grid;
  place-items: center;
}

.hcp-operator-select {
  border: 0 !important;
  background: transparent !important;
  padding: 2px 4px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  color: var(--text) !important;
  max-width: 112px;
  text-overflow: ellipsis;
}

.hcp-operator-select option {
  background: var(--panel);
  color: var(--text);
}

/* ==========================================================================
   FULL-BLEED WORKSPACE CONTENT & THEME-AWARE CONTROLS
   ========================================================================== */

.v2-content,
.hcp-full-content {
  padding: 16px 20px 44px;
  width: 100%;
  max-width: 100vw;
}

input,
select,
textarea {
  background: var(--panel2);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 7px 10px;
  font: inherit;
  outline: none;
}

body.hcp-light-body input,
body.hcp-light-body select,
body.hcp-light-body textarea {
  background: #ffffff;
  border-color: #cbd5e1;
  color: #0f172a;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--acc2);
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.14);
}

.b {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--panel2);
  color: var(--text);
  font: 600 12.5px inherit;
  cursor: pointer;
  transition: 0.14s;
}

body.hcp-light-body .b {
  background: #ffffff;
  border-color: #cbd5e1;
  color: #1e293b;
}

.b:hover {
  border-color: var(--acc2);
  background: var(--panel3);
}

.b.sm {
  padding: 5px 9px;
  font-size: 11.5px;
}

.b.pri {
  background: linear-gradient(135deg, var(--acc), #4f46e5) !important;
  border-color: rgba(124, 92, 255, 0.6) !important;
  color: #ffffff !important;
  font-weight: 700;
}

body.hcp-light-body .b.pri {
  background: #006aff !important;
  border-color: #006aff !important;
}

.b.ok {
  background: #10b981 !important;
  border-color: #059669 !important;
  color: #ffffff !important;
  font-weight: 700;
}

.b.cyan {
  background: #0284c7 !important;
  border-color: #0369a1 !important;
  color: #ffffff !important;
  font-weight: 700;
}

.b.warn {
  background: rgba(245, 158, 11, 0.18) !important;
  border-color: rgba(245, 158, 11, 0.5) !important;
  color: #fde68a !important;
  font-weight: 700;
}

body.hcp-light-body .b.warn {
  background: #fef3c7 !important;
  border-color: #f59e0b !important;
  color: #92400e !important;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 14px;
}

.kpi {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 15px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.18);
}

body.hcp-light-body .kpi {
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

.kpi span {
  display: block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--mut);
}

.kpi b {
  display: block;
  font-size: 22px;
  font-weight: 800;
  margin-top: 4px;
  color: var(--text);
}

.ops-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 9px 14px;
  margin-bottom: 14px;
}

.sub-tabs {
  display: inline-flex;
  background: var(--panel2);
  padding: 3px;
  border-radius: 9px;
  border: 1px solid var(--line);
  gap: 3px;
}

.sub-tab {
  padding: 6px 12px;
  border-radius: 7px;
  border: 0;
  background: transparent;
  color: var(--mut);
  font: 700 12px inherit;
  cursor: pointer;
}

.sub-tab.on {
  background: rgba(124, 92, 255, 0.25);
  color: #ffffff;
  border: 1px solid rgba(124, 92, 255, 0.5);
}

body.hcp-light-body .sub-tab.on {
  background: #ffffff;
  color: #006aff;
  border: 0;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
}

.card,
.hcp-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 16px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.22);
  color: var(--text);
}

body.hcp-light-body .card,
body.hcp-light-body .hcp-card {
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 99px;
  background: var(--panel2);
  border: 1px solid var(--line);
  color: var(--tx-sec);
}

.tag.ok-tag {
  background: rgba(16, 185, 129, 0.16);
  border-color: rgba(16, 185, 129, 0.45);
  color: #34d399;
}

body.hcp-light-body .tag.ok-tag {
  background: #dcfce7;
  border-color: #86efac;
  color: #15803d;
}

.tag.warn-tag,
.tag.gate {
  background: rgba(245, 158, 11, 0.16);
  border-color: rgba(245, 158, 11, 0.45);
  color: #fbbf24;
}

body.hcp-light-body .tag.warn-tag,
body.hcp-light-body .tag.gate {
  background: #fef3c7;
  border-color: #fcd34d;
  color: #b45309;
}

.tag.cc {
  background: rgba(34, 211, 238, 0.15);
  border-color: rgba(34, 211, 238, 0.45);
  color: #67e8f9;
}

body.hcp-light-body .tag.cc {
  background: #e0f2fe;
  border-color: #7dd3fc;
  color: #0369a1;
}

.tag.bad-tag {
  background: rgba(244, 63, 94, 0.16);
  border-color: rgba(244, 63, 94, 0.45);
  color: #fb7185;
}

body.hcp-light-body .tag.bad-tag {
  background: #fee2e2;
  border-color: #fca5a5;
  color: #b91c1c;
}

.meta {
  font-size: 12px;
  color: var(--mut);
}

/* ==========================================================================
   SCHEDULE SUBHEADER, DISPATCH SWIMLANE GRID & INTERACTIVE MAP
   ========================================================================== */

.hcp-sched-toolbar {
  min-height: 52px;
  padding: 8px 18px;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin: -16px -20px 14px;
}

.hcp-sched-left,
.hcp-sched-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.hcp-unsched-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 11px;
  border-radius: 7px;
  border: 1px solid var(--line);
  background: var(--panel2);
  color: var(--text);
  font-weight: 700;
  font-size: 12.5px;
  cursor: pointer;
}

.hcp-red-badge {
  background: #ef4444;
  color: #ffffff !important;
  font-size: 11px;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 999px;
}

.hcp-view-toggle {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 7px;
  overflow: hidden;
  background: var(--panel2);
}

.hcp-view-toggle button {
  padding: 6px 12px;
  border: 0;
  background: transparent;
  color: var(--mut);
  font: 700 12.5px 'Inter', sans-serif;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.hcp-view-toggle button.active,
.hcp-view-toggle button.on {
  background: var(--acc) !important;
  color: #ffffff !important;
}

.swimlane-wrap,
.hcp-dispatch-grid {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0;
  overflow-x: auto;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.22);
}

.swimlane-table,
.hcp-dispatch-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1020px;
  background: var(--panel);
}

.swimlane-table th,
.hcp-dispatch-table th {
  text-align: left;
  padding: 10px 12px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--mut);
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  background: var(--panel2);
}

.swimlane-table td,
.hcp-dispatch-table td {
  vertical-align: top;
  padding: 8px;
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  background: var(--panel);
}

.hcp-tech-cell {
  width: 130px;
  min-width: 130px;
  text-align: center;
  vertical-align: middle !important;
  background: var(--panel2) !important;
  padding: 12px 8px !important;
}

body.hcp-light-body .hcp-tech-cell {
  background: #ffffff !important;
}

.hcp-tech-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  margin: 0 auto 5px;
  display: grid;
  place-items: center;
  color: #ffffff !important;
  font-weight: 800;
  font-size: 12px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

.swimlane-drop-cell.drag-over {
  background: rgba(34, 211, 238, 0.12) !important;
  outline: 2px dashed var(--acc2);
}

.hcp-dispatch-card,
.swimlane-visit {
  border-radius: 7px;
  padding: 7px 10px;
  color: #ffffff !important;
  font-size: 12px;
  cursor: pointer;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.24);
  margin-bottom: 7px;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
  position: relative;
}

.hcp-dispatch-card *,
.swimlane-visit * {
  color: #ffffff;
}

.hcp-dispatch-card:hover,
.swimlane-visit:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.38);
}

.hcp-dispatch-line1 {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 6px;
  font-weight: 800;
  font-size: 12.5px;
  color: #ffffff !important;
}

.hcp-dispatch-initials {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.32);
  border: 1px solid rgba(255, 255, 255, 0.6);
  display: inline-grid;
  place-items: center;
  font-size: 10px;
  font-weight: 800;
  color: #ffffff !important;
  flex-shrink: 0;
}

.hcp-dispatch-line2,
.hcp-dispatch-line3,
.hcp-dispatch-line4 {
  font-size: 11.5px;
  line-height: 1.35;
  color: rgba(255, 255, 255, 0.95) !important;
  margin-top: 2px;
}

.open-slot-btn {
  width: 100%;
  min-height: 54px;
  border-radius: 7px;
  border: 1px dashed var(--line);
  background: rgba(255, 255, 255, 0.02);
  color: var(--mut);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  cursor: pointer;
  transition: 0.14s;
  font-size: 11.5px;
}

body.hcp-light-body .open-slot-btn {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.open-slot-btn:hover {
  border-color: var(--acc2);
  background: rgba(34, 211, 238, 0.08);
  color: var(--text);
}

/* INTERACTIVE SAN ANTONIO MAP SPLIT VIEW */
.hcp-map-split {
  height: calc(100vh - 122px);
  min-height: 560px;
  display: grid;
  grid-template-columns: 72% 28%;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.hcp-map-canvas,
#v2-hcp-dispatch-map,
#v2-hcp-job-mini-map,
#v2-hcp-home-map {
  position: relative;
  width: 100%;
  height: 100%;
  background: #e5e3df !important;
  color: #1e293b;
}

.leaflet-container {
  background: #e5e3df !important;
  font-family: 'Inter', system-ui, sans-serif !important;
}

.hcp-leaflet-pin {
  background: transparent !important;
  border: 0 !important;
}

.hcp-map-floating-pills {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.hcp-map-pill {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 6px 12px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  cursor: pointer;
}

.hcp-map-sidebar {
  border-left: 1px solid var(--line);
  background: var(--panel);
  padding: 14px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.hcp-pin-circle {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  font-size: 11px;
  font-weight: 800;
  color: #ffffff !important;
  flex-shrink: 0;
}

/* ==========================================================================
   MODALS, DRAWER, DASH & DATA TABLES
   ========================================================================== */

.modal-bg {
  position: fixed;
  inset: 0;
  background: rgba(3, 6, 14, 0.72);
  backdrop-filter: blur(5px);
  display: grid;
  place-items: center;
  padding: 18px;
  z-index: 70;
}

.modal {
  width: 100%;
  max-width: 740px;
  max-height: 92vh;
  overflow-y: auto;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px 20px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
  color: var(--text);
}

.preset-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 6px;
}

.preset-card {
  text-align: left;
  padding: 9px 11px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--panel2);
  color: var(--text);
  cursor: pointer;
}

.preset-card.on {
  border-color: var(--acc2);
  background: rgba(34, 211, 238, 0.14);
}

.win-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.win-btn {
  padding: 9px 8px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--panel2);
  color: var(--text);
  cursor: pointer;
  text-align: center;
  font-weight: 600;
}

.win-btn.on {
  border-color: var(--acc2);
  background: rgba(34, 211, 238, 0.15);
  color: var(--acc2);
}

.drawer-bg {
  position: fixed;
  inset: 0;
  background: rgba(3, 6, 14, 0.65);
  backdrop-filter: blur(4px);
  display: flex;
  justify-content: flex-end;
  z-index: 65;
}

.drawer {
  width: 100%;
  max-width: 620px;
  height: 100vh;
  background: var(--panel);
  border-left: 1px solid var(--line);
  padding: 18px 20px;
  overflow-y: auto;
  color: var(--text);
  box-shadow: -12px 0 36px rgba(0, 0, 0, 0.45);
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.grid-3,
.hcp-dash-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

#v2-toast {
  position: fixed;
  bottom: 20px;
  right: 22px;
  background: #10b981;
  color: #04130e !important;
  font-weight: 800;
  padding: 10px 18px;
  border-radius: 99px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  display: none;
  z-index: 99;
}

.morning-check-bar {
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 4px solid var(--warn);
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 14px;
}

.morning-buckets {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
  margin-top: 10px;
}

.morning-bucket {
  background: var(--panel2);
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 8px 10px;
}

.morning-bucket span {
  display: block;
  font-size: 10.5px;
  font-weight: 700;
  color: var(--mut);
}

.morning-bucket b {
  display: block;
  font-size: 16px;
  font-weight: 800;
  color: var(--text);
  margin-top: 2px;
}

.morning-item-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 8px 11px;
  border-radius: 8px;
  background: var(--panel2);
  border: 1px solid var(--line);
  font-size: 12.5px;
  color: var(--text);
}

.we-owe-banner {
  margin-top: 8px;
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(245, 158, 11, 0.14);
  border: 1px solid rgba(245, 158, 11, 0.45);
  border-left: 3px solid var(--warn);
  color: #fde68a;
  font-size: 12px;
}

body.hcp-light-body .we-owe-banner {
  background: #fffbeb;
  border-color: #fcd34d;
  color: #92400e;
}

.math-line {
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px dashed var(--line);
  background: var(--panel2);
  font-size: 12.5px;
  color: var(--tx-sec);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.data-table,
.hcp-customers-table,
.hcp-leaderboard-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
  background: var(--panel);
}

.data-table th,
.hcp-customers-table th,
.hcp-leaderboard-table th {
  text-align: left;
  padding: 10px 12px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--mut);
  border-bottom: 1px solid var(--line);
  background: var(--panel2);
}

.data-table td,
.hcp-customers-table td,
.hcp-leaderboard-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
  color: var(--text);
}

.data-table tr:hover td,
.hcp-customers-table tr:hover td,
.hcp-leaderboard-table tr:hover td {
  background: var(--panel2);
}

.hcp-leaderboard-table tr.total-row td {
  font-weight: 800;
  background: rgba(124, 92, 255, 0.14);
  color: var(--text);
}

body.hcp-light-body .hcp-leaderboard-table tr.total-row td {
  background: #eff6ff;
  color: #0f172a;
}

.pickup-banner {
  padding: 6px 9px;
  border-radius: 7px;
  background: rgba(34, 211, 238, 0.13);
  border: 1px solid rgba(34, 211, 238, 0.4);
  color: #67e8f9;
  font-size: 11.5px;
  font-weight: 700;
  margin-top: 6px;
}

body.hcp-light-body .pickup-banner {
  background: #e0f2fe;
  border-color: #7dd3fc;
  color: #0369a1;
}

/* ==========================================================================
   HOUSECALL PRO TWO-COLUMN JOB DETAIL & ESTIMATE DETAIL WORKSPACE
   ========================================================================== */

.hcp-detail-wrap {
  display: flex;
  flex-direction: column;
  gap: 14px;
  animation: hcpFadeIn 0.14s ease-out;
}

@keyframes hcpFadeIn {
  from {
    opacity: 0;
    transform: translateY(3px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hcp-top-bar {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hcp-breadcrumb {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  font-size: 12px;
  color: var(--mut);
}

.hcp-breadcrumb a,
.hcp-breadcrumb [data-close-job-detail],
.hcp-breadcrumb [data-close-estimate-detail],
.hcp-breadcrumb [data-open-360] {
  color: var(--acc2);
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}

body.hcp-light-body .hcp-breadcrumb a,
body.hcp-light-body .hcp-breadcrumb [data-close-job-detail],
body.hcp-light-body .hcp-breadcrumb [data-open-360] {
  color: #006aff;
}

.hcp-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.hcp-layout {
  display: grid;
  grid-template-columns: 310px 1fr;
  gap: 18px;
  align-items: start;
}

.hcp-left-rail,
.hcp-main-col {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.hcp-card-head,
.hcp-card > header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding-bottom: 9px;
  margin-bottom: 10px;
  border-bottom: 1px solid var(--line);
  font-weight: 700;
  font-size: 13.5px;
  color: var(--text);
}

.hcp-customer-banner {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.18), rgba(124, 92, 255, 0.18));
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 9px;
  padding: 10px 12px;
  margin-bottom: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  color: var(--text);
}

body.hcp-light-body .hcp-customer-banner {
  background: linear-gradient(135deg, #eff6ff, #e0f2fe);
  border-color: #bae6fd;
  color: #0f172a;
}

.hcp-contact-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid var(--line);
  font-size: 12.5px;
  color: var(--text);
}

.hcp-contact-row:last-child {
  border-bottom: 0;
}

/* 6-STEP HORIZONTAL STEPPER */
.hcp-stepper {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 4px;
  padding: 8px 6px 4px;
  overflow-x: auto;
  position: relative;
}

.hcp-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  flex: 1;
  min-width: 86px;
  position: relative;
  z-index: 2;
  cursor: pointer;
  user-select: none;
}

.hcp-step-undo {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--acc2);
  cursor: pointer;
  margin-bottom: 4px;
  min-height: 15px;
  text-decoration: underline;
}

.hcp-step-circle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 14px;
  font-weight: 800;
  background: var(--panel2);
  border: 2px solid var(--line);
  color: var(--mut);
  transition: 0.16s ease;
  position: relative;
  z-index: 2;
}

.hcp-step:hover .hcp-step-circle {
  border-color: var(--acc2);
  color: var(--acc2);
  transform: scale(1.05);
}

.hcp-step.done .hcp-step-circle,
.hcp-step.completed .hcp-step-circle,
.hcp-step-circle.done,
.hcp-step-circle.completed {
  background: linear-gradient(135deg, #0ea5e9, #2563eb) !important;
  border-color: #38bdf8 !important;
  color: #ffffff !important;
  box-shadow: 0 2px 10px rgba(14, 165, 233, 0.35);
}

.hcp-step.active .hcp-step-circle,
.hcp-step.current .hcp-step-circle,
.hcp-step-circle.active,
.hcp-step-circle.current {
  background: #0284c7 !important;
  border-color: #38bdf8 !important;
  color: #ffffff !important;
  box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.22);
  font-weight: 900;
}

.hcp-step-line {
  flex: 1;
  height: 3px;
  background: var(--line);
  align-self: center;
  margin-top: -12px;
  border-radius: 2px;
  min-width: 18px;
  z-index: 1;
}

.hcp-step-line.done,
.hcp-step-line.completed,
.hcp-step-line.active {
  background: linear-gradient(90deg, #0ea5e9, #2563eb);
}

.hcp-step-label {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-top: 7px;
  color: var(--tx-sec);
}

.hcp-step.active .hcp-step-label,
.hcp-step.done .hcp-step-label {
  color: var(--acc2);
}

.hcp-step-time {
  font-size: 10px;
  color: var(--mut);
  margin-top: 2px;
  line-height: 1.25;
  max-width: 115px;
}

.hcp-jarvis-bar {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.14), rgba(124, 92, 255, 0.16));
  border: 1px solid rgba(56, 189, 248, 0.4);
  border-radius: 11px;
  padding: 11px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  color: var(--text);
}

body.hcp-light-body .hcp-jarvis-bar {
  background: linear-gradient(135deg, #f0f9ff, #eff6ff);
  border-color: #bae6fd;
  color: #0f172a;
}

.hcp-line-item-row {
  background: var(--panel2);
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 12px;
  margin-bottom: 10px;
}

.hcp-line-item-grid {
  display: grid;
  grid-template-columns: 1fr 82px 125px 110px 34px;
  gap: 8px;
  align-items: center;
}

.hcp-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 7px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
  color: var(--text);
}

.hcp-summary-row.total {
  font-size: 16px;
  font-weight: 800;
  color: var(--text);
  border-top: 2px solid var(--line);
  padding-top: 10px;
  margin-top: 4px;
}

.hcp-notes-toggle,
.hcp-notes-tabs {
  display: inline-flex;
  background: var(--panel2);
  border: 1px solid var(--line);
  border-radius: 99px;
  padding: 2px;
  gap: 2px;
}

.hcp-notes-toggle button,
.hcp-notes-tab {
  padding: 4px 11px;
  border-radius: 99px;
  border: 0;
  background: transparent;
  color: var(--mut);
  font: 700 11px inherit;
  cursor: pointer;
  transition: 0.14s;
}

.hcp-notes-toggle button.on,
.hcp-notes-toggle button.active,
.hcp-notes-tab.on,
.hcp-notes-tab.active {
  background: var(--acc) !important;
  color: #ffffff !important;
  font-weight: 700;
}

.hcp-note-item {
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-left: 3px solid var(--warn);
  border-radius: 8px;
  padding: 8px 10px;
  margin-bottom: 8px;
  font-size: 12px;
  color: var(--text);
}

body.hcp-light-body .hcp-note-item {
  background: #fffbeb;
  border-color: #fde68a;
  color: #1e293b;
}

.hcp-field-row {
  display: grid;
  grid-template-columns: 112px 1fr;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 12px;
}

.hcp-field-row label {
  color: var(--mut);
  font-weight: 600;
}

.hcp-checklist-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 8px;
  background: var(--panel2);
  border: 1px solid var(--line);
  margin-bottom: 6px;
  cursor: pointer;
  transition: 0.14s;
  color: var(--text);
}

.hcp-checklist-row:hover {
  border-color: var(--acc2);
}

.hcp-accordion {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 11px;
  overflow: hidden;
  margin-bottom: 8px;
}

.hcp-accordion > summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  font-weight: 700;
  font-size: 13.5px;
  color: var(--text);
  cursor: pointer;
  background: var(--panel2);
  user-select: none;
}

.hcp-accordion > summary::-webkit-details-marker {
  display: none;
}

.hcp-accordion[open] > summary {
  border-bottom: 1px solid var(--line);
}

.hcp-accordion-body {
  padding: 14px 16px;
  background: var(--panel);
  color: var(--text);
}

.hcp-activity-feed {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hcp-activity-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 8px 11px;
  border-radius: 8px;
  background: var(--panel2);
  border: 1px solid var(--line);
  font-size: 12.5px;
  color: var(--text);
}

.hcp-unscheduled-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: 99px;
  background: rgba(239, 68, 68, 0.18);
  border: 1px solid rgba(239, 68, 68, 0.5);
  color: #fca5a5;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

body.hcp-light-body .hcp-unscheduled-pill {
  background: #fee2e2;
  border-color: #fca5a5;
  color: #dc2626;
}

/* ==========================================================================
   HOME (/app/home), DASH (/app/dashboard) & REPORTING WIDGETS
   ========================================================================== */

.hcp-home-hero {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.18) 0%, rgba(124, 92, 255, 0.24) 55%, rgba(217, 70, 239, 0.16) 100%) !important;
  border: 1px solid rgba(124, 92, 255, 0.4);
  border-radius: 13px;
  padding: 24px 22px;
  text-align: center;
  margin-bottom: 16px;
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.26);
  color: var(--text);
}

body.hcp-light-body .hcp-home-hero {
  background: linear-gradient(135deg, #e0f2fe 0%, #ede9fe 50%, #fae8ff 100%) !important;
  border-color: #ddd6fe;
  box-shadow: 0 2px 10px rgba(99, 102, 241, 0.08);
  color: #0f172a;
}

.hcp-home-hero h2 {
  margin: 0 0 12px;
  font-size: 20px;
  font-weight: 800;
  color: var(--text);
}

.hcp-home-prompts {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.hcp-home-prompt-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid rgba(167, 139, 250, 0.5);
  color: #e0e7ff;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.14s;
}

body.hcp-light-body .hcp-home-prompt-pill {
  background: rgba(255, 255, 255, 0.92);
  border-color: #c4b5fd;
  color: #4338ca;
}

.hcp-home-prompt-pill:hover {
  border-color: var(--acc2);
  transform: translateY(-1px);
}

.hcp-home-pipe-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 16px;
}

.hcp-pipe-blue-box {
  background: rgba(14, 165, 233, 0.12) !important;
  border: 1px solid rgba(56, 189, 248, 0.35) !important;
  border-radius: 9px;
  padding: 12px;
  margin: 10px 0;
  color: #e0f2fe !important;
}

body.hcp-light-body .hcp-pipe-blue-box {
  background: #eff6ff !important;
  border-color: #bfdbfe !important;
  color: #1e3a8a !important;
}

.hcp-mtd-ribbon {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 18px;
  margin-bottom: 16px;
}

.hcp-mtd-cols {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin-top: 10px;
}

.hcp-mtd-col {
  padding: 4px 16px;
  border-right: 1px solid var(--line);
}

.hcp-mtd-col:first-child {
  padding-left: 0;
}

.hcp-mtd-col:last-child {
  border-right: 0;
}

.hcp-mtd-col span.lbl {
  display: block;
  font-size: 10.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--mut);
}

.hcp-mtd-col b.val {
  font-size: 22px;
  font-weight: 800;
  color: var(--text);
}

.hcp-trend-up {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: rgba(16, 185, 129, 0.16);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.45);
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 99px;
}

body.hcp-light-body .hcp-trend-up {
  background: #dcfce7;
  color: #15803d;
  border-color: #86efac;
}

.hcp-trend-down {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: rgba(244, 63, 94, 0.16);
  color: #fb7185;
  border: 1px solid rgba(244, 63, 94, 0.45);
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 99px;
}

body.hcp-light-body .hcp-trend-down {
  background: #fce7f3;
  color: #be185d;
  border-color: #f9a8d4;
}

.hcp-home-status-split {
  display: grid;
  grid-template-columns: 42% 58%;
  gap: 14px;
  margin-bottom: 16px;
  align-items: stretch;
}

.hcp-dash-widget-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 14px;
  margin-bottom: 16px;
}

.hcp-col-3 { grid-column: span 3; }
.hcp-col-4 { grid-column: span 4; }
.hcp-col-5 { grid-column: span 5; }
.hcp-col-6 { grid-column: span 6; }
.hcp-col-7 { grid-column: span 7; }
.hcp-col-8 { grid-column: span 8; }
.hcp-col-12 { grid-column: span 12; }

.hcp-donut-wrap,
.hcp-gauge-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

/* ==========================================================================
   AUTOMATIC INLINE STYLE ADAPTERS FOR DARK MODE vs. LIGHT MODE
   ========================================================================== */

/* 1. When in DARK MODE (body.hcp-dark-body), adapt hardcoded light inline styles */
body.hcp-dark-body .v2-content [style*="background:#fff"]:not(.hcp-map-canvas):not(#v2-hcp-dispatch-map):not(#v2-hcp-job-mini-map):not(#v2-hcp-home-map),
body.hcp-dark-body .v2-content [style*="background: #fff"]:not(.hcp-map-canvas):not(#v2-hcp-dispatch-map):not(#v2-hcp-job-mini-map):not(#v2-hcp-home-map),
body.hcp-dark-body .v2-content [style*="background:#ffffff"],
body.hcp-dark-body .v2-content [style*="background: #ffffff"],
body.hcp-dark-body .v2-content [style*="background:#f8fafc"],
body.hcp-dark-body .v2-content [style*="background: #f8fafc"],
body.hcp-dark-body .v2-content [style*="background:#f1f5f9"],
body.hcp-dark-body .v2-content [style*="background: #f1f5f9"],
body.hcp-dark-body .modal [style*="background:#fff"],
body.hcp-dark-body .modal [style*="background:#f8fafc"],
body.hcp-dark-body .drawer [style*="background:#fff"],
body.hcp-dark-body .drawer [style*="background:#f8fafc"] {
  background: var(--panel2) !important;
  border-color: var(--line) !important;
  color: var(--text) !important;
}

body.hcp-dark-body .v2-content [style*="background:#eff6ff"],
body.hcp-dark-body .v2-content [style*="background: #eff6ff"],
body.hcp-dark-body .v2-content [style*="background:#f0f9ff"],
body.hcp-dark-body .v2-content [style*="background:#e0f2fe"] {
  background: rgba(14, 165, 233, 0.14) !important;
  border-color: rgba(56, 189, 248, 0.35) !important;
  color: #e0f2fe !important;
}

body.hcp-dark-body .v2-content [style*="background:#fef3c7"],
body.hcp-dark-body .v2-content [style*="background:#fffbeb"] {
  background: rgba(245, 158, 11, 0.14) !important;
  border-color: rgba(245, 158, 11, 0.4) !important;
  color: #fde68a !important;
}

body.hcp-dark-body .v2-content [style*="background:#dcfce7"],
body.hcp-dark-body .v2-content [style*="background:#f0fdf4"],
body.hcp-dark-body .v2-content [style*="background:#ecfdf5"],
body.hcp-dark-body .v2-content [style*="background: #ecfdf5"] {
  background: rgba(16, 185, 129, 0.15) !important;
  border-color: rgba(16, 185, 129, 0.4) !important;
  color: #6ee7b7 !important;
}

body.hcp-dark-body .v2-content [style*="background:#f5f3ff"],
body.hcp-dark-body .v2-content [style*="background: #f5f3ff"],
body.hcp-dark-body .v2-content [style*="background:#ede9fe"] {
  background: rgba(124, 58, 237, 0.15) !important;
  border-color: rgba(139, 92, 246, 0.42) !important;
  color: #ddd6fe !important;
}

body.hcp-dark-body .v2-content [style*="background:#fef2f2"] {
  background: rgba(239, 68, 68, 0.14) !important;
  border-color: rgba(239, 68, 68, 0.4) !important;
  color: #fca5a5 !important;
}

body.hcp-dark-body .v2-content [style*="color:#6d28d9"] {
  color: #c4b5fd !important;
}

body.hcp-dark-body .v2-content [style*="color:#047857"] {
  color: #34d399 !important;
}

body.hcp-dark-body .v2-content [style*="color:#b45309"] {
  color: #fbbf24 !important;
}

body.hcp-dark-body .v2-content [style*="color:#0f172a"],
body.hcp-dark-body .v2-content [style*="color: #0f172a"],
body.hcp-dark-body .v2-content [style*="color:#1e293b"],
body.hcp-dark-body .v2-content [style*="color: #1e293b"],
body.hcp-dark-body .v2-content [style*="color:#334155"],
body.hcp-dark-body .v2-content [style*="color: #334155"],
body.hcp-dark-body .modal [style*="color:#0f172a"],
body.hcp-dark-body .modal [style*="color:#1e293b"],
body.hcp-dark-body .drawer [style*="color:#0f172a"],
body.hcp-dark-body .drawer [style*="color:#1e293b"] {
  color: var(--text) !important;
}

body.hcp-dark-body .v2-content [style*="color:#475569"],
body.hcp-dark-body .v2-content [style*="color:#64748b"] {
  color: var(--mut) !important;
}

body.hcp-dark-body .v2-content [style*="color:#1e3a8a"],
body.hcp-dark-body .v2-content [style*="color:#0369a1"],
body.hcp-dark-body .v2-content [style*="color:#006aff"] {
  color: #38bdf8 !important;
}

body.hcp-dark-body .v2-content [style*="border:1px solid #e2e8f0"],
body.hcp-dark-body .v2-content [style*="border: 1px solid #e2e8f0"],
body.hcp-dark-body .v2-content [style*="border-bottom:1px solid #e2e8f0"],
body.hcp-dark-body .v2-content [style*="border-top:1px solid #e2e8f0"] {
  border-color: var(--line) !important;
}

/* 2. When in LIGHT MODE (body.hcp-light-body), adapt hardcoded dark inline styles */
body.hcp-light-body .v2-content [style*="background:rgba(0,0,0"]:not(.hcp-dispatch-initials):not(.hcp-dispatch-card *):not(.swimlane-visit *),
body.hcp-light-body .v2-content [style*="background: rgba(0, 0, 0"]:not(.hcp-dispatch-initials):not(.hcp-dispatch-card *):not(.swimlane-visit *),
body.hcp-light-body .v2-content [style*="background:rgba(15,23,42"]:not(.hcp-dispatch-card *):not(.swimlane-visit *),
body.hcp-light-body .v2-content [style*="background: rgba(15, 23, 42"]:not(.hcp-dispatch-card *):not(.swimlane-visit *),
body.hcp-light-body .v2-content [style*="background:rgba(255,255,255,0.0"],
body.hcp-light-body .v2-content [style*="background:#090d18"],
body.hcp-light-body .v2-content [style*="background:#0b0f19"],
body.hcp-light-body .v2-content [style*="background:#0f1525"],
body.hcp-light-body .v2-content [style*="background:#131b2e"],
body.hcp-light-body .v2-content [style*="background:#151d32"],
body.hcp-light-body .modal [style*="background:rgba(0,0,0"],
body.hcp-light-body .modal [style*="background:rgba(15,23,42"],
body.hcp-light-body .modal [style*="background:rgba(255,255,255,0.0"],
body.hcp-light-body .drawer [style*="background:rgba(0,0,0"],
body.hcp-light-body .drawer [style*="background:rgba(15,23,42"],
body.hcp-light-body .drawer [style*="background:rgba(255,255,255,0.0"] {
  background: #f8fafc !important;
  border-color: #e2e8f0 !important;
  color: #1e293b !important;
}

body.hcp-light-body .v2-content [style*="color:#fff"]:not(.b):not(.hcp-dispatch-card):not(.hcp-dispatch-card *):not(.swimlane-visit):not(.swimlane-visit *):not(.hcp-tech-avatar):not(.hcp-pin-circle):not(.hcp-red-badge):not(.hcp-step-circle),
body.hcp-light-body .v2-content [style*="color: #fff"]:not(.b):not(.hcp-dispatch-card):not(.hcp-dispatch-card *):not(.swimlane-visit):not(.swimlane-visit *):not(.hcp-tech-avatar):not(.hcp-pin-circle):not(.hcp-red-badge):not(.hcp-step-circle),
body.hcp-light-body .v2-content [style*="color:#f8fafc"],
body.hcp-light-body .v2-content [style*="color:#e2e8f0"],
body.hcp-light-body .v2-content [style*="color:#cbd5e1"],
body.hcp-light-body .modal [style*="color:#fff"]:not(.b),
body.hcp-light-body .modal [style*="color:#e2e8f0"],
body.hcp-light-body .drawer [style*="color:#fff"]:not(.b),
body.hcp-light-body .drawer [style*="color:#e2e8f0"] {
  color: #0f172a !important;
}

@media (max-width: 1200px) {
  .morning-buckets {
    grid-template-columns: repeat(3, 1fr);
  }
  .hcp-map-split {
    grid-template-columns: 64% 36%;
  }
}

@media (max-width: 1100px) {
  .hcp-home-pipe-grid,
  .hcp-mtd-cols {
    grid-template-columns: repeat(2, 1fr);
  }
  .hcp-home-status-split {
    grid-template-columns: 1fr;
  }
  .hcp-col-3,
  .hcp-col-4,
  .hcp-col-5,
  .hcp-col-6,
  .hcp-col-7,
  .hcp-col-8 {
    grid-column: span 12;
  }
}

@media (max-width: 1024px) {
  .hcp-layout,
  .hcp-map-split,
  .hcp-dash-grid {
    grid-template-columns: 1fr;
  }
  .hcp-line-item-grid {
    grid-template-columns: 1fr 70px 100px 90px 32px;
  }
}

/* MORE menu active underline when viewing quoter / pipeline / reporting / settings */
.hcp-more-summary.active {
  color: var(--acc2);
  border-bottom-color: var(--acc2);
  font-weight: 700;
}

body.hcp-light-body .hcp-more-summary.active {
  color: #006aff;
  border-bottom-color: #006aff;
}

/* ==========================================================================
   EXECUTIVE PREMIUM DESIGN SYSTEM POLISH (LINEAR / STRIPE / APPLE PRO GRADE)
   ========================================================================== */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Crisp tabular numerals for financial figures, metrics, phone numbers & tables */
.data-table td,
.data-table th,
.kpi-val,
.hcp-kpi-val,
.tag,
.badge,
#v2-avatar-pay-amount {
  font-variant-numeric: tabular-nums;
}

/* Tighter executive headings */
h1, h2, h3, .hcp-settings-title {
  letter-spacing: -0.02em;
}

/* Subtle top inner specular highlight + cleaner elevation on dark cards */
body.hcp-dark-body .card,
body.hcp-dark-body .hcp-card {
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  border-color: rgba(148, 163, 184, 0.14);
}

body.hcp-light-body .card,
body.hcp-light-body .hcp-card {
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05), 0 6px 20px rgba(15, 23, 42, 0.03);
  border-color: #e2e8f0;
}

/* Crisp SVG icon alignment inside buttons, nav links, badges, tabs & headings */
.b, .btn, .sub-tab, .tag, .badge, .hcp-settings-nav-item, .hcp-nav-link, .hcp-new-btn, .hcp-jarvis-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.hcp-settings-nav-item {
  display: flex;
  gap: 9px;
}

.hcp-menu-ico {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: rgba(148, 163, 184, 0.1);
  border: 1px solid var(--line);
  color: var(--acc2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

body.hcp-light-body .hcp-menu-ico {
  background: #f1f5f9;
  color: #0284c7;
}

/* Refined primary action & Jarvis AI pills in top nav */
.hcp-new-btn {
  padding: 0 12px;
  height: 34px;
  border-radius: 9px;
  font-weight: 700;
  letter-spacing: -0.01em;
  box-shadow: 0 2px 10px rgba(0, 106, 255, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.18);
  transition: transform 0.12s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.hcp-new-btn:hover {
  filter: brightness(1.06);
  box-shadow: 0 4px 14px rgba(0, 106, 255, 0.36);
}

.hcp-jarvis-pill {
  height: 34px;
  padding: 0 12px;
  border-radius: 9px;
  font-weight: 700;
  letter-spacing: -0.01em;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.92), rgba(14, 165, 233, 0.9)) !important;
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  color: #ffffff !important;
  box-shadow: 0 2px 12px rgba(79, 70, 229, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.22);
  transition: transform 0.12s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.hcp-jarvis-pill:hover {
  filter: brightness(1.08);
  box-shadow: 0 4px 16px rgba(79, 70, 229, 0.45);
}

/* Calmer, crisper button micro-transitions */
.b {
  border-radius: 8px;
  transition: background 0.14s ease, border-color 0.14s ease, transform 0.1s ease, box-shadow 0.14s ease;
}

.b:active {
  transform: scale(0.98);
}

.b.pri {
  box-shadow: 0 2px 8px rgba(79, 70, 229, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.14);
}

/* Refined table aesthetics */
.data-table th {
  font-size: 11px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 700;
}

.data-table tbody tr {
  transition: background 0.12s ease;
}

.data-table tbody tr:hover {
  background: rgba(148, 163, 184, 0.05);
}

/* Refined tag pills */
.tag {
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: 0.005em;
}

/* Subtle executive scrollbars */
::-webkit-scrollbar {
  width: 7px;
  height: 7px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.24);
  border-radius: 999px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(148, 163, 184, 0.4);
}

/* ==========================================================================
   INSTALLS WORKSPACE — SPACIOUS EXECUTIVE PROJECT CARDS (WIDE & 2-COL GRID)
   ========================================================================== */
.inst-shell {
  max-width: 1460px;
  margin: 0 auto;
  padding: 20px 26px 44px;
}

.inst-top-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.inst-top-title {
  margin: 0;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 10px;
}

.inst-top-sub {
  font-size: 13px;
  color: var(--mut);
  margin-top: 3px;
}

.inst-phase-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 22px;
}

.inst-phase-card {
  position: relative;
  padding: 16px 20px;
  border-radius: 15px;
  background: var(--panel);
  border: 1px solid var(--line);
  cursor: pointer;
  transition: transform 0.14s ease, border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
  display: flex;
  flex-direction: column;
  gap: 6px;
  overflow: hidden;
}

.inst-phase-card:hover {
  transform: translateY(-1px);
  border-color: rgba(56, 189, 248, 0.45);
}

.inst-phase-card.on {
  background: rgba(14, 165, 233, 0.12);
  border-color: var(--acc2);
  box-shadow: 0 8px 24px rgba(14, 165, 233, 0.14);
}

body.hcp-light-body .inst-phase-card.on {
  background: #eff6ff;
  border-color: #0284c7;
}

.inst-phase-card.on::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--acc2);
}

.inst-phase-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
}

.inst-phase-num {
  font-size: 28px;
  font-weight: 800;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}

.inst-phase-num.has-items {
  color: var(--acc2);
}

.inst-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.inst-search-wrap {
  position: relative;
  flex: 1;
  min-width: 240px;
  max-width: 420px;
}

.inst-search-wrap input {
  width: 100%;
  height: 38px;
  padding: 0 14px 0 36px;
  border-radius: 10px;
  background: var(--panel);
  border: 1px solid var(--line);
  color: var(--text);
  font-size: 13px;
}

.inst-search-wrap .inst-search-ico {
  position: absolute;
  left: 11px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--mut);
  pointer-events: none;
  display: inline-flex;
}

.inst-seg-toggle {
  display: inline-flex;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 3px;
  gap: 3px;
}

.inst-seg-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--mut);
  font: 600 12.5px 'Inter', sans-serif;
  height: 30px;
  padding: 0 12px;
  border-radius: 7px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background 0.14s ease, color 0.14s ease;
}

.inst-seg-btn.on {
  background: rgba(56, 189, 248, 0.16);
  color: var(--acc2);
}

body.hcp-light-body .inst-seg-btn.on {
  background: #e0f2fe;
  color: #0284c7;
}

.inst-list {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.inst-list.grid-mode {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  align-items: start;
}

.inst-card {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 24px 26px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.14s ease;
  overflow: hidden;
}

body.hcp-light-body .inst-card {
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.05), 0 10px 26px rgba(15, 23, 42, 0.04);
}

.inst-card:hover {
  border-color: rgba(148, 163, 184, 0.34);
}

.inst-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 16px;
  bottom: 16px;
  width: 4px;
  border-radius: 0 4px 4px 0;
  background: var(--acc2);
}

.inst-card.state-failed::before { background: var(--bad); }
.inst-card.state-closed::before { background: var(--ok); }

.inst-card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  flex-wrap: wrap;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 18px;
}

.inst-eyebrow-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.inst-job-num {
  font-size: 11.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--mut);
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--panel2);
  border: 1px solid var(--line);
}

.inst-client-name {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  line-height: 1.2;
}

.inst-client-addr {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--mut);
  margin-top: 5px;
}

.inst-price-col {
  text-align: right;
  flex-shrink: 0;
}

.inst-price-val {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--ok);
  line-height: 1.1;
}

.inst-rebate-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 6px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.3);
  color: var(--warn);
  font-size: 11.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.inst-meta-grid {
  display: grid;
  grid-template-columns: 1.45fr 1fr 0.95fr;
  gap: 12px;
  margin-bottom: 20px;
}

.inst-list.grid-mode .inst-meta-grid {
  grid-template-columns: 1fr 1fr;
}

.inst-list.grid-mode .inst-meta-tile:first-child {
  grid-column: 1 / -1;
}

.inst-meta-tile {
  padding: 13px 15px;
  border-radius: 12px;
  background: var(--panel2);
  border: 1px solid var(--line);
  min-width: 0;
}

.inst-meta-lbl {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--mut);
  margin-bottom: 5px;
  display: flex;
  align-items: center;
  gap: 5px;
}

.inst-meta-val {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.35;
}

.inst-meta-sub {
  font-size: 12px;
  color: var(--mut);
  margin-top: 3px;
}

.inst-progress-wrap {
  margin-bottom: 20px;
}

.inst-progress-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--mut);
  margin-bottom: 8px;
}

.inst-seg-bar {
  display: grid;
  grid-template-columns: repeat(14, 1fr);
  gap: 5px;
  margin-bottom: 12px;
}

.inst-seg-tick {
  height: 7px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.16);
}

.inst-seg-tick.done { background: var(--ok); }
.inst-seg-tick.failed { background: var(--bad); }

.inst-stepper {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.inst-list.grid-mode .inst-stepper {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.inst-step-pill {
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  background: var(--panel2);
  color: var(--mut);
  border: 1px solid var(--line);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.inst-step-pill.done {
  background: rgba(16, 185, 129, 0.13);
  border-color: rgba(16, 185, 129, 0.38);
  color: var(--ok);
}

.inst-step-pill.cur {
  background: rgba(14, 165, 233, 0.14);
  border-color: rgba(56, 189, 248, 0.55);
  color: var(--text);
}

.inst-next-box {
  padding: 16px 18px;
  border-radius: 14px;
  background: rgba(14, 165, 233, 0.07);
  border: 1px solid rgba(56, 189, 248, 0.24);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

body.hcp-light-body .inst-next-box {
  background: #f0f9ff;
  border-color: #bae6fd;
}

.inst-next-text {
  flex: 1;
  min-width: 240px;
}

.inst-next-kicker {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--acc2);
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
}

.inst-next-desc {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.45;
}

.inst-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.inst-actions .b {
  min-height: 36px;
  padding: 0 14px;
  font-size: 12.5px;
  font-weight: 700;
  border-radius: 9px;
}

.inst-details {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.inst-details > summary {
  list-style: none;
  cursor: pointer;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--mut);
  display: inline-flex;
  align-items: center;
  gap: 7px;
  user-select: none;
  transition: color 0.14s ease;
}

.inst-details > summary::-webkit-details-marker {
  display: none;
}

.inst-details > summary:hover {
  color: var(--text);
}

.inst-details > summary .inst-chev {
  transition: transform 0.16s ease;
  display: inline-flex;
}

.inst-details[open] > summary .inst-chev {
  transform: rotate(90deg);
}

.inst-details-body {
  margin-top: 14px;
  padding: 16px;
  border-radius: 12px;
  background: var(--panel2);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

@media (max-width: 1180px) {
  .inst-phase-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .inst-list.grid-mode {
    grid-template-columns: 1fr;
  }
  .inst-meta-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .inst-shell {
    padding: 14px 14px 36px;
  }
  .inst-card {
    padding: 18px 18px;
  }
  .inst-phase-grid,
  .inst-meta-grid,
  .inst-stepper {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   FINANCIAL DASHBOARD (DASH) — SPACIOUS EXECUTIVE CARDS & CHART CONTRAST
   ========================================================================== */
.dash-shell {
  max-width: 1460px;
  margin: 0 auto;
  padding: 20px 26px 48px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.dash-top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.dash-top-title {
  margin: 0;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 10px;
}

.dash-top-sub {
  font-size: 13px;
  color: var(--mut);
  margin-top: 3px;
}

.dash-controls-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 10px 14px;
  border-radius: 14px;
  background: var(--panel);
  border: 1px solid var(--line);
}

.dash-seg-tabs {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--panel2);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 3px;
}

.dash-seg-tab {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--mut);
  font: 600 12.5px 'Inter', sans-serif;
  height: 32px;
  padding: 0 13px;
  border-radius: 7px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  transition: background 0.14s ease, color 0.14s ease;
}

.dash-seg-tab:hover {
  color: var(--text);
}

.dash-seg-tab.on {
  background: rgba(56, 189, 248, 0.16);
  color: var(--acc2);
}

body.hcp-light-body .dash-seg-tab.on {
  background: #e0f2fe;
  color: #0284c7;
}

.dash-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.dash-kpi-card {
  position: relative;
  padding: 18px 20px;
  border-radius: 16px;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

body.hcp-light-body .dash-kpi-card {
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.05), 0 8px 20px rgba(15, 23, 42, 0.03);
}

.dash-kpi-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--acc2);
}

.dash-kpi-card.tone-warn::before { background: var(--warn); }
.dash-kpi-card.tone-acc::before { background: var(--acc); }
.dash-kpi-card.tone-ok::before { background: var(--ok); }

.dash-kpi-lbl {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--mut);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.dash-kpi-val {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}

.dash-kpi-val.c-warn { color: var(--warn); }
.dash-kpi-val.c-acc { color: #a78bfa; }
.dash-kpi-val.c-ok { color: var(--ok); }
body.hcp-light-body .dash-kpi-val.c-acc { color: #6d28d9; }

.dash-kpi-sub {
  font-size: 12px;
  color: var(--mut);
  font-variant-numeric: tabular-nums;
}

.dash-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 22px 24px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  display: flex;
  flex-direction: column;
  min-width: 0;
}

body.hcp-light-body .dash-card {
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.05), 0 10px 24px rgba(15, 23, 42, 0.03);
}

.dash-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding-bottom: 14px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.dash-card-title {
  font-size: 15.5px;
  font-weight: 800;
  letter-spacing: -0.015em;
  color: var(--text);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.dash-card-head .tag {
  white-space: nowrap;
  flex-shrink: 0;
}

.dash-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  align-items: stretch;
}

.dash-grid-4 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  align-items: stretch;
}

.dash-grid-2-1 {
  display: grid;
  grid-template-columns: 1.75fr 1fr;
  gap: 20px;
  align-items: stretch;
}

.dash-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.dash-row-item {
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--panel2);
  border: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: border-color 0.14s ease, transform 0.12s ease;
}

.dash-row-item:hover {
  border-color: rgba(56, 189, 248, 0.45);
  transform: translateY(-1px);
}

.dash-subtile {
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--panel2);
  border: 1px solid var(--line);
}

.dash-table {
  width: 100%;
  border-collapse: collapse;
}

.dash-table th {
  padding: 10px 12px;
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.055em;
  color: var(--mut);
  border-bottom: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
}

.dash-table td {
  padding: 13px 12px;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  vertical-align: middle;
}

.dash-table tbody tr {
  transition: background 0.12s ease;
}

.dash-table tbody tr:hover {
  background: rgba(148, 163, 184, 0.06);
}

.dash-table .nw {
  white-space: nowrap;
}

.dash-table .tag {
  white-space: nowrap;
}

.dash-svg-val {
  fill: var(--text);
  font-family: 'Inter', sans-serif;
  font-variant-numeric: tabular-nums;
}

.dash-svg-mut {
  fill: var(--mut);
  font-family: 'Inter', sans-serif;
}

.dash-svg-grid {
  stroke: var(--line);
}

.dash-tier-row {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.dash-tier-track {
  height: 7px;
  border-radius: 999px;
  background: var(--panel2);
  overflow: hidden;
  border: 1px solid var(--line);
}

.dash-builder-form {
  padding: 18px 20px;
  border-radius: 14px;
  background: var(--panel2);
  border: 1px solid var(--line);
  display: grid;
  grid-template-columns: 1.8fr 1fr 1fr 1fr auto;
  gap: 12px;
  align-items: end;
}

.dash-builder-form input,
.dash-builder-form select {
  width: 100%;
  height: 38px;
  padding: 0 12px;
  border-radius: 9px;
  background: var(--panel);
  border: 1px solid var(--line);
  color: var(--text);
  font-size: 13px;
}

@media (max-width: 1220px) {
  .dash-kpi-grid,
  .dash-grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .dash-grid-3,
  .dash-grid-2-1 {
    grid-template-columns: 1fr;
  }
  .dash-builder-form {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .dash-shell {
    padding: 14px 14px 36px;
  }
  .dash-kpi-grid,
  .dash-grid-4,
  .dash-grid-2,
  .dash-builder-form {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   EXECUTIVE CUSTOMERS DIRECTORY (.cust-* — SPACIOUS DOSSIER CARD SYSTEM)
   ========================================================================== */

.cust-shell {
  max-width: 1460px;
  margin: 0 auto;
  padding: 20px 26px 48px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.cust-top-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
}

.cust-top-title {
  margin: 0;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 10px;
}

.cust-top-sub {
  margin-top: 4px;
  font-size: 13.5px;
  color: var(--mut);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* 4 Executive Interactive KPI Filter Cards */
.cust-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.cust-kpi-card {
  position: relative;
  padding: 16px 20px;
  border-radius: 15px;
  background: var(--panel);
  border: 1px solid var(--line);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 5px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition: transform 0.14s ease, border-color 0.16s ease, box-shadow 0.16s ease;
  overflow: hidden;
  text-align: left;
}

.cust-kpi-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: transparent;
  transition: background 0.16s ease;
}

.cust-kpi-card:hover {
  transform: translateY(-2px);
  border-color: rgba(56, 189, 248, 0.42);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.cust-kpi-card.on {
  border-color: rgba(56, 189, 248, 0.62);
  box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.35), 0 10px 26px rgba(14, 165, 233, 0.14);
}

.cust-kpi-card.on::before { background: var(--acc2); }
.cust-kpi-card.tone-ok.on::before { background: var(--ok); }
.cust-kpi-card.tone-warn.on::before { background: var(--warn); }
.cust-kpi-card.tone-acc.on::before { background: var(--acc); }

body.hcp-light-body .cust-kpi-card {
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06), 0 6px 18px rgba(15, 23, 42, 0.04);
}

.cust-kpi-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.cust-kpi-num {
  font-size: 28px;
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.025em;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}

.cust-kpi-num.c-ok { color: var(--ok); }
.cust-kpi-num.c-warn { color: var(--warn); }
.cust-kpi-num.c-cyan { color: var(--acc2); }

.cust-kpi-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text);
  margin-top: 2px;
}

.cust-kpi-sub {
  font-size: 12px;
  color: var(--mut);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Toolbar Row (Live Search + Sort + Density Switcher) */
.cust-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.cust-search-wrap {
  position: relative;
  flex: 1;
  min-width: 280px;
  max-width: 520px;
}

.cust-search-wrap input {
  width: 100%;
  height: 38px;
  padding: 0 14px 0 38px;
  border-radius: 11px;
  background: var(--panel);
  border: 1px solid var(--line);
  color: var(--text);
  font-size: 13px;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.cust-search-wrap input:focus {
  outline: none;
  border-color: var(--acc2);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.16);
}

.cust-search-ico {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--mut);
  pointer-events: none;
  display: inline-flex;
  align-items: center;
}

.cust-controls-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.cust-sort-select {
  height: 38px;
  padding: 0 12px;
  border-radius: 10px;
  background: var(--panel);
  border: 1px solid var(--line);
  color: var(--text);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
}

.cust-seg-toggle {
  display: inline-flex;
  align-items: center;
  padding: 3px;
  border-radius: 11px;
  background: var(--panel);
  border: 1px solid var(--line);
  gap: 2px;
}

.cust-seg-btn {
  padding: 6px 12px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--mut);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background 0.14s ease, color 0.14s ease;
}

.cust-seg-btn.on {
  background: var(--acc);
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.28);
}

/* Spacious Customer Dossier Cards */
.cust-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.cust-list.grid-mode {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  align-items: stretch;
}

.cust-card {
  position: relative;
  padding: 22px 26px 20px 28px;
  border-radius: 18px;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.14s ease;
}

.cust-card:hover {
  border-color: rgba(56, 189, 248, 0.36);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

body.hcp-light-body .cust-card {
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.05), 0 10px 26px rgba(15, 23, 42, 0.04);
}

body.hcp-light-body .cust-card:hover {
  border-color: rgba(2, 132, 199, 0.38);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

/* 4px Inset Left Status Accent Bar */
.cust-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 16px;
  bottom: 16px;
  width: 4px;
  border-radius: 0 4px 4px 0;
  background: rgba(148, 163, 184, 0.4);
}

.cust-card.tone-member::before { background: var(--ok); }
.cust-card.tone-due::before { background: var(--warn); }
.cust-card.tone-commercial::before { background: var(--acc2); }

/* Zone 1: Card Header */
.cust-card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.cust-ident {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  min-width: 0;
  flex: 1;
}

.cust-avatar {
  width: 44px;
  height: 44px;
  border-radius: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 800;
  color: #ffffff;
  flex-shrink: 0;
  letter-spacing: -0.01em;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.22);
}

.cust-ident-body {
  min-width: 0;
  flex: 1;
}

.cust-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.cust-name-link {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
  cursor: pointer;
  line-height: 1.2;
  transition: color 0.14s ease;
}

.cust-name-link:hover {
  color: var(--acc2);
}

.cust-addr-line {
  margin-top: 5px;
  font-size: 13px;
  color: var(--mut);
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.cust-ltv-box {
  text-align: right;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}

.cust-ltv-val {
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--ok);
  line-height: 1.1;
}

.cust-ltv-lbl {
  font-size: 11px;
  font-weight: 600;
  color: var(--mut);
  white-space: nowrap;
}

/* Zone 2: Structured 3-Tile Metadata Grid */
.cust-meta-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.cust-list.grid-mode .cust-meta-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.cust-list.grid-mode .cust-meta-tile.tile-wide {
  grid-column: 1 / -1;
}

.cust-meta-tile {
  padding: 13px 15px;
  border-radius: 12px;
  background: var(--panel2);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
}

.cust-tile-lbl {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--mut);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 6px;
}

.cust-tile-val {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.35;
  font-variant-numeric: tabular-nums;
}

.cust-tile-sub {
  font-size: 12px;
  color: var(--mut);
  line-height: 1.4;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.cust-phone-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.cust-phone-num {
  font-size: 14.5px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: var(--text);
  white-space: nowrap;
}

.cust-quick-comms {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.cust-quick-comms .b {
  min-height: 28px;
  padding: 0 9px;
  font-size: 11.5px;
  border-radius: 8px;
}

/* Zone 3: Calm Notes & Action Footer */
.cust-footer {
  margin-top: auto;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--panel2);
  border: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.cust-note-preview {
  flex: 1;
  min-width: 220px;
  cursor: pointer;
}

.cust-note-kicker {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--mut);
  margin-bottom: 3px;
}

.cust-note-text {
  font-size: 13px;
  color: var(--text);
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.cust-footer-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  flex-wrap: wrap;
}

.cust-footer-actions .b {
  min-height: 36px;
  padding: 0 14px;
  font-size: 12.5px;
  font-weight: 700;
  border-radius: 9px;
}

/* Compact Table Mode (Zero Overflow, Clean Dark/Light Parity) */
.cust-table-card {
  border-radius: 18px;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  overflow: hidden;
}

body.hcp-light-body .cust-table-card {
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.05), 0 10px 26px rgba(15, 23, 42, 0.04);
}

.cust-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.cust-table th {
  text-align: left;
  padding: 13px 16px;
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--mut);
  background: var(--panel2);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.cust-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.cust-table tbody tr:last-child td {
  border-bottom: none;
}

.cust-table tbody tr:hover td {
  background: rgba(56, 189, 248, 0.05);
}

/* Vault Scope Footer */
.cust-vault-footer {
  padding: 14px 18px;
  border-radius: 14px;
  background: var(--panel);
  border: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 12.5px;
  color: var(--mut);
}

@media (max-width: 1200px) {
  .cust-kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .cust-list.grid-mode {
    grid-template-columns: 1fr;
  }
  .cust-meta-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .cust-shell {
    padding: 14px 14px 36px;
  }
  .cust-card {
    padding: 18px 18px 18px 20px;
  }
  .cust-kpi-grid,
  .cust-meta-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   WARM HUMAN EXECUTIVE SYSTEM — PROGRESSIVE DISCLOSURE, HOME, MONEY, PAYROLL & SCHEDULE
   ========================================================================== */

/* Unified Single-Chevron Progressive Disclosure Drawer (.ux-drawer) */
.ux-drawer {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.ux-drawer.compact {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

.ux-drawer > summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--mut);
  user-select: none;
  transition: color 0.14s ease;
}

.ux-drawer > summary::-webkit-details-marker {
  display: none;
}

.ux-drawer > summary:hover {
  color: var(--text);
}

.ux-drawer > summary .ux-chev {
  display: inline-flex;
  transition: transform 0.16s ease;
  color: var(--acc2);
}

.ux-drawer[open] > summary .ux-chev {
  transform: rotate(90deg);
}

.ux-drawer-body {
  margin-top: 10px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--panel2);
  border: 1px solid var(--line);
}

/* Shared Warm Workspace Shell */
.ux-shell {
  max-width: 1460px;
  margin: 0 auto;
  padding: 20px 26px 48px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.ux-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
}

.ux-title {
  margin: 0;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 10px;
}

.ux-sub {
  margin-top: 4px;
  font-size: 13.5px;
  color: var(--mut);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.ux-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.ux-kpi-card {
  position: relative;
  padding: 16px 20px;
  border-radius: 15px;
  background: var(--panel);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 6px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  overflow: hidden;
  transition: transform 0.14s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.ux-kpi-card.clickable {
  cursor: pointer;
}

.ux-kpi-card.clickable:hover {
  transform: translateY(-2px);
  border-color: rgba(56, 189, 248, 0.45);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.ux-kpi-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--acc2);
}

.ux-kpi-card.tone-ok::before { background: var(--ok); }
.ux-kpi-card.tone-warn::before { background: var(--warn); }
.ux-kpi-card.tone-acc::before { background: var(--acc); }
.ux-kpi-card.tone-bad::before { background: var(--bad); }

body.hcp-light-body .ux-kpi-card {
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06), 0 6px 18px rgba(15, 23, 42, 0.04);
}

.ux-kpi-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.ux-kpi-top .tag {
  white-space: nowrap;
  flex-shrink: 0;
}

.ux-kpi-lbl {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.055em;
  color: var(--mut);
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ux-kpi-val {
  font-size: 27px;
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.1;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.ux-kpi-val.c-ok { color: var(--ok); }
.ux-kpi-val.c-warn { color: var(--warn); }
.ux-kpi-val.c-cyan { color: var(--acc2); }
.ux-kpi-val.c-acc { color: #a5b4fc; }
body.hcp-light-body .ux-kpi-val.c-acc { color: #4f46e5; }

.ux-kpi-sub {
  font-size: 12px;
  color: var(--mut);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.ux-card {
  padding: 22px 24px;
  border-radius: 18px;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

body.hcp-light-body .ux-card {
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.05), 0 10px 26px rgba(15, 23, 42, 0.04);
}

.ux-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding-bottom: 14px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.ux-card-title {
  margin: 0;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.015em;
  color: var(--text);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.ux-seg-tabs {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px;
  border-radius: 11px;
  background: var(--panel);
  border: 1px solid var(--line);
}

.ux-seg-tab {
  padding: 7px 14px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--mut);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background 0.14s ease, color 0.14s ease;
  white-space: nowrap;
}

.ux-seg-tab:hover {
  color: var(--text);
}

.ux-seg-tab.on {
  background: var(--acc);
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.28);
}

/* HOME — Warm Atmospheric Welcome Banner */
.home-welcome {
  position: relative;
  padding: 24px 28px;
  border-radius: 20px;
  background:
    radial-gradient(ellipse 60% 110% at 6% 10%, rgba(245, 158, 11, 0.14), transparent 65%),
    radial-gradient(ellipse 55% 110% at 92% 90%, rgba(99, 102, 241, 0.14), transparent 65%),
    var(--panel);
  border: 1px solid var(--line);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

body.hcp-light-body .home-welcome {
  background:
    radial-gradient(ellipse 55% 110% at 5% 10%, rgba(251, 191, 36, 0.16), transparent 65%),
    radial-gradient(ellipse 55% 110% at 92% 90%, rgba(56, 189, 248, 0.14), transparent 65%),
    #ffffff;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.05), 0 12px 28px rgba(15, 23, 42, 0.04);
}

.home-welcome-title {
  margin: 0;
  font-size: 25px;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text);
}

.home-welcome-sub {
  margin-top: 6px;
  font-size: 13.5px;
  color: var(--mut);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.home-welcome-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.home-welcome-actions .b {
  min-height: 38px;
  padding: 0 16px;
  border-radius: 11px;
  font-size: 13px;
  font-weight: 700;
}

/* Home Compact MTD Pulse Ribbon */
.home-mtd-bar {
  padding: 14px 20px;
  border-radius: 16px;
  background: var(--panel);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}

.home-mtd-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  flex: 1;
  min-width: 560px;
}

.home-mtd-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-right: 16px;
  border-right: 1px solid var(--line);
}

.home-mtd-item:last-child {
  border-right: none;
  padding-right: 0;
}

.home-mtd-val {
  font-size: 19px;
  font-weight: 800;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  display: flex;
  align-items: center;
  gap: 7px;
}

/* Home Tech Card & Priority Row */
.home-tech-item {
  padding: 12px 14px;
  border-radius: 13px;
  background: var(--panel2);
  border: 1px solid var(--line);
  transition: border-color 0.14s ease;
}

.home-tech-item:hover {
  border-color: rgba(56, 189, 248, 0.35);
}

.home-tech-visit {
  margin-top: 8px;
  padding: 8px 10px;
  border-radius: 9px;
  background: var(--panel);
  border: 1px solid var(--line);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 12px;
  transition: border-color 0.14s ease;
}

.home-tech-visit:hover {
  border-color: var(--acc2);
}

.home-queue-row {
  padding: 12px 15px;
  border-radius: 13px;
  background: var(--panel2);
  border: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  transition: border-color 0.14s ease;
}

.home-queue-row:hover {
  border-color: rgba(56, 189, 248, 0.36);
}

.home-bucket-strip {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.home-bucket-pill {
  padding: 5px 11px;
  border-radius: 999px;
  background: var(--panel2);
  border: 1px solid var(--line);
  color: var(--mut);
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  transition: all 0.14s ease;
}

.home-bucket-pill:hover {
  border-color: rgba(56, 189, 248, 0.4);
  color: var(--text);
}

.home-bucket-pill.on {
  background: rgba(56, 189, 248, 0.14);
  border-color: var(--acc2);
  color: var(--text);
}

/* MY MONEY — Dossier Cards & Rebate Stepper */
.money-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  align-items: start;
}

.money-item-card {
  position: relative;
  padding: 18px 20px 18px 22px;
  border-radius: 15px;
  background: var(--panel2);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: border-color 0.14s ease;
}

.money-item-card:hover {
  border-color: rgba(56, 189, 248, 0.38);
}

.money-item-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 14px;
  bottom: 14px;
  width: 3.5px;
  border-radius: 0 3px 3px 0;
  background: var(--acc2);
}

.money-item-card.tone-ok::before { background: var(--ok); }
.money-item-card.tone-warn::before { background: var(--warn); }
.money-item-card.tone-bad::before { background: var(--bad); }

.money-rebate-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.money-step-box {
  padding: 10px 12px;
  border-radius: 11px;
  background: var(--panel);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.money-step-box.done {
  border-color: rgba(16, 185, 129, 0.35);
  background: rgba(16, 185, 129, 0.06);
}

.money-step-box.active {
  border-color: rgba(245, 158, 11, 0.45);
  background: rgba(245, 158, 11, 0.06);
}

/* PAYROLL — Balanced Crew Lead Cards & Clean Tables */
.pay-crew-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}

.pay-crew-card {
  position: relative;
  padding: 18px 20px;
  border-radius: 16px;
  background: var(--panel2);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pay-crew-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 14px;
  bottom: 14px;
  width: 4px;
  border-radius: 0 4px 4px 0;
  background: var(--crew-accent, var(--acc2));
}

.pay-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.pay-table th {
  text-align: left;
  padding: 11px 14px;
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--mut);
  background: var(--panel2);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.pay-table td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  vertical-align: middle;
  font-variant-numeric: tabular-nums;
}

.pay-table tbody tr:last-child td {
  border-bottom: none;
}

.pay-table tbody tr:hover td {
  background: rgba(56, 189, 248, 0.04);
}

/* SCHEDULE — Theme-Aware Executive Dispatch Board (Zero Horizontal Clipping) */
.sched-header-shell {
  background: var(--panel);
  border-bottom: 1px solid var(--line);
}

.sched-bar-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 11px 22px;
}

.sched-bar-row.sub-row {
  padding: 9px 22px;
  background: var(--panel2);
  border-top: 1px solid var(--line);
}

.sched-grid-wrap {
  padding: 14px 20px 36px;
  background: var(--bg);
}

.sched-table-card {
  border-radius: 16px;
  background: var(--panel);
  border: 1px solid var(--line);
  overflow: hidden;
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.18);
}

body.hcp-light-body .sched-table-card {
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
}

.sched-swim-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  background: var(--panel);
}

.sched-swim-table th {
  padding: 11px 10px;
  font-size: 11px;
  font-weight: 800;
  color: var(--text);
  background: var(--panel2);
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sched-swim-table th:last-child,
.sched-swim-table td:last-child {
  border-right: none;
}

.sched-swim-table td {
  padding: 8px;
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  vertical-align: top;
  background: var(--panel);
}

.sched-swim-table tbody tr:last-child td {
  border-bottom: none;
}

.sched-emp-cell {
  width: 148px;
  text-align: center;
  padding: 12px 8px !important;
  background: var(--panel2) !important;
}

.sched-unsched-row td {
  background: rgba(245, 158, 11, 0.06) !important;
}

.sched-unsched-pill {
  padding: 6px 11px;
  border-radius: 10px;
  background: rgba(244, 63, 94, 0.13);
  border: 1px solid rgba(244, 63, 94, 0.38);
  color: var(--text);
  font-size: 12px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: border-color 0.14s ease, background 0.14s ease;
}

.sched-unsched-pill:hover {
  background: rgba(244, 63, 94, 0.22);
  border-color: var(--bad);
}

.sched-open-slot {
  width: 100%;
  min-height: 48px;
  border-radius: 9px;
  border: 1px dashed rgba(148, 163, 184, 0.22);
  background: transparent;
  color: var(--mut);
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  opacity: 0.62;
  transition: opacity 0.14s ease, border-color 0.14s ease, background 0.14s ease, color 0.14s ease;
}

.sched-open-slot:hover {
  opacity: 1;
  border-color: var(--acc2);
  background: rgba(56, 189, 248, 0.08);
  color: var(--text);
}

.sched-pickup-banner {
  margin-bottom: 12px;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(14, 165, 233, 0.09);
  border: 1px solid rgba(56, 189, 248, 0.3);
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

/* INBOX — Calm Call List Cards */
.inbox-call-item {
  padding: 13px 15px;
  border-radius: 13px;
  background: var(--panel2);
  border: 1px solid var(--line);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: border-color 0.14s ease, background 0.14s ease;
}

.inbox-call-item:hover {
  border-color: rgba(56, 189, 248, 0.38);
}

.inbox-call-item.on {
  background: rgba(56, 189, 248, 0.11);
  border-color: rgba(56, 189, 248, 0.55);
}

@media (max-width: 1200px) {
  .ux-kpi-grid,
  .home-mtd-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    min-width: 0;
  }
  .money-grid-2,
  .pay-crew-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .ux-shell {
    padding: 14px 14px 36px;
  }
  .ux-kpi-grid,
  .money-rebate-steps,
  .home-mtd-metrics {
    grid-template-columns: 1fr;
  }
}

/* ==================== HIGH-CONTRAST SERVICE REPAIR QUOTER TILES (DARK + LIGHT PARITY) ==================== */
.sr-tile {
  appearance: none;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 4px;
  padding: 10px 11px;
  border-radius: 12px;
  border: 1.5px solid var(--line);
  background: var(--panel2);
  color: var(--text);
  text-align: left;
  cursor: pointer;
  width: 100%;
  height: auto;
  transition: border-color 0.14s ease, background 0.14s ease, box-shadow 0.14s ease, transform 0.1s ease;
}

.sr-tile:hover {
  border-color: rgba(148, 163, 184, 0.45);
}

.sr-tile-title {
  font-size: 13px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.25;
}

.sr-tile-sub {
  font-size: 11px;
  font-weight: 700;
  color: var(--text);
  opacity: 0.88;
  line-height: 1.3;
}

.sr-tile-ex {
  font-size: 10.5px;
  color: var(--mut);
  line-height: 1.3;
  white-space: normal;
}

.sr-tile-price {
  font-size: 13px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  color: #34d399;
  padding: 2px 7px;
  border-radius: 99px;
  background: rgba(16, 185, 129, 0.14);
  border: 1px solid rgba(16, 185, 129, 0.35);
  white-space: nowrap;
}

body.hcp-light-body .sr-tile-price {
  color: #047857;
  background: rgba(16, 185, 129, 0.14);
  border-color: rgba(5, 150, 105, 0.32);
}

.sr-tile.on-cat {
  background: rgba(99, 102, 241, 0.16);
  border: 2px solid #818cf8;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.18);
}

body.hcp-light-body .sr-tile.on-cat {
  background: rgba(79, 70, 229, 0.1);
  border-color: #4f46e5;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.14);
}

.sr-tile.on-tier {
  background: rgba(16, 185, 129, 0.15);
  border: 2px solid #10b981;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.22);
}

body.hcp-light-body .sr-tile.on-tier {
  background: rgba(16, 185, 129, 0.12);
  border-color: #059669;
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.16);
}

.sr-tile.on-tier .sr-tile-price {
  background: #10b981;
  border-color: #10b981;
  color: #022c22;
}

body.hcp-light-body .sr-tile.on-tier .sr-tile-price {
  background: #047857;
  border-color: #047857;
  color: #ffffff;
}

.sr-tile.on-diff {
  background: rgba(14, 165, 233, 0.16);
  border: 2px solid #38bdf8;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.2);
}

body.hcp-light-body .sr-tile.on-diff {
  background: rgba(2, 132, 199, 0.1);
  border-color: #0284c7;
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.14);
}

.sr-chip-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  border-radius: 99px;
  border: 1px solid var(--line);
  background: var(--panel2);
  color: var(--text);
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  transition: border-color 0.14s ease, background 0.14s ease;
}

.sr-chip-btn:hover {
  border-color: rgba(56, 189, 248, 0.5);
}

.sr-chip-btn.on {
  background: rgba(14, 165, 233, 0.18);
  border-color: #38bdf8;
  color: var(--text);
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.18);
}

.sr-chip-badge {
  font-size: 10px;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 99px;
  background: rgba(99, 102, 241, 0.2);
  color: #a5b4fc;
  font-variant-numeric: tabular-nums;
}

body.hcp-light-body .sr-chip-badge {
  background: rgba(79, 70, 229, 0.12);
  color: #4338ca;
}
