*{box-sizing:border-box}body{margin:0;font:15px/1.45 -apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif;background:#f4f5f7;color:#1d2330}
a{color:#2563eb;text-decoration:none}a:hover{text-decoration:underline}
.topbar{display:flex;align-items:center;justify-content:space-between;background:#0f172a;color:#fff;padding:10px 18px;position:sticky;top:0;z-index:10}
.topbar .logo{font-weight:700}.topbar .sub{opacity:.7;margin-left:8px;font-size:13px}
.topbar a{color:#cbd5e1}
.tabs{display:flex;gap:8px;padding:12px 18px 0}
.tab{padding:8px 16px;border-radius:8px 8px 0 0;background:#e5e7eb;font-weight:600;color:#374151}
.tab.active{background:#fff;color:#0f172a;box-shadow:0 -2px 0 #2563eb inset}
.wrap{padding:14px 18px 60px}
.stats{display:flex;gap:10px;flex-wrap:wrap;margin:10px 0 18px}
.stat{background:#fff;border:1px solid #e5e7eb;border-radius:10px;padding:10px 14px;min-width:96px}
.stat .n{font-size:22px;font-weight:700}.stat .l{font-size:12px;color:#6b7280}
.stat.hot .n{color:#dc2626}.stat.today .n{color:#2563eb}
h2.section{margin:18px 0 10px;font-size:16px}
.cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(330px,1fr));gap:12px}
.card{background:#fff;border:1px solid #e5e7eb;border-radius:12px;padding:14px;display:flex;flex-direction:column;gap:8px}
.card.hot{border-color:#fca5a5;box-shadow:0 0 0 1px #fee2e2}
.card .nm{font-weight:700}.card .hand{color:#6b7280;font-size:13px}
.badges{display:flex;gap:6px;flex-wrap:wrap}
.badge{font-size:11px;font-weight:700;padding:2px 8px;border-radius:999px}
.badge.hot{background:#fee2e2;color:#b91c1c}.badge.reply{background:#dcfce7;color:#15803d}.badge.today{background:#dbeafe;color:#1d4ed8}.badge.ghl{background:#ede9fe;color:#6d28d9}
.bio{font-size:13px;color:#374151;max-height:48px;overflow:hidden}
.row{display:flex;gap:6px;align-items:center;flex-wrap:wrap}
input[type=text],input[type=email],textarea,select{border:1px solid #d1d5db;border-radius:8px;padding:7px 9px;font:inherit;width:100%}
textarea{min-height:42px;resize:vertical}
button,.btn{cursor:pointer;border:1px solid #d1d5db;background:#fff;border-radius:8px;padding:7px 11px;font:inherit;font-weight:600}
button:hover{background:#f3f4f6}
.btn-pri{background:#2563eb;color:#fff;border-color:#2563eb}.btn-pri:hover{background:#1d4ed8}
.btn-ghl{background:#7c3aed;color:#fff;border-color:#7c3aed}.btn-ghl:hover{background:#6d28d9}
.btn-ghl[disabled]{opacity:.5;cursor:not-allowed}
.btn-sm{padding:4px 9px;font-size:13px}
table{width:100%;border-collapse:collapse;background:#fff;border:1px solid #e5e7eb;border-radius:10px;overflow:hidden}
th,td{padding:8px 10px;text-align:left;border-bottom:1px solid #f0f0f0;font-size:14px}
th{background:#f9fafb;font-size:12px;text-transform:uppercase;color:#6b7280}
.filters{display:flex;gap:8px;flex-wrap:wrap;margin:8px 0;align-items:center}
.filters input,.filters select{width:auto}
.muted{color:#9ca3af}.ok{color:#16a34a;font-weight:700}
.login-body{display:grid;place-items:center;height:100vh;background:#0f172a}
.login-card{background:#fff;padding:28px;border-radius:14px;width:320px;display:flex;flex-direction:column;gap:12px}
.login-card h1{font-size:18px;margin:0 0 6px}.login-card label{font-size:13px;font-weight:600;display:flex;flex-direction:column;gap:4px}
.login-card button{background:#2563eb;color:#fff;border:0;padding:10px}.err{background:#fee2e2;color:#b91c1c;padding:8px;border-radius:8px;font-size:13px}
.flash{position:fixed;bottom:18px;left:50%;transform:translateX(-50%);background:#0f172a;color:#fff;padding:10px 16px;border-radius:10px;opacity:0;transition:.2s;pointer-events:none}
.flash.show{opacity:1}
#overlay{position:fixed;inset:0;background:rgba(15,23,42,.55);display:none;place-items:center;z-index:50}
#overlay.show{display:grid}
.modal{background:#fff;border-radius:14px;padding:20px;width:min(460px,92vw);max-height:88vh;overflow:auto;display:flex;flex-direction:column;gap:10px;position:relative}
.modal .x{position:absolute;top:10px;right:10px;border:0;background:#f3f4f6;border-radius:8px;width:30px;height:30px;cursor:pointer}
.modal .nm{font-weight:700;font-size:17px}
.tags-label{font-size:12px;font-weight:700;color:#6b7280;margin-top:2px}
.tagbox{display:flex;flex-wrap:wrap;gap:6px 12px}
.tagbox label{display:flex;align-items:center;gap:5px;font-size:13px;background:#f8fafc;border:1px solid #e5e7eb;border-radius:8px;padding:4px 8px;cursor:pointer}
.tagbox input{width:auto}
.pathline{font-size:13px;background:#eff6ff;border:1px solid #dbeafe;border-radius:8px;padding:5px 9px}
.pathline b{color:#1d4ed8}
.reply{font-size:13px;border-radius:8px;padding:6px 9px;background:#f8fafc;border:1px solid #e5e7eb}
.reply b{text-transform:capitalize}
.reply.r-positive{background:#dcfce7;border-color:#bbf7d0}
.reply.r-question{background:#dbeafe;border-color:#bfdbfe}
.reply.r-auto{background:#f3f4f6;color:#6b7280}
.reply.r-negative{background:#fee2e2;border-color:#fecaca}
.savef{margin-top:4px;background:#eef2ff;border-color:#c7d2fe;color:#3730a3}
.willsend{font-size:12px;margin-top:4px;color:#6b7280}
.chip{display:inline-block;padding:1px 6px;border-radius:6px;font-weight:600;font-size:11px;margin:1px}
.chip-no{background:#fee2e2;color:#b91c1c}
.chip-yes{background:#dcfce7;color:#166534}
.bio{max-height:none;overflow:visible;white-space:normal;word-break:break-word}
