/* ==================== 个人工作台 ==================== */

.workspace-tabs {
    border-bottom: 2px solid var(--border, #e2e8f0);
    background: var(--card-header-bg, #f8fafc);
}

.workspace-tabs .nav-link {
    border: none;
    color: var(--text-muted, #64748b);
    padding: 12px 20px;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    font-size: 14px;
    transition: all .15s;
}

.workspace-tabs .nav-link:hover {
    color: var(--text, #1e293b);
    border-bottom-color: var(--border, #cbd5e1);
}

.workspace-tabs .nav-link.active {
    color: var(--primary, #2563eb);
    border-bottom-color: var(--primary, #2563eb);
    font-weight: 600;
    background: transparent;
}

.memo-list {
    display: flex;
    flex-direction: column;
}

.memo-item {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-light, #f1f5f9);
    transition: background .15s;
    cursor: pointer;
}

.memo-item:hover {
    background: var(--hover-bg, #f8fafc);
}

.memo-item.pinned {
    background: var(--warning-bg, #fffbeb);
    border-left: 3px solid #f59e0b;
}

.memo-item.done {
    opacity: 0.6;
}

.memo-item.overdue {
    background: #fff5f5;
    border-left: 3px solid #dc2626;
}

/* 待办事项分组 */
.memo-section {
    margin-bottom: 2px;
}
.memo-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
    background: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
    position: sticky;
    top: 0;
    z-index: 1;
}
.memo-section-header.today { color: #2563eb; background: #eff6ff; border-left: 3px solid #2563eb; }
.memo-section-header.upcoming { color: #7c3aed; background: #f5f3ff; border-left: 3px solid #7c3aed; }
.memo-section-header.future { color: #0891b2; background: #ecfeff; border-left: 3px solid #0891b2; }
.memo-section-header.overdue { color: #dc2626; background: #fef2f2; border-left: 3px solid #dc2626; }
.memo-section-header.unscheduled { color: #6b7280; background: #f3f4f6; border-left: 3px solid #9ca3af; }
.memo-section-count {
    font-weight: 400;
    font-size: 12px;
    opacity: 0.7;
}

/* 待办事项混排卡状态阴影（2026-10-16 · 洛川需求：hover 阴影变明显 + 按状态着色）
   覆盖范围：dispatch.js memoCardHtml / taskCardHtml / followupCardHtml 三类卡（均带 .task-card），
   即工作台「待办事项」tab 里混排的个人待办、派发任务、回访待办。
   颜色口径：正常 = 科技蓝（theme.css --primary-500 #2563eb）；过期 = 红（Bootstrap .border-danger #dc3545）。
   特异性说明：.card.task-card 为 (0,3,0)，压过 theme.css 的 .card:hover (0,2,0)，
   不受 theme.css 最后加载的影响；theme.css .card 自带 box-shadow .25s 过渡，此处沿用。 */
.card.task-card {
    box-shadow: 0 2px 4px rgba(37, 99, 235, .08), 0 4px 12px rgba(37, 99, 235, .12);
}
.card.task-card:hover {
    box-shadow: 0 8px 24px rgba(37, 99, 235, .32), 0 2px 8px rgba(37, 99, 235, .20);
    border-color: rgba(37, 99, 235, .50);
}
/* 过期卡：红框（dispatch.js 已加 border-danger）+ 红色常驻阴影，hover 同色系加重 */
.card.task-card.border-danger {
    box-shadow: 0 2px 4px rgba(220, 53, 69, .10), 0 4px 12px rgba(220, 53, 69, .14);
}
.card.task-card.border-danger:hover {
    box-shadow: 0 8px 24px rgba(220, 53, 69, .32), 0 2px 8px rgba(220, 53, 69, .20);
}

/* 人脉分组标签 */
.group-badge {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 500;
}
.group-政府 { background: #eff6ff; color: #2563eb; }
.group-基金 { background: #fef3c7; color: #d97706; }
.group-项目方 { background: #ecfdf5; color: #059669; }
.group-朋友 { background: #fdf2f8; color: #db2777; }
.group-合作伙伴 { background: #f5f3ff; color: #7c3aed; }
.group-专家 { background: #f0fdf4; color: #16a34a; }
.group-投资人 { background: #fff7ed; color: #ea580c; }
.group-其他 { background: #f1f5f9; color: #64748b; }

.memo-item .memo-actions {
    display: flex;
    gap: 4px;
    opacity: 0;
    transition: opacity .15s;
}

.memo-item:hover .memo-actions {
    opacity: 1;
}

.repeat-badge {
    background: #e0f2fe;
    color: #0369a1;
    font-weight: 500;
    font-size: 11px;
}

/* 居中提示弹窗 */
.center-alert-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0,0.45);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}
.center-alert-box {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    width: 90%;
    max-width: 400px;
    padding: 24px;
    text-align: center;
    animation: centerAlertIn .2s ease-out;
}
.center-alert-box .icon {
    font-size: 36px;
    margin-bottom: 12px;
}
.center-alert-box .title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #1f2937;
}
.center-alert-box .message {
    font-size: 14px;
    color: #6b7280;
    margin-bottom: 20px;
    line-height: 1.5;
    white-space: pre-wrap;
}
.center-alert-box .btn {
    min-width: 80px;
}
@keyframes centerAlertIn {
    from { opacity: 0; transform: translateY(-10px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.habit-card {
    transition: transform .15s, box-shadow .15s;
    border-left: 4px solid transparent;
    cursor: pointer;
}
.habit-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
.habit-card.habit-done {
    border-left-color: #22c55e;
}
.habit-icon-circle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}
.habit-check-circle {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 2px solid #cbd5e1;
    background: transparent;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
    cursor: pointer;
    padding: 0;
    transition: border-color .15s, background .15s;
}
.habit-check-circle:hover { border-color: #2563eb; }
.habit-check-circle.is-done {
    background: #2563eb;
    border-color: #2563eb;
}
.habit-check-circle .bi { font-size: 14px; line-height: 1; }

.habit-actions {
    display: flex;
    gap: 4px;
    opacity: 0;
    transition: opacity .15s;
}
.habit-card:hover .habit-actions {
    opacity: 1;
}
.habit-icon-btn {
    width: 36px;
    height: 36px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.habit-icon-btn.active {
    background: var(--primary, #2563eb);
    color: #fff;
    border-color: var(--primary, #2563eb);
}
.habit-color-btn {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 2px solid transparent;
    padding: 0;
}
.habit-color-btn.active {
    border-color: #1e293b;
    transform: scale(1.1);
}
.habit-reminder-tag {
    font-size: 13px;
    padding: 6px 10px;
    font-weight: 500;
}

.contact-avatar {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: var(--primary-light, #eff6ff);
    color: var(--primary, #2563eb);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
    flex-shrink: 0;
    transition: all .15s;
}

.contact-avatar:hover {
    background: var(--primary, #2563eb);
    color: #fff;
    transform: scale(1.05);
}

/* 人脉卡片 */
.contact-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 14px 16px;
    cursor: pointer;
    transition: all .15s;
}

.contact-card:hover {
    border-color: var(--primary, #2563eb);
    box-shadow: 0 2px 8px rgba(37,99,235,.1);
}

.contact-card.contact-overdue {
    border-left-width: 3px;
    border-left-style: solid;
}
.contact-card.contact-warning {
    border-left-width: 3px;
    border-left-style: solid;
    border-left-color: #f59e0b;
}

/* 人脉卡片墙 */
.contact-card-wall {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 16px;
    cursor: pointer;
    transition: all .15s;
    height: 100%;
}

.contact-card-wall:hover {
    border-color: var(--primary, #2563eb);
    box-shadow: 0 4px 16px rgba(37,99,235,.12);
    transform: translateY(-2px);
}

.contact-card-wall.contact-overdue {
    border-color: #fca5a5;
    background: #fef2f2;
}
.contact-card-wall.contact-warning {
    border-color: #fde68a;
    background: #fffbeb;
}

/* 人脉维护记录 */
.contact-records-section {
    margin-top: 12px;
}

.contact-records-divider {
    height: 1px;
    background: #e5e7eb;
    margin: 10px 0 12px 0;
}

.record-item {
    border-bottom: 1px solid #f3f4f6;
}

.record-item:last-child {
    border-bottom: none;
}

.record-item:hover {
    background: #f9fafb;
    border-radius: 6px;
    padding-left: 6px;
    padding-right: 6px;
}

/* 日报周报 */
.report-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.report-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 16px;
    transition: all .15s;
}

.report-card:hover {
    border-color: #93c5fd;
    box-shadow: 0 2px 8px rgba(37,99,235,.08);
}

.report-date-badge {
    width: 56px;
    height: 50px;
    border-radius: 10px;
    background: var(--primary-light, #eff6ff);
    color: var(--primary, #2563eb);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    line-height: 1.1;
    overflow: hidden;
}

/* 汇报流时间线 */
.flow-timeline {
    position: relative;
    padding-left: 8px;
}
.flow-timeline-item {
    position: relative;
    padding-left: 28px;
    padding-bottom: 20px;
}
.flow-timeline-item:last-child {
    padding-bottom: 0;
}
.flow-timeline-item::before {
    content: '';
    position: absolute;
    left: 11px;
    top: 24px;
    bottom: 0;
    width: 2px;
    background: #e5e7eb;
}
.flow-timeline-item:last-child::before {
    display: none;
}
.flow-timeline-dot {
    position: absolute;
    left: 0;
    top: 0;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* @ 提及下拉 */
.mention-dropdown {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    bottom: 100%;
    margin-bottom: 4px;
    max-height: 200px;
    overflow-y: auto;
    background: #fff;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0,0,0,.12);
    z-index: 1000;
}

.mention-dropdown .mention-item {
    padding: 8px 12px;
    cursor: pointer;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: background .1s;
}

.mention-dropdown .mention-item:hover,
.mention-dropdown .mention-item.active {
    background: #eff6ff;
    color: #2563eb;
}

.mention-dropdown .mention-item i {
    font-size: 14px;
    opacity: .6;
}

.mention-dropdown .mention-group-label {
    padding: 4px 10px 2px;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: .5px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 2px;
}

/* # 对接人：前面没有 @企业 时的提示（不可点，仅说明为什么要先 @） */
.mention-dropdown .mention-hint {
    padding: 8px 12px;
    font-size: 12.5px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: default;
}

.mention-dropdown .mention-hint i {
    font-size: 14px;
    opacity: .7;
}

.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,.4);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1050;
}

.modal-box {
    background: #fff;
    border-radius: 12px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 8px 32px rgba(0,0,0,.2);
}

/* ---- 每日目标次数：组合控件（可输入 + 下拉三角出常用档位）---- */
/* 2026-10-17 BOSS 需求：用户可直接键入任意正整数（跳绳/俯卧撑 50~200 次）， */
/* 同时保留右侧下拉三角点出预设档位（含「不限」）。沿用主题令牌，浅/深色自适应。 */
.kj-dg {
    position: relative;
}
.kj-dg__input {
    padding-right: 2.25rem;  /* 给右侧三角留位，避免数字与箭头重叠 */
}
.kj-dg__caret {
    position: absolute;
    top: 0;
    right: 0;
    width: 2.25rem;
    height: 100%;
    border: 0;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}
.kj-dg__caret::after {
    content: "";
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 6px solid var(--text-muted, #64748b);
    pointer-events: none;
}
.kj-dg__menu {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    z-index: 60;            /* 高于弹窗滚动区，确保浮层不被裁切 */
    background: var(--surface, #fff);
    border: 1px solid var(--border, #e6e9f0);
    border-radius: var(--radius-xs, 6px);
    box-shadow: var(--shadow-md, 0 6px 16px rgba(0,0,0,.08));
    max-height: 220px;
    overflow-y: auto;
    padding: 4px;
}
.kj-dg__item {
    display: block;
    width: 100%;
    text-align: left;
    border: 0;
    background: transparent;
    padding: 7px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    color: var(--text, #0f172a);
}
.kj-dg__item:hover {
    background: rgba(37, 99, 235, .08);
    color: var(--primary-600, #1d4ed8);
}
body.dark .kj-dg__item:hover {
    background: rgba(96, 165, 250, .14);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid #e5e7eb;
}

.modal-title {
    font-size: 16px;
    font-weight: 600;
}

.modal-body {
    padding: 20px;
}

.btn-close {
    background: transparent url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3e%3cpath d='M.293.293a1 1 0 0 1 1.414 0L8 6.586 14.293.293a1 1 0 1 1 1.414 1.414L9.414 8l6.293 6.293a1 1 0 0 1-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 0 1-1.414-1.414L6.586 8 .293 1.707a1 1 0 0 1 0-1.414z'/%3e%3c/svg%3e") center/1em auto no-repeat;
    border: none;
    cursor: pointer;
    padding: 0.25em;
    line-height: 1;
    opacity: 0.7;
}

.btn-close:hover { opacity: 1; }

.stat-card {
    transition: all .2s;
    border: 1px solid var(--border, #e2e8f0);
    height: 100%;            /* 同排卡片强制等高 */
}

.stat-card-clickable {
    position: relative;
}

.stat-card-clickable::after {
    content: '\F134';
    font-family: 'bootstrap-icons';
    position: absolute;
    top: 12px;
    right: 12px;
    font-size: 12px;
    color: var(--gray-400, #9ca3af);
    opacity: 0;
    transition: opacity .2s;
    pointer-events: none;
}

.stat-card-clickable:hover::after {
    opacity: 1;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,.08);
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.modal-box-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border, #e2e8f0);
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 16px;
}

.modal-box-body {
    padding: 20px;
    max-height: 70vh;
    overflow-y: auto;
}

.modal-box-footer {
    padding: 14px 20px;
    border-top: 1px solid var(--border, #e2e8f0);
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

/* 仪表盘选择器 */
.dashboard-selector { position: relative; display: inline-block; flex-shrink: 0; }

.dashboard-selector .dropdown-toggle {
    font-size: 13px;
    padding: 4px 12px;
    border-radius: 6px;
    white-space: nowrap;
}

.dashboard-menu {
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 4px;
    min-width: 220px;
    background: var(--card-bg, #fff);
    border: 1px solid var(--border, #e2e8f0);
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,.12);
    z-index: 1050;
    overflow: hidden;
}

.dashboard-menu-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    cursor: pointer;
    font-size: 13px;
    transition: background .15s;
}

.dashboard-menu-item:hover { background: var(--hover-bg, #f8fafc); }
.dashboard-menu-item.active { background: #eef2ff; color: var(--primary, #4f46e5); font-weight: 600; }

.dashboard-menu-count {
    font-size: 11px;
    color: var(--text-muted, #94a3b8);
    background: #f1f5f9;
    padding: 1px 8px;
    border-radius: 10px;
}

.dashboard-menu-divider {
    height: 1px;
    background: var(--border, #e2e8f0);
    margin: 4px 0;
}

.dashboard-menu-new {
    color: var(--primary, #4f46e5);
    gap: 6px;
    justify-content: flex-start;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: var(--brand-name);
    font-weight: var(--brand-name-weight);
    color: #fff;
}

.logo i { font-size: var(--brand-mark); color: var(--primary); }

.sidebar ul { list-style: none; padding: 12px 8px; flex: 0 0 auto; overflow-y: auto; overflow-x: hidden; }

.nav-item { margin-bottom: 2px; }

.nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    color: #cbd5e1;
    text-decoration: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all .2s;
    font-size: 13.5px;
}

.nav-link:hover { background: rgba(255,255,255,.06); color: #fff; }
.nav-link.active { background: var(--primary); color: #fff; }
.nav-link i { font-size: 18px; width: 20px; text-align: center; }
.nav-group { margin: 2px 0; }
.nav-group-head {
    display: flex; align-items: center; gap: 10px;
    padding: 10px 14px; cursor: pointer;
    color: #cbd5e1; font-size: 13.5px; font-weight: 500;
    transition: color .15s, background .15s;
}
.nav-group-head:hover { color: #fff; background: rgba(255,255,255,.06); }
.nav-group-head > i:first-child { font-size: 18px; width: 20px; text-align: center; }
.nav-group-chevron { margin-left: 6px; font-size: .7rem; transition: transform .15s; transform: rotate(-90deg); }
.nav-group.open .nav-group-chevron { transform: rotate(0deg); }
.nav-group-items { display: none; }
.nav-group.open > .nav-group-items { display: block; }
.nav-group-items .nav-item .nav-link { padding-left: 40px; font-size: 13.5px; }

/* 侧边栏横向滚动条修复（2026-08-18，2026-08-29 宽度 240px→200px）：固定宽度下菜单不再出现左右滑块。
   .sidebar ul 已加 overflow-x:hidden 关掉横向滚动；此处让超长菜单文字省略号截断，
   悬停 title 看全名，而非撑破 200px 布局。图标/箭头 flex-shrink:0 保持不收缩。 */
.nav-link, .nav-group-head { min-width: 0; }
.nav-link > i, .nav-group-head > i:first-child, .nav-group-chevron { flex-shrink: 0; }
.nav-link > span, .nav-group-head > span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}

.sidebar-footer { padding: 14px 18px; border-top: 1px solid rgba(255,255,255,.08); }

.user-info { display: flex; align-items: center; gap: 10px; }
.user-avatar {
    width: 36px; height: 36px; border-radius: 50%;
    background: var(--primary); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 16px; flex-shrink: 0;
}
.user-detail { flex: 1; min-width: 0; }
.user-name { color: #fff; font-size: 14px; font-weight: 600; }
.user-role { color: rgba(255,255,255,.5); font-size: 12px; }

