/* salesux2 (Ø-404): canonical stylesheet for Call-list + Projekter + Projektagent.
   Load AFTER styles.css. Core selectors live here once — no extra patch layers. */

:root {
  --sales-gap-xs: 4px;
  --sales-gap-sm: 8px;
  --sales-gap-md: 12px;
  --sales-gap-lg: 16px;
  --sales-space-1: var(--sales-gap-xs);
  --sales-space-2: var(--sales-gap-sm);
  --sales-space-3: var(--sales-gap-md);
  --sales-space-4: var(--sales-gap-lg);
  --sales-space-5: 24px;
  --sales-control-h: 36px;
  --sales-ctrl-h: var(--sales-control-h);
  --sales-row-h: 46px;
  --sales-card-w: 280px;
  --sales-card-w-min: 280px;
  --sales-card-w-max: 280px;
  --sales-card-h: 240px;
  --sales-card-radius: 8px;
  --sales-radius: var(--sales-card-radius);
  --sales-inspector-w: 480px;
  --sales-border: rgba(33,58,75,.14);
  --sales-border-strong: rgba(33,58,75,.28);
  --sales-muted: #6b7c86;
  --sales-surface: #fff;
  --sales-surface-2: #f4f7f9;
  --sales-hover: rgba(33,58,75,.06);
  --sales-selected: rgba(33,58,75,.1);
  --sales-title: 14.5px;
  --sales-meta: 12.5px;
  --sales-status: 11.5px;
  --sales-page: 21px;
  --sales-section: 15px;
}

    #view-prospects .table-wrap { overflow: auto; max-height: calc(100vh - 220px); }
    #view-prospects .calllist-table { min-width: 760px; }
    #view-prospects .table-wrap.calllist-compact .calllist-table th,
    #view-prospects .table-wrap.calllist-compact .calllist-table td { padding: 8px 10px; }
    #view-prospects .calllist-table thead th {
      position: sticky; top: 0; z-index: 5; background: var(--surface, #fff);
      box-shadow: 0 1px 0 var(--border);
    }
    #view-prospects .calllist-table th:nth-child(1),
    #view-prospects .calllist-table td:nth-child(1) {
      position: sticky; left: 0; z-index: 3; background: var(--surface, #fff);
    }
    #view-prospects .calllist-table th:nth-child(2),
    #view-prospects .calllist-table td:nth-child(2) {
      position: sticky; left: 58px; z-index: 3; background: var(--surface, #fff);
    }
    #view-prospects .calllist-table thead th:nth-child(1),
    #view-prospects .calllist-table thead th:nth-child(2) { z-index: 6; }
    #view-prospects .call-firm { gap: 3px; }
    #view-prospects .call-firm-name { font-size: 14px; line-height: 1.25; }
    #view-prospects .call-firm-note { font-size: 11.5px; line-height: 1.3; max-width: 36ch; }
    #view-prospects .call-manual { font-size: 10.5px; }
    #view-prospects .stage-cell { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
    #view-prospects .call-next { display: flex; flex-direction: column; gap: 1px; line-height: 1.25; }
    #view-prospects .call-next-type { font-weight: 800; color: var(--brand-navy, #213a4b); }
    #view-prospects .call-next-when { font-size: 12px; font-weight: 700; }
    #view-prospects .call-next.is-overdue .call-next-when { color: #b45309; }
    #view-prospects .agreed-pill {
      display: inline-flex; align-self: flex-start; font-size: 10px; font-weight: 800;
      padding: 1px 6px; border-radius: 999px; background: rgba(78,156,134,.14);
      border: 1px solid rgba(78,156,134,.4); color: #2f6d5c;
    }
    #view-prospects .call-act { max-width: 168px; }
    #view-prospects .call-density { display: inline-flex; gap: 4px; align-items: center; margin-left: 8px; }
    .project-subnav { display: flex; gap: 8px; margin: 0 0 8px; }
    #view-prospects > .view-head { margin-bottom: 8px; }
    .project-detail-head { display: flex; flex-direction: column; align-items: stretch; gap: 4px; margin: 0 0 10px; }
    .pj-back { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; margin: 0; padding: 2px 0; border: 0; background: transparent; color: var(--brand-navy, #213a4b); font-weight: 700; font-size: 13px; cursor: pointer; min-height: 28px; }
    .pj-back .tic { width: 16px; height: 16px; }
    .pj-detail-title-row { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 8px 12px; }
    .pj-detail-title-row > div:first-child { min-width: 0; flex: 1 1 16rem; }
    .pj-detail-title-row h2 { margin: 0; overflow-wrap: anywhere; }
    #pjDetailMeta { margin-top: 2px; line-height: 1.4; overflow-wrap: anywhere; }
    .pj-detail-acts { display: flex; flex-wrap: wrap; gap: 8px; }
    .project-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin: 0 0 14px; }
    .project-kpi { background: var(--sales-surface); border: 1px solid var(--sales-border); border-radius: var(--sales-card-radius); padding: 10px 12px; }
    .project-kpi b { display: inline; font-size: 18px; }
    .project-kpi span { font-size: 12px; color: var(--sales-muted); }
    .project-card.is-focus { border-color: #c9a227; }
    .pj-card-head { display: block; margin: 0 0 8px; min-width: 0; max-width: 100%; }
    .pj-card-head h3 { margin: 0; font-size: 16px; min-width: 0; max-width: 100%; line-height: 1.3; padding-right: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .pj-card-check { position: absolute; top: 10px; right: 10px; margin: 0; z-index: 2; opacity: .42; }
    .project-card:hover .pj-card-check, .project-card.is-selected .pj-card-check { opacity: 1; }
    .pj-card-check input { width: 16px; height: 16px; }
    .project-card.is-selected { outline: 2px solid var(--brand-navy, #213a4b); }
    .project-card .project-meta { font-size: 12px; color: var(--muted, #667); margin: 0 0 8px; }
    .pj-card-fact { display: block; margin: 0 0 3px; font-size: 13px; line-height: 1.35; }
    .pj-card-fact-lbl { display: none; }
    .pj-card-fact-val { font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .pj-card-intel { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 10px; justify-content: flex-start; }
    .pj-card-acts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; justify-content: flex-start; align-items: center; }
    .pj-run-ai-wrap { display: inline-flex; gap: 4px; align-items: center; }
    .pj-run-ai-more { font-weight: 600; opacity: .82; padding: 4px 8px; }
    .project-card .pj-card-archive { display: block; margin: 8px 0 0; padding: 2px 0; border: 0; background: transparent; font-size: 12px; font-weight: 600; opacity: .45; color: var(--muted, #667); }
    .project-card .pj-card-archive:hover { opacity: 1; }
    .pj-ai-card.is-busy { opacity: .55; pointer-events: none; }
    .pj-ai-card.is-treated { opacity: .88; }
    .pj-ai-card.is-treated .modal-actions { display: none; }
    .project-canvas-wrap { position: relative; height: min(70vh, 640px); border: 1px solid var(--border, #dbe3ea); border-radius: 12px; overflow: hidden; background: #f6f8fa; touch-action: none; }
    .project-canvas-wrap:fullscreen, .project-canvas-wrap:-webkit-full-screen { width: 100%; height: 100%; border-radius: 0; background: #eef2f6; }
    .pj-fs-exit { display: none; position: absolute; top: 10px; right: 12px; z-index: 12; width: 36px; height: 36px; border: 0; border-radius: 999px; background: #fff; color: #213a4b; box-shadow: 0 2px 8px rgba(33,58,75,.16); cursor: pointer; align-items: center; justify-content: center; padding: 0; }
    .project-canvas-wrap.is-fs .pj-fs-exit { display: inline-flex; }
    .project-canvas-wrap.is-fs.has-panel .pj-fs-exit { right: auto; left: 12px; }
    .pj-panel-head { position: sticky; top: 0; z-index: 6; display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; margin: -14px -14px 12px; padding: 12px 14px 10px; background: #fff; border-bottom: 1px solid #eef2f6; }
    .pj-panel-head h3 { margin: 0; flex: 1; padding-right: 8px; }
    .pj-panel-head-acts { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
    .pj-panel-x { width: 32px; height: 32px; border: 0; border-radius: 8px; background: #eef2f6; color: #213a4b; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; padding: 0; }
    .pj-ctx { position: absolute; z-index: 80; min-width: 228px; max-width: 280px; background: #fff; border: 1px solid #dbe3ea; border-radius: 10px; box-shadow: 0 10px 28px rgba(33,58,75,.18); padding: 6px 0; }
    .pj-ctx.hidden { display: none; }
    .pj-ctx button { display: block; width: 100%; text-align: left; border: 0; background: transparent; padding: 7px 14px; font-size: 13px; color: #213a4b; cursor: pointer; }
    .pj-ctx button:hover, .pj-ctx button:focus { background: #eef2f6; }
    .pj-ctx button.is-danger { color: #9a3412; }
    .pj-ctx .pj-ctx-sec { display: block; font-size: 10px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: #719898; padding: 8px 14px 4px; }
    .pj-ctx .pj-ctx-split { height: 1px; background: #eef2f6; margin: 4px 0; }
    .project-canvas-world { position: absolute; left: 0; top: 0; transform-origin: 0 0; }
    .project-edges { position: absolute; inset: 0; width: 4000px; height: 3000px; pointer-events: none; overflow: visible; z-index: 0; }
    .project-edges path, .project-edges text, .project-edges rect, .project-edges g { pointer-events: stroke; cursor: pointer; }
    .project-edges text, .project-edges .pj-edge-lab { pointer-events: auto; }
    .project-edges .pj-edge-draw.is-hot, .project-edges .pj-edge-draw.is-selected { stroke-width: 2.8px; opacity: 1; }
    .project-edges .pj-edge-draw.is-dimmed { opacity: .25; }
    .project-edges .pj-edge-lab.is-hot rect, .project-edges .pj-edge-lab.is-selected rect { stroke: #213a4b; }
    .project-edges .pj-edge-lab.is-dimmed { opacity: .25; }
    .project-edges .pj-edge-ep { cursor: grab; pointer-events: all; }
    .pj-edge-tools { position: absolute; z-index: 18; display: none; gap: 4px; background: #fff; border: 1px solid #dbe3ea; border-radius: 8px; padding: 3px; box-shadow: 0 4px 12px rgba(33,58,75,.14); }
    .pj-edge-tools.is-on { display: flex; }
    .pj-edge-tools button { width: 28px; height: 28px; border: 0; border-radius: 6px; background: #eef2f6; color: #213a4b; cursor: pointer; padding: 0; display: inline-flex; align-items: center; justify-content: center; }
    .project-edges #pjPreviewEdge { pointer-events: none; stroke: #213a4b; stroke-width: 1.8; stroke-dasharray: 5 5; fill: none; opacity: .85; }
    .pj-link-banner { position: absolute; left: 12px; top: 10px; z-index: 5; background: #fff; border: 1px solid #dbe3ea; border-radius: 999px; padding: 6px 12px; font-size: 12px; box-shadow: 0 4px 10px rgba(33,58,75,.08); pointer-events: none; }
    .project-node-connector { position: absolute; width: 14px; height: 14px; border-radius: 50%; background: #fff; border: 2px solid #213a4b; opacity: 0; pointer-events: none; cursor: crosshair; z-index: 6; padding: 0; box-sizing: border-box; }
    .project-node:hover .project-node-connector, .project-node.is-focus .project-node-connector, .project-node.is-linking .project-node-connector, .project-canvas-wrap.is-linking .project-node-connector { opacity: .9; pointer-events: auto; }
    .project-node-connector.is-right { right: -7px; top: 50%; margin-top: -7px; }
    .project-node-connector.is-left { left: -7px; top: 50%; margin-top: -7px; }
    .project-node.is-linking { box-shadow: 0 0 0 2px #213a4b; z-index: 4; }
    .project-node.is-link-target { box-shadow: 0 0 0 2px #5d8a6a; z-index: 4; }
    .project-node.is-link-target .pj-link-hint { display: inline-block; }
    .pj-link-hint { display: none; font-size: 9px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: #5d8a6a; margin-top: 6px; }
    .pj-linking-badge { display: inline-block; font-size: 9px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: #213a4b; background: #eef2f6; border-radius: 999px; padding: 1px 7px; margin-top: 6px; }
    .pj-edge-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
    .project-node { position: absolute; box-sizing: border-box; width: 220px; min-height: 88px; background: #fffdf6; border: 1px solid #e2d6b8; border-radius: 8px; padding: 8px 10px; box-shadow: 1px 2px 0 rgba(33,58,75,.06), 0 4px 10px rgba(33,58,75,.08); cursor: grab; }
    .project-node.is-project { border-width: 2px; border-color: var(--brand-navy, #213a4b); background: #f4f7f8; width: 248px; min-height: 104px; }
    .project-node.is-ai-dim { opacity: .62; }
    .pj-ai-dot { position: absolute; top: 6px; right: 28px; width: 8px; height: 8px; border-radius: 50%; background: #5d8a6a; z-index: 5; }
    .pj-ai-mini { position: absolute; top: 4px; right: 24px; font-size: 9px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; background: #eef6f0; color: #3d6b4f; border-radius: 999px; padding: 1px 6px; z-index: 5; }
    .pj-ai-mini.is-change { background: #f8efe3; color: #8a5a2b; }
    .pj-ai-status { margin-top: 4px; font-size: 12px; }
    .pj-ai-status button { border: 0; background: none; color: inherit; font: inherit; cursor: pointer; padding: 0; text-decoration: underline; }
    .pj-ai-panel { margin: 8px 0 12px; padding: 12px 14px; border: 1px solid var(--border, #dbe3ea); border-radius: 10px; background: #fff; }
    .pj-ai-panel.hidden { display: none; }
    .pj-ai-pills { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
    .pj-ai-card { border: 1px solid #e5e7eb; border-radius: 10px; padding: 12px; margin: 8px 0; background: #fbfcfd; }
    .pj-ai-card h4 { margin: 0 0 6px; font-size: 14px; }
    .pj-ai-vs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 8px 0; }
    .pj-ai-vs div { background: #fff; border: 1px solid #eef2f6; border-radius: 8px; padding: 8px; }
    .pj-ai-vs .lbl { font-size: 10px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: #719898; }
    .pj-src-list { list-style: none; margin: 8px 0 0; padding: 0; }
    .pj-src-list li { margin: 0 0 8px; padding: 8px; background: #fff; border: 1px solid #eef2f6; border-radius: 8px; }
    .pj-ai-run { font-size: 12px; margin: 6px 0; }
    .pj-intel-flags { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 6px; }
    .pj-flag { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 700; transform-origin: 20% 90%; }
    .pj-flag svg { width: 16px; height: 16px; }
    .pj-flag-green { color: var(--green, #4e9c86); }
    .pj-flag-yellow { color: var(--amber, #d8901f); }
    .pj-flag b { font-size: 11px; }
    .pj-spark { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: #719898; }
    .pj-spark svg { width: 14px; height: 14px; }
    .pj-intel-box { margin: 8px 0 12px; padding: 12px 14px; border: 1px solid var(--border, #dbe3ea); border-radius: 10px; background: #fff; }
    .pj-intel-box.hidden { display: none; }
    .pj-intel-box h3 { margin: 0 0 8px; font-size: 15px; }
    .pj-card-intel { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 10px; justify-content: flex-start; }
    .pj-card-acts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; justify-content: flex-start; align-items: center; }
    .pj-run-ai-wrap { display: inline-flex; gap: 4px; align-items: center; }
    .pj-ai-backlog { font-size: 13px; color: #719898; margin: 0 0 8px; }
    .pj-select-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 0 0 10px; padding: 8px 10px; border: 1px solid var(--border, #dbe3ea); border-radius: 8px; background: #fff; }
    @keyframes pjFlagWave {
      0% { transform: rotate(0deg); }
      8% { transform: rotate(-8deg); }
      16% { transform: rotate(6deg); }
      24% { transform: rotate(-3deg); }
      33% { transform: rotate(0deg); }
      100% { transform: rotate(0deg); }
    }
    .pj-flag.is-wave { animation: pjFlagWave 3s ease-in-out infinite; }
    @media (prefers-reduced-motion: reduce) {
      .pj-flag.is-wave { animation: none; }
    }
    .pj-person-head { display: flex; align-items: flex-start; gap: 8px; min-width: 0; }
    .pj-person-avatar { width: 32px; height: 32px; flex-shrink: 0; color: #213a4b; pointer-events: none; display: inline-flex; align-items: center; justify-content: center; }
    .pj-person-avatar svg { width: 32px; height: 32px; pointer-events: none; display: block; }
    .pj-person-copy { min-width: 0; flex: 1; }
    .pj-person-copy strong { overflow-wrap: anywhere; word-break: break-word; }
    .pj-person-copy small { overflow-wrap: anywhere; word-break: break-word; }
    .pj-person-copy .pj-person-firm { color: #8899a6; }
    .pj-kicker-ic { display: inline-flex; width: 12px; height: 12px; margin-right: 4px; vertical-align: -2px; pointer-events: none; }
    .pj-kicker-ic svg { width: 12px; height: 12px; pointer-events: none; display: block; }
    .pj-rel-badge { display: inline-block; font-size: 9px; font-weight: 700; letter-spacing: .03em; color: #719898; margin-top: 4px; }
    .pj-panel-person-title { display: flex; align-items: center; gap: 8px; }
    .pj-panel-title-ic { width: 22px; height: 22px; flex-shrink: 0; color: #213a4b; pointer-events: none; display: inline-flex; }
    .pj-panel-title-ic svg { width: 22px; height: 22px; pointer-events: none; display: block; }
    .project-node.is-unknown { border-style: dashed; background: #f7f7f4; }
    .project-node.is-actor { border-style: dashed; background: #fffdf6; }
    .project-node.is-note { background: #fff6c8; border-color: #e6d48a; }
    .project-node.is-opportunity { border-color: #5d8a6a; background: #f3faf5; }
    .project-node.is-task { border-color: #8a7a5d; background: #fbf6ee; }
    .project-node.is-group { z-index: 0; background: rgba(33,58,75,.06); border: 1px dashed #9aafbd; min-height: 100px; width: 420px; box-shadow: none; border-radius: 14px; padding: 12px; }
    .project-node.is-drop-target { box-shadow: 0 0 0 2px #5d8a6a; background: rgba(93,138,106,.12); }
    .project-node.is-rel-end { box-shadow: 0 0 0 2px #213a4b; }
    .project-node.is-group-hidden { display: none; }
    .project-node.is-group.is-collapsed { min-height: 56px; height: 56px !important; }
    .pj-group-count { font-size: 11px; font-weight: 700; color: #719898; }
    .pj-node-footer { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; align-items: center; }
    .project-node .pj-node-footer .pj-status,
    .project-node .pj-node-footer .pj-scope { margin-top: 0; }
    .pj-card-check { position: absolute; top: 10px; right: 10px; margin: 0; z-index: 2; opacity: .42; padding: 8px; }
    .pj-built-in { font-size: 12px; margin-top: 6px; color: #2e8b57; font-weight: 650; }
    .pj-drop-hint { display: none; font-size: 9px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: #5d8a6a; margin-top: 6px; }
    .project-node.is-drop-target .pj-drop-hint { display: inline-block; }
    .project-node-edit, .project-node-del { position: absolute; top: 4px; width: 22px; height: 22px; border: 0; border-radius: 6px; background: #fff; color: #213a4b; box-shadow: 0 1px 3px rgba(33,58,75,.12); opacity: 0; cursor: pointer; z-index: 8; padding: 0; display: inline-flex; align-items: center; justify-content: center; pointer-events: auto; }
    .project-node-edit { right: 4px; }
    .project-node.is-group .project-node-edit { right: 28px; }
    .project-node-del { right: 4px; color: #9a3412; }
    .project-node-resize { position: absolute; right: 2px; bottom: 2px; width: 14px; height: 14px; cursor: nwse-resize; opacity: 0; z-index: 7; background: linear-gradient(135deg, transparent 50%, #9aafbd 50%); border: 0; padding: 0; }
    .project-node:hover .project-node-edit, .project-node:hover .project-node-del, .project-node:hover .project-node-resize, .project-node.is-focus .project-node-edit { opacity: 1; }
    .project-node.is-company, .project-node.is-person, .project-node.is-note, .project-node.is-unknown, .project-node.is-opportunity, .project-node.is-project, .project-node.is-task, .project-node.is-actor { z-index: 1; }
    .project-node-kicker { display: flex; align-items: center; font-size: 10px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: #719898; margin: 0 0 2px; }
    .project-node .pj-status { display: inline-block; font-size: 10px; font-weight: 700; border-radius: 999px; padding: 1px 7px; background: #eef2f6; color: #213a4b; margin-top: 4px; }
    .project-node .pj-scope { display: inline-block; font-size: 9px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: #719898; margin-top: 6px; }
    .project-node .pj-status.is-bekræftet, .project-node .pj-status.is-bekraftet { background: rgba(46,139,87,.16); }
    .project-node .pj-status.is-rygte, .project-node .pj-status.is-mulig { background: rgba(201,162,39,.18); }
    .project-node .pj-status.is-afkræftet, .project-node .pj-status.is-afkraftet { background: rgba(180,83,9,.16); }
    .project-missing { margin: 10px 0; border: 1px solid rgba(33,58,75,.18); background: rgba(33,58,75,.04); }
    .project-missing .pj-miss { display: inline-flex; align-items: center; gap: 6px; margin: 3px 8px 3px 0; }
    .project-missing .pj-miss i { width: 8px; height: 8px; border-radius: 50%; display: inline-block; background: #c9a227; }
    .project-missing .pj-miss.is-hot i { background: #b45309; }
    .project-missing .pj-miss.is-mid i { background: #c9a227; }
    .project-missing .pj-miss.is-soft i { background: #719898; }
    .project-side h4 { margin: 12px 0 6px; font-size: 11px; letter-spacing: .04em; text-transform: uppercase; color: #719898; }
    .project-node.is-dim { opacity: .62; }
    .project-node.is-focus { z-index: 3; box-shadow: 0 0 0 2px #213a4b; }
    .project-node strong { display: block; font-size: 13px; }
    .project-node small { display: block; color: #667; font-size: 11px; }
    .project-side { position: absolute; right: 0; top: 0; bottom: 0; width: min(360px, 100%); background: #fff; border-left: 1px solid var(--border, #dbe3ea); padding: 14px; overflow: auto; z-index: 4; }
    .project-layers { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 8px; }
    .pj-task-badge { display: inline-flex; align-items: center; gap: 4px; border: 0; background: #eef2f6; color: var(--brand-navy, #213a4b); border-radius: 999px; padding: 2px 8px; font-size: 11px; font-weight: 700; cursor: pointer; }
    .project-form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
    .call-pj { margin-top: 2px; }
    .project-firm-pick { margin: 0 0 12px; padding: 12px; border: 1px solid var(--border, #dbe3ea); border-radius: 12px; background: var(--surface, #fff); }
    .project-canvas-wrap > .project-firm-pick { position: absolute; z-index: 50; left: 12px; right: 12px; top: 48px; max-height: calc(100% - 60px); overflow: auto; margin: 0; box-shadow: 0 10px 28px rgba(33,58,75,.18); }
    .project-firm-pick .event-list { max-height: 280px; overflow: auto; margin-top: 8px; }
    .project-firm-pick .event-item { display: block; width: 100%; text-align: left; }
    .project-firm-pick .inline-field { display: block; margin: 8px 0; }
    #pjStartPick { margin: 12px 0; }
    #pjStartPick .pj-tmpl-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
    .project-side .modal-actions .btn { margin: 4px 4px 0 0; }
    @media (max-width: 720px) {
      .project-side { width: min(100%, 100%); }
      .project-canvas-wrap { height: min(55vh, 480px); }
    }
    #todayTasks h3 .count-badge { cursor: pointer; }
    #todayTasks .ov-work { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
    #todayTasks .ov-work-main { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; flex: 1 1 220px; }
    #todayTasks .ov-work-act { display: flex; flex-wrap: wrap; gap: 4px; }
    #todayTasks .ov-manual-done { margin-left: auto; font-size: 12px; }
    #callWorkBar { display: flex; flex-direction: column; gap: 6px; }
    #callWorkBar .call-sum-group { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; }
    #callWorkBar .call-sum-label { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; color: var(--muted, #6b7280); margin-right: 4px; }
    #prospectForm .pr-sec { margin: 0 0 14px; padding: 10px 12px; border: 1px solid var(--border, #e5e7eb); border-radius: 10px; }
    #prospectForm .pr-sec h3 { margin: 0 0 8px; font-size: 13px; font-weight: 800; }
    #prospectForm .pr-sec-now { border-color: rgba(33,58,75,.28); background: rgba(33,58,75,.04); }
    #pq-search { min-width: 180px; }
    #ptaskForm .tk-quick { display: flex; flex-direction: column; gap: 6px; }
    #ptaskForm .tk-lab { display: block; font-size: 12px; font-weight: 700; margin: 0 0 4px; }
    #ptaskForm .chip-row { margin-top: 4px; }
    #ptaskForm .tk-type-picks .chip { min-height: 38px; padding: 8px 14px; font-weight: 800; }
    #ptaskForm .tk-time-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
    #ptaskForm #tk-hour { min-width: 76px; }
    /* cprole1: rolle-bokse i én række, fluebenet må ikke strække som et input-felt */
    #contactForm .cp-flags { grid-column: 1 / -1; display: flex; flex-direction: column; gap: 6px; }
    #contactForm .cp-flags .tk-lab { display: block; font-size: 12px; font-weight: 700; }
    #contactForm .cp-flags .chip-row { display: flex; flex-wrap: wrap; gap: 8px; }
    .modal #contactForm .cp-flags .checkline {
      display: inline-flex; flex-direction: row; align-items: center; gap: 8px;
      margin: 0; padding: 6px 12px; border: 1px solid var(--border, #e5e7eb);
      border-radius: 8px; background: #fff; font-weight: 600; color: var(--navy, #213a4b);
      cursor: pointer; white-space: nowrap;
    }
    .modal #contactForm .cp-flags .checkline input {
      width: 16px; height: 16px; margin: 0; padding: 0; flex: 0 0 auto;
      accent-color: var(--teal-accent, #719898); background: none; border: none;
    }
    .modal #contactForm .cp-flags .checkline:has(input:checked) {
      border-color: var(--teal-accent, #719898); background: rgba(113,152,152,.14);
    }

/* ===== salesux2 primitives ===== */
#view-prospects.crm-sales-wide { max-width: none; }
#view-prospects .view-title { font-size: var(--sales-page); font-weight: 750; }
.sales-summary { font-size: var(--sales-meta); color: var(--sales-muted); margin: 0 0 var(--sales-space-3); }
.sales-toolbar { display: flex; flex-wrap: wrap; gap: var(--sales-space-2); align-items: center; margin: 0 0 var(--sales-space-3); }
.sales-toolbar input[type="search"] { min-width: 220px; height: var(--sales-ctrl-h); }
.sales-saved { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 var(--sales-space-3); }
.sales-saved .chip { min-height: var(--sales-ctrl-h); }
.sales-filter-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 var(--sales-space-2); min-height: 0; }
.sales-filter-chips:empty { display: none; }
.sales-record-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, var(--sales-card-w));
  justify-content: start;
  gap: var(--sales-space-3);
  margin: 0 0 var(--sales-space-4);
}
.sales-record-grid > * { width: var(--sales-card-w); max-width: var(--sales-card-w); }
.project-grid, .pj-land-col .project-grid, .pj-cat-block .project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, var(--sales-card-w));
  justify-content: start;
  align-items: start;
  gap: 12px;
}
.project-card, .sales-firm-card, .pj-cand-card {
  width: var(--sales-card-w);
  max-width: var(--sales-card-w);
  min-width: var(--sales-card-w);
  min-height: var(--sales-card-h);
  height: var(--sales-card-h);
  max-height: var(--sales-card-h);
  box-sizing: border-box;
  border: 1px solid var(--sales-border);
  border-radius: var(--sales-radius);
  background: var(--sales-surface);
  padding: 8px 10px 8px;
  cursor: pointer;
}
.project-card h3, .sales-firm-card h3, .pj-cand-card h3 {
  font-size: var(--sales-title); font-weight: 650; margin: 0 0 4px;
}
.project-card .project-meta, .sales-firm-card .muted, .pj-cand-card .pj-cand-meta {
  font-size: var(--sales-meta); color: var(--sales-muted);
}
.project-card:hover, .sales-firm-card:hover, .pj-land-row:hover, .sales-list-row:hover {
  background: var(--sales-hover);
}
.project-card.is-selected, .sales-firm-card.is-selected { background: var(--sales-selected); box-shadow: 0 0 0 1px var(--sales-border-strong); }

#prospectCallPanel { display: flex; flex-direction: column; }
#prospectCallPanel > #callSummary { order: 1; }
#prospectCallPanel > #aiAgentCall { order: 2; }
#prospectCallPanel > .toolbar { order: 3; }
#prospectCallPanel > #callSavedViews,
#prospectCallPanel > #callFocusBar { order: 4; }
#prospectCallPanel > #callActiveFilters { order: 5; }
#prospectCallPanel > #callTodayStrip { order: 16; }
#prospectCallPanel > #prospectCardGrid { order: 18; }
#prospectCallPanel > .table-wrap { order: 20; }
#prospectCallPanel > #callDashboard { order: 90; }
#prospectCallPanel > #prospectStats,
#prospectCallPanel > #salesTaskCols,
#prospectCallPanel > #callMoreMods { order: 90; }
#prospectCallPanel:not(.is-dash-open) > #prospectStats,
#prospectCallPanel:not(.is-dash-open) > #salesTaskCols,
#prospectCallPanel:not(.is-dash-open) > #callMoreMods { display: none; }
#prospectCallPanel .call-kpi-row { display: none; }
#prospectCallPanel .filters.compact > label.inline-field:not(.is-search) { display: none; }
#prospectCallPanel.is-filters-open .filters.compact > label.inline-field { display: inline-flex; }
#prospectCallPanel:not(.is-filters-open) #pq-filters { display: none; }
#prospectCallPanel.is-cards .table-wrap { display: none; }
#prospectCallPanel:not(.is-cards) #prospectCardGrid { display: none; }

.pj-land-row, .sales-list-row {
  display: grid;
  grid-template-columns: minmax(160px, 1.6fr) 70px minmax(90px, .8fr) minmax(70px, .6fr) minmax(80px, .6fr) minmax(90px, .7fr) auto;
  gap: 8px;
  align-items: center;
  min-height: var(--sales-row-h);
  padding: 6px 8px;
  border-bottom: 1px solid var(--sales-border);
  font-size: var(--sales-meta);
  background: transparent;
  width: 100%;
  text-align: left;
  cursor: pointer;
}
.pj-land-row strong, .sales-list-row strong { font-size: var(--sales-title); font-weight: 650; }
.pj-land-board { display: flex; flex-direction: column; gap: 18px; }
.pj-land-col { min-width: 0; }
.pj-land-col h2 { font-size: var(--sales-section); margin: 0 0 8px; }
.pj-cat-block h3 { font-size: 12px; letter-spacing: .04em; text-transform: uppercase; color: var(--sales-muted); margin: 10px 0 4px; }
.pj-land-rows { display: flex; flex-direction: column; }
.pj-card-acts { margin-top: 8px; }
.ai-agent-box { border: 0; padding: 0; background: transparent; box-shadow: none; }
.ai-agent-box h3 { display: none; }
.ai-agent-run { display: flex; gap: 8px; align-items: center; }
.ai-agent-run input { flex: 1; height: var(--sales-ctrl-h); }
.ai-agent-scope, .ai-agent-tips, .ai-agent-bill, .pj-openai-box { display: none; }
.ai-agent-box.is-open .ai-agent-scope,
.ai-agent-box.is-open .ai-agent-tips { display: block; }
.pj-cand-row {
  display: grid;
  grid-template-columns: minmax(180px, 1.4fr) minmax(120px, .8fr) auto;
  gap: 8px;
  align-items: center;
  min-height: var(--sales-row-h);
  padding: 8px 4px;
  border-bottom: 1px solid var(--sales-border);
}
.pj-cand-row h3 { font-size: var(--sales-title); margin: 0; }
.sales-inspector {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(var(--sales-inspector-w), 100%);
  background: var(--sales-surface); border-left: 1px solid var(--sales-border);
  z-index: 80; overflow: auto; padding: 16px 18px 24px;
  box-shadow: -8px 0 24px rgba(33,58,75,.12);
}
.sales-inspector.hidden { display: none; }
@media (max-width: 720px) {
  .sales-inspector { width: 100%; }
}
.sales-ctx {
  position: fixed; z-index: 90; min-width: 220px; max-width: 280px;
  background: var(--sales-surface); border: 1px solid var(--sales-border);
  border-radius: var(--sales-radius); box-shadow: 0 10px 28px rgba(33,58,75,.18);
  padding: 6px;
}
.sales-ctx.hidden { display: none; }
.sales-ctx button { display: block; width: 100%; text-align: left; border: 0; background: transparent; padding: 7px 10px; border-radius: 6px; cursor: pointer; font-size: 13px; }
.sales-ctx button:hover { background: var(--sales-hover); }
.sales-ctx button.is-danger { color: #9a3412; }
.sales-ctx .sales-ctx-split { height: 1px; background: var(--sales-border); margin: 4px 6px; }
.sales-inline { border-bottom: 1px dashed var(--sales-border-strong); cursor: text; }
.sales-bulk { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 8px 0; }
.sales-bulk.hidden { display: none; }
.project-node-edit, .project-node-del {
  width: 32px !important; height: 32px !important; z-index: 20 !important; pointer-events: auto !important;
}
.pj-canvas-tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.pj-canvas-tools .pj-tool-group { display: none; }
.pj-canvas-tools.is-open .pj-tool-group { display: flex; flex-wrap: wrap; gap: 6px; }
.calllist-table tbody tr { min-height: var(--sales-row-h); }
.calllist-table tbody td { font-size: var(--sales-meta); }
.call-firm-name { font-size: var(--sales-title); font-weight: 650; }
.pj-empty-line { font-size: var(--sales-meta); color: var(--sales-muted); margin: 0; padding: 4px 0; }

/* salesux3 shell */
.sales-drawer { border: 1px solid var(--sales-border); border-radius: var(--sales-card-radius); padding: 10px 12px; margin: 0 0 var(--sales-gap-sm); background: var(--sales-surface); }
.sales-drawer.hidden, .pj-agent-shell.hidden, #callDashboard.hidden, .call-col-extra.hidden { display: none !important; }
#view-prospects .call-act { max-width: 148px; }
#view-prospects .actions-col { width: 148px; white-space: nowrap; }
.why-wrap { display: flex; flex-wrap: wrap; gap: 4px; max-width: 28ch; }
.why-chip { font-size: 11px; padding: 1px 6px; border-radius: 999px; background: var(--sales-surface-2); }
.pj-agent-shell { margin: 0; }
.pj-agent-panel { margin: 0; }
.pj-agent-head { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; margin: 0 0 10px; }
.pj-agent-prog { border: 0; background: transparent; font: inherit; color: var(--sales-muted); cursor: pointer; font-size: 12px; padding: 0; }
.pj-cand-meta { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
@media (max-width: 720px) { .pj-cand-row { grid-template-columns: 1fr; } }

/* salesux4 — compact workspace, dashboard back, shared badges/menus */
#prospectCallActions .sales-head-extra { display: none; }
#prospectCallActions.is-extra .sales-head-extra { display: inline-flex; }
.sales-toolbar { gap: var(--sales-gap-xs); margin-bottom: var(--sales-gap-sm); }
.sales-summary { margin-bottom: var(--sales-gap-sm); }
.call-dash-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 8px;
  margin: 0 0 8px;
  align-items: start;
}
#callDashboard .car-box { padding: 8px 10px; min-height: 0; }
#callDashboard .task-col { min-height: 0; }
#callDashboard .collapsible-intro { margin: 0 0 6px; font-size: 12px; }
#callDashboard .watch-toolbar, #callDashboard .job-add { margin: 4px 0; }
.call-sec-fold { margin: 0 0 8px; border: 1px solid var(--sales-border); border-radius: var(--sales-card-radius); padding: 4px 8px; }
.call-sec-fold > summary { cursor: pointer; font-weight: 650; font-size: 13px; padding: 4px 0; }
.pj-card-acts { margin-top: 6px; gap: 4px; }
.pj-card-head { margin: 0 0 4px; }
.project-card .project-meta { margin: 0 0 4px; }
.pj-card-intel { margin-top: 6px; }
.calllist-table tbody tr[data-pr-open] { cursor: pointer; }
.calllist-table tbody tr[data-pr-open]:hover { background: var(--sales-hover); }
#pjListTable tbody tr[data-pj-open] { cursor: pointer; }
#pjListTable tbody tr[data-pj-open]:hover { background: var(--sales-hover); }
.pj-agent-inbox {
  display: grid;
  grid-template-columns: repeat(auto-fill, var(--sales-card-w));
  justify-content: start;
  gap: 12px;
  margin: 8px 0 0;
}
.pj-agent-status {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; color: var(--sales-muted); min-height: 22px;
}
.pj-agent-status .dot {
  width: 8px; height: 8px; border-radius: 50%; background: #5d8a6a;
  box-shadow: 0 0 0 3px rgba(93,138,106,.18);
}
.pj-agent-status.is-run .dot { background: #e08a2a; animation: salesux4pulse 1.2s ease-in-out infinite; }
@keyframes salesux4pulse { 50% { opacity: .35; } }
.sales-badge {
  display: inline-flex; align-items: center;
  font-size: 10.5px; font-weight: 800; letter-spacing: .03em; text-transform: uppercase;
  padding: 1px 6px; border-radius: 999px; line-height: 1.4;
  background: var(--sales-surface-2); color: var(--sales-muted);
}
.sales-badge.is-hot { background: rgba(228,92,74,.14); color: #b42318; }
.sales-badge.is-varm, .sales-badge.is-warm { background: rgba(224,138,42,.16); color: #9a5b12; }
.sales-badge.is-kold, .sales-badge.is-cold { background: rgba(90,122,153,.14); color: #3d5a73; }
.sales-badge.is-unset { background: var(--sales-surface-2); color: var(--sales-muted); }
.sales-badge.is-new { background: rgba(93,138,106,.16); color: #2f6d5c; }
.sales-badge.is-focus { background: rgba(201,162,39,.18); color: #8a6a10; }
.sales-badge.is-miss { background: rgba(180,83,9,.14); color: #9a3412; }
.sales-badge.is-arch { background: #eef2f6; color: #667; }
.pj-elig { display: flex; flex-wrap: wrap; gap: 4px; margin: 4px 0; }
.pj-elig span { font-size: 11px; background: var(--sales-surface-2); border-radius: 999px; padding: 1px 6px; }
.pj-elig span.is-no { opacity: .55; text-decoration: line-through; }
.pj-land-col .sales-record-grid, .pj-land-rows.sales-record-grid { margin: 0; }
.btn.btn-ghost { background: transparent; border: 1px solid var(--sales-border); }
.pj-land-board { gap: 14px; }
.pj-land-col h2 { margin: 0 0 6px; }
#view-prospects .view-head { margin-bottom: 4px; }
.project-kpis { margin: 0 0 8px; gap: 6px; }
.project-kpi { padding: 6px 8px; }

.call-today-strip {
  border: 1px solid var(--sales-border);
  border-radius: var(--sales-card-radius);
  padding: 6px 10px;
  margin: 0 0 8px;
  background: var(--sales-surface);
}
.call-today-head { display: flex; align-items: center; gap: 8px; margin: 0 0 4px; font-size: 13px; }
.call-today-head strong { font-size: 13px; }
.call-today-row {
  display: grid;
  grid-template-columns: minmax(8rem, 1.2fr) minmax(8rem, 1.4fr) auto auto;
  gap: 8px;
  align-items: center;
  min-height: 28px;
  font-size: 12.5px;
  border-top: 1px solid var(--sales-border);
  padding: 3px 0;
}
.call-today-row:hover { background: var(--sales-hover); }
.pj-cand-line, .pj-card-line {
  font-size: var(--sales-meta); color: var(--sales-muted);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin: 0 0 2px;
}
.pj-cand-sum {
  font-size: var(--sales-meta); color: var(--sales-muted); margin: 0 0 4px;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.pj-card-src { opacity: .55; width: 16px; height: 16px; flex: 0 0 auto; }
.pj-card-src:hover { opacity: 1; }
.pj-card-src .tic { width: 14px; height: 14px; }

/* salesux6 — fælles shell + compact card-familie */
#view-prospects { max-width: none; }
.sales-shell {
  display: flex;
  align-items: flex-start;
  gap: 0;
  min-height: 0;
  margin: 0;
}
.sales-rail {
  flex: 0 0 196px;
  width: 196px;
  border-right: 1px solid var(--sales-border);
  background: var(--sales-surface-2);
  padding: 8px 8px 12px;
  position: sticky;
  top: 8px;
  align-self: flex-start;
  height: auto;
  max-height: calc(100vh - 88px);
  overflow: auto;
  z-index: 2;
  box-sizing: border-box;
}
.sales-shell.is-rail-collapsed .sales-rail {
  flex-basis: 52px; width: 52px; padding: 8px 6px;
  overflow: hidden;
}
.sales-shell.is-rail-collapsed .sales-rail-lab,
.sales-shell.is-rail-collapsed .sales-rail .count-badge { display: none; }
.sales-rail-toggle {
  display: flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; margin: 0 0 8px; border: 0; background: transparent;
  color: var(--sales-muted); cursor: pointer; border-radius: 6px;
}
.sales-rail-toggle:hover { background: var(--sales-hover); color: inherit; }
.sales-shell.is-rail-collapsed .sales-rail-toggle { transform: rotate(180deg); }
.sales-rail-nav { display: flex; flex-direction: column; gap: 2px; }
.sales-rail-item.is-off,
.sales-rail-item[hidden] { display: none !important; }
.sales-rail-item {
  display: flex; align-items: center; gap: 8px;
  width: 100%; text-align: left; border: 0; background: transparent;
  padding: 7px 8px; border-radius: 8px; cursor: pointer;
  font-size: 13px; color: inherit; min-height: 36px;
}
.sales-rail-item .tic { width: 18px; height: 18px; flex: 0 0 auto; }
.sales-rail-lab { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sales-rail-item:hover { background: var(--sales-hover); }
.sales-rail-item.is-active { background: var(--sales-selected); font-weight: 650; }
.sales-shell-main { flex: 1 1 auto; min-width: 0; padding: 0 12px 16px; }
.sales-subnav-legacy { display: none !important; }
.sales-toolbar #callDashBtn,
.sales-toolbar #callOverblikBtn { display: none; }
#prospectCallPanel > #callTodayStrip { display: none; }

.sales-work-drawer {
  position: sticky;
  top: 8px;
  flex: 1 1 58%;
  width: min(760px, 58%);
  min-width: min(560px, 100%);
  max-width: min(820px, 64%);
  align-self: stretch;
  min-height: calc(100vh - 88px);
  max-height: calc(100vh - 88px);
  height: calc(100vh - 88px);
  background: var(--sales-surface);
  border-right: 1px solid var(--sales-border);
  z-index: 2;
  overflow: auto;
  box-shadow: none;
  display: flex;
  flex-direction: column;
  border-radius: 0;
  box-sizing: border-box;
}
.sales-work-drawer.hidden { display: none !important; }
.sales-work-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--sales-border);
  position: sticky; top: 0; background: var(--sales-surface); z-index: 1;
}
.sales-work-drawer:not([data-sales-work="today"]) #inboxTaskOpen { display: none; }
#inboxTaskOpen { margin-left: auto; }
.inbox-task-card { min-width: min(640px, 92vw); max-width: 720px; }
#inbox-title { min-height: 12em; width: 100%; resize: vertical; }
.inbox-task-kind { font-weight: 600; }
.inbox-task-body { white-space: pre-wrap; overflow-wrap: anywhere; display: block; }
.inbox-task-img { display: inline-flex; flex-shrink: 0; }
.inbox-task-img img { width: 40px; height: 40px; object-fit: cover; border-radius: 6px; }
.inbox-image-preview { min-height: 2.2em; }
.inbox-image-preview img { max-width: 100%; max-height: 180px; border-radius: 8px; display: block; }
.sales-work-body { padding: 8px 14px 20px; flex: 1 1 auto; min-height: 0; }
.sales-work-body #callDashboard { display: block !important; }
.sales-work-body #callDashboard.hidden { display: block !important; }
.sales-work-body .call-today-strip { margin: 0 0 12px; }
.sales-work-drawer .call-today-row {
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.4fr) auto auto;
}
.sales-work-drawer .call-dash-grid {
  grid-template-columns: 1fr;
}
.sales-work-drawer .task-col .ov-list { max-height: min(62vh, 640px); }
.sales-work-drawer[data-sales-work="today"] #callDashboard > :not(#callFocusBar):not(#salesTaskCols) { display: none !important; }
.sales-work-drawer[data-sales-work="today"] #salesTaskCols > :not(#todayTasks) { display: none !important; }
.sales-work-drawer[data-sales-work="notes"] #callTodayStrip,
.sales-work-drawer[data-sales-work="activity"] #callTodayStrip { display: none !important; }
.sales-work-drawer[data-sales-work="notes"] #callDashboard > :not(#salesTaskCols):not(#salesMonCols) { display: none !important; }
.sales-work-drawer[data-sales-work="notes"] #salesTaskCols > :not(#notifications) { display: none !important; }
.sales-work-drawer[data-sales-work="activity"] #callDashboard > :not(#salesTaskCols):not(#prospectStats) { display: none !important; }
.sales-work-drawer[data-sales-work="activity"] #salesTaskCols > :not(#doneTasks) { display: none !important; }
body.crm-sales-wide.has-sales-drawer { overflow: visible; }

.sales-card, .project-card, .sales-firm-card, .pj-cand-card {
  display: flex;
  flex-direction: column;
  width: var(--sales-card-w);
  max-width: var(--sales-card-w);
  min-width: var(--sales-card-w);
  min-height: var(--sales-card-h);
  height: var(--sales-card-h);
  max-height: var(--sales-card-h);
  box-sizing: border-box;
  border: 1px solid var(--sales-border);
  border-radius: var(--sales-card-radius);
  background: var(--sales-surface);
  padding: 8px 10px 8px;
  cursor: pointer;
  overflow: hidden;
  margin: 0;
}
.sales-card-head {
  display: flex; align-items: flex-start; gap: 6px; margin: 0 0 4px;
}
.sales-card-head .pj-flag, .sales-rail-flags .pj-flag { flex: 0 0 auto; }
.sales-rail-flags { display: inline-flex; align-items: center; gap: 2px; min-width: 0; }
.sales-rail-flags:empty { display: none; }
.sales-rail-flags .pj-flag svg { width: 14px; height: 14px; }
.pj-land-flags { display: inline-flex; align-items: center; gap: 4px; }
.sales-card-title, .sales-card h3, .project-card h3, .sales-firm-card h3, .pj-cand-card h3 {
  flex: 1 1 auto; min-width: 0; margin: 0;
  font-size: var(--sales-title); font-weight: 650; line-height: 1.25;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.sales-card-more {
  flex: 0 0 auto; margin-left: auto; min-width: 28px; padding: 0 6px !important;
}
.sales-card-sub, .sales-card-desc {
  font-size: var(--sales-meta); color: var(--sales-muted);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin: 0 0 2px;
}
.sales-card-desc { -webkit-line-clamp: 2; display: -webkit-box; -webkit-box-orient: vertical; white-space: normal; }
.sales-card-badges {
  display: flex; flex-wrap: wrap; gap: 4px; margin: 4px 0 2px; min-height: 20px; align-items: center;
}
.sales-card-rel {
  font-size: var(--sales-meta); color: var(--sales-muted);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin: 0 0 4px;
}
.sales-card-foot, .pj-card-acts {
  display: flex; flex-wrap: wrap; gap: 4px; align-items: center;
  margin-top: auto; padding-top: 6px;
}
.sales-badge, .pj-elig span, .why-chip, .pj-rel-badge {
  display: inline-flex; align-items: center; height: 20px; padding: 0 7px;
  border-radius: 999px; font-size: 11px; font-weight: 650; line-height: 1; white-space: nowrap;
  border: 0;
}
.pj-rel-badge { cursor: pointer; }
.pj-agent-inbox { display: grid; grid-template-columns: repeat(auto-fill, var(--sales-card-w)); justify-content: start; gap: var(--sales-space-3); }
.pj-agent-inbox.is-list {
  display: flex; flex-direction: column; gap: 0;
}
.pj-agent-inbox.is-list .pj-cand-card,
.pj-agent-inbox.is-list .sales-card {
  width: 100%; min-width: 0; max-width: none; min-height: 0; height: auto; max-height: none;
  flex-direction: row; flex-wrap: wrap; align-items: center;
  border-radius: 0; border-left: 0; border-right: 0; padding: 8px 4px;
}
.pj-agent-inbox .pj-cand-row { display: flex; flex-direction: column; }
.pj-agent-inbox.is-list .pj-cand-row { display: grid; grid-template-columns: minmax(160px, 1.6fr) minmax(120px, 1fr) auto; }

.calllist-table tbody tr:hover, .sales-list-row:hover, .pj-land-row:hover, .project-card:hover, .sales-firm-card:hover, .pj-cand-card:hover, .sales-card:hover {
  background: var(--sales-hover);
}
.calllist-table tbody tr { cursor: pointer; }
.call-firm-name { text-decoration: underline; text-decoration-color: transparent; }
.calllist-table tbody tr:hover .call-firm-name { text-decoration-color: currentColor; }
#projectListWrap table { width: 100%; }
#projectListWrap td, #projectListWrap th { font-size: var(--sales-meta); padding: 8px 10px; }
.pj-land-board { gap: 10px; }
.pj-land-col { min-width: 0; }
.pj-map-popup { max-width: 260px; }
.pj-map-popup.sales-card { min-height: 0; height: auto; max-width: 260px; cursor: default; }
.pj-map-popup h3 { font-size: 13px; margin: 0 0 4px; }
.pj-map-popup .sales-card-foot { margin-top: 8px; }

.sales-card .prio-pill {
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 800;
  padding: 2px 8px;
  min-width: 28px;
  justify-content: center;
  line-height: 1.2;
}
.sales-card .prio-pill.prio-hot { color: #c23b32; }
.sales-card .prio-pill.prio-varm { color: #c48412; }
.sales-card .prio-pill.prio-kold { color: #2a8aa8; }
.sales-firm-card.prio-hot { border-color: rgba(227,93,82,.45); box-shadow: inset 3px 0 0 #e35d52; }
.sales-firm-card.prio-varm { border-color: rgba(242,169,34,.5); box-shadow: inset 3px 0 0 #f2a922; }
.sales-firm-card.prio-kold { border-color: rgba(77,184,214,.4); box-shadow: inset 3px 0 0 #4db8d6; }
.sales-card-board.pj-land-board {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin: 0 0 16px;
}
.sales-land-col h2 {
  margin: 0 0 8px;
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--brand-navy, #213a4b);
  font-weight: 800;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--sales-border);
}
.sales-land-col .sales-record-grid { margin: 0; }

@media (max-width: 900px) {
  .sales-shell { margin: 0; }
  .sales-rail { flex-basis: 48px; width: 48px; padding: 8px 4px; }
  .sales-rail-lab, .sales-rail .count-badge { display: none; }
  .sales-work-drawer { flex: 1 1 100%; width: 100%; min-width: 0; max-width: 100%; height: auto; min-height: 0; max-height: calc(100vh - 76px); }
}
