/* MONTECO Talent: email threads (Messages screen, person tab, requirement lanes). Built on app.css tokens. No edge bars, no heading rules. */
.th-list{background:var(--panel);border:1px solid var(--hair);border-radius:var(--r-card);box-shadow:var(--shadow-1);overflow:hidden}
.th-row{display:flex;align-items:flex-start;gap:12px;width:100%;padding:14px 16px;border:0;border-bottom:1px solid var(--line);background:var(--panel);text-align:left;cursor:pointer;color:var(--ink);font:inherit}
.th-row:last-child{border-bottom:0}
.th-row:hover{background:var(--surface-2)}
.th-row.is-sel{background:var(--tint);box-shadow:inset 0 0 0 1.5px var(--tint-line)}
.th-row .av{flex:none;margin-top:1px}
.th-main{display:flex;flex-direction:column;gap:2px;min-width:0;flex:1}
.th-top{display:flex;align-items:baseline;gap:8px;min-width:0}
.th-top b{font-size:15px;font-weight:500;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0}
.th-row.is-unread .th-top b{font-weight:700}
.th-org{font-size:13px;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0;flex:1}
.th-time{font-size:12.5px;color:var(--muted);flex:none;margin-left:auto;font-variant-numeric:tabular-nums}
.th-subj{font-size:13.5px;line-height:19px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.th-row.is-unread .th-subj{font-weight:600}
.th-snip{font-size:13.5px;line-height:19px;color:var(--muted);display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.th-chips{display:flex;flex-wrap:wrap;gap:6px;margin-top:4px}
.th-dot{flex:none;margin-top:7px}
.th-empty{padding:28px 20px}

/* the thread */
.th-view{display:flex;flex-direction:column;gap:16px}
.th-vhead{display:flex;align-items:flex-start;gap:14px}
.th-vhead .grow{min-width:0}
.th-vhead h2{margin:0;font-size:20px;line-height:26px;font-weight:600;overflow-wrap:anywhere}
.th-vhead p{margin:2px 0 0;font-size:14px;line-height:20px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.th-vchips{display:flex;flex-wrap:wrap;gap:6px}
.th-view>.th-vchips{margin-top:-4px}
.th-vchips .chip{max-width:100%;min-width:0}
.th-vchips a.chip{text-decoration:none}
.th-ct{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.th-back{display:none;align-self:flex-start}
.th-subject{margin:0;font-size:16px;line-height:24px;font-weight:600}
.th-note{display:flex;gap:12px;align-items:flex-start;padding:14px 16px;border-radius:var(--r-card);background:var(--surface-2);box-shadow:inset 0 0 0 1px var(--hair)}
.th-note>svg{flex:none;width:18px;height:18px;margin-top:2px;color:var(--green-text)}
.th-note p{margin:0;font-size:14.5px;line-height:22px}
.th-note .th-acts{display:flex;flex-wrap:wrap;gap:8px;margin-top:10px}
.th-msgs{display:flex;flex-direction:column;gap:12px}
.th-msg{border-radius:var(--r-card);padding:14px 16px;background:var(--panel);box-shadow:inset 0 0 0 1px var(--hair)}
.th-msg.is-out{background:var(--surface-2)}
.th-msg.is-new{background:var(--tint);box-shadow:inset 0 0 0 1px var(--tint-line)}
.th-msg header{display:flex;align-items:center;gap:10px;margin-bottom:8px}
.th-msg header b{font-size:14px;font-weight:600}
.th-msg header .muted{font-size:13px}
.th-msg header time{margin-left:auto;font-size:12.5px;color:var(--muted);flex:none;font-variant-numeric:tabular-nums}
.th-tags{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:8px}
.th-body{font-size:14.5px;line-height:23px;white-space:pre-wrap;overflow-wrap:anywhere}
.th-compose{border-radius:var(--r-card);background:var(--panel);box-shadow:inset 0 0 0 1px var(--hair);padding:12px 14px;display:flex;flex-direction:column;gap:10px}
.th-compose.is-held{opacity:.7}
.th-compose .th-to{font-size:13px;color:var(--muted);display:flex;flex-wrap:wrap;gap:4px 12px}
.th-box{width:100%;min-height:96px;resize:vertical;border:1px solid var(--hair);border-radius:var(--r-ctl);padding:10px 12px;font:inherit;font-size:14.5px;line-height:22px;color:var(--ink);background:var(--panel)}
.th-box:focus{outline:2px solid var(--focus);outline-offset:1px}
.th-compose .th-bar{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.th-compose .th-bar .grow{flex:1;min-width:0}
.th-match{display:flex;flex-direction:column;gap:12px}
.th-sug{padding:14px 16px;border-radius:var(--r-card);background:var(--surface-2);box-shadow:inset 0 0 0 1px var(--hair)}
.th-sug p{margin:0 0 10px;font-size:14.5px;line-height:22px}
.th-res{display:flex;flex-direction:column;gap:2px;max-height:260px;overflow:auto}
.th-pick{display:flex;align-items:center;gap:10px;width:100%;min-height:48px;padding:6px 10px;border:0;border-radius:8px;background:none;text-align:left;font:inherit;color:var(--ink);cursor:pointer}
.th-pick:hover{background:var(--surface)}
.th-pick[aria-pressed="true"]{background:var(--tint);box-shadow:inset 0 0 0 1.5px var(--tint-line)}
.th-pick span.s{display:block;font-size:13px;color:var(--muted)}

/* two lanes on a requirement */
.th-lanes{display:grid;grid-template-columns:1fr 1fr;gap:16px;align-items:start}
.th-lane{display:flex;flex-direction:column;gap:10px;min-width:0}
.th-lane>header{display:flex;align-items:flex-start;gap:10px}
.th-lane>header h3{margin:0;font-size:16px;line-height:22px;font-weight:600}
.th-lane>header p{margin:2px 0 0;font-size:13.5px;line-height:20px;color:var(--muted)}
.th-lane>header .grow{min-width:0}
.th-views{margin:0 0 14px}
.th-ptab{display:flex;flex-direction:column;gap:14px}
.th-ptab .th-ph{display:flex;align-items:center;gap:10px}
.th-ptab h3{margin:0;font-size:16px;font-weight:600}
.th-sub{margin:18px 0 8px;font-size:15px;font-weight:600}

/* the Messages screen */
.msg-shell{flex:1;min-height:0;display:flex;flex-direction:column;max-width:1360px;width:100%;margin:0 auto;padding:12px 28px 16px}
.msg-head{display:flex;align-items:flex-end;gap:16px;flex-wrap:wrap;margin-bottom:12px}
.msg-head h1{margin:0;font-size:28px;line-height:34px;font-weight:600}
.msg-head p{margin:2px 0 0;font-size:14.5px;color:var(--muted)}
.msg-bar{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin-bottom:12px}
.msg-bar .inp-wrap{flex:1;min-width:200px;max-width:340px}
.msg-grid{flex:1;min-height:0;display:grid;grid-template-columns:minmax(320px,420px) minmax(0,1fr);gap:16px}
.msg-listcol,.msg-viewcol{min-height:0;overflow:auto}
.msg-viewcol{background:var(--panel);border:1px solid var(--hair);border-radius:var(--r-card);box-shadow:var(--shadow-1);padding:20px 22px}
.msg-pick{display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;gap:6px;min-height:100%;color:var(--muted)}
.msg-pick b{color:var(--ink);font-size:16px}
@media (max-width:1100px){.th-lanes{grid-template-columns:1fr}}
@media (max-width:900px){
  .msg-shell{padding:8px 16px 12px}
  .msg-grid{grid-template-columns:minmax(0,1fr)}
  .msg-grid.is-open .msg-listcol{display:none}
  .msg-grid:not(.is-open) .msg-viewcol{display:none}
  .msg-viewcol{padding:0 16px 16px}
  /* the way back stays at the top of the open conversation while it scrolls */
  .th-view>.th-back{display:inline-flex;position:sticky;top:0;z-index:3;align-self:stretch;justify-content:flex-start;height:48px;margin:0 -16px -4px;padding:0 16px;border-radius:0;background:var(--panel);box-shadow:0 1px 0 var(--line)}
  .msg-head h1{font-size:24px;line-height:30px}
}
@media (max-width:560px){
  .th-vhead h2{font-size:18px;line-height:24px}
  .th-msg{padding:12px}
  /* all five filters fit across a phone, with a count only where it matters, so nothing needs a sideways scroll to reach */
  #msgTabs,#msgTabs .tabs{width:100%}
  #msgTabs .tabs.seg{display:flex}
  #msgTabs .tab{flex:1 1 auto;justify-content:center;padding:0 6px;gap:4px;font-size:13px}
  #msgTabs .tab[data-key="all"] .n,#msgTabs .tab[data-key="candidates"] .n,#msgTabs .tab[data-key="clients"] .n{display:none}
  .msg-bar .inp-wrap{max-width:none}
}
