/* =========================================================
   金信鸽装饰 · 管理后台样式（admin.html 专用）
   ========================================================= */
:root {
  --gold: #c89b54; --gold2: #a97c34; --ink: #1b1b1d;
  --muted: #6e6e73; --muted2: #9a9a9e; --line: #e9e4db;
  --bg: #f4f2ee; --ok: #2e7d43; --warn: #b0752a; --bad: #b3423a;
  --sb-w: 232px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body.adm {
  font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg); color: var(--ink); font-size: 14px; line-height: 1.65;
}
a { text-decoration: none; color: inherit; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: 14px; outline: none; }

/* ---- 布局 ---- */
.adm-side {
  position: fixed; left: 0; top: 0; bottom: 0; width: var(--sb-w); z-index: 50;
  background: #1b1b1d; color: rgba(255,255,255,.72); display: flex; flex-direction: column;
}
.adm-logo { display: flex; align-items: center; gap: 10px; padding: 20px 20px 18px; border-bottom: 1px solid rgba(255,255,255,.09); }
.adm-logo .mark { width: 36px; height: 36px; border-radius: 9px; object-fit: contain; display: block; }
.adm-logo b { color: #fff; font-size: 16px; display: block; letter-spacing: .05em; }
.adm-logo span { font-size: 11px; color: rgba(255,255,255,.4); letter-spacing: .12em; }
.adm-nav { flex: 1; overflow-y: auto; padding: 14px 12px; }
.adm-nav .grp { font-size: 11px; letter-spacing: .14em; color: rgba(255,255,255,.34); padding: 16px 10px 8px; }
.adm-nav a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 8px; margin-bottom: 2px; font-size: 14px; transition: .15s; }
.adm-nav a:hover { background: rgba(255,255,255,.07); color: #fff; }
.adm-nav a.is-active { background: var(--gold); color: #fff; font-weight: 600; }
.adm-nav a i { font-style: normal; width: 20px; text-align: center; opacity: .85; }
.adm-side__foot { padding: 14px 16px; border-top: 1px solid rgba(255,255,255,.09); font-size: 12px; display: flex; justify-content: space-between; align-items: center; }
.adm-side__foot a { color: rgba(255,255,255,.5); }
.adm-side__foot a:hover { color: var(--gold); }

.adm-main { margin-left: var(--sb-w); min-height: 100vh; }
.adm-top {
  position: sticky; top: 0; z-index: 40; height: 60px;
  background: rgba(255,255,255,.94); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 16px; padding: 0 28px;
}
.adm-top h2 { font-size: 17px; }
.adm-top .crumb { font-size: 12px; color: var(--muted2); }
.adm-top .right { margin-left: auto; display: flex; align-items: center; gap: 14px; font-size: 13px; color: var(--muted); }
.adm-body { padding: 26px 28px 60px; max-width: 1280px; }

/* ---- 组件 ---- */
.card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 22px; margin-bottom: 22px; }
.card h3 { font-size: 15.5px; margin-bottom: 16px; display: flex; align-items: center; gap: 10px; }
.card h3 .btn { margin-left: auto; }

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 24px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 20px 22px; }
.stat b { display: block; font-size: 30px; line-height: 1.2; }
.stat span { font-size: 12.5px; color: var(--muted2); }
.stat.gold b { color: var(--gold2); }
.stat.ok b { color: var(--ok); }
.stat.warn b { color: var(--warn); }

