/* Supervisor Finder: editorial light theme (warm greys, flat white cards, red accent, pill controls) */
:root {
  --page: #e8e8eb;
  --bg: #f4f4f4;
  --panel: #ffffff;
  --panel-2: #f3f3f3;
  --text: #151515;
  --muted: #8d8d8d;
  --line: #ebebeb;
  --red: #e5383b;
  --red-dark: #c42d30;
  --red-soft: #fdeeee;
  --red-tint: #f9cfd0;
  /* legacy names, mapped to the red theme */
  --lime: var(--red);
  --lime-strong: var(--red-dark);
  --lime-ink: #ffffff;
  --lavender: #f1f1f1;
  --lavender-ink: #3a3a3a;
  --sky: #f1f1f1;
  --sky-ink: #3a3a3a;
  --mint: #e8f5ec;
  --mint-ink: #1d7442;
  --teal: #151515;
  --teal-2: #000000;
  --rose: #fdeeee;
  --rose-ink: #c42d30;
  --amber: #fff2e3;
  --amber-ink: #9a5410;
  --dark: #151515;
  --bar-a: #e5383b;
  --bar-b: #f6b2b3;
  --radius: 24px;
  --radius-sm: 14px;
  --shadow: none;
}

* { box-sizing: border-box; }
html, body { background: var(--page); }
body {
  margin: 0; color: var(--text);
  font: 14px/1.5 "Inter", "Segoe UI", Roboto, Arial, sans-serif; font-feature-settings: "cv11", "ss01";
  -webkit-font-smoothing: antialiased;
}
a { color: var(--text); text-decoration: none; }
a:hover { color: var(--teal); }
.link { color: var(--teal); font-weight: 600; }

/* ---------- frame ---------- */
.frame { max-width: 1480px; margin: 18px auto; background: var(--bg); border-radius: 26px; overflow: hidden;
         box-shadow: 0 10px 40px rgba(20, 24, 31, .08); min-height: calc(100vh - 36px); display: flex; }
.side { width: 236px; flex-shrink: 0; background: var(--panel); padding: 26px 18px; display: flex; flex-direction: column; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 20px; margin: 0 10px 34px; letter-spacing: -.02em; }
.logo .mark { width: 30px; height: 30px; border-radius: 9px; background: var(--dark); color: var(--lime); display: grid; place-items: center; font-size: 15px; }
.nav a { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 12px; color: var(--text);
         font-weight: 500; margin-bottom: 4px; }
.nav a svg { width: 18px; height: 18px; flex-shrink: 0; }
.nav a:hover { background: var(--panel-2); color: var(--text); }
.nav a.active { background: var(--lime); font-weight: 700; color: var(--lime-ink); }
.side-foot { margin-top: auto; text-align: center; padding-top: 24px; }
.side-foot .avatar.lg { margin: 0 auto 10px; }
.side-foot .who { font-weight: 700; font-size: 15px; word-break: break-all; }
.side-foot .role { color: var(--muted); font-size: 12px; margin-bottom: 18px; }
.side-foot .logout { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-weight: 500; }
.side-foot .logout svg { width: 16px; height: 16px; }

