:root {
  --bg: #f5f7fa;
  --panel: #ffffff;
  --ink: #1f2933;
  --muted: #6b7785;
  --line: #e3e8ef;
  --brand: #2f6fed;
  --brand-soft: #e8f0fe;
  /* 别名：历史代码里使用但漏定义的变量，统一映射到上面的主色板 */
  --card: #ffffff;        /* = --panel，卡片/弹窗背景 */
  --card-bg: #ffffff;
  --text: #1f2933;        /* = --ink，正文文字 */
  --txt: #1f2933;
  --sub: #6b7785;         /* = --muted，次要文字 */
  --border: #e3e8ef;      /* = --line，边框 */
  --blue: #2f6fed;        /* = --brand，强调蓝 */
  --primary: #2f6fed;
  --green: #1f9d55;
  --green-soft: #e3f6ec;
  --orange: #e8820c;
  --orange-soft: #fdf0dc;
  --red: #d64545;
  --red-soft: #fbe6e6;
  --purple: #7c4dff;
  --purple-soft: #efe9ff;
  --gray: #8a94a6;
  --gray-soft: #eef1f5;
  --shadow: 0 1px 3px rgba(16,24,40,.06), 0 6px 18px rgba(16,24,40,.05);
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg); color: var(--ink); font-size: 14px; line-height: 1.5;
}
.layout { display: flex; min-height: 100vh; overflow: hidden; }
.sidebar {
  width: 244px; flex-shrink: 0; background: var(--panel);
  border-right: 1px solid var(--line);
  display: flex; flex-direction: column; padding: 18px 14px;
  position: sticky; top: 0; height: 100vh;
  z-index: 10;
  isolation: isolate;
}
.brand { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.logo { font-size: 28px; }
.biz { font-weight: 700; font-size: 18px; }
.sub { color: var(--muted); font-size: 12px; }
.sidenav { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.nav-sep { height: 1px; background: var(--line); margin: 5px 10px; flex: 0 0 auto; }
.sbtn {
  border: none; background: transparent; text-align: left; cursor: pointer;
  font-size: 14px; font-weight: 600; color: var(--muted);
  padding: 12px 14px; border-radius: 10px; display: flex; align-items: center; gap: 8px;
}
.sbtn:hover { background: var(--bg); color: var(--ink); }
.sbtn.active { background: var(--brand); color: #fff; }
.side-foot { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; }
body.locked .layout { display: none !important; }
.userbar { margin-left: auto; font-size: 13px; color: var(--muted); display: inline-flex; align-items: center; gap: 8px; }
.userbar b { color: var(--brand); }
.content { flex: 1; min-width: 0; display: flex; flex-direction: column; overflow: hidden; overflow-y: auto; position: relative; }
.topbar {
  display: flex; align-items: center; gap: 16px;
  padding: 10px 20px; background: var(--panel); border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 20;
}
.datelabel { font-size: 12px; color: var(--muted); display: flex; flex-direction: column; gap: 3px; }
.datelabel input { padding: 5px 8px; border: 1px solid var(--line); border-radius: 7px; font-size: 13px; }
.today { color: var(--muted); font-size: 12px; }
.clock { font-variant-numeric: tabular-nums; font-weight: 600; color: var(--brand); font-size: 15px; }

main { padding: 20px; overflow-x: hidden; }

/* ===== 移动端适配（手机竖屏）===== */
@media (max-width: 760px) {
  body { font-size: 15px; }
  .layout { flex-direction: column; }
  .sidebar {
    width: 100%; height: auto; position: sticky; top: 0; z-index: 30;
    flex-direction: row; align-items: center; gap: 10px;
    padding: 8px 10px; box-shadow: var(--shadow);
  }
  .brand { margin-bottom: 0; gap: 6px; flex: 0 0 auto; }
  .brand .logo { font-size: 22px; }
  .brand .sub { display: none; }
  .brand .biz { font-size: 15px; }
  .side-foot { display: none; }
  .sidenav {
    flex: 1 1 auto; flex-direction: row; flex-wrap: nowrap;
    overflow-x: auto; gap: 6px; padding-bottom: 2px;
    -webkit-overflow-scrolling: touch; scrollbar-width: none;
  }
  .sidenav::-webkit-scrollbar { display: none; }
  .sbtn { white-space: nowrap; padding: 10px 14px; font-size: 14px; border-radius: 9px; flex: 0 0 auto; }
  .sbtn.active { box-shadow: none; }
  .content { min-width: 0; }
  .topbar { flex-wrap: wrap; gap: 8px; padding: 10px 12px; position: static; }
  .topbar .datelabel { flex: 1 1 100%; }
  .topbar .datelabel input { width: 100%; font-size: 15px; padding: 9px 10px; }
  .topbar .hint { font-size: 12px; }
  #viewHint {
    display: inline-flex; align-items: center;
    background: var(--brand); color: #fff;
    padding: 4px 14px; border-radius: 20px;
    font-size: 13px; font-weight: 600;
    white-space: nowrap; line-height: 1.4;
  }
  main { padding: 12px; }

  /* 触摸目标放大 */
  button.btn { padding: 11px 18px; font-size: 15px; }
  button.btn.sm { padding: 7px 12px; }
  select, input[type=text], input[type=number], input[type=date], textarea {
    padding: 11px 12px; font-size: 15px;
  }
  .kpi .n { font-size: 24px; }
  .panel { padding: 14px; }

  /* 日历：手机上横滑查看，字号略放大 */
  .cal-wrap { -webkit-overflow-scrolling: touch; }
  table.cal { min-width: 880px; }
  table.cal th, table.cal td { font-size: 13px; }
  .cell { height: 42px; }
  .sales-cal-wrap { -webkit-overflow-scrolling: touch; }
  table.sales-cal { min-width: 980px; }

  /* 弹窗在手机上全宽 */
  .modal { max-width: 96vw; padding: 18px 16px; }
  .modal-h { font-size: 17px; }
  .toast { bottom: 16px; font-size: 14px; }

  /* 表格横向滚动更顺滑 */
  .tbl-scroll, .util-scroll, .tablewrap, .cal-wrap, .sales-cal-wrap { -webkit-overflow-scrolling: touch; }
  table.util-table { min-width: 620px; font-size: 13px; }

  /* 管家任务清单卡片在手机上更紧凑 */
  .task-item, .ho-item, .ce-row, .inv-card, .acc-row { padding: 12px 14px; }
  .ho-add input#hoTitle { min-width: 140px; }
  .two-col { grid-template-columns: 1fr; }
  .inv-grid { grid-template-columns: 1fr; }
  .asset-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
  .asset-wall { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); }
}
@media (max-width: 480px) {
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .overview-kpis { grid-template-columns: repeat(2, 1fr); }
  .util-money-cards { grid-template-columns: 1fr; }
  .overview-header { gap: 10px; }
  .month-list .month-block .cal-wrap table.cal { min-width: 920px; }
  .overview-top-row { gap: 6px; }
  .overview-top-row .kpi, .overview-top-row .rs-card { min-width: 78px; max-width: none; padding: 8px 10px; }
  .month-summary-chips { margin-left: 0; width: 100%; justify-content: flex-start; margin-top: 4px; }
}

.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 18px; margin-bottom: 18px; }
.panel h2 { margin: 0 0 4px; font-size: 17px; }
.panel .desc { color: var(--muted); font-size: 13px; margin-bottom: 14px; }

/* 快速跳转导航栏 */
.quick-jump-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  background: linear-gradient(135deg, #f0f4ff, #e8f0fe);
  border: 1px solid #c5d6ff;
  border-radius: 10px;
  margin-bottom: 16px;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 2px 8px rgba(59,130,246,0.08);
}
.qj-label {
  font-size: 12px;
  font-weight: 700;
  color: #1e40af;
  white-space: nowrap;
  margin-right: 4px;
}
.qj-btn {
  display: inline-block;
  padding: 4px 12px;
  font-size: 12.5px;
  color: #2563eb;
  background: white;
  border: 1px solid #bfdbfe;
  border-radius: 20px;
  text-decoration: none;
  cursor: pointer;
  transition: all .15s;
  white-space: nowrap;
}
.qj-btn:hover {
  background: #2563eb;
  color: white;
  border-color: #2563eb;
  transform: translateY(-1px);
  box-shadow: 0 2px 6px rgba(37,99,235,0.25);
}

