/* ============ 页面级样式 ============ */

/* ---------- 工作台 ---------- */
.dash-grid { display: grid; grid-template-columns: 1.55fr 1fr; gap: 14px; margin-top: 14px; }
@media (max-width: 1080px) { .dash-grid { grid-template-columns: 1fr; } }

.dash-brief {
  display: flex; flex-wrap: wrap; gap: 8px 22px;
  margin: 14px 2px 2px; padding: 0 2px;
  font-size: 12.5px; color: var(--muted);
}
.dash-brief b { color: var(--ink); font-size: 14px; font-weight: 700; margin-left: 4px; }
@media (max-width: 760px) {
  .dash-brief { gap: 6px 16px; margin: 12px 0 0; }
}

.chart { width: 100%; height: auto; display: block; }
.legend { display: flex; gap: 14px; font-size: 11.5px; color: var(--muted); align-items: center; flex-wrap: wrap; }
.legend i { width: 8px; height: 8px; border-radius: 2px; display: inline-block; margin-right: 5px; }

.hbars { display: flex; flex-direction: column; gap: 12px; }
.hb-row { display: grid; grid-template-columns: 1fr 46px; gap: 10px; align-items: center; }
.hb-row .hb-track { grid-column: 1 / -1; margin-top: -4px; }
.hb-label { display: flex; justify-content: space-between; gap: 8px; font-size: 12.5px; }
.hb-label b { font-weight: 600; }
.hb-label span { color: var(--muted); font-size: 11.5px; white-space: nowrap; }

.alert-row {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 0; border-bottom: 1px dashed #eceee9;
}
.alert-row:last-child { border-bottom: 0; }
.alert-row .grow { flex: 1; min-width: 0; }
.alert-row .name { font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 6px; }