.main { flex: 1; min-width: 0; padding: 28px 32px 48px; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.topbar > div:first-child { min-width: 260px; flex: 1; }
.topbar h1 { font-size: 26px; font-weight: 800; margin: 0; letter-spacing: -.02em; }
.topbar .date { color: var(--muted); font-size: 13px; margin-top: 2px; }
.topbar .crumb { font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.topbar .crumb a { color: var(--muted); }
.top-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.top-actions form { margin: 0; }
.icon-btn { width: 40px; height: 40px; border-radius: 12px; background: var(--panel); display: grid; place-items: center;
            border: 1px solid var(--line); color: var(--text); position: relative; }
.icon-btn svg { width: 18px; height: 18px; }
.icon-btn .dot { position: absolute; top: 9px; right: 10px; width: 7px; height: 7px; border-radius: 50%; background: #ef5a4f; }
.me { display: flex; align-items: center; gap: 10px; padding-left: 6px; }
.me .name { font-weight: 700; font-size: 14px; line-height: 1.2; }
.me .role { color: var(--muted); font-size: 12px; }

.avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 13px;
          background: var(--lavender); color: var(--lavender-ink); flex-shrink: 0; }
.avatar.lg { width: 64px; height: 64px; font-size: 20px; }
.avatar.sm { width: 32px; height: 32px; font-size: 12px; }
.avatar.c1 { background: var(--sky); color: var(--sky-ink); }
.avatar.c2 { background: var(--mint); color: var(--mint-ink); }
.avatar.c3 { background: var(--amber); color: var(--amber-ink); }
.avatar.c4 { background: var(--rose); color: var(--rose-ink); }

/* ---------- layout helpers ---------- */
.grid { display: grid; gap: 18px; }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g3c { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: minmax(0, 2.1fr) minmax(0, 1fr); }
.dash { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 18px; align-items: start; }
.stack { display: grid; gap: 18px; align-content: start; }
.dash > *, .stack > *, .grid > * { min-width: 0; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }
.mt { margin-top: 18px; }

/* ---------- cards ---------- */
.card { background: var(--panel); border-radius: var(--radius); padding: 20px 22px; box-shadow: var(--shadow); }
.card h2, .card-title { font-size: 18px; font-weight: 700; margin: 0 0 14px; letter-spacing: -.01em; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.card-head h2 { margin: 0; }
.card .hint { color: var(--muted); font-size: 12px; margin: -10px 0 14px; }

.stat { border-radius: var(--radius); padding: 16px 18px 18px; text-align: center; }
.stat .lbl { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; text-align: left; }
.stat .lbl i { width: 24px; height: 24px; border-radius: 50%; background: rgba(255, 255, 255, .55); display: grid; place-items: center; font-style: normal; }
.stat .lbl i svg { width: 13px; height: 13px; }
.stat .val { font-size: 30px; font-weight: 800; margin: 12px 0 2px; letter-spacing: -.02em; }
.stat .cap { font-size: 12px; opacity: .75; }
.stat.lav { background: var(--lavender); }
.stat.sky { background: var(--sky); }
.stat.mint { background: var(--mint); }
.stat.lime { background: var(--lime); }

.promo { background: var(--teal); color: #fff; border-radius: var(--radius); padding: 22px; position: relative; overflow: hidden; }
.promo h3 { margin: 0 0 12px; font-size: 18px; font-weight: 600; }
.promo .big { font-size: 21px; font-weight: 800; overflow-wrap: anywhere; line-height: 1.25; }
.promo .big.email { font-size: 17px; }
.promo .sub2 { opacity: .85; font-size: 13px; margin: 4px 0 16px; }
.promo::after { content: ""; position: absolute; right: -40px; bottom: -40px; width: 150px; height: 150px; border-radius: 50%;
                border: 22px solid rgba(255, 255, 255, .08); }

/* ---------- chart ---------- */
.chart { display: grid; grid-template-columns: 38px 1fr; gap: 6px; }
.chart .yaxis { display: flex; flex-direction: column; justify-content: space-between; color: var(--muted); font-size: 11px; height: 230px; text-align: right; padding-bottom: 2px; }
.chart .plot { position: relative; height: 230px; display: flex; align-items: flex-end; justify-content: space-around;
               background-image: repeating-linear-gradient(to top, transparent 0, transparent 56.5px, var(--line) 56.5px, var(--line) 57.5px); }
.chart .day { display: flex; gap: 5px; align-items: flex-end; height: 100%; }
.chart .bar { width: 11px; border-radius: 6px 6px 3px 3px; min-height: 3px; }
.chart .bar.a { background: var(--bar-a); }
.chart .bar.b { background: var(--bar-b); }
.chart .xaxis { grid-column: 2; display: flex; justify-content: space-around; color: var(--muted); font-size: 12px; margin-top: 6px; }
.legend { display: flex; gap: 14px; font-size: 12px; color: var(--muted); }
.legend span::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.legend .a::before { background: var(--bar-a); }
.legend .b::before { background: var(--bar-b); }

/* ---------- list rows (like "Store Sell Ratio" / team members) ---------- */
.list-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; margin-bottom: 10px; background: var(--panel); }
.list-row:hover { border-color: #dfe2e6; color: var(--text); }
.list-row .grow { flex: 1; min-width: 0; }
.list-row .t { font-weight: 600; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list-row .s { color: var(--muted); font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list-row .chev { color: var(--muted); display: grid; }
.list-row .chev svg { width: 16px; height: 16px; }
.avatar svg { width: 15px; height: 15px; }
.list-row .ic { width: 30px; height: 30px; border-radius: 10px; background: var(--panel-2); display: grid; place-items: center; }
.list-row .ic svg { width: 15px; height: 15px; }

/* ---------- tables ---------- */
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px 10px; vertical-align: middle; }
th { font-size: 12.5px; color: var(--muted); font-weight: 500; border-bottom: 1px solid var(--line); }
td { border-bottom: 1px solid var(--line); font-size: 13.5px; }
tr:last-child td { border-bottom: 0; }
tbody tr:hover td, table tr:hover td { background: #fafbfc; }
td.num, th.num { text-align: right; }
.table-wrap { overflow-x: auto; }

/* ---------- badges ---------- */
.badge { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 11.5px; font-weight: 700; background: var(--panel-2); color: var(--muted); white-space: nowrap; text-transform: capitalize; }
.s-queued { background: var(--sky); color: var(--sky-ink); }
.s-sent { background: var(--mint); color: var(--mint-ink); }
.s-replied { background: var(--lime); color: var(--lime-ink); }
.s-bounced, .s-failed { background: var(--rose); color: var(--rose-ink); }
.s-sending { background: var(--amber); color: var(--amber-ink); }
.s-skipped { text-decoration: line-through; }
.chip { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: 12px; font-weight: 600; background: var(--panel); border: 1px solid var(--line); color: var(--text); }
.chip.on { background: var(--dark); color: #fff; border-color: var(--dark); }
.chip:hover { color: var(--text); border-color: #d5d9de; }
.chip.on:hover { color: #fff; }
.warn-dot { color: var(--rose-ink); font-weight: 800; }
.soft-dot { color: var(--amber-ink); font-weight: 800; }

/* ---------- buttons & forms ---------- */
.btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); background: var(--panel); color: var(--text);
       padding: 9px 16px; border-radius: 11px; cursor: pointer; font: inherit; font-weight: 600; font-size: 13px; white-space: nowrap; }
.btn:hover { background: var(--panel-2); color: var(--text); }
.btn.primary { background: var(--lime); border-color: var(--lime); color: var(--lime-ink); }
.btn.primary:hover { background: var(--lime-strong); }
.btn.dark { background: var(--dark); border-color: var(--dark); color: #fff; }
.btn.dark:hover { background: #33373e; color: #fff; }
.btn.danger { color: var(--rose-ink); }
.btn.small { padding: 6px 12px; font-size: 12px; border-radius: 9px; }
.btn.full { width: 100%; justify-content: center; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.btn svg { width: 15px; height: 15px; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=datetime-local], input[type=file], select, textarea {
  font: inherit; color: var(--text); background: var(--panel-2); border: 1px solid transparent; border-radius: 11px; padding: 10px 12px; width: 100%; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--lime-strong); background: #fff; box-shadow: 0 0 0 4px rgba(229, 56, 59, .12); }
textarea { min-height: 380px; font-family: ui-monospace, Consolas, monospace; font-size: 13px; line-height: 1.55; }
label { display: block; font-size: 12px; color: var(--muted); margin: 12px 0 5px; font-weight: 600; }
label.check { display: flex; align-items: center; gap: 8px; color: var(--text); font-size: 13.5px; }
.search { position: relative; }
.search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--muted); }
.search input { padding-left: 36px; background: var(--panel); border: 1px solid var(--line); }

/* ---------- misc ---------- */
.muted { color: var(--muted); }
.small { font-size: 12px; }
.mono { font-family: ui-monospace, Consolas, monospace; font-size: 12px; }
.strong { font-weight: 700; }
.banner { padding: 12px 16px; border-radius: 14px; margin-bottom: 16px; font-size: 13.5px; }
.banner a { font-weight: 700; text-decoration: underline; }
.banner.dry { background: var(--amber); color: var(--amber-ink); }
.banner.ok { background: var(--mint); color: var(--mint-ink); }
.banner.error { background: var(--rose); color: var(--rose-ink); }
.banner.info { background: var(--sky); color: var(--sky-ink); }
.preview { border: 1px solid var(--line); border-radius: 14px; padding: 18px 22px; background: #fff; font-size: 14px; }
.preview p { margin: 0 0 12px; }
.notes { font-size: 13px; }
.notes table { font-size: 12px; }
.notes td, .notes th { padding: 6px 8px; }
.notes h1 { font-size: 16px; } .notes h2 { font-size: 14px; margin: 14px 0 6px; }
details summary { cursor: pointer; font-weight: 700; list-style: none; display: flex; align-items: center; justify-content: space-between; }
details summary::after { content: "+"; color: var(--muted); font-weight: 400; font-size: 18px; }
details[open] summary::after { content: "–"; }
.bulkbar { position: sticky; top: 0; z-index: 2; background: var(--bg); padding: 10px 0; }
.kv { display: grid; grid-template-columns: 110px 1fr; gap: 8px 12px; font-size: 13.5px; }
.kv > div:nth-child(odd) { color: var(--muted); }
.sched p { margin: 0 0 4px; }
.sched ul { margin: 0; padding-left: 16px; }
.sched { font-size: 12px; background: var(--panel-2); border-radius: 12px; padding: 10px 12px; }
.empty { color: var(--muted); padding: 22px; text-align: center; font-size: 13px; }
.divider { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }
.attach { display: inline-flex; align-items: center; gap: 8px; padding: 7px 12px; border-radius: 10px; background: var(--panel-2); margin: 0 6px 6px 0; font-size: 13px; font-weight: 600; }
.attach svg { width: 15px; height: 15px; color: var(--teal); }
.progress { height: 8px; background: var(--panel-2); border-radius: 99px; overflow: hidden; }
.progress > div { height: 100%; background: var(--lime-strong); border-radius: 99px; }
ol.steps { padding-left: 18px; font-size: 13px; } ol.steps li { margin-bottom: 6px; }

@media (max-width: 1100px) {
  .dash { grid-template-columns: 1fr; }
  .g3 { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .frame { margin: 0; border-radius: 0; flex-direction: column; }
  .side { width: auto; padding: 14px 16px; flex-direction: row; align-items: center; gap: 10px; flex-wrap: wrap; }
  .logo { margin: 0 12px 0 0; }
  .nav { display: flex; gap: 4px; flex-wrap: wrap; }
  .side-foot { display: none; }
  .main { padding: 18px 16px 40px; }
  .g4, .g3c { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g2 { grid-template-columns: 1fr; }
  .me .txt { display: none; }
}

input[type=checkbox] { accent-color: var(--teal); width: 16px; height: 16px; }

/* ---------- multi-account & v2 additions ---------- */
.side-accounts { margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--line); }
.side-label { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 700; margin: 0 10px 10px; }
.side-acc { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 12px; margin-bottom: 4px; }
.side-acc:hover { background: var(--panel-2); color: var(--text); }
.side-acc .grow { min-width: 0; flex: 1; display: flex; flex-direction: column; line-height: 1.25; }
.side-acc .t { font-weight: 600; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-acc .s { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-acc .star { color: #c9a400; }
.side-add { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--teal); margin: 6px 10px 0; }
.side-add svg { width: 14px; height: 14px; }
.sync-form { margin: 0; }
.promo-acc { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: rgba(255, 255, 255, .1); border-radius: 12px; margin-bottom: 8px; }
.promo-acc .grow { flex: 1; min-width: 0; }
.promo-acc .usage { text-align: right; font-weight: 800; font-size: 15px; }
.sub3 { font-size: 11.5px; opacity: .8; font-weight: 400; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.btn.ghost { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .45); }
.btn.ghost:hover { background: rgba(255, 255, 255, .12); color: #fff; }
.chip.warn { border-color: var(--rose); color: var(--rose-ink); }
.chip.warn.on { background: var(--rose-ink); border-color: var(--rose-ink); color: #fff; }
a.stat { display: block; color: var(--text); transition: transform .12s ease; }
a.stat:hover { color: var(--text); transform: translateY(-2px); }
.attach-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 4px; }
.attach-row .attach { margin: 0; }
.attach-row.off .attach { opacity: .45; text-decoration: line-through; }
.attach-row form { margin: 0; }
.list-row .ic { font-weight: 800; font-size: 13px; }
@media (max-width: 860px) { .side-accounts { display: none; } }

/* ---------- AI assistant ---------- */
.ai-toggle { display: inline-flex; align-items: center; gap: 7px; padding: 7px 8px 7px 12px; border-radius: 999px; cursor: pointer;
             border: 1px solid var(--line); background: var(--panel); color: var(--muted); font: inherit; font-weight: 700; font-size: 13px; }
.ai-toggle svg { width: 15px; height: 15px; }
.ai-toggle .knob { width: 34px; height: 20px; border-radius: 999px; background: #d5d9de; position: relative; transition: background .15s; }
.ai-toggle .knob::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%;
                          background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .2); transition: left .15s; }
.ai-toggle.on { color: var(--lime-ink); border-color: var(--lime-strong); background: #f4fbd9; }
.ai-toggle.on .knob { background: var(--lime-strong); }
.ai-toggle.on .knob::after { left: 16px; }
.side-ai { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); font-weight: 600; margin-bottom: 12px; }
.side-ai svg { width: 15px; height: 15px; }
.side-ai .on { color: var(--mint-ink); }
.side-ai .off { color: var(--muted); font-weight: 500; }
.ai-card .card-head h2 { display: inline-flex; align-items: center; gap: 8px; }
.ai-card .card-head h2 svg, #ai .card-head h2 svg { width: 18px; height: 18px; }
.ai-sub { font-size: 12.5px; font-weight: 700; margin-bottom: 6px; }
.reply-text { white-space: pre-wrap; background: var(--panel-2); border-radius: 12px; padding: 12px 14px; font-size: 13.5px;
              line-height: 1.55; max-height: 360px; overflow: auto; }
.ai-task { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 14px; }
.ai-task-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.ai-task-head form { margin: 0; }
.ai-task p { margin: 6px 0; }
.mt-s { margin-top: 10px; }
ul.tight { margin: 6px 0 10px; padding-left: 20px; }
ul.tight li { margin-bottom: 4px; }
textarea.short { min-height: 150px; }
textarea.draft { min-height: 280px; font-family: inherit; font-size: 13.5px; }
.tag { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 11.5px; font-weight: 700; white-space: nowrap;
       background: var(--panel-2); color: var(--muted); }
.tag.t-positive, .tag.t-meeting, .tag.v-ready { background: var(--mint); color: var(--mint-ink); }
.tag.t-wants_info, .tag.t-referral { background: var(--sky); color: var(--sky-ink); }
.tag.t-no_position, .tag.t-declined, .tag.v-fix_first, .tag.u-today { background: var(--rose); color: var(--rose-ink); }
.tag.v-minor_issues { background: var(--amber); color: var(--amber-ink); }
.queued-box { background: var(--sky); color: var(--sky-ink); border-radius: 14px; padding: 12px 14px; margin-bottom: 14px; }
.queued-box .btn.danger { background: #fff; border-color: #f3c4c0; }
.queued-box .btn.danger:hover { background: var(--rose); }
.model-pick { width: auto; padding: 6px 10px; font-size: 12px; border-radius: 9px; }
.rewrite-box { margin-top: 16px; border: 1px dashed var(--lime-strong); background: #fbfdf2; border-radius: 14px; padding: 14px 16px; }
.rewrite-box .ai-sub { display: inline-flex; align-items: center; gap: 6px; }
.rewrite-box .ai-sub svg { width: 15px; height: 15px; }
.banner.has-undo { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.undo-form { margin: 0; flex-shrink: 0; }
.filter-bar { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.filter-note { font-size: 12.5px; color: var(--muted); margin: -4px 0 10px; }
.filter-note a { font-weight: 700; color: var(--text); text-decoration: underline; }
.search .clear-x { color: var(--muted); font-weight: 700; padding: 0 4px; }
.chip.empty { opacity: .65; }

/* ---------- Fit & Evidence ---------- */
.progress-card { margin-bottom: 18px; }
.act-tiles { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 10px; margin-bottom: 18px; }
@media (max-width: 1300px) { .act-tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.act-tile { display: block; border-radius: 16px; padding: 12px 14px; background: var(--panel); border: 2px solid transparent; color: var(--text); }
.act-tile:hover { color: var(--text); border-color: var(--line); }
.act-tile.on { border-color: var(--dark); }
.act-tile .n { font-size: 26px; font-weight: 800; line-height: 1.1; }
.act-tile .l { font-weight: 700; font-size: 13px; margin-top: 2px; }
.act-tile .d { font-size: 11.5px; color: var(--muted); margin-top: 4px; line-height: 1.35; }
.act-tile.act-reply_needed, .act-tile.act-email_now { background: #eaf8d2; }
.act-tile.act-follow_up_now, .act-tile.act-email_this_week { background: #e6eefc; }
.act-tile.act-wait_for_reply { background: #f4f1fd; }
.act-tile.act-low_priority { background: #fbf6e6; }
.act-tile.act-skip { background: #fdeeed; }
.act { display: inline-block; border-radius: 999px; padding: 4px 11px; font-size: 12px; font-weight: 800; white-space: nowrap; }
.act.big { font-size: 14px; padding: 7px 14px; }
.act-reply_needed, .act-email_now { background: var(--lime); color: var(--lime-ink); }
.act-follow_up_now, .act-email_this_week { background: var(--sky); color: var(--sky-ink); }
.act-wait_for_reply { background: var(--lavender); color: var(--lavender-ink); }
.act-low_priority { background: var(--amber); color: var(--amber-ink); }
.act-skip { background: var(--rose); color: var(--rose-ink); }
.ring { display: inline-flex; align-items: baseline; justify-content: center; gap: 1px; min-width: 54px; height: 54px; padding-top: 14px;
        border-radius: 50%; font-weight: 800; font-size: 19px; background: var(--panel-2); color: var(--text); box-sizing: border-box; }
.ring small { font-size: 10px; color: var(--muted); font-weight: 600; }
.ring.sm { min-width: 44px; height: 44px; padding-top: 11px; font-size: 15px; }
.ring-high { background: var(--lime); color: var(--lime-ink); }
.ring-medium { background: var(--sky); color: var(--sky-ink); }
.ring-low { background: var(--amber); color: var(--amber-ink); }
.ring-fit { background: var(--lavender); color: var(--lavender-ink); }
.sig-row { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0; }
.sig-row.compact { margin: 0 0 4px; gap: 4px; }
.sig { font-size: 11.5px; font-weight: 700; padding: 3px 9px; border-radius: 999px; background: var(--panel-2); color: #a3a9b1; }
.sig.on { background: var(--mint); color: var(--mint-ink); }
.fit-row { display: grid; grid-template-columns: minmax(0, 2.2fr) auto minmax(0, 2fr) minmax(0, 2.2fr); gap: 16px; align-items: center;
           padding: 14px 10px; border-bottom: 1px solid var(--line); color: var(--text); border-radius: 12px; }
.fit-row:hover { background: var(--panel-2); color: var(--text); }
.fit-who { display: flex; gap: 10px; align-items: center; min-width: 0; }
.fit-scores { display: flex; gap: 6px; align-items: center; }
.clamp2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 4px; }
@media (max-width: 1000px) { .fit-row { grid-template-columns: 1fr; } }
.ev-head { display: grid; grid-template-columns: auto auto minmax(0, 1fr); gap: 18px; align-items: center; }
.ev-score { display: flex; gap: 10px; align-items: center; }
.ev-next { background: var(--panel-2); border-radius: 14px; padding: 10px 14px; }
@media (max-width: 900px) { .ev-head { grid-template-columns: 1fr; } }
.opp { border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; margin-top: 4px; background: #fbfdf2; }
.opp.opp-no { background: #fdf2f1; }
.ev-sec { margin-top: 16px; }
.ev-sec h3 { font-size: 14px; margin: 0 0 8px; }
.ev-sec summary { cursor: pointer; }
.ev-item { display: grid; grid-template-columns: 86px minmax(0, 1fr); gap: 8px; padding: 6px 0; border-bottom: 1px dashed var(--line); }
.ev-date { padding-top: 2px; }
.tag.rel-high { background: var(--mint); color: var(--mint-ink); }
.tag.rel-medium { background: var(--sky); color: var(--sky-ink); }
.hook { margin-top: 14px; padding: 12px 14px; border-radius: 14px; background: #f4fbd9; border: 1px dashed var(--lime-strong); }
.todo { display: flex; gap: 10px; align-items: flex-start; padding: 6px 0; }
.todo form { margin: 0; }
.todo .tick { width: 20px; height: 20px; border-radius: 6px; border: 2px solid #c9cfd6; background: #fff; cursor: pointer; display: inline-grid;
              place-items: center; font-size: 12px; font-weight: 800; color: var(--mint-ink); padding: 0; flex-shrink: 0; }
.todo.done span:last-child { text-decoration: line-through; color: var(--muted); }
.todo.done .tick { background: var(--mint); border-color: var(--mint); }
.match-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; gap: 6px 12px; font-size: 13px; }
.match-grid .mh { font-size: 11.5px; color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: .03em; }
.strength { font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 999px; }
.strength.s-strong { background: var(--mint); color: var(--mint-ink); }
.strength.s-medium { background: var(--sky); color: var(--sky-ink); }
.strength.s-weak { background: var(--amber); color: var(--amber-ink); }
table.pts td { padding: 3px 8px 3px 0; font-size: 13px; border: 0; }
/* leads & muse */
.lead-row { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr) auto auto; gap: 14px; align-items: center;
            padding: 12px 10px; border-bottom: 1px solid var(--line); color: var(--text); border-radius: 12px; }
.lead-row:hover { background: var(--panel-2); color: var(--text); }
@media (max-width: 1000px) { .lead-row { grid-template-columns: 1fr; } }
.lead-text { white-space: pre-wrap; background: var(--panel-2); border-radius: 12px; padding: 12px 14px; font-size: 13.5px; max-height: 320px; overflow: auto; }
.l-new { background: var(--sky); color: var(--sky-ink); }
.l-researching, .l-drafting { background: var(--amber); color: var(--amber-ink); }
.l-researched { background: var(--lavender); color: var(--lavender-ink); }
.l-drafted { background: var(--lime); color: var(--lime-ink); }
.l-dismissed { background: var(--panel-2); color: var(--muted); }
.l-error { background: var(--rose); color: var(--rose-ink); }
.copy-box { display: flex; gap: 8px; align-items: center; }
.copy-box input { font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; }
.steps-num { counter-reset: s; list-style: none; padding: 0; }
.steps-num li { counter-increment: s; position: relative; padding: 4px 0 8px 34px; }
.steps-num li::before { content: counter(s); position: absolute; left: 0; top: 2px; width: 24px; height: 24px; border-radius: 50%;
                        background: var(--lime); color: var(--lime-ink); font-weight: 800; font-size: 12px; display: grid; place-items: center; }
.dot-ok { color: var(--mint-ink); font-weight: 800; }
.dot-bad { color: var(--rose-ink); font-weight: 800; }
.prio-list .list-row { margin-bottom: 8px; }
.card-head h2 { display: inline-flex; align-items: center; gap: 8px; }
.card-head h2 svg { width: 18px; height: 18px; flex-shrink: 0; }

/* ---------- Find professors ---------- */
.harvest-card { margin-bottom: 16px; }
.harvest-card summary { cursor: pointer; list-style: none; }
.harvest-card summary svg { width: 15px; height: 15px; vertical-align: -2px; }
.country-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 2px 12px; }
.check.country { margin: 0; font-size: 13px; }
.hs { font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 999px; background: var(--panel-2); color: var(--muted); }
.hs-done { background: var(--mint); color: var(--mint-ink); }
.hs-running { background: var(--amber); color: var(--amber-ink); }
.hs-paused { background: var(--sky); color: var(--sky-ink); }
.hs-error { background: var(--rose); color: var(--rose-ink); }
.ai-search { margin-bottom: 16px; background: #f4fbd9; border: 1px solid var(--lime-strong); }
.ai-search input[type=text] { flex: 1; font-size: 14px; }
.ai-icon svg { width: 20px; height: 20px; }
.prof-layout { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 16px; align-items: start; }
@media (max-width: 1000px) { .prof-layout { grid-template-columns: 1fr; } }
.prof-filters label.check { margin: 4px 0; }
.prof-row { display: grid; grid-template-columns: 22px minmax(0, 1fr) 150px 160px; gap: 14px; align-items: center;
            padding: 12px 6px; border-bottom: 1px solid var(--line); }
.prof-row:hover { background: var(--panel-2); }
.prof-main { color: var(--text); min-width: 0; }
.prof-main:hover { color: var(--text); }
.dom-chips { margin-top: 6px; display: flex; flex-wrap: wrap; gap: 4px; }
.clamp1 { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 4px; }
.ai-reason { margin-top: 6px; color: var(--lime-ink); background: #f4fbd9; border-radius: 8px; padding: 4px 8px; }
.ai-reason svg { width: 12px; height: 12px; vertical-align: -1px; }
.meter { height: 8px; border-radius: 999px; background: var(--panel-2); overflow: hidden; margin-bottom: 4px; }
.meter div { height: 100%; background: var(--lime-strong); border-radius: 999px; }
@media (max-width: 1000px) { .prof-row { grid-template-columns: 22px 1fr; } .prof-nums, .prof-ev { grid-column: 2; } }

/* shortlist folders */
.folder-head { margin-bottom: 12px; background: #fbfdf2; }
.folder-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.x-btn { border: 0; background: transparent; color: var(--muted); cursor: pointer; font-weight: 800; padding: 0 2px; }
.x-btn:hover { color: var(--rose-ink); }

/* shortlists: folder list in the sidebar, overview cards, folder page */
.nav-folders { margin: -2px 0 6px 30px; padding-left: 10px; border-left: 1px solid #e4e4e4; }
.nav .nav-folders a.nf { display: flex; align-items: center; gap: 8px; padding: 5px 8px; margin: 0; border-radius: 10px;
  font-size: 13px; font-weight: 500; color: #444; }
.nav .nav-folders a.nf:hover { background: #fff; }
.nav .nav-folders a.nf.active { background: var(--dark); color: #fff; }
.nf-who { flex: 0 0 18px; height: 18px; border-radius: 50%; font-size: 10px; font-weight: 700; display: grid; place-items: center;
  background: #eceff5; color: #3b4a6b; }
.nf-who.nf-bio { background: #e8f5ec; color: #1d7442; }
.nf-n { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nf-c { font-size: 11.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.nav .nav-folders a.nf.active .nf-c { color: rgba(255, 255, 255, .7); }
.nav .nav-folders a.nf-more { color: var(--muted); font-size: 12.5px; }

.sl-group { margin-bottom: 26px; }
.sl-group-head svg, .sl-new svg, .sl-head svg { width: 15px; height: 15px; vertical-align: -2px; }
.sl-new .strong { display: inline-flex; gap: 6px; align-items: center; }
.sl-group-head { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; }
.sl-group-head h2 { margin: 0; font-size: 18px; }
.sl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.sl-card { display: block; color: inherit; text-decoration: none; padding: 18px; transition: box-shadow .15s, transform .15s; }
.sl-card:hover { box-shadow: 0 6px 22px rgba(0, 0, 0, .08); transform: translateY(-1px); color: inherit; }
.sl-name { font-weight: 700; font-size: 16px; margin-bottom: 2px; display: flex; gap: 8px; align-items: baseline; }
.sl-name .star { color: var(--brand, #E5383B); }
.sl-count { font-size: 30px; font-weight: 700; line-height: 1.1; margin: 10px 0 2px; }
.sl-mini { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12.5px; color: var(--muted); margin-top: 8px; }
.sl-mini b { color: var(--text); }
.sl-mini b.hot { color: #1d7442; }
.sl-countries { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 10px; }
.sl-empty { padding: 22px; color: var(--muted); }
.sl-new { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.sl-new input[type=text] { width: 260px; }
.sl-head { display: flex; gap: 16px; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; }
.sl-head h2 { margin: 2px 0 4px; font-size: 22px; }
.sl-stats { display: flex; gap: 22px; flex-wrap: wrap; margin-top: 12px; }
.sl-stats div { font-size: 12.5px; color: var(--muted); }
.sl-stats b { display: block; font-size: 20px; color: var(--text); }
.sl-tools { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.sl-tools .chip.on { background: var(--dark); color: #fff; }
.sl-added { font-size: 12px; color: var(--muted); }

/* opening flags */
.oflag { display: inline-block; font-size: 12px; font-weight: 800; padding: 3px 9px; border-radius: 999px; margin-bottom: 4px; background: var(--panel-2); color: var(--muted); }
.oflag a { color: inherit; text-decoration: underline; }
.of-open { background: var(--mint); color: var(--mint-ink); }
.of-likely { background: var(--amber); color: var(--amber-ink); }
.of-checking { background: var(--sky); color: var(--sky-ink); }
.of-error { background: var(--rose); color: var(--rose-ink); }
.opening-card { margin-bottom: 16px; }
.of-bg-open { background: #eaf8d2; }
.of-bg-likely { background: #fff7dc; }


/* =====================================================================================================
   Theme: editorial red (flat white cards on warm grey, pill controls, large light headings)
   Later rules override the earlier component styles above.
   ===================================================================================================== */
html, body { background: var(--page); }
body { letter-spacing: -.005em; }
a:hover { color: var(--red); }
.link { color: var(--red); font-weight: 600; }
.strong { font-weight: 600; }

/* frame & sidebar */
.frame { max-width: 1520px; margin: 20px auto; background: var(--bg); border-radius: 40px; box-shadow: none; min-height: calc(100vh - 40px); }
.side { background: transparent; padding: 28px 18px 24px 22px; width: 250px; }
.logo { font-weight: 600; font-size: 19px; margin: 0 8px 26px; letter-spacing: -.02em; }
.logo .mark { width: 40px; height: 40px; border-radius: 50%; background: var(--dark); color: #fff; font-size: 16px; }
.logo small { display: block; font-size: 13px; font-weight: 400; color: var(--muted); letter-spacing: 0; margin-top: -2px; }
.nav-group { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: #b0b0b0; margin: 18px 12px 6px; }
.nav a { padding: 9px 12px; border-radius: 16px; font-weight: 500; margin-bottom: 2px; align-items: flex-start; }
.nav a svg { margin-top: 2px; }
.nav a .nl { display: block; line-height: 1.25; }
.nav a .nd { display: block; font-size: 11.5px; font-weight: 400; color: var(--muted); line-height: 1.3; margin-top: 1px; }
.nav a:hover { background: #fff; }
.nav a.active { background: var(--dark); color: #fff; font-weight: 500; }
.nav a.active .nd { color: rgba(255, 255, 255, .62); }
.side-accounts { background: #fff; border-radius: 22px; padding: 14px 12px; margin-top: 18px; }
.side-label { color: #b0b0b0; }

/* main & topbar */
.main { padding: 30px 34px 56px 10px; }
.topbar { align-items: center; margin-bottom: 22px; }
.topbar h1 { font-size: 34px; font-weight: 500; letter-spacing: -.03em; line-height: 1.15; }
.topbar .date { font-size: 15px; color: var(--muted); margin-top: 4px; }
.topbar .crumb { font-size: 13px; }
.icon-btn { width: 44px; height: 44px; border-radius: 50%; border: 1px solid #e3e3e3; background: #fff; }
.icon-btn .dot { background: var(--red); top: 11px; right: 12px; }
.me { background: #fff; border-radius: 999px; padding: 5px 16px 5px 5px; border: 1px solid #eee; }
.me .name { font-weight: 600; }

/* cards */
.card { border-radius: var(--radius); padding: 22px 24px; box-shadow: none; border: 0; }
.card h2, .card-title { font-size: 17px; font-weight: 500; letter-spacing: -.01em; }
.card .hint { font-size: 12.5px; }
.promo { background: var(--dark); border-radius: var(--radius); }
.promo h3 { font-weight: 500; }
.promo .big { font-weight: 600; }
.promo::after { border-color: rgba(229, 56, 59, .35); }
.promo .btn.primary { background: var(--red); border-color: var(--red); color: #fff; }

/* stat tiles: white, big number with a red accent */
.stat { background: #fff !important; border-radius: var(--radius); text-align: left; padding: 20px 22px; color: var(--text); }
.stat .lbl { font-weight: 500; color: var(--text); }
.stat .lbl i { width: 30px; height: 30px; border: 1px solid #e6e6e6; background: #fff; }
.stat .val { font-size: 32px; font-weight: 600; letter-spacing: -.03em; margin: 14px 0 2px; }
.stat .val::first-letter { color: inherit; }
.stat .cap { opacity: 1; color: var(--muted); }
.stat.lime { background: var(--red) !important; color: #fff; }
.stat.lime .lbl, .stat.lime .cap { color: rgba(255, 255, 255, .85); }
.stat.lime .lbl i { background: rgba(255, 255, 255, .15); border-color: rgba(255, 255, 255, .3); }

/* buttons: pills */
.btn { border-radius: 999px; padding: 10px 18px; font-weight: 500; border: 1px solid #e3e3e3; background: #fff; }
.btn:hover { background: #f7f7f7; border-color: #d9d9d9; }
.btn.small { padding: 7px 14px; border-radius: 999px; font-size: 12.5px; }
.btn.primary { background: var(--red); border-color: var(--red); color: #fff; }
.btn.primary:hover { background: var(--red-dark); border-color: var(--red-dark); color: #fff; }
.btn.dark { background: var(--dark); border-color: var(--dark); }
.btn.danger { color: var(--red-dark); }
.btn.ghost { color: #fff; border-color: rgba(255, 255, 255, .35); background: transparent; }
.btn .arrow { margin-left: 4px; }

/* inputs */
input[type=text], input[type=email], input[type=password], input[type=number], input[type=datetime-local], input[type=file], input[type=search], select, textarea {
  background: #f4f4f4; border: 1px solid transparent; border-radius: 14px; padding: 11px 14px; font: inherit; color: var(--text); width: 100%; }
input:focus, select:focus, textarea:focus { border-color: var(--red); background: #fff; box-shadow: 0 0 0 4px rgba(229, 56, 59, .12); }
.search input { background: #fff; border: 1px solid #e6e6e6; border-radius: 999px; }
label { font-weight: 500; }
input[type=checkbox] { accent-color: var(--red); width: 16px; height: 16px; }

/* chips, badges, tags */
.chip { border-radius: 999px; padding: 6px 14px; font-weight: 500; border: 1px solid #e6e6e6; background: #fff; }
.chip.on { background: var(--dark); border-color: var(--dark); }
.badge { font-weight: 600; padding: 4px 11px; }
.s-replied { background: var(--red); color: #fff; }
.tag { background: #f3f3f3; color: #555; font-weight: 500; }

/* banners */
.banner { border-radius: 18px; padding: 13px 18px; }
.banner.ok { background: #e8f5ec; color: #1d7442; }
.banner.info { background: #f1f1f1; color: #333; }
.banner.dry { background: #fff2e3; color: #9a5410; }
.banner.error { background: var(--red-soft); color: var(--red-dark); }

/* tables & lists */
th { font-weight: 500; }
tbody tr:hover td, table tr:hover td { background: #fafafa; }
.list-row { border-radius: 18px; border-color: #eee; }
.preview { border-radius: 18px; }

/* top-bar AI switch */
.ai-toggle { border-radius: 999px; padding: 8px 10px 8px 14px; background: #fff; border: 1px solid #e3e3e3; color: var(--text); font-weight: 500; }
.ai-toggle.on { color: var(--text); border-color: #e3e3e3; background: #fff; }
.ai-toggle.on .knob { background: var(--red); }

/* chart, rings, funnel (dashboard) */
.chart .bar { border-radius: 8px 8px 3px 3px; }
.ring-stat { display: flex; align-items: center; gap: 16px; }
.donut { width: 112px; height: 112px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0;
         background: conic-gradient(var(--red) calc(var(--p) * 1%), #2b2b2b 0); }
.donut::before { content: ""; grid-area: 1 / 1; width: 84px; height: 84px; border-radius: 50%; background: var(--dark); }
.donut span { grid-area: 1 / 1; z-index: 1; color: #fff; font-size: 20px; font-weight: 600; text-align: center; line-height: 1.1; }
.donut span small { display: block; font-size: 10px; font-weight: 400; color: rgba(255, 255, 255, .7); }
.funnel { position: relative; height: 270px; display: grid; place-items: end center; }
.funnel .c { position: absolute; left: 50%; bottom: 0; transform: translateX(-50%); border-radius: 50%; display: flex;
             flex-direction: column; align-items: center; justify-content: flex-start; padding-top: 14px; font-weight: 600; font-size: 15px; }
.funnel .c small { font-size: 11px; font-weight: 400; color: rgba(0, 0, 0, .55); }
.funnel .c1 { width: 270px; height: 270px; background: radial-gradient(circle at 50% 70%, #fff3f3, #fde4e4); }
.funnel .c2 { width: 200px; height: 200px; background: radial-gradient(circle at 50% 70%, #fde0e0, #f9c2c3); }
.funnel .c3 { width: 136px; height: 136px; background: radial-gradient(circle at 50% 70%, #f6a5a7, #ef7d80); }
.funnel .c4 { width: 78px; height: 78px; background: radial-gradient(circle at 50% 40%, #ef5457, #d92c30); color: #fff; justify-content: center; padding: 0; }
.funnel .c4 small { color: rgba(255, 255, 255, .8); }
.date-pill { display: flex; align-items: center; gap: 12px; }
.date-circle { width: 64px; height: 64px; border-radius: 50%; border: 1px solid #e0e0e0; background: #fff; display: grid; place-items: center;
               font-size: 22px; font-weight: 500; }
.date-pill .dl { font-size: 13px; line-height: 1.25; }
.greet-sub { font-size: 34px; font-weight: 300; color: #b3b3b3; letter-spacing: -.03em; line-height: 1.15; }

/* "How this page works" */
.howto { background: #fff; border-radius: var(--radius); padding: 18px 22px; margin-bottom: 18px; display: grid;
         grid-template-columns: auto minmax(0, 1fr) auto; gap: 18px; align-items: start; }
.howto .hi { width: 40px; height: 40px; border-radius: 50%; background: var(--red-soft); color: var(--red); display: grid; place-items: center; font-weight: 700; }
.howto h3 { margin: 0 0 6px; font-size: 15px; font-weight: 600; }
.howto ol { margin: 0; padding-left: 18px; color: #444; font-size: 13px; line-height: 1.6; }
.howto .x { border: 0; background: transparent; color: var(--muted); cursor: pointer; font-size: 18px; }
.howto-reopen { border: 0; background: transparent; color: var(--muted); cursor: pointer; font-size: 12.5px; text-decoration: underline; padding: 0; }
.steps-start { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 1100px) { .steps-start { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.step { display: block; background: #fff; border-radius: 22px; padding: 16px 18px; color: var(--text); border: 1px solid transparent; }
.step:hover { border-color: #e6e6e6; color: var(--text); }
.step .sn { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 600; font-size: 13px;
            background: #f1f1f1; margin-bottom: 10px; }
.step.done .sn { background: var(--red); color: #fff; }
.step .st { font-weight: 600; font-size: 14px; }
.step .sd { color: var(--muted); font-size: 12.5px; margin-top: 2px; }

/* replace the old lime tints */
.ai-search { background: #fff; border: 1px solid #f1d4d4; }
.ai-search input[type=text] { background: #f7f7f7; border-radius: 999px; }
.ai-icon { color: var(--red); }
.ai-reason { color: var(--red-dark); background: var(--red-soft); border-radius: 12px; }
.hook { background: var(--red-soft); border: 1px dashed var(--red-tint); }
.rewrite-box { background: #fafafa; border: 1px dashed #dcdcdc; border-radius: 18px; }
.opp { background: #fafafa; border-radius: 18px; }
.opp.opp-no { background: var(--red-soft); }
.folder-head { background: #fff; }
.of-bg-open { background: #eaf6ee; }
.of-bg-likely { background: #fff6ea; }
.act-tile { background: #fff !important; border: 1px solid transparent; border-radius: 22px; }
.act-tile .n { font-weight: 600; }
.act-tile.on { border-color: var(--dark); }
.act-tile.act-reply_needed .n, .act-tile.act-email_now .n { color: var(--red); }
.act-reply_needed, .act-email_now { background: var(--red); color: #fff; }
.act-follow_up_now, .act-email_this_week { background: var(--dark); color: #fff; }
.act-wait_for_reply { background: #f1f1f1; color: #333; }
.ring { font-weight: 600; }
.ring-high { background: var(--red); color: #fff; }
.ring-high small { color: rgba(255, 255, 255, .8); }
.ring-medium { background: var(--dark); color: #fff; }
.ring-medium small { color: rgba(255, 255, 255, .7); }
.ring-low { background: #f1f1f1; color: #333; }
.ring-fit { background: #fff; border: 2px solid var(--red-tint); color: var(--text); }
.meter div { background: var(--red); }
.sig.on { background: #e8f5ec; color: #1d7442; }
.progress div { background: var(--red) !important; }
.l-drafted { background: var(--red); color: #fff; }
.of-open { background: #e8f5ec; color: #1d7442; }
.steps-num li::before { background: var(--red); color: #fff; }
.tag.v-ready { background: #e8f5ec; color: #1d7442; }
.harvest-card { background: #fff; }

/* Find professors: roomier, calmer rows */
.prof-layout { grid-template-columns: 280px minmax(0, 1fr); gap: 18px; }
.prof-filters { position: sticky; top: 16px; }
.prof-filters .fgroup { border-top: 1px solid #f0f0f0; padding-top: 10px; margin-top: 10px; }
.prof-filters .fgroup:first-child { border-top: 0; padding-top: 0; margin-top: 0; }
.prof-row { grid-template-columns: 22px minmax(0, 1fr) 170px 190px; gap: 18px; padding: 16px 12px; border-radius: 18px; border-bottom: 0; margin-bottom: 4px; }
.prof-row:hover { background: #f7f7f7; }
.prof-main .strong { font-size: 15px; font-weight: 600; }
.dom-chips .tag { font-size: 11.5px; background: #f4f4f4; }
.oflag { white-space: nowrap; font-weight: 600; border-radius: 999px; padding: 5px 12px; }
.prof-ev { text-align: left; }
.bulkbar { background: #fff !important; border-radius: 999px; padding: 8px 10px 8px 16px !important; border: 1px solid #eee; margin-bottom: 8px; top: 8px; }
.sel-hint { color: var(--muted); font-size: 12.5px; }
.dash-trio { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr); }
@media (max-width: 1300px) { .dash-trio { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }

/* funnel scales with its card */
.funnel { height: auto; aspect-ratio: 1; max-width: 270px; margin: 0 auto; width: 100%; }
.funnel .c { aspect-ratio: 1; height: auto !important; }
.funnel .c1 { width: 100%; }
.funnel .c2 { width: 74%; }
.funnel .c3 { width: 50%; }
.funnel .c4 { width: 29%; }
.prio-list .act { font-size: 11px; padding: 3px 9px; }
.bulkbar { border-radius: 22px !important; }
.search input, .search input[type=search] { padding-left: 38px !important; }
.search svg { left: 14px; z-index: 1; }


/* ---------- readability pass: larger text, stronger contrast (WCAG AA), calmer headings ---------- */
:root { --muted: #5f5f5f; --text: #111111; }
body { font-size: 15px; line-height: 1.6; letter-spacing: 0; }
.small, .card .hint, .filter-note, .sel-hint { font-size: 13px; }
.muted { color: var(--muted); }
.topbar h1 { font-size: 30px; font-weight: 600; letter-spacing: -.02em; }
.topbar .date { font-size: 14.5px; color: var(--muted); }
.card h2, .card-title { font-size: 18px; font-weight: 600; }
label { font-size: 13px; color: #444; }
label.check { font-size: 14.5px; }
.nav a { font-size: 15px; }
.nav a .nd { font-size: 12.5px; color: #6a6a6a; }
.nav a.active .nd { color: rgba(255, 255, 255, .78); }
.nav-group { font-size: 12px; color: #8a8a8a; }
th { font-size: 13px; color: #555; }
td { font-size: 14.5px; }
.badge, .tag, .oflag, .act { font-size: 12.5px; }
.chip { font-size: 13.5px; }
.btn { font-size: 14px; }
.btn.small { font-size: 13px; }
.list-row .t { font-size: 14.5px; }
.list-row .s { font-size: 13px; color: var(--muted); }
.stat .lbl { font-size: 14.5px; }
.stat .cap { font-size: 13px; }
.stat .val { font-size: 34px; }
.banner { font-size: 14.5px; }
.howto ol { font-size: 14px; color: #333; }
.howto h3 { font-size: 16px; }
.prof-main .strong { font-size: 16px; }
.dom-chips .tag { font-size: 12.5px; color: #444; }
.kv { font-size: 14.5px; }
.preview { font-size: 15px; line-height: 1.65; }
.reply-text, .lead-text { font-size: 14.5px; }
.ev-sec h3 { font-size: 15px; }
.ev-item { font-size: 14px; }
.act-tile .l { font-size: 14px; }
.act-tile .d { font-size: 12.5px; color: #555; }
.step .sd { font-size: 13px; color: #555; }
.side-acc .s, .side-label { font-size: 12px; }
.mono { font-size: 13px; }
.greet-sub { font-size: 30px; font-weight: 400; color: #6a6a6a; }
input, select, textarea { font-size: 14.5px !important; }
textarea { font-size: 14px !important; }

.funnel { max-width: 210px; }
.funnel-legend { margin-top: 16px; display: grid; gap: 8px; font-size: 14px; }
.funnel-legend div { display: flex; align-items: center; gap: 10px; }
.funnel-legend strong { margin-left: auto; font-weight: 600; }
.fd { width: 12px; height: 12px; border-radius: 50%; flex-shrink: 0; }
.fd1 { background: #fde4e4; border: 1px solid #f6c9ca; } .fd2 { background: #f9c2c3; } .fd3 { background: #ef7d80; } .fd4 { background: var(--red); }

/* brand: logo lockup (brand/ holds the master SVGs and guideline) */
.logo { display: flex; align-items: center; margin: 2px 8px 28px; color: var(--text); }
.logo-lockup { display: inline-flex; align-items: center; gap: 10px; }
.brand-mark { width: 38px; height: 38px; flex-shrink: 0; color: var(--red); display: block; }
.wordmark { font-family: Inter, system-ui, sans-serif; font-weight: 700; font-size: 19px; letter-spacing: -.035em; line-height: .98; color: var(--text); text-align: left; }
.logo:hover .brand-mark { color: var(--red-dark); }
.logo-lockup.mono .brand-mark, .logo-lockup.mono .wordmark { color: currentColor; }
@media (max-width: 860px) {
  .logo { margin: 0 12px 0 0; }
  .brand-mark { width: 30px; height: 30px; }
  .wordmark { font-size: 16px; }
}

/* "Running now" panel (app.js renders it from GET /jobs) */
.jobs-panel { background: var(--panel); border-radius: var(--radius); padding: 16px 20px; margin-bottom: 18px; }
.jobs-head { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.jobs-head .small { margin-left: auto; }
.pulse { width: 9px; height: 9px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 0 rgba(229, 56, 59, .5); animation: pulse 1.8s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 8px rgba(229, 56, 59, 0); } 100% { box-shadow: 0 0 0 0 rgba(229, 56, 59, 0); } }
.job { padding: 12px 0; border-top: 1px solid var(--line); }
.job:first-child { border-top: 0; }
.job-top { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; margin-bottom: 7px; }
.job-title { font-weight: 600; font-size: 15px; }
.job-title a:hover { color: var(--red); }
.job-pct { font-weight: 600; font-variant-numeric: tabular-nums; }
.job-foot { display: flex; justify-content: space-between; gap: 12px; align-items: center; margin-top: 6px; font-size: 13.5px; color: var(--muted); }
.job-btns { display: flex; gap: 6px; flex-shrink: 0; }
.job-btns form { margin: 0; }
.job-waiting .progress div, .job-stopped .progress div { background: #c9c9c9 !important; }
.job-finished .progress div { background: #2e9d5b !important; }
.job-finished .job-pct { color: #1d7442; }
@media (max-width: 860px) { .jobs-head .small { display: none; } .job-foot { flex-direction: column; align-items: flex-start; } }
.btn.job-x { padding-inline: 10px; }

/* Find professors: choose a field first, then it stays locked */
.field-choose h2 { margin-bottom: 4px; }
.field-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 16px; }
.field-tile { display: flex; flex-direction: column; gap: 8px; padding: 22px; border-radius: 22px; background: var(--bg); border: 2px solid transparent; transition: border-color .15s, transform .15s; }
.field-tile:hover { border-color: var(--red); transform: translateY(-2px); }
.ft-icon { width: 46px; height: 46px; border-radius: 50%; background: var(--red-soft); color: var(--red); display: grid; place-items: center; }
.ft-icon svg { width: 24px; height: 24px; }
.ft-name { font-size: 21px; font-weight: 700; letter-spacing: -.02em; }
.ft-count { font-weight: 600; color: var(--red-dark); }
.ft-doms { font-size: 14px; color: var(--muted); }
.ft-who { font-size: 14px; display: flex; gap: 6px; align-items: flex-start; }
.ft-who svg, .field-who svg { width: 16px; height: 16px; flex-shrink: 0; margin-top: 2px; }
.field-tile .btn { align-self: flex-start; margin-top: 6px; }
.field-bar { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.field-switch { display: inline-flex; background: var(--panel); border-radius: 99px; padding: 5px; gap: 4px; }
.field-switch a { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: 99px; font-weight: 600; color: var(--muted); }
.field-switch a svg { width: 16px; height: 16px; }
.field-switch a:hover { color: var(--text); background: var(--bg); }
.field-switch a.on { background: var(--red); color: #fff; }
.field-switch .fs-n { font-weight: 500; font-size: 13px; opacity: .8; }
.field-who { display: flex; align-items: center; gap: 6px; font-size: 14.5px; color: #555; }
.ffield { display: flex; align-items: center; gap: 8px; background: var(--red-soft); color: var(--red-dark); border-radius: 14px; padding: 9px 12px; font-size: 14px; margin-bottom: 6px; }
.ffield svg { width: 15px; height: 15px; }

/* filters you have set are red, so it's clear what's applied */
.fhead { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.fcount { background: var(--red); color: #fff; border-radius: 99px; font-size: 11.5px; font-weight: 600; padding: 2px 9px; }
.prof-filters select.f-on, .prof-filters .search.f-on input { background: var(--red-soft) !important; border: 1.5px solid var(--red) !important; color: var(--red-dark); font-weight: 600; }
.prof-filters label.l-on { color: var(--red-dark); font-weight: 600; }
.prof-filters label.check.f-on { background: var(--red-soft); color: var(--red-dark); font-weight: 600; border-radius: 10px; padding: 4px 8px; margin-left: -8px; }
.prof-filters label.check input { accent-color: var(--red); }
.dom-checks { display: grid; gap: 2px; }
.active-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 14px; }
.af-label { font-size: 13.5px; font-weight: 600; color: #555; }
.fchip { display: inline-flex; align-items: center; gap: 8px; background: var(--red-soft); color: var(--red-dark); border: 1px solid #f6c9ca; border-radius: 99px; padding: 6px 8px 6px 14px; font-size: 13.5px; font-weight: 600; }
.fchip span { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; background: #fff; font-size: 11px; }
.fchip:hover { border-color: var(--red); }
.fchip:hover span { background: var(--red); color: #fff; }
.fchip.sort { background: var(--panel); color: #444; border-color: var(--line); }
.af-clear { font-size: 13.5px; color: var(--muted); text-decoration: underline; margin-left: 4px; }
.af-clear:hover { color: var(--red); }
.tag.tag-on { background: var(--red-soft); color: var(--red-dark); }
@media (max-width: 860px) { .field-tiles { grid-template-columns: 1fr; } .field-switch a { padding: 8px 12px; } }

/* Candidates: two people side by side, plus the switch in the top bar */
.cand-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-items: start; }
.cand { border: 2px solid transparent; }
.cand.cand-on { border-color: var(--red); }
.cand-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.cand-head svg { width: 14px; height: 14px; vertical-align: -2px; }
.cand-av { width: 52px; height: 52px; border-radius: 50%; background: var(--red-soft); color: var(--red-dark); display: grid; place-items: center; font-size: 22px; font-weight: 700; flex-shrink: 0; }
.cand-on .cand-av { background: var(--red); color: #fff; }
.cand-name { font-size: 20px; font-weight: 700; letter-spacing: -.02em; }
.cand-stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin-bottom: 14px; }
.cand-stats a { background: var(--bg); border-radius: 16px; padding: 10px 8px; text-align: center; display: flex; flex-direction: column; gap: 2px; }
.cand-stats a:hover { background: var(--red-soft); }
.cand-stats b { font-size: 20px; font-weight: 700; font-variant-numeric: tabular-nums; }
.cand-stats b.hot { color: var(--red); }
.cand-stats span { font-size: 12px; color: var(--muted); }
.cand-profile { min-height: 300px !important; font-size: 14px; line-height: 1.5; }
.cand-switch { display: inline-flex; background: var(--panel); border-radius: 99px; padding: 4px; gap: 2px; }
.cand-switch a { display: inline-flex; align-items: center; gap: 7px; padding: 5px 12px 5px 5px; border-radius: 99px; font-weight: 600; font-size: 14px; color: var(--muted); }
.cand-switch a:hover { color: var(--text); }
.cand-switch a.on { background: var(--dark); color: #fff; }
.cs-av { width: 28px; height: 28px; border-radius: 50%; background: var(--red-soft); color: var(--red-dark); display: grid; place-items: center; font-size: 13px; font-weight: 700; }
.cand-switch a.on .cs-av { background: var(--red); color: #fff; }
@media (max-width: 1100px) { .cand-grid { grid-template-columns: 1fr; } }
@media (max-width: 860px) { .cand-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); } .cs-n { display: none; } .cand-switch a { padding: 4px; } }

/* login: pick who you are, then the password */
.login-card { max-width: 420px; margin: 80px auto; text-align: center; padding: 30px; }
.login-form { text-align: left; }
.login-who { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 16px 0 18px; }
.login-user { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 16px 10px; border: 1.5px solid #e4e4e4;
  border-radius: 16px; cursor: pointer; margin: 0; font-weight: 600; transition: border-color .15s, background .15s; }
.login-user:hover { border-color: #bbb; }
.login-user input { position: absolute; opacity: 0; pointer-events: none; }
.login-user:has(input:checked) { border-color: var(--dark); background: #fafafa; box-shadow: 0 0 0 1px var(--dark); }
.login-user:has(input:focus-visible) { outline: 2px solid #E5383B; outline-offset: 2px; }
.lu-av { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-size: 18px; font-weight: 700;
  background: #eceff5; color: #3b4a6b; }
.lu-av.lu-fatima { background: #e8f5ec; color: #1d7442; }
.lu-name { font-size: 14px; }

/* candidate profile form */
.prof-grid-2 { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 18px; align-items: start; }
.profile-form label { margin-top: 18px; }
.profile-form label:first-child { margin-top: 0; }
.pf-help { margin: -2px 0 6px; }
.pf-area { width: 100%; resize: vertical; min-height: 70px; }
.pf-save { margin-top: 20px; position: sticky; bottom: 0; background: #fff; padding: 12px 0 4px; }
.pf-side { display: flex; flex-direction: column; gap: 14px; position: sticky; top: 16px; }
@media (max-width: 1000px) { .prof-grid-2 { grid-template-columns: 1fr; } .pf-side { position: static; } }