.row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-bottom: 16px; }
.kpi { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; box-shadow: var(--shadow); }
.kpi .n { font-size: 28px; font-weight: 800; line-height: 1.1; }
.kpi .l { color: var(--muted); font-size: 13px; margin-top: 4px; }
.kpi.green .n { color: var(--green); } .kpi.green { background: var(--green-soft); border-color: #bfe9cf; }
.kpi.orange .n { color: var(--orange); } .kpi.orange { background: var(--orange-soft); border-color: #f6dcb0; }
.kpi.red .n { color: var(--red); } .kpi.red { background: var(--red-soft); border-color: #f3c9c9; }
.kpi.purple .n { color: var(--purple); } .kpi.purple { background: var(--purple-soft); border-color: #d9ccff; }
.kpi.blue .n { color: var(--brand); } .kpi.blue { background: var(--brand-soft); border-color: #c5d9fb; }

table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--line); }
th { color: var(--muted); font-weight: 600; background: #fafbfc; position: sticky; top: 0; }
tbody tr:hover { background: #f8fafc; }
.tag { display: inline-block; padding: 2px 8px; border-radius: 20px; font-size: 12px; font-weight: 600; }
.tag.green { background: var(--green-soft); color: var(--green); }
.tag.orange { background: var(--orange-soft); color: var(--orange); }
.tag.red { background: var(--red-soft); color: var(--red); }
.tag.purple { background: var(--purple-soft); color: var(--purple); }
.tag.blue { background: var(--brand-soft); color: var(--brand); }
.tag.gray { background: var(--gray-soft); color: var(--gray); }

/* calendar */
.cal-wrap { overflow-x: auto; }
table.cal { border-collapse: separate; border-spacing: 0; min-width: 1160px; }
table.cal th, table.cal td { border: 1px solid var(--line); text-align: center; padding: 0; }
table.cal th.rownm, table.cal td.rownm { position: sticky; left: 0; background: var(--panel); z-index: 2; text-align: left; padding: 8px 10px; font-weight: 600; white-space: nowrap; }
table.cal thead th { background: #fafbfc; padding: 6px 4px; font-size: 12px; }
.cell { height: 38px; font-size: 12px; display: flex; align-items: center; justify-content: center; flex-direction: column; cursor: default; }
.cell.available { background: var(--green-soft); color: var(--green); }
.cell.occupied { background: var(--orange-soft); color: var(--orange); }
.cell.checkout { background: var(--red-soft); color: var(--red); }
.cell.checkin { background: var(--purple-soft); color: var(--purple); }
.cell.today-col { outline: 2px solid var(--brand); outline-offset: -2px; }
.cell .small { font-size: 10px; opacity: .8; }
.cell.has-bk { cursor: pointer; position: relative; }
.cell.has-bk:hover { filter: brightness(0.95); box-shadow: inset 0 0 0 2px var(--brand); }
.cell.has-bk::after { content: '✎'; position: absolute; top: 1px; right: 2px; font-size: 9px; opacity: 0; transition: opacity .2s; }
.cell.has-bk:hover::after { opacity: 0.6; }

/* 日历订单详情面板（底部弹出） */
.cal-bk-panel { margin-top: 14px; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--card-bg, #fff); box-shadow: 0 4px 16px rgba(0,0,0,.08); animation: slideUp .25s ease; }
@keyframes slideUp { from{opacity:0;transform:translateY(8px)} to{opacity:1;transform:translateY(0)} }
.cal-bk-header { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; background: linear-gradient(135deg, var(--brand-soft, #e8f0fe), var(--bg)); border-bottom: 1px solid var(--line); }
.cal-bk-title { font-weight: 700; font-size: 15px; color: var(--text); }
.cal-bk-sub { font-size: 12px; color: var(--sub); margin-left: 8px; }
.cal-bk-body { padding: 14px 16px; }
.cal-bk-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; margin-bottom: 12px; }
.cbk-field label { display: block; font-size: 11px; font-weight: 600; color: var(--sub); margin-bottom: 3px; text-transform: uppercase; letter-spacing: .5px; }
.cbk-field input, .cbk-field select { width: 100%; padding: 7px 10px; border: 1px solid var(--line); border-radius: 6px; font-size: 14px; background: var(--bg); color: var(--text); box-sizing: border-box; }
.cbk-field input:focus, .cbk-field select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(66,133,244,.15); }
#cbkPrice { font-weight: 700; font-size: 16px; color: var(--orange); border-color: var(--orange-soft); }
.cal-bk-actions { display: flex; gap: 8px; flex-wrap: wrap; padding-top: 10px; border-top: 1px solid var(--line); }

/* 日历汇总列（当月合计间夜 / 已完成间夜 / 满房率） */
table.cal th.sum-col { background: #f0f4ff; color: var(--blue); font-weight: 700; font-size: 11px; padding: 6px 5px !important; min-width: 52px; position: sticky; right: 108px; z-index: 2; }
table.cal td.sum-cell { font-size: 12px; font-weight: 600; background: #fafcff; min-width: 52px; position: sticky; }
table.cal td.sum-cell:nth-last-child(3) { right: 104px; z-index: 1; } /* 合计间夜 */
table.cal td.sum-cell:nth-last-child(2) { right: 54px; z-index: 1; }   /* 已完成 */
table.cal td.sum-cell:last-child { right: 0; z-index: 1; }            /* 满房率 */
table.cal td.sum-cell.sold { color: var(--orange); }
table.cal td.sum-cell.rate { color: var(--purple); font-size: 11px; }
table.cal tr.sum-row { background: linear-gradient(90deg, #f0f4ff, #fafbff); border-top: 2px solid var(--blue); }
table.cal tr.sum-row td { padding: 8px 4px !important; }

/* 总览：顶部 KPI + 多月日历 */
.overview-top-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: stretch; margin-bottom: 14px; }
.overview-top-row .kpi, .overview-top-row .rs-card { flex: 1 1 auto; min-width: 90px; max-width: 160px; }
.overview-header { display: flex; gap: 18px; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; margin-bottom: 14px; }
.overview-header > div:first-child { flex: 1 1 280px; }
.overview-kpis { display: grid; grid-template-columns: repeat(2, minmax(120px, 1fr)); gap: 10px; flex: 1 1 280px; max-width: 380px; }
.overview-kpis .kpi { padding: 12px 14px; text-align: center; }
.overview-kpis .kpi .n { font-size: 24px; }
.overview-room-stats { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; padding: 14px 16px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); }
.rs-card { display: flex; align-items: baseline; gap: 8px; padding: 8px 14px; border-radius: 10px; background: #fff; border: 1px solid var(--line); }
.rs-card:nth-child(1) { background: var(--brand-soft); border-color: #c5d9fb; }
.rs-card:nth-child(2) { background: var(--orange-soft); border-color: #f6dcb0; }
.rs-card:nth-child(3) { background: var(--green-soft); border-color: #bfe9cf; }
.rs-card.rs-card-brown { background: #fdf3e4; border-color: #ddb89a; }
.rs-card.rs-card-brown .rs-n { color: #8b5e2c; }
.rs-card.rs-click { cursor: pointer; transition: transform .15s ease, box-shadow .15s ease; }
.rs-card.rs-click:hover { transform: translateY(-2px); box-shadow: 0 4px 14px rgba(0,0,0,.08); }
.rs-card.rs-click .rs-l { color: var(--brand); font-weight: 600; }
.rs-card.rs-click:active { transform: translateY(0); }
.yr-date { padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; font-size: 13px; font-family: inherit; background: #fff; color: var(--text); }
.yr-date:focus { outline: 2px solid var(--brand); outline-offset: -1px; border-color: var(--brand); }
.rs-n { font-size: 22px; font-weight: 800; color: var(--text); }
.rs-l { font-size: 13px; color: var(--muted); }
.cal-nav { display:flex; align-items:center; gap:4px; flex-wrap:wrap; }
.cal-btn { display:inline-flex; align-items:center; justify-content:center; min-width:32px; height:30px; padding:0 8px; border:1px solid var(--line); border-radius:8px; background:var(--panel); color:var(--text); font-size:14px; cursor:pointer; transition:all .15s; white-space:nowrap; }
.cal-btn:hover { background:var(--brand); color:#fff; border-color:var(--brand); }
.cal-btn.ghost { opacity:.6; font-size:12px; }
.cal-btn.ghost:hover { opacity:1; }
.cal-range { font-size:13px; font-weight:700; color:var(--text); padding:0 6px; white-space:nowrap; }
.month-list { margin-top: 8px; }
.month-block { padding: 14px 0; border-top: 1px solid var(--line); }
.month-block:first-child { border-top: none; padding-top: 0; }
.month-block.current-month .month-title span:first-child { color: var(--brand); }
.month-title { font-weight: 700; font-size: 15px; margin-bottom: 8px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* 月份标题旁的当月汇总芯片 */
.month-summary-chips { display: inline-flex; gap: 6px; margin-left: auto; }
.ms-chip { display: inline-flex; align-items: center; padding: 2px 10px; border-radius: 20px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.ms-chip.ms-blue { background: var(--brand-soft); color: var(--brand); }
.ms-chip.ms-orange { background: var(--orange-soft); color: var(--orange); }
.ms-chip.ms-purple { background: var(--purple-soft); color: var(--purple); }

.controls { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
select, input[type=text], input[type=number], input[type=date], textarea {
  padding: 7px 10px; border: 1px solid var(--line); border-radius: 8px; font-size: 13px; font-family: inherit;
}
select:focus, input:focus, textarea:focus { outline: 2px solid var(--brand-soft); border-color: var(--brand); }
button.btn { background: var(--brand); color: #fff; border: none; padding: 8px 14px; border-radius: 8px; cursor: pointer; font-size: 13px; font-weight: 600; }
button.btn:hover { filter: brightness(1.05); }
button.btn.ghost { background: #fff; color: var(--brand); border: 1px solid var(--brand); }
button.btn.danger { background: var(--red); }
button.btn.sm { padding: 4px 9px; font-size: 12px; }

.banner { background: linear-gradient(90deg,#fff4e0,#ffe9e9); border: 1px solid #f3c9c9; color: #9a3b3b; padding: 12px 16px; border-radius: 12px; margin-bottom: 16px; font-weight: 600; display: flex; gap: 10px; align-items: center; }
.banner.on { background: linear-gradient(90deg,#ffe1e1,#ffd0d0); border-color: #e6a0a0; animation: pulse 1.6s infinite; }
@keyframes pulse { 0%,100% { box-shadow: 0 0 0 0 rgba(214,69,69,.4);} 50% { box-shadow: 0 0 0 6px rgba(214,69,69,0);} }

.legend { display: flex; gap: 14px; flex-wrap: wrap; color: var(--muted); font-size: 12px; margin-top: 10px; }
.legend span { display: inline-flex; align-items: center; gap: 5px; }
.dot { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }

.section-title { font-weight: 700; font-size: 15px; margin: 4px 0 10px; display: flex; align-items: center; gap: 8px; }

.empty { color: var(--muted); text-align: center; padding: 20px; }

/* ============ 财务视图 ============ */
.fin-wrap { overflow-x: auto; }
.fin-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.fin-table th, .fin-table td { border-bottom: 1px solid var(--line); padding: 8px 10px; text-align: center; white-space: nowrap; }
.fin-table thead th { background: #fafbfc; font-size: 12px; color: var(--muted); font-weight: 600; }
.fin-table td.rownm { text-align: left; font-weight: 600; }
.fin-table td.sum-cell { font-weight: 600; }
.fin-table td.sum-cell.sold { color: var(--orange); }
.fin-table td.sum-cell.ok { color: #43a047; }
.fin-table td.sum-cell.warn { color: #e53935; }
/* 间夜数 / 平均每间夜（2026-09-21 新增列） */
.fin-table th .th-sub { font-weight: 400; font-size: 10px; color: #9aa6b6; display: block; margin-top: 1px; }
.fin-table td.sum-cell.nights { color: var(--blue); }
.fin-table td.sum-cell.adr { color: #0d9488; }
.fin-table tr.sum-row { background: linear-gradient(90deg, #f0f4ff, #fafbff); border-top: 2px solid var(--blue); }
.fin-table tr.sum-row td { font-weight: 700; }
/* 年租统计面板（2026-09-21 新增） */
.yr-kpis { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.yr-kpi { flex: 1 1 130px; background: #fff; border: 1px solid #ecd9b0; border-radius: 10px; padding: 10px 14px; text-align: center; }
.yr-kpi.main { background: linear-gradient(135deg, #fff4e0, #ffe9c7); border-color: #e0b878; }
.yr-kpi-num { font-size: 21px; font-weight: 700; color: #b45309; letter-spacing: -0.4px; }
.yr-kpi-lbl { font-size: 12px; color: #9c8b72; margin-top: 2px; }
.fin-table input.yr-amt { width: 112px; }
.fin-table input.yr-date { width: 134px; }
table.lr-table th .th-sub { font-weight: 400; font-size: 10px; color: #a8886a; display: block; margin-top: 1px; }
table.lr-table input.yr-amt, table.lr-table input.yr-date { padding: 5px 7px; border: 1px solid #ddb89a; border-radius: 6px; font-size: 13px; background: #fff; color: var(--text); }
table.lr-table input.yr-amt { width: 112px; }
table.lr-table td.yr-monthly { color: #0d9488; font-weight: 600; }
table.lr-table tr.sum-row { background: #f8eeda; border-top: 2px solid #c4a882; }
table.lr-table tr.sum-row td { font-weight: 700; }
.fin-input { width: 96px; padding: 5px 7px; border: 1px solid var(--line); border-radius: 6px; font-size: 13px; background: var(--panel); color: var(--text); }
.mnav { display: inline-flex; gap: 6px; margin-left: auto; }
.exp-form { display:flex; gap:8px; flex-wrap:wrap; align-items:center; margin-bottom:6px; }
.exp-form .fin-input { width:auto; }
.fin-lock { max-width:440px; margin:24px auto; background:var(--card); border:1px solid var(--line); border-radius:12px; padding:22px; box-shadow:0 1px 4px rgba(0,0,0,.06); }
.fin-lock .sub { color:var(--muted); font-size:13px; margin:0 0 16px; }
.lock-row { display:flex; align-items:center; gap:10px; margin-bottom:12px; }
.lock-row label { width:64px; font-size:13px; color:var(--text); }

/* 销售进度条 */
.prog-bar-wrap { background:#f1f5f9; border-radius:6px; height:22px; overflow:hidden; position:relative; min-width:80px; }
.prog-bar { height:100%; border-radius:6px; transition:width .3s; display:flex; align-items:center; justify-content:flex-end; padding-right:6px; min-width:28px; background:linear-gradient(90deg,#3b82f6,#60a5fa); color:#fff; font-size:11px; font-weight:600; white-space:nowrap; }
.prog-bar.ok { background:linear-gradient(90deg,#16a34a,#4ade80); }
.prog-bar.warn { background:linear-gradient(90deg,#d97706,#fbbf24); color:#713f12; }
.prog-txt { text-shadow:0 1px 2px rgba(0,0,0,.15); }
.lock-input { flex:1; padding:9px 11px; border:1px solid var(--line); border-radius:8px; font-size:14px; background:var(--panel); color:var(--text); }
.fin-lock .btn { width:100%; }
.link { color:#2b7de9; font-size:13px; cursor:pointer; text-decoration:underline; }

/* ============ 每周抄表记录面板 ============ */
.reading-toolbar { display:flex; align-items:center; gap:12px; flex-wrap:wrap; margin:14px 0 10px; padding:10px 14px; background:var(--card); border:1px solid var(--line); border-radius:10px; }
.reading-week-label { font-weight:600; font-size:13px; color:var(--text); white-space:nowrap; }
.reading-summary { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; margin:14px 0; }
.rs-card { background:var(--card); border:1px solid var(--line); border-radius:10px; padding:12px 14px; text-align:center; }
.rs-card.highlight { background:linear-gradient(135deg,#e8f5e9,#f1f8e9); border-color:#a5d6a7; }
.rs-label { font-size:12px; color:var(--muted); margin-bottom:4px; }
.rs-value { font-size:22px; font-weight:700; color:var(--text); line-height:1.2; }
.rs-value.warn { color:var(--red); }
.rs-value small { font-size:12px; font-weight:400; color:var(--muted); }
.rs-cost { font-size:13px; color:var(--green); font-weight:600; margin-top:2px; }
.rs-sub { font-size:11px; color:var(--muted); margin-top:2px; }
.reading-form { background:var(--card); border:1px solid var(--line); border-radius:10px; padding:12px 14px; margin:14px 0; }
.rf-row { display:flex; gap:10px; flex-wrap:wrap; align-items:flex-end; }
.rf-field { display:flex; flex-direction:column; gap:3px; min-width:130px; }
.rf-field label { font-size:12px; color:var(--muted); font-weight:500; }
.rf-field input { padding:7px 9px; border:1px solid var(--line); border-radius:6px; font-size:13px; background:var(--panel); color:var(--text); }
.reading-history { margin:14px 0; }
.reading-price-settings { background:#fffbf0; border:1px solid #ffe082; border-radius:10px; padding:12px 14px; margin:14px 0 4px; }

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 900px){ .two-col { grid-template-columns: 1fr; } }

.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px,1fr)); gap: 12px; }
.field { display: flex; flex-direction: column; gap: 4px; }
.field label { font-size: 12px; color: var(--muted); }
textarea { width: 100%; min-height: 120px; resize: vertical; }
.hint { font-size: 12px; color: var(--muted); }

.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(20px); background: #1f2933; color: #fff; padding: 10px 18px; border-radius: 10px; opacity: 0; pointer-events: none; transition: .25s; z-index: 50; font-size: 13px; }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

.danger-zone { border: 1px dashed var(--red); }
.preview-box { background: #fafbfc; border: 1px solid var(--line); border-radius: 8px; padding: 10px; max-height: 220px; overflow: auto; font-size: 12px; }
.linedel { text-decoration: line-through; opacity: .5; }

/* ===== 管家每日必做清单 ===== */
.task-alert { border-radius: 10px; padding: 12px 14px; margin: 10px 0 14px; font-size: 14px; line-height: 1.6; }
.task-alert.now { background: var(--orange-soft); border: 1px solid var(--orange); color: #8a4b00; }
.task-alert.overdue { background: var(--red-soft); border: 1px solid var(--red); color: #8a1f1f; }
.task-alert.done { background: var(--green-soft); border: 1px solid var(--green); color: #145c33; }
.task-alert.gray { background: var(--gray-soft); border: 1px solid var(--line); color: var(--muted); }
.task-list { display: flex; flex-direction: column; gap: 8px; }
.task-item { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); border-left: 4px solid var(--line); }
.task-item.now { border-left-color: var(--orange); background: var(--orange-soft); box-shadow: 0 0 0 1px var(--orange) inset; }
.task-item.overdue { border-left-color: var(--red); background: var(--red-soft); }
.task-item.done { border-left-color: var(--green); opacity: .7; }
.task-item.upcoming { border-left-color: var(--gray); }
.task-check { display: flex; align-items: center; padding-top: 2px; }
.task-check input { width: 18px; height: 18px; cursor: pointer; }
.task-time { font-variant-numeric: tabular-nums; font-weight: 700; font-size: 15px; color: var(--ink); min-width: 48px; padding-top: 1px; }
.task-main { flex: 1; }
.task-title { font-weight: 600; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.task-item.done .task-title { text-decoration: line-through; }
.task-desc { color: var(--muted); font-size: 13px; margin-top: 3px; }

/* ---- 管家交接提醒 ---- */
.ho-table { width: 100%; border-collapse: collapse; margin-top: 8px; }
.ho-table th, .ho-table td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); font-size: 14px; }
.ho-table th { background: var(--gray-soft); color: var(--muted); font-weight: 600; }
.ho-input { width: 100%; padding: 6px 8px; border: 1px solid var(--border); border-radius: 7px; background: #fff; color: var(--text); font-size: 14px; }
.ho-select { width: 100%; padding: 6px 8px; border: 1px solid var(--border); border-radius: 7px; background: #fff; color: var(--text); font-size: 14px; }
.ho-list { display: flex; flex-direction: column; gap: 8px; margin: 10px 0; }
.ho-item { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); border-left: 4px solid var(--orange); }
.ho-item.done { border-left-color: var(--green); opacity: .7; }
.ho-item.done .ho-title { text-decoration: line-through; }
.ho-check { padding-top: 2px; }
.ho-check input { width: 18px; height: 18px; cursor: pointer; }
.ho-main { flex: 1; }
.ho-title { font-weight: 600; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ho-meta { color: var(--muted); font-size: 12px; margin-top: 3px; }
.ho-note { color: var(--ink); font-size: 13px; margin-top: 5px; padding: 6px 10px; background: var(--gray-soft); border-radius: 6px; }
.ho-add { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--line); }
.ho-add input, .ho-add select { padding: 8px 10px; border: 1px solid var(--border); border-radius: 8px; background: #fff; color: var(--text); font-size: 14px; }
.ho-add input[type="date"] { width: 130px; }
.ho-add input#hoTitle { flex: 1; min-width: 220px; }
.ho-add input#hoPerson { width: 110px; }
.ho-add input#hoNote { flex: 1; min-width: 180px; }

/* ---- 客户服务备忘录 ---- */
.req-table { width: 100%; border-collapse: collapse; margin-top: 8px; }
.req-table th, .req-table td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); font-size: 14px; }
.req-table th { background: var(--gray-soft); color: var(--muted); font-weight: 600; }
.req-select { padding: 5px 8px; border: 1px solid var(--border); border-radius: 7px; background: #fff; color: var(--text); font-size: 13px; }

/* ---- 保洁库存清单 ---- */
.inv-table th, .inv-table td { text-align: left; }
.inv-input { width: 90px; padding: 5px 8px; font-size: 14px; border: 1px solid var(--border); border-radius: 7px; background: #fff; color: var(--text); }
.inv-input.low { border-color: #e74c3c; background: #fff5f5; font-weight: 600; }
.inv-input[readonly], .inv-input.readonly { background: #f4f6f9; color: var(--muted); cursor: not-allowed; }
.inv-table td.low, .inv-table .low { color: #e74c3c; font-weight: 600; }

/* ---- 销售：3 周日历 + 点选可售 + 范围查询 ---- */
.sales-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; margin-bottom: 14px; }
.sales-kpis .kpi { text-align: center; padding: 12px 10px; }
.sales-kpis .kpi .n { font-size: 24px; }
.sales-cal-wrap { overflow-x: auto; }
table.sales-cal { min-width: 1100px; }
.sales-cal-th { cursor: pointer; background: #fafbfc; padding: 6px 3px; font-size: 11px; transition: .15s; }
.sales-cal-th:hover { background: var(--brand-soft); }
.sales-cal-th.selected { background: var(--brand); color: #fff; }
.sales-cal-th.today { border-bottom: 2px solid var(--brand); }
.sales-cal-th.we { background: #fff8ef; }
.sales-cal-th.we.selected { background: var(--brand); }
.sales-cal-dow { font-weight: 600; }
.sales-cal-date { font-size: 12px; margin-top: 2px; }
.today-dot { display: inline-block; background: var(--brand); color: #fff; border-radius: 4px; padding: 0 4px; font-size: 10px; margin-left: 2px; }
.sales-cal-cell { height: 36px; cursor: default; border-radius: 4px; font-size: 12px; font-weight: 600;
  display: flex; align-items: center; justify-content: center; transition: all .15s; }
.sales-cal-cell.selected { outline: 2px solid var(--brand); outline-offset: -2px; }

/* 销售日历 · 房态颜色 */
.sales-cal-cell.available { background: #d4edda; color: #155724; }
.sales-cal-cell.occupied { background: #fff3cd; color: #856404; }
.sales-cal-cell.checkout { background: #f8d7da; color: #721c24; }
.sales-cal-cell.checkin { background: #e8daef; color: #5b2c6f; }

/* 连住空档高亮（最少连住筛选生效时） */
.sales-cal-cell.block-available { background: linear-gradient(135deg, #28a745, #20c997); color: #fff; box-shadow: inset 0 0 0 1px rgba(255,255,255,.3); }
.sales-cal-cell.block-start { border-radius: 4px 0 0 4px; }
.sales-cal-cell.block-end { border-radius: 0 4px 4px 0; }
.sales-cal-cell.block-single { border-radius: 4px; }
.sales-cal-cell.too-short { background: #f8f9fa; color: #ccc; }
.sales-cal-cell.has-bk { cursor: pointer; position: relative; }
.sales-cal-cell.has-bk:hover { filter: brightness(0.95); box-shadow: inset 0 0 0 2px var(--brand); }
.sales-cal-cell.has-bk::after { content: '✎'; position: absolute; top: 1px; right: 2px; font-size: 9px; opacity: 0; transition: opacity .2s; }
.sales-cal-cell.has-bk:hover::after { opacity: 0.6; }
.sales-day-panel { margin-top: 14px; padding: 14px; border-radius: 12px; background: var(--green-soft); border: 1px solid #bfe9cf; }
.sales-day-title { font-weight: 700; margin-bottom: 8px; }
.sales-day-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.range-picker { margin-top: 18px; padding: 14px; border-radius: 12px; background: #fafbfc; border: 1px solid var(--line); }
.range-title { font-weight: 700; margin-bottom: 10px; }
.range-fields { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
.range-result { margin-top: 12px; }
.range-result-title { font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.range-result table { font-size: 13px; }
.wk-grid { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.wk-day { flex: 1 1 180px; min-width: 160px; border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; background: #fff; }
.wk-we { background: #fff8ef; }
.wk-today { border-color: var(--blue); box-shadow: 0 0 0 2px rgba(52,152,219,.12); }
.wk-h { font-weight: 600; margin-bottom: 6px; }
.wk-b { font-size: 13px; color: var(--muted); line-height: 1.7; }
.promo-table th, .promo-table td { text-align: left; }
.promo-table tr.hot { background: #fff5f5; }
.promo-table tr.hot td:first-child { font-weight: 700; color: #e74c3c; }

/* ===== 库存：采购提醒 + 布草送洗调度 ===== */
.buy-btn { padding: 5px 10px; border-radius: 8px; border: 1px solid var(--line); background: #fff; cursor: pointer; font-size: 12px; font-weight: 600; color: var(--muted); }
.buy-btn.low { background: var(--red-soft); border-color: var(--red); color: var(--red); animation: pulse 1.6s infinite; }
.inv-sub { display: flex; gap: 18px; flex-wrap: wrap; font-size: 12px; color: var(--muted); margin-top: 10px; padding-top: 8px; border-top: 1px dashed var(--line); }
.inv-sub b { color: var(--ink); }
.inv-wash { background: #fafcff; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; margin-top: 10px; display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; }
.inv-wash .l-f { display: inline-flex; flex-direction: column; gap: 3px; vertical-align: top; }
.inv-wash .l-f label { font-size: 11px; color: var(--muted); }
.inv-wash input { padding: 5px 7px; border: 1px solid var(--line); border-radius: 7px; font-size: 13px; width: 110px; }
.inv-wash .l-act { display: flex; gap: 8px; align-items: flex-end; }
.inv-wash .l-note { font-size: 12px; color: var(--muted); margin-top: 8px; }
.inv-wash .l-note b { color: var(--ink); }
.inv-wash .due { color: var(--red); font-weight: 700; }

/* 库存卡片网格：宽屏多列，窄屏单列，避免右侧大片空白 */
.inv-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(360px, 1fr)); gap: 12px; margin-top: 10px; }
@media (max-width: 820px) {
  .inv-grid { grid-template-columns: 1fr; }
}

/* ===== 登录遮罩 ===== */
.login-mask { position: fixed; inset: 0; background: linear-gradient(135deg,#0f2a4d 0%,#2f6fed 100%); display: none; align-items: center; justify-content: center; z-index: 100; }
.login-mask.show { display: flex; }
.login-box { background: #fff; border-radius: 18px; padding: 32px 30px; width: 360px; max-width: 92vw; box-shadow: 0 20px 60px rgba(16,24,40,.25); }
.login-brand { font-weight: 800; font-size: 22px; text-align: center; color: var(--brand); }
.login-sub { text-align: center; color: var(--muted); font-size: 13px; margin: 4px 0 20px; }
.login-tabs { display: flex; gap: 8px; margin-bottom: 16px; }
.ltab { flex: 1; border: 1px solid var(--line); background: var(--bg); color: var(--muted); padding: 10px; border-radius: 10px; cursor: pointer; font-weight: 600; font-size: 14px; }
.ltab.active { background: var(--brand); color: #fff; border-color: var(--brand); }
.login-form { display: flex; flex-direction: column; gap: 12px; }
.login-form input,
.login-form select.login-select { padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; font-size: 15px; outline: none; background: #fff; appearance: auto; cursor: pointer; }
.login-form input:focus,
.login-form select.login-select:focus { border-color: var(--brand); }
.login-btn { padding: 12px; font-size: 16px; letter-spacing: 4px; margin-top: 4px; }
.login-err { color: var(--red); font-size: 13px; text-align: center; min-height: 18px; margin-top: 10px; }

/* ===== 库存卡片（新版 · 三段式） ===== */
.inv-card { border: 1px solid var(--line); border-radius: 12px; background: #fff; margin-bottom: 14px; overflow: hidden; box-shadow: 0 1px 3px rgba(0,0,0,.04); transition: box-shadow .2s; }
.inv-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,.08); }
.inv-card.low { border-color: #f5a6a6; border-width: 1.5px; }

/* ① 头部 */
.inv-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px 10px; border-bottom: 1px solid #f0f2f5; }
.inv-h-left { display: flex; align-items: baseline; gap: 8px; }
.inv-name { font-weight: 700; font-size: 16px; color: var(--ink); letter-spacing: .3px; }
.inv-unit { font-size: 12px; color: var(--muted); background: var(--bg); padding: 1px 8px; border-radius: 10px; }
.inv-status { font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 10px; white-space: nowrap; }
.inv-status.ok   { background: #e8f5e9; color: #2e7d32; }
.inv-status.warn { background: #fff3e0; color: #e65100; }

/* ② 平衡公式条 —— 核心创新：一眼看清数字关联 */
.inv-balance { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; padding: 11px 14px; background: linear-gradient(135deg,#fafbff 0%,#f5f7fa 100%); border-bottom: 1px solid #f0f2f5; font-size: 13px; line-height: 1.5; }
.inv-balance.mismatch { background: linear-gradient(135deg,#fff8f0 0%,#fff3e0 100%); }
.bal-item { display: inline-flex; flex-direction: column; align-items: center; min-width: 42px; padding: 2px 6px; border-radius: 6px; transition: background .15s; }
.bal-item:hover { background: rgba(255,255,255,.7); }
.bal-lbl { font-size: 10px; color: #999; text-transform: none; letter-spacing: 0; font-weight: 500; }
.bal-val b { font-weight: 700; font-size: 15px; }
.bal-eq { color: #bbb; font-weight: 600; font-size: 13px; margin: 0 2px; }
.bal-plus { color: #ccc; font-weight: 400; font-size: 13px; margin: 0 1px; }
.bal-sum { font-weight: 700; font-size: 14px; color: #2e7d32; padding: 1px 6px; border-radius: 4px; }
.bal-sum.err { color: #c62828; background: #ffebee; }
/* 平衡条各字段颜色 */
.bal-total .bal-val b { color: #1565c0; }
.bal-used  .bal-val b { color: #1976d2; }
.bal-stock .bal-val b { color: #2e7d32; }
.bal-stock.low .bal-val b { color: #c62828; }
.bal-dirty .bal-val b { color: #e65100; }
.bal-washing .bal-val b { color: #7b1fa2; }
.bal-loss  .bal-val b { color: #c62828; }

/* ③ 编辑网格 */
.inv-grid-edit { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px 14px; padding: 12px 16px; }
.ie-cell { display: flex; flex-direction: column; gap: 4px; }
.ie-lbl { font-size: 11.5px; color: #777; font-weight: 500; line-height: 1.3; }
.ie-hint { font-size: 9.5px; color: #aaa; font-weight: 400; margin-left: 2px; }
.ie-inp { width: 100%; padding: 7px 10px; border: 1.5px solid #e0e3e8; border-radius: 8px; font-size: 15px; font-weight: 600; text-align: center; outline: none; transition: all .15s; background: #fafbfd; color: var(--ink); box-sizing: border-box; }
.ie-inp:focus { border-color: #2563eb; background: #fff; box-shadow: 0 0 0 3px rgba(37,99,235,.1); }
.ie-inp.low { border-color: #ef4444; background: #fef2f2; color: #dc2626; }
.ie-ro { font-size: 15px; font-weight: 700; color: #1565c0; padding: 6px 0; text-align: center; }
.ie-set-btn { font-size: 12px; padding: 5px 14px; align-self: flex-start; }

/* ④ 操作栏 */
.inv-ops { display: flex; gap: 8px; flex-wrap: wrap; padding: 10px 16px 12px; border-top: 1px dashed #eee; }

/* 后勤报修 */
.rp-note { color: var(--muted); font-size: 13px; }
.rp-done { color: var(--green); font-size: 12px; }
.rp-ops { white-space: nowrap; }
.rp-row.urgent td:first-child { font-weight: 700; }

/* 工程保障 Tab 切换 */
.log-tabs { display: flex; gap: 4px; margin-bottom: 18px; border-bottom: 2px solid var(--line); padding-bottom: 0; }
.log-tab { background: none; border: none; border-bottom: 3px solid transparent; color: var(--muted); font-size: 14px; font-weight: 600; padding: 10px 16px; cursor: pointer; position: relative; transition: all .2s; }
.log-tab:hover { color: var(--txt); background: rgba(37,99,235,.04); }
.log-tab.active { color: var(--blue); border-bottom-color: var(--blue); }
.tab-badge { background: var(--red); color: #fff; font-size: 10px; font-weight: 700; padding: 1px 6px; border-radius: 10px; margin-left: 4px; vertical-align: top; }

/* 硬件库存 */
.hw-low { background: #fff8f0 !important; }
.hw-low td { background: #fff8f0 !important; }
.hw-ops { white-space: nowrap; min-width: 200px; }
.hw-ops button { margin: 1px 2px; }

/* 房间颜色标记：3号楼一单元（3-1）绿色，其他单元/楼层粉色 */
.room-tag { display: inline-block; padding: 2px 9px; border-radius: 999px; font-weight: 600; font-size: 13px; border: 1px solid transparent; }
.room-tag.g { color: #1a7f37; background: #e6f4ea; border-color: #b7e1c2; }
.room-tag.p { color: #c2185b; background: #fde7f0; border-color: #f3c0d6; }
.legend { display: flex; gap: 16px; align-items: center; margin: 2px 0 12px; font-size: 12px; color: var(--muted); }
.legend .dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 5px; vertical-align: middle; }
.legend .dot.g { background: #1a7f37; }
.legend .dot.p { background: #c2185b; }

/* 资产视图：每间房录入行 */
.asset-add { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; align-items: center; }
.asset-add input[type=text] { flex: 1; min-width: 120px; }
.asset-add input[type=number] { width: 70px; }

/* 后勤费用结余面板 */
table select.tag { font-size: 12px; padding: 4px 10px; border-radius: 20px; cursor: pointer; }
.util-pending { color: var(--orange); font-weight: 600; }
.util-owed { color: var(--red); font-weight: 700; }
.util-paid { color: var(--green); font-weight: 600; }

/* 弹窗通用 */
.modal-mask { position: fixed; inset: 0; background: rgba(0,0,0,0.45); z-index: 2000; display: none; align-items: center; justify-content: center; padding: 20px; }
.modal-mask.show { display: flex; }
.modal { background: var(--card, #ffffff); border-radius: 16px; box-shadow: 0 20px 50px rgba(0,0,0,0.18); width: 100%; max-width: 420px; padding: 22px 24px 24px; text-align: center; }
.modal-h { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.modal-sub { font-size: 13px; color: var(--muted); margin-bottom: 18px; line-height: 1.5; }

/* 账号与密码面板 */
.acc-list { display: flex; flex-direction: column; gap: 12px; margin: 8px 0 4px; }
.acc-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); }
.acc-role { font-weight: 700; color: var(--brand); min-width: 56px; }
.acc-user { color: var(--ink); }
.acc-pass { flex: 1; min-width: 180px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 9px; font-size: 14px; outline: none; }
.acc-pass:focus { border-color: var(--brand); }
.acc-mobile { flex: 0 0 168px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 9px; font-size: 13.5px; outline: none; }
.acc-mobile:focus { border-color: var(--brand); }

/* 统计视图 */
.tag-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.recon-bad { background: var(--red-soft); }
.recon-bad td:first-child { font-weight: 700; }

/* 库存盘点：实际盘点输入 */
.inv-input.st-act { width: 84px; }

/* 弹窗表单（消耗/补给/报损） */
.modal-form { display: flex; flex-direction: column; gap: 12px; text-align: left; margin: 6px 0 16px; }
.flow-field { display: flex; flex-direction: column; gap: 4px; }
.flow-field label { font-size: 12px; color: var(--muted); }
.flow-field select, .flow-field input { padding: 7px 10px; border: 1px solid var(--line); border-radius: 8px; font-size: 13px; font-family: inherit; }

/* 资产视图：紧凑网格 + 照片备案 */
.as-form { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 12px; margin-bottom: 14px; }
.as-form .field { min-width: 120px; }
.space-block { margin-top: 14px; }
.space-title { font-weight: 700; font-size: 14px; margin-bottom: 8px; color: var(--ink); }
.asset-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.asset-card { border: 1px solid var(--line); border-radius: 12px; background: #fff; padding: 10px; display: flex; gap: 10px; align-items: flex-start; }
.asset-thumb { width: 72px; height: 72px; flex-shrink: 0; border-radius: 10px; overflow: hidden; background: var(--bg); border: 1px solid var(--line); position: relative; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.asset-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.asset-thumb.noimg { background: var(--gray-soft); }
.asset-ph { font-size: 11px; color: var(--muted); }
.asset-cnt { position: absolute; right: 3px; bottom: 3px; background: rgba(16,24,40,.62); color: #fff; font-size: 10px; padding: 1px 5px; border-radius: 8px; }
.asset-info { flex: 1; min-width: 0; }
.asset-name { font-weight: 700; font-size: 14px; }
.asset-qty { color: var(--brand); font-size: 13px; margin-left: 4px; }
.asset-meta { margin-top: 4px; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.asset-space { font-size: 12px; color: var(--muted); }
.asset-note { font-size: 12px; color: var(--muted); margin-top: 4px; }
.asset-ops { margin-top: 8px; display: flex; gap: 6px; flex-wrap: wrap; }

/* 资产修改弹窗（2026-09-18）：位置/类别/名称/照片 都能改，不必删了重传 */
#assetEditModal.modal-mask { z-index: 2200; }
#assetEditModal .modal-card {
  background: #fff; border-radius: 16px; padding: 20px 22px; width: 100%; max-width: 620px;
  max-height: 88vh; overflow-y: auto; box-shadow: 0 20px 60px rgba(16,24,40,.28);
}
#assetEditModal .modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
#assetEditModal .modal-header h3 { font-size: 17px; font-weight: 700; margin: 0; }
#assetEditModal .modal-body { display: flex; flex-direction: column; gap: 12px; }
#assetEditModal .field label { font-size: 13px; font-weight: 600; color: var(--ink); margin-bottom: 3px; display: block; }
#assetEditModal .field input, #assetEditModal .field select {
  width: 100%; padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px;
  font-size: 14px; font-family: inherit; box-sizing: border-box; background: #fff;
}
#assetEditModal .modal-footer { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }
#assetEditModal .as-prev { margin-bottom: 0; }
.asset-wall { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
.asset-wall .asset-thumb { width: 100%; height: 140px; }
/* 资产拖拽上传 */
.dropzone { border: 2px dashed var(--line); border-radius: 10px; padding: 16px 12px; text-align: center; color: var(--muted); cursor: pointer; transition: .15s; background: var(--bg); font-size: 13px; line-height: 1.5; }
.dropzone:hover { border-color: var(--brand); color: var(--brand); background: #f3f9ff; }
.dropzone.over { border-color: #2e9e4f; color: #2e9e4f; background: #eef9f0; }
.as-prev { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.as-prev .asset-thumb { width: 64px; height: 64px; cursor: pointer; }
.as-prev .asset-thumb .asset-cnt { right: 1px; bottom: 1px; background: #e5484d; }
/* 照片放大灯箱 */
.lightbox { background: #fff; border-radius: 14px; padding: 12px; max-width: 92vw; max-height: 92vh; display: flex; flex-direction: column; gap: 10px; align-items: center; }
.lightbox img { max-width: 80vw; max-height: 74vh; border-radius: 8px; object-fit: contain; }
.lightbox-bar { display: flex; gap: 10px; align-items: center; }
/* 后勤费用：按房间表格 */
.util-scroll { overflow-x: auto; }
table.util-table { min-width: 680px; }
table.util-table th, table.util-table td { text-align: center; padding: 10px 8px; vertical-align: middle; }
.rownm2 { text-align: left !important; position: sticky; left: 0; background: var(--panel); z-index: 2; font-weight: 600; white-space: nowrap; padding-left: 12px !important; }
.util-room-h { text-align: left !important; padding-left: 12px !important; }
.util-cell { cursor: pointer; min-width: 110px; background: #fff; transition: .15s; }
.util-cell:hover { background: var(--brand-soft); }
.util-bal { font-size: 15px; font-weight: 800; margin-bottom: 4px; }
.util-paid-sm { font-size: 11px; color: var(--muted); margin-top: 4px; }
.util-meta { font-size: 11px; color: var(--muted); margin-bottom: 4px; }
.util-cell.util-alert { box-shadow: inset 0 0 0 2px var(--red); background: #fff5f5; animation: utilPulse 1.2s infinite; }
@keyframes utilPulse { 0%,100% { background: #fff5f5; } 50% { background: #ffe0e0; } }
.util-form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; }
.util-money-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 14px; }
.util-money-card { border-radius: 12px; padding: 14px; text-align: left; }
.util-money-card.balance { background: var(--green-soft); border: 1px solid #b8e7cc; }
.util-money-card.paid { background: var(--brand-soft); border: 1px solid #c2d8f7; }
.umc-label { font-size: 13px; font-weight: 700; margin-bottom: 8px; }
.util-money-card.balance .umc-label { color: var(--green); }
.util-money-card.paid .umc-label { color: var(--brand); }
.util-money-input { display: flex; align-items: center; gap: 6px; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 4px 10px; }
.util-money-input .prefix { font-size: 18px; font-weight: 700; color: var(--ink); }
.util-money-input input { flex: 1; border: none; background: transparent; font-size: 22px; font-weight: 800; padding: 6px 0; color: var(--ink); outline: none; }
.util-money-input input::-webkit-outer-spin-button,
.util-money-input input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.util-consumption { display: flex; gap: 20px; margin: 14px 0; padding: 10px 14px; background: var(--brand-soft); border-radius: 8px; font-size: 13px; }
.util-consumption b { font-size: 15px; }
.util-payments { margin-top: 10px; }
.util-payments h4 { margin: 0 0 8px; font-size: 14px; }
.util-pay-table { width: 100%; font-size: 12px; margin-bottom: 10px; }
.util-pay-table th, .util-pay-table td { text-align: center; padding: 6px 4px; border-bottom: 1px solid var(--line); }
.util-pay-add { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.util-pay-add input { flex: 1; min-width: 80px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 6px; font-size: 12px; }

/* 保洁视图：大瓶消耗品使用比例 */
.consume-summary { display: flex; flex-wrap: wrap; gap: 10px; margin: 10px 0 14px; }
.cs-type { background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; flex: 1; min-width: 200px; }
.cs-name { font-weight: 700; font-size: 13px; margin-bottom: 6px; color: var(--ink); }
.cs-bars { display: flex; flex-wrap: wrap; gap: 6px; }
.cb { font-size: 11px; color: var(--muted); background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 2px 8px; }
.cb b { font-size: 12px; }
.cb.full { color: var(--green); border-color: #b8e7cc; background: var(--green-soft); }
.cb.b80 { color: #1a9e8f; border-color: #bfe3da; background: #e6f7f2; }
.cb.b50 { color: var(--brand); border-color: #c2d8f7; background: var(--brand-soft); }
.cb.b30 { color: var(--orange); border-color: #f3d4a8; background: var(--orange-soft); }
.cb.b10 { color: var(--red); border-color: #f0bcbc; background: var(--red-soft); }
.cb.none { color: var(--muted); background: var(--gray-soft); }
.consume-table td { vertical-align: middle; transition: background .15s; }
.consume-table td:hover { background: rgba(0,0,0,.04); }
.consume-table .consume-badge { display: inline-block; min-width: 34px; padding: 2px 0; border-radius: 7px; font-weight: 800; font-size: 11px; }
.consume-table .consume-badge.full { color: #fff; background: var(--green); }
.consume-table .consume-badge.b80 { color: #fff; background: #1a9e8f; }
.consume-table .consume-badge.b50 { color: #fff; background: var(--brand); }
.consume-table .consume-badge.b30 { color: #fff; background: var(--orange); }
.consume-table .consume-badge.b10 { color: #fff; background: var(--red); }
.consume-meta { font-size: 10px; color: var(--muted); margin-top: 3px; }
.consume-rows { display: flex; flex-direction: column; gap: 10px; margin: 8px 0 14px; }
.ce-row { display: flex; align-items: center; gap: 12px; padding: 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); }
.ce-name { font-weight: 700; font-size: 14px; min-width: 80px; }
.ce-fields { display: flex; gap: 12px; flex: 1; }
.ce-fields .flow-field { flex: 1; }
.ce-meta { font-size: 12px; color: var(--muted); min-width: 130px; text-align: right; }

/* 主卫 / 次卫 逐瓶上报 */
.consume-stack { display: flex; flex-direction: column; gap: 3px; align-items: center; }
.consume-stack .cu { display: inline-flex; align-items: center; gap: 4px; }
.consume-stack .cu > i { font-style: normal; font-size: 10px; color: var(--muted); }
.cs-sub { font-size: 11px; font-weight: 400; color: var(--muted); margin-left: 4px; }

/* ---- 消耗品「是否投放」开关 ---- */
.deploy-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 14px; padding: 10px 12px; background: var(--bg); border: 1px solid var(--line); border-radius: 10px; }
.deploy-bar-title { font-weight: 700; font-size: 13px; color: var(--ink); flex: none; }
.deploy-bar-hint { font-size: 11px; color: var(--muted); flex: 1 1 220px; min-width: 200px; line-height: 1.5; }
.deploy-switch { display: inline-flex; align-items: center; gap: 7px; padding: 4px 12px 4px 8px; border: 1px solid var(--line); border-radius: 999px; background: #fff; font-size: 13px; font-weight: 700; color: var(--muted); cursor: pointer; user-select: none; transition: .15s; }
.deploy-switch:hover { border-color: #b9b9b9; }
.deploy-switch.on { background: var(--green-soft); border-color: #b8e7cc; color: var(--green); }
.deploy-switch input { -webkit-appearance: none; appearance: none; position: relative; width: 30px; height: 17px; margin: 0; border-radius: 999px; background: #cfd4d9; cursor: pointer; transition: .15s; flex: none; }
.deploy-switch input::after { content: ''; position: absolute; top: 2px; left: 2px; width: 13px; height: 13px; border-radius: 50%; background: #fff; transition: .15s; }
.deploy-switch input:checked { background: var(--green); }
.deploy-switch input:checked::after { left: 15px; }
.deploy-switch input:focus-visible { outline: 2px solid var(--brand, #2f6fd0); outline-offset: 1px; }
.cs-type.cs-off { background: #f7f8f9; border-style: dashed; }
.cs-type.cs-off .cs-name { color: var(--muted); }
.cb.off { color: var(--muted); background: #f2f3f4; border-style: dashed; }
.consume-table th { padding-top: 8px; padding-bottom: 8px; }
.consume-table th .cu-th-name { font-weight: 700; }
.consume-table th.cu-off-th .cu-th-name { color: var(--muted); }
/* 房间级投放小开关（每格右上角，2026-09-17 「按房间单独设」） */
.cu-rsw-td { position: relative; }
.cu-rsw { position: absolute; top: 3px; right: 3px; z-index: 2; font-size: 11px; line-height: 1; padding: 3px 6px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--muted); cursor: pointer; user-select: none; font-weight: 700; transition: .15s; }
.cu-rsw:hover { border-color: #b9b9b9; background: #f4f4f2; }
.cu-rsw.on { background: var(--green-soft); border-color: #b8e7cc; color: var(--green); }
.cu-rsw.off { background: #f1f1ef; border-color: #dcdcd8; color: #8d8d88; }
.cu-rsw.on:hover { background: #fdecea; border-color: #f3c4bd; color: #b3452f; }
.cu-seg { display: inline-flex; margin-top: 6px; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; background: #fff; }
.cu-seg-b { padding: 2px 9px; font-size: 11px; font-weight: 700; line-height: 1.6; color: var(--muted); background: #fff; cursor: pointer; user-select: none; transition: background .15s, color .15s; }
.cu-seg-b + .cu-seg-b { border-left: 1px solid var(--line); }
.cu-seg-b:hover { background: var(--bg); color: var(--ink); }
.cu-seg-b.on { background: var(--green); color: #fff; }
.cu-seg-b.on:hover { background: var(--green); color: #fff; }
.cu-seg-b.off { background: #9aa3ab; color: #fff; }
.cu-seg-b.off:hover { background: #8b949c; color: #fff; }
.consume-table td.cu-off-td { background: #fafbfb; }
.consume-table td.cu-off-td:hover { background: #f5f6f7; }
.cu-off-tag { display: inline-block; padding: 3px 9px; border-radius: 7px; border: 1px dashed #cfd4d9; background: #f2f3f4; color: var(--muted); font-size: 11px; font-weight: 700; }
.cu-off-inline { color: var(--muted); }
.ce-row-off { background: #f7f8f9; border-style: dashed; }
.ce-off-note { flex: 1; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 12px; color: var(--muted); }
.ce-off-link { display: block; margin-top: 4px; padding: 0; border: 0; background: none; color: var(--muted); font-size: 11px; font-weight: 400; text-decoration: underline; cursor: pointer; }
.ce-off-link:hover { color: var(--red); }
.ce-name-sub { display: block; font-size: 11px; font-weight: 400; color: var(--muted); margin-top: 2px; }
.ce-row-multi { align-items: flex-start; }
.ce-units { display: flex; flex-direction: column; gap: 8px; flex: 1; }
.ce-unit { display: flex; align-items: flex-end; gap: 10px; }
.ce-unit-tag { font-size: 12px; font-weight: 700; color: var(--brand); background: var(--brand-soft); border-radius: 6px; padding: 4px 8px; min-width: 48px; text-align: center; flex: none; }
.ce-unit .flow-field { flex: 1; }
.ce-unit-meta { font-size: 11px; color: var(--muted); min-width: 118px; text-align: right; flex: none; }
.ce-bathset { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 12px; margin: 0 0 12px; background: var(--bg); border: 1px solid var(--line); border-radius: 10px; }
.ce-bathset label { font-weight: 700; font-size: 13px; }
.ce-bathset .hint { font-size: 11px; color: var(--muted); }

/* ===== 保洁外包领任务 · 内部管理 ===== */
.kpi.yellow { background: #fbf3d6; color: #a07d00; }
.kpi.yellow .n { color: #a07d00; }
.kpi.blue { background: var(--brand-soft); color: var(--brand); }
.kpi.blue .n { color: var(--brand); }
.clean-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 12px; }
.cg-box { background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 14px; }
.cg-h { font-weight: 800; font-size: 14px; margin-bottom: 10px; }
.team-list { display: flex; flex-direction: column; gap: 8px; }
.team-row { display: flex; gap: 6px; align-items: center; }
.team-add { display: flex; gap: 6px; margin-top: 10px; }
.inp { padding: 7px 9px; border: 1px solid var(--line); border-radius: 8px; font-size: 13px; flex: 1; min-width: 0; }
.inp.sm { flex: 1; }
.inp.xs { width: 62px; flex: none; }
.link-row { margin: 8px 0; }
.link-row code { background: var(--panel); border: 1px dashed var(--line); border-radius: 8px; padding: 8px 10px; font-size: 12px; word-break: break-all; display: block; color: var(--brand); }
.misc-add { display: flex; gap: 6px; flex-wrap: wrap; margin: 8px 0 12px; }
.misc-add .inp { flex: 1; min-width: 140px; }
.misc-list, .claim-list { display: flex; flex-direction: column; gap: 8px; }
.misc-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; background: #fffbe6; border: 1px solid #f0e3b0; border-radius: 8px; padding: 8px 11px; font-size: 13px; }
.claim-row { display: flex; align-items: center; gap: 8px; background: var(--green-soft); border: 1px solid #b8e7cc; border-radius: 8px; padding: 8px 11px; font-size: 13px; flex-wrap: wrap; }
.claim-row .btn { margin-left: auto; }
@media (max-width: 760px) { .clean-grid { grid-template-columns: 1fr; } }

/* 营销中心 · 楼书内嵌版（去 iframe） */
.marketing-toolbar { display: flex; gap: 10px; align-items: center; margin: 10px 0 14px; flex-wrap: wrap; }

/* ---- 楼书作用域（样式只作用于 .loushu-scope 内，全部 ls- 前缀） ---- */
.loushu-scope {
  --ls-primary:#1a3a4a; --ls-primary-l:#264d5e; --ls-accent:#c9a96e; --ls-accent-l:#faf6ee;
  --ls-bg:#f8f6f2; --ls-text:#2c2c2c; --ls-muted:#7a7265; --ls-border:#e8e0d5;
  background: var(--ls-bg); border: 1px solid var(--ls-border); border-radius: 12px;
  overflow: hidden; color: var(--ls-text); line-height: 1.6; font-size: 13px;
}
.ls-layout { display: flex; align-items: stretch; }
/* 左侧：楼栋导览树 + 筛选 */
.ls-left { width: 250px; min-width: 250px; flex-shrink: 0; border-right: 1px solid var(--ls-border); background: #fff; display: flex; flex-direction: column; overflow-y: auto; max-height: calc(100vh - 200px); }
.ls-tree-header { padding: 14px 14px 10px; border-bottom: 1px solid var(--ls-border); font-size: 13px; font-weight: 700; color: var(--ls-primary); letter-spacing: 1px; display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.ls-tree-header::before { content: ''; display: inline-block; width: 3px; height: 14px; background: var(--ls-accent); border-radius: 2px; }
.ls-group { border-bottom: 1px solid var(--ls-border); }
.ls-group-title { padding: 11px 14px 7px; font-size: 12.5px; font-weight: 700; color: var(--ls-primary); cursor: pointer; user-select: none; display: flex; align-items: center; justify-content: space-between; transition: background .15s; }
.ls-group-title:hover { background: var(--ls-accent-l); }
.ls-arrow { font-size: 10px; color: var(--ls-muted); transition: transform .2s; }
.ls-arrow.open { transform: rotate(90deg); }
.ls-group-children { overflow: hidden; max-height: 600px; transition: max-height .3s ease; }
.ls-group-children.collapsed { max-height: 0; }
.ls-item { padding: 8px 14px 8px 28px; font-size: 12.5px; color: var(--ls-text); cursor: pointer; position: relative; display: flex; align-items: center; justify-content: space-between; border-left: 3px solid transparent; transition: all .15s; }
.ls-item::before { content: ''; position: absolute; left: 16px; top: 50%; transform: translateY(-50%); width: 5px; height: 5px; border-radius: 50%; background: #ccc; transition: background .15s; }
.ls-item:hover { background: var(--ls-accent-l); }
.ls-item:hover::before { background: var(--ls-accent); }
.ls-item.active { background: linear-gradient(90deg, var(--ls-accent-l), transparent); border-left-color: var(--ls-accent); font-weight: 600; color: var(--ls-primary); }
.ls-item.active::before { background: var(--ls-primary); }
.ls-badge { font-size: 9px; padding: 1px 6px; border-radius: 8px; font-weight: 600; flex-shrink: 0; margin-left: 6px; }
.ls-b-standard { background: rgba(26,58,74,.1); color: var(--ls-primary); }
.ls-b-hot { background: rgba(198,40,40,.1); color: #c62828; }
.ls-b-economy { background: rgba(46,125,50,.1); color: #2e7d32; }
.ls-b-yard { background: rgba(21,101,192,.1); color: #1560bd; }
.ls-code { font-size: 10px; color: var(--ls-muted); margin-right: 4px; }
.ls-fbar { flex-shrink: 0; background: linear-gradient(to bottom, #f8f6f3, #fff); padding: 10px 12px 14px; border-top: 1px solid var(--ls-border); margin-top: auto; }
.ls-frow { display: flex; flex-direction: column; gap: 5px; padding: 4px 0; }
.ls-fbtn { padding: 6px 12px; border-radius: 8px; font-size: 12px; border: 1px solid var(--ls-border); background: #fff; cursor: pointer; white-space: nowrap; color: var(--ls-text); font-weight: 500; text-align: left; transition: all .2s; }
.ls-fbtn.active { background: var(--ls-primary); color: #fff; border-color: var(--ls-primary); }
.ls-fbtn.active-gold { background: var(--ls-accent); color: #fff; border-color: var(--ls-accent); }
/* 右侧主内容 */
.ls-main { flex: 1; min-width: 0; }
.ls-header { background: linear-gradient(135deg, var(--ls-primary), var(--ls-primary-l)); color: #fff; padding: 18px 20px 14px; text-align: center; }
.ls-hsub { opacity: .65; font-size: 12px; letter-spacing: 1px; line-height: 1.6; margin: 0 0 8px; }
.ls-stats { display: flex; justify-content: center; gap: 24px; margin-top: 6px; }
.ls-hs-item { text-align: center; }
.ls-hs-num { font-size: 20px; font-weight: 700; color: var(--ls-accent); }
.ls-hs-lbl { font-size: 10px; opacity: .5; letter-spacing: 1.5px; }
.ls-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; padding: 16px; }
.ls-card { background: #fff; border-radius: 12px; overflow: hidden; border: 1px solid var(--ls-border); box-shadow: 0 2px 12px rgba(0,0,0,.06); display: flex; flex-direction: column; cursor: pointer; transition: all .25s; }
.ls-card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,.12); }
.ls-card.hidden { display: none; }
.ls-cover { height: 110px; position: relative; overflow: hidden; background: linear-gradient(135deg, var(--ls-primary), var(--ls-primary-l)); display: flex; align-items: center; justify-content: center; }
.ls-cover img { width: 44px; height: 44px; border-radius: 11px; object-fit: contain; background: rgba(255,255,255,.95); padding: 4px; }
.ls-cover-ov { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,.5)); display: flex; flex-direction: column; justify-content: flex-end; padding: 8px 10px; }
.ls-rcode { font-size: 12px; color: #fff; font-weight: 700; letter-spacing: 1px; }
.ls-badges { display: flex; gap: 4px; margin-top: 4px; flex-wrap: wrap; }
.ls-rbadge { font-size: 9px; padding: 2px 7px; border-radius: 8px; font-weight: 600; }
.rb-standard { background: rgba(26,58,74,.88); color: #fff; }
.rb-economy { background: rgba(46,125,50,.85); color: #fff; }
.rb-pool { background: rgba(230,80,0,.85); color: #fff; }
.rb-yard { background: rgba(21,101,192,.88); color: #fff; }
.rb-hot { background: rgba(198,40,40,.88); color: #fff; }
.ls-cbody { padding: 10px 12px 12px; flex: 1; display: flex; flex-direction: column; }
.ls-cname { font-size: 13px; font-weight: 700; color: var(--ls-primary); margin-bottom: 3px; }
.ls-cstyle { font-size: 11px; color: var(--ls-accent); font-weight: 600; margin-bottom: 4px; }
.ls-cdesc { font-size: 10.5px; color: var(--ls-muted); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-bottom: 8px; flex: 1; }
.ls-irow { display: flex; gap: 1px; background: var(--ls-accent-l); border-radius: 8px; overflow: hidden; }
.ls-icell { flex: 1; text-align: center; padding: 5px 2px; }
.ls-ival { font-size: 12px; font-weight: 700; color: var(--ls-primary); }
.ls-ilbl { font-size: 9px; color: var(--ls-muted); }
.ls-caction { display: flex; align-items: center; justify-content: center; margin-top: 8px; padding: 7px 0; background: linear-gradient(135deg, var(--ls-primary), var(--ls-primary-l)); border-radius: 8px; color: #fff; font-size: 11.5px; font-weight: 600; }
.ls-empty { display: none; text-align: center; padding: 50px 20px; color: var(--ls-muted); }
.ls-empty.show { display: block; }
.ls-empty span { font-size: 44px; display: block; margin-bottom: 8px; opacity: .3; }
.ls-footer { text-align: center; padding: 22px 16px; color: var(--ls-muted); font-size: 11px; border-top: 1px solid var(--ls-border); }
/* 详情页 */
.ls-dnav { background: var(--ls-primary); color: #fff; display: flex; align-items: center; padding: 12px 16px; gap: 12px; }
.ls-back { background: rgba(255,255,255,.15); border: none; color: #fff; padding: 8px 18px; border-radius: 20px; font-size: 13px; font-weight: 600; cursor: pointer; flex-shrink: 0; }
.ls-back:hover { background: rgba(255,255,255,.25); }
.ls-dtitle { font-size: 15px; font-weight: 600; letter-spacing: 1px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ls-dhead { background: linear-gradient(135deg, var(--ls-primary), var(--ls-primary-l)); color: #fff; padding: 30px 20px 26px; text-align: center; }
.ls-dbrand { font-size: 11px; letter-spacing: 5px; opacity: .6; margin-bottom: 8px; }
.ls-dname { font-size: 24px; font-weight: 700; letter-spacing: 2px; margin-bottom: 8px; }
.ls-dstyle { font-size: 14px; color: var(--ls-accent); margin-bottom: 14px; }
.ls-dtags { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }
.ls-dtag { padding: 5px 16px; border-radius: 15px; font-size: 11.5px; font-weight: 600; background: rgba(255,255,255,.15); }
.ls-ibar { display: flex; justify-content: space-around; padding: 16px 12px; background: #fff; border-bottom: 1px solid var(--ls-border); }
.ls-di { text-align: center; }
.ls-di-val { font-size: 20px; font-weight: 700; color: var(--ls-primary); }
.ls-di-lbl { font-size: 10px; color: var(--ls-muted); margin-top: 2px; }
.ls-tabs { display: flex; gap: 6px; padding: 12px 12px 0; overflow-x: auto; border-bottom: 1px solid var(--ls-border); background: #fff; }
.ls-tab { padding: 7px 18px; border-radius: 20px; font-size: 13px; border: 1.5px solid var(--ls-border); background: #fff; cursor: pointer; white-space: nowrap; color: var(--ls-muted); font-weight: 500; flex-shrink: 0; transition: all .25s; }
.ls-tab.active { background: var(--ls-primary); color: #fff; border-color: var(--ls-primary); }
.ls-psec { padding: 16px 12px; background: var(--ls-bg); }
.ls-dph { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.ls-dpt { font-size: 16px; font-weight: 700; color: var(--ls-primary); }
.ls-dpc { font-size: 12px; color: var(--ls-muted); background: var(--ls-accent-l); padding: 3px 12px; border-radius: 10px; }
.ls-pgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.ls-pitem { border-radius: 10px; overflow: hidden; background: #e8e0d5; aspect-ratio: 4/3; }
.ls-pitem img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ls-loading { text-align: center; padding: 50px 20px; color: var(--ls-muted); }
.ls-spin { width: 36px; height: 36px; border: 3px solid var(--ls-border); border-top-color: var(--ls-primary); border-radius: 50%; animation: lsspin .8s linear infinite; margin: 0 auto 14px; }
@keyframes lsspin { to { transform: rotate(360deg); } }
.ls-ddesc { padding: 20px 16px; background: #fff; border-top: 1px solid var(--ls-border); }
.ls-ddt { font-size: 15px; font-weight: 700; color: var(--ls-primary); margin-bottom: 10px; }
.ls-ddx { font-size: 13.5px; color: var(--ls-muted); line-height: 1.8; }

/* ===== 房源介绍 · 结构化排版（2026-09-22）
   类名与对外画册 public/loushu/index.html 里的 .dd-* 完全一致 —— 改样式必须两处同步。
   渲染函数：lsRenderDescHtml()（中台） / renderDescHtml()（画册） */
.ls-ddx .dd-lead {
  position: relative; margin: 0 0 18px; padding: 16px 18px 16px 20px;
  background: linear-gradient(135deg, #faf6ee 0%, #fffdfa 100%);
  border-radius: 10px; border-left: 3px solid var(--ls-accent);
  font-family: 'STSong', 'SimSun', 'Songti SC', serif;
  font-size: 14.5px; line-height: 2.05; color: #4f4739; letter-spacing: .5px;
}
.ls-ddx .dd-lead::after {
  content: ''; position: absolute; right: 14px; top: 14px;
  width: 6px; height: 6px; border-radius: 50%; background: var(--ls-accent); opacity: .4;
}
.ls-ddx .dd-para {
  margin: 0 0 14px; font-size: 13.5px; line-height: 1.95; color: var(--ls-muted);
  text-align: justify; word-break: break-word;
}
.ls-ddx .dd-sec { margin-bottom: 0; }
.ls-ddx .dd-sec + .dd-sec { margin-top: 16px; padding-top: 16px; border-top: 1px dashed var(--ls-border); }
.ls-ddx .dd-sec-h {
  display: inline-flex; align-items: center; gap: 6px;
  margin-bottom: 9px; padding: 5px 13px 5px 11px;
  background: var(--ls-accent-l); border-left: 3px solid var(--ls-accent);
  border-radius: 0 7px 7px 0;
  font-size: 13px; font-weight: 700; color: var(--ls-primary); letter-spacing: .6px;
}
.ls-ddx .dd-sec-h .dd-ico { font-size: 12px; line-height: 1; }
.ls-ddx .dd-sec-b {
  font-size: 13.5px; line-height: 1.95; color: var(--ls-muted);
  text-align: justify; word-break: break-word;
}

/* 编辑弹窗里的「排版会自动美化」提示 */
.ls-ef-tip {
  margin-top: 6px; padding: 8px 11px; border-radius: 7px;
  background: var(--ls-accent-l); color: #6b6153; font-size: 11.5px; line-height: 1.7;
}
.ls-ef-tip b { color: var(--ls-primary); }
.ls-qrow { display: flex; flex-wrap: wrap; gap: 8px; padding: 16px; background: #fff; }
.ls-qbadge { padding: 8px 14px; border-radius: 8px; font-size: 11px; color: var(--ls-muted); background: var(--ls-accent-l); font-weight: 500; }
@media (max-width: 760px) {
  .ls-layout { flex-direction: column; }
  .ls-left { width: 100%; min-width: 0; max-height: none; border-right: none; border-bottom: 1px solid var(--ls-border); }
  .ls-frow { flex-direction: row; flex-wrap: wrap; }
  .ls-fbtn { text-align: center; }
  .ls-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; padding: 12px 10px; }
  .ls-pgrid { grid-template-columns: repeat(2, 1fr); }
}

/* ===== 长租管理（棕色主题）===== */
.panel-longrent { border-color: #c4a882 !important; }
.lr-scroll { overflow-x: auto; }
table.lr-table { width: 100%; border-collapse: collapse; font-size: 13px; }
table.lr-table th, table.lr-table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid #e8dcc8; }
table.lr-table th { background: #f5e6d0; color: #8b5e2c; font-weight: 700; font-size: 12px; white-space: nowrap; }
table.lr-table tbody tr:hover { background: #faf3e4; }
tr.lr-row td:first-child { font-weight: 600; }
.tag-lr-active { display: inline-block; padding: 3px 10px; border-radius: 20px; font-size: 12px; font-weight: 600; background: #f0e0c8; color: #8b5e2c; border: 1px solid #ddb89a; margin: 2px 4px 2px 0; }
.tag-lr-vacant { display: inline-block; padding: 3px 10px; border-radius: 20px; font-size: 12px; font-weight: 600; background: #e8e0d8; color: #8a8a8a; border: 1px solid #ccc2b8; }
.btn-brown { background: #8b5e2c !important; color: #fff !important; border-color: #8b5e2c !important; }
.btn-brown:hover { background: #a07240 !important; }

/* ===== 管家交接 & 备忘录 合并面板 ===== */
.memo-block { margin: 0; }
.memo-h { font-size: 16px; font-weight: 700; margin: 0 0 6px; }
.memo-divider { border: none; border-top: 1px dashed var(--line); margin: 22px 0 18px; }

@media (max-width: 760px) {
  table.lr-table { min-width: 500px; font-size: 14px; }
  .panel-longrent { padding: 12px; }
}

/* ===== 话术卡面板 ===== */
.sc-panel { border-color: #d4af7a !important; }
.sc-header { margin-bottom: 14px; }
.sc-body { display: flex; gap: 16px; min-height: 480px; }
.sc-sidebar {
  flex: 0 0 200px; max-height: 560px; overflow-y: auto;
  background: linear-gradient(160deg, #1a1612, #151310);
  border: 1px solid rgba(216,192,160,.15); border-radius: 8px; padding: 10px;
}
.sc-sidebar::-webkit-scrollbar { width: 5px; }
.sc-sidebar::-webkit-scrollbar-thumb { background: rgba(216,192,160,.25); border-radius: 3px; }
.sc-part-label {
  font-size: 10px; letter-spacing: 2.5px; color: #d8c0a0;
  margin: 10px 0 6px; padding-left: 8px;
  border-left: 2px solid #d8c0a0; line-height: 1.3;
}
.sc-part-label:first-child { margin-top: 0; }
.sc-item {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 10px; border-radius: 5px; cursor: pointer;
  transition: background .15s; margin-bottom: 2px;
  font-size: 15px; color: #c4b8a4;
}
.sc-item:hover { background: rgba(216,192,160,.08); }
.sc-item.active { background: rgba(216,192,160,.14); border-left: 2px solid #d8c0a0; }
.sc-num {
  font-family: 'Cormorant Garamond', 'Times New Roman', serif;
  font-size: 16px; color: #d8c0a0; width: 28px; text-align: center; opacity: .8;
}
.sc-title { flex: 1; line-height: 1.3; }
.sc-tag {
  font-size: 9px; color: #d8c0a0; background: rgba(216,192,160,.12);
  padding: 1px 5px; border-radius: 8px; opacity: .75;
}
.sc-main { flex: 1; display: flex; flex-direction: column; gap: 12px; }
.sc-card-header {
  display: flex; align-items: center; gap: 10px;
  padding-bottom: 10px; border-bottom: 1px solid var(--line);
}
.sc-card-num {
  background: linear-gradient(135deg, #d8c0a0, #c4a982);
  color: #1a1612; font-weight: 800; font-size: 17px;
  padding: 4px 11px; border-radius: 6px;
}
.sc-card-title { font-size: 24px; font-weight: 800; color: var(--text); }
.sc-slogan {
  margin-left: auto; font-size: 16px; color: var(--muted);
  font-style: italic; letter-spacing: .5px;
}
.sc-card-body {
  background: linear-gradient(135deg, #fdfbf7, #f9f4eb);
  border: 1px solid #e8dcc8; border-radius: 10px;
  padding: 22px 26px; font-size: 18px; line-height: 2.1;
  color: #3a2f22; flex: 1; overflow-y: auto;
  white-space: pre-wrap; word-break: break-word;
  font-weight: 500;
}
/* 二维码缩小：保证手机能扫即可 */
.sc-card-body img {
  max-width: 140px !important;
  max-height: 140px !important;
  border-radius: 6px;
  border: 1px solid #e0d0a8;
}
.sc-card-body::-webkit-scrollbar { width: 5px; }
.sc-card-body::-webkit-scrollbar-thumb { background: #d4c4a8; border-radius: 3px; }
.sc-var {
  display: inline; background: #fff3cd; color: #856404;
  padding: 2px 6px; border-radius: 3px; font-weight: 700;
  font-size: 16px; border-bottom: 1px dashed #d4a020;
}
.sc-vars {
  background: #fffbf0; border: 1px solid #f0e3b0;
  border-radius: 6px; padding: 10px 14px;
}
.sc-vars-title { font-size: 16px; font-weight: 700; color: #8b6914; margin-bottom: 6px; }
.sc-var-item {
  display: inline-block; background: #fff; border: 1px solid #e0d0a8;
  padding: 4px 11px; border-radius: 5px; font-size: 16px;
  color: #6b5a30; margin: 2px 5px 2px 0; font-family: monospace;
}
.sc-actions { display: flex; gap: 10px; flex-wrap: wrap; }

@media (max-width: 760px) {
  .sc-body { flex-direction: column; min-height: auto; }
  .sc-sidebar { flex: none; max-height: 200px; }
  .sc-card-body { max-height: 280px; }
}

/* ===== 管家视图 Tab 栏 ===== */
.house-tab-bar {
  display: flex;
  gap: 0;
  border-bottom: 2px solid var(--line);
  margin-bottom: 16px;
}
.house-tab {
  padding: 10px 22px;
  border: none;
  background: transparent;
  font-size: 14px;
  font-weight: 600;
  color: var(--gray);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: all .2s;
  border-radius: 8px 8px 0 0;
}
.house-tab:hover { color: var(--ink); background: var(--gray-soft); }
.house-tab.active {
  color: var(--blue);
  border-bottom-color: var(--blue);
  background: linear-gradient(to top, rgba(59,130,246,.06), transparent);
}

/* ===== 管家每日必做 ===== */
.daily-tasks { padding: 4px 0; }
.daily-header { margin-bottom: 16px; }
.daily-section {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 12px;
}
.daily-section-title {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.daily-weekly { background: #fffbf0; border-color: #f0e3b0; }
.daily-list { display: flex; flex-direction: column; gap: 6px; }
.daily-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  cursor: pointer;
  transition: background .15s;
  font-size: 13px;
}
.daily-item:hover { background: rgba(0,0,0,.03); }
.daily-item input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--blue);
  flex-shrink: 0;
  cursor: pointer;
}
.daily-item span { flex: 1; }
.daily-hint {
  font-size: 11px;
  color: var(--gray);
  background: var(--gray-soft);
  padding: 2px 8px;
  border-radius: 10px;
  white-space: nowrap;
  flex-shrink: 0;
}
.daily-footer {
  display: flex;
  gap: 10px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px dashed var(--line);
}
@media (max-width: 760px) {
  .house-tab { padding: 8px 14px; font-size: 13px; }
  .daily-section { padding: 10px 12px; }
  .daily-hint { display: none; }
}

/* ============ 事项待办 ============ */
.view-header { margin-bottom: 14px; }
.view-header h2 { font-size: 20px; font-weight: 700; margin: 0 0 4px; }
.view-header .sub { color: var(--muted); font-size: 13px; }

.kpi-row { display: flex; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.kpi-card { background: var(--card); border-radius: 12px; padding: 12px 18px; min-width: 100px; text-align: center; box-shadow: 0 1px 4px rgba(0,0,0,0.06); border: 1px solid var(--line); }
.kpi-num { font-size: 26px; font-weight: 800; color: var(--primary); line-height: 1.2; }
.kpi-num.warn { color: #e53935; }
.kpi-num.ok { color: #43a047; }
.kpi-lbl { font-size: 11px; color: var(--muted); margin-top: 2px; }

.todo-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; gap: 10px; flex-wrap: wrap; }
.todo-filters { display: flex; gap: 6px; flex-wrap: wrap; }
.todo-filters .f-btn { padding: 6px 14px; font-size: 12.5px; border-radius: 20px; border: 1px solid var(--line); background: #fff; cursor: pointer; white-space: nowrap; transition: all 0.2s; }
.todo-filters .f-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }

/* 涉及人员快速筛选栏 */
.person-filter-bar {
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  padding: 10px 14px; background: #fafbff; border: 1px solid #e2e8f0;
  border-radius: 10px; margin-bottom: 14px;
}
.pf-label { font-size: 12.5px; font-weight: 700; color: #475569; white-space: nowrap; }
.pf-chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 12px; font-size: 12.5px; border-radius: 20px;
  border: 1px solid #cbd5e1; background: white; cursor: pointer;
  transition: all .15s; white-space: nowrap; color: #334155;
}
.pf-chip:hover { border-color: #818cf8; background: #eef2ff; }
.pf-chip.active { background: #6366f1; color: white; border-color: #6366f1; }
.pf-chip small { opacity: .7; font-size: 11px; }
.pf-chip.active small { opacity: .9; }

.todo-list { display: flex; flex-direction: column; gap: 8px; }
.empty-hint { text-align: center; color: var(--muted); padding: 40px 20px; font-size: 14px; }

.todo-card { display: flex; align-items: flex-start; gap: 10px; background: var(--card); border-radius: 12px; padding: 14px 16px; border: 1px solid var(--line); transition: all 0.2s; }
.todo-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.08); }
.todo-card.done { opacity: 0.6; background: #f9f9f9; }
.todo-card.done .todo-title { text-decoration: line-through; color: var(--muted); }
.todo-card.overdue { border-left: 3px solid #e53935; }

.todo-left { padding-top: 2px; }
.todo-cb { width: 20px; height: 20px; cursor: pointer; accent-color: var(--primary); flex-shrink: 0; }

.todo-body { flex: 1; min-width: 0; }
.todo-title { font-size: 15px; font-weight: 600; color: var(--ink); margin-bottom: 3px; word-break: break-word; }
.todo-desc { font-size: 13px; color: var(--muted); margin-bottom: 6px; line-height: 1.5; word-break: break-word; }
.todo-meta { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; font-size: 11.5px; }
.todo-pri { display: inline-block; padding: 1px 8px; border-radius: 10px; font-size: 11px; font-weight: 600; }
.pri-high { background: #fce4ec; color: #c62828; }
.pri-normal { background: #fff8e1; color: #e65100; }
.pri-low { background: #e8f5e9; color: #2e7d32; }
.todo-assign { color: var(--primary); font-weight: 500; }
.todo-deadline { color: var(--muted); }
.todo-deadline.late { color: #e53935; font-weight: 600; }
.todo-creator { color: var(--muted); }

.todo-actions { flex-shrink: 0; }

/* 待办弹窗（复用modal-overlay） */
#todoModal.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.45); z-index: 2000; display: none; align-items: center; justify-content: center; padding: 20px; }
#todoModal .modal { max-width: 520px; width: 100%; text-align: left; }
#todoModal .modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
#todoModal .modal-header h3 { font-size: 17px; font-weight: 700; margin: 0; }
#todoModal .modal-close { background: none; border: none; font-size: 24px; cursor: pointer; color: var(--muted); line-height: 1; }
#todoModal .modal-body { display: flex; flex-direction: column; gap: 12px; }
#todoModal .field label { font-size: 13px; font-weight: 600; color: var(--ink); margin-bottom: 3px; display: block; }
#todoModal .field input, #todoModal .field textarea, #todoModal .field select {
  width: 100%; padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px;
  font-size: 14px; font-family: inherit; box-sizing: border-box; background: #fff;
}
#todoModal .field textarea { resize: vertical; }
.field-row { display: flex; gap: 12px; }
.field-row .field.flex-1 { flex: 1; }
.req { color: #e53935; }
#todoModal .modal-footer { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }

/* ==================== 待办提醒（企业微信推送）2026-09-17 ==================== */
.todo-tools { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.todo-nb { border: 1px solid var(--line); }
.todo-nb.on { border-color: #2e7d32; color: #2e7d32; background: #eef7ee; font-weight: 600; }

.todo-nbar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  border-radius: 12px; padding: 11px 16px; margin-bottom: 14px; font-size: 13px;
}
.todo-nbar.on { background: #eef7ee; border: 1px solid #c6e3c8; }
.todo-nbar.off { background: #fff8e6; border: 1px solid #f0dfae; }
.todo-nbar .tnb-ico { font-size: 16px; }
.todo-nbar .tnb-main { font-weight: 700; color: var(--ink); }
.todo-nbar .tnb-sub { color: var(--muted); flex: 1; min-width: 200px; }
.todo-nbar .tnb-sub b { color: #e53935; }
.todo-nbar.on .tnb-sub b { color: #2e7d32; }
.todo-nbar .btn.sm { padding: 5px 12px; font-size: 12.5px; }

.todo-alarm { font-size: 11px; padding: 1px 7px; border-radius: 9px; font-weight: 600; }
.todo-alarm.late { background: #fdecea; color: #e53935; }
.todo-alarm.today { background: #fff3e0; color: #ef6c00; }
.todo-alarm.soon { background: #fff8e6; color: #a07900; }
.todo-alarm.none { background: #f2f2f2; color: #9e9e9e; font-weight: 400; }

#todoNotifyModal.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.45); z-index: 2100; display: none; align-items: center; justify-content: center; padding: 20px; }
#todoNotifyModal .modal { max-width: 580px; width: 100%; text-align: left; max-height: 90vh; overflow-y: auto; }
#todoNotifyModal .modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
#todoNotifyModal .modal-header h3 { font-size: 17px; font-weight: 700; margin: 0; }
#todoNotifyModal .modal-close { background: none; border: none; font-size: 24px; cursor: pointer; color: var(--muted); line-height: 1; }
#todoNotifyModal .modal-body { display: flex; flex-direction: column; gap: 13px; }
#todoNotifyModal .field label { font-size: 13px; font-weight: 600; color: var(--ink); margin-bottom: 3px; display: block; }
#todoNotifyModal .field input[type="text"], #todoNotifyModal .field input[type="time"], #todoNotifyModal .field select {
  width: 100%; padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px;
  font-size: 14px; font-family: inherit; box-sizing: border-box; background: #fff;
}
#todoNotifyModal .modal-footer { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; flex-wrap: wrap; }

.tn-tip { background: #eef4fb; border: 1px solid #cfe0f2; border-radius: 9px; padding: 9px 12px; font-size: 12.5px; color: #2c5a8c; line-height: 1.6; }
.tn-help { font-size: 11.5px; color: var(--muted); margin-top: 4px; line-height: 1.6; }
.tn-checks { display: flex; flex-direction: column; gap: 7px; padding: 8px 12px; background: var(--bg); border-radius: 9px; }
.tn-chk { font-size: 13px; display: flex; align-items: center; gap: 7px; cursor: pointer; font-weight: 400; }
.tn-chk input { width: 15px; height: 15px; accent-color: var(--primary); flex-shrink: 0; }
.tn-switch-row { display: flex; align-items: center; gap: 8px; font-size: 14px; cursor: pointer; background: #eef7ee; border: 1px solid #c6e3c8; border-radius: 9px; padding: 10px 12px; }
.tn-switch-row input { width: 17px; height: 17px; accent-color: #2e7d32; }

.tn-status { background: var(--bg); border-radius: 9px; padding: 10px 12px; font-size: 12px; color: var(--muted); }
.tn-status-head { line-height: 1.7; }
.tn-status-head b { color: #e53935; }
.tn-warn { margin-top: 6px; color: #ef6c00; font-weight: 600; }
.tn-log-title { margin: 8px 0 5px; font-weight: 600; color: var(--ink); }
.tn-log { display: flex; flex-direction: column; gap: 3px; max-height: 150px; overflow-y: auto; }
.tn-log-item { font-size: 11.5px; padding: 3px 0; border-bottom: 1px dashed rgba(0,0,0,0.06); line-height: 1.5; }
.tn-log-item:last-child { border-bottom: none; }
.tn-log-item.bad { color: #c62828; }
.tn-lt { color: var(--muted); font-family: ui-monospace, Consolas, monospace; }
.tn-log-empty { font-size: 12px; }

@media (max-width: 760px) {
  .kpi-row { gap: 6px; }
  .kpi-card { min-width: 72px; padding: 8px 10px; }
  .kpi-num { font-size: 20px; }
  .todo-toolbar { flex-direction: column; align-items: stretch; }
  .todo-filters { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; }
  .todo-card { padding: 10px 12px; }
  .field-row { flex-direction: column; gap: 0; }
}

/* ==================== 截图OCR识别录入 ==================== */
.ocr-parsed-box {
  background: var(--bg);
  border-radius: 8px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.ocr-field-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 0;
  border-bottom: 1px solid rgba(128,128,128,0.1);
}
.ocr-field-row:last-child { border-bottom: none; }
.ocr-fl {
  font-size: 12px;
  color: var(--sub);
  min-width: 42px;
  font-weight: 600;
}
.ocr-fv {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
}
.ocr-fv.ok { color: var(--green, #16a34a); }
.ocr-fv.miss { color: var(--orange, #f59e0b); }

.ocr-spinner {
  display: inline-block;
  width: 32px; height: 32px;
  border: 3px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: ocrSpin 0.8s linear infinite;
}
@keyframes ocrSpin { to { transform: rotate(360deg); } }

/* ==================== 入住率加强 ==================== */
.occ-bar-cell {
  min-width: 80px;
}
.occ-bar-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
}
.occ-bar-track {
  flex: 1;
  height: 14px;
  background: #e5e7eb;
  border-radius: 7px;
  overflow: hidden;
  min-width: 40px;
}
.occ-bar-fill {
  height: 100%;
  border-radius: 7px;
  transition: width 0.4s ease;
  background: linear-gradient(90deg, #16a34a, #22c55e);
}
.occ-bar-fill.mid { background: linear-gradient(90deg, #f59e0b, #fbbf24); }
.occ-bar-fill.low { background: linear-gradient(90deg, #ef4444, #f87171); }
.occ-pct {
  font-size: 13px;
  font-weight: 700;
  min-width: 36px;
  text-align: right;
}
.kpi.occ-highlight {
  background: linear-gradient(135deg, #eff6ff, #dbeafe);
  border: 2px solid #93c5fd;
}

/* ===== 楼书导览树：编辑/分享按钮 + 新增房源（2026-08-29） ===== */
.ls-item { justify-content: flex-start; gap: 6px; }
.ls-item-main { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ls-item-ops { flex: 0 0 auto; display: flex; gap: 1px; }
.ls-op { border: none; background: transparent; cursor: pointer; font-size: 12px; padding: 2px 4px; border-radius: 5px; opacity: .5; line-height: 1.2; }
.ls-op:hover { opacity: 1; background: rgba(0,0,0,.07); }
.ls-add-btn { margin-left: auto; border: 1px solid var(--ls-accent); background: transparent; color: var(--ls-primary); border-radius: 6px; font-size: 11.5px; padding: 3px 9px; cursor: pointer; white-space: nowrap; }
.ls-add-btn:hover { background: var(--ls-accent-l); }

/* ===== 楼书编辑弹窗 ===== */
#lsEditModal .modal { max-width: 690px; width: 100%; text-align: left; max-height: 92vh; overflow-y: auto; }
#lsEditModal .modal-sub { text-align: left; }
.ls-ef-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px 14px; }
.ls-ef-field label { display: block; font-size: 12px; color: #777; margin-bottom: 4px; }
.ls-ef-field input, .ls-ef-field select, .ls-ef-field textarea {
  width: 100%; box-sizing: border-box; padding: 8px 10px;
  border: 1px solid #ddd; border-radius: 8px; font-size: 14px; background: #fff;
}
.ls-ef-field textarea { min-height: 118px; resize: vertical; line-height: 1.75; }
.ls-ef-checks { display: flex; gap: 12px; flex-wrap: wrap; padding-top: 4px; }
.ls-ef-checks label { display: flex; align-items: center; gap: 4px; font-size: 13px; color: #444; margin: 0; }
.ls-ef-field label.ls-ef-inline { display: flex; align-items: center; gap: 6px; font-size: 13px; color: #444; margin: 0; padding-top: 6px; }
.ls-ph-sec { margin-top: 14px; border-top: 1px dashed #e5e0d8; padding-top: 10px; }
.ls-ph-tools { display: flex; gap: 8px; flex-wrap: wrap; }
.ls-eph-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; margin-top: 10px; }
.ls-eph { position: relative; border: 1px solid #e5e0d8; border-radius: 8px; overflow: hidden; background: #faf8f5; }
.ls-eph img { width: 100%; aspect-ratio: 4/3; object-fit: cover; display: block; }
.ls-eph select { width: 100%; border: none; border-top: 1px solid #eee; font-size: 12px; padding: 4px; background: #fff; }
.ls-eph-btns { position: absolute; top: 4px; right: 4px; display: flex; gap: 3px; }
.ls-eph-btns button { border: none; background: rgba(0,0,0,.5); color: #fff; border-radius: 5px; cursor: pointer; font-size: 11px; padding: 2px 6px; line-height: 1.4; }
.ls-eph-cover { position: absolute; top: 4px; left: 4px; background: var(--ls-accent, #c9a96e); color: #fff; font-size: 10px; padding: 1px 6px; border-radius: 4px; }
.ls-eph-empty { grid-column: 1 / -1; font-size: 13px; color: #999; background: #faf8f5; border: 1px dashed #e0dbd2; border-radius: 8px; padding: 14px; line-height: 1.6; }
.ls-eph-drop { margin-top: 10px; border: 2px dashed #d8d2c8; border-radius: 10px; background: #fbfaf7; padding: 16px; text-align: center; cursor: pointer; transition: background .15s, border-color .15s; }
.ls-eph-drop:hover { background: #f5f1ea; }
.ls-eph-drop.over { border-color: var(--ls-primary, #2f6fed); background: #eef4ff; }
.ls-eph-drop-inner { font-size: 14px; font-weight: 600; color: var(--ls-primary, #2f6fed); }
.ls-eph-drop-inner span { display: block; margin-top: 5px; font-size: 12px; font-weight: 400; color: #999; }
.ls-ef-btnrow { display: flex; gap: 10px; margin-top: 16px; flex-wrap: wrap; justify-content: flex-end; }
@media (max-width: 640px) { .ls-ef-grid { grid-template-columns: 1fr; } }