table { width: 100%; border-collapse: collapse; }
th { text-align: left; font-size: 12.5px; color: var(--muted2); font-weight: 600; padding: 9px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 11px 12px; border-bottom: 1px solid #f1ede6; font-size: 13.5px; vertical-align: top; }
tr:last-child td { border-bottom: 0; }
tr:hover td { background: #faf8f5; }
.td-wrap { max-width: 340px; }

.tag { display: inline-block; font-size: 12px; padding: 3px 12px; border-radius: 999px; white-space: nowrap; }
.tag--gold { background: #f3e8d4; color: var(--gold2); }
.tag--ok { background: #e8f3ea; color: var(--ok); }
.tag--warn { background: #fdf3e4; color: var(--warn); }
.tag--grey { background: #f0f0f2; color: var(--muted); }
.tag--bad { background: #fdf0ef; color: var(--bad); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 38px; padding: 0 18px; border-radius: 8px; border: 1px solid transparent; font-size: 13.5px; font-weight: 600; }
.btn--pri { background: var(--gold); color: #fff; }
.btn--pri:hover { background: var(--gold2); }
.btn--ghost { background: #fff; border-color: var(--line); color: var(--ink); }
.btn--ghost:hover { border-color: var(--gold); color: var(--gold2); }
.btn--danger { background: #fdf0ef; color: var(--bad); }
.btn--sm { height: 30px; padding: 0 12px; font-size: 12.5px; border-radius: 6px; }
.btn--link { background: none; border: 0; color: var(--gold2); padding: 0 6px; height: auto; }

.field { margin-bottom: 14px; }
.field label { display: block; font-size: 12.5px; color: var(--muted); margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: #fafaf9; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--gold); background: #fff; }
.frow { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.frow3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }

/* 进度条 */
.pg { display: flex; align-items: center; gap: 10px; min-width: 130px; }
.pg .bar { flex: 1; height: 7px; border-radius: 99px; background: #eee9e1; overflow: hidden; }
.pg .bar i { display: block; height: 100%; background: var(--gold); border-radius: 99px; }
.pg span { font-size: 12px; color: var(--muted); width: 34px; text-align: right; }

/* 节点 */
.node-row { display: grid; grid-template-columns: 130px 1fr 110px 100px 70px; gap: 10px; align-items: center;
  padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; margin-bottom: 8px; background: #fff; }
.node-row b { font-size: 13.5px; }
.node-row small { color: var(--muted2); font-size: 12px; }

/* 弹窗 */
.mask { display: none; position: fixed; inset: 0; background: rgba(20,18,16,.5); z-index: 90;
  align-items: flex-start; justify-content: center; padding: 7vh 20px 40px; overflow-y: auto; }
.mask.is-open { display: flex; }
.modal { background: #fff; border-radius: 16px; width: 640px; max-width: 100%; padding: 26px; }
.modal h3 { font-size: 17px; margin-bottom: 20px; display: flex; }
.modal h3 .x { margin-left: auto; background: none; border: 0; font-size: 20px; color: var(--muted2); line-height: 1; }
.modal__foot { display: flex; justify-content: flex-end; gap: 12px; margin-top: 22px; }

.empty { text-align: center; color: var(--muted2); padding: 40px 0; font-size: 13.5px; }
.mt0 { margin-top: 0; } .mb14 { margin-bottom: 14px; }

/* ---- 管理看板：工程状态看板（kanban） ---- */
.board { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.board-col { background: #faf8f5; border: 1px solid var(--line); border-radius: 12px; padding: 14px; }
.board-col h4 { font-size: 13.5px; margin-bottom: 12px; display: flex; align-items: center; gap: 8px; color: var(--ink); }
.board-col h4 .cnt { font-size: 12px; font-weight: 600; color: #fff; background: var(--gold2); border-radius: 999px; padding: 1px 9px; }
.board-item { display: block; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 11px 12px; margin-bottom: 9px; transition: .15s; }
.board-item:hover { border-color: var(--gold); box-shadow: 0 6px 18px rgba(200,155,84,.16); }
.board-item b { display: block; font-size: 13.5px; margin-bottom: 8px; line-height: 1.4; }
.board-item .pg { min-width: 0; }
.board-empty { font-size: 12.5px; color: var(--muted2); text-align: center; padding: 18px 0; }

/* ---- 管理看板：漏斗 / 构成条 ---- */
.funnel-row { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.funnel-name { width: 64px; font-size: 13px; color: var(--muted); flex-shrink: 0; }
.funnel-bar { flex: 1; height: 24px; background: #f0ece4; border-radius: 6px; overflow: hidden; }
.funnel-bar i { display: block; height: 100%; background: var(--gold); border-radius: 6px; min-width: 2px; }
.funnel-bar.bar--c i { background: var(--gold2); }
.funnel-bar.bar--w i { background: #5b8db8; }
.funnel-bar.bar--p i { background: #7a9a5b; }
.funnel-num { width: 30px; text-align: right; font-size: 14px; }

/* ---- 会员三分类标签 ---- */
.mem-tabs { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.mem-tabs button { height: 36px; padding: 0 16px; border-radius: 8px; border: 1px solid var(--line); background: #fff; font-size: 13.5px; color: var(--muted); cursor: pointer; }
.mem-tabs button.is-active { background: var(--gold); border-color: var(--gold); color: #fff; font-weight: 600; }
.mem-tabs button .badge { display: inline-block; min-width: 18px; padding: 0 6px; margin-left: 4px; font-size: 11px; border-radius: 999px; background: rgba(0,0,0,.06); color: inherit; }
.mem-tabs button.is-active .badge { background: rgba(255,255,255,.25); }

@media (max-width: 960px) {
  :root { --sb-w: 64px; }
  .adm-logo b, .adm-logo span, .adm-nav a span, .adm-nav .grp, .adm-side__foot span { display: none; }
  .adm-nav a { justify-content: center; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .frow, .frow3, .node-row { grid-template-columns: 1fr 1fr; }
  .board { grid-template-columns: repeat(2, 1fr); }
  .grid2col { grid-template-columns: 1fr !important; }
}
@media (max-width: 560px) {
  .board { grid-template-columns: 1fr; }
}

/* ================= GEO 优化模块 ================= */
.grp-arrow { float: right; font-style: normal; font-size: 10px; color: var(--muted2); }
.switch-row {
  display: flex; align-items: flex-start; gap: 12px; padding: 13px 14px;
  border: 1px solid var(--line); border-radius: 12px; margin-bottom: 10px;
  cursor: pointer; transition: .2s; background: #fff;
}
.switch-row:hover { border-color: var(--gold); }
.switch-row.is-on { border-color: var(--gold); background: rgba(200, 155, 84, .06); }
.switch-row input { display: none; }
.switch-row .switch {
  flex-shrink: 0; width: 40px; height: 22px; border-radius: 999px; margin-top: 2px;
  background: #d8d3ca; position: relative; transition: .25s;
}
.switch-row .switch::after {
  content: ''; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px;
  border-radius: 50%; background: #fff; box-shadow: 0 1px 4px rgba(0, 0, 0, .25); transition: .25s;
}
.switch-row.is-on .switch { background: var(--gold); }
.switch-row.is-on .switch::after { transform: translateX(18px); }
.switch-txt { min-width: 0; }
.switch-txt b { display: block; font-size: 14px; }
.switch-txt em { display: block; font-style: normal; font-size: 12.5px; color: var(--muted2); margin-top: 3px; line-height: 1.6; }
.code-box {
  background: #f7f4ef; border: 1px solid var(--line); border-radius: 12px;
  padding: 14px 16px; font-family: ui-monospace, Consolas, monospace;
  font-size: 12.5px; line-height: 1.7; color: var(--ink-2);
  white-space: pre-wrap; word-break: break-all; margin: 0;
}
.adm textarea {
  width: 100%; padding: 10px 14px; font-size: 13.5px; color: var(--ink-2);
  border: 1px solid var(--line); border-radius: 10px; background: #fff;
  outline: 0; transition: .2s; resize: vertical;
}
.adm textarea:focus { border-color: var(--gold); }
