:root {
  --brand: #10896B;
  --brand-dark: #0B6A52;
  --brand-soft: #E6F4EF;
  --text: #17201D;
  --text-2: #5C6764;
  --text-3: #97A19E;
  --line: #E9EEEC;
  --bg: #F4F6F5;
  --card: #FFFFFF;
  --danger: #C6403F;
  --danger-soft: #FBEDED;
  --warn: #A9761A;
  --warn-soft: #FBF1E0;
  --info: #2563EB;
  --info-soft: #EAF1FE;
  --shadow: 0 1px 3px rgba(23, 32, 29, .04), 0 8px 24px rgba(23, 32, 29, .04);
  --radius: 14px;
  --sidebar: 232px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

a { color: var(--brand); text-decoration: none; }
button { font-family: inherit; }
input, select, textarea { font-family: inherit; font-size: 14px; color: var(--text); }

/* ---------------- 布局 ---------------- */
.shell {
  display: grid;
  grid-template-columns: var(--sidebar) 1fr;
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  background: #fff;
  border-right: 1px solid var(--line);
  padding: 22px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 2px 10px 20px;
}

.brand-mark {
  width: 34px; height: 34px;
  border-radius: 10px;
  background: linear-gradient(140deg, #1AA57F, #0B6A52);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -.5px;
  box-shadow: 0 4px 10px rgba(16, 137, 107, .25);
}

.brand-name { font-size: 15px; font-weight: 650; letter-spacing: .2px; }
.brand-sub { font-size: 11px; color: var(--text-3); margin-top: 1px; }

.nav-group { margin-top: 14px; padding: 0 10px 6px; font-size: 11px; color: var(--text-3); letter-spacing: .8px; }

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 9px;
  color: var(--text-2);
  font-size: 13.5px;
  cursor: pointer;
  transition: background .15s, color .15s;
}

.nav-item:hover { background: #F5F8F7; color: var(--text); }
.nav-item.active { background: var(--brand-soft); color: var(--brand-dark); font-weight: 600; }
.nav-item .ico { width: 18px; text-align: center; opacity: .9; font-size: 15px; }
.nav-item .badge-mini {
  margin-left: auto;
  min-width: 18px; height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--danger);
  color: #fff;
  font-size: 11px;
  line-height: 18px;
  text-align: center;
  font-weight: 600;
}

.sidebar-foot {
  margin-top: auto;
  border-top: 1px solid var(--line);
  padding-top: 12px;
  display: flex;
  align-items: center;
  gap: 9px;
}

.avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--brand-soft);
  color: var(--brand-dark);
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 600;
  flex-shrink: 0;
}

.sidebar-foot .who { font-size: 12.5px; line-height: 1.3; min-width: 0; }
.sidebar-foot .who b { display: block; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-foot .who span { color: var(--text-3); font-size: 11px; }

.main { min-width: 0; display: flex; flex-direction: column; }

.topbar {
  height: 58px;
  padding: 0 26px;
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(244, 246, 245, .88);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid transparent;
}

.topbar.scrolled { border-bottom-color: var(--line); }
.topbar-title { font-size: 16px; font-weight: 650; letter-spacing: .2px; }
.topbar-sub { font-size: 12px; color: var(--text-3); }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 8px; }

.content { padding: 6px 26px 48px; max-width: 1180px; width: 100%; }

.tabbar { display: none; }

/* ---------------- 通用 ---------------- */
.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid rgba(233, 238, 236, .7);
}

.card + .card { margin-top: 14px; }

