/* ============ 云客 CRM Pro · 简洁后台管理风格 ============ */
:root {
--primary: #2563eb;
--primary-dark: #1d4ed8;
--primary-light: #eff6ff;
--bg: #f5f6f8;
--surface: #ffffff;
--border: #e5e7eb;
--text: #1f2937;
--text-soft: #6b7280;
--text-mute: #9ca3af;
--danger: #dc2626;
--success: #16a34a;
--warn: #d97706;
--radius: 8px;
--shadow: 0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
--shadow-lg: 0 12px 32px rgba(0,0,0,.12);
--ease: cubic-bezier(.4,0,.2,1);
--t: .2s;
--font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
* { box-sizing: border-box; }
html, body, #root { height: 100%; margin: 0; }
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", sans-serif;
font-size: 14px; color: var(--text); background: var(--bg);
}
button, input, select, textarea { font-family: inherit; font-size: inherit; }
button { cursor: pointer; }
/* 全局平滑过渡 */
.btn, .nav-item, .tab, .pool-tab, .table tbody tr, .cloud-item, .scope-opt, .stat-card, .method-chip {
transition: all var(--t) var(--ease);
}
.btn:active, .nav-item:active { transform: translateY(1px); }
::selection { background: #dbeafe; color: #1e3a8a; }
/* 滚动条美化 */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 8px; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; }
::-webkit-scrollbar-track { background: transparent; }
code { background: #f3f4f6; padding: 2px 6px; border-radius: 4px; font-size: 12px; color: #374151; }
em { color: var(--danger); font-style: normal; }
/* ---------- 启动/登录 ---------- */
.boot, .login-page { height: 100%; display: flex; align-items: center; justify-content: center; flex-direction: column; }
.boot-logo, .login-mark, .brand-mark {
display: inline-flex; align-items: center; justify-content: center;
background: var(--primary); color: #fff; font-weight: 700; border-radius: 10px;
}
.boot-logo { width: 56px; height: 56px; font-size: 26px; margin-bottom: 16px; }
.boot p { color: var(--text-soft); }
.login-page { background: linear-gradient(135deg,#eef2ff 0%,#f5f6f8 50%,#e0f2fe 100%); }
.login-box { width: 380px; background: var(--surface); border-radius: 14px; box-shadow: 0 12px 40px rgba(0,0,0,.1); padding: 40px;
animation: loginIn .5s var(--ease); }
@keyframes loginIn { from { opacity: 0; transform: translateY(16px) scale(.98) } to { opacity: 1; transform: none } }
.login-mark { animation: markPulse 3s ease-in-out infinite; }
@keyframes markPulse { 0%,100% { box-shadow: 0 0 0 0 rgba(37,99,235,.25) } 50% { box-shadow: 0 0 0 10px rgba(37,99,235,0) } }
.login-brand { text-align: center; margin-bottom: 30px; }
.login-mark { width: 56px; height: 56px; font-size: 26px; margin: 0 auto 14px; }
.login-brand h1 { margin: 0 0 6px; font-size: 23px; }
.login-brand p { margin: 0; color: var(--text-soft); font-size: 13px; }
.login-form label, .modal-body label, .drawer-form label { display: block; margin-bottom: 14px; color: var(--text-soft); font-size: 13px; }
.login-form input, .modal-body input, .modal-body select, .modal-body textarea,
.drawer-form textarea, .settings-body input, .settings-body select,
.toolbar input, .toolbar select {
display: block; width: 100%; margin-top: 6px; padding: 10px 12px;
border: 1px solid var(--border); border-radius: 7px; background: #fff; color: var(--text);
}
.login-form input:focus, .modal-body input:focus, .modal-body select:focus, .modal-body textarea:focus,
.drawer-form textarea:focus, .toolbar input:focus, .toolbar select:focus {
outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,235,.1);
}
.login-foot { text-align: center; margin-top: 22px; font-size: 12px; color: var(--text-mute); }
/* ---------- 按钮 ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px;
padding: 9px 16px; border: 1px solid var(--border); border-radius: 7px;
background: #fff; color: var(--text); font-weight: 500; white-space: nowrap; }
.btn:hover { border-color: #c7cbd1; background: #fafafa; }
.btn-primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
.btn-ghost { background: #fff; }
.btn-sm { padding: 5px 11px; font-size: 13px; }
.btn-block { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.file-btn { position: relative; }
.form-error { color: var(--danger); background: #fef2f2; border: 1px solid #fecaca; padding: 9px 12px; border-radius: 7px; font-size: 13px; margin: 10px 0; }
/* ---------- 布局 ---------- */
.app-shell { display: flex; height: 100%; }
.sidebar { width: 210px; flex-shrink: 0; background: #111827; color: #d1d5db; display: flex; flex-direction: column; }
.brand { display: flex; align-items: center; gap: 10px; padding: 20px; border-bottom: 1px solid #1f2937; }
.brand-mark { width: 34px; height: 34px; font-size: 17px; border-radius: 8px; }
.brand-text { font-size: 16px; font-weight: 600; color: #fff; line-height: 1.2; }
.brand-text small { display: block; font-size: 11px; font-weight: 400; color: #6b7280; margin-top: 2px; }
.nav { padding: 12px; flex: 1; }
.nav-item { width: 100%; display: flex; align-items: center; gap: 10px; padding: 11px 12px; margin-bottom: 4px;
border: 0; border-radius: 7px; background: transparent; color: #9ca3af; text-align: left; font-size: 14px; }
.nav-item:hover { background: #1f2937; color: #e5e7eb; }
.nav-item.active { background: var(--primary); color: #fff; }
.nav-icon { font-size: 16px; width: 18px; text-align: center; }
.sidebar-foot { padding: 16px 20px; border-top: 1px solid #1f2937; }
.side-stat { display: flex; justify-content: space-between; font-size: 12px; color: #6b7280; margin-bottom: 8px; }
.side-stat b { color: #d1d5db; }
.main { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.topbar { height: 62px; flex-shrink: 0; background: var(--surface); border-bottom: 1px solid var(--border);
display: flex; align-items: center; justify-content: space-between; padding: 0 26px; }
.topbar-title { font-size: 17px; font-weight: 600; }
.topbar-user { display: flex; align-items: center; gap: 10px; }
.user-badge { display: flex; align-items: center; gap: 9px; margin-right: 6px; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--primary-light); color: var(--primary);
display: inline-flex; align-items: center; justify-content: center; font-weight: 600; }
.user-info { line-height: 1.25; }
.user-info b { display: block; font-size: 13px; }
.user-info small { color: var(--text-soft); font-size: 11px; }
.content { flex: 1; overflow-y: auto; padding: 22px 26px 40px; animation: contentIn .3s var(--ease); }
@keyframes contentIn { from { opacity: 0; transform: translateY(6px) } to { opacity: 1; transform: none } }
/* ---------- 统计卡 ---------- */
.stat-row { display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; margin-bottom: 18px; }
.stat-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
padding: 16px 18px; box-shadow: var(--shadow);
animation: cardIn .35s var(--ease) backwards; }
.stat-card:nth-child(1) { animation-delay: .02s } .stat-card:nth-child(2) { animation-delay: .06s }
.stat-card:nth-child(3) { animation-delay: .1s } .stat-card:nth-child(4) { animation-delay: .14s }
.stat-card:nth-child(5) { animation-delay: .18s } .stat-card:nth-child(6) { animation-delay: .22s }
@keyframes cardIn { from { opacity: 0; transform: translateY(10px) } to { opacity: 1; transform: none } }
.stat-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.stat-card span { display: block; color: var(--text-soft); font-size: 12px; margin-bottom: 8px; }
.stat-card b { font-size: 26px; font-weight: 600; }
@media (max-width: 1100px) { .stat-row { grid-template-columns: repeat(3, 1fr); } }
/* ---------- 面板/工具栏 ---------- */
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.panel-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--border); }
.panel-head h3 { margin: 0; font-size: 15px; }
.panel-head p { margin: 5px 0 0; }
.toolbar { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.toolbar input.search { width: 280px; margin: 0; }
.toolbar select { width: auto; margin: 0; padding: 9px 12px; }
.toolbar-spacer { flex: 1; }
.hint { font-size: 12px; color: var(--text-soft); margin: 6px 0; }
.muted { color: var(--text-mute); }
.nowrap { white-space: nowrap; }
/* ---------- 表格 ---------- */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; padding: 11px 14px; background: #f9fafb; color: var(--text-soft);
font-weight: 500; font-size: 12px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.table td { padding: 12px 14px; border-bottom: 1px solid #f3f4f6; vertical-align: middle; }
.table tbody tr { animation: rowIn .25s var(--ease) backwards; }
.table tbody tr:nth-child(1) { animation-delay: .01s } .table tbody tr:nth-child(2) { animation-delay: .02s }
.table tbody tr:nth-child(3) { animation-delay: .03s } .table tbody tr:nth-child(4) { animation-delay: .04s }
.table tbody tr:nth-child(5) { animation-delay: .05s } .table tbody tr:nth-child(6) { animation-delay: .06s }
.table tbody tr:nth-child(7) { animation-delay: .07s } .table tbody tr:nth-child(8) { animation-delay: .08s }
.table tbody tr:nth-child(9) { animation-delay: .09s } .table tbody tr:nth-child(10) { animation-delay: .1s }
@keyframes rowIn { from { opacity: 0 } to { opacity: 1 } }
.table tbody tr:hover { background: #f0f6ff; }
.table tbody tr:last-child td { border-bottom: 0; }
.table-compact th, .table-compact td { padding: 8px 10px; }
.td-center { text-align: center; color: var(--text-soft); padding: 40px !important; }
.empty { color: var(--text-mute); }
.row-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.link { background: none; border: 0; color: var(--primary); padding: 0; font-size: 13px; }
.link:hover { text-decoration: underline; }
.link-danger { color: var(--danger); }
.link-primary { color: var(--primary); font-weight: 600; }
.pagination { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-top: 1px solid var(--border); color: var(--text-soft); font-size: 13px; }
/* ---------- 标签 ---------- */
.status-tag { display: inline-block; padding: 3px 9px; border-radius: 12px; font-size: 12px; background: #f3f4f6; color: #4b5563; }
.st-lead { background: #e0e7ff; color: #4338ca; }
.st-contacted { background: #fef3c7; color: #b45309; }
.st-won { background: #dcfce7; color: #15803d; }
.st-lost { background: #f3f4f6; color: #6b7280; }
.owner-tag { color: var(--text); }
.pool-tag { background: #ede9fe; color: #6d28d9; padding: 3px 9px; border-radius: 12px; font-size: 12px; }
.level-tag { margin-left: 6px; font-size: 11px; color: var(--warn); }
.super-tag { margin-left: 6px; font-size: 11px; background: #fee2e2; color: #b91c1c; padding: 2px 7px; border-radius: 10px; }
.scope-tag, .perm-tag, .action-tag { display: inline-block; background: var(--primary-light); color: var(--primary);
padding: 2px 8px; border-radius: 10px; font-size: 12px; }
.perm-tags { display: flex; gap: 4px; flex-wrap: wrap; }
.perm-tag { background: #f3f4f6; color: #4b5563; }
.status-dot::before { content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 6px; }
.status-dot.on { color: var(--success); } .status-dot.on::before { background: var(--success); }
.status-dot.off { color: var(--text-mute); } .status-dot.off::before { background: var(--text-mute); }
/* ---------- 弹窗 ---------- */
.modal-backdrop, .drawer-backdrop { position: fixed; inset: 0; background: rgba(17,24,39,.45); z-index: 100;
display: flex; align-items: center; justify-content: center; animation: fade .15s ease;
backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px); }
@keyframes fade { from { opacity: 0 } to { opacity: 1 } }
.modal { background: var(--surface); border-radius: 12px; width: 92%; max-width: 640px; max-height: 90vh; overflow-y: auto; box-shadow: 0 20px 60px rgba(0,0,0,.2); }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 22px; border-bottom: 1px solid var(--border); }
.modal-head h3 { margin: 0; font-size: 16px; }
.modal-x { background: none; border: 0; font-size: 24px; color: var(--text-mute); line-height: 1; }
.modal-x:hover { color: var(--text); }
.modal-body { padding: 20px 22px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 20px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.custom-fields { border-top: 1px dashed var(--border); margin-top: 6px; padding-top: 14px; }
.section-subtitle { font-size: 13px; font-weight: 600; color: var(--text); margin: 6px 0 12px; }
.check-line { display: flex !important; align-items: center; gap: 8px; }
.check-line input { width: auto; margin: 0; }
.saved-tip { color: var(--success); align-self: center; }
/* ---------- 抽屉(跟进)---------- */
.drawer-backdrop { justify-content: flex-end; }
.drawer { width: 100%; max-width: 460px; height: 100%; background: var(--surface); display: flex; flex-direction: column; box-shadow: -8px 0 32px rgba(0,0,0,.15); }
.drawer-head { display: flex; justify-content: space-between; padding: 20px 22px; border-bottom: 1px solid var(--border); }
.drawer-head h3 { margin: 0; font-size: 17px; }
.drawer-sub { margin: 5px 0 0; color: var(--text-soft); font-size: 13px; }
.drawer-form { padding: 16px 22px; border-bottom: 1px solid var(--border); }
.drawer-form textarea { resize: vertical; }
.method-row { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.method-chip { padding: 5px 12px; border: 1px solid var(--border); border-radius: 16px; background: #fff; color: var(--text-soft); font-size: 12px; }
.method-chip.active { border-color: var(--primary); background: var(--primary-light); color: var(--primary); font-weight: 600; }
.drawer-list { flex: 1; overflow-y: auto; padding: 16px 22px; }
.drawer-list-title { font-size: 13px; font-weight: 600; color: var(--text-soft); margin-bottom: 10px; }
.followup-item { padding: 12px 0; border-bottom: 1px solid #f3f4f6; }
.followup-meta { display: flex; align-items: center; gap: 8px; margin-bottom: 7px; font-size: 12px; flex-wrap: wrap; }
.followup-method { padding: 2px 8px; border-radius: 10px; background: #f3f4f6; color: var(--text-soft); }
.method-phone { background: #dbeafe; color: #1d4ed8; }
.method-wechat { background: #d1fae5; color: #047857; }
.method-email { background: #fef3c7; color: #b45309; }
.method-meeting { background: #ede9fe; color: #6d28d9; }
.followup-author { font-weight: 600; }
.followup-time { color: var(--text-mute); }
.followup-content { font-size: 14px; line-height: 1.6; white-space: pre-wrap; }
.empty-mini { color: var(--text-mute); text-align: center; padding: 30px; font-size: 13px; }
/* ---------- Tabs ---------- */
.tabs { display: flex; gap: 4px; margin-bottom: 14px; border-bottom: 1px solid var(--border); }
.tab { padding: 10px 16px; border: 0; background: none; color: var(--text-soft); font-size: 14px; border-bottom: 2px solid transparent; }
.tab:hover { color: var(--text); }
.tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }
/* ---------- 权限勾选 / 字段开关 / 设置 ---------- */
.perm-check { margin: 6px 0 14px; }
.perm-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.check-item { display: flex !important; align-items: center; gap: 7px; margin: 0 !important; cursor: pointer; }
.check-item input { width: auto; margin: 0; }
.toggle { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; color: var(--text-mute); font-size: 12px; padding: 0; }
.toggle span { width: 30px; height: 17px; background: #d1d5db; border-radius: 10px; position: relative; transition: .2s; }
.toggle span::after { content: ''; position: absolute; width: 13px; height: 13px; background: #fff; border-radius: 50%; top: 2px; left: 2px; transition: .2s; }
.toggle.on { color: var(--success); }
.toggle.on span { background: var(--success); }
.toggle.on span::after { left: 15px; }
.settings-body { padding: 20px 22px; max-width: 640px; }
.setting-item { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 16px 0; border-bottom: 1px solid #f3f4f6; }
.setting-item b { font-size: 14px; }
.setting-item p { margin: 4px 0 0; font-size: 12px; color: var(--text-soft); }
.toggle-switch input { display: none; }
.toggle-switch span { width: 42px; height: 23px; background: #d1d5db; border-radius: 14px; display: block; position: relative; transition: .2s; cursor: pointer; }
.toggle-switch span::after { content: ''; position: absolute; width: 19px; height: 19px; background: #fff; border-radius: 50%; top: 2px; left: 2px; transition: .2s; }
.toggle-switch input:checked + span { background: var(--primary); }
.toggle-switch input:checked + span::after { left: 21px; }
/* ---------- 导入 ---------- */
.import-steps { display: flex; gap: 10px; margin-bottom: 8px; }
.import-summary { margin: 14px 0 10px; font-size: 13px; }
.import-summary b { color: var(--text); }
.import-summary .warn-text { color: var(--warn); }
.strategy { margin-left: 16px; color: var(--text-soft); }
.strategy select { margin-left: 6px; padding: 4px 8px; border: 1px solid var(--border); border-radius: 5px; }
.row-dup { background: #fffbeb; }
.dup-tag { color: var(--warn); font-size: 12px; }
.ok-tag { color: var(--success); font-size: 12px; }
.detail-cell { max-width: 240px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-soft); font-size: 12px; }
/* ---------- 通用对话框 / 轻提示 ---------- */
.dlg-backdrop { position: fixed; inset: 0; background: rgba(17,24,39,.5); z-index: 200;
display: flex; align-items: center; justify-content: center; animation: fade .15s ease; padding: 20px; }
.dlg-card { width: 100%; max-width: 420px; background: #fff; border-radius: 14px; box-shadow: 0 20px 60px rgba(0,0,0,.22);
padding: 26px 26px 20px; text-align: center; animation: dlgpop .18s ease; }
@keyframes dlgpop { from { transform: translateY(8px) scale(.98); opacity: 0 } to { transform: none; opacity: 1 } }
.dlg-icon { width: 46px; height: 46px; border-radius: 50%; margin: 0 auto 14px;
display: flex; align-items: center; justify-content: center; font-size: 24px; font-weight: 700; }
.dlg-icon.info { background: var(--primary-light); color: var(--primary); }
.dlg-icon.danger { background: #fee2e2; color: var(--danger); }
.dlg-card h3 { margin: 0 0 10px; font-size: 17px; }
.dlg-card p { margin: 0 0 18px; color: var(--text-soft); line-height: 1.65; font-size: 14px; white-space: pre-wrap; text-align: left; }
.dlg-actions { display: flex; gap: 12px; justify-content: center; margin-top: 8px; }
.dlg-actions .btn { min-width: 92px; }
.btn-danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn-danger:hover { background: #b91c1c; border-color: #b91c1c; }
.dlg-input { width: 100%; padding: 11px 13px; border: 1px solid var(--border); border-radius: 8px; margin-bottom: 18px; }
.dlg-input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,235,.1); }
.dlg-options { max-height: 260px; overflow-y: auto; margin: -4px 0 18px; text-align: left; }
.dlg-option { width: 100%; display: flex; align-items: center; gap: 10px; padding: 11px 13px; margin-bottom: 6px;
border: 1px solid var(--border); border-radius: 8px; background: #fff; text-align: left; }
.dlg-option:hover { border-color: var(--primary); background: var(--primary-light); }
.dlg-option.active { border-color: var(--primary); background: var(--primary-light); }
.radio-dot { width: 16px; height: 16px; border: 2px solid #cbd5e1; border-radius: 50%; flex-shrink: 0; position: relative; }
.dlg-option.active .radio-dot { border-color: var(--primary); }
.dlg-option.active .radio-dot::after { content: ''; position: absolute; inset: 3px; background: var(--primary); border-radius: 50%; }
.dlg-option-label { flex: 1; font-weight: 500; }
.dlg-option small { color: var(--text-mute); }
.toast-stack { position: fixed; top: 20px; left: 50%; transform: translateX(-50%); z-index: 300;
display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast { display: flex; align-items: center; gap: 9px; background: #fff; border: 1px solid var(--border);
border-radius: 9px; padding: 11px 18px; box-shadow: 0 8px 24px rgba(0,0,0,.12); font-size: 14px;
animation: toastIn .3s var(--ease); }
@keyframes toastIn { from { opacity: 0; transform: translateY(-12px) scale(.96) } to { opacity: 1; transform: none } }
.toast-icon { width: 20px; height: 20px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
color: #fff; font-size: 13px; font-weight: 700; flex-shrink: 0; }
.toast-success .toast-icon { background: var(--success); }
.toast-error .toast-icon { background: var(--danger); }
.toast-info .toast-icon { background: var(--primary); }
/* ---------- 批量选择 ---------- */
.check-col { width: 38px; text-align: center; }
.row-check { width: 16px; height: 16px; cursor: pointer; accent-color: var(--primary); }
.batch-bar { display: flex; align-items: center; gap: 10px; padding: 10px 16px;
background: var(--primary-light); border-bottom: 1px solid #dbeafe; font-size: 13px; }
.batch-bar b { color: var(--primary); }
.batch-bar .btn { padding: 5px 12px; font-size: 13px; }
.table tbody tr.row-selected { background: #eff6ff; }
.table tbody tr.row-selected:hover { background: #dbeafe; }
/* ---------- 云端备份 ---------- */
.restore-source { display: flex; align-items: center; justify-content: space-between; gap: 16px;
padding: 14px 0; border-bottom: 1px solid var(--border); }
.restore-source b { font-size: 14px; }
.cloud-list { margin-top: 16px; }
.cloud-item { display: flex; align-items: center; gap: 12px; padding: 11px 14px; margin-bottom: 8px;
border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.cloud-item .btn { margin-left: auto; }
.cloud-file { font-family: var(--font-mono); font-size: 13px; }
.preview-card { margin-top: 16px; border: 1px solid var(--border); border-radius: 10px; padding: 18px; background: #fafbfc; }
.preview-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.preview-head b { font-size: 14px; }
.preview-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 14px; }
.preview-stats > div { background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; font-size: 12px; color: var(--text-soft); }
.preview-stats b { display: block; font-size: 20px; color: var(--text); margin-top: 4px; }
.preview-groups { background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 12px 14px; margin-bottom: 16px; }
.group-line { padding: 5px 0; font-size: 13px; }
.restore-panel { border-top: 1px solid var(--border); padding-top: 14px; }
.scope-options { display: flex; flex-direction: column; gap: 8px; }
.scope-opt { display: flex !important; align-items: center; gap: 9px; padding: 10px 12px; margin: 0 !important;
border: 1px solid var(--border); border-radius: 8px; background: #fff; cursor: pointer; font-size: 13px; }
.scope-opt:hover { border-color: var(--primary); }
.scope-opt.active { border-color: var(--primary); background: var(--primary-light); }
.scope-opt input { width: auto; margin: 0; }
.owner-picker { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; padding: 12px;
background: #fff; border: 1px solid var(--border); border-radius: 8px; margin-top: 8px; }
.owner-picker .check-item { padding: 6px 0; }
@media (max-width: 768px) { .preview-stats { grid-template-columns: repeat(2, 1fr); } .owner-picker { grid-template-columns: 1fr; } }
/* ---------- 跟进状态标识 / 每页条数 ---------- */
.follow-tag { display: inline-block; padding: 3px 9px; border-radius: 12px; font-size: 12px; white-space: nowrap; }
.follow-tag.followed { background: #dcfce7; color: #15803d; }
.follow-tag.never { background: #fee2e2; color: #b91c1c; font-weight: 500; }
.stat-never { border-top: 3px solid var(--danger); }
.page-size { display: inline-flex; align-items: center; gap: 6px; color: var(--text-soft); }
.page-size select { padding: 4px 8px; border: 1px solid var(--border); border-radius: 5px; background: #fff; color: var(--text); }
/* ---------- 公海资源池 ---------- */
.pool-tabs { display: flex; flex-wrap: wrap; gap: 6px; padding: 12px 16px 0; border-bottom: 1px solid var(--border); }
.pool-tab { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border: 1px solid transparent; border-bottom: none; background: transparent; color: var(--text-soft); cursor: pointer; border-radius: 6px 6px 0 0; font-size: 13px; }
.pool-tab:hover { background: rgba(0,0,0,.03); }
.pool-tab.active { background: #fff; border-color: var(--border); color: var(--primary); font-weight: 600; margin-bottom: -1px; }
.pool-tab-count { background: var(--bg); border-radius: 10px; padding: 1px 7px; font-size: 11px; color: var(--text-soft); }
.pool-tab.active .pool-tab-count { background: rgba(59,130,246,.12); color: var(--primary); }
.pool-tab.pool-manage { margin-left: auto; color: var(--primary); }
.pool-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 5px; vertical-align: middle; }
.pool-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.pool-mini-tag { display: inline-block; padding: 1px 7px; border: 1px solid var(--border); border-left-width: 3px; border-radius: 4px; font-size: 11px; color: var(--text); white-space: nowrap; }
.pool-form input[type=color] { padding: 2px 4px; height: 36px; }
.import-target { margin: 14px 0; padding: 12px; background: var(--bg); border-radius: 6px; }
.target-line { display: flex; align-items: center; gap: 10px; margin: 6px 0; font-size: 13px; }
.target-line input[type=checkbox] { width: 16px; height: 16px; }
.target-line .hint { font-weight: normal; }
.target-line select { padding: 5px 8px; border: 1px solid var(--border); border-radius: 5px; background: #fff; color: var(--text); }
.pool-perm { margin-top: 14px; padding: 12px; border: 1px solid var(--border); border-radius: 6px; }
.pool-perm-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; font-size: 13px; }
.pool-perm-actions { margin-left: auto; display: flex; gap: 12px; }
.pool-perm-list { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.pool-check { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; cursor: pointer; }
.pool-check input { width: 15px; height: 15px; }
/* ---------- 用户级权限覆盖 ---------- */
.perm-override { margin-top: 12px; padding: 12px; border: 1px solid var(--border); border-radius: 6px; }
.perm-override select { padding: 6px 10px; width: 100%; border: 1px solid var(--border); border-radius: 5px; background: #fff; color: var(--text); }
.perm-mode { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-bottom: 8px; }
.perm-mode .hint { margin-left: auto; }
.override-tag { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 10px; font-size: 11px; background: #fef3c7; color: #92400e; }
/* ================= 上传界面(拖拽区 / 文件卡片 / 进度) ================= */
.stepper { display: flex; align-items: center; justify-content: center; gap: 10px; padding: 16px 22px 0; }
.step { display: flex; align-items: center; gap: 7px; font-size: 13px; color: var(--text-mute); }
.step.active { color: var(--primary); font-weight: 600; }
.step.done { color: var(--success); }
.step-num { width: 22px; height: 22px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
background: #f3f4f6; color: var(--text-soft); font-size: 12px; font-weight: 600; }
.step.active .step-num { background: var(--primary); color: #fff; }
.step.done .step-num { background: var(--success); color: #fff; }
.step-line { width: 60px; height: 2px; background: var(--border); border-radius: 2px; }
.dropzone { position: relative; margin: 4px 0 10px; padding: 30px 20px; border: 2px dashed #cbd5e1; border-radius: 12px;
background: #fafbfe; text-align: center; cursor: pointer; transition: all var(--t) var(--ease); overflow: hidden; }
.dropzone:hover, .dropzone.dragging { border-color: var(--primary); background: var(--primary-light); transform: translateY(-1px); }
.dropzone.dragging { box-shadow: 0 0 0 4px rgba(37,99,235,.1); }
.dropzone.has-file { padding: 16px 20px; border-style: solid; border-color: var(--border); background: #fff; }
.drop-icon { font-size: 34px; color: var(--primary); line-height: 1; margin-bottom: 8px; animation: floaty 2.5s ease-in-out infinite; }
@keyframes floaty { 0%,100% { transform: translateY(0) } 50% { transform: translateY(-5px) } }
.drop-title { font-size: 14px; font-weight: 600; color: var(--text); }
.drop-sub { font-size: 12px; color: var(--text-mute); margin-top: 5px; }
.dropzone-sm { padding: 20px; margin: 10px 0 16px; }
.dropzone-sm .drop-icon { font-size: 26px; }
.file-card { display: flex; align-items: center; gap: 14px; text-align: left; animation: dlgpop .25s var(--ease); }
.file-card-sm { padding: 2px 0; }
.file-icon { width: 42px; height: 42px; border-radius: 10px; background: var(--primary-light); color: var(--primary);
display: inline-flex; align-items: center; justify-content: center; font-size: 22px; flex-shrink: 0; }
.file-meta { flex: 1; min-width: 0; }
.file-meta b { display: block; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-meta span { font-size: 12px; color: var(--text-mute); }
.progress-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: #e5e7eb; overflow: hidden; }
.progress-bar span { display: block; height: 100%; width: 40%; background: var(--primary); border-radius: 3px;
animation: progress 1.1s var(--ease) infinite; }
@keyframes progress { 0% { transform: translateX(-100%) } 100% { transform: translateX(350%) } }
.import-toolrow { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 12px; }
.import-toolrow .hint { margin: 0; flex: 1; min-width: 200px; }
.mini-stats { display: flex; gap: 10px; flex-wrap: wrap; }
.mini-stat { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 8px 14px; min-width: 86px; }
.mini-stat span { display: block; font-size: 11px; color: var(--text-soft); }
.mini-stat b { font-size: 19px; }
.mini-stat.ok { border-color: #bbf7d0; background: #f0fdf4; }
.mini-stat.ok b { color: var(--success); }
.mini-stat.warn { border-color: #fde68a; background: #fffbeb; }
.mini-stat.warn b { color: var(--warn); }
.import-summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
/* ================= 响应式自适应 ================= */
/* 平板横屏:统计卡 4 列、侧栏收窄 */
@media (max-width: 1400px) {
.stat-row { grid-template-columns: repeat(4, 1fr); }
}
/* 平板竖屏:侧栏折叠为图标、统计卡 3 列 */
@media (max-width: 1100px) {
.stat-row { grid-template-columns: repeat(3, 1fr); }
.sidebar { width: 68px; }
.brand { padding: 18px 12px; justify-content: center; }
.brand-text, .side-stat, .nav-item span:not(.nav-icon) { display: none; }
.nav-item { justify-content: center; padding: 12px; }
.nav-icon { font-size: 20px; width: auto; }
.sidebar-foot { padding: 12px; text-align: center; }
.content { padding: 18px; }
.topbar { padding: 0 18px; }
}
/* 小平板:统计卡 2 列、表单单列 */
@media (max-width: 900px) {
.stat-row { grid-template-columns: repeat(2, 1fr); }
.form-grid, .perm-grid { grid-template-columns: 1fr; }
.modal { max-height: 92vh; }
}
/* 手机:侧栏变顶部横条、表格横向滚动、弹窗全宽 */
@media (max-width: 768px) {
.app-shell { flex-direction: column; }
.sidebar { width: 100%; height: auto; flex-direction: row; align-items: center; flex-wrap: wrap; }
.brand { border-bottom: 0; padding: 10px 14px; }
.brand-text { display: block; }
.nav { display: flex; gap: 4px; padding: 6px 10px; overflow-x: auto; flex: 1; }
.nav-item { width: auto; margin: 0; padding: 8px 12px; white-space: nowrap; }
.nav-item span:not(.nav-icon) { display: inline; }
.sidebar-foot { display: none; }
.topbar { height: auto; padding: 12px 16px; gap: 8px; flex-wrap: wrap; }
.user-badge .user-info { display: none; }
.content { padding: 14px 12px 30px; }
.stat-card { padding: 12px 14px; }
.stat-card b { font-size: 22px; }
.toolbar { padding: 12px; gap: 8px; }
.toolbar input.search { width: 100%; }
.toolbar select { flex: 1; min-width: 120px; }
.table th, .table td { padding: 9px 10px; font-size: 13px; }
.table { min-width: 640px; } /* 强制横向滚动,避免列被挤压 */
.pagination { flex-wrap: wrap; justify-content: center; }
.modal { width: 96%; max-height: 94vh; }
.modal-body { padding: 16px; }
.modal-head { padding: 14px 16px; }
.drawer { max-width: 100%; }
.step-line { width: 30px; }
.import-summary { flex-direction: column; align-items: stretch; }
.preview-stats { grid-template-columns: repeat(2, 1fr); }
.restore-source { flex-direction: column; align-items: flex-start; }
.setting-item { flex-wrap: wrap; }
.row-actions { gap: 8px; }
}
/* 小屏手机 */
@media (max-width: 480px) {
.stat-row { grid-template-columns: repeat(2, 1fr); gap: 8px; }
.brand-text small { display: none; }
.topbar-title { font-size: 15px; }
.btn { padding: 8px 12px; }
.btn-sm { padding: 4px 9px; font-size: 12px; }
.mini-stat { flex: 1; min-width: 70px; }
.stepper { padding: 12px 14px 0; }
.step { font-size: 12px; }
.dropzone { padding: 22px 12px; }
}
/* 减少动画偏好:尊重系统设置 */
@media (prefers-reduced-motion: reduce) {
*, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important;
transition-duration: .01ms !important; }
}