:root{
  --navy:#1f3864; --navy-2:#16264a; --teal:#2f9e93; --teal-soft:#3bb0a4;
  --bg:#f6f7f9; --surface:#ffffff; --text:#1a2233; --muted:#697386;
  --border:#e4e7ec; --accent:#eef2f8; --danger:#c0392b;
  --sidebar-bg:#132743; --sidebar-fg:#c7d2e2; --sidebar-active:#22406b;
  --radius:10px; --shadow:0 1px 2px rgba(16,24,40,.06),0 1px 3px rgba(16,24,40,.08);
  --font:"Pretendard","Apple SD Gothic Neo","Malgun Gothic",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif;
}
[data-theme="dark"]{
  --navy:#4a6fa5; --teal:#3bb0a4; --bg:#0f1520; --surface:#161d2b; --text:#e6ebf3; --muted:#94a0b4;
  --border:#26303f; --accent:#1b2433; --sidebar-bg:#0c1119; --sidebar-fg:#aebbce; --sidebar-active:#1d2b44;
  --shadow:0 1px 3px rgba(0,0,0,.4);
}
*{box-sizing:border-box}
html,body{margin:0;padding:0}
body{font-family:var(--font);background:var(--bg);color:var(--text);font-size:14px;line-height:1.5;-webkit-font-smoothing:antialiased}
a{color:inherit;text-decoration:none}
button{font-family:inherit;cursor:pointer}
h1,h2,h3,h4{margin:0;letter-spacing:-.01em}
input,select,textarea{font-family:inherit;font-size:14px;width:100%;padding:9px 11px;border:1px solid var(--border);border-radius:8px;background:var(--surface);color:var(--text)}
input:focus,select:focus,textarea:focus{outline:none;border-color:var(--teal);box-shadow:0 0 0 3px rgba(47,158,147,.15)}
label{display:block;font-weight:600;font-size:12.5px;margin:0 0 5px;color:var(--muted)}
.btn{display:inline-flex;align-items:center;gap:6px;padding:9px 14px;border:1px solid var(--border);border-radius:8px;background:var(--surface);color:var(--text);font-weight:600;font-size:13px}
.btn:hover{background:var(--accent)}
.btn-primary{background:var(--navy);color:#fff;border-color:var(--navy)}
.btn-primary:hover{background:var(--navy-2)}
.btn-teal{background:var(--teal);color:#fff;border-color:var(--teal)}
.btn-sm{padding:5px 10px;font-size:12px}
.btn-danger{color:var(--danger);border-color:var(--danger)}
.btn-danger:hover{background:rgba(192,57,43,.08)}
.muted{color:var(--muted)}
.pill{display:inline-block;padding:2px 9px;border-radius:20px;font-size:11.5px;font-weight:600;background:var(--accent);color:var(--muted);white-space:nowrap}
.pill.teal{background:rgba(47,158,147,.14);color:var(--teal)}
.pill.warn{background:rgba(214,158,46,.16);color:#b9770e}
.pill.danger{background:rgba(192,57,43,.12);color:var(--danger)}
.pill.done{background:rgba(47,158,147,.14);color:var(--teal)}

/* ---------- 로그인 ---------- */
.auth{display:flex;min-height:100vh}
.auth-brand{flex:1;background:linear-gradient(150deg,#16264a 0%,#0e1b33 55%,#0a1428 100%);background-size:200% 200%;animation:authBg 20s ease-in-out infinite;color:#eaf0f8;position:relative;overflow:hidden;padding:52px 48px;display:flex;flex-direction:column;justify-content:space-between;word-break:keep-all}
@keyframes authBg{0%,100%{background-position:0% 0%}50%{background-position:100% 100%}}
.auth-canvas{position:absolute;inset:0;z-index:1}
.auth-brand .au-top{position:relative;z-index:2}
.auth-brand .au-eyebrow{font-size:12.5px;letter-spacing:.01em;color:#5ec8bd;font-weight:600;margin-bottom:18px;opacity:0;animation:authFadeUp .8s ease .1s forwards;word-break:keep-all}
.auth-brand .logo{display:flex;align-items:center;gap:13px;opacity:0;animation:authFadeUp .8s ease .25s forwards}
.auth-brand .logo .mark{width:48px;height:48px;border-radius:13px;background:#fff;display:flex;align-items:center;justify-content:center;box-shadow:0 6px 20px rgba(0,0,0,.28)}
.auth-brand h1{font-size:26px;letter-spacing:.06em;font-weight:800}
.auth-brand .sub{font-size:12.5px;color:#9fb2cf;letter-spacing:.01em}
.auth-brand .headline{position:relative;z-index:2;max-width:480px}
.au-rotator{min-height:92px;display:flex;flex-direction:column;justify-content:flex-end;gap:6px;margin-bottom:18px}
.au-rot-ko{font-size:28px;line-height:1.3;font-weight:800;background:linear-gradient(90deg,#eaf0f8,#a9e6de);-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent;transition:opacity .44s ease;word-break:keep-all}
.au-rot-en{font-size:13px;font-weight:600;color:#6fd3c7;letter-spacing:.01em;transition:opacity .44s ease}
.auth-brand .headline p{color:#a9b8d1;font-size:14px;line-height:1.78;opacity:0;animation:authFadeUp .8s ease .5s forwards;word-break:keep-all}
.auth-brand .headline p b{color:#7fe0d5;font-weight:600}
.auth-brand .tags{margin-top:22px;display:flex;flex-wrap:wrap;gap:8px;opacity:0;animation:authFadeUp .8s ease .7s forwards}
.auth-brand .tags span{border:1px solid rgba(126,224,213,.28);border-radius:20px;padding:5px 13px;font-size:12px;color:#bcccdf;background:rgba(126,224,213,.05)}
@keyframes authFadeUp{from{opacity:0;transform:translateY(14px)}to{opacity:1;transform:none}}
.au-glow{position:absolute;z-index:1;border-radius:50%;filter:blur(10px);pointer-events:none;background:radial-gradient(circle,rgba(59,176,164,.42),rgba(59,176,164,0) 68%);animation:authGlow 10s ease-in-out infinite}
.au-glow1{width:340px;height:340px;left:-40px;top:40px}
.au-glow2{width:420px;height:420px;right:-80px;bottom:-40px;animation-delay:-5s}
@keyframes authGlow{0%,100%{opacity:.35;transform:scale(1)}50%{opacity:.7;transform:scale(1.16)}}
@media(prefers-reduced-motion:reduce){.auth-brand,.au-glow,.au-eyebrow,.logo,.headline p,.tags{animation:none!important;opacity:1!important}}
.auth-form-wrap{flex:0 0 440px;display:flex;align-items:center;justify-content:center;padding:32px;background:var(--surface)}
.auth-form{width:100%;max-width:340px}
.auth-form h3{font-size:20px;margin-bottom:4px}
.auth-tabs{display:flex;background:var(--accent);border-radius:9px;padding:4px;margin:18px 0}
.auth-tabs button{flex:1;border:none;background:none;padding:8px;border-radius:6px;font-weight:600;color:var(--muted)}
.auth-tabs button.active{background:var(--surface);color:var(--text);box-shadow:var(--shadow)}
.field{margin-bottom:13px}
.auth-error{background:rgba(192,57,43,.1);color:var(--danger);padding:9px 11px;border-radius:8px;font-size:12.5px;margin-bottom:12px}
.auth-note{font-size:11.5px;color:var(--muted);margin-top:14px;text-align:center;line-height:1.6}
@media(max-width:820px){.auth{flex-direction:column}.auth-brand{min-height:320px;padding:32px}.auth-form-wrap{flex:1}.au-rot-ko{font-size:22px}.au-rotator{min-height:72px}.auth-brand .headline p{font-size:13px}}
/* 인턴 카드 */
.intern-card{transition:transform .12s ease,box-shadow .12s ease}
.intern-card:hover{transform:translateY(-2px);box-shadow:0 4px 14px rgba(16,24,40,.1)}

/* ---------- 레이아웃 ---------- */
.shell{display:flex;min-height:100vh}
.sidebar{width:230px;background:var(--sidebar-bg);color:var(--sidebar-fg);flex-shrink:0;display:flex;flex-direction:column;position:sticky;top:0;height:100vh}
.sidebar .brand{padding:18px 18px 14px;display:flex;align-items:center;gap:10px;border-bottom:1px solid rgba(255,255,255,.07)}
.sidebar .brand .mark{width:32px;height:32px;border-radius:8px;background:var(--teal);display:flex;align-items:center;justify-content:center;flex-shrink:0}
.sidebar .brand b{font-size:14.5px;color:#fff;display:block}
.sidebar .brand small{font-size:10.5px;color:#8ba0bf}
.nav{flex:1;overflow-y:auto;padding:10px 10px 20px}
.nav .sec{font-size:10.5px;text-transform:uppercase;letter-spacing:.05em;color:#6f83a3;padding:14px 10px 6px}
.nav a{display:flex;align-items:center;gap:10px;padding:8px 11px;border-radius:8px;font-size:13.5px;color:var(--sidebar-fg);margin-bottom:2px}
.nav a:hover{background:rgba(255,255,255,.06)}
.nav a.active{background:var(--sidebar-active);color:#fff}
.nav a .ic{width:18px;text-align:center;opacity:.85}
.nav a .soon{margin-left:auto;font-size:9.5px;background:rgba(255,255,255,.1);padding:1px 6px;border-radius:10px;color:#9fb2cf}
.main{flex:1;min-width:0;display:flex;flex-direction:column}
.topbar{height:58px;background:var(--surface);border-bottom:1px solid var(--border);display:flex;align-items:center;gap:12px;padding:0 20px;position:sticky;top:0;z-index:20}
.topbar .search{flex:1;max-width:440px;position:relative}
.topbar .search input{padding-left:34px}
.topbar .search .ic{position:absolute;left:11px;top:9px;opacity:.5}
.topbar .sp{flex:1}
.icon-btn{width:36px;height:36px;border-radius:8px;border:1px solid var(--border);background:var(--surface);display:flex;align-items:center;justify-content:center}
.icon-btn:hover{background:var(--accent)}
.avatar{width:34px;height:34px;border-radius:50%;background:var(--navy);color:#fff;display:flex;align-items:center;justify-content:center;font-weight:700;font-size:13px}
.content{padding:24px;max-width:1180px;width:100%;margin:0 auto}
.welcome{margin-bottom:20px}
.welcome h2{font-size:27px;font-weight:700;letter-spacing:-.02em}
.welcome p{margin:6px 0 0;color:var(--muted);font-size:14.5px}
.viewtoggle{display:inline-flex;background:var(--accent);border-radius:8px;padding:3px}
.viewtoggle button{border:none;background:none;padding:6px 12px;border-radius:6px;font-weight:600;font-size:12.5px;color:var(--muted)}
.viewtoggle button.active{background:var(--surface);color:var(--text);box-shadow:var(--shadow)}
.chips{display:flex;gap:8px;margin-bottom:14px;flex-wrap:wrap}
.chip{border:1px solid var(--border);background:var(--surface);border-radius:20px;padding:5px 14px;font-size:12.5px;font-weight:600;color:var(--muted)}
.chip.active{background:var(--navy);color:#fff;border-color:var(--navy)}
img.av{width:44px;height:44px;border-radius:50%}
img.avatar{width:34px;height:34px;border-radius:50%}
.section-head{font-size:12px;font-weight:700;letter-spacing:.03em;color:var(--muted);text-transform:uppercase;margin:6px 0 12px;padding-bottom:7px;border-bottom:1px solid var(--border)}
.nav a .ic svg{display:block}
.page-head{display:flex;align-items:flex-end;justify-content:space-between;margin-bottom:20px;gap:12px;flex-wrap:wrap}
.page-head h2{font-size:21px}
.page-head .crumb{font-size:12px;color:var(--muted);margin-bottom:4px}
.hamburger{display:none}
@media(max-width:900px){
  .sidebar{position:fixed;left:-240px;z-index:50;transition:left .2s;box-shadow:0 0 40px rgba(0,0,0,.3)}
  .sidebar.open{left:0}
  .hamburger{display:flex}
  .backdrop{display:none;position:fixed;inset:0;background:rgba(0,0,0,.4);z-index:40}
  .backdrop.show{display:block}
}

/* ---------- 카드/그리드 ---------- */
.card{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);box-shadow:var(--shadow)}
.card-p{padding:16px}
.grid{display:grid;gap:14px}
.stat-row{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:12px;margin-bottom:20px}
.stat{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);padding:15px 16px;box-shadow:var(--shadow)}
.stat .n{font-size:26px;font-weight:700}
.stat .l{font-size:12px;color:var(--muted);margin-top:2px}
.stat .l.danger{color:var(--danger)}
.two-col{display:grid;grid-template-columns:1.6fr 1fr;gap:16px}
@media(max-width:860px){.two-col{grid-template-columns:1fr}}
.section-title{font-size:14px;font-weight:700;margin-bottom:10px;display:flex;align-items:center;justify-content:space-between}

.proj-grid{grid-template-columns:repeat(auto-fill,minmax(280px,1fr))}
.proj-card{padding:16px;cursor:pointer;transition:border-color .15s}
.proj-card:hover{border-color:var(--teal)}
.proj-card h4{font-size:15px;margin-bottom:6px}
.proj-card .cat{font-size:12px;color:var(--teal);font-weight:600;margin-bottom:8px}
.bar{height:7px;background:var(--accent);border-radius:6px;overflow:hidden;margin:10px 0 4px}
.bar > i{display:block;height:100%;background:var(--teal);border-radius:6px}
.proj-meta{display:flex;justify-content:space-between;font-size:11.5px;color:var(--muted);margin-top:8px}

table{width:100%;border-collapse:collapse;font-size:13px}
th,td{text-align:left;padding:10px 12px;border-bottom:1px solid var(--border)}
th{font-size:11.5px;text-transform:uppercase;letter-spacing:.03em;color:var(--muted);background:var(--accent)}
tr:hover td{background:var(--accent)}
.table-wrap{overflow-x:auto;border:1px solid var(--border);border-radius:var(--radius);background:var(--surface)}

.member-grid{grid-template-columns:repeat(auto-fill,minmax(230px,1fr))}
.member-card{padding:16px;display:flex;gap:12px;align-items:center}
.member-card .av{width:44px;height:44px;border-radius:50%;background:var(--navy);color:#fff;display:flex;align-items:center;justify-content:center;font-weight:700}

.empty{text-align:center;padding:50px 20px;color:var(--muted)}
.empty .big{font-size:40px;margin-bottom:10px;opacity:.5}
.coming{text-align:center;padding:60px 20px}
.coming .badge{display:inline-block;background:rgba(47,158,147,.14);color:var(--teal);padding:5px 14px;border-radius:20px;font-weight:700;font-size:12px;margin-bottom:14px}
.coming h3{font-size:19px;margin-bottom:8px}

/* modal / sheet */
.overlay{position:fixed;inset:0;background:rgba(15,20,32,.5);z-index:100;display:flex;justify-content:flex-end}
.overlay.center{align-items:center;justify-content:center}
.sheet{width:640px;max-width:94vw;background:var(--surface);height:100%;overflow-y:auto;box-shadow:-8px 0 30px rgba(0,0,0,.2);animation:slide .2s}
.modal{width:520px;max-width:94vw;background:var(--surface);border-radius:12px;max-height:90vh;overflow-y:auto;animation:pop .15s}
@keyframes slide{from{transform:translateX(30px);opacity:.6}to{transform:none;opacity:1}}
@keyframes pop{from{transform:scale(.97);opacity:.6}to{transform:none;opacity:1}}
.sheet-head,.modal-head{display:flex;align-items:center;justify-content:space-between;padding:16px 18px;border-bottom:1px solid var(--border);position:sticky;top:0;background:var(--surface)}
.sheet-body,.modal-body{padding:18px}
.sheet iframe{width:100%;height:62vh;border:1px solid var(--border);border-radius:8px;background:#fff}
.tabs{display:flex;gap:4px;border-bottom:1px solid var(--border);margin-bottom:16px;overflow-x:auto}
.tabs button{border:none;background:none;padding:9px 13px;font-weight:600;color:var(--muted);border-bottom:2px solid transparent;white-space:nowrap}
.tabs button.active{color:var(--text);border-bottom-color:var(--teal)}
.timeline{list-style:none;padding:0;margin:0}
.timeline li{display:flex;gap:12px;padding:9px 0;align-items:flex-start}
.timeline .dot{width:11px;height:11px;border-radius:50%;background:var(--border);margin-top:4px;flex-shrink:0}
.timeline li.done .dot{background:var(--teal)}
.kanban{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:10px}
.kanban .col{background:var(--accent);border-radius:8px;padding:8px}
.kanban .col h5{font-size:11.5px;text-transform:uppercase;color:var(--muted);margin-bottom:8px;padding:2px 4px}
.kanban .kc{background:var(--surface);border:1px solid var(--border);border-radius:7px;padding:8px 10px;margin-bottom:6px;font-size:12.5px}
.row-actions{display:flex;gap:6px}
.toast{position:fixed;bottom:22px;left:50%;transform:translateX(-50%);background:var(--navy-2);color:#fff;padding:11px 18px;border-radius:8px;font-size:13px;z-index:200;box-shadow:0 6px 20px rgba(0,0,0,.25);animation:pop .15s}
.toast.err{background:var(--danger)}
.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}
@media(max-width:560px){.form-grid{grid-template-columns:1fr}}
.spin{display:inline-block;width:20px;height:20px;border:2.5px solid var(--border);border-top-color:var(--teal);border-radius:50%;animation:sp .7s linear infinite}
@keyframes sp{to{transform:rotate(360deg)}}
.center-load{display:flex;justify-content:center;padding:60px}

/* ── 알림 팝업 (새 소식) ── */
.notifstack{position:fixed;right:18px;bottom:18px;z-index:210;display:flex;flex-direction:column;gap:8px;max-width:min(340px,calc(100vw - 36px))}
.notif{display:flex;align-items:center;gap:10px;background:#fff;border:1px solid var(--border);border-left:4px solid var(--teal);border-radius:10px;padding:12px 12px 12px 14px;font-size:13px;box-shadow:0 8px 24px rgba(15,30,60,.18);cursor:pointer;animation:pop .2s;line-height:1.5}
.notif span{flex:1;word-break:break-all}
.notif .x{background:none;border:none;color:var(--muted,#888);font-size:16px;cursor:pointer;padding:0 2px;line-height:1}
.notif.out{opacity:0;transform:translateY(8px);transition:all .3s}
.likebtn{background:none;border:1px solid var(--border);border-radius:999px;padding:4px 12px;font-size:13px;cursor:pointer;display:inline-flex;align-items:center;gap:5px;transition:all .15s}
.likebtn:hover{border-color:var(--teal)}
.likebtn.on{border-color:#f5b7c4;background:#fff5f7}
.upbar{height:6px;background:var(--bg);border:1px solid var(--border);border-radius:4px;margin-top:4px;overflow:hidden}
.upbar i{display:block;height:100%;width:0%;background:var(--teal);transition:width .15s}
.icon-btn{cursor:pointer;font-size:16px;color:var(--text,#1c2942)}

/* ══════════ v2.0 Research Workspace ══════════ */
/* 로고 마크 */
.sidebar .brand .mark.logo-mark{background:#fff;padding:3px;border:1px solid var(--border)}
.logo-mark img{width:100%;height:100%;object-fit:contain;border-radius:inherit;display:block}

/* 체크박스 필 (카테고리·멤버·PM 선택) */
.chkwrap{display:flex;flex-wrap:wrap;gap:6px;margin:6px 0}
.chkpill{display:inline-flex;align-items:center;gap:5px;padding:4px 10px;border:1px solid var(--border);border-radius:14px;font-size:12px;cursor:pointer;background:#fff;user-select:none}
.chkpill input{accent-color:var(--teal);margin:0}
.chkpill:has(input:checked){border-color:var(--teal);background:#eefaf8;color:#0b6b5f}
.chkpill.sub{font-size:11px;opacity:.9;margin-left:8px}

/* Project Type 배지 */
.ptype{display:inline-block;padding:2px 8px;border-radius:10px;font-size:11px;font-weight:600;line-height:1.5}
.ptype-paper{background:#e8f0fe;color:#1a56b0}
.ptype-contract{background:#fef3e2;color:#a05a00}
.ptype-gov{background:#efe8fd;color:#5b2fb0}
.ptype-univ{background:#e2f7ef;color:#0b7a52}
.ptype-internal{background:#eef1f5;color:#44546a}
.ptype-collab{background:#e0f4fb;color:#0b6f8f}
.ptype-intern{background:#fdeef2;color:#b03060}
.ptype-etc{background:#f2f2ec;color:#6b6b52}

.pill.navy{background:#e8effa;color:#1f3f77;border-color:#c8d8f0}

/* Todo */
.tdrow{display:flex;align-items:center;gap:10px;padding:9px 4px;border-bottom:1px solid var(--border)}
.tdrow:last-child{border-bottom:none}
.tdrow input[type=checkbox]{width:17px;height:17px;accent-color:var(--teal);cursor:pointer;flex-shrink:0}
.tdrow .tdt{flex:1;min-width:0;cursor:pointer}
.tdrow.done .tdt{text-decoration:line-through;color:var(--muted)}
.tdrow .tdmeta{font-size:11px;color:var(--muted);margin-top:1px;display:flex;gap:6px;flex-wrap:wrap}
.tdrow .tdact{font-size:11px;color:var(--teal);cursor:pointer;white-space:nowrap}
.tdrow .tdact:hover{text-decoration:underline}
.tdpri-high{color:#c0392b;font-weight:700}
.tdpri-mid{color:#a05a00}
.tdpri-low{color:var(--muted)}

/* 팀 챗 */
.chatbox{height:420px;overflow-y:auto;padding:10px 6px;background:var(--bg);border:1px solid var(--border);border-radius:10px;display:flex;flex-direction:column;gap:2px}
.cdate{text-align:center;font-size:11px;color:var(--muted);margin:10px 0 6px;position:relative}
.cdate span{background:var(--bg);padding:0 10px;position:relative;z-index:1}
.cdate::before{content:'';position:absolute;left:0;right:0;top:50%;border-top:1px solid var(--border)}
.cmsg{display:flex;gap:8px;padding:4px 6px;border-radius:8px;max-width:88%}
.cmsg:hover{background:#eef1f4}
.cmsg.mine{flex-direction:row-reverse;align-self:flex-end}
.cav{width:30px;height:30px;border-radius:50%;background:var(--teal);color:#fff;display:flex;align-items:center;justify-content:center;font-size:12px;font-weight:700;flex-shrink:0;margin-top:2px}
.cmsg.mine .cav{background:#44546a}
.cbody{min-width:0}
.cname{font-size:11px;color:var(--muted);margin-bottom:2px}
.cmsg.mine .cname{text-align:right}
.ctext{background:#fff;border:1px solid var(--border);border-radius:10px;padding:7px 11px;font-size:13px;line-height:1.5;word-break:break-word;white-space:pre-wrap}
.cmsg.mine .ctext{background:#e6f5f2;border-color:#c9e8e2}
.creply{font-size:11px;color:var(--muted);border-left:2px solid var(--teal);padding:2px 8px;margin-bottom:3px;background:#fff;border-radius:0 6px 6px 0;cursor:pointer;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:280px}
.cpinned{font-size:10px;color:#a05a00}
.cfile{display:flex;align-items:center;gap:8px;background:#fff;border:1px solid var(--border);border-radius:10px;padding:8px 11px;font-size:13px;margin-top:2px}
.cfile a{color:var(--teal);font-weight:600;text-decoration:none;word-break:break-all}
.carchive{font-size:10px;color:var(--muted);margin-top:3px}
.cmeta{font-size:10px;color:var(--muted);margin-top:2px;display:flex;gap:8px;align-items:center}
.cmsg.mine .cmeta{justify-content:flex-end}
.cacts{display:none;gap:6px}
.cmsg:hover .cacts{display:inline-flex}
.cacts span{cursor:pointer;opacity:.7}
.cacts span:hover{opacity:1}
.rxrow{display:flex;gap:4px;margin-top:3px;flex-wrap:wrap}
.cmsg.mine .rxrow{justify-content:flex-end}
.rx{display:inline-flex;align-items:center;gap:3px;border:1px solid var(--border);border-radius:10px;padding:1px 7px;font-size:11px;background:#fff;cursor:pointer}
.rx.mine{border-color:var(--teal);background:#eefaf8}
.pinbar{background:#fffbea;border:1px solid #f0e2b0;border-radius:8px;padding:6px 10px;font-size:12px;margin-bottom:8px}
.pinbar .pi{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:2px 0;cursor:pointer}
.replybar{display:flex;align-items:center;gap:8px;background:#eef1f4;border-radius:8px;padding:5px 10px;font-size:12px;color:var(--muted);margin-top:8px}
.replybar b{color:var(--text)}
.replybar .rx-close{margin-left:auto;cursor:pointer;font-size:14px}
.chatinput{display:flex;gap:8px;align-items:flex-end;margin-top:8px}
.chatinput textarea{flex:1;min-height:40px;max-height:120px;resize:vertical}
.chatfile-label{cursor:pointer;font-size:18px;padding:8px 6px;color:var(--muted)}
.chatfile-label:hover{color:var(--teal)}
.mention{color:#1a56b0;font-weight:600;background:#e8f0fe;border-radius:4px;padding:0 3px}

/* 챗 오버뷰 */
.chatitem{display:flex;align-items:center;gap:12px;padding:12px 10px;border-bottom:1px solid var(--border);cursor:pointer;border-radius:8px}
.chatitem:hover{background:var(--bg)}
.chatitem .ci-last{font-size:12px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;margin-top:2px}
.unread-dot{width:9px;height:9px;border-radius:50%;background:#e0533d;display:inline-block;flex-shrink:0}

/* 논문 정리 (Knowledge Base) */
.kbsec{border:1px solid var(--border);border-radius:10px;margin-bottom:10px;overflow:hidden}
.kbhead{background:var(--bg);padding:8px 12px;font-size:13px;font-weight:700;display:flex;align-items:center;gap:8px}
.kbentry{padding:9px 12px;border-top:1px solid var(--border)}
.kbwho{font-size:11px;color:var(--muted);margin-bottom:4px;display:flex;gap:8px;align-items:center}
.kbtext{font-size:13px;line-height:1.6;white-space:pre-wrap;word-break:break-word}

/* 논문 추천 */
.reccard{border:1px solid var(--border);border-radius:12px;padding:14px;margin-bottom:10px;background:#fff}
.reccard:hover{border-color:var(--teal)}
.matchbadge{display:inline-block;background:#0b6b5f;color:#fff;border-radius:10px;padding:2px 9px;font-size:11px;font-weight:700}
.whybox{background:#f4faf9;border:1px solid #d8ede9;border-radius:8px;padding:7px 11px;font-size:12px;color:#0b6b5f;margin:8px 0}
.recacts{display:flex;gap:6px;flex-wrap:wrap;margin-top:8px}
.recacts .mini{font-size:12px}

/* Daily/Weekly 연구노트 */
.dn-item{display:flex;gap:8px;align-items:flex-start;padding:6px 4px;border-bottom:1px dashed var(--border);font-size:13px}
.dn-item:last-child{border-bottom:none}
.dn-ic{flex-shrink:0;width:20px;text-align:center}
.autopill{display:inline-block;background:#eef1f5;color:#44546a;border-radius:8px;padding:1px 7px;font-size:10px;font-weight:600;vertical-align:middle}
.savest{font-size:11px;color:var(--muted)}
.savest.saving{color:#a05a00}
.savest.saved{color:#0b7a52}

/* 카테고리 트리 (설정) */
.cattree{font-size:13px}
.catrow{display:flex;align-items:center;gap:8px;padding:6px 4px;border-bottom:1px solid var(--border)}
.catrow:last-child{border-bottom:none}
.catrow.child{padding-left:26px;font-size:12px}
.catrow .ca{font-size:11px;color:var(--teal);cursor:pointer;white-space:nowrap}
.catrow .ca:hover{text-decoration:underline}
.catrow .ca.danger{color:#c0392b}

/* 가중치 슬라이더 */
.wrow{display:flex;align-items:center;gap:10px;margin:8px 0;font-size:13px}
.wrow label{width:110px;flex-shrink:0}
.wrow input[type=range]{flex:1;accent-color:var(--teal)}
.wrow .wval{width:38px;text-align:right;font-weight:700}

/* 검색 그룹 확장·기타 */
.mystat-pill{font-size:11px;padding:2px 8px;border-radius:10px;background:var(--bg);border:1px solid var(--border)}

/* v2.1 소폭 개선 */
.recpct{flex:none;width:42px;height:42px;border-radius:50%;background:#eefaf8;border:2px solid var(--teal);color:#0b6b5f;font-weight:700;font-size:11px;display:inline-flex;align-items:center;justify-content:center;line-height:1}
.unread-dot{width:auto;min-width:17px;height:17px;border-radius:9px;background:#e0533d;color:#fff;font-size:10px;font-weight:700;display:inline-flex;align-items:center;justify-content:center;padding:0 4px;line-height:1;vertical-align:middle}
.unread-dot:empty{min-width:9px;width:9px;height:9px;padding:0}