.quick-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.quick-btn {
  display: flex; align-items: center; gap: 9px;
  border: 1px solid var(--line); background: #fbfcfa; border-radius: 10px;
  padding: 10px 12px; cursor: pointer; font-size: 12.5px; color: var(--ink2);
  text-align: left; transition: .15s;
}
.quick-btn:hover { border-color: #bcd4c9; background: var(--brand-soft); color: var(--brand); }
.quick-btn svg { width: 16px; height: 16px; opacity: .8; }

/* ---------- 登录页 ---------- */
.login-body { background: #0f231d; }
.login-wrap { display: grid; grid-template-columns: 1.05fr .95fr; min-height: 100vh; }
.login-brand {
  background:
    radial-gradient(1100px 600px at 0% 0%, rgba(217, 131, 36, .18), transparent 60%),
    radial-gradient(900px 600px at 100% 100%, rgba(26, 122, 102, .30), transparent 60%),
    #0f231d;
  color: #eaf2ee; padding: 56px 7vw; display: flex; align-items: center;
}
.login-brand-inner { max-width: 470px; }
.brand-mark { display: flex; align-items: center; gap: 11px; margin-bottom: 46px; }
.brand-logo {
  width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center;
  background: #fff; color: #1d1305; overflow: hidden; flex: 0 0 42px;
  font-weight: 800; font-size: 19px;
}
img.brand-logo { object-fit: contain; padding: 3px; box-sizing: border-box; }
.brand-mark strong { display: block; font-size: 16px; letter-spacing: 3px; color: #fff; }
.brand-mark span { display: block; font-size: 11px; color: #8ea79d; letter-spacing: 1.5px; }
.login-brand h1 { font-size: 34px; line-height: 1.35; letter-spacing: .5px; font-weight: 650; }
.login-lead { color: #9fb8ae; font-size: 13.5px; line-height: 1.9; margin-top: 16px; }
.login-points { list-style: none; padding: 0; margin: 30px 0 0; display: flex; flex-direction: column; gap: 12px; }
.login-points li { display: flex; align-items: center; gap: 10px; font-size: 13px; color: #c8d9d2; }
.login-points i {
  width: 7px; height: 7px; border-radius: 50%; background: #e0a458; flex: 0 0 7px;
  box-shadow: 0 0 0 4px rgba(224, 164, 88, .14);
}
.login-foot { margin-top: 52px; font-size: 11px; color: #5f7770; letter-spacing: 1px; }

.login-panel {
  display: flex; align-items: center; justify-content: center; padding: 40px 24px;
  background:
    radial-gradient(800px 500px at 100% 0%, rgba(26, 122, 102, .07), transparent 65%),
    radial-gradient(700px 500px at 0% 100%, rgba(224, 164, 88, .08), transparent 60%),
    #f4f5f2;
}
.login-card {
  width: 100%; max-width: 380px;
  background: #fff; border: 1px solid var(--line); border-radius: 18px;
  box-shadow: 0 26px 70px -34px rgba(15, 35, 29, .45);
  padding: 32px 30px 26px;
}
.login-mini-brand { display: none; }
.login-card h2 { font-size: 21px; font-weight: 650; letter-spacing: .5px; }
.login-tip { font-size: 12.5px; color: var(--muted); margin: 4px 0 22px; }
.login-card .field { display: block; margin-bottom: 14px; }
.login-card .input { height: 42px; }
.login-card .btn-block { margin-top: 6px; padding: 11px; font-size: 14px; letter-spacing: 2px; }
.login-help { margin-top: 18px; font-size: 11.5px; color: #9aa39d; text-align: center; }

@media (max-width: 900px) {
  .login-wrap { grid-template-columns: 1fr; }
  .login-brand { display: none; }
  .login-panel { min-height: 100vh; }
  .login-mini-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 20px; }
  .login-mini-brand img { width: 34px; height: 34px; object-fit: contain; border-radius: 8px; }
  .login-mini-brand strong { font-size: 15px; letter-spacing: 1px; color: var(--ink); }
}

/* ---------- 客户 / 项目详情 ---------- */
.meta-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.info-box {
  background: #f7f9f6; border: 1px solid #edf0ea;
  border-radius: 10px; padding: 12px 14px; font-size: 12.5px;
  color: var(--ink2); line-height: 1.7;
}
.info-box strong { color: var(--ink); }
.sub-item {
  border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 12px; margin-bottom: 8px; background: #fff;
}
.sub-item .s-h { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.sub-item .s-name { font-size: 12.5px; font-weight: 600; }
.sub-item .s-meta { font-size: 11.5px; color: var(--muted); margin-top: 3px; }

/* ---------- 采集页 ---------- */
.platform-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.platform-item {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  border: 1px solid var(--line); border-radius: 10px; padding: 9px 11px;
  font-size: 12.5px; color: var(--ink2); background: #fff;
}
.collect-note {
  border-left: 3px solid var(--amber); background: var(--amber-soft);
  border-radius: 0 10px 10px 0; padding: 12px 14px;
  font-size: 12px; color: #7d5a25; line-height: 1.8;
}
.log-row { display: flex; gap: 10px; align-items: flex-start; padding: 10px 0; border-bottom: 1px dashed #eceee9; font-size: 12.5px; }
.log-row:last-child { border-bottom: 0; }
.log-dot { width: 7px; height: 7px; border-radius: 50%; margin-top: 6px; flex: 0 0 7px; background: var(--brand2); }
.log-dot.warn { background: var(--amber); }
.log-dot.err { background: var(--danger); }

/* ---------- 员工 / 设置 ---------- */
.user-card { display: flex; align-items: center; gap: 12px; padding: 13px 0; border-bottom: 1px dashed #eceee9; }
.user-card:last-child { border-bottom: 0; }
.user-card .avatar { width: 38px; height: 38px; border-radius: 11px; font-size: 15px; flex: 0 0 38px; }
.user-card .grow { flex: 1; min-width: 0; }
.user-card .name { font-size: 13.5px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.user-card .meta { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.user-stat { text-align: right; font-size: 11.5px; color: var(--muted); }
.user-stat b { display: block; font-size: 15px; color: var(--ink); font-variant-numeric: tabular-nums; }

.settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 980px) { .settings-grid { grid-template-columns: 1fr; } }

/* ---------- 表格横向滚动适配 ---------- */
@media (max-width: 760px) {
  th, td { padding: 10px 10px; }
  .toolbar { gap: 8px; }
  .search { max-width: none; }
}
