/* ============================================================
   家约医护 · 移动端原型（居民端 / 医护端）
   设计基线：医疗蓝白 / 375px 视口 / uni-app + rpx 可直接映射
   ============================================================ */

:root {
  --brand: #1d6fe0;
  --brand-deep: #14549e;
  --brand-soft: #e8f2fe;
  --brand-line: #cfe2f8;
  --sky: #38bdf8;

  --bg: #f5f8fc;
  --surface: #ffffff;
  --surface-alt: #f7fafd;
  --border: #e4ecf6;
  --border-strong: #d5e3f2;

  --text: #132033;
  --sub: #5b7089;
  --muted: #8fa3b8;

  --success: #0e9f6e;
  --success-soft: #e7f7f1;
  --warn: #b45309;
  --warn-soft: #fdf4e6;
  --danger: #dc2626;
  --danger-soft: #fdecec;

  --radius: 12px;
  --radius-sm: 9px;
  --shadow: 0 2px 10px rgba(19, 32, 51, 0.05);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 26px 16px;
  background: #dfe8f3;
  font-family: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", system-ui, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--brand); text-decoration: none; }
button, input, textarea, select { font-family: inherit; font-size: inherit; color: inherit; }
h1, h2, h3, p, ul { margin: 0; padding: 0; }
ul { list-style: none; }
svg { display: block; }

/* ---------- 手机外壳 ---------- */
.phone {
  position: relative;
  width: 375px;
  height: 812px;
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border: 8px solid #101d2c;
  border-radius: 42px;
  overflow: hidden;
  box-shadow: 0 26px 60px rgba(12, 32, 56, 0.28);
}

.statusbar {
  flex: 0 0 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px 0 24px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.3px;
  background: #ffffff;
  position: relative;
  z-index: 5;
}
.statusbar.on-blue { color: #fff; }
.statusbar .sb-right { display: flex; align-items: center; gap: 5px; }

.navbar {
  flex: 0 0 44px;
  height: 44px;
  display: flex;
  align-items: center;
  padding: 0 12px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: relative;
  z-index: 6;
}
.navbar .nb-title {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-size: 16px;
  font-weight: 600;
  white-space: nowrap;
}
.navbar .nb-back {
  width: 32px; height: 32px;
  display: grid; place-items: center;
  color: var(--text);
  border-radius: 8px;
}
.navbar .nb-right { margin-left: auto; font-size: 12.5px; color: var(--muted); }
.navbar.transparent { background: transparent; border-bottom: 0; }
.navbar.transparent .nb-title, .navbar.transparent .nb-back { color: #fff; }

.screen {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 12px;
  padding-bottom: 22px;
}
.screen.no-pad { padding: 0; }
.screen::-webkit-scrollbar { width: 0; }

.tabbar {
  flex: 0 0 58px;
  height: 58px;
  display: flex;
  background: rgba(255, 255, 255, 0.97);
  border-top: 1px solid var(--border);
  padding-bottom: env(safe-area-inset-bottom);
}
.tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-size: 10.5px;
  color: var(--muted);
}
.tab.active { color: var(--brand); font-weight: 500; }

/* ---------- 通用 ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.card-pad { padding: 14px; }
.card + .card { margin-top: 10px; }

.section-hd {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 16px 2px 8px;
}
.section-hd .t { font-size: 15px; font-weight: 600; }
.section-hd .s { font-size: 11.5px; color: var(--muted); }
.section-hd .more { margin-left: auto; font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 2px; }

.row { display: flex; align-items: center; gap: 8px; }
.row.between { justify-content: space-between; }
.grow { flex: 1; min-width: 0; }
.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.muted { color: var(--muted); }
.sub { color: var(--sub); }
.fs11 { font-size: 11px; }
.fs12 { font-size: 12px; }
.fs13 { font-size: 13px; }
.bold { font-weight: 600; }
.num { font-variant-numeric: tabular-nums; }

.divider { height: 1px; background: var(--border); margin: 12px 0; }
.dashed { height: 1px; background: repeating-linear-gradient(90deg, var(--border) 0 5px, transparent 5px 10px); margin: 10px 0; }

/* ---------- 按钮 ---------- */
.btn {
  height: 44px;
  padding: 0 18px;
  border: 0;
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  font-size: 15px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:active { background: var(--brand-deep); }
.btn-soft { background: var(--brand-soft); color: var(--brand-deep); }
.btn-outline { background: transparent; border: 1px solid var(--border-strong); color: var(--sub); }
.btn-danger-line { background: #fff; border: 1px solid #f2cfcf; color: var(--danger); }
.btn-block { width: 100%; }
.btn-sm { height: 32px; padding: 0 12px; font-size: 12.5px; border-radius: 8px; }
.btn-xs { height: 27px; padding: 0 10px; font-size: 12px; border-radius: 7px; }
.btn[disabled] { opacity: 0.45; }

/* ---------- 表单 ---------- */
.field { display: flex; flex-direction: column; gap: 6px; }
.label { font-size: 12.5px; color: var(--sub); font-weight: 500; }
.input, .textarea {
  width: 100%;
  height: 42px;
  padding: 0 12px;
  border: 1px solid var(--border-strong);
  border-radius: 9px;
  background: #fff;
  outline: none;
  font-size: 14px;
}
.textarea { height: auto; min-height: 78px; padding: 10px 12px; resize: none; }
.input:focus, .textarea:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(29, 111, 224, 0.1); }
.input::placeholder, .textarea::placeholder { color: #b3c1d1; }

.form-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 0;
  border-bottom: 1px solid var(--border);
}
.form-row:last-child { border-bottom: 0; }
.form-row .k { width: 74px; flex: 0 0 74px; font-size: 13px; color: var(--sub); }
.form-row .v { flex: 1; min-width: 0; font-size: 13.5px; text-align: right; }
.form-row .v.ph { color: #b3c1d1; }

/* ---------- 徽章 / 标签 ---------- */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 21px;
  padding: 0 7px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 500;
  white-space: nowrap;
}
.pill-blue { background: var(--brand-soft); color: var(--brand-deep); }
.pill-sky { background: #e6f6ff; color: #0b6a8f; }
.pill-green { background: var(--success-soft); color: #0b7a56; }
.pill-amber { background: var(--warn-soft); color: #93500a; }
.pill-red { background: var(--danger-soft); color: #b22020; }
.pill-gray { background: #f1f5f9; color: #64748b; }

/* ---------- 价格 ---------- */
.price { color: var(--brand); font-weight: 600; font-variant-numeric: tabular-nums; }
.price .cny { font-size: 12px; font-weight: 500; margin-right: 1px; }
.price .unit { font-size: 11px; color: var(--muted); font-weight: 400; margin-left: 2px; }
.price-lg { font-size: 22px; }

/* ---------- 居民端首页 ---------- */
.home-hero {
  position: relative;
  padding: 4px 14px 58px;
  background: linear-gradient(150deg, #1d6fe0 0%, #2f8ef5 58%, #38bdf8 100%);
  color: #fff;
  overflow: hidden;
}
.home-hero::after {
  content: "";
  position: absolute;
  width: 220px; height: 220px;
  right: -80px; top: -90px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
}
.hero-top { display: flex; align-items: center; gap: 8px; position: relative; z-index: 1; }
.hero-loc { display: flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 500; }
.hero-entry {
  margin-left: auto;
  height: 24px;
  padding: 0 9px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  font-size: 11px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.searchbar {
  position: relative;
  z-index: 1;
  margin-top: 12px;
  height: 38px;
  border-radius: 19px;
  background: rgba(255, 255, 255, 0.96);
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 14px;
  color: var(--muted);
  font-size: 13px;
  box-shadow: 0 4px 14px rgba(10, 45, 90, 0.12);
}
.hero-sub { position: relative; z-index: 1; margin-top: 14px; font-size: 11.5px; color: rgba(255, 255, 255, 0.85); }
.hero-body { position: relative; margin-top: -46px; padding: 0 12px; }

.banner {
  height: 96px;
  border-radius: 12px;
  background: linear-gradient(120deg, #eaf4ff, #d9ecff);
  border: 1px solid var(--brand-line);
  display: flex;
  align-items: center;
  padding: 0 16px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}
.banner::after {
  content: "";
  position: absolute; right: -20px; bottom: -30px;
  width: 110px; height: 110px; border-radius: 50%;
  background: rgba(56, 189, 248, 0.18);
}
.banner h3 { font-size: 15px; font-weight: 600; color: var(--brand-deep); }
.banner p { font-size: 11.5px; color: var(--sub); margin-top: 3px; }

.cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; padding: 14px 6px; }
.cat { display: flex; flex-direction: column; align-items: center; gap: 7px; }
.cat .ic {
  width: 44px; height: 44px;
  border-radius: 14px;
  background: var(--brand-soft);
  display: grid; place-items: center;
  color: var(--brand);
}
.cat span { font-size: 11.5px; color: var(--sub); }

.svc-card {
  display: flex;
  gap: 12px;
  padding: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 10px;
}
.svc-thumb {
  width: 82px; height: 82px;
  flex: 0 0 82px;
  border-radius: 10px;
  background: linear-gradient(140deg, #e8f2fe, #d7e9fb);
  display: grid; place-items: center;
  color: #9dc2ea;
}
.svc-info { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.svc-name { font-size: 14.5px; font-weight: 600; }
.svc-desc { font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.svc-meta { display: flex; align-items: center; gap: 6px; margin-top: 7px; flex-wrap: wrap; }
.svc-op { display: flex; align-items: center; gap: 4px; font-size: 11px; color: var(--sub); }
.svc-foot { display: flex; align-items: flex-end; justify-content: space-between; margin-top: auto; padding-top: 6px; }
.fee { font-size: 10.5px; color: #6b7f94; margin-top: 2px; }

/* ---------- 服务列表（左侧分类） ---------- */
.list-banner {
  height: 132px;
  background: linear-gradient(135deg, #dcebfb, #eaf4ff 60%, #d5e9fc);
  overflow: hidden;
}
.list-banner img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sort-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: #fff;
  border-bottom: 1px solid var(--border);
}
.sort-select {
  border: 0;
  background: transparent;
  font-size: 12.5px;
  color: var(--sub);
  padding: 2px 16px 2px 0;
  appearance: none;
  -webkit-appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, #8fa3b8 50%), linear-gradient(135deg, #8fa3b8 50%, transparent 50%);
  background-position: calc(100% - 8px) 55%, calc(100% - 4px) 55%;
  background-size: 4px 4px, 4px 4px;
  background-repeat: no-repeat;
  outline: none;
}
.list-body { display: flex; align-items: stretch; background: #fff; }
.cat-side {
  width: 82px;
  flex: 0 0 82px;
  background: #f5f8fc;
  padding: 6px 0 24px;
}
.cat-side button {
  display: block;
  width: 100%;
  padding: 15px 4px;
  border: 0;
  background: transparent;
  font-size: 12.5px;
  color: var(--sub);
  text-align: center;
  cursor: pointer;
}
.cat-side button.active {
  background: #fff;
  color: var(--brand);
  font-weight: 600;
  position: relative;
}
.cat-side button.active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 18px;
  border-radius: 0 3px 3px 0;
  background: var(--brand);
}
.list-main { flex: 1; min-width: 0; padding: 10px 10px 0; }
.svc-list .svc-card {
  gap: 10px;
  padding: 10px 0;
  border: 0;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  box-shadow: none;
  background: transparent;
  margin: 0;
}
.svc-list .svc-thumb { width: 70px; height: 70px; flex: 0 0 70px; border-radius: 9px; }
.svc-list .svc-name { font-size: 13.5px; line-height: 1.45; }
.svc-list .svc-desc {
  font-size: 11px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.svc-list .svc-meta { margin-top: 5px; }
.svc-list .price { font-size: 15px; }
.list-end { padding: 18px 0 26px; text-align: center; font-size: 11.5px; color: var(--muted); }

/* ---------- 详情 ---------- */
.detail-cover {
  height: 190px;
  background: linear-gradient(150deg, #dcebfb, #eaf4ff 55%, #d5e9fc);
  display: grid;
  place-items: center;
  color: #a8c8e8;
  position: relative;
}
.detail-body { margin-top: -18px; border-radius: 18px 18px 0 0; background: var(--bg); position: relative; padding: 14px 12px 0; }
.detail-title { font-size: 18px; font-weight: 600; }
.detail-price { display: flex; align-items: baseline; gap: 6px; margin-top: 6px; }

.buybar {
  position: sticky;
  bottom: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, 0.98);
  border-top: 1px solid var(--border);
  z-index: 8;
}
.buybar .total { flex: 1; }
.buybar .total .t { font-size: 10.5px; color: var(--muted); }
.buybar .btn { flex: 0 0 132px; }

/* ---------- 分段 / Tabs ---------- */
.seg {
  display: flex;
  gap: 2px;
  padding: 3px;
  background: #edf3fa;
  border-radius: 9px;
}
.seg button {
  flex: 1;
  height: 30px;
  border: 0;
  background: transparent;
  border-radius: 7px;
  font-size: 12.5px;
  color: var(--sub);
}
.seg button.active { background: #fff; color: var(--brand); font-weight: 500; box-shadow: 0 1px 3px rgba(19,32,51,.08); }

.tabs-line {
  display: flex;
  gap: 18px;
  padding: 12px 14px 0;
  background: #fff;
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
}
.tabs-line a {
  position: relative;
  padding-bottom: 10px;
  font-size: 13.5px;
  color: var(--sub);
  white-space: nowrap;
}
.tabs-line a.active { color: var(--brand); font-weight: 600; }
.tabs-line a.active::after {
  content: "";
  position: absolute;
  left: 50%; bottom: 0;
  width: 18px; height: 2.5px;
  border-radius: 2px;
  background: var(--brand);
  transform: translateX(-50%);
}

/* ---------- 订单卡 ---------- */
.order-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 13px;
  margin-bottom: 10px;
}
.order-hd { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.order-hd .no { font-size: 11.5px; color: var(--muted); }
.order-body { display: flex; gap: 11px; }
.order-thumb {
  width: 58px; height: 58px; flex: 0 0 58px;
  border-radius: 9px;
  background: linear-gradient(140deg, #e8f2fe, #d7e9fb);
  display: grid; place-items: center;
  color: #a8c8e8;
}
.order-amount { display: flex; align-items: center; justify-content: space-between; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); font-size: 12px; color: var(--sub); }
.order-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 10px; }

/* ---------- 金额明细 ---------- */
.money-row { display: flex; align-items: center; justify-content: space-between; padding: 8px 0; font-size: 13px; }
.money-row .k { color: var(--sub); display: flex; align-items: center; gap: 5px; }
.money-row .v { font-variant-numeric: tabular-nums; font-weight: 500; }
.money-row.total { border-top: 1px solid var(--border); margin-top: 4px; padding-top: 11px; }
.money-row.total .v { color: var(--brand); font-size: 17px; font-weight: 600; }

/* ---------- 进度 / 时间线 ---------- */
.steps { display: flex; align-items: flex-start; padding: 4px 0 2px; }
.step { flex: 1; text-align: center; position: relative; font-size: 10.5px; color: var(--muted); }
.step .dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: #dbe6f2;
  margin: 0 auto 6px;
  position: relative;
  z-index: 2;
}
.step::before {
  content: "";
  position: absolute;
  top: 4px; left: -50%;
  width: 100%; height: 1.5px;
  background: #dbe6f2;
}
.step:first-child::before { display: none; }
.step.done { color: var(--brand-deep); }
.step.done .dot { background: var(--brand); }
.step.done::before { background: var(--brand); }
.step.current { color: var(--brand); font-weight: 600; }
.step.current .dot { background: #fff; border: 2.5px solid var(--brand); box-shadow: 0 0 0 3px rgba(29,111,224,.14); }

.timeline { padding-left: 4px; }
.tl-item { display: flex; gap: 10px; position: relative; padding-bottom: 16px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before { content: ""; position: absolute; left: 4px; top: 12px; bottom: 0; width: 1px; background: var(--border); }
.tl-item:last-child::before { display: none; }
.tl-dot { width: 9px; height: 9px; border-radius: 50%; margin-top: 4px; flex: 0 0 9px; background: #dbe6f2; }
.tl-item.done .tl-dot { background: var(--brand); }
.tl-item.current .tl-dot { background: #fff; border: 2px solid var(--brand); width: 10px; height: 10px; flex: 0 0 10px; margin-left: -0.5px; }
.tl-t { font-size: 12.5px; font-weight: 500; }
.tl-m { font-size: 11px; color: var(--muted); margin-top: 1px; }

/* ---------- 服务人员 ---------- */
.avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, #2f8ef5, #38bdf8);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  display: grid; place-items: center;
  flex: 0 0 40px;
}

/* ---------- 底部操作条 ---------- */
.actionbar {
  position: sticky;
  bottom: 0;
  display: flex;
  gap: 9px;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, 0.98);
  border-top: 1px solid var(--border);
}
.actionbar .btn { flex: 1; }
.actionbar .btn.wide { flex: 2; }

/* ---------- 提示条 ---------- */
.notice {
  display: flex;
  gap: 7px;
  padding: 9px 11px;
  border-radius: 9px;
  font-size: 11.5px;
  line-height: 1.65;
  background: var(--brand-soft);
  color: #175a9e;
  border: 1px solid #d6e7fb;
}
.notice.warn { background: var(--warn-soft); color: #8a5408; border-color: #f2e2c8; }
.notice.green { background: var(--success-soft); color: #0b6f50; border-color: #cfebdf; }
.notice .ni { flex: 0 0 14px; margin-top: 1px; }

/* ---------- 底部弹层 ---------- */
.scrim {
  position: absolute;
  inset: 0;
  background: rgba(10, 26, 44, 0.42);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  z-index: 20;
}
.scrim.open { opacity: 1; pointer-events: auto; }
.sheet {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  background: #fff;
  border-radius: 18px 18px 0 0;
  transform: translateY(102%);
  transition: transform 0.26s cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 21;
  max-height: 78%;
  display: flex;
  flex-direction: column;
}
.sheet.open { transform: none; }
.sheet-hd {
  padding: 15px 16px 10px;
  text-align: center;
  position: relative;
  border-bottom: 1px solid var(--border);
}
.sheet-hd .st { font-size: 15px; font-weight: 600; }
.sheet-hd .ss { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.sheet-bd { padding: 14px 16px; overflow-y: auto; }
.sheet-ft { padding: 10px 16px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--border); }

/* ---------- 星级 ---------- */
.stars { display: flex; gap: 6px; justify-content: center; }
.star { color: #dfe7f0; }
.star.on { color: #f5a623; }

/* ---------- 我的 ---------- */
.me-hero {
  background: linear-gradient(150deg, #1d6fe0, #2f8ef5 60%, #38bdf8);
  color: #fff;
  padding: 10px 16px 46px;
  position: relative;
  overflow: hidden;
}
.me-hero::after {
  content: "";
  position: absolute; right: -50px; top: -60px;
  width: 170px; height: 170px; border-radius: 50%;
  background: rgba(255,255,255,.13);
}
.me-card {
  margin: -34px 12px 0;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 6px 18px rgba(19,32,51,.08);
  padding: 14px;
  position: relative;
}
.me-cell {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 14px;
  background: #fff;
  border-bottom: 1px solid var(--border);
}
.me-cell:last-child { border-bottom: 0; }
.me-cell .ic {
  width: 30px; height: 30px; border-radius: 9px;
  background: var(--brand-soft); color: var(--brand);
  display: grid; place-items: center;
  flex: 0 0 30px;
}
.me-cell .t { flex: 1; font-size: 13.5px; }
.me-cell .v { font-size: 12px; color: var(--muted); }

/* ---------- 工作台 ---------- */
.work-hero {
  background: linear-gradient(150deg, #14549e 0%, #1d6fe0 55%, #2f8ef5 100%);
  color: #fff;
  padding: 6px 16px 54px;
  position: relative;
  overflow: hidden;
}
.work-hero::after {
  content: "";
  position: absolute; right: -60px; bottom: -70px;
  width: 190px; height: 190px; border-radius: 50%;
  background: rgba(56,189,248,.22);
}
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: -42px;
  padding: 0 12px;
  position: relative;
}
.stat {
  background: #fff;
  border-radius: 11px;
  padding: 11px 6px 10px;
  text-align: center;
  box-shadow: 0 4px 14px rgba(19,32,51,.07);
}
.stat .n { font-size: 19px; font-weight: 600; font-variant-numeric: tabular-nums; }
.stat .l { font-size: 10.5px; color: var(--muted); margin-top: 2px; }
.stat.accent .n { color: var(--brand); }
.stat-grid.is-empty .stat .n,
.stat-grid.is-empty .stat.accent .n { color: var(--muted); font-weight: 500; }
.idle-hint { margin: 9px 14px 0; font-size: 11.5px; color: var(--muted); text-align: center; }

.switch-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 14px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin: 12px 12px 0;
}
.switch {
  width: 44px; height: 25px;
  border-radius: 13px;
  background: #d8e3ef;
  position: relative;
  transition: background 0.2s;
  flex: 0 0 44px;
}
.switch::after {
  content: "";
  position: absolute;
  top: 2px; left: 2px;
  width: 21px; height: 21px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(19,32,51,.2);
  transition: transform 0.2s;
}
.switch.on { background: var(--brand); }
.switch.on::after { transform: translateX(19px); }

.task-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 13px;
  margin-bottom: 10px;
}
.task-hd { display: flex; align-items: center; gap: 6px; margin-bottom: 9px; }
.task-time { display: flex; align-items: center; gap: 5px; font-size: 12px; color: var(--sub); }
.task-main { font-size: 14px; font-weight: 600; }
.task-addr { display: flex; align-items: flex-start; gap: 5px; font-size: 11.5px; color: var(--muted); margin-top: 5px; }
.task-foot { display: flex; align-items: center; gap: 8px; margin-top: 11px; padding-top: 10px; border-top: 1px dashed var(--border); }

/* ---------- 空态 ---------- */
.empty { padding: 46px 0; text-align: center; color: var(--muted); }
.empty .eic {
  width: 64px; height: 64px;
  margin: 0 auto 12px;
  border-radius: 20px;
  background: var(--brand-soft);
  color: #9dc2ea;
  display: grid; place-items: center;
}
.empty p { font-size: 12.5px; }

/* ---------- 提示 ---------- */
.toast {
  position: absolute;
  left: 50%; bottom: 90px;
  transform: translate(-50%, 10px);
  background: rgba(19, 32, 51, 0.9);
  color: #fff;
  font-size: 12.5px;
  padding: 8px 15px;
  border-radius: 9px;
  opacity: 0;
  pointer-events: none;
  transition: all 0.2s;
  z-index: 40;
  max-width: 84%;
  text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- 首页沉浸式状态栏 ---------- */
.phone.overlay-status .statusbar {
  position: absolute;
  top: 0; left: 0; right: 0;
  color: #fff;
  background: transparent;
  z-index: 30;
}
.phone.overlay-status .screen { padding-top: 0; }
.overlay-status .home-hero,
.overlay-status .work-hero,
.overlay-status .me-hero { padding-top: 52px; }

/* ---------- 响应式 ---------- */
@media (max-width: 480px) {
  body { padding: 0; background: var(--bg); }
  .phone { width: 100%; height: 100vh; border: 0; border-radius: 0; box-shadow: none; }
}
