/* OmniCRM stylesheet — extracted from index.html (v1.6.1 restructure, phase 1) */
  /* design tokens: single source of truth is the :root block below (was duplicated pre-v4.9.1) */
  *{box-sizing:border-box;}
  html,body{height:100%;}
  body{
    margin:0; background:var(--bg); color:var(--ink);
    font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
    font-size:17px; line-height:1.5;
  }
  button{font-family:inherit;font-size:16px;cursor:pointer;}
  input,select,textarea{font-family:inherit;font-size:16px;}

  .btn{
    display:inline-flex;align-items:center;gap:8px;justify-content:center;
    min-height:44px;padding:0 18px;border-radius:var(--radius);
    border:1px solid var(--line-strong);background:var(--panel);color:var(--ink);
    font-weight:600;transition:background .12s,border-color .12s;white-space:nowrap;
  }
  .btn:hover{background:#f3f5f8;}
  .btn-primary{background:var(--accent);border-color:var(--accent);color:var(--accent-ink);}
  .btn-primary:hover{background:#315499;}
  .btn-ghost{background:transparent;border-color:transparent;}
  .btn-ghost:hover{background:#e3e8ef;}
  .btn-danger{background:var(--danger);border-color:var(--danger);color:#fff;}
  .btn-danger:hover{background:#bd3030;}
  .btn-sm{min-height:40px;padding:0 14px;font-size:15px;}
  .btn[disabled]{opacity:.55;cursor:not-allowed;}
  .btn.active{background:var(--accent);border-color:var(--accent);color:#fff;}

  /* ---------- Auth screen ---------- */
  #auth{min-height:100%;display:flex;align-items:center;justify-content:center;padding:24px;}
  .auth-card{
    width:100%;max-width:420px;background:var(--panel);border:1px solid var(--line);
    border-radius:16px;box-shadow:var(--shadow);padding:34px 32px;text-align:center;
  }
  .brand{font-size:30px;font-weight:800;letter-spacing:-.5px;margin:0 0 4px;}
  .brand span{color:var(--accent);}
  .auth-sub{color:var(--muted);margin:0 0 26px;font-size:16px;}
  .auth-card label{display:block;text-align:left;font-weight:600;font-size:15px;margin:0 0 6px;}
  .auth-card input{
    width:100%;min-height:48px;padding:0 14px;border:1px solid var(--line-strong);
    border-radius:var(--radius);margin-bottom:16px;
  }
  .auth-card input:focus{outline:2px solid var(--accent-soft);border-color:var(--accent);}
  .auth-card .btn{width:100%;}
  .auth-msg{margin-top:16px;font-size:15px;min-height:22px;}
  .auth-msg.ok{color:var(--ok);} .auth-msg.err{color:var(--danger);}

  /* ---------- App shell ---------- */
  #app{display:flex;flex-direction:column;height:100%;}
  header.topbar{
    display:flex;align-items:center;gap:10px;flex-wrap:wrap;
    padding:10px 16px;background:var(--panel);border-bottom:1px solid var(--line);
  }
  header .logo{font-size:20px;font-weight:800;letter-spacing:-.3px;}
  header .logo span{color:var(--accent);}
  header button.logo-home{
    appearance:none;border:0;background:transparent;color:inherit;padding:0;margin:0;
    line-height:1;cursor:pointer;
  }
  header button.logo-home:hover{opacity:.78;}
  header button.logo-home:focus-visible{outline:2px solid var(--accent);outline-offset:4px;border-radius:3px;}
  header .ver{font-size:12px;color:var(--muted);font-weight:700;margin-left:-4px;}
  header .spacer{flex:1;}
  header .who{color:var(--muted);font-size:14px;max-width:200px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
  .divider{width:1px;height:28px;background:var(--line);margin:0 2px;}

  main.workspace{flex:1;display:flex;min-height:0;position:relative;}
  #graph-wrap{flex:1;display:flex;flex-direction:column;min-width:0;position:relative;}
  /* v4.2.5: the applied-view name is now a real header row above the canvas (not a floating
     pill over it) — plain title, not a banner, so it reads like a page header. */
  .view-header-bar{
    flex:0 0 auto;display:flex;align-items:center;gap:12px;
    padding:12px 22px;background:var(--panel);border-bottom:1px solid var(--line);
  }
  .view-header-bar .vh-eyebrow{font-size:11px;font-weight:700;color:var(--muted);text-transform:uppercase;letter-spacing:.05em;}
  .view-header-bar .vh-name{font-size:19px;font-weight:800;color:var(--ink);}
  .view-header-bar a{margin-left:auto;color:var(--accent);text-decoration:none;font-size:13px;font-weight:600;}
  .view-header-bar a:hover{text-decoration:underline;}
  #graph-canvas-area{flex:1;position:relative;min-height:0;background-color:#f7f8fb;background-image:
     radial-gradient(circle at 1px 1px, rgba(71,85,105,.10) .8px, transparent .9px);background-size:24px 24px;}
  #graph{position:absolute;inset:0;}
  .canvas-fullscreen-btn{position:absolute;right:18px;top:14px;z-index:25;box-shadow:var(--shadow);}
  #graph-wrap:fullscreen{width:100vw;height:100vh;background:#f7f8fb;}
  #graph-wrap:fullscreen .canvas-fullscreen-btn{top:14px;}
  .connect-banner{
    position:absolute;left:50%;top:14px;transform:translateX(-50%);
    background:var(--accent);color:#fff;padding:8px 16px;border-radius:999px;
    font-size:14px;font-weight:600;box-shadow:var(--shadow);
  }
  .focus-banner{
    position:absolute;left:50%;top:14px;transform:translateX(-50%);
    background:#1d2733;color:#fff;padding:8px 16px;border-radius:999px;
    font-size:14px;font-weight:600;box-shadow:var(--shadow);
  }
  .focus-banner a{color:#fff;text-decoration:underline;margin-left:6px;}
  .node-info{
    position:absolute;z-index:30;max-width:220px;background:var(--panel);border:1px solid var(--line-strong);
    border-radius:10px;padding:8px 10px;box-shadow:0 8px 28px rgba(0,0,0,.18);pointer-events:auto;
  }
  .node-info .ni-photo{display:block;width:36px;height:36px;object-fit:cover;border-radius:6px;margin-bottom:5px;}
  .node-info .ni-photo.round{border-radius:50%;}
  .node-info .ni-name{font-size:13px;font-weight:700;color:var(--ink);margin-bottom:3px;}
  .node-info .ni-row{font-size:12px;color:var(--muted);margin:2px 0;line-height:1.35;}
  .node-info .ni-row .badge{font-size:11px;padding:1px 7px;}

  /* ---------- Side panel ---------- */
  aside#side{
    width:360px;flex:0 0 360px;background:var(--panel);border-right:1px solid var(--line);
    display:flex;flex-direction:column;min-height:0;
    transition:flex-basis .18s ease,width .18s ease;overflow:hidden;
  }
  main.workspace.side-collapsed aside#side{width:0;flex-basis:0;min-width:0;border-right:0;}
  .side-toggle{
    position:absolute;top:50%;left:0;transform:translateY(-50%);z-index:20;
    width:18px;height:56px;border:1px solid var(--line-strong);border-left:0;
    background:var(--panel);border-radius:0 8px 8px 0;cursor:pointer;
    display:flex;align-items:center;justify-content:center;font-size:16px;line-height:1;
    color:var(--muted);box-shadow:var(--shadow);padding:0;
  }
  .side-toggle:hover{background:var(--accent-soft);color:var(--accent);}
  main.workspace.side-collapsed .side-toggle{transform:translateY(-50%) rotate(180deg);}
  .side-head{padding:12px 16px;border-bottom:1px solid var(--line);font-weight:700;
    display:flex;align-items:center;gap:8px;}
  .side-head .spacer{flex:1;}
  .side-body{padding:14px 16px;overflow-y:auto;overflow-x:hidden;flex:1;}
  .search-row{display:flex;gap:8px;margin-bottom:10px;}
  .search-row input{flex:1;min-height:42px;padding:0 12px;border:1px solid var(--line-strong);border-radius:8px;}
  .search-row select{min-height:42px;padding:0 8px;border:1px solid var(--line-strong);border-radius:8px;}
  .list-item{
    display:flex;align-items:center;gap:7px;padding:2px 8px;border:1px solid var(--line);
    border-radius:6px;margin-bottom:2px;cursor:pointer;transition:border-color .1s,background .1s;
    line-height:1.4;
  }
  .list-item .nm{flex:1;min-width:0;font-size:16px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
  .list-item:hover{border-color:var(--accent);background:var(--accent-soft);}
  .list-item .mark{width:11px;height:11px;border-radius:3px;flex:0 0 auto;}
  .list-item .mark.contact{border-radius:50%;}
  .list-item .mark.deal{border-radius:2px;transform:rotate(45deg);}
  .thumb{width:18px;height:18px;border-radius:5px;object-fit:cover;flex:0 0 auto;background:#eef1f5;border:1px solid var(--line);}
  .view-actions{display:flex;gap:6px;align-items:center;flex-wrap:wrap;margin-bottom:6px;}
  #view-del{color:var(--danger);background:var(--danger-soft);border-color:var(--danger);}
  #view-del:hover{background:var(--danger);border-color:var(--danger);color:#fff;}
  #view-del:active{background:#bd3030;border-color:#bd3030;color:#fff;}
  .view-row{display:flex;gap:6px;margin-bottom:8px;align-items:center;}
  .view-row select{flex:1;min-width:0;width:100%;}
  #show-panel{border:1px solid var(--line);border-radius:9px;padding:8px 12px;margin-bottom:10px;background:#fbfcfe;}
  #show-panel summary{cursor:pointer;font-weight:600;font-size:14px;user-select:none;}
  .sp-dim{margin-top:10px;}
  .sp-t{font-size:12px;color:var(--muted);text-transform:uppercase;letter-spacing:.4px;margin-bottom:4px;}
  .sp-list{display:flex;flex-wrap:wrap;gap:4px 16px;}
  .sp-cb{display:flex;align-items:center;gap:6px;font-size:14px;cursor:pointer;font-weight:500;}
  .sp-cb input{width:auto;min-height:auto;}
  .row-hide{margin-left:6px;flex:0 0 auto;font-size:12px;color:var(--muted);text-decoration:none;padding:4px 7px;border-radius:6px;opacity:0;transition:opacity .12s;}
  .list-item:hover .row-hide, .list-item:focus-within .row-hide{opacity:1;}
  .row-hide:hover{background:var(--danger-soft);color:var(--danger);}
  #hidden-row{margin-top:10px;font-size:13px;color:var(--muted);}
  .wslider{display:flex;gap:2px;flex-wrap:nowrap;}
  .wseg{
    border:1px solid var(--line-strong);background:#fff;border-radius:5px;
    padding:3px 5px;font-size:11px;font-weight:600;cursor:pointer;color:var(--muted);
    min-height:0;white-space:nowrap;flex:0 1 auto;
    transition:background .1s,border-color .1s,color .1s;
  }
  .wseg:hover{border-color:var(--wc,#888);color:var(--ink);}
  .wseg.on{background:var(--wc,#888);border-color:var(--wc,#888);color:#fff;}
  .wseg.clear{font-weight:600;font-style:normal;}
  .wseg.clear.on{background:var(--muted);border-color:var(--muted);color:#fff;}
  /* per-view relationship/role status swatches (green/orange/red/white) — unlike the warmth/
     weight sliders above, every swatch always shows its own color (not just when selected),
     so all four options are visible at a glance; the selected one gets a dark ring. */
  .stance-slider .wseg{width:24px;height:24px;min-height:0;padding:0;border-radius:50%;background:var(--wc);border:2px solid var(--wc);}
  .stance-slider .wseg:hover{border-color:var(--wc);}
  .stance-slider .wseg.on{box-shadow:0 0 0 2px #fff inset,0 0 0 4px var(--ink);}
  .stance-slider .wseg[data-s="white"]{border-color:var(--line-strong);}
  .stance-slider .wseg.clear{width:auto;height:24px;border-radius:6px;padding:0 8px;background:#fff;border:1px dashed var(--line-strong);color:var(--muted);font-size:14px;}
  .stance-slider .wseg.clear.on{background:#fff;border-color:var(--ink);color:var(--ink);}
  .thumb.round{border-radius:50%;}
  .detail-photo{width:76px;height:76px;border-radius:10px;object-fit:cover;border:1px solid var(--line);margin-bottom:12px;background:#eef1f5;}
  .detail-photo.round{border-radius:50%;}
  .img-edit{display:flex;align-items:center;gap:12px;flex-wrap:wrap;}
  .img-edit img{width:60px;height:60px;border-radius:8px;object-fit:cover;border:1px solid var(--line-strong);background:#f3f5f8;}
  .img-edit.round img{border-radius:50%;}
  .img-edit input[type=file]{flex:1;min-height:auto;border:none;padding:0;}
  .img-edit .img-paste{flex-basis:100%;min-height:30px;padding:4px 8px;font-size:12px;font-style:italic;color:var(--muted);border:1px dashed var(--line-strong);border-radius:6px;background:#fbfcfe;}
  .img-edit .img-paste:focus{font-style:normal;color:var(--ink);border-style:solid;}
  .list-item .nm{font-weight:600;}
  .list-item .sub{color:var(--muted);font-size:13px;}
  .empty{color:var(--muted);text-align:center;padding:30px 10px;}

  /* org -> contacts tree (v4.1.0) */
  .tree-sec-h{font-size:12px;color:var(--muted);text-transform:uppercase;letter-spacing:.5px;font-weight:700;margin:14px 0 6px;}
  .tree-sec-h:first-child{margin-top:0;}
  .empty-sub{color:var(--muted);font-size:13px;padding:2px 8px 6px 34px;}
  .org-branch{margin-bottom:2px;}
  .org-row{display:flex;align-items:center;gap:6px;padding:2px 8px;border:1px solid var(--line);
    border-radius:6px;cursor:pointer;transition:border-color .1s,background .1s;line-height:1.4;}
  .org-row:hover{border-color:var(--accent);background:var(--accent-soft);}
  .org-row .nm{flex:1;min-width:0;font-size:16px;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
  .org-toggle{width:28px;height:28px;flex:0 0 auto;border:none;background:none;cursor:pointer;
    color:var(--muted);font-size:18px;padding:0;display:flex;align-items:center;justify-content:center;}
  .org-toggle:disabled{cursor:default;opacity:.4;}
  /* expanded (accordion — only one organization's contact list stays open at a time) */
  .org-branch.expanded .org-row{border-color:var(--accent);background:var(--accent-soft);
    box-shadow:0 0 0 1px var(--accent);}
  .org-branch.expanded .org-toggle{color:var(--accent);}
  .org-selall{flex:0 0 auto;cursor:pointer;width:20px;height:20px;accent-color:var(--accent);margin:0 2px 0 0;}
  .org-count{flex:0 0 auto;font-size:12px;color:var(--muted);min-width:16px;text-align:right;}
  .org-contacts{padding-left:26px;margin-top:2px;}
  .org-contacts .list-item{margin-bottom:2px;}
  .contact-chk{flex:0 0 auto;cursor:pointer;width:20px;height:20px;accent-color:var(--accent);margin:0 2px 0 0;}

  /* unassigned contacts grouped by group_name (v4.2.3) — same look as the org tree above,
     but its own class names so its accordion (only one GROUP open at a time) never touches
     the organization accordion, and vice versa; no checkboxes/multi-drag for groups (v1). */
  .group-branch{margin-bottom:2px;}
  .group-row{display:flex;align-items:center;gap:6px;padding:2px 8px;border:1px solid var(--line);
    border-radius:6px;cursor:pointer;transition:border-color .1s,background .1s;line-height:1.4;}
  .group-row:hover{border-color:var(--accent);background:var(--accent-soft);}
  .group-row .nm{flex:1;min-width:0;font-size:16px;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
  .group-toggle{width:28px;height:28px;flex:0 0 auto;border:none;background:none;cursor:pointer;
    color:var(--muted);font-size:18px;padding:0;display:flex;align-items:center;justify-content:center;}
  .group-branch.expanded .group-row{border-color:var(--accent);background:var(--accent-soft);
    box-shadow:0 0 0 1px var(--accent);}
  .group-branch.expanded .group-toggle{color:var(--accent);}
  .group-count{flex:0 0 auto;font-size:12px;color:var(--muted);min-width:16px;text-align:right;}
  .group-contacts{padding-left:26px;margin-top:2px;}
  .group-contacts .list-item{margin-bottom:2px;}

  /* zone chips: draggable, unplaced-by-default zones (v4.1.0) */
  .zone-chips{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:4px;}
  .zone-chip{display:flex;align-items:center;gap:6px;padding:4px 10px;border:1px solid var(--line);
    border-radius:14px;cursor:grab;font-size:13px;font-weight:600;background:#fff;}
  .zone-chip:hover{border-color:var(--accent);background:var(--accent-soft);}
  .zone-chip-sw{width:10px;height:10px;border-radius:50%;flex:0 0 auto;}

  .detail-kv{margin:0 0 12px;}
  .detail-kv .k{font-size:12px;color:var(--muted);text-transform:uppercase;letter-spacing:.4px;}
  .detail-kv .v{font-size:16px;}
  .chip{display:inline-block;background:var(--accent-soft);color:var(--accent);
    border-radius:999px;padding:2px 10px;font-size:13px;font-weight:600;margin:2px 4px 2px 0;}
  .detail-actions{display:flex;gap:8px;margin-top:18px;flex-wrap:wrap;}
  .badge{display:inline-block;padding:3px 10px;border-radius:999px;font-size:13px;font-weight:700;color:#fff;}
  /* Projop details panel — Info/Log tabs (v4.7.4) */
  .pj-tabs{display:flex;gap:2px;margin:20px 0 0;border-bottom:1px solid var(--line);}
  .pj-tab-btn{background:none;border:none;padding:8px 14px;font-size:13px;font-weight:600;
    color:var(--muted);cursor:pointer;border-bottom:2px solid transparent;margin-bottom:-1px;}
  .pj-tab-btn.active{color:var(--ink);border-bottom-color:var(--accent);}
  .pj-tab-panel{display:none;padding-top:14px;}
  .pj-tab-panel.active{display:block;}
  /* Projop Info tab — "legend left, value right" orderly rows (v4.8.3) */
  .pj-kv{display:grid;grid-template-columns:130px 1fr;column-gap:14px;align-items:baseline;
    padding:8px 0;border-bottom:1px solid var(--line);}
  .pj-kv:last-child{border-bottom:none;}
  .pj-kv .k{font-size:11px;letter-spacing:.6px;text-transform:uppercase;color:var(--muted);font-weight:600;}
  .pj-kv .v{font-size:14px;color:var(--ink);line-height:1.4;}
  /* v4.8.4: lengthy fields (Description) stack label above value instead of squeezing
     into the 130px legend column — grid-template-columns:1fr puts .k and .v each on
     their own full-width row (still same two grid cells, just single-column now). */
  .pj-kv-stack{grid-template-columns:1fr;row-gap:6px;}
  .pj-tab-hint{margin:0 0 12px;}

  /* ---------- Projop popup (v11.3.0) — #side gets relocated in here, unchanged, so every
     existing rule inside it keeps working; only width/flex are overridden to fill this shell
     instead of the docked 360px column. z-index sits BELOW .modal-overlay's 50, so the Edit
     Projop form still opens visually on top of this when opened from inside it. */
  .pj-popup{position:fixed;inset:0;background:rgba(20,30,45,.45);display:flex;
    align-items:center;justify-content:center;padding:20px;z-index:45;}
  .pj-popup[hidden]{display:none;}
  .pj-popup-panel{background:var(--panel);border-radius:14px;box-shadow:var(--shadow);
    width:min(880px,94vw);height:min(880px,88vh);display:flex;flex-direction:column;overflow:hidden;}
  /* v12.3.1 — the popup is a SET size (height, not max-height) so it stops resizing itself as you
     move between tabs, and #side-body is the one thing that scrolls inside it. min-height:0 is
     what actually lets a flex child shrink below its content and hand the overflow to that
     scroller; without it the panel would simply be pushed past its own height. */
  .pj-popup-panel aside#side{width:100%;flex:1 1 auto;min-height:0;height:100%;border-right:0;}
.pj-popup-panel #side-body{flex:1 1 auto;min-height:0;overflow-y:auto;}
.pj-popup-foot .pj-popup-record-action{flex:0 0 auto;}
  .pj-popup-foot{display:flex;gap:8px;justify-content:flex-end;padding:10px 16px;
    border-top:1px solid var(--line);flex:0 0 auto;order:2;}

  /* ---------- Modal ---------- */
  .modal-overlay{position:fixed;inset:0;background:rgba(20,30,45,.45);display:flex;
    align-items:center;justify-content:center;padding:20px;z-index:50;}
  .modal-card{background:var(--panel);border-radius:14px;box-shadow:var(--shadow);
    width:100%;max-width:520px;max-height:90vh;overflow:auto;}
  .modal-head{padding:18px 22px;border-bottom:1px solid var(--line);font-size:20px;font-weight:800;}
  .modal-body{padding:18px 22px;}
  .modal-foot{padding:14px 22px;border-top:1px solid var(--line);display:flex;gap:10px;justify-content:flex-end;}
  .field{margin-bottom:14px;}
  .field label{display:block;font-weight:600;font-size:14px;margin-bottom:5px;}
  .field input,.field select,.field textarea{
    width:100%;min-height:44px;padding:8px 12px;border:1px solid var(--line-strong);border-radius:8px;
  }
  .field textarea{min-height:74px;resize:vertical;}
  .field .hint{color:var(--muted);font-size:12px;margin-top:4px;}
  .grid2{display:grid;grid-template-columns:1fr 1fr;gap:0 14px;}

  /* ---------- inline quick-add-organization (contact form) ---------- */
  .org-pick-row{display:flex;align-items:center;gap:6px;}
  .org-pick-row select{flex:1;min-width:0;}
  .org-pick-row .btn{flex:0 0 auto;padding-left:14px;padding-right:14px;}
  .org-quick-add{display:flex;align-items:center;gap:6px;margin-top:8px;}
  .org-quick-add input{flex:1;min-width:0;min-height:38px;padding:6px 10px;border:1px solid var(--line-strong);border-radius:8px;}
  .org-quick-add .btn{flex:0 0 auto;}

  /* ---------- LinkedIn candidate picker ---------- */
  .li-cand-list{display:flex;flex-direction:column;gap:8px;margin-bottom:6px;}
  .li-cand{display:flex;gap:10px;align-items:flex-start;border:1px solid var(--line);border-radius:10px;
    padding:10px 12px;cursor:pointer;transition:border-color .12s,background .12s;}
  .li-cand:hover{border-color:var(--line-strong);background:var(--bg);}
  .li-cand input[type="radio"]{margin-top:3px;min-height:0;width:auto;flex:0 0 auto;}
  .li-cand-body{flex:1;min-width:0;}
  .li-cand-top{display:flex;align-items:center;gap:8px;font-size:15px;}
  .li-cand-sub{color:var(--muted);font-size:13px;margin-top:2px;}
  .li-cand-url{display:block;font-size:12px;color:var(--accent);margin-top:4px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
  .li-cand-manual .li-manual-input{width:100%;min-height:38px;padding:6px 10px;border:1px solid var(--line-strong);
    border-radius:8px;margin-top:6px;font-size:14px;}
  .li-conf{font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.3px;padding:2px 7px;border-radius:20px;}
  .li-conf-high{background:var(--ok);color:#fff;}
  .li-conf-medium{background:#e0a800;color:#fff;}
  .li-conf-low{background:var(--line-strong);color:var(--ink);}
  /* v12.78.0 — the picker is a standalone screen now (its own button), so it carries the two
     things it never had: WHY a candidate is being offered, and a way through when the AI finds
     nothing. Every colour below uses a variable defined in :root — an undefined custom property
     invalidates the whole declaration silently, and jsdom applies no CSS, so the smoke suite
     cannot catch it (see the --card and --pc findings in CLAUDE.md). */
  .li-cand-why{color:var(--muted);font-size:12px;font-style:italic;margin-top:3px;}
  .li-search-links{display:flex;flex-direction:column;gap:6px;margin-top:12px;padding-top:10px;border-top:1px solid var(--line);}
  .li-search-head{font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.4px;color:var(--muted);margin-bottom:2px;}
  .li-search-link{display:flex;flex-direction:column;gap:1px;text-decoration:none;border:1px solid var(--line);
    border-radius:8px;padding:8px 10px;background:var(--card);transition:border-color .12s,background .12s;}
  .li-search-link:hover{border-color:var(--line-strong);background:var(--bg);}
  .li-search-link b{font-size:13px;color:var(--accent);}
  .li-search-link span{font-size:12px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
  .li-why{margin-top:12px;font-size:12px;color:var(--muted);}
  .li-why summary{cursor:pointer;font-weight:600;}
  .li-why p{margin:6px 0 0;line-height:1.45;word-break:break-word;}

  /* ---------- Toast ---------- */
  #toast{position:fixed;left:50%;bottom:26px;transform:translateX(-50%) translateY(20px);
    background:#1d2733;color:#fff;padding:12px 20px;border-radius:10px;font-size:15px;
    box-shadow:var(--shadow);opacity:0;pointer-events:none;transition:.22s;z-index:80;max-width:80vw;}
  #toast.show{opacity:1;transform:translateX(-50%) translateY(0);}
  #toast.err{background:var(--danger);}

  .stake-row{display:flex;align-items:center;gap:8px;padding:7px 8px;border:1px solid var(--line);border-radius:8px;margin-bottom:6px;cursor:pointer;}
  .stake-row:hover{border-color:var(--accent);}
  .stake-name{font-weight:600;flex:1;}
  .stake-x{border:none;background:transparent;color:var(--muted);font-size:18px;line-height:1;cursor:pointer;padding:0 4px;}
  .stake-x:hover{color:var(--danger);}
  /* v4.9.0: .stake-kv modifier on .stake-row — "label left, name right" justified layout for
     the Stakeholders-tab list. The base .stake-row/.stake-name/.stake-x rules above are shared
     with the Connections block (js/ui.js connectionsBlockHtml()), which never gets .stake-kv,
     so its original inline layout is untouched. */
  .stake-row.stake-kv{display:grid;grid-template-columns:110px 1fr;column-gap:14px;align-items:center;}
  .stake-kv .stake-meta{display:flex;align-items:center;gap:8px;}
  .stake-kv .stake-name{flex:1;}
  .stake-edit{border:none;background:transparent;color:var(--muted);font-size:14px;line-height:1;cursor:pointer;padding:0 2px;}
  .stake-edit:hover{color:var(--accent);}
  /* Generic type-to-filter picker (v4.9.0) — text input + click-to-select dropdown, used by
     the Add/Edit Stakeholder form's Contact/Organization fields instead of a long native <select>. */
  .fp-wrap{position:relative;}
  .fp-input{width:100%;min-height:38px;padding:0 10px;border:1px solid var(--line-strong);border-radius:8px;background:#fff;}
  .fp-input:disabled{background:var(--panel-2,#f3f6fa);color:var(--muted);}
  .fp-list{position:absolute;left:0;right:0;top:calc(100% + 4px);z-index:50;background:#fff;
    border:1px solid var(--line);border-radius:8px;max-height:180px;overflow:auto;
    box-shadow:0 4px 14px rgba(0,0,0,.12);}
  .fp-item{padding:6px 10px;cursor:pointer;font-size:13px;}
  .fp-item:hover{background:var(--accent-soft);}
  .fp-empty{padding:6px 10px;color:var(--muted);font-size:12px;}
  .act-row{border:1px solid var(--line);border-radius:8px;padding:8px 10px;margin-bottom:8px;cursor:pointer;}
  .act-row:hover{border-color:var(--accent);}
  .act-head{display:flex;align-items:center;gap:8px;}
  .act-check{margin:0;flex:0 0 auto;}
  .act-d{color:var(--muted);font-size:13px;flex:1;}
  .act-sum{margin-top:4px;font-size:15px;}
  /* v4.9.0: activities are micro-tasks now — a checked-done row stays visible but visually
     recedes (dimmed + struck-through summary), it's never removed from the timeline. */
  .act-row.done{opacity:.6;}
  .act-row.done .act-sum{text-decoration:line-through;}
  .act-next{margin-top:4px;font-size:14px;color:var(--accent);}
  /* deal-log (view_notes) timeline reuses .act-row/.act-head/.act-d/.act-sum above — only the
     add-row is new. */
  .vn-add-row{display:flex;gap:6px;margin-top:8px;}
  .vn-add-row input{flex:1;min-height:38px;padding:0 10px;border:1px solid var(--line-strong);border-radius:8px;}

  /* ---- v9.9.5: the note CARD, shared by every log surface ------------------------------
     Costas asked for title first, date under it, then the content — the old .act-head put the
     DATE on the top line and never rendered a title at all. .nc-top is .act-head's replacement
     for note rows only; activity rows still use .act-head because they lead with a type badge
     and a done checkbox, not a title. */
  .nc-top{display:flex;align-items:flex-start;gap:8px;}
  .nc-main{flex:1;min-width:0;}
  .nc-title{font-size:15px;font-weight:600;color:var(--ink);line-height:1.25;
            overflow-wrap:anywhere;margin-bottom:1px;}
  .nc-date{color:var(--muted);font-size:12px;line-height:1.3;}
  .nc-body{margin-top:5px;font-size:15px;overflow-wrap:anywhere;}
  .nc-body a{color:var(--accent);text-decoration:underline;}
  .nc-body b{font-weight:600;}
  .act-row.done .nc-body{text-decoration:line-through;}

  /* ---- v9.9.5: the note COMPOSER, shared by every log surface ----
     Title on its own line, then a multi-line body: a log entry is often more than one sentence
     and the old single-line <input> made that painful. Enter in the body inserts a newline,
     Ctrl/Cmd+Enter submits (wireNoteComposerKeys). */
  .nc-add{margin-top:10px;}
  .nc-add-title{width:100%;min-height:36px;padding:0 10px;font-weight:600;
                border:1px solid var(--line-strong);border-radius:8px;background:var(--panel);color:var(--ink);}
  .nc-add-row{display:flex;gap:6px;align-items:flex-start;margin-top:6px;}
  .nc-add-body{flex:1;min-width:0;min-height:52px;padding:8px 10px;font:inherit;font-size:14px;
               line-height:1.4;resize:vertical;
               border:1px solid var(--line-strong);border-radius:8px;background:var(--panel);color:var(--ink);}
  .nc-add-row select{flex:0 0 auto;max-width:150px;}
  .nc-add-row .btn{flex:0 0 auto;}
  .nc-hint{margin-top:4px;font-size:11px;color:var(--muted);}

  /* ---- v9.9.7: edit an existing entry, inline ----
     A pencil beside the delete ×. Deliberately not a whole-card click: note bodies carry real
     hyperlinks since v9.9.6, and a card-wide handler would fight them and block text selection.
     The button sits at the same size/weight as .stake-x so the two read as a pair. */
  .nc-edit{background:none;border:0;padding:0 4px;cursor:pointer;color:var(--muted);
           font-size:15px;line-height:1;flex:0 0 auto;}
  .nc-edit:hover{color:var(--accent);}
  .act-row.nc-editing{cursor:default;border-color:var(--accent);}
  .nc-edit-form{display:flex;flex-direction:column;gap:6px;}
  .nc-edit-form .nc-e-url{width:100%;min-height:36px;padding:0 10px;
           border:1px solid var(--line-strong);border-radius:8px;background:var(--panel);color:var(--ink);}
  .nc-edit-form .nc-add-body{min-height:64px;}
  .nc-edit-actions{display:flex;gap:6px;justify-content:flex-end;}
  /* v12.115.0 — the edit window is deliberately user-resizable, with a compact Gmail-like
     toolbar shared by new-note composers and inline edits. */
  .nc-edit-form .nc-e-body{display:block;width:100%;min-height:130px;height:auto;max-height:none;
    flex:0 0 auto!important;resize:none;overflow:auto;box-sizing:border-box;}
  .nc-compose-body{flex:1;min-width:0;display:flex;flex-direction:column;}
  .nc-compose-body .nc-add-body{width:100%;box-sizing:border-box;}
  .nc-formatbar{display:flex;align-items:center;gap:2px;min-height:30px;padding:2px 4px;
    border:1px solid var(--line-strong);border-bottom:0;border-radius:8px 8px 0 0;background:#f7f9fc;}
  .nc-formatbar + .nc-add-body{border-radius:0 0 8px 8px;}
  .nc-formatbar button{min-width:27px;height:25px;padding:0 6px;border:0;border-radius:5px;
    background:transparent;color:var(--ink);font-size:12px;cursor:pointer;}
  .nc-formatbar button:hover{background:var(--accent-soft);color:var(--accent);}
  .nc-format-sep{width:1px;height:18px;background:var(--line-strong);margin:0 3px;}
  .nc-resize-grip{display:flex;align-items:center;justify-content:center;gap:5px;height:22px;
    border:1px solid var(--line-strong);border-top:0;border-radius:0 0 8px 8px;
    background:#f7f9fc;color:var(--muted);font-size:10.5px;font-weight:600;cursor:ns-resize;
    user-select:none;touch-action:none;}
  .nc-resize-grip:hover,.nc-resize-grip.dragging{background:var(--accent-soft);color:var(--accent);}
  .nc-formatbar + .nc-add-body{border-radius:0;}
  .act-date.overdue{color:var(--danger);font-weight:700;}
  .due-dot{width:11px;height:11px;border-radius:50%;background:var(--muted);flex:0 0 auto;}
  .due-dot.overdue{background:var(--danger);}
  .due-dot.today{background:#e6a700;}
  .btn.due-alert{background:var(--danger);border-color:var(--danger);color:#fff;}
  .seg-banner{
    position:absolute;left:50%;top:14px;transform:translateX(-50%);
    background:#0f5132;color:#fff;padding:8px 16px;border-radius:999px;
    font-size:14px;font-weight:600;box-shadow:var(--shadow);
  }
  .seg-banner a{color:#fff;text-decoration:underline;margin-left:6px;}
  .kpi{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:14px;}
  .kpi .card{flex:1;min-width:84px;background:var(--accent-soft);border-radius:10px;padding:10px 12px;}
  .kpi .card .v{font-size:22px;font-weight:800;line-height:1.1;}
  .kpi .card .l{font-size:12px;color:var(--muted);}
  .dash-section{margin-bottom:16px;}
  .dash-section h4{margin:0 0 6px;font-size:12px;color:var(--muted);text-transform:uppercase;letter-spacing:.4px;}
  .stat{display:flex;justify-content:space-between;align-items:center;padding:6px 0;border-bottom:1px dashed var(--line);}
  .stat .n{font-weight:700;}
  [hidden]{display:none !important;}
  @media (max-width:780px){
    aside#side{width:300px;flex-basis:300px;}
    .grid2{grid-template-columns:1fr;}
  }

/* -------------------- duplicate contacts -------------------- */
.dup-tools{display:flex;align-items:center;gap:14px;flex-wrap:wrap;margin:0 0 10px;font-size:14px;}
.dup-tools .dup-lbl{color:var(--muted);}
.dup-tools label{display:flex;align-items:center;gap:6px;cursor:pointer;}
.dup-note{font-size:13px;color:var(--muted);background:var(--bg);border:1px solid var(--line);border-radius:8px;padding:9px 11px;margin:0 0 10px;line-height:1.5;}
.dup-sum{font-weight:600;margin:0 0 8px;}
.dup-empty{padding:20px 4px;text-align:center;color:var(--muted);font-size:15px;}
#dup-clusters{display:flex;flex-direction:column;gap:12px;max-height:56vh;overflow:auto;padding-right:2px;}
.dup-card{border:1px solid var(--line);border-radius:10px;padding:10px 12px;background:var(--panel);}
.dup-head{display:flex;align-items:center;gap:10px;margin-bottom:8px;}
.dup-reason{font-size:13px;color:var(--muted);}
.dup-rows{display:flex;flex-direction:column;gap:6px;}
.dup-row{display:flex;align-items:flex-start;gap:10px;padding:8px 9px;border-radius:8px;cursor:pointer;border:1px solid transparent;}
.dup-row:hover{background:var(--bg);}
.dup-row input{margin-top:3px;}
.dup-row input:checked ~ .dup-keep{background:#3a63b8;color:#fff;}
.dup-keep{font-size:11px;text-transform:uppercase;letter-spacing:.04em;color:var(--muted);background:var(--bg);border:1px solid var(--line);border-radius:5px;padding:2px 7px;align-self:center;min-width:38px;text-align:center;}
.dup-body{display:flex;flex-direction:column;gap:2px;min-width:0;}
.dup-name{font-weight:600;color:var(--ink);}
.dup-facts{font-size:13px;color:var(--ink);opacity:.85;}
.dup-refs{font-size:12px;color:var(--muted);}
.dup-foot{margin-top:9px;text-align:right;}

/* -------------------- weight badge + priority matrix -------------------- */
.legend .wbadge{display:inline-flex;align-items:center;justify-content:center;width:14px;height:14px;font-size:14px;line-height:1;flex:0 0 auto;color:var(--ink);}
.matrix-wrap{overflow:auto;max-height:60vh;}
table.matrix{border-collapse:collapse;font-size:13px;width:100%;}
table.matrix th,table.matrix td{border:1px solid var(--line);padding:6px 8px;vertical-align:top;text-align:left;}
table.matrix thead th{position:sticky;top:0;z-index:1;background:var(--panel);white-space:nowrap;font-weight:600;}
table.matrix th.mx-corner{font-weight:600;color:var(--muted);white-space:nowrap;}
table.matrix tbody th.mx-rowh{white-space:nowrap;background:var(--panel);font-weight:600;}
table.matrix td.mx-cell{min-width:96px;}
table.matrix td.prio{background:rgba(224,69,44,.09);}
.mx-dot{display:inline-block;width:9px;height:9px;border-radius:50%;margin-right:6px;vertical-align:middle;}
.mx-chip{display:inline-block;background:var(--bg);border:1px solid var(--line-strong);border-radius:11px;padding:1px 8px;margin:2px 4px 0 0;cursor:pointer;font-size:12px;color:var(--ink);}
.mx-chip:hover{border-color:#3a63b8;color:#3a63b8;}
.mx-empty{color:var(--line-strong);}

/* -------------------- zones manager -------------------- */
#zone-list{display:flex;flex-direction:column;gap:8px;max-height:52vh;overflow:auto;}
.zone-row{display:flex;align-items:center;gap:6px;flex-wrap:wrap;}
.zone-row .zone-color{width:34px;height:30px;padding:0;border:1px solid var(--line);border-radius:6px;background:none;cursor:pointer;flex:0 0 auto;}
.zone-row .zone-name{flex:1 1 auto;min-width:0;}
.zone-row .zone-count{font-size:12px;color:var(--muted);white-space:nowrap;flex:0 0 auto;}
.zone-row .zone-vis{display:flex;align-items:center;gap:4px;font-size:12px;color:var(--muted);white-space:nowrap;flex:0 0 auto;cursor:pointer;}
.zone-row .zone-vis input{cursor:pointer;}
.zone-row .zone-unplaced{font-size:11px;color:var(--warn,#e67e22);border:1px solid var(--warn,#e67e22);
  border-radius:5px;padding:1px 6px;white-space:nowrap;flex:0 0 auto;}

/* hide vis-network's native hover tooltip — the custom .node-info popup replaces it */
.vis-tooltip{ display:none !important; }

/* -------------------- node right-click context menu -------------------- */
.ctx-menu{position:fixed;z-index:1000;min-width:190px;background:var(--panel);border:1px solid var(--line-strong);border-radius:10px;box-shadow:0 8px 28px rgba(0,0,0,.18);padding:5px;}
.ctx-head{font-size:12px;font-weight:700;color:var(--muted);padding:6px 10px 7px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:260px;}
.ctx-item{display:block;width:100%;text-align:left;background:none;border:0;border-radius:7px;padding:8px 10px;font-size:14px;color:var(--ink);cursor:pointer;}
.ctx-item:hover{background:var(--accent-soft,#eef3ff);}
.ctx-item.danger{color:var(--danger);}
.ctx-item.danger:hover{background:var(--danger-soft);}
.ctx-sep{height:1px;background:var(--line);margin:5px 6px;}


/* ================================================================
   v4.4.0 — refined-light redesign (token + component refresh layer)
   ================================================================ */
:root{
  --bg:#f2f5f9; --panel:#ffffff; --ink:#1b2530; --muted:#67737f;
  --line:#e3e8ef; --line-strong:#d3dae3;
  --accent:#3a63b8; --accent-ink:#ffffff; --accent-soft:#e8eef8;
  --danger:#d23b3b; --danger-soft:#fdecec; --ok:#189a55;
  --side-bg:#eef1f5;   /* v12.3.1 — the side/popup panel ground; the sticky popup header matches it */
  --field-ink:#1668e3;   /* v12.15.2 — a value in Preview. Bright blue, not navy: Costas asked for it
                            to separate from the grey label at a glance, and #123a6b read as near-black. */
  /* v12.76.0 — --card was USED in five rules and DEFINED nowhere, so every one of them fell back
     to no background at all: the Today/Home tab strip, the active tab, the sort select and both
     key-player card rules were transparent rather than white. Defining it is the fix for all
     five at once — every one of them was written expecting a white card. */
  --card:#ffffff;
  --radius:9px;
  --sp-1:4px; --sp-2:8px; --sp-3:12px; --sp-4:16px;   /* spacing scale (v4.9.1) */
  --shadow:0 1px 2px rgba(16,24,40,.05),0 1px 3px rgba(16,24,40,.07);
  --shadow-lg:0 4px 8px -2px rgba(16,24,40,.06),0 16px 32px -6px rgba(16,24,40,.14);
}
body{font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;font-size:16px;}

header.topbar{
  gap:8px;padding:9px 14px;background:var(--panel);
  border-bottom:1px solid var(--line);box-shadow:0 1px 2px rgba(16,24,40,.04);
  position:relative;z-index:60;
}
header .logo{font-size:19px;font-weight:700;letter-spacing:-.4px;}
header .ver{font-weight:600;border:1px solid var(--line);border-radius:99px;padding:1px 8px;margin-left:-2px;}
header .divider{width:1px;height:22px;background:var(--line);margin:0 4px;}

.btn{min-height:38px;padding:0 14px;font-weight:600;font-size:14px;border-radius:8px;
  transition:background .12s,border-color .12s,box-shadow .12s,transform .05s;}
.btn:active{transform:scale(.98);}
.btn-sm{min-height:34px;padding:0 12px;font-size:13.5px;}
.btn:focus-visible{outline:none;box-shadow:0 0 0 3px var(--accent-soft);border-color:var(--accent);}
.btn-primary:focus-visible{box-shadow:0 0 0 3px rgba(58,99,184,.35);}
.bi{width:16px;height:16px;flex:0 0 auto;}
.caret{font-size:10px;margin-left:2px;opacity:.7;}

.tb-menu{position:relative;display:inline-flex;}
.tb-menu-btn.open{background:#f0f3f8;border-color:var(--line-strong);}
.btn-primary.tb-menu-btn.open{background:#315499;}
.tb-drop{
  position:absolute;top:calc(100% + 6px);left:0;min-width:200px;
  background:var(--panel);border:1px solid var(--line);border-radius:10px;
  box-shadow:var(--shadow-lg);padding:6px;z-index:70;
}
.tb-drop-right{left:auto;right:0;}
.drop-item{
  display:flex;align-items:center;gap:10px;width:100%;text-align:left;
  border:0;background:transparent;border-radius:7px;padding:9px 10px;
  font-size:14px;font-weight:500;color:var(--ink);
}
.drop-item:hover{background:var(--accent-soft);color:#1c4fc0;}
.drop-item .bi{color:var(--muted);}

aside#side{background:var(--panel);box-shadow:1px 0 2px rgba(16,24,40,.03);}
.side-head{font-weight:600;letter-spacing:-.1px;}
.list-item{border-radius:8px;}
.list-item:hover{box-shadow:0 1px 2px rgba(16,24,40,.06);}

.detail-kv .k{font-size:11px;letter-spacing:.7px;text-transform:uppercase;color:var(--muted);font-weight:600;}

input,select,textarea{border-radius:8px;transition:border-color .12s,box-shadow .12s;}
input:focus,select:focus,textarea:focus{outline:none;border-color:var(--accent);box-shadow:0 0 0 3px var(--accent-soft);}

.modal-overlay{background:rgba(16,24,40,.45);backdrop-filter:blur(2px);}
.modal-card{border-radius:14px;box-shadow:var(--shadow-lg);border:1px solid var(--line);}
.modal-head{font-weight:600;letter-spacing:-.2px;border-bottom:1px solid var(--line);}

.legend{border-radius:12px;box-shadow:var(--shadow);backdrop-filter:blur(4px);}
.chip{border-radius:99px;}
.toast{border-radius:10px;box-shadow:var(--shadow-lg);font-weight:500;}

*{scrollbar-width:thin;scrollbar-color:#c6cdd6 transparent;}
*::-webkit-scrollbar{width:8px;height:8px;}
*::-webkit-scrollbar-thumb{background:#c6cdd6;border-radius:99px;}
*::-webkit-scrollbar-track{background:transparent;}


/* ============ v4.4.1 — sidebar density + Projop form ============ */
.side-head{padding:8px 12px;font-size:13px;}
.side-body{padding:8px 10px;}
.view-row{gap:4px;margin-bottom:6px;}
.view-row .btn,.view-row .btn-sm{min-height:26px;padding:0 9px;font-size:12px;border-radius:6px;}
.view-row select{min-height:26px;font-size:12.5px;padding:2px 6px;border-radius:6px;}
.side-body input,.side-body select{font-size:13px;min-height:28px;padding:4px 8px;}
#q{min-height:30px;}
#show-panel summary{font-size:11px;}
.tree-sec-h{font-size:10px;letter-spacing:.7px;margin:10px 0 4px;}
.org-row{padding:1px 6px;gap:5px;border-radius:6px;}
.org-row .nm{font-size:12.5px;font-weight:500;}
.org-row input[type=checkbox]{width:13px;height:13px;min-height:0;}
.zone-chips{gap:4px;}
.zone-chips .chip,.zone-chips button{font-size:11px;padding:2px 8px;min-height:0;}
.list-item{padding:2px 6px;margin-bottom:2px;}
.list-item .nm{font-size:12.5px;}

.modal-card:has(.pj-form){width:min(680px,94vw);max-width:94vw;}
/* v11.4.1: Costas — "i want the backround of the edit form pal[e] yellow and the editable fields
   white." Same tinted-backdrop pattern the Org (grey, #d5d9e0) and Contact (pale blue, #dce7f7)
   forms already use — .modal-body gets the tint, the actual inputs/selects/textareas stay an
   explicit white so the fields you type into always read as distinct from the backdrop. */
.modal-card:has(.pj-form) .modal-body{background:#f5f0c8;}
.pj-form .sec{border:1px solid var(--line);border-radius:10px;padding:10px 12px 6px;margin-bottom:10px;background:#fbfcfe;}
.pj-form .sec-t{font-size:10.5px;letter-spacing:.8px;text-transform:uppercase;color:var(--muted);font-weight:600;margin-bottom:8px;}
/* v6.0.0: label-left/field-right, one field per row — same general layout already used on the
   Organization/Contact forms (v5.3.0/v5.4.0), adopted here too per Costas' explicit ask. Replaces
   the old side-by-side .grid2 field pairs — every field now stacks full-width. */
.pj-form .field{display:grid;grid-template-columns:120px 1fr;column-gap:10px;align-items:center;margin-bottom:6px;}
.pj-form .field label{margin:0;font-size:11.5px;font-weight:600;color:var(--muted);}
.pj-form input,.pj-form select,.pj-form textarea{min-height:30px;font-size:13px;padding:4px 9px;width:100%;background:#fff;}
.pj-form textarea{min-height:64px;}
.pj-form .grid2{display:block;}
.pj-form .money-row{display:flex;gap:6px;}
/* v9.5.1: Hot + Archive, one compact row instead of two full-width sentence rows. */
.pj-flags{display:flex;gap:14px;}
.pj-flag{display:flex;align-items:center;gap:5px;margin:0;font-size:12.5px;font-weight:500;color:var(--ink);cursor:pointer;}
.pj-flag input{min-height:0;width:14px;height:14px;padding:0;flex:0 0 auto;}
.pj-form .money-row input:first-child{flex:1;}
.pj-form .money-row input:last-child{width:64px;flex:0 0 auto;}
/* v6.0.0's open-ended Parties list (.pj-party-row etc.) lived only in the old Edit-form's
   Players tab, deleted at v11.0.0 — Stakeholders now has exactly one renderer, the workspace's
   own renderDealStakeholders()/.stake-row (see below), so these rules had no element left to
   style and were removed rather than kept as dead weight. */

/* v4.5.1 — active Projop highlight (the dropdown selector is gone) */
.projop-row.active-view{border-color:var(--accent);background:var(--accent-soft);}
.projop-row .badge{font-size:9px;padding:1px 7px;}

/* v4.5.3 — org rows: kill the fat expander button, clamp row height */
.org-toggle{
  min-height:0;height:16px;width:16px;padding:0;border:0;background:transparent;
  font-size:10px;line-height:16px;color:var(--muted);border-radius:4px;flex:0 0 auto;
}
.org-toggle:hover:not(:disabled){background:var(--accent-soft);color:var(--accent);}
.org-row{min-height:22px;padding:0 6px;margin-bottom:2px;}
.org-row .nm{font-size:12px;line-height:1.35;}
.org-count{font-size:10.5px;min-width:14px;}
.org-row input[type=checkbox],.org-selall{width:12px;height:12px;min-height:0;margin:0;}
.org-row .row-hide{padding:1px 5px;font-size:10.5px;}
.org-row .mark{width:9px;height:9px;}
.list-item{min-height:22px;}

/* ============ v4.5.4 — white canvas, pale chrome, hover-tint buttons ============ */
#graph-wrap{background:#f7f8fb;}
header.topbar{background:#dde2ea;}
aside#side{background:#dde2ea;box-shadow:none;border-right:1px solid var(--line);}
.side-head{border-bottom:1px solid var(--line);}
.btn{background:#fff;}
.btn:hover{background:var(--accent-soft);border-color:#b9cdf8;color:#1c4fc0;}
.btn:hover .bi{color:#1c4fc0;}
.btn-ghost{background:transparent;}
.btn-ghost:hover{background:var(--accent-soft);color:#1c4fc0;}
.btn-primary{background:var(--accent);color:#fff;}
.btn-primary:hover{background:#315499;border-color:#315499;color:#fff;}
/* v4.8.4: re-assert btn-danger's solid red fill — the generic .btn{background:#fff} rule
   above (v4.5.4) sits later in the cascade than .btn-danger's original color rule, so it was
   silently winning and leaving delete buttons looking like an empty box with just a red
   border (Costas screenshot: Projop panel's Delete button). Same fix pattern as .btn-primary. */
.btn-danger{background:var(--danger);border-color:var(--danger);color:#fff;}
.btn-danger:hover{background:#b83232;border-color:#b83232;color:#fff;}
.tb-menu-btn.open{background:var(--accent-soft);border-color:#b9cdf8;color:#1c4fc0;}
.btn-primary.tb-menu-btn.open{background:#315499;color:#fff;}

/* ============ v4.6.1 -- org/group rows white (stand out from pale sidebar);
   Contact Groups rows now match Organizations compact style ============ */
.org-row,.group-row{background:var(--panel);}
/* v5.9.0: Costas wants these arrows as big as the "Show on canvas" native disclosure
   triangle at the top of the sidebar — was shrunk back down to 16px/10px in v5.1.0 to match
   Contact Groups' own compact row height; sized back up now, same 28px/18px this row type
   already used once before (v4.11.1). */
.group-toggle{
  min-height:0;height:28px;width:28px;padding:0;border:0;background:transparent;
  font-size:18px;line-height:28px;color:var(--muted);border-radius:6px;flex:0 0 auto;
  display:flex;align-items:center;justify-content:center;cursor:pointer;
}
.group-toggle:hover{background:var(--accent-soft);color:var(--accent);}
.group-row{min-height:22px;padding:0 6px;margin-bottom:2px;}
.group-row .nm{font-size:12px;font-weight:500;line-height:1.35;}
.group-count{font-size:10.5px;min-width:14px;}
.group-row .mark{width:9px;height:9px;}

/* v4.7.0 -- rename affordance on a Contact Groups row (groups are a real table now) */
.group-rename{flex:0 0 auto;font-size:12px;color:var(--muted);text-decoration:none;padding:1px 4px;border-radius:5px;}
.group-rename:hover{background:var(--accent-soft);color:var(--accent);}

/* ============ v5.3.0/v5.4.0 — Organization + Contact edit forms: 4/3 tabs,
   label-left/field-right, tinted backdrop, condensed sizing (Costas' explicit ask). Shared
   structural rules cover both `.org-form` (grey backdrop) and `.contact-form` (pale blue
   backdrop, v5.4.0) — only the backdrop color and modal width differ between the two, kept
   as separate rules right below so each form's own block stays easy to find. ============ */
.modal-card:has(.org-form){width:min(600px,94vw);max-width:94vw;}
/* v12.80.0 — ONE tint for "you are editing", across all three forms. Costas asked for the
   organization form to be pale yellow "like for the contacts"; contacts were pale blue and only
   the Projop form was yellow, so he was asked which he meant and chose yellow everywhere. The
   fields themselves stay explicitly white, which is the whole point of the tinted backdrop. */
.modal-card:has(.org-form) .modal-body{background:#f5f0c8;}
.modal-card:has(.contact-form){width:min(600px,94vw);max-width:94vw;}
/* v12.131.0 — Costas: "is there a reason this popup is so small? make it same size as the othe
   redit popups". There was no reason: .org-form and .contact-form each opt into a width here and
   .stake-form never did, so Edit stakeholder fell back to the 520px default while its neighbours
   sat at 600-700. It now takes the same 600px as the contact form it most resembles. */
.modal-card:has(.stake-form){width:min(600px,94vw);max-width:94vw;}
.modal-card:has(.contact-form) .modal-body{background:#f5f0c8;}
.org-form .of-tabs,.contact-form .of-tabs{display:flex;gap:2px;margin:0 0 12px;border-bottom:1px solid var(--line-strong);}
.org-form .of-tab-btn,.contact-form .of-tab-btn{background:none;border:none;padding:7px 12px;font-size:12.5px;font-weight:600;
  color:var(--muted);cursor:pointer;border-bottom:2px solid transparent;margin-bottom:-1px;}
.org-form .of-tab-btn.active,.contact-form .of-tab-btn.active{color:var(--ink);border-bottom-color:var(--accent);}
.org-form .of-tab-panel,.contact-form .of-tab-panel{display:none;}
.org-form .of-tab-panel.active,.contact-form .of-tab-panel.active{display:block;}
/* every field row: label fixed-width on the left, the actual control filling the rest on the
   right — applies to plain inputs/selects/textareas and to the custom-field rows generated by
   customFieldsHtml() (also just a plain .field), so nothing there needed its own override. */
.org-form .field,.contact-form .field{display:grid;grid-template-columns:120px 1fr;column-gap:10px;align-items:center;margin-bottom:6px;}
.org-form .field label,.contact-form .field label{margin:0;font-size:11.5px;font-weight:600;color:var(--muted);}
.org-form .field .hint,.contact-form .field .hint{grid-column:2;font-size:10.5px;margin-top:2px;color:var(--muted);}
.org-form .field input,.org-form .field select,.org-form .field textarea,
.contact-form .field input,.contact-form .field select,.contact-form .field textarea{
  min-height:28px;padding:4px 8px;font-size:12.5px;background:#fff;width:100%;}
.org-form .field textarea,.contact-form .field textarea{min-height:50px;}
.pjl-how{display:block;font-size:10.5px;color:var(--muted);font-weight:400;margin-top:1px;}
.org-projops{margin:2px 0 10px;}
.org-form .grid2,.contact-form .grid2{display:block;}   /* was side-by-side field pairs — now every field stacks full-width label-left/value-right */
.org-form .org-quick-add,.contact-form .org-quick-add{grid-column:2;margin-left:0;margin-top:6px;}
.org-form .img-edit,.contact-form .img-edit{grid-column:2;}
.org-form .field:has(.img-edit),.org-form .field:has(datalist),
.contact-form .field:has(.img-edit),.contact-form .field:has(datalist){margin-bottom:6px;}
/* v5.3.1: AI summary/Notes get more room and a touch bigger text than the rest of the
   condensed form — Costas: "more space for AI-official profile and Notes... a little bigger
   so its easier to read". A modifier on the shared .field grid, not a new layout. */
.org-form .field.big-text textarea,.contact-form .field.big-text textarea{min-height:110px;font-size:13.5px;line-height:1.45;}
/* v12.82.0 — Organization editor cleanup. The old 600px shell forced the logo file input and
   two buttons into an untidy wrap, while the generic `.field label` rule also styled the nested
   Archived checkbox label and produced the large duplicated label seen in Costas' screenshot.
   Keep this scoped to the organization form: the contact editor has different controls. */
.modal-card:has(.org-form){width:min(700px,94vw);}
.modal-card:has(.org-form) .modal-head{padding:15px 20px;font-size:19px;font-weight:700;}
.modal-card:has(.org-form) .modal-body{padding:14px 20px 16px;}
.modal-card:has(.org-form) .modal-foot{padding:11px 20px;gap:8px;}
.modal-card:has(.org-form) .modal-foot .btn{min-height:34px;padding:0 13px;font-size:13px;}
.org-form .of-tabs{gap:4px;margin-bottom:14px;}
.org-form .of-tab-btn{padding:6px 10px;font-size:12px;}
.org-form .field{grid-template-columns:108px minmax(0,1fr);column-gap:14px;align-items:center;margin-bottom:8px;}
.org-form .field>label{font-size:11px;line-height:1.25;font-weight:650;letter-spacing:.01em;}
.org-form .field input,.org-form .field select,.org-form .field textarea{min-height:32px;padding:5px 9px;font-size:12.5px;}
.org-form .field.big-text textarea{min-height:92px;font-size:12.5px;line-height:1.4;}
.org-form .of-ai-editor{grid-column:2;display:flex;flex-direction:column;align-items:flex-start;gap:6px;min-width:0;}
.org-form .of-ai-editor textarea{width:100%;}
.org-form .of-ai-editor .btn{min-height:28px;padding:0 10px;font-size:11.5px;}
.org-form .of-projops-field{align-items:start;margin-top:14px;padding-top:12px;border-top:1px solid rgba(103,115,127,.22);}
.org-form .of-projops-field .pjl-links{gap:5px;margin:0;}
.org-form .of-projops-field .pjl-open{display:block;padding:6px 8px;border:1px solid rgba(58,99,184,.18);
  border-radius:7px;background:rgba(255,255,255,.72);font-size:12px;font-weight:550;line-height:1.25;}
.org-form .of-projops-field .pjl-open:hover{border-color:rgba(58,99,184,.45);background:#fff;text-decoration:none;}
.org-form /* v12.134.0 — the Projop's own report buttons, directly under the hero. An action row, sitting
   apart from the fields below it so it never reads as one. */
.pj-report-row{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:0 0 12px;}
.pj-report-row .btn{font-weight:600;}
.pj-report-dialog .rb-dates{display:flex;gap:8px;margin-top:6px;}

/* v12.133.0 — a company's identity line: Category on the left, its two links as icons, Status on
   the right. One row, so the three facts you check before opening a company read together. */
.org-idrow{display:flex;align-items:center;gap:14px;flex-wrap:wrap;}
.org-idrow > .pjb-sec{margin-bottom:0;flex:0 1 auto;min-width:0;}
.org-link-icos{display:inline-flex;align-items:center;gap:6px;flex:0 0 auto;}
.org-link-ico{display:inline-flex;align-items:center;justify-content:center;width:24px;height:24px;
  border-radius:6px;border:1px solid var(--line);text-decoration:none;}
.org-link-ico svg{width:15px;height:15px;}
.org-link-ico.on{color:var(--accent);border-color:#bcd2f2;background:#eef4fd;}
.org-link-ico.on:hover{background:#dde9fb;border-color:var(--accent);}
/* Grey and inert when there is nothing to open — the icon still appears, because "no LinkedIn
   on file" is worth knowing and an empty space says nothing. */
.org-link-ico.off{color:#b6c0cc;background:var(--panel);cursor:default;}
.org-link-in{font-size:11px;font-weight:800;letter-spacing:-.02em;line-height:1;}

.of-profile-divider{margin:14px 0 10px;padding-top:10px;border-top:1px solid rgba(103,115,127,.22);
  color:var(--muted);font-size:10px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;}
.org-form .field .of-archive-check{grid-column:2;display:inline-flex;align-items:center;justify-self:start;gap:8px;
  margin:0;padding:6px 9px;border:1px solid var(--line-strong);border-radius:7px;background:rgba(255,255,255,.72);
  color:var(--ink);font-size:11.5px;font-weight:500;cursor:pointer;}
.org-form .field .of-archive-check input{width:14px;height:14px;min-height:0;margin:0;padding:0;accent-color:var(--accent);}
.org-form .of-archive-check span{display:flex;align-items:baseline;gap:7px;}
.org-form .of-archive-check b{font-size:11.5px;font-weight:650;}
.org-form .of-archive-check small{font-size:10.5px;color:var(--muted);font-weight:400;}
.org-form #o-logo-wrap{grid-column:2;display:grid;grid-template-columns:52px minmax(150px,1fr) auto auto;
  grid-template-rows:auto auto;gap:7px 8px;align-items:center;min-width:0;}
.org-form .org-logo-preview{grid-column:1;grid-row:1 / span 2;position:relative;width:52px;height:52px;
  display:flex;align-items:center;justify-content:center;border:1px solid var(--line-strong);border-radius:8px;background:#fff;overflow:hidden;}
.org-form .org-logo-placeholder{display:flex;color:#8a98a8;}
.org-form .org-logo-placeholder svg{width:22px;height:22px;}
.org-form #o-logo-wrap .org-logo-preview img{position:absolute;inset:0;width:100%;height:100%;margin:0;padding:4px;
  border:0;border-radius:0;object-fit:contain;background:#fff;}
.org-form #o-logo-file{grid-column:2;grid-row:1;min-width:0;width:100%;padding:0;font-size:11px;background:transparent;}
.org-form #o-logo-file::file-selector-button{min-height:28px;margin-right:7px;padding:0 9px;border:1px solid var(--line-strong);
  border-radius:7px;background:#fff;color:var(--ink);font:600 11px/1 inherit;cursor:pointer;}
.org-form #o-logo-fetch,.org-form #o-logo-clear,.org-form #o-logo-size-reset{min-height:29px;padding:0 10px;font-size:11.5px;}
.org-form #o-logo-paste{grid-column:2 / -1;grid-row:2;min-height:29px;padding:4px 8px;font-size:11.5px;}
.org-form .of-logo-size-field{align-items:start;}
.org-form .logo-size-row{grid-column:2;width:100%;gap:8px;}
.org-form .logo-size-row .logo-size-val{min-width:42px;font-size:11.5px;}
.org-form .of-logo-size-field .hint{font-size:10px;margin-top:3px;}
@media(max-width:640px){
  .org-form .field{grid-template-columns:1fr;row-gap:4px;}
  .org-form .field>*{grid-column:1!important;}
  .org-form #o-logo-wrap{grid-template-columns:48px minmax(120px,1fr) auto;}
  .org-form #o-logo-clear{grid-column:3;grid-row:2;}
  .org-form #o-logo-paste{grid-column:2 / 3!important;}
}
/* v5.3.1/v5.4.0: read-only "Projop-specific roles" list under Default role — one line per
   Projop this org/contact has a deal_roles override in, click to jump to that Projop
   (openProjop()). */
/* v7.8.0: Contact form's Core-tab "Projops" field is now just a plain list of which Projops
   this contact is placed on the canvas of — no notes here (those moved to the Log tab,
   grouped by Projop — see .cl-* below — and are added via the central "+ Add note" button,
   see .of-add-note below). */
.pjl-links{grid-column:2;display:flex;flex-direction:column;gap:2px;margin-top:2px;}
.pjl-open{font-size:12.5px;color:var(--accent);text-decoration:none;cursor:pointer;}
.pjl-open:hover{text-decoration:underline;}
/* v12.83.0 — multi-Projop membership editor shared by organization and contact forms. */
.pmp-current,.projop-membership-picker{grid-column:2;min-width:0;}
.pmp-current{margin-bottom:7px;}
.projop-membership-picker{overflow:hidden;border:1px solid var(--line-strong);border-radius:8px;background:rgba(255,255,255,.7);}
.pmp-toolbar{display:flex;align-items:center;gap:8px;padding:6px;border-bottom:1px solid var(--line);}
.pmp-key-toolbar{justify-content:space-between;background:rgba(47,109,246,.045);}
.pmp-key-label{color:var(--muted);font-size:10.5px;font-weight:750;text-transform:uppercase;letter-spacing:.04em;}
.org-form .field .pmp-toolbar .pmp-search,.contact-form .field .pmp-toolbar .pmp-search{
  flex:1;min-width:0;width:auto;min-height:28px;padding:4px 8px;font-size:11.5px;}
.pmp-count{flex:0 0 auto;color:var(--muted);font-size:10.5px;font-weight:650;white-space:nowrap;}
.pmp-list{max-height:168px;overflow:auto;padding:3px;scrollbar-gutter:stable;}
.pmp-empty{padding:7px 8px;color:var(--muted);font-size:11px;font-style:italic;}
.projop-membership-picker .pmp-option{display:grid;grid-template-columns:16px minmax(0,1fr) auto;
  align-items:center;gap:7px;margin:0;padding:5px 6px;border-radius:5px;color:var(--ink);font-size:11.5px;font-weight:500;cursor:pointer;}
.projop-membership-picker .pmp-option:hover{background:var(--accent-soft);}
.projop-membership-picker .pmp-option[hidden]{display:none;}
.projop-membership-picker .pmp-option .pmp-check{
  width:14px;height:14px;min-height:0;margin:0;padding:0;accent-color:var(--accent);}
.pmp-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.pmp-badge{padding:1px 5px;border-radius:999px;background:#edf0f3;color:var(--muted);font-size:9.5px;font-weight:650;}
.pmp-other{position:relative;padding:6px;border-top:1px solid var(--line);}
.org-form .field .pmp-other .pmp-search,.contact-form .field .pmp-other .pmp-search{width:100%;min-height:28px;padding:4px 8px;font-size:11.5px;}
.pmp-search-list{position:absolute;z-index:4;left:6px;right:6px;top:39px;max-height:142px;overflow:auto;border:1px solid var(--line-strong);border-radius:6px;background:#fff;box-shadow:0 5px 14px rgba(25,42,70,.16);}
.pmp-search-option{display:block;width:100%;min-height:0;padding:7px 8px;border:0;border-bottom:1px solid var(--line);background:#fff;color:var(--ink);text-align:left;font-size:11.5px;cursor:pointer;}
.pmp-search-option:hover{background:var(--accent-soft);}
.pmp-search-option[hidden]{display:none;}
.pmp-extras{display:flex;flex-wrap:wrap;gap:4px;margin-top:5px;}
.pmp-extra{display:inline-flex;align-items:center;gap:4px;max-width:100%;padding:3px 4px 3px 7px;border:1px solid #b9cdf6;border-radius:999px;background:#f3f7ff;color:#2856a7;font-size:10.5px;}
.pmp-extra-remove{width:16px;min-height:16px;padding:0;border:0;border-radius:50%;background:transparent;color:#5e7191;font-size:15px;line-height:14px;cursor:pointer;}
.pmp-extra-remove:hover{background:#d9e7ff;color:#1f4c99;}
.org-form .field .projop-membership-picker>.hint,.contact-form .field .projop-membership-picker>.hint{
  display:block;grid-column:auto;margin:0;padding:6px 8px;border-top:1px solid var(--line);font-size:10px;line-height:1.35;}
@media(max-width:640px){
  .pmp-current,.projop-membership-picker{grid-column:1;}
}
/* The single entry point for every new note (Costas: "all notes should be added via a
   central + button") — sits in the tab row, level with the tab labels, pushed to the right
   via margin-left:auto so it doesn't need a change to the shared .of-tabs container (which
   the Organization form's tab row also uses and was not part of this request). */
.of-add-note{margin-left:auto;flex:0 0 auto;align-self:center;min-height:26px;padding:0 10px;border:1px solid var(--line-strong);border-radius:7px;background:#fff;color:var(--ink);font-size:11.5px;font-weight:600;cursor:pointer;}
.of-add-note:hover:not(:disabled){border-color:var(--accent);color:var(--accent);}
.of-add-note:disabled{opacity:.5;cursor:default;}
/* Contact form's Log tab (v7.8.0) — grouped into one section per Projop, condensed and
   zebra-striped rows (date / body / delete), read-only here besides delete — adding goes
   through .of-add-note above. */
.cl-wrap{display:flex;flex-direction:column;gap:8px;}
.cl-block{border:1px solid var(--line);border-radius:8px;padding:8px 10px;background:#fff;}
.cl-head{margin-bottom:4px;}
.cl-head .cl-open{font-weight:600;font-size:12.5px;color:var(--accent);text-decoration:none;cursor:pointer;}
.cl-head .cl-open:hover{text-decoration:underline;}
.cl-note{display:flex;align-items:baseline;gap:6px;padding:4px 6px;border-radius:5px;font-size:12.5px;}
.cl-note:nth-child(even){background:var(--bg);}
.cl-note-d{flex:0 0 auto;color:var(--muted);font-size:11px;white-space:nowrap;}
.cl-note-body{flex:1;min-width:0;word-break:break-word;}
.cl-note-body .act-sum{margin:0;font-size:12.5px;}
.cl-note-x{flex:0 0 auto;border:none;background:transparent;color:var(--muted);cursor:pointer;padding:0 2px;font-size:13px;line-height:1;}
.cl-note-x:hover{color:var(--danger);}
/* Central "Add note" picker (v7.8.0) — type + scope selects, then whichever type-specific
   fields apply. Reuses the plain .field layout the rest of this form uses. */
.an-form select,.an-form input,.an-form textarea{width:100%;}
.an-form textarea{min-height:60px;}
.an-form input[type=file]{padding:4px 0;}
/* v5.5.0: Contact form's "Info" tab — a mixed notes/hyperlinks/images/doc-links shelf
   (contact_info_items). Reuses .act-row/.act-head/.act-d/.act-sum/.stake-x for individual
   items (same look as the Log/Activities lists elsewhere in this app). */
.ci-add-wrap{display:flex;flex-direction:column;gap:6px;}
.ci-add-wrap select{min-height:34px;}
.ci-add-wrap textarea{min-height:60px;}
.ci-add-wrap input[type=file]{padding:4px 0;}
.ci-link{font-size:12.5px;color:var(--accent);word-break:break-all;}
.ci-thumb{max-width:100%;max-height:180px;border-radius:6px;display:block;margin-top:4px;}
.ci-caption{font-size:11.5px;color:var(--muted);margin-top:3px;}
/* Org form's Contacts tab — plain read-only rows, click opens that contact's own edit form */
/* v12.129.0 — Costas, on a company with 15 people in one level: "i want the contacts more
   condensed simple rows with alternating color backround". Each row was its own bordered,
   rounded card with a 5px gap under it, so fifteen people needed a great deal of scrolling to
   say very little. The box moves OUT to the list (one border around the group, below) and the
   rows become plain lines with zebra striping — which is what a card's border was doing badly:
   telling you where one person ends and the next begins. */
.of-contact-row{display:flex;align-items:center;gap:8px;padding:3px 8px;border:0;border-radius:0;
  margin:0;cursor:pointer;background:transparent;font-size:12px;min-height:26px;}
.of-contact-row:nth-child(even){background:#f2f6fb;}
.of-contact-row:hover{background:#e4edfa;}
.of-contact-row .nm{font-weight:600;flex:1;}
.of-contact-row .sub{color:var(--muted);font-size:11.5px;}
/* v12.129.0 — 30px was a card's portrait; on a 26px line it IS the line. 20px matches the
   Players list, which settled the same question in v12.10.0. */
.of-contact-avatar{width:20px;height:20px;border-radius:50%;object-fit:cover;flex:0 0 20px;background:#edf3fb;color:#5c7da6;}
.of-contact-avatar.fallback{display:flex;align-items:center;justify-content:center;}
.of-contact-avatar.fallback svg{width:13px;height:13px;}
.of-contact-copy{display:flex;flex:1 1 auto;min-width:0;align-items:baseline;gap:10px;}
.of-contact-row .of-contact-copy .nm{flex:none;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.of-contact-row .of-contact-title{display:block;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
/* v12.129.0 — the pencil. Muted until you are on the row, so fifteen of them do not read as
   fifteen buttons; margin-left:auto pushes it (and the controls after it) to the right end. */
/* v12.132.0 — no margin-left:auto any more: the pencil sits immediately after the avatar, and
   .of-contact-projop-controls keeps the right-hand corner to itself. */
.of-contact-edit{flex:0 0 auto;border:0;background:transparent;cursor:pointer;
  color:var(--muted);font-size:13px;line-height:1;padding:2px 5px;border-radius:5px;opacity:.5;
  transition:opacity .12s,color .12s,background .12s;}
.of-contact-row:hover .of-contact-edit{opacity:1;}
.of-contact-edit:hover{color:var(--accent);background:#dce8f8;opacity:1;}
.of-contact-projop-controls{display:flex;align-items:center;justify-content:flex-end;gap:12px;flex:0 0 auto;margin-left:auto;}
.of-contact-projop-controls label{display:inline-flex;align-items:center;gap:4px;color:var(--ink);font-size:11px;font-weight:600;cursor:pointer;white-space:nowrap;}
.of-contact-projop-controls input[type=checkbox]{width:14px;height:14px;min-height:0;margin:0;padding:0;accent-color:var(--accent);}
.of-contact-projop-controls input[type=checkbox]:disabled{cursor:default;opacity:1;filter:none;}
.of-contact-projop-controls label:has(input:disabled){color:var(--ink);cursor:default;opacity:1;}
.of-contact-levels{display:flex;flex-direction:column;gap:12px;}
.of-contact-level{min-width:0;}
.of-contact-level-head{display:flex;align-items:center;justify-content:space-between;padding:0 2px 5px;
  border-bottom:2px solid #9db8e2;color:#4676b8;font-size:11px;font-weight:700;letter-spacing:.045em;text-transform:uppercase;}
.of-contact-level-count{min-width:22px;padding:1px 7px;border-radius:999px;background:#e8f0fb;color:#476f9f;
  font-size:10.5px;text-align:center;}
/* v12.129.0 — ONE box around the group rather than one per person: no gaps between rows, so the
   stripes run continuously, and overflow:hidden lets the first and last rows take the rounded
   corners without each row needing its own radius. */
.of-contact-level .of-contact-list{display:flex;flex-direction:column;gap:0;margin-top:5px;
  border:1px solid var(--line);border-radius:7px;overflow:hidden;background:#fff;}
.of-contact-level-empty{padding:6px 8px;color:var(--muted);font-size:11.5px;font-style:italic;}

/* ================= v4.9.2 — quieter / more professional chrome ================= */
/* Softer danger button (was a loud solid red block) */
.btn-danger{background:var(--danger-soft);border-color:#ecc2c2;color:#b23530;box-shadow:none;}
.btn-danger:hover{background:#f6d6d6;border-color:#e0a6a6;color:#9c2a26;}
.btn-danger .bi{color:inherit;}
/* Slimmer buttons; calm, neutral hover for secondary buttons (no blue-wash) */
.btn{min-height:32px;padding:0 12px;font-size:13.5px;box-shadow:none;}
.btn-sm{min-height:29px;padding:0 10px;font-size:13px;}
.btn:not(.btn-primary):not(.btn-danger):hover{background:#f3f5f9;border-color:var(--line-strong);color:var(--ink);}
.btn:not(.btn-primary):not(.btn-danger):hover .bi{color:var(--muted);}
/* Quieter pills — smaller and lighter (colour kept for meaning) */
.badge{font-size:11.5px;font-weight:600;padding:2px 9px;}
/* Denser Projop / details panel */
.detail-actions{margin-top:12px;gap:6px;}
.pj-tabs{margin:14px 0 0;}
.pj-tab-btn{padding:6px 12px;font-size:12.5px;}
.stake-row{padding:5px 8px;margin-bottom:5px;}

/* v4.9.3 — soft-tinted informational pills (light background + coloured text) */
.badge.soft{
  background:#eef1f5;
  background:color-mix(in srgb, var(--pc,#64748b) 14%, #fff);
  color:var(--pc,#475569);
  border:1px solid #dfe4ea;
  border-color:color-mix(in srgb, var(--pc,#64748b) 32%, #fff);
  font-weight:600;
}

/* ============ v4.10.1 — buttons: clear outline, discreet hover, obvious press ============ */
/* Costas: after the v4.9.1-4.9.3 "quieter chrome" passes, plain buttons' borders faded to
   var(--line-strong) (#d3dae3) — nearly invisible against the white/pale panels — and the only
   pressed-state feedback was a tiny scale(.98). Wants every button to read as clearly clickable:
   a real, visible outline at rest, a subtle (not garish) hover, and a press that's obviously
   different from hover, not just a smaller version of it. Consolidated here at the end of the
   cascade rather than reworking every earlier pass — same "re-assert last" pattern already used
   above for .btn-danger/.btn-primary. */
.btn{border-width:1.5px;border-color:#93a1b3;}
.btn-ghost{background:#fff;border-color:#93a1b3;}
.btn-primary{border-color:#28417a;}
.btn-danger{border-color:#e3a8a8;}
.tb-menu-btn.open{border-color:var(--accent);}

.btn:not(.btn-primary):not(.btn-danger):hover{background:color-mix(in srgb, var(--accent) 20%, #fff);border-color:var(--accent);}
.btn-ghost:hover{background:color-mix(in srgb, var(--accent) 20%, #fff);border-color:var(--accent);color:#1c4fc0;}
.btn-primary:hover{border-color:#1f3562;}
.btn-danger:hover{border-color:#d68f8f;}

/* Pressed/active — a clearly different shade + edge, on top of the existing scale-down. */
.btn:active{transform:scale(.97);}
.btn:not(.btn-primary):not(.btn-danger):active{background:var(--accent);border-color:var(--accent);color:#fff;}
.btn-ghost:active{background:var(--accent);border-color:var(--accent);color:#fff;}
.btn-primary:active{background:#24407a;border-color:#16264a;}
.btn-danger:active{background:#f2c6c6;border-color:#c97c7c;color:#8f2424;}

/* ============ v5.0.4 — Organizations grouped by type in the sidebar ============ */
/* One collapsible section per org type (Hotel/Chain/Group/Vendor/Partner/Other), each with its
   own expand/collapse state (orgTypeOpen in js/ui.js) — styled to match Contact Groups'
   .group-branch/.group-row look (bordered row, accent hover/expanded ring) for a consistent
   sidebar feel; the per-type show/hide checkbox row was removed per Costas' request, so every
   type with organizations always gets a section, collapsed by default. Arrow kept at the bigger
   28px size (Costas' prior explicit request) rather than matching Contact Groups' smaller one. */
.org-type-sec{margin-bottom:2px;}
.org-type-h{
  display:flex;align-items:center;gap:6px;padding:0 6px;min-height:22px;margin-bottom:2px;
  border:1px solid var(--line);border-radius:6px;cursor:pointer;background:var(--panel);
  transition:border-color .1s,background .1s;line-height:1.4;
}
.org-type-h:hover{border-color:var(--accent);background:var(--accent-soft);}
.org-type-h .nm{flex:1;min-width:0;font-size:12px;font-weight:500;line-height:1.35;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.org-type-h .mark{width:9px;height:9px;border-radius:50%;flex:0 0 auto;}
.org-type-sec.expanded .org-type-h{border-color:var(--accent);background:var(--accent-soft);box-shadow:0 0 0 1px var(--accent);}
/* v4.11.1: bigger, easier-to-hit arrow (Costas) — was 20px/11px, hard to spot/click. */
.org-type-toggle{
  width:28px;height:28px;flex:0 0 auto;border:none;background:none;cursor:pointer;
  color:var(--muted);font-size:18px;font-weight:700;border-radius:6px;display:flex;align-items:center;justify-content:center;
}
.org-type-toggle:hover{background:var(--accent-soft);color:var(--accent);}
.org-type-sec.expanded .org-type-toggle{color:var(--accent);}
.org-type-body{padding-left:26px;margin-top:2px;}
/* v5.0.6: quick inline rename, same affordance/style as Contact Groups' .group-rename. */
.org-type-rename{flex:0 0 auto;font-size:12px;color:var(--muted);text-decoration:none;padding:1px 4px;border-radius:5px;}
.org-type-rename:hover{background:var(--accent-soft);color:var(--accent);}
/* v5.7.0: "Add/edit/remove roles…" link next to the Default role dropdown (Contact + Org
   forms) — same quick-link affordance as .group-rename/.org-type-rename above. */
.manage-roles-link{display:inline-block;margin-top:4px;font-size:12px;color:var(--muted);text-decoration:none;padding:1px 4px;border-radius:5px;}
.manage-roles-link:hover{background:var(--accent-soft);color:var(--accent);}

/* ============ v5.1.0 -- redo of v5.0.9, per Costas: ONE shared color for ALL
   Organization Type buttons, a DIFFERENT shared color for ALL Contact Group buttons,
   and a DIFFERENT color for EACH Zone (that part of v5.0.9 was already right — zones
   already have their own real .color field). v5.0.9 wrongly gave every individual org
   type AND every individual group its own hue — overcorrecting v5.0.8's real bug (low
   contrast) into "different colors" at the wrong granularity. Also: the 3 states are
   now literally white(rest) -> pale(hover) -> solid(pressed/active/expanded), not
   pale-at-rest the way v5.0.9 had it — same state model now applied to every other
   plain button in the app too (see the v4.10.1 block above, reworked from a neutral
   grey hover/press to this same blue). Header/sidebar background also bumped to a
   clearly-visible pale grey (#e7ebf1, was #f3f6fa — too close to white to read as
   intentional; Costas flagged this had been missed). */
/* v5.9.0: matches .group-toggle's size bump above — same "as big as Show on canvas" ask. */
.org-type-toggle{width:28px;height:28px;font-size:18px;line-height:28px;border-radius:6px;}

.org-type-h{--pc:#0f8a82;}   /* one shared teal for every Organization Type row */
.group-row{--pc:#3a63b8;}    /* one shared blue for every Contact Group row (== --accent) */

.group-row,.org-type-h,.zone-chip{
  background:#fff;border-color:var(--line);
  transition:background .1s,border-color .1s;
}
.group-row:hover,.org-type-h:hover,.zone-chip:hover{
  background:color-mix(in srgb, var(--pc) 20%, #fff);
  border-color:var(--pc);
}
.group-row:active,.org-type-h:active,.zone-chip:active,
.group-branch.expanded .group-row,.org-type-sec.expanded .org-type-h{
  background:var(--pc);border-color:var(--pc);box-shadow:0 0 0 1px var(--pc);
}
.group-row:active .nm,.org-type-h:active .nm,.zone-chip:active .nm,
.group-branch.expanded .group-row .nm,.org-type-sec.expanded .org-type-h .nm{
  color:#fff;
}
.group-row:active .mark,.org-type-h:active .mark,
.group-branch.expanded .group-row .mark,.org-type-sec.expanded .org-type-h .mark{
  box-shadow:0 0 0 1px #fff;
}
.group-row:hover .group-toggle,.org-type-h:hover .org-type-toggle{color:var(--pc);}
.group-branch.expanded .group-toggle,.org-type-sec.expanded .org-type-toggle,
.group-row:active .group-toggle,.org-type-h:active .org-type-toggle{color:#fff;}

/* Zone chip — quick inline rename ✎, same affordance as group/org-type rename links */
.zone-chip{padding-right:6px;}
.zone-chip-rename{flex:0 0 auto;font-size:12px;color:var(--muted);text-decoration:none;padding:1px 4px;border-radius:5px;}
.zone-chip-rename:hover{background:rgba(255,255,255,.6);color:var(--ink);}
/* Placed zones (already dragged onto the canvas) go flat pale grey — signals "already
   used" and stops them visually competing with the zones still waiting to be placed. */
.zone-chip.placed{background:#eef1f5;border-color:#d3dae3;}
.zone-chip.placed:hover{background:#e2e6ec;border-color:#b7c0cc;}
.zone-chip.placed:active{background:#c7cdd6;border-color:#9aa5b1;box-shadow:0 0 0 1px #9aa5b1;}
.zone-chip.placed .zone-chip-sw{opacity:.4;}

/* ---------- v6.0.6: details-panel header (preview + Edit top-right) ----------
   Costas asked for the company's key facts at a glance with the Edit button in the top-right,
   rather than the old layout where Edit sat under the entire field list. */
.detail-head{
  display:flex;align-items:flex-start;gap:10px;
  padding-bottom:10px;margin-bottom:10px;border-bottom:1px solid var(--line);
}
.detail-head-main{display:flex;align-items:flex-start;gap:10px;min-width:0;flex:1;}
.contact-ref-pill{flex:0 0 auto;display:inline-flex;align-items:center;min-height:24px;padding:2px 9px;
  border:1px solid #b8ccec;border-radius:999px;background:#edf4ff;color:#245da9;font-size:11px;font-weight:750;white-space:nowrap;}
.detail-head-txt{min-width:0;display:flex;flex-direction:column;gap:3px;}
.detail-head-name{font-size:16px;font-weight:700;color:var(--ink);line-height:1.25;word-break:break-word;}
.detail-head-sub{font-size:12.5px;color:var(--muted);line-height:1.3;}
.contact-head-company{align-self:flex-start;}
.contact-head-title{display:flex;align-items:center;gap:6px;min-height:22px;}
.contact-head-linkedin{display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;
  flex:0 0 18px;border-radius:3px;background:#0a66c2;color:#fff!important;text-decoration:none;font-size:11px;font-weight:800;line-height:1;}
.contact-head-name-edit{display:grid;grid-template-columns:minmax(90px,1fr) minmax(90px,1fr);gap:6px;}
.contact-head-name-edit input,.contact-head-org,.contact-head-title input{min-height:30px;padding:4px 7px;border:1px solid var(--line-strong);border-radius:6px;background:#fff;color:var(--ink);font:inherit;}
.contact-head-title input{width:min(320px,100%);}
.detail-head .detail-edit{flex:0 0 auto;}
.detail-head .detail-photo{margin:0;flex:0 0 auto;}
.detail-initials{display:flex;align-items:center;justify-content:center;border-radius:50%;background:#e8eef8;
  color:var(--accent);font-weight:800;font-size:20px;letter-spacing:.4px;}
.detail-initials[hidden]{display:none;}
.profile-ai-summary{display:block;width:100%;min-height:180px;box-sizing:border-box;padding:14px 16px;
  border:1px solid var(--line);border-radius:8px;background:#fff;font-size:14px;line-height:1.5;white-space:normal;}
/* Contact LinkedIn preview and Info content. The LinkedIn block now lives on the consolidated
   Profile tab; the articles remain on Info. Shared classes keep both areas visually consistent.
   Every colour is a variable defined in :root — an undefined custom property invalidates the
   whole declaration silently and jsdom applies no CSS, so nothing here would catch it (the
   --card and --pc findings in CLAUDE.md, twice over). */
.profile-info-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:2px 0 8px;}
.profile-linkedin-section{margin-top:16px;padding-top:12px;border-top:1px solid var(--line);}
.profile-li-preview-label{margin:0 0 5px;color:var(--muted);font-size:11px;font-weight:700;
  letter-spacing:.05em;text-transform:uppercase;}
.profile-li-blurb{padding:12px 14px;border:1px solid var(--line);border-radius:8px;background:var(--card);
  font-size:14px;line-height:1.55;}
.profile-li-blurb.empty{color:var(--muted);background:transparent;border-style:dashed;}
.profile-li-link{margin:8px 0 0;font-size:13px;word-break:break-all;}
.profile-info-acts{display:flex;align-items:center;gap:6px;}
.profile-ai-summary.empty{min-height:0;color:var(--muted);background:transparent;border-style:dashed;}
.ai-inline-input{width:100%;box-sizing:border-box;padding:12px 14px;font-size:14px;line-height:1.5;
  border:1px solid var(--line-strong);border-radius:8px;background:var(--card);color:var(--ink);resize:vertical;}
.li-inline-input{width:100%;min-height:36px;box-sizing:border-box;padding:6px 10px;font-size:13px;
  border:1px solid var(--line-strong);border-radius:8px;background:var(--card);color:var(--ink);}
.profile-li-link a{color:var(--accent);}
.profile-research-when{margin-top:6px;font-size:11px;color:var(--muted);}
.profile-articles-t{margin-top:16px;}
.profile-research-docs .doc-row{margin-bottom:7px;}
.profile-notes-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:18px 0 8px;
  padding-bottom:6px;border-bottom:1px solid var(--line);font-size:12px;font-weight:800;text-transform:uppercase;letter-spacing:.35px;}
.profile-info-notes .doc-row{margin-bottom:7px;}
.conn-arrow{color:var(--muted);font-size:18px;line-height:1;}
.identity-connection{min-height:46px;gap:10px;padding:6px 9px;}
.conn-avatar{width:32px;height:32px;flex:0 0 32px;border-radius:50%;object-fit:cover;
  display:flex;align-items:center;justify-content:center;background:#edf3fb;border:1px solid var(--line);color:#6f87a5;overflow:hidden;}
.conn-avatar.square{border-radius:7px;background:#f4f6f9;}
.conn-avatar.fallback svg{width:17px;height:17px;}
.conn-identity{display:flex;flex:1 1 auto;min-width:0;flex-direction:column;gap:2px;}
.conn-name{font-size:13px;font-weight:650;line-height:1.25;color:var(--ink);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.conn-title{font-size:11.5px;font-weight:400;line-height:1.25;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.identity-connection:hover .conn-name{color:var(--accent);}
.profile-section{margin:0 0 8px;}
.profile-section-title,.profile-notes-head,#od-panel-info .pj-kv .k{
  color:#79a8cf;font-weight:600;}
.profile-section-title{margin:12px 0 6px;padding-bottom:4px;border-bottom:1px solid #c9ddec;
  font-size:11px;letter-spacing:.06em;text-transform:uppercase;}
.profile-description-section .profile-section-title{margin-top:0;}
/* v12.95.0 — the .profile-projop-* rules are DELETED with the tabbed Projop list they styled
   (see connectionsBlockHtml). A profile's Projops are picture tiles on Core now: .pjt-row below. */
.profile-description-value{min-height:48px;padding:8px 0;font-size:13px;line-height:1.5;color:var(--ink);}
.profile-description-value.empty{color:var(--muted);font-style:italic;}
#side-body #od-panel-info.profile-panel .pj-kv .v,
#side-body #od-panel-info.profile-panel .pj-kv-stack .v{
  background:transparent;border-color:transparent;border-radius:0;padding-left:0;padding-right:0;box-shadow:none;}
#side-body #od-panel-info.profile-panel .pj-kv{border-bottom:1px solid #e5edf4;padding:5px 0;}
#side-body #od-panel-info.profile-panel .pj-kv:has(.wt-slider) .v{background:transparent;border-color:transparent;}
.company-connection .conn-name,.company-website-row .stake-name{color:var(--accent);}
.company-connection,.company-website-row{background:#fff;}

/* ---------- v6.2.0: manual logo sizing on the organization form ---------- */
.logo-size-row{display:flex;align-items:center;gap:10px;}
.logo-size-row input[type=range]{flex:1;min-width:0;accent-color:var(--accent);}
.logo-size-row .logo-size-val{
  font-size:12.5px;color:var(--muted);min-width:48px;text-align:right;font-variant-numeric:tabular-nums;
}

/* ---------- v6.4.1: organization details panel — label left, value right ----------
   Costas: "i want the labels on the left the fields on the right. and a cleaner more pro look".
   The rows themselves are pjKv() (the same label-left grid the Projop panel uses); this block
   tidies the whole panel and catches anything else that renders a .detail-kv inside a tab —
   custom fields, for one — so a single field can't fall back to the old stacked layout. */
#side-body .pj-tab-panel .detail-kv{
  display:grid;grid-template-columns:120px 1fr;column-gap:14px;align-items:baseline;
  padding:9px 0;margin:0;border-bottom:1px solid var(--line);
}
#side-body .pj-tab-panel .detail-kv:last-child{border-bottom:none;}
#side-body .pj-tab-panel .detail-kv .k,
#side-body .pj-tab-panel .pj-kv .k{
  font-size:11px;letter-spacing:.6px;text-transform:uppercase;color:var(--muted);font-weight:600;
}
#side-body .pj-tab-panel .detail-kv .v,
#side-body .pj-tab-panel .pj-kv .v{font-size:14px;color:var(--ink);line-height:1.45;}
#side-body .pj-tab-panel .pj-kv{grid-template-columns:120px 1fr;padding:9px 0;}
/* sliders and chip rows sit centred against their label rather than on the text baseline */
#side-body .pj-tab-panel .pj-kv:has(.stance-slider),
#side-body .pj-tab-panel .pj-kv:has(.wt-slider),
#side-body .pj-tab-panel .pj-kv:has(.chip){align-items:center;}
/* long free text (Notes) stacks under its label instead of squeezing into the value column */
#side-body .pj-tab-panel .pj-kv-stack{grid-template-columns:1fr;row-gap:6px;}
#side-body .pj-tab-panel .pj-kv-stack .v{
  background:var(--bg);border:1px solid var(--line);border-radius:8px;padding:9px 11px;
}
/* links: readable, not shouty */
#side-body .pj-tab-panel .v a{color:var(--accent);text-decoration:none;word-break:break-all;}
#side-body .pj-tab-panel .v a:hover{text-decoration:underline;}
/* the action row reads as a toolbar under the header */
#side-body .detail-actions{
  margin:0 0 2px;padding-bottom:12px;border-bottom:1px solid var(--line);
}
#side-body .pj-tabs{margin-top:0;}

/* ---------- v6.4.2: details-panel controls, tightened ----------
   The status swatches were 24px with a 4px dark halo and the "no status" button was a wide
   dashed pill — three different shapes in one row. Everything in a panel row is now the same
   small, consistent control, and rows share a common height so one doesn't tower over the rest. */
#side-body .pj-tab-panel .stance-slider{gap:6px;}
#side-body .pj-tab-panel .stance-slider .wseg{
  width:16px;height:16px;border-width:1px;box-shadow:none;
}
#side-body .pj-tab-panel .stance-slider .wseg.on{
  box-shadow:0 0 0 2px var(--panel), 0 0 0 3px var(--ink);
}
#side-body .pj-tab-panel .stance-slider .wseg.clear{
  width:16px;height:16px;border-radius:50%;padding:0;font-size:0;
  background:#fff;border:1px dashed var(--line-strong);
}
#side-body .pj-tab-panel .stance-slider .wseg.clear.on{
  border-style:solid;border-color:var(--ink);
}
/* weight: a compact segmented control in the same key as the status swatches */
#side-body .pj-tab-panel .wslider:not(.stance-slider){gap:4px;}
#side-body .pj-tab-panel .wslider:not(.stance-slider) .wseg{
  min-width:24px;height:20px;padding:0 6px;border-radius:4px;font-size:11px;line-height:18px;
}
/* every row the same height, so the panel reads as a table */
#side-body .pj-tab-panel .pj-kv,
#side-body .pj-tab-panel .detail-kv{min-height:38px;}
/* links stay on one line and truncate rather than breaking across words */
#side-body .pj-tab-panel .v a{
  display:inline-block;max-width:100%;white-space:nowrap;overflow:hidden;
  text-overflow:ellipsis;vertical-align:bottom;word-break:normal;
}

/* ---------- v6.5.0: Projop documents / reports ---------- */
.doc-list{display:flex;flex-direction:column;gap:6px;}
.doc-row{
  display:flex;align-items:flex-start;gap:8px;
  border:1px solid var(--line);border-radius:8px;padding:9px 10px;background:var(--panel);
}
.doc-main{flex:1;min-width:0;}
.doc-row .doc-open{
  font-size:13.5px;font-weight:600;color:var(--accent);text-decoration:none;
  display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
}
.doc-row .doc-open:hover{text-decoration:underline;}
.doc-title{font-weight:600;color:var(--ink);}
.doc-meta{font-size:11px;color:var(--muted);text-transform:uppercase;letter-spacing:.4px;margin-top:2px;}
.doc-note{font-size:12.5px;color:var(--ink);margin-top:4px;line-height:1.4;}
.doc-total{font-size:11.5px;color:var(--muted);margin:8px 0 0;}
.doc-add{margin-top:14px;padding-top:12px;border-top:1px solid var(--line);display:flex;flex-direction:column;gap:7px;}
.doc-add input[type=text],.doc-add textarea{width:100%;}
.doc-add textarea,.doc-edit-form textarea{resize:vertical;min-height:74px;}
.doc-add-author,.doc-edit-form label{display:flex;align-items:center;gap:8px;font-size:12px;color:var(--muted);}
.doc-add-author select,.doc-edit-form select{min-width:180px;}
.doc-add-row{display:flex;gap:7px;align-items:center;}
.doc-add-row input[type=file]{flex:1;min-width:0;font-size:12.5px;}
.doc-add-row input[type=text]{flex:1;min-width:0;}
.doc-actions{display:flex;flex-direction:column;gap:3px;align-items:center;flex:none;width:54px;}
.doc-pill{display:block;border:1px solid var(--line-strong);border-radius:999px;background:#fff;
  color:var(--ink);font:600 9.5px/1.1 inherit;padding:3px 7px;text-align:center;white-space:nowrap;}
button.doc-pill{cursor:pointer;}
button.doc-edit:hover{border-color:var(--accent);color:var(--accent);}
button.doc-del{border-color:#efb4b4;background:#fff3f3;color:var(--danger);}
.doc-contributor{display:flex;width:25px;height:25px;padding:0;align-items:center;justify-content:center;
  background:var(--accent-soft);border-color:#bfd1ee;color:var(--accent);overflow:hidden;}
.doc-contributor img{width:100%;height:100%;object-fit:cover;border-radius:50%;}
.doc-contrib-ini,.doc-ai-icon{font-size:10px;font-weight:800;line-height:1;}
.doc-ai-icon{font-size:14px;}
.doc-actions button.doc-pill{width:46px;height:24px;font-family:inherit;font-size:10.5px;font-weight:500;line-height:1;}
.doc-edit-form{width:100%;display:flex;flex-direction:column;gap:9px;font-size:13px;}
.doc-edit-form input[type=text],.doc-edit-form textarea{width:100%;font-size:13px;line-height:1.4;padding:7px 9px;border-color:#c7d0dc;border-radius:7px;background:#fff;}
.doc-edit-form input[type=text],.doc-edit-form select{min-height:34px;}
.doc-edit-form textarea{min-height:0;}
.doc-edit-form .doc-e-note{min-height:72px;}
.modal-card:has(.doc-edit-modal){width:min(660px,94vw);max-width:94vw;}
.modal-card:has(.doc-edit-modal) .modal-head{padding:14px 18px;font-size:18px;font-weight:700;}
.modal-card:has(.doc-edit-modal) .modal-body{padding:14px 18px;background:#f5f8fc;}
.modal-card:has(.doc-edit-modal) .modal-foot{display:none;}
.doc-edit-form .doc-e-field{display:flex;flex-direction:column;align-items:stretch;gap:4px;color:var(--muted);}
.doc-edit-form .doc-e-field>span,.doc-summary-head label{font-size:10.5px;font-weight:700;letter-spacing:.045em;text-transform:uppercase;color:#6686ad;}
.doc-edit-meta{display:grid;grid-template-columns:minmax(180px,260px);gap:10px;}
.doc-edit-form select{width:100%;min-width:0;padding:5px 8px;font-size:13px;border:1px solid #c7d0dc;border-radius:7px;background:#fff;}
.doc-e-important{display:inline-flex!important;align-items:center;align-self:center;gap:6px;padding:5px 9px;border:1px solid #d8bf55;border-radius:999px;background:#fff9d9;color:#725700;font-size:11px;font-weight:700;cursor:pointer;}
.doc-e-important input{width:14px;height:14px;min-height:0;margin:0;accent-color:#d4a800;}
.doc-e-important span{white-space:nowrap;}
.doc-edit-options{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:2px 0;}
.doc-edit-form .doc-e-file-label{display:inline-flex;align-items:center;gap:7px;color:var(--muted);font-size:11.5px;}
.doc-e-file{font-size:11px;max-width:260px;}
.doc-edit-actions{display:flex;gap:7px;justify-content:flex-end;margin-top:2px;padding-top:10px;border-top:1px solid var(--line);}
.doc-edit-actions .btn{min-height:32px;padding:0 12px;font-size:12px;border-radius:7px;}
.doc-edit-actions .doc-e-delete{margin-right:auto;}
.doc-e-remove{color:var(--danger)!important;}
.doc-private-thumb.unavailable{visibility:hidden;}
.doc-media{flex:0 0 112px;width:112px;height:122px;min-height:0;max-height:122px;align-self:flex-start;margin:-9px 0 -9px -10px;overflow:hidden;border-radius:7px 0 0 7px;background:var(--bg);display:flex;align-items:center;justify-content:center;}
.doc-media .doc-thumb{width:100%;height:122px;min-height:0;max-height:122px;margin:0;border:0;border-radius:0;object-fit:cover;object-position:center top;}
.doc-media .doc-fav{flex:none;margin:0;}
.doc-meta-line{display:flex;align-items:center;gap:7px;min-width:0;margin-top:2px;}
.doc-meta-line .doc-meta{margin:0;min-width:0;}
/* v12.76.0 — the AI summary pill is a .ai-pill now; its look lives with the other two at the end of this file. */
.doc-summary-editor{padding:9px 10px;border:1px solid #d7e0ec;border-radius:8px;background:#fff;}
.doc-summary-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:6px;}
.doc-summary-editor .doc-e-article-summary{min-height:92px;}
.doc-summary-editor .doc-e-ai-summary{min-height:30px;padding:0 10px;font-size:11.5px;white-space:nowrap;color:var(--accent);border-color:#aebfe3;background:#edf3ff;}
.article-summary-popup{white-space:pre-wrap;line-height:1.55;color:var(--ink);font-size:14px;}
@media (max-width:640px){.doc-media{flex-basis:82px;}.doc-edit-meta{grid-template-columns:1fr;}.doc-edit-options{align-items:flex-start;flex-direction:column;}.doc-e-important{align-self:flex-start;}}

/* v6.8.0 — Players / Parties: role section > companies A-Z > their people.
   The role is the section heading, so a company row carries no role badge and nothing wraps.
   Every row is flex with a min-width:0 name, so a long name truncates instead of shoving the
   stars and buttons off the right edge. */
.stake-rgrp,.pj-rgrp{ margin:0 0 16px; }
.stake-rgrp:last-child,.pj-rgrp:last-child{ margin-bottom:0; }
.stake-rgrp-h,.pj-rgrp-h{
  display:flex; align-items:center; gap:7px;
  font-size:11px; font-weight:700; letter-spacing:.06em; text-transform:uppercase;
  color:var(--muted); padding:0 2px 6px;
}
.rgrp-dot{ width:7px; height:7px; border-radius:50%; flex:none; }
.stake-rgrp.plain .rgrp-dot,.pj-rgrp.plain .rgrp-dot{ opacity:.45; }
.stake-rgrp-body,.pj-rgrp-body{ display:flex; flex-direction:column; gap:9px; }

.stake-grp,.pj-grp{ margin:0; }
.stake-grp-h.plain,.pj-grp-h.plain{
  display:flex; align-items:center; gap:8px;
  font-size:13px; color:var(--muted); font-style:italic;
  padding:3px 2px 5px; border-bottom:1px dashed var(--line);
}
.stake-grp-body,.pj-grp-body{ margin:4px 0 0 13px; padding-left:11px; border-left:2px solid var(--line); }
.stake-grp-body:empty,.pj-grp-body:empty{ display:none; border-left:0; padding:0; margin:0; }

.stake-row.stake-co,.stake-row.stake-pn{
  display:flex; align-items:center; gap:9px; min-width:0;
  border:0; border-radius:0; margin:0; padding:5px 2px;
}
.stake-row.stake-co{ border-bottom:1.5px solid var(--line-strong,#d3dae3); }
.stake-row.stake-pn{ border-bottom:1px solid var(--line); }
.stake-row.stake-pn:last-child{ border-bottom:0; }
.stake-row.stake-co:hover,.stake-row.stake-pn:hover{ background:var(--accent-soft,#eef4ff); }
.stake-co .stake-name{ font-size:14.5px; font-weight:600; }
.stake-pn .stake-name{ font-size:13px; font-weight:500; }
.stake-pn .stake-name{
  flex:1 1 auto; min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap;
}
.stake-co .stake-co-content{display:flex;flex:1 1 auto;min-width:0;flex-direction:column;align-items:flex-start;gap:3px;}
.stake-co .stake-name{display:block;width:100%;white-space:normal;overflow-wrap:anywhere;line-height:1.25;}
.stake-co .stake-co-meta{display:flex;align-items:center;gap:7px;min-width:0;}
.stake-chip,.stake-edit,.stake-x{ flex:none; }
.stake-chip{ font-size:10.5px; padding:1px 7px; }
.stake-av{ width:24px; height:24px; border-radius:50%; object-fit:cover; flex:none;
  background:var(--panel); border:1px solid var(--line); }
.stake-av.sq{ width:28px; height:28px; border-radius:6px; }
.stake-av.ini{ display:flex; align-items:center; justify-content:center;
  font-size:10px; font-weight:700; color:var(--muted); letter-spacing:.02em; }

/* v7.0.0 — Players: a company is the player, every one of its contacts is listed beneath it,
   and the checkbox is this Projop's canvas membership. A person who is OFF the canvas is
   dimmed rather than hidden, so you can always see who else is available. */
.stake-chk{ flex:none; width:15px; height:15px; margin:0 1px 0 0; cursor:pointer; accent-color:var(--accent,#2f6df6); }
.stake-grp-n{ font-size:11px; color:var(--muted); margin:2px 0 3px 40px; }
.stake-row.stake-pn{ opacity:.5; transition:opacity .12s; }
.stake-row.stake-pn.on{ opacity:1; }
.stake-row.stake-pn:hover{ opacity:1; }
.stake-pen{ flex:none; border:0; background:transparent; cursor:pointer; color:var(--muted);
  font-size:13px; padding:2px 4px; border-radius:4px; }
.stake-pen:hover{ background:var(--accent-soft,#e8eef8); color:var(--accent,#2f6df6); }

/* v12.88.1 — the caret alone expands a company; the rest of the row opens its profile. */
.stake-caret{ flex:none; width:18px; height:22px; padding:0; border:0; border-radius:5px;
  background:transparent; font-size:10px; color:var(--muted); line-height:1; cursor:pointer; }
.stake-caret:hover,.stake-caret:focus-visible{ background:var(--accent-soft,#e8eef8); color:var(--accent,#2f6df6); }
.stake-row.stake-co{ cursor:pointer; }
.stake-row.stake-co:focus-visible{ outline:2px solid var(--accent,#2f6df6); outline-offset:-2px; }
.stake-grp-n{ cursor:pointer; }
.stake-grp:not(.open) .stake-grp-body{ display:none; }

/* ---------- v7.5.0: unified node log (profile + every Projop) ---------- */
.nl-filter-row{display:flex;align-items:center;gap:8px;margin:2px 0 10px;}
.nl-filter-lab{font-size:11px;letter-spacing:.6px;text-transform:uppercase;color:var(--muted);font-weight:600;}
.nl-filter-row select{flex:1;min-width:0;}
.nl-tag{
  font-size:10.5px;letter-spacing:.4px;text-transform:uppercase;font-weight:700;
  color:var(--accent);background:var(--accent-soft);border-radius:999px;padding:1px 8px;
  max-width:150px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
}
.nl-tag.own{color:var(--muted);background:var(--line);}
.nl-add{display:flex;gap:6px;align-items:center;margin-top:10px;}
.nl-add input{flex:1;min-width:0;}
.nl-add select{flex:0 0 auto;max-width:150px;}

/* v7.7.0 — "Add from canvas…" bulk player picker (openAddFromCanvas, js/entities.js).
   Deliberately reuses .stake-av (the Players tab avatar) so a row here reads the same as the
   row it will become. */
.stake-actions{display:flex;gap:6px;flex-wrap:wrap;margin-top:6px;}
.afc-tools{font-size:12px;color:var(--muted);margin:2px 0 8px;}
.afc-tools a{color:var(--accent);text-decoration:none;}
.afc-tools a:hover{text-decoration:underline;}
#afc-list{max-height:46vh;overflow-y:auto;}
.afc-row{display:flex;align-items:center;gap:8px;padding:5px 2px;border-bottom:1px solid var(--line);}
.afc-row:last-child{border-bottom:0;}
.afc-name{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;cursor:pointer;font-size:13px;}
.afc-kind{flex:0 0 auto;font-size:11px;color:var(--muted);text-transform:uppercase;letter-spacing:.03em;}
.afc-role{flex:0 0 auto;max-width:150px;}

/* v7.9.0 — Projop funnel fields: the four-year expected-income split rendered inline on the
   Brief tab. Each year is a small pill so the line reads as a series rather than a sentence. */
.pj-inc{display:inline-block;margin:0 6px 3px 0;padding:2px 7px;border:1px solid var(--line);border-radius:5px;background:var(--bg);font-size:12px;white-space:nowrap}
.pj-inc b{font-weight:600;color:var(--muted);margin-right:4px;font-size:11px}

/* v8.0.0: Projops board — the new "home page", a Kanban view of every Projop, columns by
   stage. Sibling of #graph-wrap inside main.workspace, so it takes the same flex slot and
   fills the space next to the sidebar; toggled via the hidden attribute (js/views.js
   showCanvasView() / js/reports.js openProjopBoard()), never destroyed while hidden. */
#board-view{flex:1;display:flex;flex-direction:column;min-width:0;overflow:hidden;background:var(--bg);}
.board-head{flex:0 0 auto;padding:14px 18px 10px;background:var(--panel);border-bottom:1px solid var(--line);}
.board-title{margin:0 0 8px;font-size:17px;font-weight:700;}
.board-filters{display:flex;align-items:center;gap:8px;flex-wrap:wrap;}
.board-filters select,.board-filters input{min-height:32px;padding:0 8px;font-size:12.5px;border:1px solid var(--line-strong);border-radius:7px;background:#fff;}
.board-filters input{width:110px;}
.board-count{color:var(--muted);font-size:12px;margin-left:4px;}
.board-canvas-link{margin-left:auto;font-size:12.5px;color:var(--accent);text-decoration:none;}
.board-canvas-link:hover{text-decoration:underline;}
/* v10.5.0 — ProjOps' Pipeline/Archive sub-tabs (oppSubnavHtml(), js/reports.js). Reuses
   .view-switch/.vs-btn verbatim (same look as the primary toolbar switcher), just placed inline
   under the board-head title instead of in the header — .opp-subnav only adds the spacing. */
.opp-subnav{margin:0 0 8px;}
.board-cols{flex:1;display:flex;gap:12px;padding:14px 18px;overflow-x:auto;overflow-y:hidden;align-items:flex-start;}
.board-col{flex:0 0 260px;display:flex;flex-direction:column;max-height:100%;background:var(--panel);border:1px solid var(--line);border-radius:10px;overflow:hidden;}
.board-col-h{flex:0 0 auto;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:9px 12px;border-bottom:2px solid var(--pc,var(--line-strong));}
.board-col-t{font-size:12.5px;font-weight:700;color:var(--ink);}
.board-col-n{font-size:11px;color:var(--muted);background:var(--bg);border-radius:10px;padding:1px 7px;}
.board-col-body{flex:1;overflow-y:auto;padding:8px;display:flex;flex-direction:column;gap:8px;}
.board-col-empty{padding:6px 2px;}
.board-card{background:#fff;border:1px solid var(--line);border-radius:8px;padding:8px 10px;cursor:pointer;}
.board-card:hover{border-color:var(--accent);box-shadow:var(--shadow);}
.board-card-name{font-size:13px;font-weight:600;color:var(--ink);text-transform:uppercase;letter-spacing:.2px;}
/* v11.1.0 — the Brief line, Title/Brief/Description hierarchy: display-only casing, the stored
   text is never rewritten. text-transform:lowercase + ::first-letter:uppercase gives "First
   letter capitalised, rest lower case" — CSS's own text-transform:capitalize instead capitalises
   EVERY word, which is not what was asked for. */
.board-card-brief{font-size:11.5px;color:var(--muted);margin-top:2px;text-transform:lowercase;}
.board-card-brief::first-letter{text-transform:uppercase;}
.board-card-ref{font-size:11px;color:var(--muted);margin-top:1px;}
/* v11.2.0 — replaces the old separate .board-card-fs / .board-card-budget lines. Stage/status/
   budget now render as ONE row reusing the sidebar's own .pjb-stage/.pjb-fs/.pjb-val classes
   (see boardCardHtml(), js/reports.js), so the card's header strip is not just similar to the
   sidebar's .pjb-top — it is the identical markup, and cannot drift from it independently. */
.board-card-top{display:flex;flex-wrap:wrap;gap:5px;align-items:center;margin-top:4px;}
.board-card-meta{display:flex;flex-wrap:wrap;gap:5px;margin-top:5px;font-size:11px;color:var(--muted);}
.board-card-meta span{background:var(--bg);border-radius:5px;padding:1px 6px;}

/* v9.5.0 — the Archive view. Same #board-view shell and .board-head/.board-title/.board-filters/
   .board-count/.board-canvas-link classes (none of them are scoped to #board-view specifically),
   just a wrapping card grid instead of Kanban columns — stage no longer matters once a Projop is
   shelved, so there is nothing to sort into columns by. */
#archive-view{flex:1;display:flex;flex-direction:column;min-width:0;overflow:hidden;background:var(--bg);}
.archive-grid{flex:1;display:flex;flex-wrap:wrap;align-content:flex-start;gap:12px;padding:14px 18px;overflow-y:auto;}
.archive-grid .board-card{flex:0 0 260px;}

/* v10.0.0 — the Housekeeping view. Same #board-view shell and .board-head/.board-title/
   .board-filters/.board-count/.board-canvas-link classes as the board and the Archive (none of
   them are scoped to a specific id), with a real data table instead of cards. Sticky header row
   so the column you sorted by stays visible while you scroll a few thousand contacts. */
#admin-view{flex:1;display:flex;flex-direction:column;min-width:0;overflow:hidden;background:var(--bg);}
.adm-tabs{display:flex;gap:6px;margin:0 0 8px;}

/* v10.3.0 — Actions Due, its own page. Same #board-view shell and .board-head/.board-title/
   .board-filters/.board-count/.board-canvas-link classes as its five siblings; body reuses the
   .home-row/.home-urg-grp classes verbatim (none of them scoped to the home cards specifically)
   so a row looks identical here to how it looked on Home's card. */
#actions-view{flex:1;display:flex;flex-direction:column;min-width:0;overflow:hidden;background:var(--bg);}
.actions-body{flex:1;overflow-y:auto;padding:10px 18px 18px;max-width:920px;}
.actions-filters{align-items:flex-start;}
.af-project-picks{display:flex;flex-wrap:wrap;gap:5px;max-width:640px;padding:5px 7px;border:1px solid var(--line-strong);border-radius:8px;background:var(--panel);}
.af-project-picks[hidden]{display:none;}
.af-project-picks label{display:inline-flex;align-items:center;gap:4px;padding:3px 7px;border:1px solid var(--line);border-radius:12px;font-size:11.5px;cursor:pointer;background:#fff;}
.af-project-picks input[type=checkbox]{width:13px;height:13px;min-height:0;margin:0;}
.adm-tab{display:inline-flex;align-items:center;gap:6px;min-height:30px;padding:0 12px;border:1px solid var(--line-strong);border-radius:8px;background:var(--panel);color:var(--ink);font-size:12.5px;font-weight:600;cursor:pointer;}
.adm-tab:hover{border-color:var(--accent);}
.adm-tab.on{background:var(--accent);border-color:var(--accent);color:#fff;}
.adm-n{font-size:10.5px;font-weight:600;background:rgba(0,0,0,.09);border-radius:9px;padding:1px 6px;}
.adm-tab.on .adm-n{background:rgba(255,255,255,.22);}
.adm-dup-l{display:inline-flex;align-items:center;gap:5px;font-size:12.5px;color:var(--muted);cursor:pointer;}
/* v11.0.2 — every checkbox on this screen (this one, plus .adm-cb's select-all/per-row boxes
   below) was missing the same width/height reset every OTHER checkbox in the app already gets
   (see .org-row/.pj-flag/.li-cand input[type=checkbox] elsewhere in this file) — with nothing
   overriding it, the browser's native default checkbox rendered next to this row's 12.5px label
   text, looking comically oversized. Same 13px convention as .org-row's. */
.adm-dup-l input[type=checkbox]{width:13px;height:13px;min-height:0;margin:0;flex:0 0 auto;}
.board-filters #adm-filter{width:190px;}

/* the bulk bar only exists while something is ticked (hidden attribute, set in adminSyncBulkBar) */
.adm-bulk{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:9px;padding:8px 10px;background:var(--bg);border:1px solid var(--line-strong);border-radius:8px;}
.adm-bulk[hidden]{display:none;}
.adm-bulk-l{font-size:12.5px;color:var(--muted);}
.adm-bulk select,.adm-bulk input{min-height:30px;padding:0 8px;font-size:12.5px;border:1px solid var(--line-strong);border-radius:7px;background:#fff;}
.adm-bulk input{width:180px;}
.adm-selcount{font-size:12.5px;font-weight:700;color:var(--accent);}

.adm-wrap{flex:1;overflow:auto;padding:0 18px 18px;}
table.adm-table{border-collapse:separate;border-spacing:0;width:100%;font-size:12.5px;background:var(--panel);}
table.adm-table thead th{position:sticky;top:0;z-index:2;background:var(--panel);text-align:left;white-space:nowrap;font-weight:700;padding:9px 10px;border-bottom:2px solid var(--line-strong);}
table.adm-table td{padding:7px 10px;border-bottom:1px solid var(--line);vertical-align:top;}
.adm-h{cursor:pointer;user-select:none;}
.adm-h:hover{color:var(--accent);}
.adm-h.on{color:var(--accent);}
.adm-arrow{margin-left:4px;font-size:10px;}
.adm-filter-drop{position:relative;margin-top:5px;color:var(--ink);font-weight:400;cursor:pointer;}
.adm-filter-drop summary{display:inline-flex;align-items:center;min-width:72px;padding:3px 7px;border:1px solid var(--line-strong);border-radius:6px;background:#fff;font-size:11px;list-style:none;}
.adm-filter-drop summary::-webkit-details-marker{display:none;}
.adm-filter-drop summary::after{content:"▾";margin-left:auto;padding-left:7px;color:var(--muted);}
.adm-filter-menu{position:absolute;top:calc(100% + 3px);left:0;z-index:8;min-width:170px;max-height:240px;overflow:auto;padding:6px;background:#fff;border:1px solid var(--line-strong);border-radius:7px;box-shadow:0 6px 18px rgba(32,45,60,.18);}
.adm-filter-menu label{display:flex;align-items:center;gap:6px;padding:4px 5px;white-space:nowrap;font-size:11.5px;cursor:pointer;}
.adm-filter-menu label:hover{background:var(--bg);}
.adm-filter-menu input{width:13px;height:13px;min-height:0;margin:0;}
.adm-num{text-align:right;}
.adm-cb{width:34px;text-align:center;padding-left:12px !important;padding-right:4px !important;}
.adm-cb input{cursor:pointer;width:13px;height:13px;min-height:0;margin:0;}
.adm-profile-col{width:56px;min-width:56px;padding-left:2px!important;padding-right:4px!important;text-align:center;white-space:nowrap;vertical-align:middle!important;}
.adm-profile-btn{display:inline-flex;align-items:center;justify-content:center;width:26px;height:26px;padding:0;border:0;border-radius:6px;background:#e5ebf2;color:#315d89;cursor:pointer;overflow:hidden;font-size:9px;font-weight:700;}
.adm-profile-btn.round{border-radius:50%;}
.adm-profile-btn:hover{box-shadow:0 0 0 2px #8eb0e8;}
.adm-profile-btn img{display:block;width:100%;height:100%;object-fit:cover;}
/* v12.85.0 — the company / independent mark beside a contact's photo in Housekeeping. Blue while
   the contact is active, grey once archived, so a scan down the column separates "real, working
   record" from "parked" without reading the Archived column. Colour is carried by the class and
   inherited by the inline SVG's currentColor — one place to change it. */
.adm-identity-pair{display:inline-flex;align-items:center;justify-content:center;gap:4px;white-space:nowrap;vertical-align:middle;}
.adm-kind-ico{display:inline-flex;align-items:center;justify-content:center;margin:0;vertical-align:middle;line-height:0;}
.adm-kind-ico.active{color:var(--accent);}
.adm-kind-ico.archived{color:var(--muted);opacity:.75;}
.adm-kind-ico.new_coop{color:#7652b8;background:#f0eaff;border-color:#cbb9ee;}
.adm-profile-fallback{display:inline-flex;align-items:center;justify-content:center;width:100%;height:100%;}
.adm-profile-fallback[hidden]{display:none;}
.adm-company-cell{color:var(--accent);cursor:pointer;text-decoration:none;}
.adm-company-cell:hover{text-decoration:underline;}
.adm-row{cursor:pointer;}
.adm-row:hover td{background:var(--bg);}
.adm-row.on td{background:rgba(47,109,246,.09);}
.adm-quick-cell{cursor:text;min-width:130px;}
.adm-quick-cell:empty:hover::after{content:attr(data-placeholder);color:#8aa9c3;font-size:11px;font-style:italic;}
.adm-quick-cell.editing{padding:2px 4px;box-shadow:inset 0 0 0 2px var(--accent);background:#fff!important;}
.adm-quick-input{display:block;width:100%;min-width:120px;height:30px;padding:0 6px;border:0;outline:0;background:#fff;color:var(--ink);font:inherit;}
.adm-quick-cell.saving{opacity:.65;}
/* v12.122.0 — Phone and Email are links you act on. They keep the .adm-quick-cell text cursor on
   the cell itself (double-click still edits), so the pointer only turns into a hand over the
   address, which is exactly where clicking does something. */
.adm-contact-link{color:var(--accent);text-decoration:none;cursor:pointer;overflow-wrap:anywhere;}
.adm-contact-link:hover{text-decoration:underline;}
/* v12.125.0 — Key contact is a checkbox you TICK, not a mark you read: the flag is yours to set
   (v12.122.0's read-only tick reported a computed fact, which is the thing Costas corrected).
   The <label> wraps it so the whole cell is a target — a 13px box is a small thing to hit on a
   265-row table — and it is what the row-click handler tests to know this was a write, not
   navigation. */
.adm-key-cell{display:flex;align-items:center;justify-content:flex-start;min-height:22px;
  padding:0 2px;cursor:pointer;}
.adm-key-chk{width:15px;height:15px;margin:0;cursor:pointer;accent-color:var(--accent);}
.adm-key-chk:disabled{opacity:.5;cursor:progress;}
.adm-empty{color:var(--muted);padding:18px 10px !important;text-align:center;}

/* v8.0.1 — board cards carry their people and their latest log line. Kept deliberately tight:
   with 85 cards on screen the board only works if a card stays scannable, so players are capped
   at three chips with a "+N" overflow and the note is clamped to two lines. The full lists live
   in the card's preview modal. */
.board-card-players{display:flex;flex-wrap:wrap;gap:3px;margin-top:6px}
.board-chip{display:inline-block;max-width:100%;padding:1px 6px;border:1px solid var(--line);border-radius:9px;background:var(--bg);font-size:11px;line-height:1.5;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.board-chip.is-org{border-style:dashed;color:var(--muted)}
.board-chip-more{color:var(--muted);border-style:dotted}
.board-card-note{margin-top:6px;font-size:11.5px;line-height:1.35;color:var(--muted);display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.board-card-notecount{margin-top:4px;font-size:10.5px;color:var(--muted);opacity:.85}
/* preview modal */
.bp-list{display:flex;flex-direction:column;gap:3px}
.bp-row{display:flex;align-items:center;gap:6px;justify-content:space-between;padding:2px 0;border-bottom:1px solid var(--line)}
.bp-name{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.bp-log{display:flex;flex-direction:column;gap:5px;max-height:260px;overflow:auto}
.bp-note{display:flex;gap:8px;font-size:12.5px;line-height:1.4;padding-bottom:4px;border-bottom:1px solid var(--line)}
.bp-note-d{flex:0 0 74px;color:var(--muted);font-size:11px;padding-top:1px}
.bp-note-b{min-width:0}

/* v8.0.2 — the Projops selector is now a type-to-filter picker (85+ Projops made the plain
   dropdown unusable). Reuses the .fp-* classes from the v4.9.5 stakeholder picker; .vp-wrap
   only widens the list, since a Projop name is far longer than a person's. */
.view-row .vp-wrap{width:100%}
.view-row .vp-wrap .fp-input{width:100%;min-height:26px;font-size:12.5px;padding:2px 6px;border-radius:6px}
.view-row .vp-wrap .fp-list{max-height:320px;min-width:100%}
.fp-item .sub{opacity:.6;font-size:11px;margin-left:6px}
.fp-item.vp-none{font-style:italic;color:var(--muted);border-bottom:1px solid var(--line)}

/* v8.1.0 — cascading Projop filters above the picker. Three full-width selects stacked rather
   than sat side by side: the sidebar is narrow and a customer name like "ΖΥΘΟΠΟΙΙΑ ΜΑΚΕΔΟΝΙΑΣ
   ΘΡΑΚΗΣ" needs the room. */
.pjf-bar{display:flex;flex-direction:column;gap:4px;margin:0 0 6px}
.pjf-sel{width:100%;min-height:26px;font-size:12px;padding:2px 6px;border:1px solid var(--line);border-radius:6px;background:#fff}
.pjf-foot{display:flex;justify-content:space-between;align-items:center;font-size:11px;color:var(--muted)}
.pjf-foot a{font-size:11px}
.view-actions{display:flex;gap:6px;align-items:center;margin-bottom:6px}

/* v8.1.4 — Projop Brief tab: a summary strip, then labelled groups. The flat nineteen-row list
   it replaces gave every field the same weight, so the three things you actually check first
   (stage, funnel status, our budget) were buried among rooms and villas. */
.pjb-top{display:flex;flex-wrap:wrap;gap:6px;align-items:center;padding:8px 0 10px;border-bottom:1px solid var(--line);margin-bottom:4px}
.pjb-fs{font-size:12px;color:var(--muted);background:var(--bg);border:1px solid var(--line);border-radius:9px;padding:1px 8px}
.pjb-val{margin-left:auto;font-weight:600;font-size:13.5px;color:var(--ink)}
.pjb-sec{margin:0 0 2px}
/* v11.1.0 — the Brief line on the Overview tab, full text, no casing transform (that's a
   card-only display convention — see .board-card-brief). */
.pjb-brief{font-size:12.5px;color:var(--muted);margin:2px 0 8px;line-height:1.4}
/* v11.6.0 — Overview header restructure. Ref badge sits in the shared side-head, just in front
   of the title; a plain rounded-square chip rather than a full circle, since a ref can run to
   three digits and a circle would clip. Stage badge shares the same header, right-aligned next
   to (or, in the popup, in place of) back-btn — see wireProjopPopupChrome()/closeProjopPopup(). */
.side-ref-badge{display:inline-flex;align-items:center;justify-content:center;min-width:26px;height:22px;
  padding:0 6px;border-radius:6px;background:var(--accent-soft);color:var(--accent);
  font-size:11.5px;font-weight:700;letter-spacing:.02em;font-variant-numeric:tabular-nums;flex:none}
.side-stage-badge:empty{display:none}
.side-stage-badge .pjb-stage{font-size:11.5px}
.side-location-badge{display:inline-flex;align-items:center;max-width:210px;height:22px;padding:0 9px;
  border:1px solid #bfd5ea;border-radius:11px;background:#eef6fd;color:#477ca8;font-size:10.5px;
  font-weight:700;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;cursor:pointer;}
.side-location-badge.empty{background:transparent;border-style:dashed;color:var(--muted);}
/* Executive summary — same label treatment as a Brief-tab section heading (.pjb-sec-t), but this
   sits above the tabs entirely, alongside Brief, per Costas: "there will be 3 fields with the
   Brief, the exec summary and below those the key stakeholders." */
.pjb-exec{margin:2px 0 10px}
.pjb-exec-label{font-size:10.5px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;
  color:var(--muted);margin:0 0 3px}
.pjb-exec-body{font-size:12.5px;color:var(--ink);line-height:1.45}
/* Key stakeholders — pills reuse .board-chip's look (same one the board card's player chips use)
   so this can never drift visually from that surface; add-ons here are just clickability. */
.pjb-keystake{margin:0 0 10px}
.pjb-pills{display:flex;flex-wrap:wrap;gap:5px}
.pjb-pill{cursor:pointer}
.pjb-pill{display:inline-flex;align-items:center;gap:6px;padding:3px 8px 3px 3px;}
.pjb-player-avatar{width:24px;height:24px;flex:0 0 24px;border-radius:50%;overflow:hidden;background:#e8eef8;}
.pjb-player-avatar img,.pjb-player-ini{width:100%;height:100%;border-radius:50%;}
.pjb-player-avatar img{display:block;object-fit:cover;}
.pjb-player-ini{display:flex;align-items:center;justify-content:center;color:var(--accent);font-size:9px;font-weight:800;}
.pjb-player-ini[hidden]{display:none;}
.pjb-player-text{display:flex;flex-direction:column;align-items:flex-start;min-width:0;line-height:1.15;}
.pjb-player-name{white-space:nowrap;}
.pjb-player-company{max-width:150px;margin-top:2px;padding:0;border:0;background:transparent;
  color:var(--muted);font-size:9.5px;font-weight:400;text-align:left;cursor:pointer;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.pjb-player-company:hover{color:var(--accent);text-decoration:underline;}
.pjb-pill:hover{background:var(--accent-soft);border-color:var(--accent);color:var(--accent)}
.canvas-save-btn.dirty{background:#168a4a;color:#fff;border-color:#11723d;font-weight:700;}
.canvas-save-btn.dirty:hover{background:#11723d;color:#fff;}
.canvas-save-btn.saved{background:var(--accent);color:#fff;border-color:var(--accent);font-weight:700;}
.canvas-save-btn.saved:hover{background:#245fcf;color:#fff;}
.canvas-save-btn.save-error{color:var(--danger);border-color:color-mix(in srgb,var(--danger) 45%,var(--line));}
/* v11.0.0 — Task 4: Overview's compact operational indicators (pjOverviewGapsHtml(), js/ui.js).
   Plain lines, not KPI tiles, per Costas' explicit "keep this compact / do not create
   dashboard-style KPI cards". .act-next/.act-date are the same classes renderActivityTimeline()
   already uses for a "→ next step" line — reused verbatim rather than styled twice. */
.pj-gaps{display:flex;flex-wrap:wrap;gap:6px;margin:2px 0 10px}
.pj-next{margin:2px 0 10px}
.pjb-sec-t{font-size:10.5px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:var(--muted);
  margin:10px 0 2px;padding-bottom:3px;border-bottom:1px solid var(--line)}
#side-body .pjb-sec .pj-kv{min-height:30px;padding:3px 0}
#side-body .pjb-sec .pj-kv .k{font-size:11px;text-transform:none;letter-spacing:0}

/* v8.1.5 — "classic" form look for the Projop panel's tabs, at Costas' request: the label is
   plain pale grey (no uppercase, no letter-spacing, not bold) and the VALUE sits in a white
   boxed field, so each row reads like a filled-in form rather than a run of text.
   Appended at the end of the file deliberately: the v6.4.1 block above sets .k/.v with the same
   specificity, and equal specificity means source order decides — the same cascade trap that
   caused the v4.8.4 .btn-danger bug and the v5.9.0 arrow-size regression. */
#side-body .pj-tab-panel .pj-kv,
#side-body .pj-tab-panel .detail-kv{
  align-items:center;border-bottom:none;padding:3px 0;column-gap:10px;
}
#side-body .pj-tab-panel .pj-kv .k,
#side-body .pj-tab-panel .detail-kv .k{
  font-size:12px;font-weight:400;letter-spacing:0;text-transform:none;color:var(--muted);
}
#side-body .pj-tab-panel .pj-kv .v,
#side-body .pj-tab-panel .detail-kv .v{
  background:#fff;border:1px solid var(--line);border-radius:6px;
  padding:5px 9px;min-height:28px;display:flex;align-items:center;
  font-size:13px;color:var(--ink);
}
/* a stacked row (Description, Notes) keeps the same white field, just full width */
#side-body .pj-tab-panel .pj-kv-stack .v{
  background:#fff;display:block;padding:8px 10px;line-height:1.45;
}
/* a value holding only a badge or chips shouldn't get a second box around it */
#side-body .pj-tab-panel .pj-kv:has(.stance-slider) .v,
#side-body .pj-tab-panel .pj-kv:has(.wt-slider) .v,
#side-body .pj-tab-panel .pj-kv:has(.chip) .v{
  background:transparent;border-color:transparent;padding-left:0;
}
/* the income pills already carry their own boxes — don't nest them in another */
#side-body .pj-tab-panel .pj-kv:has(.pj-inc) .v{background:transparent;border-color:transparent;padding-left:0;flex-wrap:wrap}

/* v8.1.6 — pale grey everywhere except the value fields themselves (Costas: "pale grey
   everything that is not inside a form field"). The panel, the tab strip and the section
   headings are all transparent so the sidebar's own grey shows through; the only white
   surfaces in the Projop panel are the boxed values. */
#side-body,
#side-body .pj-tabs,
#side-body .pj-tab-panel,
#side-body .pjb-sec,
#side-body .pjb-top{background:transparent;}
#side-body .pj-tab-panel .pj-kv .v,
#side-body .pj-tab-panel .detail-kv .v,
#side-body .pj-tab-panel .pj-kv-stack .v{background:#fff;}
/* the funnel-status chip and the income pills read as labels, not fields — keep them grey */
#side-body .pjb-fs,
#side-body .pj-inc{background:var(--bg);}

/* v8.1.7 — section headings on the Brief tab read darker. At --muted they sat at the same
   weight as the field labels beneath them, so the groups didn't separate. */
#side-body .pjb-sec-t{color:var(--ink);font-weight:700;border-bottom-color:var(--line-strong);}

/* ============================================================================
   v8.4.0 — Projop panel, "Option C": folder tabs joined to a white panel sheet.
   Costas picked this over an underline strip and a segmented control. The active
   tab physically connects to the sheet below it, so there is never any doubt
   which tab owns what you are reading.
   Consequence worth understanding: the panel is now WHITE, so the value boxes
   inside it can no longer be white too — they move to a pale tint and keep their
   border, which is what still makes them read as fields. This deliberately
   supersedes the v8.1.5/v8.1.6 colours; appended last so it wins the cascade.
   ========================================================================== */
aside#side{background:var(--side-bg);}

#side-body .pj-tabs{
  display:flex;gap:3px;align-items:flex-end;border-bottom:none;margin:0;padding:0;
}
#side-body .pj-tab-btn{
  font-size:12.5px;line-height:1.2;padding:6px 10px;margin:0;cursor:pointer;
  background:#e2e7ee;border:1px solid transparent;border-bottom:none;
  border-radius:7px 7px 0 0;color:#5a6674;font-weight:400;
}
#side-body .pj-tab-btn:hover{background:#e8edf3;color:#1b2530;}
#side-body .pj-tab-btn.active{
  background:#fff;border-color:#dbe2ea;color:#1b2530;font-weight:500;
  padding:7px 11px;position:relative;z-index:2;margin-bottom:-1px;
}
#side-body .pj-tab-panel{
  background:#fff;border:1px solid #dbe2ea;border-radius:0 8px 8px 8px;
  padding:12px;margin:0;position:relative;z-index:1;
}
/* value boxes: pale tint on the white sheet, so a field still reads as a field */
#side-body .pj-tab-panel .pj-kv .v,
#side-body .pj-tab-panel .detail-kv .v,
#side-body .pj-tab-panel .pj-kv-stack .v{
  background:#f7f9fb;border-color:#e3e8ef;
}
#side-body .pjb-top{border-bottom-color:#e3e8ef;}
#side-body .pjb-sec-t{border-bottom-color:#e3e8ef;}

/* --- form controls inside the tabs: one look everywhere. The Info tab was using raw
       browser defaults for its file input and buttons, which is why it looked like a
       different application from the Log tab. --- */
#side-body .pj-tab-panel input[type=text],
#side-body .pj-tab-panel input:not([type]),
#side-body .pj-tab-panel input[type=url],
#side-body .pj-tab-panel input[type=date],
#side-body .pj-tab-panel input[type=number],
#side-body .pj-tab-panel select,
#side-body .pj-tab-panel textarea{
  width:100%;box-sizing:border-box;min-height:30px;padding:5px 9px;
  border:1px solid #dbe2ea;border-radius:6px;background:#fff;
  font-size:13px;font-family:inherit;color:var(--ink);
}
#side-body .pj-tab-panel input:focus,
#side-body .pj-tab-panel textarea:focus,
#side-body .pj-tab-panel select:focus{outline:none;border-color:var(--accent);}
#side-body .pj-tab-panel input[type=file]{
  width:100%;box-sizing:border-box;font-size:12px;padding:5px 0;background:transparent;border:none;
}
#side-body .pj-tab-panel input[type=file]::file-selector-button{
  font:inherit;font-size:12px;padding:5px 10px;margin-right:9px;cursor:pointer;
  border:1px solid #dbe2ea;border-radius:6px;background:#f7f9fb;color:var(--ink);
}
#side-body .pj-tab-panel input[type=file]::file-selector-button:hover{background:#eef1f5;}
#side-body .pj-tab-panel .btn{min-height:30px;}
#side-body .pj-tab-panel .vn-add-row{display:flex;gap:6px;align-items:center;margin-top:8px;}
#side-body .pj-tab-panel .pj-tab-hint{margin:0 0 10px;}

/* --- Players list: rows, not statistics --- */
#side-body .stake-rgrp.anon>.stake-rgrp-body{margin-top:0;}
#side-body .stake-grp{border:1px solid #e3e8ef;border-radius:7px;overflow:hidden;margin-bottom:6px;background:#fff;}
#side-body .stake-grp-h{padding:7px 9px;background:#f7f9fb;border-bottom:1px solid #eef1f5;}
#side-body .stake-grp.open .stake-grp-body{border-top:none;}
#side-body .stake-row.stake-pn{padding:6px 9px 6px 22px;border-bottom:1px solid #f2f5f9;}
#side-body .stake-row.stake-pn:last-child{border-bottom:none;}
#side-body .stake-independent{margin-top:6px;background:#fff;}
#side-body .stake-independent>.stake-row.stake-pn{padding-left:9px;}
#side-body .stake-av{width:24px;height:24px;}

/* ============================ HOME (v8.8.0) ============================
   Slim band, hot strip, then five cards in one row. All motion is CSS and all of it is
   switched off under prefers-reduced-motion at the end of this block. */

.workspace.home-solo #side,
.workspace.home-solo .side-toggle{display:none;}

#home-view{flex:1;display:flex;flex-direction:column;min-width:0;overflow:hidden;background:var(--bg);}
.home-body{flex:1;overflow-y:auto;padding:14px 18px 20px;}
.home-body>*{animation:homeRise .40s cubic-bezier(.2,.7,.3,1) both;}
.home-body>*:nth-child(1){animation-delay:.02s;}
.home-body>*:nth-child(2){animation-delay:.08s;}
.home-body>*:nth-child(3){animation-delay:.14s;}
@keyframes homeRise{from{opacity:0;transform:translateY(9px);}to{opacity:1;transform:none;}}

/* ---- the slim band ---- */
.home-band{position:relative;display:flex;align-items:center;gap:12px;overflow:hidden;
  height:46px;padding:0 16px;margin-bottom:14px;border-radius:11px;color:#fff;
  background:linear-gradient(110deg,#22386a 0%,#3a63b8 62%,#4d7fd6 100%);}
.home-band-t{font-size:14.5px;font-weight:700;letter-spacing:-.2px;}
.home-band-d{font-size:11.5px;opacity:.74;font-weight:500;}
.home-band-art{margin-left:auto;flex:0 0 auto;width:190px;height:38px;opacity:.9;}
.band-edge{stroke:rgba(255,255,255,.40);stroke-width:1;animation:bandPulse 5.5s ease-in-out infinite;}
.band-node{fill:rgba(255,255,255,.85);animation:bandFloat 6.5s ease-in-out infinite;}
.band-n1{fill:#ffd873;} .band-n2{fill:#a8ffe4;}
.band-drift{animation:bandDrift 15s ease-in-out infinite;}
@keyframes bandDrift{0%,100%{transform:translate(0,0);}50%{transform:translate(-4px,2px);}}
@keyframes bandFloat{0%,100%{transform:translateY(0);}50%{transform:translateY(-2px);}}
@keyframes bandPulse{0%,100%{opacity:.32;}50%{opacity:.72;}}

/* ---- hot strip ---- */
.home-strip{margin-bottom:16px;}
.home-strip-h{display:flex;align-items:center;gap:9px;margin:0 2px 9px;}
.home-strip-h h3{margin:0;font-size:14px;font-weight:700;}
.home-strip-nav{margin-left:auto;display:flex;gap:6px;}
.projop-scroller{display:grid;grid-template-columns:30px minmax(0,1fr) 30px;gap:6px;align-items:center;min-width:0;}
.projop-scroll-arrow{width:30px;height:42px;border-radius:999px;border:1px solid var(--line-strong);background:var(--panel);
  cursor:pointer;font-size:22px;line-height:1;color:var(--ink);box-shadow:var(--shadow);
  transition:background .14s,color .14s,border-color .14s,opacity .14s;}
.projop-scroll-arrow:hover:not(:disabled){background:var(--accent);border-color:var(--accent);color:#fff;}
.projop-scroll-arrow:disabled{opacity:.3;cursor:default;box-shadow:none;}
.projop-scroll-arrow[hidden]{visibility:hidden;display:block;}
.projop-scroll-arrow.left{grid-column:1;}
.projop-scroll-track{grid-column:2;}
.projop-scroll-arrow.right{grid-column:3;}
.projop-scroll-track{display:flex;gap:12px;overflow-x:auto;padding:3px 2px 11px;
  scroll-snap-type:x proximity;scrollbar-width:thin;min-width:0;}
.projop-scroll-track::-webkit-scrollbar{height:8px;}
.projop-scroll-track::-webkit-scrollbar-thumb{background:var(--line-strong);border-radius:99px;}
.projop-scroll-item{position:relative;flex:0 0 252px;width:252px;min-width:252px;max-width:252px;
  scroll-snap-align:start;display:flex;flex-direction:column;box-sizing:border-box;}
.projop-scroll-item .projop-card{flex:1 1 auto;width:100%;min-height:0;box-sizing:border-box;}
.projop-scroll-foot{flex:0 0 18px;height:18px;min-height:18px;margin-top:4px;padding-left:3px;
  box-sizing:border-box;font-size:11px;line-height:14px;color:var(--muted);}
.home-hot{
  animation:homeRise .38s cubic-bezier(.2,.7,.3,1) both;}
.home-hot .board-card{border-radius:12px;padding:11px 12px;border-color:#e7c96b;box-shadow:var(--shadow);
  transition:transform .16s cubic-bezier(.2,.7,.3,1),box-shadow .16s;}
.home-hot:hover .board-card{transform:translateY(-3px);box-shadow:var(--shadow-lg);}
.home-hot .board-pin{display:none;}   /* the strip has its own star */
.home-hot-foot{color:var(--muted);}
.home-unpin{position:absolute;top:6px;right:7px;z-index:2;border:none;background:transparent;cursor:pointer;
  font-size:15px;line-height:1;color:#e0a800;padding:2px 4px;transition:transform .16s,color .16s;}
.home-unpin:hover{transform:scale(1.18);color:var(--danger);}
.home-empty-strip{background:var(--panel);border:1px dashed var(--line-strong);border-radius:12px;}

/* ---- the cards ----
   V11 Task 3 retired the old 4-up ".home-cards" grid (Projops Management / Actions Due / New
   log notes / Market info) in favor of: a full-width Pipeline Overview band, the strip above,
   a two-column Team Execution / Portfolio Health row (".home-row2col" below), then a full-width
   Market Signals card. */
.home-card{position:relative;overflow:hidden;min-height:318px;
  border:1px solid var(--line);border-radius:14px;background:var(--panel);box-shadow:var(--shadow);
  transition:transform .16s cubic-bezier(.2,.7,.3,1),box-shadow .16s,border-color .16s;}
.home-card:hover{border-color:var(--pc,var(--accent));box-shadow:var(--shadow-lg);}
/* the abstract mark: a soft disc of the card's own colour, bleeding off the top-right corner */
.home-card::before{content:"";position:absolute;top:-52px;right:-38px;width:120px;height:120px;border-radius:50%;
  background:var(--pc,var(--accent));opacity:.07;pointer-events:none;
  transition:transform .3s cubic-bezier(.2,.7,.3,1),opacity .3s;}
.home-card:hover::before{transform:scale(1.2);opacity:.12;}
.home-card.tone-a{--pc:#3a63b8;} .home-card.tone-b{--pc:#0f8a82;} .home-card.tone-c{--pc:#7a5cc4;}
.home-card.tone-d{--pc:#189a55;} .home-card.tone-e{--pc:#d23b3b;} .home-card.tone-f{--pc:#c4761f;}
.home-card-ic{flex:0 0 auto;width:34px;height:34px;display:grid;place-items:center;
  border-radius:10px;background:color-mix(in srgb,var(--pc) 13%,#fff);color:var(--pc);}
.home-card-ic svg{width:19px;height:19px;}
.home-card-t{font-size:13px;font-weight:700;color:var(--ink);line-height:1.25;}
.home-card-s{font-size:11.5px;color:var(--muted);line-height:1.5;}

/* EVERY card — navigation or panel — is a column whose first child is this header row. That
   is what keeps all five titles on one line (v8.8.1). min-height fixes the row height so a
   two-line title cannot shift the card next to it. */
.home-card{display:flex;flex-direction:column;}
.home-card-h{position:relative;display:flex;align-items:center;gap:10px;padding:11px 13px;
  min-height:58px;box-sizing:border-box;border-bottom:1px solid var(--line);}
.home-card-hr{margin-left:auto;display:flex;align-items:center;gap:7px;flex:0 0 auto;}
.home-card-n{font-size:19px;font-weight:700;line-height:1;letter-spacing:-.5px;color:var(--pc);
  font-variant-numeric:tabular-nums;}
.home-card-add{width:26px;height:26px;border-radius:8px;border:1px solid var(--line);
  background:var(--panel);color:var(--pc);font-size:16px;line-height:1;cursor:pointer;
  transition:background .14s,color .14s,border-color .14s;}
.home-card-add:hover{background:var(--pc);border-color:var(--pc);color:#fff;}
/* v10.5.0 — Today's explicit "View all actions →" label (openTodayView(), js/reports.js).
   Sits inside the same clickable .home-card-h header as the count, so no click handler of its
   own is needed — just a visible affordance, not a plain number like .home-card-n. */
.home-card-viewall{font-size:12px;font-weight:600;color:var(--accent);white-space:nowrap;}
.home-card-b{position:relative;flex:1;overflow-y:auto;padding:6px;scrollbar-width:thin;}
.home-card-b::-webkit-scrollbar{width:8px;}
.home-card-b::-webkit-scrollbar-thumb{background:var(--line-strong);border-radius:99px;}

/* v9.4.0: .home-card-nav (the old "whole card is a button" nav-card variant) is gone — every
   card on Home is a .home-card-panel now, Projops Funnel having moved into a plain button in
   the Hot Projops header (homeHotHtml()) and Projops Management having become a list card. */

/* ---- rows shared by the four panels ---- */
.home-empty{padding:14px 10px;font-size:12px;color:var(--muted);line-height:1.6;}
.home-empty a{color:var(--accent);}
.home-row{display:flex;align-items:flex-start;gap:8px;padding:8px 9px;border-radius:9px;cursor:pointer;
  border:1px solid transparent;transition:background .13s,border-color .13s,transform .13s;}
.home-row:hover{background:#f7f9fb;border-color:var(--line);transform:translateX(2px);}
.home-row-main{flex:1;min-width:0;}
.home-row-t{font-size:12.5px;color:var(--ink);line-height:1.45;}
.home-row-s{margin-top:2px;font-size:11px;color:var(--muted);display:flex;flex-wrap:wrap;gap:5px;align-items:center;}
.home-clamp{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;}
.home-act-check{margin-top:2px;flex:0 0 auto;}
.home-od{color:var(--danger);font-weight:600;}
.home-td{color:var(--accent);font-weight:600;}
.home-src{background:var(--bg);border:1px solid var(--line);border-radius:5px;padding:0 6px;color:var(--ink);font-weight:600;}
.home-hotdot{color:#e0a800;}
.home-n{font-size:11px;color:var(--muted);background:var(--bg);border-radius:10px;padding:1px 8px;font-weight:600;}

/* the pin star on a board card (board view) */
.board-card{position:relative;}
.board-pin{position:absolute;top:5px;right:5px;border:none;background:transparent;cursor:pointer;
  font-size:15px;line-height:1;padding:2px 4px;color:var(--line-strong);transition:transform .16s,color .16s;}
.board-pin:hover{color:#e0a800;transform:scale(1.18);}
.board-pin.on{color:#e0a800;}
.board-card.pinned{border-color:#e7c96b;}
.board-card-name{padding-right:22px;}
#pj-pin.on{border-color:#e0a800;color:#8a6a00;}

@media (prefers-reduced-motion: reduce){
  .home-body>*,.home-hot{animation:none;}
  .band-drift,.band-node,.band-edge{animation:none;}
  .home-card,.home-card::before,.home-row,.home-hot .board-card{transition:none;}
  .home-hot:hover .board-card,.home-row:hover{transform:none;}
}

/* v8.9.0 — a homeGoWhenReady() button waiting for the background load. Only the plain
   "Projops Funnel" button in the Hot Projops header uses this now (v9.4.0); it was originally
   written for the two now-gone .home-card-nav tiles. */
.is-loading{cursor:progress;opacity:.72;}

/* v9.0.0 — AI research review: the news list */
.ai-news-list{max-height:280px;overflow-y:auto;border:1px solid var(--line);border-radius:9px;padding:6px;background:var(--panel);}
.ai-news-row{display:flex;gap:9px;align-items:flex-start;padding:7px 8px;border-radius:7px;cursor:pointer;}
.ai-news-row:hover{background:var(--bg);}
.ai-news-row input{margin-top:3px;flex:0 0 auto;}
.ai-news-b{display:flex;flex-direction:column;gap:2px;min-width:0;}
.ai-news-t{font-size:12.5px;font-weight:600;color:var(--ink);}
.ai-news-n{font-size:11.5px;color:var(--muted);}
.ai-news-u{font-size:11px;color:var(--accent);word-break:break-all;}

/* ---- v9.0.1: stage colour on the Kanban columns ----
   Header solid in the stage colour, body a light mix of the same one, cards left white so
   they still read as objects sitting on the column. Appended last so it wins over the
   original .board-col-h / .board-col-body rules at equal specificity — the cascade discipline
   this file has used since v4.8.4. */
.board-col{
  background:color-mix(in srgb, var(--pc, var(--line-strong)) 8%, #fff);
  border-color:color-mix(in srgb, var(--pc, var(--line-strong)) 26%, #fff);
}
.board-col-h{
  background:var(--pc, var(--line-strong));
  border-bottom:none;
  padding:10px 12px;
}
.board-col-h .board-col-t{color:#fff;letter-spacing:.01em;}
.board-col-h .board-col-n{
  color:#fff;background:rgba(255,255,255,.22);font-weight:700;
}
.board-col-body{background:transparent;}
.board-col-empty{color:color-mix(in srgb, var(--pc, var(--muted)) 62%, var(--muted));}

/* v9.1.0 — the guide link on the Home band */
.home-band-help{margin-left:14px;font-size:11.5px;color:#fff;opacity:.85;text-decoration:none;
  border-bottom:1px solid rgba(255,255,255,.5);}
.home-band-help:hover{opacity:1;}

/* ---- v9.2.0 ---- */
/* the sidebar forced visible while a Projop panel is open (does not touch the saved preference) */
/* v12.2.4 — entering the canvas retracts the sidebar so the graph gets the full width. A class,
   not a stored setting: setSideCollapsed() strips it, so the collapse handle always wins. */
main.workspace.side-force-collapsed aside#side{width:0;flex-basis:0;min-width:0;border-right:0;}
main.workspace.side-force-collapsed .side-toggle{transform:translateY(-50%) rotate(180deg);}
main.workspace.side-collapsed.side-force-open aside#side{width:360px;flex-basis:360px;min-width:0;border-right:1px solid var(--line);}
main.workspace.side-collapsed.side-force-open .side-toggle{transform:translateY(-50%);}

/* v9.3.1 — hot strip cards all the same height, whatever their content */
.home-strip-track{align-items:stretch;}
.home-hot .board-card{display:flex;flex-direction:column;}
.home-hot .board-card-note{margin-top:auto;}

/* v9.3.2 — Home dashboard fonts nudged up a size across the board: the hot strip cards, the
   five-card row's titles/counts, and the row lists inside them (log notes, market info, due
   actions). Appended last so it wins over the v8.x declarations above at equal specificity —
   the same "re-assert at the end of the file" rule this file has used since the v4.8.4 fix. */
.home-band-t{font-size:15.5px;}
.home-band-d{font-size:12.5px;}
.home-strip-h h3{font-size:15px;}
.home-hot-foot{font-size:12px;}
.projop-scroll-item .projop-scroll-foot{font-size:12px;}
.home-hot .board-card-name{font-size:14px;}
.home-hot .board-card-brief{font-size:12px;}
.home-hot .board-card-ref,
.home-hot .board-card-meta,
.home-hot .board-chip{font-size:12px;}
/* v11.2.0 — replaces the old .home-hot .board-card-fs/.board-card-budget overrides now that
   both are part of .board-card-top, reusing the sidebar's pjb-fs/pjb-val classes directly. */
.home-hot .board-card-top .pjb-fs{font-size:12px;}
.home-hot .board-card-top .pjb-val{font-size:13px;}
.home-hot .board-card-note{font-size:12.5px;}
.home-hot .board-card-notecount{font-size:11.5px;}
.home-card-t{font-size:14px;}
.home-card-s{font-size:12.5px;}
.home-card-n{font-size:20px;}
.home-empty{font-size:13px;}
.home-row-t{font-size:13.5px;}
.home-row-s{font-size:12px;}
.home-n{font-size:12px;}

/* v9.4.0 — Actions Due split into three urgency groups (High/Medium/Low, derived purely from
   next_step_date since activities carries no priority column of its own — see the comment on
   homeActUrgency() in js/reports.js). Each group is just a small uppercase label + count above
   its own run of .home-row rows; an empty group renders nothing at all. */
.home-urg-grp{margin-bottom:6px;}
.home-urg-grp:last-child{margin-bottom:0;}
.home-urg-h{display:flex;align-items:center;gap:6px;padding:6px 9px 3px;
  font-size:11px;font-weight:700;letter-spacing:.04em;text-transform:uppercase;color:var(--muted);}
.home-urg-h .home-n{margin-left:auto;}
.home-urg-high .home-urg-h{color:var(--danger);}
.home-urg-med .home-urg-h{color:#c4761f;}
.home-urg-low .home-urg-h{color:var(--muted);}

/* Projops Management's rows need nothing beyond the shared .home-row/.home-row-t/.home-row-s
   look — no new class required. */

/* ---------------- v9.7.0: top bar tidy-up ----------------
   The four mutually exclusive main views (Home / Canvas / Board / Archive) render as ONE
   segmented control rather than four loose buttons, so a "place you can go" no longer looks
   identical to a canvas TOOL sitting beside it. Appended at the end of the file, same
   last-wins-the-cascade convention every other override pass in this project uses. */
.view-switch{display:inline-flex;align-items:center;gap:2px;background:var(--bg);
  border:1px solid var(--line);border-radius:9px;padding:2px;}
.vs-btn{display:inline-flex;align-items:center;gap:6px;border:1px solid transparent;
  background:transparent;border-radius:7px;padding:0 10px;min-height:30px;
  font-size:13px;font-weight:500;color:var(--muted);white-space:nowrap;cursor:pointer;
  transition:background .12s,color .12s,border-color .12s;}
.vs-btn .bi{width:15px;height:15px;flex:0 0 auto;}
.vs-btn:hover{color:var(--ink);background:#e8edf3;}
/* the active view: raised to look like the one surface you are standing on */
.vs-btn.on{background:var(--panel);border-color:var(--line-strong);color:var(--ink);
  font-weight:600;box-shadow:0 1px 2px rgba(16,24,40,.06);}
.vs-btn.on:hover{background:var(--panel);}
.vs-btn:focus-visible{outline:none;box-shadow:0 0 0 3px var(--accent-soft);border-color:var(--accent);}

/* the account overflow: icon-only, so it needs its own square-ish footprint */
#menu-more-btn{padding:0 9px;}
#menu-more-btn .bi{margin:0;}
/* v12.138.0 — the route-switch under the sign-in button. A quiet link, not a second button:
   there is one primary action on this card and it stays the primary action. */
.auth-alt{display:block;width:100%;margin-top:8px;border:0;background:none;cursor:pointer;
  font-size:11.5px;color:var(--muted);text-decoration:underline;padding:2px 0;}
.auth-alt:hover{color:var(--accent,#2f6df6);}

/* ---------------- v12.137.0 ACCOUNT ----------------
   The trigger stops being three dots and becomes WHO YOU ARE: avatar, role, caret. It has to
   read at a glance from across the room, because the question it answers ("am I signed in as
   me?") is one you ask without meaning to, and only notice you got wrong afterwards.
   Sizes follow the topbar's own scale — 11px role text, 22px avatar — so it sits on the same
   baseline as the buttons beside it rather than making the bar taller. */
.tb-acct-btn{display:inline-flex;align-items:center;gap:6px;padding:3px 6px 3px 3px;}
.acct-av{flex:none;width:22px;height:22px;border-radius:50%;overflow:hidden;
  display:inline-flex;align-items:center;justify-content:center;
  font-size:9.5px;font-weight:700;letter-spacing:.2px;line-height:1;
  background:var(--accent,#2f6df6);color:#fff;text-transform:uppercase;}
.acct-av img{width:100%;height:100%;object-fit:cover;display:block;}
.acct-role{font-size:11px;font-weight:600;line-height:1;white-space:nowrap;color:var(--muted);}
.acct-caret{width:12px;height:12px;flex:none;opacity:.55;}
/* A role nobody granted is not the same as a role somebody chose. An unmembered session falls
   back to admin-of-an-empty-workspace (see loadMembership), and that must not look normal. */
.acct-role.acct-role-none{color:#c0392b;}

/* The identity block at the top of the menu: picture, name, email, role and what the role can
   do. Not a clickable row — it is the heading that tells you whose menu this is. */
.drop-who{padding:8px 10px 9px;border-bottom:1px solid var(--line);margin-bottom:4px;
  display:flex;gap:9px;align-items:flex-start;}
.who-av{flex:none;width:34px;height:34px;border-radius:50%;overflow:hidden;
  display:inline-flex;align-items:center;justify-content:center;
  font-size:12px;font-weight:700;line-height:1;
  background:var(--accent,#2f6df6);color:#fff;text-transform:uppercase;}
.who-av img{width:100%;height:100%;object-fit:cover;display:block;}
.who-text{min-width:0;flex:1;}
.who-name{font-size:12.5px;font-weight:600;color:var(--ink);line-height:1.25;}
.who-mail{font-size:11px;color:var(--muted);line-height:1.3;word-break:break-all;}
.who-role{display:inline-block;margin-top:4px;font-size:10px;font-weight:700;line-height:1;
  padding:3px 7px;border-radius:999px;text-transform:uppercase;letter-spacing:.3px;
  background:var(--accent-soft,#e8eef8);color:var(--accent,#2f6df6);}
.who-role.who-role-none{background:#fdecea;color:#c0392b;}
.who-hint{font-size:10.5px;color:var(--muted);line-height:1.35;margin-top:4px;}

/* ---------------- v9.9.1 strip header ----------------
   V11 Task 3 removed the "Hot Projops"/"My Projops" tab control — the strip is Hot-only now,
   back to a plain <h3> (styled via .home-strip-h h3 above) carrying its own count badge. The
   .home-tabs/.home-tab rules that styled the old segmented control are gone with it. */
/* the nav buttons stay hard right */
.home-strip-h .home-strip-nav{margin-left:auto;}

/* ---------------- v9.9.2: the "Mine" toggle ----------------
   Sits beside the hot star on a board card. A filled dot rather than a second star, so the two
   read as different questions at a glance — "is this hot?" and "am I on it?" — and never as two
   of the same control. Deliberately quieter than the star: hot is a priority signal, mine is a
   fact about who is on the deal. */
.board-mine{position:absolute;top:5px;right:26px;border:none;background:transparent;cursor:pointer;
  font-size:13px;line-height:1;padding:2px;color:var(--line-strong);
  transition:color .12s,transform .12s;}
.board-mine:hover{color:var(--accent);transform:scale(1.18);}
.board-mine.on{color:var(--accent);}
/* the strip carries its own corner control, same as it does for the star */
.home-hot .board-mine{display:none;}
/* .home-unmine (the strip's own "remove me" dot) was removed with the My Projops tab in V11
   Task 3 — .board-mine above still covers the Board/Archive/Today card control. */
/* the panel button, matching the Hot button's own on-state */
#pj-mine.on{border-color:var(--accent);color:var(--accent);}

/* v9.9.3: voice notes — the recorder inside the central "+ Add note" picker, and the Play
   button a recorded/saved clip renders as in the Info tab and the Log tab's per-Projop rows. */
.voice-rec-row{display:flex;align-items:center;gap:8px;margin-bottom:6px;}
.voice-time{font-variant-numeric:tabular-nums;color:var(--muted);font-size:12.5px;}
/* v9.9.4: these were #an-voice-preview/#an-voice-rec (id-scoped to the Contact picker only)
   until voiceRecorderHtml() became a shared widget (Projop Log tab, Actions tab too) — class
   selectors now, so every recorder instance gets the same look regardless of its id prefix. */
.voice-preview{display:block;width:100%;margin-bottom:6px;}
.voice-rec-btn{color:var(--danger);border-color:var(--danger);}
.voice-rec-btn:hover{background:var(--danger-soft);}
.voice-play-btn{display:inline-flex;align-items:center;gap:4px;border:1px solid var(--line-strong);border-radius:7px;background:#fff;color:var(--ink);font-size:12.5px;padding:3px 9px;cursor:pointer;}
.voice-play-btn:hover{border-color:var(--accent);color:var(--accent);}
/* v12.99.0: compact, independent playback. It deliberately does not use #modal-root, so playing
   a voice note from an edit form cannot replace that form. */
.voice-player-popup{position:fixed;right:18px;bottom:18px;z-index:90;width:min(350px,calc(100vw - 24px));
  padding:10px 12px 12px;border:1px solid var(--line-strong);border-radius:12px;background:var(--panel);
  box-shadow:var(--shadow-lg);}
.voice-player-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:7px;
  color:var(--ink);font-size:13px;}
.voice-player-close{border:0;background:transparent;color:var(--muted);font-size:21px;line-height:1;
  min-width:24px;min-height:24px;padding:0;cursor:pointer;}
.voice-player-close:hover{color:var(--danger);}
.voice-player-audio{display:block;width:100%;height:36px;}

/* v9.9.5: legibility pass on the Projop panel — Costas: fonts/UI reading too small. Tab labels
   were 12.5px, action-row buttons (Report/Map/Research/Tidy/Edit/Delete etc, all .btn-sm inside
   .detail-actions) were 13px/29px-tall. Bumped a notch; appended last so it wins the cascade,
   same discipline every other override pass in this file has used. Scoped to the sidebar panel
   specifically, not every .btn-sm app-wide (toolbar/modal buttons are a different context and
   weren't part of this complaint). */
#side-body .pj-tab-btn{font-size:14px;padding:8px 12px;}
#side-body .pj-tab-btn.active{padding:9px 13px;}
#side-body .detail-actions .btn-sm{min-height:32px;padding:0 12px;font-size:14px;}

/* v10.2.0/v10.3.0: Home's Market info AND "New log notes" cards, both grouped by Projop — one
   header per Projop (its own name, not a generic type badge) instead of repeating it on every
   row. Shared rules: the two card's groups look identical on purpose. */
/* v12.77.0 — .home-mkt-grp / .home-mkt-grp-h moved to the accordion block at the end of this
   file. They used to share these rules with the log-notes card, including `color:var(--pc)` —
   a variable defined only on `.home-card.tone-*`, which these groups stopped living inside in
   v12.69.0, so the heading had no colour of its own. The .home-note-* half is untouched. */
.home-note-grp{margin-bottom:8px;}
.home-note-grp-h{display:flex;align-items:center;gap:5px;margin:10px 9px 2px;font-size:11px;
  font-weight:700;color:var(--pc);text-transform:uppercase;letter-spacing:.02em;}
.home-note-grp:first-child .home-note-grp-h{margin-top:4px;}
/* The Team Execution card header opens the full Actions page (wireDueCardOpen) — needs to read
   as clickable like the rest of Home's interactive rows. V11 Task 3 renamed the card from
   "Actions Due" (#home-card-due) to "Team Execution" (#home-card-exec); selector updated to match. */
#home-card-exec .home-card-h{cursor:pointer;}
#home-card-exec .home-card-h:hover{background:#f7f9fb;}

/* ===================== TODAY (v10.6.0) =====================
   V11 P0 Task 2. Today deliberately does NOT look like Home: Home is a grid of four fixed-height
   panel cards you read, Today is a stack of full-width bands you work, and every row ends in a
   primary verb button (.today-do). Reuses .home-row / .home-row-t / .home-row-s / .home-urg-grp /
   .home-empty / .home-n / .board-card verbatim — none of those are scoped to the Home cards, and
   reusing them is what keeps a row looking like a row everywhere in this app. Appended last,
   same discipline every other override pass in this file uses; nothing above was edited. */
.today-head{display:flex;align-items:flex-start;gap:12px;margin:0 2px 12px;}
.today-head-l{min-width:0;}
.today-head .board-title{margin:0;}
.today-sub{margin-top:3px;font-size:12px;color:var(--muted);}
.today-head .board-canvas-link{margin-left:auto;flex:0 0 auto;padding-top:4px;}
/* No "Me" contact set — Today cannot tell which work is yours, so it says so instead of
   silently rendering three empty bands and looking broken. */
.today-nome{margin:0 2px 12px;padding:10px 12px;border:1px dashed var(--line-strong);border-radius:10px;
  background:var(--panel);font-size:12px;color:var(--muted);line-height:1.6;}

.today-band{margin:0 2px 14px;border:1px solid var(--line);border-radius:12px;background:var(--panel);
  overflow:hidden;box-shadow:var(--shadow);}
.today-band-h{display:flex;align-items:center;gap:9px;padding:10px 13px;border-bottom:1px solid var(--line);}
.today-band-t{font-size:13px;font-weight:700;color:var(--ink);}
.today-band-b{padding:6px;max-height:420px;overflow-y:auto;scrollbar-width:thin;}
.today-band-b::-webkit-scrollbar{width:8px;}
.today-band-b::-webkit-scrollbar-thumb{background:var(--line-strong);border-radius:99px;}
/* .today-cols is unused as of v12.66.0 — People to Contact and My Signals became tabs rather
   than two side-by-side bands. Kept because it costs nothing and the two-column band layout may
   return elsewhere; delete it freely if it is still unreferenced later. */
.today-cols{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 12px;}
@media (max-width:1000px){ .today-cols{grid-template-columns:1fr;} }

/* v12.66.0 — Today's three tabs (Do Now · People to Contact · My Signals) and the Do Now sort
   bar. The tab strip deliberately reuses the band's own frame so the tabbed section reads as
   one panel below the Projop scroller rather than as a third kind of container. */
.today-tabwrap{border:1px solid var(--line);border-radius:10px;background:var(--card);margin-top:10px;overflow:hidden;}
.today-tabstrip{display:flex;gap:2px;padding:6px 6px 0;border-bottom:1px solid var(--line);flex-wrap:wrap;background:var(--bg);}
.today-tab{
  border:1px solid transparent;border-bottom:none;background:transparent;color:var(--muted);
  font-size:12.5px;font-weight:600;cursor:pointer;padding:7px 12px;border-radius:8px 8px 0 0;
  display:inline-flex;align-items:center;gap:6px;
}
/* v12.76.0 — Costas: "when i am in an active tab or hover over another they should become white
   for better UI". The strip is the grey ground, the tab you are on and the tab under the cursor
   are white. The active tab keeps its -1px bottom overlap so it merges into the pane below. */
.today-tab:hover{color:var(--ink);background:var(--card);border-color:var(--line);border-bottom-color:transparent;}
.today-tab.on{background:var(--card);border-color:var(--line);color:var(--ink);margin-bottom:-1px;border-bottom:1px solid var(--card);}
.today-pane .today-band-b{max-height:520px;}
.today-sortbar{
  display:flex;align-items:center;gap:8px;padding:2px 4px 8px;
  border-bottom:1px solid var(--line);margin-bottom:6px;
}
.today-sort-n{font-size:12px;color:var(--muted);margin-right:auto;}
.today-sort-l{font-size:11.5px;color:var(--muted);}
.today-sort{font-size:12px;padding:3px 6px;border:1px solid var(--line);border-radius:6px;background:var(--card);color:var(--ink);}
/* Importance as ACTION_PRIORITY's own symbol, not a fourth coloured pill — a flat list of many
   actions has to stay scannable. */
.today-prio{flex:none;font-weight:800;font-size:12px;letter-spacing:-0.5px;width:22px;text-align:center;}

/* The verb button. This is the visible difference from Home's read-only Actions card, so it has
   to look like something you press, not like a chip. */
.today-row{align-items:center;}
.today-do{flex:0 0 auto;align-self:center;border:1px solid var(--line-strong);background:var(--panel);
  color:var(--ink);border-radius:8px;padding:5px 11px;font-size:11.5px;font-weight:600;cursor:pointer;
  white-space:nowrap;transition:background .13s,border-color .13s,color .13s;}
.today-do:hover{background:var(--accent);border-color:var(--accent);color:#fff;}
.today-row:hover{transform:none;}   /* the button is the affordance here, not a row nudge */

/* The two scope sub-groups inside each due bucket — "On my Projops" / "Not on a Projop".
   Deliberately quieter than the bucket heading above them: the deadline is the primary
   grouping, ownership is the secondary one. */
.today-scope{margin:0 0 2px;}
.today-scope-h{display:flex;align-items:center;gap:6px;padding:3px 9px 2px;font-size:10.5px;
  font-weight:600;color:var(--muted);opacity:.85;}
.today-scope-h .home-n{margin-left:auto;}
.today-urg-gap .home-urg-h{color:#7a5cc4;}
/* The honest footnote: open actions that sit on Projops you are not on are counted, not shown —
   Today is a personal screen, and hiding them silently would make it under-report. */
.today-elsewhere{padding:8px 10px 4px;font-size:11px;color:var(--muted);line-height:1.6;}
.today-elsewhere a{color:var(--accent);}

/* My ProjOps: the SAME boardCardHtml() card as the Pipeline, Archive and Home strip. The
   only Today-specific thing is the footer; the card markup itself is untouched. No age line and
   no stale badge — nothing on Today judges a Projop's relevance (see js/reports.js). */
.today-opps-track{align-items:stretch;}
.today-opp .board-card{border-radius:12px;padding:11px 12px;border-color:#e7c96b;box-shadow:var(--shadow);
  transition:transform .16s cubic-bezier(.2,.7,.3,1),box-shadow .16s;}
.today-opp:hover .board-card{transform:translateY(-3px);box-shadow:var(--shadow-lg);}
.today-opp-foot{font-weight:600;color:#7a5cc4;}

/* v12.114.0 — My ProjOps is a five-column, two-visible-row grid. More than ten cards stay
   directly underneath and are reached with the grid's compact vertical scrollbar. */
.projop-scroller.is-grid{display:block;}
.projop-scroller.is-grid .projop-scroll-arrow{display:none!important;}
.projop-scroller.is-grid .today-opps-track{
  display:grid;grid-template-columns:repeat(5,minmax(0,1fr));grid-auto-rows:186px;
  gap:10px 12px;max-height:382px;overflow-x:hidden;overflow-y:auto;padding:3px 8px 3px 2px;
  scroll-snap-type:y proximity;scrollbar-width:thin;align-items:stretch;
}
.projop-scroller.is-grid .today-opps-track::-webkit-scrollbar{width:8px;height:0;}
.projop-scroller.is-grid .today-opps-track .projop-scroll-item{
  width:100%;min-width:0;max-width:none;height:186px;scroll-snap-align:start;
}
.projop-scroller.is-grid .pjc-compact .pjc-media{height:112px;}
.projop-scroller.is-grid .pjc-compact .pjc-body{padding:7px 9px;gap:0;}
.projop-scroller.is-grid .pjc-compact .pjc-name{font-size:12px;}
.projop-scroller.is-grid .pjc-compact .pjc-ref{font-size:9.5px;padding:1px 5px;}
@media (max-width:980px){
  .projop-scroller.is-grid .today-opps-track{grid-template-columns:repeat(3,minmax(0,1fr));}
}
@media (max-width:620px){
  .projop-scroller.is-grid .today-opps-track{grid-template-columns:repeat(2,minmax(0,1fr));}
}

/* ===================== HOME REDESIGN (V11 Task 3, v10.7.0) =====================
   Pipeline Overview (full width) -> Priority ProjOps strip (unchanged) -> a two-column
   Team Execution / Portfolio Health row -> Market Signals (full width, unchanged body).
   Appended last, same last-wins-the-cascade convention as every other override pass in this
   file. */

/* ---- Pipeline Overview ---- */
.home-card.home-pipeline{min-height:0;margin-bottom:16px;}
.home-pipe-stat{flex:1 1 160px;min-width:150px;border:1px solid var(--line);border-radius:10px;
  padding:10px 12px;cursor:pointer;transition:background .13s,border-color .13s;}
.home-pipe-stat:hover{background:#f7f9fb;border-color:var(--pc,var(--accent));}
.home-pipe-v{display:block;font-size:19px;font-weight:700;color:var(--ink);
  font-variant-numeric:tabular-nums;letter-spacing:-.3px;}
.home-pipe-l{display:block;margin-top:2px;font-size:11.5px;color:var(--muted);}
.home-pipe-funnel{display:flex;flex-wrap:wrap;gap:8px;padding:10px 13px 13px;cursor:pointer;}
.home-pipe-stage{flex:1 1 100px;min-width:88px;text-align:center;border-radius:9px;padding:8px 6px;
  background:color-mix(in srgb,var(--pc,var(--line-strong)) 10%,#fff);
  border:1px solid color-mix(in srgb,var(--pc,var(--line-strong)) 30%,#fff);
  transition:transform .13s;}
.home-pipe-funnel:hover .home-pipe-stage{transform:translateY(-1px);}
.home-pipe-stage-n{display:block;font-size:16px;font-weight:700;color:var(--pc,var(--ink));
  font-variant-numeric:tabular-nums;}
.home-pipe-stage-l{display:block;margin-top:1px;font-size:10.5px;color:var(--muted);
  text-transform:uppercase;letter-spacing:.02em;}

/* ---- Team Execution / Portfolio Health two-column row ---- */
.home-row2col{display:grid;grid-template-columns:1fr 1fr;gap:12px;align-items:stretch;margin-bottom:16px;}
@media (max-width:900px){ .home-row2col{grid-template-columns:1fr;} }
.home-row2col .home-card{min-height:0;}
.home-stat-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:8px;padding:8px;}
.home-stat-tile{border:1px solid var(--line);border-radius:10px;padding:10px 12px;cursor:pointer;
  transition:background .13s,border-color .13s;}
.home-stat-tile:hover{background:#f7f9fb;border-color:var(--pc,var(--accent));}
.home-stat-n{display:block;font-size:20px;font-weight:700;color:var(--ink);
  font-variant-numeric:tabular-nums;letter-spacing:-.4px;}
.home-stat-n.zero{color:var(--muted);}
.home-stat-n.danger{color:var(--danger);}
.home-stat-l{display:block;margin-top:2px;font-size:11.5px;color:var(--muted);}

/* Market Signals is now the sole full-width card at the bottom — no grid sibling to stretch
   against, so it should not carry the old four-up card's fixed min-height. */
#home-card-market{min-height:0;}

/* ===================== HOME KPI STRIP (V11 Task 3 correction, still v10.7.0) =====================
   Five leading-indicator tiles above Pipeline Overview — a fast executive summary. Reuses
   .home-stat-tile/.home-stat-n/.home-stat-l verbatim (already generic, not scoped to a
   .home-card), so a tile here looks identical to one inside Team Execution/Portfolio Health.
   Appended last, same last-wins-the-cascade convention as every other override pass here. */
/* v12.67.0 — THREE pills, not six (Actions Due / No Next Action / Decision-Maker Gaps removed),
   so the grid is three columns rather than six. */
.home-kpi-strip{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;padding:12px 13px 4px;margin:0;}
@media (max-width:640px){ .home-kpi-strip{grid-template-columns:repeat(2,minmax(0,1fr));} }

/* The "narrower strip" Costas asked for. Pipeline Overview moved BELOW the Projop scroller in
   v12.67.0, so it is supporting context rather than the lead: same information, less vertical
   weight, smaller numerals. Nothing is hidden — only the scale changes. */
.home-pipeline-slim .home-kpi-strip{padding:8px 10px 2px;gap:6px;}
.home-pipeline-slim .home-pipe-stat{padding:7px 10px;}
.home-pipeline-slim .home-pipe-v{font-size:16px;}
.home-pipeline-slim .home-pipe-l{font-size:11px;}
.home-pipeline-slim .home-stat-n{font-size:18px;}
.home-pipeline-slim .home-pipe-funnel{padding-top:4px;}
.home-kpi-tile{background:var(--panel);box-shadow:none;min-width:0;}
.home-pipeline-summary .home-pipe-stat{min-width:0;background:var(--panel);}
.home-budget-kpi{border-color:color-mix(in srgb,var(--accent) 35%,var(--line));}
.home-budget-kpi .home-pipe-l{font-weight:600;color:var(--accent);}

/* ===================== PROJOP WORKSPACE/EDIT-FORM MERGE (v12.0.0) =====================
   Every Overview/Info field is now inline-editable rather than living in a separate Edit modal
   — .pj-field wraps a plain label + input/select/textarea (.pj-field-input, styled by the
   existing #side-body .pj-tab-panel input/select/textarea rules above, unchanged); .pj-field-grid
   lays a group's fields out two-up, .pj-field-wide spans both columns for a long text field
   (Name, Brief, Description, Executive summary, etc). Appended last, same last-wins-the-cascade
   convention as every other override pass in this file. */
.pj-field-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px 14px;padding:2px 0 6px;}
@media (max-width:520px){ .pj-field-grid{grid-template-columns:1fr;} }
.pj-field{display:flex;flex-direction:column;gap:3px;min-width:0;}
.pj-field-wide{grid-column:1 / -1;}
.pj-field label{font-size:10.5px;font-weight:600;letter-spacing:.03em;text-transform:uppercase;color:var(--muted);}
.pj-field-input.pj-field-saving{opacity:.6;}
.pj-field-value{min-height:28px;padding:5px 0;color:var(--ink);line-height:1.45;white-space:normal;overflow-wrap:anywhere;}
.pj-field-empty{color:var(--muted);}
.pj-preview-mode .pj-field-grid{padding-bottom:7px;}
.pj-preview-mode .pj-field{gap:1px;}
.pj-preview-mode .pj-inline-field-sec{margin-bottom:5px;}
.pj-preview-mode .pj-field.pj-field-inline label{padding-top:6px;}
/* v12.0.6 — Name/Location/Brief are single-field rows: one label on the left, control on the
   right. They deliberately have no duplicate .pjb-sec-t heading. */
.pj-inline-field-sec{margin:0 0 8px;}
.pj-field.pj-field-inline{display:grid;grid-template-columns:132px minmax(0,1fr);gap:12px;align-items:start;}
.pj-field.pj-field-inline label{padding-top:8px;}
.pj-field.pj-field-inline .pj-field-input{width:100%;min-width:0;}
@media (max-width:520px){
  .pj-field.pj-field-inline{grid-template-columns:78px minmax(0,1fr);gap:8px;}
}
/* ---- v12.3.0 — ONE layout rule for every field on the Projop workspace ------------------
   Costas: "use as much as you can the rule label on the left, info/field on the right", and
   remove the section headings that repeated a field's own label. Every field on Overview and
   Info is now a .pj-inline-field-sec, so these rules cover the whole surface rather than the
   three rows v12.0.6 introduced them for. A hairline under each row is what makes a stack of
   label/value pairs readable without the headings that used to separate them. */
.pj-tab-panel .pj-inline-field-sec{border-bottom:1px solid var(--line);padding-bottom:6px;}
.pj-tab-panel .pj-inline-field-sec:last-child{border-bottom:0;}
.pj-tab-panel .pj-field.pj-field-inline label{
  font-size:10.5px;font-weight:700;letter-spacing:.04em;text-transform:uppercase;color:var(--muted);}
/* The mode tint. Preview = pale grey (read), Edit = pale yellow (Costas: "to alert the editor").
   Applied to ALL FIVE panels via showProjopDetails()'s modeCls, not only the two with fields. */
#side-body .pj-tab-panel.pj-preview-mode,
#side-body .pj-tab-panel.pj-edit-mode{
  border:1px solid var(--line);border-radius:10px;padding:12px 14px;}
#side-body .pj-tab-panel.pj-preview-mode{background:#f4f6f9;}
#side-body .pj-tab-panel.pj-edit-mode{background:#fdf7dd;border-color:#e6d9a2;}
#side-body .pj-tab-panel.pj-edit-mode .pj-inline-field-sec{border-bottom-color:#e6d9a2;}
#side-body .pj-tab-panel.pj-edit-mode .pj-field-input{background:#fff;}
/* Profile-only controls that are richer than one input (organization picker, photo/logo and
   Archived) obey the same label-left/control-right grid as every .pj-inline-field-sec row. */
#side-body .pj-tab-panel.pj-edit-mode > .field{display:grid;grid-template-columns:132px minmax(0,1fr);
  gap:4px 12px;align-items:start;margin:0 0 8px;padding:0 0 6px;border-bottom:1px solid #e6d9a2;}
#side-body .pj-tab-panel.pj-edit-mode > .field > label:first-child{margin:0;padding-top:8px;
  color:var(--muted);font-size:10.5px;font-weight:700;letter-spacing:.04em;text-transform:uppercase;}
#side-body .pj-tab-panel.pj-edit-mode > .field > :not(label:first-child){grid-column:2;min-width:0;}
#side-body .pj-tab-panel .of-archive-check{display:flex;align-items:center;justify-self:start;gap:8px;
  margin:0;padding:7px 10px;border:1px solid var(--line-strong);border-radius:7px;background:#fff;
  color:var(--ink);cursor:pointer;}
#side-body .pj-tab-panel .of-archive-check input{width:15px;height:15px;min-height:0;margin:0;accent-color:var(--accent);}
#side-body .pj-tab-panel .of-archive-check span{display:flex;align-items:baseline;gap:8px;}
#side-body .pj-tab-panel .of-archive-check b{font-size:12px;}
#side-body .pj-tab-panel .of-archive-check small{color:var(--muted);font-size:10.5px;font-weight:400;}
@media(max-width:520px){
  #side-body .pj-tab-panel.pj-edit-mode > .field{grid-template-columns:78px minmax(0,1fr);gap:4px 8px;}
}
/* Base success button; semantic action colours below keep verbs consistent. */
.btn-success{background:var(--ok);border-color:var(--ok);color:#fff;}
.btn-success:hover{background:#13803f;border-color:#13803f;color:#fff;}
.btn-saved-pale{background:#e5e7eb;border-color:#aeb6c0;color:#4b5563;}

/* v12.106.0 — verbs have one colour everywhere. These semantic classes are applied to buttons
   from their visible label by syncActionButtonStyles(), including buttons created after load. */
button.action-save{background:#189a55!important;border-color:#137c45!important;color:#fff!important;}
button.action-save:hover{background:#137c45!important;border-color:#0f6738!important;color:#fff!important;}
button.action-edit{background:#e58a1f!important;border-color:#bd6d12!important;color:#fff!important;}
button.action-edit:hover{background:#cb7517!important;border-color:#a85d0d!important;color:#fff!important;}
button.action-delete{background:#d23b3b!important;border-color:#ae2929!important;color:#fff!important;}
button.action-delete:hover{background:#b83232!important;border-color:#962525!important;color:#fff!important;}
button.btn-danger{background:#d23b3b!important;border-color:#ae2929!important;color:#fff!important;}
button.btn-danger:hover{background:#b83232!important;border-color:#962525!important;color:#fff!important;}
button.action-add{background:#3a63b8!important;border-color:#28417a!important;color:#fff!important;}
button.action-add:hover{background:#315499!important;border-color:#1f3562!important;color:#fff!important;}
button.action-done{background:#e5e7eb!important;border-color:#aeb6c0!important;color:#4b5563!important;cursor:default;}
/* Flags row — Hot/Mine/Archived as inline toggle chips, replacing the old pj-pin/pj-mine action
   buttons and the Edit form's Archived checkbox. Plain chip look, same family as .pjf-fs/.badge. */
.pj-flags-row{display:flex;flex-wrap:wrap;gap:6px;padding:2px 0 6px;}
.pj-flag-chip{font-size:12px;padding:4px 11px;border-radius:9px;border:1px solid var(--line);
  background:var(--bg);color:var(--muted);cursor:pointer;font-weight:600;}
.pj-flag-chip:hover{border-color:var(--accent);color:var(--accent);}
.pj-flag-chip.on{background:var(--accent-soft);border-color:var(--accent);color:var(--accent);}
/* v12.0.2 — Flags moved OUT of Overview's body and into the action-button row itself, right-
   aligned, per Costas: "move it on the right side of the row with the action buttons." The
   buttons keep their own left-aligned group so wrapping (narrow sidebar) puts flags on their own
   line rather than interleaving with Report/Map/Research/Delete. */
.pj-actions-row{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px;}
.pj-actions-btns{display:flex;gap:8px;flex-wrap:wrap;}
.pj-flags-inline{display:flex;flex:none;}
.pj-flags-inline .pj-flags-row{padding:0;}
/* v12.0.2 — Sector badge, same family as .side-ref-badge, sitting top-right next to Stage. Both
   Ref and Sector are click-to-edit here now (wireHeaderBadgeEdit(), js/ui.js) — the separate
   Overview body fields were removed as a duplicate. An empty one shows a muted "+ Ref"/
   "+ Sector" placeholder rather than hiding, since this is the only way to set either value. */
.side-sector-badge{display:inline-flex;align-items:center;justify-content:center;min-width:26px;height:22px;
  padding:0 8px;border-radius:6px;background:var(--accent-soft);color:var(--accent);
  font-size:11.5px;font-weight:700;letter-spacing:.02em;flex:none;margin-right:6px;cursor:pointer;}
.side-ref-badge{cursor:pointer;}
.side-ref-badge.empty,.side-sector-badge.empty{background:transparent;border:1px dashed var(--line);color:var(--muted);font-weight:600;}
.side-ref-badge:hover,.side-sector-badge:hover{border-color:var(--accent);}
.side-badge-input{width:84px;height:20px;font-size:11.5px;font-weight:600;padding:0 4px;
  border-radius:5px;border:1px solid var(--accent);background:var(--bg);color:var(--fg);}

/* ==========================================================================
   v12.3.1 — the Projop/record popup is a fixed rectangle and scrolls inside.
   The title bar (.side-head) is outside #side-body and so is already fixed; the
   action buttons and the tab strip are INSIDE it (setSide() writes them as part
   of the body), so they are pinned with position:sticky rather than by moving
   them out into the head — moving them would mean every non-Projop caller of
   setSide() (org, contact, link, path finder) suddenly had to populate a shared
   header region it knows nothing about. They sit on the panel's own ground
   colour so scrolled content passes cleanly underneath.
   ========================================================================== */
.pj-popup-panel #side-body .pj-sticky-head{
  position:sticky;top:0;z-index:5;background:var(--side-bg);
  margin:-8px -10px 0;padding:8px 10px 0;border-bottom:1px solid var(--line);
  box-shadow:0 5px 8px rgba(30,45,65,.08);}
.pj-popup-panel #side-body .pj-sticky-head .pj-actions-row{margin-bottom:10px;}
.pj-popup-panel #side-body .pj-tab-panel{padding-top:10px;}

/* ==========================================================================
   v12.4.0 — the Players tab, grouped by SIDE and condensed.
   Six groups in Costas' order (Key players first, then the five PLAYER_SIDES),
   companies as accordion heads with their people nested one line each:
   photo · LAST first · title, controls hard right. Appended last so it wins
   over the earlier .stake-row sizing.
   ========================================================================== */
.stake-side{margin:0 0 14px;}
.stake-side:last-child{margin-bottom:0;}
.stake-side-t{
  font-size:10.5px;font-weight:800;letter-spacing:.07em;text-transform:uppercase;
  color:var(--pc,var(--muted));padding:0 0 4px;margin:0 0 6px;
  border-bottom:2px solid var(--pc,var(--line));}
.stake-side-empty{margin:2px 0 6px;}
.stake-grp-empty{margin:2px 0 4px 6px;font-size:12px;}
.stake-side .stake-grp{margin-bottom:4px;}
/* One line per person: the name/title block takes the slack, controls stay hard right. */
.stake-row.stake-pn{padding:3px 8px;gap:7px;}
.stake-row.stake-co{padding:4px 8px;}
.stake-person{display:flex;align-items:baseline;gap:7px;flex:1;min-width:0;}
.stake-person .stake-name{flex:0 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.stake-person .stake-name b{font-weight:700;}
.stake-title{
  flex:1 1 auto;min-width:0;font-size:11.5px;color:var(--muted);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.stake-count{
  flex:none;font-size:11px;font-weight:700;color:var(--muted);
  background:var(--bg);border:1px solid var(--line);border-radius:8px;padding:1px 7px;}
.stake-count-key{color:var(--accent);}
/* v12.4.1 — the ⓘ on a person row: quiet until the person actually has notes on this Projop. */
.stake-info{
  flex:none;border:1px solid transparent;background:none;cursor:pointer;
  font-size:13px;line-height:1;color:var(--muted);padding:2px 5px;border-radius:7px;
  display:inline-flex;align-items:center;gap:3px;}
.stake-info:hover{color:var(--accent);border-color:var(--accent);background:var(--accent-soft);}
.stake-info.has{color:var(--accent);}
.stake-info-n{font-size:10px;font-weight:700;}

/* ==========================================================================
   v12.5.0 — the Log tab: composer on top in its own frame, the stream below,
   and one line per entry (date · who · note · edit/delete).
   ========================================================================== */
.log-composer{
  background:var(--panel);border:1px solid var(--line-strong);border-radius:10px;
  padding:10px 12px;margin:0 0 4px;}
.log-composer .nc-add{margin:0;}
.log-stream{border-top:2px solid var(--line-strong);padding-top:10px;margin-top:12px;}
.log-head,.log-row{
  display:grid;grid-template-columns:74px 132px minmax(0,1fr) 54px;
  gap:10px;align-items:start;}
.log-head{
  font-size:10px;font-weight:800;letter-spacing:.06em;text-transform:uppercase;
  color:var(--muted);padding:0 8px 5px;border-bottom:1px solid var(--line);}
.log-row{
  padding:7px 8px;border-bottom:1px solid var(--line);background:none;border-radius:0;
  margin:0;}
.log-row .log-when,.log-row .log-who,.log-row .log-body,.log-row .log-acts{align-self:start;margin-top:0;padding-top:0;}
.log-row .log-body{font-size:13px;font-weight:400;line-height:1.4;color:#5686ad;}
.log-row .log-who,.log-row .who-cell{align-items:flex-start;}
.log-row:last-child{border-bottom:0;}
.log-row:hover{background:var(--accent-soft);}
.log-when{font-size:11.5px;color:var(--muted);white-space:nowrap;padding-top:2px;}
.log-who{min-width:0;overflow:hidden;}
.log-body{min-width:0;overflow-wrap:anywhere;}
/* v12.128.0 — the entry's own title, back in the listing. Heavier than the body so a scan down
   the column reads as headlines, and the only thing on the row when nothing else was typed. */
.log-title{font-weight:700;color:var(--ink);margin:0 0 2px;}
/* An attached file: one chip, the icon says what it is, the click opens it. Deliberately a
   button and not a link — the address is signed at click time and would be stale in an href. */
.note-attach{display:inline-flex;align-items:center;gap:6px;max-width:100%;margin:5px 0 0;
  padding:3px 10px 3px 7px;border:1px solid var(--line-strong);border-radius:999px;
  background:var(--panel);color:var(--ink);font:inherit;font-size:11.5px;cursor:pointer;
  text-align:left;transition:background .14s,border-color .14s;}
.note-attach:hover{background:#eef3fb;border-color:var(--accent);}
.note-attach-ico{font-size:13px;line-height:1;flex:0 0 auto;}
.note-attach-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:600;}
.note-attach-size{color:var(--muted);flex:0 0 auto;}
.note-attach-static{cursor:default;}
.note-attach-static:hover{background:var(--panel);border-color:var(--line-strong);}
/* The paperclip in the composer, and the chip that confirms what you picked before you press Add. */
.nc-attach{display:inline-flex;align-items:center;gap:4px;padding:4px 8px;border-radius:8px;
  border:1px solid var(--line-strong);background:var(--panel);cursor:pointer;font-size:13px;
  align-self:flex-start;}
.nc-attach:hover{border-color:var(--accent);}
.nc-attach-sm{font-size:12px;padding:2px 7px;}
.nc-attach-chosen{display:flex;align-items:center;gap:6px;margin:6px 0 0;font-size:11.5px;color:var(--ink);}
.nc-attach-x{border:0;background:transparent;color:var(--muted);cursor:pointer;font-size:14px;line-height:1;padding:0 2px;}
.nc-attach-x:hover{color:var(--danger);}
.nc-e-attach{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:6px 0 0;font-size:11.5px;}
.nc-e-attach-rm-l{display:inline-flex;align-items:center;gap:4px;color:var(--muted);cursor:pointer;}
.log-acts{display:flex;gap:2px;justify-content:flex-end;align-items:flex-start;}
/* An entry being edited in place drops the grid — the inline form needs the full width. */
.log-row.nc-editing{display:block;}
@media (max-width:560px){
  .log-head{display:none;}
  .log-row{grid-template-columns:1fr auto;grid-template-areas:"when acts" "who who" "body body";}
  .log-when{grid-area:when;} .log-who{grid-area:who;} .log-body{grid-area:body;} .log-acts{grid-area:acts;}
}
/* Shared "who" cell — the Log tab now, the Actions list from v12.6.0. */
.who-cell{display:inline-flex;align-items:center;gap:5px;min-width:0;font-size:12px;}
.who-cell .who-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.who-none{color:var(--muted);}
.who-av{width:20px;height:20px;border-radius:50%;object-fit:cover;flex:none;}
.who-av.ini{
  display:inline-flex;align-items:center;justify-content:center;background:var(--line-strong);
  color:var(--ink);font-size:9px;font-weight:700;}
/* Manage Team */
.team-row{
  display:flex;align-items:center;gap:10px;padding:6px 8px;border:1px solid var(--line);
  border-radius:8px;margin-bottom:6px;}
.team-row .who-cell{flex:1;min-width:0;}
.team-title{font-size:11.5px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}

/* ==========================================================================
   v12.6.0 — the Actions tab: add form on top, then one group per responsible.
   Row: assignee photo · assigner photo · date · importance · task · edit/delete
   · status hard right (Costas' own left-to-right order).
   ========================================================================== */
.act-composer{
  display:grid;grid-template-columns:minmax(0,1fr) 118px 118px 92px 130px auto auto;
  gap:6px;align-items:center;
  background:var(--panel);border:1px solid var(--line-strong);border-radius:10px;
  padding:10px 12px;margin:0 0 4px;}
.act-composer input,.act-composer select{min-width:0;}
.act-composer .ac-new-sum{font-weight:600;}
@media (max-width:640px){ .act-composer{grid-template-columns:1fr 1fr;} .act-composer .ac-new-sum{grid-column:1 / -1;} }
.act-stream{border-top:2px solid var(--line-strong);padding-top:10px;margin-top:12px;}
.act-grp{margin:0 0 12px;}
.act-grp-t{
  display:flex;align-items:center;gap:8px;padding:0 0 4px;margin:0 0 5px;
  border-bottom:1px solid var(--line);font-size:12px;font-weight:700;}
.act-grp-t .act-grp-n{
  margin:0;font-size:10px;font-weight:700;color:var(--muted);
  background:var(--bg);border:1px solid var(--line);border-radius:8px;padding:1px 6px;}
/* v12.91.0 — Costas' column order: created · date · what needs doing · responsible · notify ·
   buttons · progress. He also asked to "remove border from actions and just use alternating color
   backgrounds to have a more condensed ui", so the row separator is gone and the banding does the
   work — which is also why the header row has to be excluded from the striping (:nth-of-type
   would otherwise count it and flip every band). */
/* v12.91.2 — Costas' revised order: FROM (creator) · date · TO (responsible) · what needs doing ·
   notify · buttons · progress. The two faces sit together at the left so a row reads "from X, on
   this date, to Y"; the header labels collided before because RESPONSIBLE and NOTIFY were being
   asked to fit inside 26px avatar columns. */
/* v12.91.3 — EVERY track is a fixed width except the task. This is the fix for the header sitting
   over the wrong columns: each .action-row is its OWN grid container, so any `auto` or
   content-sized track resolves per row — the header's widths came from its words, the rows' from
   their avatars, and the two never lined up. Fixed tracks make every row compute identically.
   The first column is wide enough for the word "From" rather than clipping it to "FR…". */
.action-row{
  display:grid;grid-template-columns:44px 78px 30px minmax(0,1fr) 104px 78px 112px;
  gap:8px;align-items:center;padding:4px 8px;border-bottom:0;
  background:none;border-radius:0;margin:0;}
.act-stream .action-row:not(.act-head-row):nth-of-type(even){background:var(--bg);}
.action-row:hover{background:var(--accent-soft);}
/* the header: same grid, so every label sits over its own column */
.act-head-row{position:sticky;top:0;z-index:2;background:var(--card);
  font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.4px;color:var(--muted);
  border-bottom:1px solid var(--line-strong);padding-top:6px;padding-bottom:6px;}
.act-head-row:hover{background:var(--card);}
/* a label must never spill into the next column — that overlap is what made the header unreadable */
.act-head-row > span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}

/* v12.91.2 — importance is a coloured dot, not punctuation: red urgent, orange medium, blue low.
   The label stays in title/aria-label, so nothing is lost to anyone who cannot see the colour. */
.ar-prio{display:inline-block;width:8px;height:8px;border-radius:50%;flex:0 0 auto;
  background:var(--pc);margin-right:6px;vertical-align:middle;cursor:pointer;}
/* the task line: smaller and quieter, so the row reads as one line rather than a headline */
/* v12.91.6 — two lines: the action's name, then its optional details underneath. Both clamp to a
   single line so the condensed row height Costas asked for in v12.91.2 survives; the full text is
   in the row's title attribute and in the Preview. */
.ar-task{display:flex;flex-direction:column;gap:1px;min-width:0;cursor:pointer;}
.ar-task-t{font-size:12.5px;line-height:1.35;color:var(--ink);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.ar-task-d{font-size:11px;line-height:1.3;color:var(--muted);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.ar-task:hover .ar-task-t{text-decoration:underline;}
/* the composer's second line: one full-width optional box under the toolbar */
.act-composer-2{margin-top:-4px;}
.act-composer-2 .ac-new-desc{flex:1;width:100%;}
/* the avatars sit hard left under their label, not centred in the track */
.ar-notify{display:flex;align-items:center;justify-content:flex-start;gap:2px;overflow:hidden;}
.ar-notify .who-av{margin:0;}
.ar-notify-more{font-size:10.5px;color:var(--muted);margin-left:2px;}
/* v12.98.0 - the Edit action modal's Notify list. One chip per recipient with its own remove
   cross, plus an Add button opening the same player picker the Actions composer uses. */
.a-notify{display:flex;flex-wrap:wrap;align-items:center;gap:6px;}
.a-notify-chips{display:flex;flex-wrap:wrap;align-items:center;gap:6px;}
.a-notify-none{color:var(--muted);font-size:13px;}
.a-notify-chip{display:inline-flex;align-items:center;gap:6px;padding:3px 6px 3px 3px;
  border:1px solid var(--line);border-radius:999px;background:var(--card);}
.a-notify-chip .who-av{margin:0;}
.a-notify-nm{font-size:12.5px;color:var(--ink);max-width:160px;overflow:hidden;
  text-overflow:ellipsis;white-space:nowrap;}
.a-notify-x{border:0;background:none;color:var(--muted);cursor:pointer;font-size:16px;
  line-height:1;padding:0 2px;min-height:0;width:auto;}
.a-notify-x:hover{color:var(--danger);}
.notify-cand-list{display:flex;flex-direction:column;gap:7px;max-height:460px;overflow-y:auto;padding-right:3px;}
.notify-cand-group{display:flex;flex-direction:column;gap:1px;}
.notify-cand-company{position:sticky;top:0;z-index:1;padding:4px 7px 3px;border-bottom:1px solid var(--accent);
  background:var(--panel);color:var(--field-ink);font-size:11px;font-weight:800;text-transform:uppercase;letter-spacing:.04em;}
.notify-cand-person{display:flex;align-items:center;gap:8px;margin:0;padding:4px 7px;border:0;border-radius:5px;background:transparent;min-height:34px;}
.notify-cand-person:hover{background:var(--accent-soft);}
.notify-cand-person input{flex:0 0 auto;margin:0;}
.notify-cand-person .who-av{width:25px;height:25px;min-width:25px;margin:0;font-size:9px;}
.notify-cand-person b{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:12.5px;font-weight:600;color:var(--ink);}

/* v12.117.0 — compact action preview: two-column facts, full-width narrative/Notify rows and
   editable recipient chips. This is the eye/notes window, not the full action form. */
.act-preview-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 14px;}
.act-preview-grid .detail-kv{margin:0;padding:0;border:0;min-width:0;}
.act-preview-grid .detail-kv.wide{grid-column:1/-1;}
.act-preview-grid .detail-kv .k{margin:0 0 2px;font-size:9.5px;font-weight:800;letter-spacing:.055em;color:#718096;}
.act-preview-grid .detail-kv .v{font-size:13.5px;line-height:1.38;color:#24364b;}
.act-preview-grid .detail-kv.wide .v{line-height:1.45;}
.act-preview-grid .detail-kv:has(.act-preview-notify-chips) .v{display:flex;align-items:center;gap:6px;flex-wrap:wrap;}
.act-preview-notify-chips{gap:4px;}
.act-preview-notify-chips .a-notify-chip{padding:2px 5px 2px 2px;background:#f5f8fc;}
.act-preview-notify-add{margin-left:2px;}
.act-preview ~ .nc-add{margin-top:7px;}
@media (max-width:560px){.act-preview-grid{grid-template-columns:1fr;}.act-preview-grid .detail-kv.wide{grid-column:auto;}}
.ar-acts{display:flex;align-items:center;justify-content:flex-start;gap:2px;}
.ar-view{background:none;border:0;cursor:pointer;font-size:13px;line-height:1;padding:2px 4px;opacity:.75;}
.ar-view:hover{opacity:1;}
/* the per-responsible tab strip */
.act-tabs{display:flex;flex-wrap:wrap;gap:2px;margin:8px 0 4px;border-bottom:1px solid var(--line-strong);}
.act-tab{background:none;border:0;border-bottom:2px solid transparent;padding:6px 10px;cursor:pointer;
  font-size:12.5px;font-weight:600;color:var(--muted);display:inline-flex;align-items:center;gap:6px;}
.act-tab.on{color:var(--ink);border-bottom-color:var(--accent);}
.act-tab-n{font-size:10.5px;font-weight:700;color:var(--muted);background:var(--bg);
  border-radius:20px;padding:1px 6px;}
.act-orphans{margin-top:10px;padding-top:6px;border-top:1px dashed var(--line);}
.ar-when{font-size:11.5px;color:var(--muted);white-space:nowrap;}
.ar-prio{
  font-weight:800;font-size:12px;color:var(--pc,var(--muted));text-align:center;
  cursor:pointer;letter-spacing:-1px;}
.ar-prio:hover{filter:brightness(.8);}
.ar-task{min-width:0;overflow-wrap:anywhere;cursor:pointer;}
.ar-task:hover{text-decoration:underline;}
.ar-due{font-size:11px;color:var(--muted);margin-left:6px;white-space:nowrap;}
.ar-due.overdue{color:var(--danger);font-weight:700;}
.ar-notes{font-size:11px;color:var(--muted);margin-left:6px;white-space:nowrap;}
.ar-acts{display:flex;gap:2px;}
.ar-edit{
  border:1px solid transparent;background:none;cursor:pointer;color:var(--muted);
  font-size:12px;padding:2px 5px;border-radius:6px;}
.ar-edit:hover{color:var(--accent);border-color:var(--accent);}
.ar-status{font-size:11.5px;}
.who-av.ini.none{background:var(--bg);color:var(--muted);border:1px dashed var(--line-strong);}
@media (max-width:640px){
  .action-row{grid-template-columns:24px 24px minmax(0,1fr) auto;
    grid-template-areas:"who by task task" "when prio acts status";}
  .ar-who{grid-area:who;} .ar-by{grid-area:by;} .ar-task{grid-area:task;}
  .ar-when{grid-area:when;} .ar-prio{grid-area:prio;} .ar-acts{grid-area:acts;} .ar-status{grid-area:status;}
}

/* v12.8.0 — Market Signals has two tabs: the shortlist (Mine & Hot) and everything else. */
.home-mkt-tabs{display:flex;gap:4px;margin:0 0 10px;border-bottom:1px solid var(--line);}
.home-mkt-tab{
  border:1px solid transparent;border-bottom:none;background:none;cursor:pointer;
  font-size:12px;font-weight:600;color:var(--muted);padding:6px 12px;border-radius:8px 8px 0 0;
  display:inline-flex;align-items:center;gap:6px;margin-bottom:-1px;}
.home-mkt-tab:hover{color:var(--ink);background:var(--accent-soft);}
.home-mkt-tab.active{background:var(--panel);border-color:var(--line);color:var(--ink);}
.home-mkt-n{
  font-size:10px;font-weight:700;background:var(--bg);border:1px solid var(--line);
  border-radius:8px;padding:0 6px;}
.home-mkt-tab.active .home-mkt-n{background:var(--accent-soft);border-color:var(--accent-soft);color:var(--accent);}
.home-mkt{cursor:pointer;display:flex;align-items:flex-start;gap:8px;border-radius:8px;}
.home-mkt-media{flex:0 0 112px;width:112px;height:104px;min-height:0;max-height:104px;align-self:flex-start;margin:-8px 0 -8px -9px;border-radius:8px 0 0 8px;overflow:hidden;background:#dfe8f2;display:flex;align-items:center;justify-content:center;}
.home-mkt-thumb{display:block;width:100%;height:104px;min-height:0;max-height:104px;object-fit:cover;object-position:center top;}
.home-mkt-media-fallback{font-size:28px;font-weight:700;color:#6f87a4;}
/* v12.76.0 — "Check links & pictures" is a .ai-pill now; see the end of this file. */
.home-mkt:hover{background:#f5f8fc;}
.home-mkt.fresh{background:#e9f7ef;}
.home-mkt.fresh:hover{background:#e1f3e8;}
.home-mkt.noteworthy{background:#f2e8f5;}
.home-mkt.noteworthy:hover{background:#ecdff0;}
.home-mkt-link{color:var(--ink);text-decoration:none;}
.home-mkt-link:hover{color:var(--accent);text-decoration:underline;}
.home-mkt-edit{flex:0 0 auto;border:1px solid var(--line-strong);border-radius:999px;background:#fff;color:var(--accent);cursor:pointer;padding:3px 9px;font:500 10.5px/1.2 inherit;}
.home-mkt-edit:hover{border-color:var(--accent);background:var(--accent-soft);}
.home-mkt-star{flex:0 0 auto;border:0;background:transparent;color:#bcc4cc;cursor:pointer;padding:3px 7px;font-size:22px;line-height:1;transition:transform .14s,color .14s;}
.home-mkt-star:hover{transform:scale(1.15);color:#d5a100;}
.home-mkt-star.on{color:#d5a100;}
.home-mkt-star:disabled{opacity:.5;cursor:wait;}
@media(max-width:640px){.home-mkt-media{flex-basis:82px;}}

/* v12.9.0 — two label-left fields per row on Overview, and full-width stacked long text on Info. */
.pj-field-pair{display:grid;grid-template-columns:1fr 1fr;gap:0 18px;}
.pj-field-pair > .pj-inline-field-sec{margin-bottom:0;}
.pj-field-pair .pj-field.pj-field-inline{grid-template-columns:106px minmax(0,1fr);gap:8px;}
@media (max-width:600px){ .pj-field-pair{grid-template-columns:1fr;} }
.pj-field-trio{display:grid;grid-template-columns:1fr 1fr 1fr;gap:0 12px;}
.pj-field-trio > .pj-inline-field-sec{margin-bottom:0;}
.pj-field-trio .pj-field.pj-field-inline,.pj-field-trio .pj-kv{grid-template-columns:minmax(58px,auto) minmax(0,1fr);gap:6px;}
/* v12.112.2 — the contact's top row is not three equal text fields: Warmth needs room for seven
   pills. Give it half the row and keep every label/value pair on one shared centreline. */
/* v12.127.0 — four cells now: Contact level, Status, Key contact, Warmth. Key contact takes the
   narrow slice a checkbox needs and Warmth keeps the room its pills need. */
.contact-profile-topline{grid-template-columns:minmax(190px,24%) minmax(120px,15%) minmax(104px,12%) minmax(340px,49%);align-items:center;}
.pj-field-quad{grid-template-columns:repeat(4,1fr);}
@media (max-width:760px){ .pj-field-quad{grid-template-columns:1fr;} }
.ckey-toggle{display:inline-flex;align-items:center;min-height:22px;cursor:pointer;}
.ckey-toggle input{width:16px;height:16px;margin:0;cursor:pointer;accent-color:var(--accent);}
.ckey-toggle input:disabled{opacity:.5;cursor:progress;}
/* A contact detail you can act on: the same blue the rest of the card uses for a value, but it
   behaves like a link, so the underline only appears when you are on it. */
.pj-field-link{color:var(--accent);text-decoration:none;overflow-wrap:anywhere;}
.pj-field-link:hover{text-decoration:underline;}
.contact-profile-topline > .pj-inline-field-sec,.contact-profile-topline > .field{align-self:stretch;display:flex;align-items:center;min-width:0;}
.contact-profile-topline .pj-field.pj-field-inline{width:100%;grid-template-columns:max-content minmax(0,1fr);align-items:center;}
.contact-profile-topline .pj-field-value{white-space:nowrap;}
.contact-profile-topline .pj-kv{display:flex;align-items:center;gap:8px;width:100%;grid-template-columns:none;}
.contact-profile-topline .pj-kv .k{flex:0 0 auto;white-space:nowrap;}
.contact-profile-topline .pj-kv .v{flex:1 1 auto;min-width:0;}
.contact-profile-topline .wslider{width:100%;}
@media (max-width:820px){
  .contact-profile-topline{grid-template-columns:1fr;}
  .contact-profile-topline > .pj-inline-field-sec,.contact-profile-topline > .field{display:block;}
}
@media (max-width:760px){ .pj-field-trio{grid-template-columns:1fr;} }
.pj-field.pj-field-stacked{display:block;}
.pj-field.pj-field-stacked label{display:block;padding:0 0 4px;}
.pj-field.pj-field-stacked .pj-field-input,
.pj-field.pj-field-stacked .pj-field-value{width:100%;min-width:0;}
/* Costas: "i want the font in the content of description to be smaller". Applies to the value in
   preview and to the box in edit, so the two modes read at the same size. */
.pj-field.pj-field-stacked .pj-field-value,
.pj-field.pj-field-stacked textarea.pj-field-input{font-size:12.5px;line-height:1.5;}

/* v12.10.0 — Costas: "clean up and condense the space that each company takes in the list
   (forget the borders)". The boxes go; separation now comes from the side headings and the
   indent under a company, which is what the eye was using anyway. */
/* v12.119.2 — THE STAKEHOLDER POPUP: LABELS LEFT, FIELDS RIGHT, CONDENSED.
   Costas: "make the popup more condensed. one more time labels left-fields right". Same 132px
   label column as every profile field since v12.89.3, so this form reads like the rest of the app
   instead of stacking a label above every control. Scoped to .stake-form so no other modal moves. */
.stake-form .field{display:grid;grid-template-columns:132px minmax(0,1fr);
  gap:2px 12px;align-items:center;margin:0 0 7px;}
.stake-form .field > label:first-child{margin:0;padding:0;font-size:11.5px;font-weight:600;
  color:var(--muted);line-height:1.25;}
.stake-form .field > :not(label:first-child){grid-column:2;min-width:0;}
.stake-form .field input,.stake-form .field select{min-height:34px;padding:5px 9px;font-size:13px;}
.stake-form .grid2{display:grid;grid-template-columns:1fr;gap:0;}
.stake-form .sc-field{align-items:start;}
.stake-form .sc-field > label:first-child{padding-top:6px;}
/* The per-contact Active/Key editor. One line per person; the list scrolls rather than growing the
   modal, which is what "more condensed" is asking for on a company with twenty staff. */
/* v12.131.0 — with the wider card there is room to show ~8 people before scrolling instead of
   ~6, which is the difference between reading a company's list and hunting through it. */
.sc-edit{border:1px solid var(--line);border-radius:8px;background:#fff;max-height:300px;overflow:auto;padding:0 6px 6px;}
/* v12.133.0 — this box now holds the SAME grouped list as the company's Contacts tab. Two things
   have to be said here and only here: the rows do not navigate inside a modal, and the
   .stake-form's own "every input is 34px tall" rule must not inflate the Active/Key boxes.
   That second one is the v12.15.1/v12.119.3 trap for the third time — a later, more specific
   rule wins over the list's own, so the override has to carry .stake-form's weight. */
.sc-edit .of-contact-row{cursor:default;}
.sc-edit .of-contact-row:hover{background:#e9eff8;}
.sc-edit .of-contact-level-head{padding-top:8px;}
.stake-form .field .of-contact-projop-controls input[type=checkbox]{
  width:14px;height:14px;min-height:0;margin:0;padding:0;}
.stake-form .field .of-contact-projop-controls label{font-size:11px;font-weight:600;}
.stake-form .field .of-contact-row .nm{font-size:12px;}
.sc-row{display:grid;grid-template-columns:22px minmax(0,1fr) auto auto;gap:8px;align-items:center;
  padding:3px 8px;border-bottom:1px solid var(--line);}
.sc-row:last-child{border-bottom:0;}
.sc-row .who-av{width:20px;height:20px;margin:0;}
.sc-who{min-width:0;display:flex;flex-direction:column;line-height:1.2;}
.sc-who b{font-size:12.5px;font-weight:600;color:var(--ink);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.sc-who small{font-size:10.5px;color:var(--muted);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
/* v12.119.3 — THE TICK LABELS MUST CARRY .field IN THEIR SELECTOR, OR LINE 291 WINS.
   `.field label{font-weight:600;font-size:14px;margin-bottom:5px}` is (0,1,1); a bare `.sc-tick`
   is (0,1,0) and loses however far below it is written, so "Active" and "Key" rendered at 14px
   bold — the third time this exact rule has enlarged a label nested inside a .field (v12.82.0's
   Archived label, v12.100.1's checkbox, now this). Name display, font-size, font-weight, colour
   AND margin-bottom explicitly: line 291 sets all of them. */
.field label.sc-tick,.sc-tick{display:flex;align-items:center;gap:4px;margin:0 0 0 0;
  white-space:nowrap;font-size:11px;font-weight:500;color:var(--muted);cursor:pointer;}
/* v12.100.1 — a checkbox inside a .field inherits the 44px full-width input rule and becomes a
   giant empty square. Width, height, min-height AND padding all have to be named — and the
   selector needs .stake-form .field weight, since `.stake-form .field input` (0,2,1) beats a
   plain `.sc-tick input[type=checkbox]` (0,1,2) and would put 34px back under every row. */
.stake-form .field .sc-tick input[type="checkbox"],
.sc-tick input[type="checkbox"]{width:13px;height:13px;min-height:0;margin:0;padding:0;flex:0 0 auto;}
.sc-tick input[type="checkbox"]:disabled{opacity:.4;cursor:not-allowed;}

/* v12.119.0 — EVERY RULE BELOW CARRIES THE #side-body PREFIX, AND THAT IS THE WHOLE FIX.
   Costas: "i had the contacts aligned with nice small fonts". They were written in v12.10.0 as
   class-only selectors and therefore LOST to two v8-era ID rules ~950 lines above:
     #side-body .stake-row.stake-pn{padding:6px 9px 6px 22px}
     #side-body .stake-av{width:24px;height:24px}
   An #id selector outranks a class-only one however far below it is written, so the condensed
   layout never applied inside the popup, which is where the Players tab actually lives. This is
   precisely the trap v12.15.1 recorded — "Any override of the Players list must carry the
   #side-body prefix" — and these rules were written in breach of it. */
#side-body .stake-side{margin-bottom:10px;}
#side-body .stake-side .stake-grp{margin-bottom:2px;}
#side-body .stake-side .stake-row,
#side-body .stake-side .stake-row.stake-co,
#side-body .stake-side .stake-row.stake-pn{
  border:0;border-radius:6px;margin-bottom:0;}
#side-body .stake-side .stake-row.stake-co{padding:3px 6px;font-size:13px;}
#side-body .stake-side .stake-row.stake-pn{padding:2px 6px 2px 8px;font-size:12.5px;}
#side-body .stake-side .stake-grp-body{margin:0 0 0 12px;padding-left:10px;border-left:1px solid var(--line);}
#side-body .stake-side .stake-grp-empty{margin:1px 0 3px 6px;font-size:11.5px;}
#side-body .stake-side-empty{margin:1px 0 4px;font-size:11.5px;}
#side-body .stake-side .stake-av{width:20px;height:20px;}
#side-body .stake-side .stake-av.sq{width:22px;height:22px;}
.stake-more{
  border:0;background:none;cursor:pointer;color:var(--muted);font-size:11px;
  padding:2px 6px;margin:1px 0 2px;border-radius:6px;}
.stake-more:hover{color:var(--accent);background:var(--accent-soft);}

/* ===== v12.135.0 — TICKS YOU CAN SEE, AND ROWS THAT LINE UP =====
   (a) "i want the checked boxes to be blue instead of grey do that they can be more easily
   visible." accent-color does NOT survive `disabled` — every browser greys a disabled box out,
   and half the ticks in these lists are disabled on purpose (a Key tick before Active, an
   archived person). So the box is drawn here instead of by the browser: same size, blue when
   ticked, a paler blue when ticked-and-disabled, and the tick mark stays white in both.
   (b) "i told you 100 times to make all the fonts and rows nice small and horizontally
   aligned." The labels were inline-wrapping under their boxes on a narrow row. Each is now a
   no-wrap flex pair with a fixed column width, so Active and Key line up down the whole list. */
.stake-active,.stake-key,.of-contact-projop-controls label{
  display:inline-flex;align-items:center;gap:5px;white-space:nowrap;flex:0 0 auto;
  font-size:11px;font-weight:600;line-height:1.1;}
.stake-active,.stake-key{min-width:62px;}
.stake-active>span,.stake-key>span{display:inline-block;}
.stake-chk,.stake-key-chk,
.of-contact-projop-controls input[type=checkbox],
.sc-tick input[type="checkbox"],.adm-key-chk,.ckey-toggle input{
  appearance:none;-webkit-appearance:none;
  width:14px;height:14px;min-height:0;margin:0;padding:0;flex:0 0 auto;
  border:1.5px solid #9fb0c4;border-radius:3.5px;background:#fff;cursor:pointer;
  position:relative;transition:background .1s,border-color .1s;}
.stake-chk:checked,.stake-key-chk:checked,
.of-contact-projop-controls input[type=checkbox]:checked,
.sc-tick input[type="checkbox"]:checked,.adm-key-chk:checked,.ckey-toggle input:checked{
  background:var(--accent);border-color:var(--accent);}
/* the tick itself, drawn so it is white on blue in every state including disabled */
.stake-chk:checked::after,.stake-key-chk:checked::after,
.of-contact-projop-controls input[type=checkbox]:checked::after,
.sc-tick input[type="checkbox"]:checked::after,.adm-key-chk:checked::after,.ckey-toggle input:checked::after{
  content:"";position:absolute;left:4px;top:1px;width:4px;height:8px;
  border:solid #fff;border-width:0 2px 2px 0;transform:rotate(42deg);}
/* Disabled is COMMUNICATED, not hidden: a ticked-but-locked box stays blue, just softer, which
   is the whole of Costas' complaint — the grey ones read as unticked at a glance. */
.stake-chk:disabled,.stake-key-chk:disabled,
.of-contact-projop-controls input[type=checkbox]:disabled,
.sc-tick input[type="checkbox"]:disabled,.adm-key-chk:disabled{
  cursor:default;border-color:#c6d2e0;background:#fff;opacity:1;filter:none;}
.stake-chk:disabled:checked,.stake-key-chk:disabled:checked,
.of-contact-projop-controls input[type=checkbox]:disabled:checked,
.sc-tick input[type="checkbox"]:disabled:checked,.adm-key-chk:disabled:checked{
  background:#8fb4ef;border-color:#8fb4ef;opacity:1;}

/* v12.11.0 — a finding row: publisher mark on the left, and a pale green ground while it is
   fresh (filed in the last month), so the last Research run stands out from the back catalogue. */
.doc-row{display:flex;align-items:flex-start;gap:9px;}
.doc-fav{width:20px;height:20px;border-radius:5px;flex:none;margin-top:2px;object-fit:contain;background:var(--bg);}
.doc-fav.ini{
  display:inline-flex;align-items:center;justify-content:center;
  background:var(--line-strong);color:var(--ink);font-size:10px;font-weight:700;}
.doc-row.fresh{background:#e9f7ef;border-color:#bfe5cd;}
.doc-row.noteworthy{background:#f3eafb;border-color:#c6a5df;box-shadow:inset 4px 0 0 #a875c7;}
.doc-noteworthy{display:flex;align-items:center;justify-content:center;width:34px;height:30px;cursor:pointer;color:#9aa5b1;}
.doc-noteworthy input{position:absolute;opacity:0;pointer-events:none;}
.doc-noteworthy span{font-size:0;line-height:1;}
.doc-noteworthy span::before{content:"☆";font-size:24px;line-height:1;}
.doc-noteworthy input:checked + span{color:#d4a800;filter:drop-shadow(0 1px 1px rgba(104,75,0,.2));}
.doc-noteworthy input:checked + span::before{content:"★";}
#pj-research-docs{margin-top:8px;}

/* v12.12.0 — "Added by" on the composer and on the inline editor, so every column a log entry
   SHOWS can also be set when adding and when editing. */
.nc-add-author,.nc-e-author-l{
  display:flex;align-items:center;gap:6px;font-size:11px;color:var(--muted);margin:0 0 6px;}
.nc-add-author select,.nc-e-author select{font-size:12px;min-height:28px;flex:0 1 200px;}

/* v12.12.1 — Costas: "in the preview i want the info to be in dark blue fonts to be distinct
   from the dark grey of the labels." Preview only: in Edit the values sit in real input boxes,
   which already separates them from their labels. The label colour is untouched. */
.pj-preview-mode .pj-field-value{color:var(--field-ink);font-weight:600;}
.pj-preview-mode .pj-field-value .pj-field-empty,
.pj-preview-mode .pj-field-empty{color:var(--muted);font-weight:400;}

/* v12.121.0 — the bright blue above is right for a value you read at a glance (a date, a
   budget, a stage) and punishing for forty lines of researched prose, which is what Executive
   summary / Description / Competition / Risks hold once something is pasted into them. Those
   four carry .pj-field-prose and read as body text: normal ink, normal weight, room between
   paragraphs, and links that look like links. Every other field keeps the blue. */
.pj-preview-mode .pj-field-value.pj-field-prose{color:var(--ink);font-weight:400;}
/* v12.124.0 — "MAke it more report like and more condensed." Was 13px/1.6 with a <br> between
   every line, which is how a pasted answer became a wall of evenly-spaced text with no shape.
   mdLiteProse() now emits real blocks and this is their spacing: a tight measure, small gaps
   INSIDE a block and larger ones between blocks, so the eye can find the headings. */
.pj-field-prose{max-width:78ch;font-size:12.5px;line-height:1.45;}
.pj-field-prose p{margin:0 0 7px;}
.pj-field-prose p:last-child{margin-bottom:0;}
.pj-field-prose .prose-h{margin:11px 0 5px;font-size:12.5px;font-weight:800;color:var(--ink);
  letter-spacing:0;text-transform:none;}
.pj-field-prose .prose-h:first-child{margin-top:0;}
.pj-field-prose .prose-list{margin:0 0 7px;padding-left:15px;}
.pj-field-prose .prose-list li{margin:0 0 3px;padding-left:1px;}
.pj-field-prose b{color:var(--field-ink);}
.pj-field-prose a{color:var(--accent);text-decoration:underline;overflow-wrap:anywhere;}
/* A citation marker is a footnote, so it reads like one: small, grey, raised, out of the way of
   the sentence it is attached to. */
.pj-field-prose .md-cite{font-size:9px;font-weight:700;color:var(--muted);vertical-align:super;
  line-height:0;margin-left:2px;letter-spacing:.02em;}
/* The Sources block: the site's NAME, one compact line each, the address behind the link. */
.pj-field-prose .prose-src-h{margin:10px 0 4px;font-size:9.5px;font-weight:800;letter-spacing:.07em;
  text-transform:uppercase;color:var(--muted);}
.pj-field-prose .prose-src{margin:0;padding:0 0 0 22px;font-size:11.5px;color:var(--muted);}
.pj-field-prose .prose-src li{margin:0 0 2px;}
.pj-field-prose .prose-src li::marker{color:var(--muted);font-weight:700;}
.pj-field-prose .prose-src a{text-decoration:none;font-weight:600;}
.pj-field-prose .prose-src a:hover{text-decoration:underline;}

/* v12.124.0 — THE APP'S OWN SECTION LABELS, told apart from what you pasted under them. Costas:
   "find a way to make the default section in the info tab to be more easily visible that the
   rest of the copy pasted text. maybe put them in a dark blue pill like ui." Pasted text now
   carries its own bold headings, so a small grey uppercase label no longer outranks anything on
   that screen — EXECUTIVE SUMMARY and DESCRIPTION were reading as the quietest things on a page
   of research. The pill is on the STACKED fields only (the long-text sections); the label-left
   rows keep the quiet grey, where nothing competes with them. */
.pj-field.pj-field-stacked>label,.pj-sec-pill{display:inline-block;margin:0 0 6px;padding:3px 11px;
  border-radius:999px;background:#14335c;color:#fff;
  font-size:9.5px;font-weight:800;letter-spacing:.09em;text-transform:uppercase;}
/* v12.130.0 — .pj-sec-pill is the same pill for a section whose body is a LIST rather than a
   field (Market Info). One rule, so the two can never drift into two shades of navy. */
.pj-sec-pill{margin-bottom:8px;}

/* v12.12.2 — Costas: "keep one line for each company, reduce the padding. just leave a row no
   extra bordered box." A company head is now a single line — logo, caret, name, influence stars,
   count, pencil, × — with no frame of its own. The box came from the base .stake-row rule
   (border + radius + margin), which every earlier Players layout inherited; these overrides are
   deliberately explicit about border, background AND radius so a future base-rule change cannot
   quietly bring the box back. */
.stake-side .stake-row,
.stake-side .stake-row.stake-co,
.stake-side .stake-row.stake-pn{
  border:0;border-radius:0;box-shadow:none;background:none;margin:0;}
.stake-side .stake-row.stake-co{padding:2px 4px;font-size:13px;}
.stake-side .stake-row.stake-pn{padding:1px 4px;}
.stake-side .stake-row.stake-co:hover,
.stake-side .stake-row.stake-pn:hover{background:var(--accent-soft);border-radius:6px;}
/* One line: the name and the stars sit side by side instead of stacking. */
.stake-side .stake-co .stake-co-content{
  flex-direction:row;align-items:center;gap:8px;min-width:0;}
.stake-side .stake-co .stake-name{
  display:inline;width:auto;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
  flex:0 1 auto;font-size:13.5px;}
.stake-side .stake-co .stake-co-meta{flex:none;}
.stake-side .stake-grp{margin-bottom:0;}
.stake-side .stake-grp-body{margin:0 0 2px 10px;padding-left:9px;}

/* v12.13.0 — the stakeholder role note, surfaced. Amber ground so it reads as a standing note
   about the person rather than another timeline entry. */
.role-note{
  border:1px solid #e6d9a2;background:#fdf7dd;border-radius:9px;
  padding:8px 10px;margin:0 0 12px;}
.role-note-h{
  display:flex;align-items:center;gap:7px;
  font-size:10.5px;font-weight:800;letter-spacing:.06em;text-transform:uppercase;
  color:var(--muted);margin:0 0 5px;}
.role-note-h .role-note-edit{margin-left:auto;}
.role-note-body{font-size:13px;line-height:1.5;color:var(--ink);overflow-wrap:anywhere;}
.role-note-empty{color:var(--muted);font-style:italic;}
.role-note .nc-edit-form{margin:0;}
.role-note textarea{width:100%;}

/* v12.14.0 — who wrote a note, beside when. Same treatment everywhere a note is listed. */
.nc-who{font-weight:600;color:var(--muted);}
.role-note-by{
  font-size:10.5px;font-weight:600;letter-spacing:0;text-transform:none;color:var(--muted);
  margin-left:2px;}
.role-note .nc-add-author{margin:6px 0 0;}

/* ==========================================================================
   v12.15.1 — Costas: "too many horizontal lines, remove the rounded corner box."
   The box was NOT the .stake-row rules this file already overrode — it came from the v8-era
   `#side-body .stake-grp` / `.stake-grp-h` / `.stake-row.stake-pn` block (~line 1425), whose id
   selector outranks every `.stake-side …` rule appended since. These overrides carry the same
   #side-body prefix so they actually win. Only the vertical guide under a company survives:
   it is what shows the nesting, and it is not one of the lines being complained about.
   ========================================================================== */
#side-body .stake-side .stake-grp{
  border:0;border-radius:0;background:none;margin-bottom:0;overflow:visible;}
#side-body .stake-side .stake-grp-h{
  background:none;border-bottom:0;padding:0;}
#side-body .stake-side .stake-row.stake-co{
  border:0;border-radius:6px;background:none;padding:3px 6px;}
#side-body .stake-side .stake-row.stake-pn{
  border:0;border-bottom:0;border-radius:6px;background:none;padding:2px 6px 2px 8px;}
#side-body .stake-side .stake-independent{background:none;margin-top:0;}
#side-body .stake-side .stake-row.stake-co:hover,
#side-body .stake-side .stake-row.stake-pn:hover{background:var(--accent-soft);}
#side-body .stake-side .stake-grp-body{
  margin:0 0 2px 12px;padding-left:10px;border-left:1px solid var(--line);}

/* The logo tile: bigger, and the whole mark inside it rather than cropped by object-fit:cover. */
#side-body .stake-side .stake-av.sq{
  width:32px;height:32px;border-radius:7px;object-fit:contain;background:#fff;padding:2px;}
#side-body .stake-side .stake-av.sq.stake-logo-none{
  padding:0;color:var(--muted);background:var(--bg);}
.stake-logo-none svg{display:block;}

/* v12.16.0 — a finding row: thumbnail left, headline with its date right after it, and the
   publisher underneath only when there is a real one to name. */
.doc-head{display:flex;align-items:baseline;gap:8px;flex-wrap:wrap;}
.doc-head .doc-open{flex:0 1 auto;min-width:0;}
.doc-when{
  flex:none;font-size:11.5px;font-weight:600;color:var(--muted);white-space:nowrap;}
.doc-row .doc-fav{width:34px;height:34px;border-radius:7px;margin-top:1px;}
.doc-row .doc-fav.ini{font-size:14px;color:#fff;letter-spacing:0;border:0;}

/* v12.17.0 — the real thumbnail. Wider than the icon tile it replaces, cropped to a consistent
   shape so a column of findings lines up regardless of what each publisher's image is. */
.doc-thumb{
  width:64px;height:48px;flex:none;border-radius:7px;object-fit:cover;margin-top:1px;
  background:var(--bg);border:1px solid var(--line);}
.doc-row{align-items:flex-start;}
.doc-head{min-width:0;}
.doc-head .doc-open,.doc-head .doc-title{display:block;max-width:100%;white-space:nowrap;
  overflow:hidden;text-overflow:ellipsis;font-size:13.5px;font-weight:600;}
.doc-meta{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.doc-note{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;}
.doc-thumbs-btn{margin-top:8px;}
.doc-tools{display:flex;gap:6px;align-items:center;margin-top:8px;}
.doc-tools .doc-thumbs-btn{margin-top:0;}
@media (max-width:520px){ .doc-thumb{width:52px;height:40px;} }

/* ==========================================================================
   v12.19.0 — the Projop card used on Home's Priority strip and on Today.
   Picture on top (sector top-left, stage top-right), then ref + title, the
   ELECNET budget, the brief, and the key players. Costas' own order.
   ========================================================================== */
.projop-card{padding:0;overflow:hidden;display:flex;flex-direction:column;}
.pjc-media{position:relative;width:100%;aspect-ratio:16/9;background:var(--bg);flex:none;}
.pjc-img{width:100%;height:100%;object-fit:cover;display:block;}
.pjc-img-none{
  display:flex;align-items:center;justify-content:center;
  background:var(--pc,#2f6df6);color:#fff;font-size:34px;font-weight:800;letter-spacing:1px;}
.pjc-tl,.pjc-tr{position:absolute;top:7px;max-width:60%;}
.pjc-tl{left:7px;} .pjc-tr{right:7px;}
.pjc-sector{
  display:inline-block;font-size:10px;font-weight:800;letter-spacing:.05em;text-transform:uppercase;
  background:rgba(255,255,255,.92);color:#1b2530;border-radius:8px;padding:2px 8px;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:100%;}
.pjc-stage{background:rgba(255,255,255,.92);}
.pjc-camera{
  position:absolute;right:7px;bottom:7px;border:0;cursor:pointer;font-size:12px;line-height:1;
  background:rgba(255,255,255,.9);border-radius:8px;padding:4px 6px;opacity:0;transition:opacity .12s;}
.projop-card:hover .pjc-camera,.pjc-camera:focus{opacity:1;}
.pjc-body{padding:9px 11px 11px;display:flex;flex-direction:column;gap:5px;min-width:0;}
.pjc-head{display:flex;align-items:baseline;gap:7px;min-width:0;}
.pjc-ref{
  flex:none;font-size:10.5px;font-weight:800;color:var(--accent);
  background:var(--accent-soft);border-radius:8px;padding:1px 7px;}
.pjc-name{
  font-size:13.5px;font-weight:800;letter-spacing:-.1px;text-transform:uppercase;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0;}
.pjc-budget{font-size:14px;font-weight:800;color:var(--field-ink);}
.pjc-brief{
  font-size:12px;color:var(--muted);line-height:1.4;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;}
.pjc-players{display:flex;flex-wrap:wrap;gap:4px;margin-top:1px;}
.pjc-player{
  font-size:10.5px;font-weight:600;background:var(--bg);border:1px solid var(--line);
  border-radius:8px;padding:1px 7px;color:var(--ink);max-width:100%;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.pjc-more{color:var(--muted);}

/* ==========================================================================
   v12.19.2 — Costas: "all the pics same height, all the cards same width, the
   private and lead pills same size and aligned."
   The strip already sets a fixed 252px track item; what broke the look was
   `.home-hot .board-card{padding:11px 12px}` (0,2,0) outranking `.projop-card`
   (0,1,0), so the picture sat inside padding and the body was padded twice.
   These overrides carry the same two-class weight and come later.
   ========================================================================== */
.home-hot .projop-card,
.today-opp .projop-card{padding:0;width:100%;}
/* One fixed picture height for every card — an aspect-ratio box varies with width,
   which is exactly what made the pictures different heights. */
.projop-card .pjc-media{aspect-ratio:auto;height:132px;}
/* Both pills, one row, identical box. */
.pjc-pills{
  position:absolute;top:8px;left:8px;right:8px;
  display:flex;align-items:center;justify-content:space-between;gap:8px;pointer-events:none;}
.pjc-pill{
  flex:0 1 auto;min-width:0;max-width:48%;
  height:19px;line-height:19px;padding:0 9px;border-radius:10px;
  font-size:10px;font-weight:800;letter-spacing:.05em;text-transform:uppercase;
  background:rgba(255,255,255,.94);color:#1b2530;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
  box-shadow:0 1px 2px rgba(16,24,40,.18);}
.pjc-pill:empty{display:none;}
.pjc-pill-stage{color:var(--pc,#1b2530);}
.pjc-stage-cluster{display:flex;align-items:center;justify-content:flex-end;gap:3px;min-width:0;}

/* v12.123.0 — the star moved to the LEFT of this row, into the slot the sector pill used to
   hold, and the stage pill stays on the right on its own. The slot is always present even when
   the card is drawn without a star (the Funnel board), because justify-content:space-between
   needs two children to keep the stage pinned right; empty, it takes no width. */
.pjc-hot-slot{display:flex;align-items:center;gap:3px;flex:0 0 auto;}
.pjc-hot-slot .home-unpin{position:static;flex:0 0 auto;width:19px;height:19px;padding:0;border:0;
  border-radius:50%;background:rgba(255,255,255,.94);font-size:12px;line-height:19px;text-align:center;
  box-shadow:0 1px 2px rgba(16,24,40,.18);color:#b9c3cf;
  /* .pjc-pills is pointer-events:none so the pills never swallow a click meant for the card.
     The star is the one thing in that row you can actually press, and it had inherited the
     none — every click on it fell through and opened the Projop instead of toggling Hot. */
  pointer-events:auto;}
.pjc-hot-slot .home-unpin.on{color:#e0a800;}
.pjc-hot-slot .home-unpin:hover{transform:scale(1.18);}

/* Hot, made visible: the pale purple that says why these cards sort to the front of the strip.
   Set on the CARD, so it tints the body under the picture and the border agrees with it. */
.projop-card.is-hot{background:#f3effd;border-color:#c4b2ea;}
.projop-card.is-hot .pjc-body{background:transparent;}
.home-hot .board-card.is-hot,.today-opp .board-card.is-hot{border-color:#c4b2ea;}

/* The Projop's picture, on the workspace Overview. */
.pj-overview-hero-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:18px;
  align-items:stretch;margin:0 0 12px;min-height:210px;}
.pj-overview-visual{min-width:0;}
.pj-overview-side{display:flex;flex-direction:column;min-width:0;}
.pj-img-row{display:flex;flex-direction:column;align-items:stretch;gap:7px;min-width:0;height:100%;}
.pj-img-thumb{width:100%;height:210px;border-radius:10px;object-fit:cover;flex:none;
  background:var(--bg);border:1px solid var(--line);}
.pj-img-thumb.pj-img-none{
  display:flex;align-items:center;justify-content:center;
  font-size:10.5px;color:var(--muted);font-style:italic;}
.pj-overview-attention{display:flex;flex-direction:column;align-items:flex-end;justify-content:flex-start;
  gap:8px;padding:6px 4px;}
.pj-overview-attention .pj-gaps{justify-content:flex-end;margin:0;}
.pj-overview-attention .pj-next{align-self:stretch;margin:0;}
.pj-overview-brief{width:100%;margin:0 0 12px;}
.pj-overview-brief .pjb-sec{margin:0;}
.pj-overview-brief .pj-field-value{min-height:82px;font-weight:500;}
.pj-overview-brief textarea{min-height:82px;resize:vertical;}
@media (max-width:620px){
  .pj-overview-hero-row{grid-template-columns:1fr;min-height:0;}
  .pj-img-thumb{height:180px;}
  .pj-overview-attention{align-items:flex-start;}
  .pj-overview-attention .pj-gaps{justify-content:flex-start;}
}

/* v12.66.0 — Players tab: a company with no role of its own, and a person showing their
   company's role as a hint.
   NOTE THE #side-body PREFIX ON BOTH. The Players list is styled by an ID-prefixed block
   (`#side-body .stake-grp`, ~line 1425), and an ID selector outranks a class-only one however
   late it is appended — two earlier releases wrote class-only overrides here and changed
   nothing on screen. See CLAUDE.md's v12.15.1 note. */
/* A DERIVED chip must never look like a stored one. Dashed, grey, italic — the visual
   vocabulary of "inferred", so nobody reads it as a role somebody actually set. */
#side-body .stake-chip-derived{
  background:transparent; color:var(--muted); border:1px dashed var(--line);
  font-style:italic; font-weight:400;
}

/* v12.68.0 — "I have read this news note" (per person, doc_reads).
   A read note is DIMMED, never hidden: Costas' rule is that it leaves Today and stays on its
   Projop. Hiding it here would be the opposite of "keep it archived in the relevant projop". */
#side-body .doc-row.is-read{ opacity:.62; }
#side-body .doc-row.is-read:hover{ opacity:1; }
#side-body .doc-pill.doc-read.on{
  background:color-mix(in srgb,var(--accent) 12%,transparent);
  border-color:color-mix(in srgb,var(--accent) 40%,var(--line));
  color:var(--accent);
}
/* Today's quiet reassurance line under My Signals: the list emptying is a filter, not a delete. */
.today-readnote{
  padding:6px 8px 2px;font-size:11.5px;color:var(--muted);font-style:italic;
}

/* v12.69.0 — the merged landing page. Today's tab strip now also carries the two Market Signals
   controls that used to sit in that card's header, pushed to the right of the tabs. */
.today-tab-ctl{ margin-left:auto; display:inline-flex; align-items:center; gap:6px; padding:0 4px 6px; }

/* v12.70.0 — Mark read as a checkbox pill: a small box with a much smaller label beside it,
   per Costas. It is an ACTION, not a state — the row disappears once ticked — so the box is
   always empty when you see it. */
.home-mkt-read{
  flex:none; display:inline-flex; align-items:center; gap:5px;
  border:1px solid var(--line); border-radius:999px; padding:3px 8px 3px 6px;
  cursor:pointer; background:transparent; user-select:none;
}
.home-mkt-read:hover{ border-color:var(--accent); }
.home-mkt-read input{ margin:0; width:13px; height:13px; cursor:pointer; }
.home-mkt-read span{ font-size:9.5px; letter-spacing:.02em; color:var(--muted); white-space:nowrap; }
.home-mkt-read:hover span{ color:var(--accent); }

/* Drag the Projop strip left/right by grabbing a card. grab/grabbing is the whole affordance —
   without it nobody discovers the gesture. `is-dragging` also suppresses text selection and
   pointer events inside the cards for the duration, so a pan never highlights a headline. */
[data-projop-scroller] .home-strip-track{ cursor:grab; touch-action:pan-y; }
[data-projop-scroller] .home-strip-track.is-dragging{ cursor:grabbing; user-select:none; scroll-behavior:auto; }
[data-projop-scroller] .home-strip-track.is-dragging *{ pointer-events:none; }

/* v12.71.0 — the Projop's warning pills, moved from Overview to the top right of the tab strip.
   `margin-left:auto` is what pins them right; the strip is already a flex row.
   ORANGE, NOT RED. Costas: "recolor them to an orange color and leave the red for more extreme
   alert." So --danger red is now RESERVED for a tier he has not defined yet — a new pill should
   default to .pj-pill-warn and only go red once he says which alerts are extreme. */
.pj-tabs{align-items:center;}
.pj-tab-alerts{
  margin-left:auto; display:inline-flex; align-items:center; gap:5px;
  flex-wrap:wrap; justify-content:flex-end; padding-bottom:4px;
}
.pj-pill-warn{
  --pc:#e67e22;
  font-size:10px; padding:2px 8px; white-space:nowrap;
  /* v12.71.1 — BLACK TEXT, overriding .badge.soft's `color:var(--pc)`. Costas asked for it to
     improve legibility, and he is right: orange type on a 14%-orange ground is the lowest
     contrast combination in the app. The pill still reads as orange — the fill and the border
     carry the colour, the text only has to be readable. */
  color:var(--ink);
}
/* The strip must never be pushed out of shape by a Projop with every gap at once. */
@media (max-width:820px){
  .pj-tabs{flex-wrap:wrap;}
  .pj-tab-alerts{margin-left:0; width:100%; justify-content:flex-start; padding:4px 0 0;}
}

/* v12.73.2 — KEY PLAYER CARDS. THE PHOTO BLEEDS TO THE CARD EDGES, exactly like a Projop card.

   EVERY SELECTOR HERE IS `#side-body .stake-key-grid .stake-row.stake-card…` — one id plus
   three classes — and that is deliberate, not verbosity. The Players tab already carries
   ID-prefixed rules with the SAME weight as a plain `#side-body .stake-row.stake-card`, so an
   equal-specificity override only wins by being later in the file, which is fragile and is
   exactly how the last two attempts lost. The one that mattered:
     `#side-body .stake-row.stake-pn{padding:6px 9px 6px 22px}`
   — a 22px LEFT indent, which is what pushed the picture off the card's edge. Outranking it
   outright is the fix; matching it and hoping to be last is not.

   For the bleed itself the recipe is the Projop card's: the CARD owns padding:0 and
   overflow:hidden with the radius, and the picture is a plain 100%-wide block. Nothing between
   the card edge and the image may carry padding, margin or a border. */
#side-body .stake-key-grid{
  display:grid; grid-template-columns:repeat(auto-fill,minmax(150px,1fr));
  gap:10px; padding:8px 2px 4px; align-items:start;
}
#side-body .stake-key-grid .stake-row.stake-card{
  display:flex; flex-direction:column; align-items:stretch; gap:0;
  padding:0; margin:0; overflow:hidden; cursor:pointer;
  border:1px solid var(--line); border-bottom:1px solid var(--line); border-radius:12px;
  background:var(--card); box-shadow:var(--shadow); opacity:1;
  transition:transform .16s cubic-bezier(.2,.7,.3,1), box-shadow .16s, border-color .13s;
}
#side-body .stake-key-grid .stake-row.stake-card:hover{
  opacity:1; background:var(--card); border-color:var(--accent);
  transform:translateY(-3px); box-shadow:var(--shadow-lg);
}
/* The picture: full width, flush to all three edges, clipped by the card's own radius. */
#side-body .stake-key-grid .stake-card .plc-media{
  display:block; width:100%; height:86px; margin:0; padding:0; border:0;
  background:var(--panel); overflow:hidden; flex:none;
}
#side-body .stake-key-grid .stake-card .plc-img{
  display:block; width:100%; height:86px; margin:0; padding:0; border:0;
  object-fit:cover; object-position:center 20%;
}
#side-body .stake-key-grid .stake-card .plc-img-none{
  display:flex; align-items:center; justify-content:center;
  background:var(--pc,#2f6df6); color:#fff; font-size:24px; font-weight:800; letter-spacing:.5px;
}
/* Three lines, one left edge, one scale — name 12, title 11, company 11. */
#side-body .stake-key-grid .stake-card .plc-body{
  padding:8px 10px 7px; display:flex; flex-direction:column; gap:1px; min-width:0;
}
#side-body .stake-key-grid .stake-card .plc-name{
  font-size:12px; line-height:1.3; color:var(--ink); font-weight:400;
  overflow:hidden; text-overflow:ellipsis; white-space:nowrap;
}
#side-body .stake-key-grid .stake-card .plc-name b{ font-weight:700; }
#side-body .stake-key-grid .stake-card .plc-title,
#side-body .stake-key-grid .stake-card .plc-org{
  font-size:11px; line-height:1.35; color:var(--muted);
  overflow:hidden; text-overflow:ellipsis; white-space:nowrap;
}
#side-body .stake-key-grid .stake-card .plc-org{ opacity:.8; }
#side-body .stake-key-grid .stake-card .plc-org:empty{ display:none; }
/* The company name on an ordinary (non-key) person row, where the role chip used to be. */
#side-body .stake-orgname{ flex:none; font-size:10.5px; color:var(--muted);
  max-width:38%; padding:0; border:0; background:transparent; font-family:inherit;
  text-align:left; cursor:pointer; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
#side-body .stake-orgname:hover{ color:var(--accent); text-decoration:underline; }

/* v12.111.0 — ordinary company-contact rows use fixed columns so photos, names, status controls
   and action icons share the same vertical lines from one row to the next. */
#side-body .stake-side .stake-grp-body .stake-row.stake-pn:not(.stake-card){
  display:grid;grid-template-columns:20px minmax(0,1fr) 62px 48px 26px 26px;
  align-items:center;column-gap:7px;min-height:32px;
}
#side-body .stake-side .stake-grp-body .stake-active,
#side-body .stake-side .stake-grp-body .stake-key{
  display:inline-flex;align-items:center;gap:4px;margin:0;color:var(--muted);
  font-size:10.5px;font-weight:400;line-height:1;white-space:nowrap;cursor:pointer;
}
#side-body .stake-side .stake-grp-body .stake-active input,
#side-body .stake-side .stake-grp-body .stake-key input{margin:0;width:14px;height:14px;}
#side-body .stake-side .stake-grp-body .stake-info,
#side-body .stake-side .stake-grp-body .stake-pen{justify-self:center;margin:0;}

/* Relationship company names throughout Preview are links to the same organization surface. */
.org-preview-link{ padding:0; border:0; background:transparent; color:var(--accent);
  font:inherit; text-align:left; cursor:pointer; }
.org-preview-link:hover{ text-decoration:underline; }

/* v12.75.0 — the news / information note's controls, as four icons in a 2x2 block with the
   contributor's photo underneath. Costas: "the star, mark read, edit and delete will all be
   icons ... and under the pic of the person that contributed the note."
   The same block on Home and on the Projop Info tab, because both draw projopDocRowHtml().
   Note these rules carry NO #side-body prefix on purpose — the row now lives in two places and
   a prefixed rule would style only one of them (the v12.15.1 finding, in reverse). */
.doc-actions{gap:6px;}
.doc-ico-grid{display:grid;grid-template-columns:repeat(2,25px);gap:4px;}
.doc-ico{
  display:flex;align-items:center;justify-content:center;width:25px;height:25px;padding:0;
  border:1px solid var(--line-strong);border-radius:7px;background:#fff;color:#8d97a3;
  font:400 14px/1 inherit;cursor:pointer;
  transition:color .13s,border-color .13s,background .13s;
}
.doc-ico:hover{border-color:var(--accent);color:var(--accent);background:var(--accent-soft);}
.doc-ico:disabled{opacity:.5;cursor:wait;}
.doc-ico.doc-star{font-size:16px;}
.doc-ico.doc-star.on{color:#d4a800;border-color:#e6c65a;background:#fffaea;}
.doc-ico.doc-read.on{
  color:var(--accent);
  border-color:color-mix(in srgb,var(--accent) 40%,var(--line-strong));
  background:color-mix(in srgb,var(--accent) 12%,transparent);
}
.doc-ico.doc-del:hover{border-color:#efb4b4;background:#fff3f3;color:var(--danger);}
/* A read note is DIMMED, never hidden, wherever the row is drawn — the Info tab keeps it, Home
   filters it out of its own list instead. Unprefixed for the same reason as above; the older
   #side-body copy of this rule is now redundant rather than wrong. */
.doc-row.is-read{opacity:.62;}
.doc-row.is-read:hover{opacity:1;}
/* Home's grouped signal lists get the same 6px rhythm the Info tab's .doc-list already has. */
/* v12.77.0 — superseded by the accordion block at the end of this file. */

/* v12.76.0 — the AI pill. Costas: "MELKA THE aI sUMMARY PILL MORE SEXY. ADD AN ai ICON - THE
   GEMINI SINCE THAT WE USE AND FONTS SMALLER. SAME FOR THE Check links & pictures PILL".
   ONE class for all three (AI summary, and the two Check links & pictures buttons), because they
   are the same kind of control — a small, quiet action that reaches Gemini — and they were
   previously three unrelated styles: a blue chip, a .btn .btn-sm, and a bordered pill.
   Unprefixed on purpose: these sit on Home AND inside #side-body, the v12.75.0 rule. */
.ai-pill{
  flex:none;display:inline-flex;align-items:center;gap:5px;
  border:1px solid #cbd8f4;border-radius:999px;
  background:linear-gradient(180deg,#fbfcff,#eaf0ff);
  color:#3552a8;font:600 9px/1 inherit;letter-spacing:.06em;text-transform:uppercase;
  padding:5px 10px 5px 8px;cursor:pointer;white-space:nowrap;
  transition:border-color .13s,box-shadow .13s,background .13s,color .13s;
}
.ai-pill:hover{
  border-color:#8ea6e8;color:#26408f;
  background:linear-gradient(180deg,#ffffff,#e2ebff);
  box-shadow:0 1px 4px rgba(58,99,184,.2);
}
.ai-pill:disabled{opacity:.6;cursor:wait;box-shadow:none;}
.ai-pill .gem-ico{flex:none;display:block;}
.ai-pill .ai-pill-t{display:block;}
.doc-tools .ai-pill{margin-top:0;}

/* v12.77.0 — the news/info accordion. One section per Projop, closed at rest.
   The header was a <div> coloured with var(--pc), a variable set only on `.home-card.tone-*`;
   since v12.69.0 these groups live in the tab strip and not inside that card, so --pc resolved
   to nothing and the heading fell back to plain body ink. It carries its own colour now — the
   same undefined-variable trap as --card in v12.76.0, found while making the header clickable. */
.home-mkt-grp{margin-bottom:6px;border:1px solid var(--line);border-radius:9px;background:var(--card);overflow:hidden;}
.home-mkt-grp-h{
  display:flex;align-items:center;gap:7px;width:100%;margin:0;
  padding:9px 11px;border:0;border-radius:0;background:transparent;
  font:700 11px/1.2 inherit;color:#8a6a2f;text-transform:uppercase;letter-spacing:.04em;
  text-align:left;cursor:pointer;transition:background .12s,color .12s;
}
.home-mkt-grp-h:hover{background:var(--accent-soft);color:var(--accent);}
.home-mkt-grp.open .home-mkt-grp-h{border-bottom:1px solid var(--line);}
.mkt-caret{
  flex:none;display:inline-block;width:11px;font-size:11px;line-height:1;color:var(--muted);
  transition:transform .15s ease;
}
.home-mkt-grp.open .mkt-caret{transform:rotate(90deg);}
.mkt-grp-name{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.mkt-grp-n{
  flex:none;min-width:20px;padding:2px 7px;border-radius:999px;
  background:var(--bg);color:var(--muted);font:600 10px/1.3 inherit;letter-spacing:0;text-align:center;
}
.home-mkt-grp-h:hover .mkt-grp-n{background:#fff;color:var(--accent);}
.home-mkt-grp .doc-list{margin:0;padding:8px;background:var(--bg);}

/* v12.81.1 — the stale-build warning. Deliberately loud and pinned to the top: the failure it
   reports made every release invisible for months, so being subtle here would defeat the point. */
#stale-build-banner{position:fixed;top:0;left:0;right:0;z-index:99999;padding:10px 16px;
  background:#c0392b;color:#fff;font-size:13.5px;line-height:1.45;text-align:center;
  box-shadow:0 2px 10px rgba(0,0,0,.28);}
#stale-build-banner a{color:#fff;text-decoration:underline;font-weight:700;}

/* v12.84.0 — the organization-merge impact preview. */
.om-impact{margin-top:12px;padding-top:10px;border-top:1px solid var(--line);}
.om-impact ul{margin:6px 0 0;padding-left:18px;font-size:13px;line-height:1.6;}
.om-impact li b{color:var(--ink);}

/* v12.90.1 — "Add a person" on an organization's Contacts tab. Same 132px label column as the
   rest of the profile fields (v12.89.3), so it lines up with everything above it. */
.of-contact-add{display:grid;grid-template-columns:132px 1fr auto;column-gap:10px;align-items:center;
  margin-top:14px;padding-top:12px;border-top:1px solid var(--line);}
.of-contact-add label{margin:0;font-size:11.5px;font-weight:600;color:var(--muted);}
.of-contact-add .fp-wrap{min-width:0;}

/* v12.90.3 — a record's name is printed ONCE. #side-title is the panel chrome and .detail-head-name
   is the identity block beside the logo/photo; a company or a person had both. The identity block
   wins because it carries the logo, the type badge and the sub-lines. The title element is still
   populated for back-navigation and for anything reading it — only hidden. A Projop is untouched:
   it has no .detail-head, so its name is the title. */
#side.side-name-in-body #side-title{display:none;}

/* v12.91.1 — the copyable notification report. Plain, email-like typography on purpose: what is
   on screen is what gets pasted. */
.notify-report{border:1px solid var(--line);border-radius:8px;padding:12px 14px;background:var(--card);
  font-size:13.5px;line-height:1.55;max-height:46vh;overflow:auto;}
.notify-report p{margin:0 0 8px;}
.notify-report ul{margin:0 0 12px;padding-left:20px;}
.notify-report a{color:var(--accent);}
.act-preview{margin-bottom:4px;}

/* v12.91.4 — the report's language switch. Greek is the default; English is one click away. */
.nr-lang{display:flex;gap:4px;margin:0 0 8px;}
.nr-lang-b{background:none;border:1px solid var(--line);border-radius:6px;padding:3px 10px;cursor:pointer;
  font-size:11px;font-weight:700;letter-spacing:.4px;color:var(--muted);}
.nr-lang-b.on{border-color:var(--accent);color:var(--accent);background:var(--accent-soft);}

/* v12.91.7 — the note / link mark on an action row. An inline SVG rather than an emoji, so it can
   never fall back to a missing-glyph box; the count only prints when there is more than one. */
.ar-notes{display:inline-flex;align-items:center;gap:2px;color:var(--muted);vertical-align:middle;margin-left:6px;}
.ar-notes svg{display:block;}
.ar-notes-n{font-size:10px;font-weight:700;line-height:1;}

/* v12.92.0 — the name-mismatch mark and its filter count. Orange, not red: the record is not
   broken, it just disagrees with itself and wants a human decision. */
.adm-name-warn{display:inline-flex;align-items:center;justify-content:center;width:14px;height:14px;
  margin-left:4px;border-radius:50%;background:#e67e22;color:#fff;font-size:10px;font-weight:800;
  line-height:1;vertical-align:middle;cursor:help;flex:0 0 auto;}
.adm-mismatch-n{margin-left:5px;font-size:10px;font-weight:700;color:var(--muted);
  background:var(--bg);border-radius:20px;padding:1px 6px;}

/* ===================== SOLUTIONS (v12.93.0) =====================
   The Projop Overview's Solutions section: chips in Preview, tick boxes in Edit.
   Plain class selectors, no #side-body prefix — nothing in the stylesheet styles these names,
   so there is no specificity fight to win here (contrast the Players list, v12.15.1, where an
   older ID-scoped rule outranked a later class-only one however late it was appended).
   Every colour is a DEFINED custom property: an undefined one invalidates the whole declaration
   silently, and jsdom applies no CSS so the suite cannot see it (v12.76.0, v12.77.0). */
.sol-chips{display:flex;flex-wrap:wrap;gap:6px;margin:2px 0 4px;}
.sol-chip{display:inline-flex;align-items:center;padding:3px 10px;border-radius:20px;
  border:1px solid var(--line-strong);background:var(--card);font-size:12px;font-weight:600;
  line-height:1.5;white-space:nowrap;}
.sol-picks{display:flex;flex-wrap:wrap;gap:4px 14px;margin:2px 0 8px;}
.sol-pick{display:inline-flex;align-items:center;gap:6px;font-size:12.5px;cursor:pointer;
  padding:2px 0;min-width:170px;}
.sol-pick input{margin:0;flex:0 0 auto;cursor:pointer;}
.sol-dot{width:9px;height:9px;border-radius:50%;flex:0 0 auto;}
.sol-pick-t{color:var(--ink);}
.sol-add-row{margin-top:2px;}
.sol-add-hint{margin-top:4px;font-size:11.5px;color:var(--muted);}
.sts-count{flex:0 0 auto;font-size:11px;color:var(--muted);white-space:nowrap;}

/* v12.94.0 — the Edit/Save button's birthplace inside #side. It is normally moved straight into
   the popup footer beside Close, which leaves this wrapper empty; :empty hides it so the record
   does not end with a stray gap. It only ever renders here if that move failed. */
.profile-foot{display:flex;justify-content:flex-end;padding:8px 0 2px;}
.profile-foot:empty{display:none;}

/* v12.94.3 — the Status select (Active / Archived). Sits in the same 132px label-left grid as
   every other field on the profile form (v12.89.3), so it lines up with the boxes above it
   rather than shrinking to its own content width. */
.of-archived-field .of-status-select{width:100%;max-width:220px;}

/* ===================== PROFILE PROJOP TILES + TAB ROW (v12.95.0) =====================
   Costas: "replace it with a simpler version of the projop card (photo, title) and list them in a
   row (or 2 if needed)".

   v12.95.2 — THIS COMMENT PREVIOUSLY CONTAINED THE TWO CHARACTERS THAT END A CSS COMMENT, inside
   what was meant to be prose about other class names. That closed the comment early, the words
   after it were parsed as a selector, and the CSS parser then discarded everything up to and
   including the NEXT rule block — which was .pjt-row. So the tiles kept their own styling and
   silently lost their container layout, and every one stacked in a single column.
   NEVER write a star-slash pair inside a CSS comment, including inside a wildcard class pattern.

   The layout is a GRID, not flex: auto-fill wraps to as many rows as it needs (Costas' "or 2 if
   needed") and, unlike a flex row, it cannot be quietly defeated by an inherited flex-direction.
   jsdom applies no CSS, so none of this is observable from the suite — the guard added in
   tools/smoke.test.js checks the STYLESHEET's comment structure instead. */
.pjt-row{display:grid;grid-template-columns:repeat(auto-fill,minmax(104px,116px));
  gap:8px;margin:4px 0 2px;align-items:start;}
.pjt{display:flex;flex-direction:column;min-width:0;border:1px solid var(--line);border-radius:8px;
  overflow:hidden;background:var(--card);text-decoration:none;color:inherit;cursor:pointer;}
.pjt:hover{border-color:var(--accent);box-shadow:var(--shadow);}
.pjt-img{display:block;width:100%;height:58px;object-fit:cover;background:var(--bg);flex:0 0 auto;}
/* The fallback is a span, so its box is built by hand — object-fit does nothing to a span. */
.pjt-img-none{display:flex;align-items:center;justify-content:center;color:var(--muted);
  font-size:15px;font-weight:700;letter-spacing:.04em;}
/* Two lines, hard-capped. The line-clamp trio does the ellipsis where it is supported; max-height
   plus overflow is the fallback that clips regardless, so a long name can never spill out of the
   tile and over the one below it. */
.pjt-name{padding:5px 7px 7px;font-size:10.5px;font-weight:600;line-height:1.3;color:var(--ink);
  word-break:break-word;}

/* The tab strip and the action buttons share one row; the buttons hug the right edge and are
   allowed to drop below the tabs on a narrow panel rather than squeezing them. */
.profile-tabbar{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;}
.profile-tabbar .profile-tabs{flex:1 1 auto;min-width:0;}
.profile-tabbar .profile-actions{flex:0 0 auto;margin:0;}

/* ===================== PROJOP TILE GROUPS + ACTIVITY TAB (v12.96.0) =====================
   Costas: "make all projops cards equal in size, height. Organize them in two levels. Active and
   Archived." Equal height is a FIXED name box, not a max-height: two lines' worth of space is
   reserved whether the name needs one line or two, so every tile in a row ends level.
   No wildcard class patterns are named in this comment — see the v12.95.2 rule about the two
   characters that end a comment block. */
.pjt-grp{margin:2px 0 8px;}
.pjt-grp-h{font-size:10.5px;font-weight:700;text-transform:uppercase;letter-spacing:.05em;
  color:var(--muted);margin:0 0 4px;display:flex;align-items:center;gap:6px;}
.pjt-grp-h span{font-weight:600;color:var(--muted);background:var(--bg);border-radius:20px;
  padding:0 6px;font-size:10px;letter-spacing:0;}
/* v12.97.1 — the fixed-height name box is GONE. See the block at the end of this file. */

.cact-grp{margin:0 0 12px;}
.cact-grp-h{display:flex;align-items:center;gap:7px;font-size:12px;font-weight:700;color:var(--ink);
  border-bottom:1px solid var(--line);padding:0 0 3px;margin:0 0 4px;}
.cact-grp-h a{color:var(--accent);text-decoration:none;cursor:pointer;}
.cact-grp-h a:hover{text-decoration:underline;}
.cact-n{font-weight:600;color:var(--muted);background:var(--bg);border-radius:20px;padding:0 6px;font-size:10px;}
.cact-row{display:grid;grid-template-columns:1fr auto auto;gap:10px;align-items:baseline;
  padding:4px 6px;border-radius:6px;cursor:pointer;font-size:12px;}
.cact-row:hover{background:var(--accent-soft);}
.cact-row.done .cact-task{text-decoration:line-through;color:var(--muted);}
.cact-task{color:var(--ink);min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.cact-meta{color:var(--muted);font-size:11px;white-space:nowrap;}
.cact-when{color:var(--muted);font-size:11px;white-space:nowrap;}

/* ===================== LOG GROUPS + ROOMIER PROJOP TILES (v12.97.0) =====================
   Costas: "make cards big enough or adjust fonts to fit all the projop title", and for the log
   "there will be only heading of the different projops for which there is a log". */
.nl-grp{margin:0 0 14px;}
.nl-grp-h{display:flex;align-items:center;gap:7px;font-size:12px;font-weight:700;color:var(--ink);
  border-bottom:1px solid var(--line);padding:0 0 3px;margin:0 0 6px;}
.nl-grp-n{font-weight:600;color:var(--muted);background:var(--bg);border-radius:20px;
  padding:0 6px;font-size:10px;}

/* ===================== EQUAL TILES, WHOLE TITLES (v12.97.1) =====================
   Costas, twice: "make cards big enough or adjust fonts to fit ALL the projop title", and the
   title was still clipped. Two earlier attempts reserved a FIXED number of lines and clamped the
   rest away — two lines, then three. That is the wrong shape of answer: any fixed count is a
   guess about the longest name, and when the guess is wrong the title is cut, which is the
   complaint. It also made the maths fragile, since `3 * 1.3em` resolves against this element's own
   font-size and quietly changes meaning if the font-size line is ever edited.

   THE GRID DECIDES THE HEIGHT NOW, NOT THE TEXT. `grid-auto-rows:1fr` makes every row exactly as
   tall as its tallest tile, and `.pjt{height:100%}` stretches the others to match. So the name
   wraps to however many lines it needs — no clamp, no cap, no overflow rule — and the tiles are
   still all identical, which was the other half of the ask. A longer name makes every tile in that
   row taller together instead of being truncated.

   The picture keeps its fixed 58px so the images stay aligned across the row; the name box takes
   whatever is left, which is what `flex:1 1 auto` on it does. */
.pjt-row{grid-template-columns:repeat(auto-fill,minmax(140px,164px));grid-auto-rows:1fr;}
.pjt{height:100%;}
.pjt-name{flex:1 1 auto;}

/* ===================== STAKEHOLDER CONTACT PICKER (v12.100.0) ===================== */
.stake-company-tools{margin:0 0 5px;font-size:11px;color:var(--muted);}
.stake-company-tools a{color:var(--accent);text-decoration:none;font-weight:600;}
.stake-company-tools a:hover{text-decoration:underline;}
.stake-company-contacts{max-height:220px;overflow:auto;border:1px solid var(--line);
  border-radius:8px;background:var(--card);padding:3px;}
.field label.stake-company-contact{display:grid;grid-template-columns:14px 24px minmax(0,1fr);gap:7px;
  align-items:center;padding:4px 6px;margin:0;border-radius:5px;cursor:pointer;font-size:11.5px;
  line-height:1.25;font-weight:400;min-height:32px;}
.stake-company-contact:hover{background:var(--accent-soft);}
.field .stake-company-contact input[type=checkbox]{appearance:auto;width:13px;height:13px;
  min-height:0;padding:0;margin:0;flex:0 0 auto;accent-color:var(--accent);}
.stake-company-contact .who-av{width:22px;height:22px;}
.stake-company-contact b{font-size:11.5px;}
.stake-company-contact small{display:inline;color:var(--muted);font-size:10.5px;line-height:1.2;
  margin-left:6px;font-weight:400;}
.stake-company-contact.archived{opacity:.55;cursor:not-allowed;}

/* ===================== REPORTS WORKSPACE (v12.102.0) ===================== */
.modal-card.report-builder-modal{max-width:820px;}
.report-builder{font-size:13px;}
.report-builder .field{margin-bottom:10px;}
.report-builder .field label{font-size:12px;}
.report-builder .field select,.report-builder .field input{min-height:34px;padding:5px 8px;font-size:13px;}
.rb-dates{display:flex;gap:7px;align-items:end;}.rb-dates[hidden]{display:none;}
.rb-dates input{width:50%;min-height:34px;border:1px solid var(--line-strong);border-radius:7px;padding:5px 8px;}
.rb-project-head{display:flex;justify-content:space-between;align-items:center;margin:4px 0 5px;}
.rb-project-head span{color:var(--muted);font-size:11px;}
.rb-projects{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:3px 8px;max-height:310px;overflow:auto;border:1px solid var(--line);border-radius:8px;padding:6px;}
.rb-projects label{display:grid;grid-template-columns:15px minmax(0,1fr);align-items:center;gap:7px;padding:5px 7px;border-radius:5px;font-size:12px;cursor:pointer;}
.rb-projects label:hover{background:var(--accent-soft);}
.rb-projects input[type=checkbox]{width:13px;height:13px;min-height:0;margin:0;padding:0;accent-color:var(--accent);}
.report-builder .hint{font-size:11px;color:var(--muted);margin:9px 0 0;}
@media(max-width:650px){.rb-projects{grid-template-columns:1fr;}}
