/* ============================================================
   文成县项目六到位管控平台 · 样式
   浅色清爽管理风 / 手机电脑自适应
   ============================================================ */
* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
  --bg: #f3f6fa;
  --card: #ffffff;
  --line: #e6ecf3;
  --line-2: #d5dee9;
  --ink: #1e2a3a;
  --ink-2: #5b6b7f;
  --ink-3: #8a99ab;
  --blue: #1e6fd9;
  --blue-deep: #14539f;
  --blue-soft: #e8f1fd;
  --green: #16a34a;
  --green-soft: #e7f7ee;
  --orange: #e8890c;
  --orange-soft: #fdf3e2;
  --red: #d93636;
  --red-soft: #fdeaea;
  --purple: #7c3aed;
  --purple-soft: #f1eafd;
  --cyan: #0891b2;
  --gray-soft: #eef2f7;
  --shadow: 0 1px 2px rgba(23, 43, 77, .04), 0 6px 18px rgba(23, 43, 77, .05);
  --shadow-lg: 0 18px 50px rgba(23, 43, 77, .18);
  --radius: 14px;
  --font: 'PingFang SC', 'Microsoft YaHei', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
html, body { height: 100%; }
body {
  font-family: var(--font); background: var(--bg); color: var(--ink);
  font-size: 14px; line-height: 1.6; -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }
button { cursor: pointer; border: none; background: none; }
a { color: var(--blue); text-decoration: none; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: #cfd9e4; border-radius: 8px; }
::-webkit-scrollbar-track { background: transparent; }

/* ================= 登录页 ================= */
.login-page { min-height: 100vh; display: flex; }
.login-brand {
  flex: 1.15; background: linear-gradient(145deg, #0d3d7a 0%, #14539f 45%, #1e6fd9 100%);
  color: #fff; padding: 56px 64px; display: flex; flex-direction: column; justify-content: center;
  position: relative; overflow: hidden;
}
.login-brand::before, .login-brand::after {
  content: ''; position: absolute; border-radius: 50%; border: 1px solid rgba(255,255,255,.12);
}
.login-brand::before { width: 620px; height: 620px; right: -220px; top: -220px; }
.login-brand::after { width: 420px; height: 420px; right: -100px; bottom: -180px; }
.brand-badge { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; letter-spacing: 1px; opacity: .85; margin-bottom: 26px; }
.brand-badge i { width: 26px; height: 26px; border-radius: 8px; background: rgba(255,255,255,.18); display: inline-flex; align-items: center; justify-content: center; font-style: normal; font-weight: 700; }
.login-brand h1 { font-size: 36px; line-height: 1.35; font-weight: 700; letter-spacing: 1px; margin-bottom: 16px; }
.login-brand p { font-size: 15px; line-height: 1.9; opacity: .78; max-width: 460px; }
.brand-stages { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 38px; max-width: 520px; }
.brand-stage {
  background: rgba(255,255,255,.09); border: 1px solid rgba(255,255,255,.14); border-radius: 12px;
  padding: 13px 14px; backdrop-filter: blur(6px);
}
.brand-stage b { display: block; font-size: 14px; margin-bottom: 3px; }
.brand-stage span { font-size: 11px; opacity: .6; }
.login-panel { flex: 1; display: flex; align-items: center; justify-content: center; padding: 40px 24px; background: var(--bg); }
.login-card { width: 100%; max-width: 400px; background: var(--card); border-radius: 20px; padding: 40px 36px 32px; box-shadow: var(--shadow-lg); border: 1px solid rgba(255,255,255,.8); }
.login-card h2 { font-size: 22px; font-weight: 700; margin-bottom: 6px; }
.login-card .sub { color: var(--ink-3); font-size: 13px; margin-bottom: 28px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-size: 13px; color: var(--ink-2); margin-bottom: 7px; font-weight: 500; }
.input, .select, .textarea {
  width: 100%; border: 1px solid var(--line-2); background: #fbfcfe; border-radius: 10px;
  padding: 10px 13px; outline: none; transition: .18s; font-size: 14px;
}
.input:focus, .select:focus, .textarea:focus { border-color: var(--blue); background: #fff; box-shadow: 0 0 0 3px rgba(30,111,217,.1); }
.textarea { min-height: 84px; resize: vertical; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 38px; padding: 0 16px; border-radius: 9px; font-size: 14px; font-weight: 500;
  background: var(--gray-soft); color: var(--ink-2); transition: .18s; white-space: nowrap;
}
.btn:hover { background: #e2e9f2; }
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-deep); }
.btn-danger { background: var(--red-soft); color: var(--red); }
.btn-danger:hover { background: #fbd5d5; }
.btn-success { background: var(--green); color: #fff; }
.btn-success:hover { background: #128a3e; }
.btn-ghost { background: transparent; border: 1px solid var(--line-2); }
.btn-sm { height: 30px; padding: 0 11px; font-size: 12.5px; border-radius: 8px; }
.btn-block { width: 100%; height: 44px; font-size: 15px; }
.login-error { background: var(--red-soft); color: var(--red); font-size: 13px; padding: 9px 12px; border-radius: 9px; margin-bottom: 14px; }
.demo-accounts { margin-top: 26px; border-top: 1px dashed var(--line-2); padding-top: 20px; }
.demo-accounts h4 { font-size: 12px; color: var(--ink-3); font-weight: 500; margin-bottom: 10px; letter-spacing: .5px; }
.quick-users { display: flex; flex-wrap: wrap; gap: 8px; }
.quick-user {
  display: flex; align-items: center; gap: 7px; padding: 6px 10px 6px 7px; border-radius: 20px;
  border: 1px solid var(--line); background: #fbfcfe; font-size: 12px; color: var(--ink-2); transition: .15s;
}
.quick-user:hover { border-color: var(--blue); color: var(--blue); background: var(--blue-soft); }
.quick-user .avatar { width: 20px; height: 20px; font-size: 10px; }
.login-foot { margin-top: 20px; text-align: center; font-size: 12px; color: var(--ink-3); }

/* ================= 布局 ================= */
.app-shell { min-height: 100vh; }
.sidebar {
  position: fixed; left: 0; top: 0; bottom: 0; width: 216px; background: #fff;
  border-right: 1px solid var(--line); display: flex; flex-direction: column; z-index: 50;
}
.side-brand { padding: 22px 20px 18px; display: flex; align-items: center; gap: 10px; border-bottom: 1px solid var(--line); }
.side-logo {
  width: 36px; height: 36px; border-radius: 11px; background: linear-gradient(135deg, #1e6fd9, #14539f);
  color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 15px; flex-shrink: 0;
}
.side-brand b { display: block; font-size: 14px; line-height: 1.3; }
.side-brand span { display: block; font-size: 10.5px; color: var(--ink-3); margin-top: 2px; }
.side-menu { flex: 1; padding: 14px 12px; overflow-y: auto; }
.side-group { font-size: 10.5px; color: var(--ink-3); letter-spacing: 1px; padding: 10px 10px 6px; }
.side-item {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px;
  color: var(--ink-2); font-size: 13.5px; margin-bottom: 3px; transition: .16s; position: relative;
}
.side-item:hover { background: #f4f7fb; color: var(--ink); }
.side-item.active { background: var(--blue-soft); color: var(--blue); font-weight: 600; }
.side-item .ico { width: 18px; text-align: center; font-size: 15px; }
.side-item .num {
  margin-left: auto; background: var(--red); color: #fff; font-size: 10px; min-width: 17px; height: 17px;
  border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; padding: 0 5px; font-weight: 600;
}
.side-foot { padding: 14px 16px; border-top: 1px solid var(--line); font-size: 11px; color: var(--ink-3); }
.side-user { display: flex; align-items: center; gap: 10px; padding: 10px 8px; border-radius: 10px; }
.side-user:hover { background: #f4f7fb; }
.avatar {
  width: 32px; height: 32px; border-radius: 50%; background: linear-gradient(135deg, #5b9be8, #1e6fd9);
  color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 600; flex-shrink: 0;
}
.avatar.leader { background: linear-gradient(135deg, #8b5cf6, #6d28d9); }
.avatar.business { background: linear-gradient(135deg, #2e9be6, #146ba8); }
.avatar.contact { background: linear-gradient(135deg, #34b98a, #15805b); }
.side-user-info { min-width: 0; }
.side-user-info b { display: block; font-size: 13px; }
.side-user-info span { display: block; font-size: 10.5px; color: var(--ink-3); }

.main { margin-left: 216px; min-height: 100vh; }
.topbar {
  height: 62px; background: rgba(255,255,255,.88); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 14px;
  padding: 0 26px; position: sticky; top: 0; z-index: 40;
}
.topbar-title { font-size: 16px; font-weight: 600; }
.topbar-sub { font-size: 12px; color: var(--ink-3); margin-left: 2px; }
.topbar-spacer { flex: 1; }
.topbar-date { font-size: 12px; color: var(--ink-3); }
.icon-btn {
  width: 36px; height: 36px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center;
  color: var(--ink-2); font-size: 17px; position: relative; transition: .15s;
}
.icon-btn:hover { background: #eef2f8; color: var(--ink); }
.icon-btn .dot {
  position: absolute; top: 6px; right: 6px; min-width: 16px; height: 16px; border-radius: 8px;
  background: var(--red); color: #fff; font-size: 9.5px; display: flex; align-items: center; justify-content: center;
  padding: 0 4px; border: 2px solid #fff; font-weight: 600;
}
.user-chip { display: flex; align-items: center; gap: 9px; padding: 5px 10px 5px 5px; border-radius: 20px; }
.user-chip:hover { background: #eef2f8; }
.user-chip b { font-size: 13px; }
.user-chip span { font-size: 11px; color: var(--ink-3); }

.page { padding: 24px 26px 40px; max-width: 1440px; margin: 0 auto; }
.page-head { display: flex; align-items: flex-end; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head h2 { font-size: 20px; font-weight: 700; letter-spacing: .2px; }
.page-head p { font-size: 12.5px; color: var(--ink-3); }
.page-head .grow { flex: 1; }
.demo-banner {
  background: #fff8e8; border: 1px solid #f5e2b8; color: #8a6212; font-size: 12px;
  border-radius: 10px; padding: 8px 13px; margin-bottom: 16px; display: flex; align-items: center; gap: 8px;
}

/* ================= 通用组件 ================= */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card-pad { padding: 20px; }
.card-head { display: flex; align-items: center; gap: 10px; padding: 17px 20px 13px; }
.card-head h3 { font-size: 15px; font-weight: 600; }
.card-head .sub { font-size: 11.5px; color: var(--ink-3); }
.card-head .grow { flex: 1; }
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.mt-16 { margin-top: 16px; } .mt-20 { margin-top: 20px; } .mt-24 { margin-top: 24px; }
.mb-12 { margin-bottom: 12px; }
.muted { color: var(--ink-3); font-size: 12.5px; }
.empty { padding: 44px 20px; text-align: center; color: var(--ink-3); font-size: 13px; }
.empty .big { font-size: 30px; margin-bottom: 10px; opacity: .45; }

.badge {
  display: inline-flex; align-items: center; gap: 4px; height: 23px; padding: 0 9px; border-radius: 6px;
  font-size: 11.5px; font-weight: 500; background: var(--gray-soft); color: var(--ink-2); white-space: nowrap;
}
.badge.blue { background: var(--blue-soft); color: var(--blue); }
.badge.green { background: var(--green-soft); color: var(--green); }
.badge.orange { background: var(--orange-soft); color: var(--orange); }
.badge.red { background: var(--red-soft); color: var(--red); }
.badge.purple { background: var(--purple-soft); color: var(--purple); }
.badge.gray { background: var(--gray-soft); color: var(--ink-3); }
.badge .pulse { width: 6px; height: 6px; border-radius: 50%; background: currentColor; animation: pulse 1.6s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: .35; transform: scale(.8); } }

.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }
.toolbar .input, .toolbar .select { width: auto; min-width: 130px; height: 36px; padding: 0 12px; font-size: 13px; }
.toolbar .search { min-width: 220px; }
.toolbar .grow { flex: 1; }

/* ================= 指标卡 ================= */
.metric {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px;
  box-shadow: var(--shadow); display: flex; align-items: flex-start; gap: 14px;
}
.metric-ico {
  width: 42px; height: 42px; border-radius: 12px; display: flex; align-items: center; justify-content: center;
  font-size: 19px; flex-shrink: 0;
}
.metric-ico.blue { background: var(--blue-soft); }
.metric-ico.green { background: var(--green-soft); }
.metric-ico.orange { background: var(--orange-soft); }
.metric-ico.red { background: var(--red-soft); }
.metric-ico.purple { background: var(--purple-soft); }
.metric-body { min-width: 0; }
.metric-body .val { font-size: 26px; font-weight: 700; line-height: 1.15; letter-spacing: -.5px; }
.metric-body .val small { font-size: 13px; font-weight: 500; color: var(--ink-3); margin-left: 2px; }
.metric-body .lbl { font-size: 12; color: var(--ink-3); margin-top: 3px; font-size: 12px; }
.metric-body .trend { font-size: 11px; margin-top: 4px; color: var(--green); }

.progress { height: 7px; background: #edf1f6; border-radius: 5px; overflow: hidden; }
.progress > i { display: block; height: 100%; border-radius: 5px; background: var(--blue); transition: width .4s; }
.progress.green > i { background: var(--green); }
.progress.orange > i { background: var(--orange); }
.progress.red > i { background: var(--red); }

/* 六到位小灯 */
.lamps { display: inline-flex; gap: 3px; align-items: center; }
.lamp { width: 9px; height: 9px; border-radius: 3px; background: #e3e9f0; }
.lamp.done { background: var(--green); }
.lamp.doing { background: var(--orange); box-shadow: 0 0 0 2px rgba(232,137,12,.16); }
.lamp.pending { background: #dfe6ee; }

/* ================= 看板 ================= */
.rate-list { padding: 4px 20px 20px; }
.rate-row { display: flex; align-items: center; gap: 12px; padding: 9px 0; }
.rate-row .name { width: 96px; font-size: 12.5px; color: var(--ink-2); flex-shrink: 0; }
.rate-row .bar { flex: 1; }
.rate-row .num { width: 64px; text-align: right; font-size: 11.5px; color: var(--ink-3); flex-shrink: 0; font-variant-numeric: tabular-nums; }
.rate-row .num b { color: var(--ink); font-size: 12.5px; }

.rank-list { padding: 2px 8px 12px; }
.rank-row { display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: 10px; transition: .15s; cursor: pointer; }
.rank-row:hover { background: #f6f9fd; }
.rank-no {
  width: 22px; height: 22px; border-radius: 7px; background: #eef2f7; color: var(--ink-3);
  font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.rank-no.top1 { background: #fff1d6; color: #b7791f; }
.rank-no.top2 { background: #eef1f5; color: #6b7a8c; }
.rank-no.top3 { background: #fbe9e2; color: #b56538; }
.rank-main { flex: 1; min-width: 0; }
.rank-main .t { font-size: 13px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-main .s { font-size: 11px; color: var(--ink-3); margin-top: 2px; display: flex; align-items: center; gap: 8px; }
.rank-prog { width: 90px; flex-shrink: 0; text-align: right; }
.rank-prog b { font-size: 13px; }
.rank-prog span { display: block; font-size: 10.5px; color: var(--ink-3); }

.urgent-list { padding: 0 16px 16px; }
.urgent-card {
  border: 1px solid var(--line); border-left: 4px solid var(--orange); border-radius: 11px;
  padding: 13px 14px; margin-bottom: 10px; background: #fffdf9; cursor: pointer; transition: .15s;
}
.urgent-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.urgent-card.critical { border-left-color: var(--red); background: #fffbfb; }
.urgent-card .top { display: flex; align-items: center; gap: 8px; margin-bottom: 5px; }
.urgent-card .top b { font-size: 13px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.urgent-card .reason { font-size: 12px; color: var(--ink-2); line-height: 1.55; margin-bottom: 8px; }
.urgent-card .meta { display: flex; gap: 12px; font-size: 11px; color: var(--ink-3); flex-wrap: wrap; align-items: center; }

/* ================= 项目卡片列表 ================= */
.proj-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.proj-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px;
  box-shadow: var(--shadow); cursor: pointer; transition: .18s; position: relative; overflow: hidden;
  display: flex; flex-direction: column; min-height: 196px;
}
.proj-card:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(23,43,77,.1); border-color: #d6e2f1; }
.proj-card .accent { position: absolute; left: 0; top: 0; bottom: 0; width: 4px; }
.proj-card .top { display: flex; align-items: flex-start; gap: 8px; margin-bottom: 6px; }
.proj-card h4 { font-size: 14px; font-weight: 600; line-height: 1.5; flex: 1; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.proj-card .customer { font-size: 12px; color: var(--ink-3); margin-bottom: 10px; display: flex; align-items: center; gap: 6px; }
.proj-card .customer .amt { color: var(--ink-2); font-weight: 600; font-size: 12.5px; }
.proj-card .lamps-row { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.proj-card .lamps-row .txt { font-size: 11px; color: var(--ink-3); }
.proj-card .foot { margin-top: auto; display: flex; align-items: center; gap: 10px; }
.proj-card .foot .who { font-size: 11px; color: var(--ink-3); display: flex; align-items: center; gap: 5px; }
.proj-card .foot .avatar { width: 20px; height: 20px; font-size: 9px; }
.proj-card .prog { flex: 1; text-align: right; }
.proj-card .prog b { font-size: 12.5px; }
.proj-card .prog .progress { width: 70px; display: inline-block; vertical-align: middle; margin-left: 6px; height: 5px; }
.proj-card .urgent-flag { position: absolute; top: 0; right: 0; font-size: 10px; color: #fff; padding: 3px 9px; border-radius: 0 13px 0 10px; background: var(--orange); font-weight: 600; letter-spacing: .5px; }
.proj-card .urgent-flag.critical { background: var(--red); }

/* ================= 项目详情 ================= */
.detail-hero { padding: 22px 24px; }
.detail-hero .title-row { display: flex; align-items: flex-start; gap: 12px; flex-wrap: wrap; }
.detail-hero h2 { font-size: 21px; font-weight: 700; line-height: 1.45; flex: 1; min-width: 260px; }
.detail-hero .meta { display: flex; gap: 22px; flex-wrap: wrap; margin-top: 14px; }
.detail-hero .meta div { font-size: 12px; color: var(--ink-3); }
.detail-hero .meta b { display: block; font-size: 14px; color: var(--ink); margin-top: 2px; font-weight: 600; }
.detail-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.stage-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.stage-card { border: 1px solid var(--line); border-radius: 12px; padding: 0; overflow: hidden; background: #fff; }
.stage-card .bar { height: 4px; }
.stage-card .inner { padding: 13px 14px 14px; }
.stage-card .head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.stage-card .head b { font-size: 13.5px; flex: 1; }
.stage-card .kv { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--ink-3); padding: 2.5px 0; gap: 8px; }
.stage-card .kv span:last-child { color: var(--ink-2); text-align: right; }
.stage-card .note { font-size: 11.5px; color: var(--ink-2); background: #f8fafc; border-radius: 8px; padding: 7px 9px; margin-top: 8px; line-height: 1.55; }
.stage-card .ops { display: flex; gap: 6px; margin-top: 10px; flex-wrap: wrap; }
.stage-card.pending { opacity: .82; }

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); padding: 0 20px; overflow-x: auto; }
.tab { padding: 12px 14px; font-size: 13.5px; color: var(--ink-3); border-bottom: 2px solid transparent; white-space: nowrap; transition: .15s; }
.tab:hover { color: var(--ink); }
.tab.active { color: var(--blue); border-bottom-color: var(--blue); font-weight: 600; }
.tab .cnt { font-size: 10.5px; background: var(--gray-soft); border-radius: 8px; padding: 1px 6px; margin-left: 5px; color: var(--ink-3); }
.tab.active .cnt { background: var(--blue-soft); color: var(--blue); }

.timeline { padding: 18px 20px; }
.tl-item { display: flex; gap: 12px; position: relative; padding-bottom: 18px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before { content: ''; position: absolute; left: 5px; top: 16px; bottom: 0; width: 1px; background: var(--line-2); }
.tl-item:last-child::before { display: none; }
.tl-dot { width: 11px; height: 11px; border-radius: 50%; background: var(--blue); margin-top: 5px; flex-shrink: 0; box-shadow: 0 0 0 3px var(--blue-soft); z-index: 1; }
.tl-body { flex: 1; min-width: 0; }
.tl-body .t { font-size: 13px; line-height: 1.6; }
.tl-body .m { font-size: 11px; color: var(--ink-3); margin-top: 2px; display: flex; gap: 10px; flex-wrap: wrap; }

.doc-row { display: flex; align-items: center; gap: 12px; padding: 12px 20px; border-bottom: 1px solid #f2f5f9; }
.doc-row:last-child { border-bottom: none; }
.doc-ico { width: 36px; height: 36px; border-radius: 9px; background: var(--blue-soft); display: flex; align-items: center; justify-content: center; font-size: 16px; flex-shrink: 0; }
.doc-main { flex: 1; min-width: 0; }
.doc-main .n { font-size: 13px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.doc-main .m { font-size: 11px; color: var(--ink-3); margin-top: 2px; display: flex; gap: 10px; flex-wrap: wrap; }
.doc-side { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }

/* ================= 甘特图 ================= */
.gantt-wrap { overflow: auto; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow); }
.gantt { min-width: 900px; }
.gantt-head { display: flex; position: sticky; top: 0; z-index: 5; background: #fbfcfe; border-bottom: 1px solid var(--line); }
.gantt-name-col { width: 250px; flex-shrink: 0; padding: 12px 14px; font-size: 12px; color: var(--ink-3); border-right: 1px solid var(--line); position: sticky; left: 0; background: #fbfcfe; z-index: 6; }
.gantt-months { display: flex; flex: 1; }
.gantt-month { width: 92px; flex-shrink: 0; text-align: center; font-size: 11px; color: var(--ink-3); padding: 12px 0; border-right: 1px solid #f0f4f8; }
.gantt-month b { display: block; font-size: 11px; color: var(--ink-2); font-weight: 600; }
.gantt-row { display: flex; border-bottom: 1px solid #f2f5f9; }
.gantt-row:hover { background: #fafcff; }
.gantt-row .gantt-name-col { background: #fff; }
.gantt-row:hover .gantt-name-col { background: #fafcff; }
.gantt-name-col .pn { font-size: 12.5px; font-weight: 500; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.gantt-name-col .ps { font-size: 10.5px; color: var(--ink-3); margin-top: 3px; display: flex; align-items: center; gap: 6px; }
.gantt-track { position: relative; flex: 1; height: 52px; background-image: linear-gradient(to right, #f0f4f8 1px, transparent 1px); background-size: 92px 100%; overflow: hidden; }
.gantt-bar {
  position: absolute; top: 13px; height: 26px; border-radius: 6px; opacity: .95;
  display: flex; align-items: center; padding: 0 7px; font-size: 10px; color: #fff; white-space: nowrap; overflow: hidden;
  cursor: pointer; transition: .15s; box-shadow: 0 1px 4px rgba(23,43,77,.12);
}
.gantt-bar:hover { transform: translateY(-1px); box-shadow: 0 4px 10px rgba(23,43,77,.2); z-index: 3; }
.gantt-bar.done { opacity: 1; }
.gantt-bar.doing { background-image: linear-gradient(45deg, rgba(255,255,255,.18) 25%, transparent 25%, transparent 50%, rgba(255,255,255,.18) 50%, rgba(255,255,255,.18) 75%, transparent 75%, transparent); background-size: 14px 14px; }
.gantt-bar.pending { opacity: .55; }
.gantt-bar.now { outline: 2px solid #fff; box-shadow: 0 0 0 2px rgba(30,111,217,.35); }
.gantt-today { position: absolute; top: 0; bottom: 0; width: 2px; background: var(--red); z-index: 4; opacity: .75; }
.gantt-legend { display: flex; gap: 18px; padding: 12px 16px; font-size: 11.5px; color: var(--ink-3); flex-wrap: wrap; align-items: center; }
.gantt-legend i { display: inline-block; width: 14px; height: 8px; border-radius: 3px; margin-right: 5px; vertical-align: middle; }

/* ================= 表格 ================= */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 13px; }
.table th { text-align: left; font-size: 11.5px; color: var(--ink-3); font-weight: 500; padding: 11px 14px; border-bottom: 1px solid var(--line); background: #fbfcfe; white-space: nowrap; }
.table td { padding: 12px 14px; border-bottom: 1px solid #f2f5f9; vertical-align: middle; }
.table tr:last-child td { border-bottom: none; }
.table tbody tr:hover { background: #fafcff; }
.table .actions { display: flex; gap: 6px; justify-content: flex-end; }

/* ================= 弹窗 ================= */
.modal-mask {
  position: fixed; inset: 0; background: rgba(15, 30, 50, .45); backdrop-filter: blur(3px);
  z-index: 200; display: flex; align-items: center; justify-content: center; padding: 20px;
}
.modal {
  width: 100%; max-width: 560px; background: #fff; border-radius: 16px; box-shadow: var(--shadow-lg);
  max-height: calc(100vh - 40px); display: flex; flex-direction: column; animation: pop .2s ease;
}
@keyframes pop { from { opacity: 0; transform: translateY(12px) scale(.985); } to { opacity: 1; transform: none; } }
.modal-head { padding: 20px 24px 12px; display: flex; align-items: center; gap: 10px; border-bottom: 1px solid var(--line); }
.modal-head h3 { font-size: 17px; font-weight: 700; flex: 1; }
.modal-body { padding: 20px 24px; overflow-y: auto; }
.modal-foot { padding: 14px 24px 20px; display: flex; justify-content: flex-end; gap: 9px; border-top: 1px solid var(--line); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-grid .full { grid-column: 1 / -1; }
.form-hint { font-size: 11.5px; color: var(--ink-3); margin-top: 5px; }

/* ================= 消息 ================= */
.msg-row { display: flex; gap: 13px; padding: 15px 20px; border-bottom: 1px solid #f2f5f9; cursor: pointer; transition: .15s; }
.msg-row:hover { background: #fafcff; }
.msg-row.unread { background: #f7faff; }
.msg-row.unread:hover { background: #f0f7ff; }
.msg-ico { width: 36px; height: 36px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 16px; flex-shrink: 0; }
.msg-ico.urgent { background: var(--red-soft); }
.msg-ico.doc { background: var(--blue-soft); }
.msg-ico.progress { background: var(--green-soft); }
.msg-ico.system { background: var(--purple-soft); }
.msg-main { flex: 1; min-width: 0; }
.msg-main .t { font-size: 13px; font-weight: 500; display: flex; align-items: center; gap: 7px; }
.msg-main .t .new { width: 7px; height: 7px; border-radius: 50%; background: var(--red); flex-shrink: 0; }
.msg-main .c { font-size: 12px; color: var(--ink-2); margin-top: 3px; line-height: 1.55; }
.msg-main .m { font-size: 11px; color: var(--ink-3); margin-top: 5px; }

/* ================= 我的 ================= */
.profile-head { display: flex; align-items: center; gap: 16px; padding: 24px; }
.profile-head .avatar { width: 58px; height: 58px; font-size: 21px; }
.profile-head h2 { font-size: 20px; }
.profile-head p { font-size: 12.5px; color: var(--ink-3); margin-top: 3px; }
.menu-list { padding: 6px 0 12px; }
.menu-item { display: flex; align-items: center; gap: 12px; padding: 14px 22px; border-bottom: 1px solid #f2f5f9; font-size: 13.5px; transition: .15s; cursor: pointer; }
.menu-item:hover { background: #fafcff; }
.menu-item .ico { width: 30px; height: 30px; border-radius: 9px; background: var(--blue-soft); display: flex; align-items: center; justify-content: center; font-size: 14px; }
.menu-item .arrow { margin-left: auto; color: var(--ink-3); }

/* ================= Toast ================= */
.toast {
  position: fixed; left: 50%; bottom: 34px; transform: translateX(-50%); z-index: 300;
  background: #1e2a3a; color: #fff; padding: 11px 20px; border-radius: 10px; font-size: 13px;
  box-shadow: 0 10px 30px rgba(0,0,0,.25); animation: toastIn .25s ease; max-width: calc(100vw - 40px);
}
.toast.success { background: #146c43; }
.toast.error { background: #a52a2a; }
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, 10px); } to { opacity: 1; transform: translate(-50%, 0); } }

/* ================= 补充 ================= */
.dash-cols { display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px; align-items: start; }
.form-grid .field { margin-bottom: 0; }
.mt-12 { margin-top: 12px; }
.mt-item { position: relative; }
.side-menu::-webkit-scrollbar { width: 4px; }

/* ================= 手机端 ================= */
.mobile-tab { display: none; }
@media (max-width: 1100px) {
  .dash-cols { grid-template-columns: 1fr; }
}

/* ================= 领导端清单（v1.1） ================= */
.plist { display: flex; flex-direction: column; gap: 10px; }
.plist-item {
  position: relative; display: flex; background: var(--card); border: 1px solid var(--line);
  border-radius: 13px; box-shadow: var(--shadow); padding: 15px 18px 13px 24px; cursor: pointer; transition: .16s;
}
.plist-item:hover { transform: translateY(-1px); box-shadow: 0 8px 22px rgba(23, 43, 77, .09); border-color: #d6e2f1; }
.plist-item .accent { position: absolute; left: 0; top: 10px; bottom: 10px; width: 4px; border-radius: 0 4px 4px 0; background: var(--blue); }
.plist-item .accent.gray { background: #b6c2d2; }
.plist-item .body { flex: 1; min-width: 0; }
.plist-item .row-top { display: flex; align-items: flex-start; gap: 10px; }
.plist-item .row-top .name { font-size: 15px; font-weight: 600; line-height: 1.5; flex: 1; min-width: 0; }
.plist-item .row-top .amt { font-size: 13px; font-weight: 600; color: var(--ink-2); white-space: nowrap; padding-top: 2px; }
.plist-item .row-sub { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; font-size: 12.5px; color: var(--ink-3); margin: 3px 0 10px; }
.plist-item .row-sub .grow { flex: 1; }
.plist-item .row-sub .dot { opacity: .5; }
.qno {
  display: inline-flex; width: 19px; height: 19px; border-radius: 6px; background: #eef2f7; color: var(--ink-3);
  font-size: 11px; font-weight: 700; align-items: center; justify-content: center; margin-right: 8px; transform: translateY(-2px);
}
.plist-item .row-stage { display: flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--ink-3); margin-top: 8px; flex-wrap: wrap; }

/* 六段进度条 */
.sixbar { display: flex; gap: 3px; height: 18px; }
.sixbar .seg {
  flex: 1; display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 600; color: #fff; border-radius: 4px; letter-spacing: 1px;
}
.sixbar .seg.pending { background: #e8edf3; color: #a5b1c2; }
.sixbar .seg.doing { opacity: .92; }

/* 商机跟进进度 */
.opp-track { display: flex; align-items: center; gap: 10px; }
.opp-track .pct { font-size: 12px; font-weight: 700; color: #7c3aed; width: 36px; text-align: right; }

/* 详情六到位清单 */
.stage-lines { padding: 6px 20px 18px; }
.stage-line { display: flex; align-items: center; gap: 11px; padding: 13px 4px; border-bottom: 1px solid #f2f5f9; }
.stage-line:last-child { border-bottom: none; }
.stage-line .bar { width: 4px; height: 34px; border-radius: 3px; flex-shrink: 0; }
.stage-line .ico { width: 22px; height: 22px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; flex-shrink: 0; }
.stage-line .ico.done { background: var(--green-soft); color: var(--green); }
.stage-line .ico.doing { background: var(--orange-soft); color: var(--orange); }
.stage-line .ico.pending { background: #eef2f7; color: #a5b1c2; }
.stage-line .nm { font-size: 14px; font-weight: 600; width: 116px; flex-shrink: 0; }
.stage-line .status { font-size: 11.5px; width: 56px; flex-shrink: 0; color: var(--ink-3); }
.stage-line .status.done { color: var(--green); }
.stage-line .status.doing { color: var(--orange); }
.stage-line .times { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.stage-line .times .hl { font-size: 12.5px; color: var(--ink); font-weight: 500; }
.stage-line .times .pl { font-size: 11px; color: var(--ink-3); }

@media (max-width: 820px) {
  .plist-item { padding: 13px 14px 12px 20px; }
  .plist-item .row-top .name { font-size: 14px; }
  .stage-line { flex-wrap: wrap; padding: 11px 2px; gap: 9px; }
  .stage-line .nm { width: auto; flex: 1; }
  .stage-line .status { width: auto; }
  .stage-line .times { width: 100%; padding-left: 37px; }
  .sixbar { height: 16px; }
  .sixbar .seg { font-size: 9px; letter-spacing: 0; }
  .opp-track .pct { width: 32px; }
}
@media (max-width: 1100px) {
  .proj-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stage-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  .login-page { flex-direction: column; }
  .login-brand { padding: 30px 24px 26px; flex: none; }
  .login-brand h1 { font-size: 24px; margin-bottom: 10px; }
  .login-brand p { font-size: 12.5px; line-height: 1.7; }
  .brand-stages { display: none; }
  .login-panel { padding: 24px 16px 40px; }
  .login-card { padding: 28px 22px 24px; border-radius: 16px; }
  .sidebar { display: none; }
  .main { margin-left: 0; padding-bottom: 64px; }
  .topbar { height: 56px; padding: 0 14px; }
  .topbar-title { font-size: 15px; }
  .topbar-sub, .topbar-date { display: none; }
  .page { padding: 16px 14px 26px; }
  .page-head h2 { font-size: 18px; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .proj-grid { grid-template-columns: 1fr; gap: 12px; }
  .stage-grid { grid-template-columns: 1fr; }
  .metric { padding: 15px 16px; }
  .metric-body .val { font-size: 23px; }
  .mobile-tab {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
    background: rgba(255,255,255,.96); backdrop-filter: blur(14px); border-top: 1px solid var(--line);
    padding: 5px 4px calc(5px + env(safe-area-inset-bottom));
  }
  .mt-item { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px; color: var(--ink-3); font-size: 10px; border-radius: 8px; }
  .mt-item .ico { font-size: 18px; line-height: 1; }
  .mt-item.active { color: var(--blue); font-weight: 600; }
  .detail-hero { padding: 17px 16px; }
  .detail-hero h2 { font-size: 17px; min-width: 0; }
  .detail-hero .meta { gap: 14px 20px; margin-top: 11px; }
  .detail-hero .meta b { font-size: 13px; }
  .tabs { padding: 0 10px; }
  .tab { padding: 11px 10px; font-size: 12.5px; }
  .doc-row { padding: 12px 14px; flex-wrap: wrap; }
  .doc-side { width: 100%; justify-content: flex-end; }
  .modal { max-width: 100%; border-radius: 14px; }
  .modal-head, .modal-body, .modal-foot { padding-left: 17px; padding-right: 17px; }
  .form-grid { grid-template-columns: 1fr; }
  .toolbar .search { min-width: 0; flex: 1; }
  .urgent-card .meta { gap: 8px; }
  .gantt-name-col { width: 180px; }
  .gantt-month { width: 74px; }
  .gantt-track { background-size: 74px 100%; }
  .gantt-bar { font-size: 9px; padding: 0 4px; }
  .table th, .table td { padding: 10px 10px; }
  .profile-head { padding: 18px 16px; }
  .menu-item { padding: 13px 16px; }
}