.card-hd {
  padding: 16px 18px 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.card-hd.bordered { padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.card-title { font-size: 14.5px; font-weight: 650; }
.card-sub { font-size: 12px; color: var(--text-3); }
.card-bd { padding: 16px 18px; }
.card-bd.tight { padding: 8px 18px; }
.card-hd .right { margin-left: auto; display: flex; align-items: center; gap: 8px; }

.section-title {
  font-size: 13px;
  color: var(--text-2);
  font-weight: 600;
  margin: 22px 2px 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.section-title .line { flex: 1; height: 1px; background: var(--line); }

.row { display: flex; align-items: center; gap: 10px; }
.between { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.col { display: flex; flex-direction: column; }
.wrap { flex-wrap: wrap; }
.mt6 { margin-top: 6px; } .mt10 { margin-top: 10px; } .mt14 { margin-top: 14px; }
.mt18 { margin-top: 18px; } .mt24 { margin-top: 24px; }
.muted { color: var(--text-2); }
.hint { color: var(--text-3); font-size: 12px; }
.strong { font-weight: 650; }
.mono { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; }
.ell { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.grow { flex: 1; min-width: 0; }
.center { text-align: center; }

/* 按钮 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 38px;
  padding: 0 16px;
  border-radius: 9px;
  border: 1px solid transparent;
  background: #F1F4F3;
  color: var(--text);
  font-size: 13.5px;
  font-weight: 500;
  cursor: pointer;
  transition: filter .15s, background .15s, box-shadow .15s;
  white-space: nowrap;
  user-select: none;
}
.btn:hover { filter: brightness(.975); }
.btn:active { transform: translateY(.5px); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 2px 8px rgba(16, 137, 107, .22); }
.btn-primary:hover { background: var(--brand-dark); filter: none; }
.btn-ghost { background: #fff; border-color: #D8E5E0; color: var(--brand-dark); }
.btn-danger { background: var(--danger-soft); color: var(--danger); }
.btn-dark { background: #1F2A27; color: #fff; }
.btn-sm { height: 30px; padding: 0 11px; font-size: 12.5px; border-radius: 7px; }
.btn-lg { height: 46px; padding: 0 22px; font-size: 15px; border-radius: 11px; }
.btn-block { width: 100%; }
.btn-link { background: none; border: none; color: var(--brand); padding: 0 4px; height: auto; font-size: 13px; cursor: pointer; }

/* 状态标签 */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 24px;
  padding: 0 9px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
  line-height: 1;
  white-space: nowrap;
}
.pill::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; opacity: .75; }
.pill.pending { background: var(--warn-soft); color: var(--warn); }
.pill.in_transit { background: var(--info-soft); color: var(--info); }
.pill.completed { background: var(--brand-soft); color: var(--brand-dark); }
.pill.rejected { background: var(--danger-soft); color: var(--danger); }
.pill.cancelled { background: #F1F3F2; color: var(--text-3); }
.pill.plain::before { display: none; }

.tag {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 8px;
  border-radius: 5px;
  font-size: 11.5px;
  background: #F2F5F4;
  color: var(--text-2);
  white-space: nowrap;
}
.tag.green { background: var(--brand-soft); color: var(--brand-dark); }
.tag.blue { background: var(--info-soft); color: var(--info); }
.tag.amber { background: var(--warn-soft); color: var(--warn); }
.tag.red { background: var(--danger-soft); color: var(--danger); }

/* 表单 */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
.form-grid .full { grid-column: 1 / -1; }

.field { padding: 13px 0; border-bottom: 1px solid var(--line); }
.field:last-child { border-bottom: none; }
.field-label { font-size: 12.5px; color: var(--text-2); margin-bottom: 6px; display: flex; align-items: center; gap: 4px; }
.field-label .req { color: var(--danger); }
.input, .select, .textarea {
  width: 100%;
  height: 40px;
  padding: 0 12px;
  border: 1px solid #E2E8E6;
  border-radius: 9px;
  background: #FBFCFC;
  outline: none;
  transition: border-color .15s, background .15s, box-shadow .15s;
}
.input:focus, .select:focus, .textarea:focus {
  border-color: var(--brand);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(16, 137, 107, .1);
}
.textarea { height: auto; min-height: 78px; padding: 10px 12px; resize: vertical; line-height: 1.6; }
.select { appearance: none; background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%2397A19E' stroke-width='1.4' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 11px center; padding-right: 30px; }
.input[type="datetime-local"], .input[type="date"] { padding-right: 8px; }

.checkline { display: flex; gap: 8px; flex-wrap: wrap; }
.check {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding: 0 12px;
  border: 1px solid #E2E8E6;
  border-radius: 9px;
  cursor: pointer;
  font-size: 13px;
  background: #FBFCFC;
  user-select: none;
}
.check input { accent-color: var(--brand); margin: 0; }
.check.on { border-color: var(--brand); background: var(--brand-soft); color: var(--brand-dark); }

/* 列表 */
.list { }
.list-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  transition: background .12s;
}
.list-item:last-child { border-bottom: none; }
.list-item:hover { background: #FAFCFB; }
.list-item .main-col { min-width: 0; flex: 1; }
.list-item .t1 { font-size: 13.5px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.list-item .t2 { font-size: 12px; color: var(--text-3); margin-top: 2px; display: flex; gap: 10px; flex-wrap: wrap; }
.list-item .t2 span { white-space: nowrap; }
.order-no { font-size: 12px; color: var(--text-3); font-variant-numeric: tabular-nums; letter-spacing: .2px; }

/* 表格 */
.table-wrap { overflow-x: auto; }
table.tb { width: 100%; border-collapse: collapse; font-size: 13px; }
table.tb th {
  text-align: left;
  font-weight: 500;
  color: var(--text-3);
  font-size: 12px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  background: #FAFBFA;
  white-space: nowrap;
}
table.tb td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
table.tb tbody tr { cursor: pointer; }
table.tb tbody tr:hover { background: #FAFCFB; }
table.tb tbody tr:last-child td { border-bottom: none; }
.tb-empty { padding: 46px 20px; text-align: center; color: var(--text-3); }

/* 空状态 */
.empty { padding: 52px 20px; text-align: center; }
.empty-ico {
  width: 52px; height: 52px;
  margin: 0 auto 12px;
  border-radius: 50%;
  background: #EFF4F2;
  display: grid;
  place-items: center;
  font-size: 22px;
  color: #B8C6C1;
}
.empty-t { font-size: 13.5px; color: var(--text-2); }
.empty-h { font-size: 12px; color: var(--text-3); margin-top: 4px; }

/* 统计卡 */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.stat {
  background: #fff;
  border-radius: var(--radius);
  border: 1px solid rgba(233, 238, 236, .8);
  box-shadow: var(--shadow);
  padding: 16px 16px 14px;
}
.stat .k { font-size: 12.5px; color: var(--text-3); display: flex; align-items: center; gap: 6px; }
.stat .v { font-size: 28px; font-weight: 650; letter-spacing: -.5px; margin-top: 6px; font-variant-numeric: tabular-nums; line-height: 1.1; }
.stat .v small { font-size: 12px; color: var(--text-3); font-weight: 400; margin-left: 3px; }
.stat.accent { background: linear-gradient(160deg, #12896B, #0B6A52); border: none; color: #fff; }
.stat.accent .k, .stat.accent .v small { color: rgba(255, 255, 255, .78); }

/* 待办入口 */
.todo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.todo-card {
  background: #fff;
  border: 1px solid rgba(233, 238, 236, .85);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 16px;
  cursor: pointer;
  transition: transform .15s, box-shadow .15s, border-color .15s;
  position: relative;
  overflow: hidden;
}
.todo-card:hover { transform: translateY(-2px); box-shadow: 0 6px 22px rgba(23, 32, 29, .08); border-color: #D9E7E2; }
.todo-card .tc-top { display: flex; align-items: center; gap: 8px; color: var(--text-2); font-size: 12.5px; }
.todo-card .tc-ico {
  width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center;
  background: var(--brand-soft); color: var(--brand-dark); font-size: 13px;
}
.todo-card.blue .tc-ico { background: var(--info-soft); color: var(--info); }
.todo-card.amber .tc-ico { background: var(--warn-soft); color: var(--warn); }
.todo-card .tc-num { font-size: 26px; font-weight: 650; margin-top: 8px; font-variant-numeric: tabular-nums; line-height: 1.1; }
.todo-card .tc-go { font-size: 12px; color: var(--text-3); margin-top: 2px; }

/* 时间轴 */
.timeline { position: relative; padding-left: 22px; }
.timeline::before {
  content: "";
  position: absolute;
  left: 5px; top: 8px; bottom: 6px;
  width: 2px;
  background: linear-gradient(#DFE9E5, #EEF3F1);
  border-radius: 2px;
}
.tl-item { position: relative; padding: 0 0 18px 0; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before {
  content: "";
  position: absolute;
  left: -22px; top: 5px;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid #C9D8D3;
  box-sizing: border-box;
}
.tl-item.done::before { border-color: var(--brand); background: var(--brand); box-shadow: 0 0 0 3px rgba(16, 137, 107, .12); }
.tl-item.bad::before { border-color: var(--danger); background: var(--danger); box-shadow: 0 0 0 3px rgba(198, 64, 63, .1); }
.tl-t { font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.tl-m { font-size: 12px; color: var(--text-3); margin-top: 2px; }

/* 照片 */
.photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.photo {
  position: relative;
  padding-top: 75%;
  border-radius: 9px;
  overflow: hidden;
  background: #F1F4F3;
  cursor: zoom-in;
}
.photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

.picker-grid { display: grid; grid-template-columns: repeat(auto-fill, 96px); gap: 8px; }
.picker-item {
  position: relative;
  width: 96px; height: 96px;
  border-radius: 9px;
  overflow: hidden;
  background: #F1F4F3;
}
.picker-item img { width: 100%; height: 100%; object-fit: cover; }
.picker-item .rm {
  position: absolute; top: 3px; right: 3px;
  width: 20px; height: 20px;
  border-radius: 50%;
  border: none;
  background: rgba(15, 20, 18, .58);
  color: #fff;
  font-size: 12px;
  line-height: 20px;
  cursor: pointer;
  padding: 0;
}
.picker-add {
  width: 96px; height: 96px;
  border-radius: 9px;
  border: 1px dashed #CFDCD8;
  background: #FAFCFB;
  color: var(--text-3);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  cursor: pointer;
  font-size: 11px;
}
.picker-add:hover { border-color: var(--brand); color: var(--brand); background: var(--brand-soft); }
.picker-add .p { font-size: 18px; line-height: 1; }

/* 弹层 */
.mask {
  position: fixed; inset: 0;
  background: rgba(15, 23, 20, .44);
  z-index: 90;
  animation: fade .16s ease;
}
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.sheet {
  position: fixed;
  z-index: 91;
  background: #fff;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  width: min(560px, calc(100vw - 32px));
  max-height: min(86vh, 780px);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 60px rgba(15, 23, 20, .22);
  animation: rise .18s ease;
}
.sheet-hd {
  display: flex; align-items: center; gap: 10px;
  padding: 18px 20px 12px;
  border-bottom: 1px solid var(--line);
}
.sheet-title { font-size: 15px; font-weight: 650; }
.sheet-x {
  margin-left: auto;
  border: none; background: none;
  font-size: 18px; color: var(--text-3);
  cursor: pointer; line-height: 1; padding: 2px 4px;
}
.sheet-bd { padding: 16px 20px; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.sheet-ft { display: flex; gap: 10px; padding: 12px 20px 18px; border-top: 1px solid var(--line); }
.sheet-ft .btn { flex: 1; }

.lightbox {
  position: fixed; inset: 0;
  background: rgba(10, 14, 12, .92);
  z-index: 120;
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  cursor: zoom-out;
  animation: fade .16s ease;
}
.lightbox img { max-width: 100%; max-height: 100%; border-radius: 6px; object-fit: contain; }

/* toast */
#toast-wrap {
  position: fixed; left: 50%; bottom: 90px;
  transform: translateX(-50%);
  z-index: 200;
  display: flex; flex-direction: column; gap: 8px; align-items: center;
  pointer-events: none;
}
.toast {
  background: rgba(23, 32, 29, .92);
  color: #fff;
  padding: 9px 16px;
  border-radius: 9px;
  font-size: 13px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .18);
  animation: rise .18s ease;
  max-width: 80vw;
}
.toast.err { background: #A93434; }
.toast.ok { background: #0E6E56; }

/* tabs */
.tabs {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  background: #EDF2F0;
  border-radius: 10px;
}
.tab {
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 13px;
  color: var(--text-2);
  cursor: pointer;
  border: none;
  background: none;
  white-space: nowrap;
}
.tab.active { background: #fff; color: var(--text); font-weight: 600; box-shadow: 0 1px 3px rgba(23, 32, 29, .08); }

.searchbar { position: relative; flex: 1; min-width: 150px; }
.searchbar input { padding-left: 32px; height: 38px; }
.searchbar .s-ico {
  position: absolute; left: 10px; top: 50%; transform: translateY(-50%);
  color: var(--text-3); font-size: 13px;
}

.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.filters .select, .filters .input { height: 36px; width: auto; min-width: 128px; background: #fff; }

.pager { display: flex; align-items: center; justify-content: space-between; padding: 12px 18px; border-top: 1px solid var(--line); }
.pager .info { font-size: 12px; color: var(--text-3); }

/* 首页 hero */
.hero {
  background: linear-gradient(135deg, #12896B 0%, #0B6A52 62%, #0A5B47 100%);
  border-radius: 16px;
  padding: 22px 22px;
  color: #fff;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 26px rgba(11, 106, 82, .18);
}
.hero::after {
  content: "";
  position: absolute;
  right: -60px; top: -80px;
  width: 240px; height: 240px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, .12), transparent 70%);
}
.hero h1 { margin: 0; font-size: 19px; font-weight: 650; letter-spacing: .2px; }
.hero p { margin: 6px 0 0; font-size: 12.5px; color: rgba(255, 255, 255, .78); }
.hero .hero-actions { margin-top: 16px; display: flex; gap: 10px; flex-wrap: wrap; }
.hero .btn-hero { background: #fff; color: var(--brand-dark); font-weight: 600; }
.hero .btn-hero-ghost { background: rgba(255, 255, 255, .12); color: #fff; border: 1px solid rgba(255, 255, 255, .24); }

/* 路由条 */
.route-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.route-node { display: flex; flex-direction: column; gap: 2px; }
.route-node .rn { font-size: 13.5px; font-weight: 600; }
.route-node .rs { font-size: 11.5px; color: var(--text-3); }
.route-arrow { color: #C3D2CD; font-size: 16px; }

/* 详情操作条 */
.action-bar {
  position: sticky;
  bottom: 0;
  background: rgba(255, 255, 255, .95);
  backdrop-filter: blur(8px);
  border-top: 1px solid var(--line);
  padding: 10px 18px calc(10px + env(safe-area-inset-bottom));
  display: flex; gap: 10px;
  margin: 16px -26px -48px;
  z-index: 15;
}
.action-bar .btn { flex: 1; }

/* 登录 */
.login-wrap {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(900px 460px at 15% -10%, #E3F2EC, transparent 60%),
    radial-gradient(760px 420px at 105% 105%, #E8F1EE, transparent 55%),
    #F4F6F5;
}
.login-card {
  width: 100%;
  max-width: 380px;
  background: #fff;
  border-radius: 18px;
  padding: 30px 28px 26px;
  box-shadow: 0 18px 50px rgba(23, 32, 29, .09);
  border: 1px solid rgba(233, 238, 236, .8);
}
.login-brand { display: flex; align-items: center; gap: 11px; margin-bottom: 22px; }
.login-brand .brand-mark { width: 40px; height: 40px; border-radius: 12px; font-size: 17px; }
.login-h1 { font-size: 18px; font-weight: 650; margin: 0; letter-spacing: .2px; }
.login-sub { font-size: 12px; color: var(--text-3); margin-top: 2px; }
.login-card .field { border-bottom: none; padding: 8px 0; }
.login-card .field-label { margin-bottom: 6px; }
.login-card .input { height: 44px; background: #FAFCFB; }
.login-foot { margin-top: 16px; font-size: 11.5px; color: var(--text-3); text-align: center; line-height: 1.7; }
.demo-hint {
  margin-top: 14px;
  background: #F7FAF9;
  border: 1px dashed #DCE8E4;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 11.5px;
  color: var(--text-2);
  line-height: 1.7;
}
.demo-hint[hidden] { display: none !important; }
.demo-hint b { color: var(--text); font-weight: 600; }
.dh-t { color: var(--text-3); margin-bottom: 3px; }
.dh-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 1px 0; }
.dh-row b { font-variant-numeric: tabular-nums; }

/* 图表 */
.bars { display: flex; align-items: flex-end; gap: 10px; height: 142px; padding-top: 4px; }
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; min-width: 0; }
.bar-hold {
  width: 100%;
  max-width: 34px;
  flex: 1;
  background: #F6F9F8;
  border-radius: 6px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}
.bar {
  width: 100%;
  border-radius: 6px 6px 3px 3px;
  background: linear-gradient(180deg, #34A98A, #10896B);
  min-height: 3px;
  transition: height .5s cubic-bezier(.2, .8, .3, 1);
}
.bar.zero { background: #DCE6E2; }
.bar-col .bl { font-size: 10.5px; color: var(--text-3); }
.bar-col .bv { font-size: 10.5px; color: var(--text-2); font-variant-numeric: tabular-nums; height: 15px; }

/* 响应式 */
@media (max-width: 960px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar { display: none; }
  .content { padding: 4px 16px calc(84px + env(safe-area-inset-bottom)); max-width: 100%; }
  .topbar { padding: 0 16px; height: 54px; }
  .stats { grid-template-columns: 1fr 1fr; }
  .todo-grid { grid-template-columns: 1fr 1fr; }
  .todo-grid .todo-card:last-child { grid-column: 1 / -1; }
  .form-grid { grid-template-columns: 1fr; }
  .tabbar {
    display: flex;
    position: fixed;
    left: 0; right: 0; bottom: 0;
    height: calc(58px + env(safe-area-inset-bottom));
    padding-bottom: env(safe-area-inset-bottom);
    background: rgba(255, 255, 255, .97);
    backdrop-filter: blur(12px);
    border-top: 1px solid var(--line);
    z-index: 30;
  }
  .tabbar .tb-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    color: var(--text-3);
    font-size: 10.5px;
    cursor: pointer;
    position: relative;
  }
  .tabbar .tb-item .i { font-size: 18px; line-height: 1; }
  .tabbar .tb-item.active { color: var(--brand); font-weight: 600; }
  .tabbar .tb-item .dot {
    position: absolute;
    top: 8px;
    left: 54%;
    min-width: 15px; height: 15px;
    border-radius: 8px;
    background: var(--danger);
    color: #fff;
    font-size: 9.5px;
    line-height: 15px;
    text-align: center;
    padding: 0 3px;
    font-weight: 600;
  }
  .sheet {
    left: 0; right: 0; bottom: 0; top: auto;
    transform: none;
    width: 100%;
    max-height: 90vh;
    border-radius: 18px 18px 0 0;
    animation: slideUp .22s ease;
  }
  @keyframes slideUp { from { transform: translateY(100%); } to { transform: none; } }
  .action-bar { margin: 16px -16px 0; padding-bottom: calc(10px + env(safe-area-inset-bottom)); }
  .list-item { padding: 13px 14px; }
  .card-hd { padding: 14px 14px 0; }
  .card-bd { padding: 14px; }
  .card-bd.tight { padding: 6px 14px; }
  .hide-m { display: none !important; }
  .hero { padding: 18px; }
  .hero h1 { font-size: 17px; }
  .login-wrap { align-items: flex-start; padding-top: 8vh; }
}

@media (max-width: 400px) {
  .stats { gap: 8px; }
  .todo-grid { gap: 8px; }
  .stat { padding: 13px 12px; }
  .stat .v { font-size: 24px; }
  .photo-grid { grid-template-columns: repeat(auto-fill, minmax(80px, 1fr)); }
}

@media (min-width: 961px) {
  .only-m { display: none !important; }
}
