:root {
  --brand: #D9480F;
  --brand-dark: #B03A0C;
  --brand-light: #FFF0E6;
  --bg: #F6F5F2;
  --card: #FFFFFF;
  --text: #1F2329;
  --text-2: #6B7280;
  --line: #ECEAE6;
  --green: #0F8A4B;
  --green-bg: #E7F6EE;
  --red: #D6303A;
  --red-bg: #FCEBEC;
  --blue: #1D6FD1;
  --blue-bg: #E8F1FC;
  --amber: #B7791F;
  --amber-bg: #FDF3E0;
  --radius: 14px;
  --tabbar-h: 60px;
}
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; }
body {
  font-family: -apple-system, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  background: var(--bg); color: var(--text); font-size: 14px;
}
#app { max-width: 560px; margin: 0 auto; min-height: 100%; position: relative; }
/* Pad/平板（宽度≥768px）：整页等比放大 1.2 倍（老板2026-08-23要求）。
   全站字号都是写死的像素，逐个改不现实；用 zoom 整体缩放，字号/间距/按钮/底部栏/弹窗一起按比例变，
   手机(<768px)完全不受影响。效果：正文14px→约17px，内容区560→672px。 */
@media (min-width: 768px) { body { zoom: 1.2; } }
main#view { padding: 0 12px calc(var(--tabbar-h) + 20px); }

/* ---------- tabbar ---------- */
#tabbar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 560px; height: var(--tabbar-h);
  background: var(--card); border-top: 1px solid var(--line);
  display: flex; z-index: 50;
  padding-bottom: env(safe-area-inset-bottom);
}
#tabbar a {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2px; text-decoration: none; color: var(--text-2); font-size: 11px;
}
#tabbar a .ico { font-size: 19px; line-height: 1; }
#tabbar a.active { color: var(--brand); font-weight: 600; }

/* ---------- page header ---------- */
.page-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 2px 6px;
}
/* 标题永远不折行：右边按钮多、字又长的页面（库存管理有两个按钮），
   原来会把"库存管理"挤成"库存管/理"两行，非常难看。改为标题不换行、按钮那一侧按需自动换行 */
.page-head h1 { font-size: 17px; font-weight: 700; white-space: nowrap; }
.page-head .sub { font-size: 11.5px; color: var(--text-2); margin-top: 2px; }
.page-head .right { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.page-head .right .btn.sm { white-space: nowrap; }
/* 详情页头部：返回箭头+标题，取代弹窗的"×关闭"，配合真实hash跳转支持系统返回键/边缘侧滑 */
.page-head.detail-head { justify-content: flex-start; gap: 4px; }
.back-btn { font-size: 26px; line-height: 1; color: var(--text); cursor: pointer; padding: 4px 8px 4px 2px; margin: -4px 0 -4px -6px; }

/* ---------- cards ---------- */
.card {
  background: var(--card); border-radius: var(--radius);
  padding: 9px 11px; margin-bottom: 7px;
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
}
.card h3 { font-size: 14px; margin-bottom: 6px; display: flex; align-items: center; justify-content: space-between; }
.card h3 .link { font-size: 11.5px; color: var(--brand); font-weight: 400; cursor: pointer; }

/* ---------- KPI ---------- */
.kpi-hero {
  background: linear-gradient(135deg, var(--brand) 0%, #E8632C 100%);
  color: #fff; border-radius: 14px; padding: 10px; margin-bottom: 7px;
}
.kpi-hero .t { font-size: 12.5px; opacity: .9; }
.kpi-hero .grid { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 6px; gap: 5px; }
.kpi-hero .item .v { font-size: 17px; font-weight: 700; }
.kpi-hero .item .l { font-size: 10.5px; opacity: .85; margin-top: 1px; }

/* ---------- module grid ---------- */
.mod-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.mod-grid a {
  background: var(--card); border-radius: var(--radius); text-decoration: none;
  color: var(--text); display: flex; flex-direction: column; align-items: center;
  padding: 10px 2px 8px; gap: 4px; font-size: 11px;
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
}
.mod-grid a .ico { font-size: 20px; line-height: 1; }
.mod-grid .blank { visibility: hidden; }

/* ---------- list rows ---------- */
.row {
  display: flex; align-items: center; gap: 9px;
  padding: 6px 0; border-bottom: 1px solid var(--line);
}
.row:last-child { border-bottom: none; }
.row .main { flex: 1; min-width: 0; }
.row .name { font-size: 14px; font-weight: 500; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.row .meta { font-size: 11.5px; color: var(--text-2); margin-top: 2px; }
.row .side { text-align: right; flex-shrink: 0; }
.row .side .v { font-weight: 600; }
.row .side .l { font-size: 10.5px; color: var(--text-2); }
.row.clickable { cursor: pointer; }

/* ---------- 收发货列表条目（央厨出货 / 门店入库）----------
   3列 × 2行 网格：日期 | 门店 | 状态 ／ 正常下单 | 临时加单 | 合并。
   以前用 .row 的 flex 布局，标签是跟在名字后面自由换行的——门店名一长、标签一多就换行，
   每条高低不齐、标签位置也对不上，一列扫下来很乱。改成网格后每一格位置固定，可以竖着对齐比对。
   列宽用 auto|1fr|auto 而不是三等分：日期和右侧标签各占自己需要的宽度，剩下的全给门店名，
   这样日期不会被截成"2026-08-…"、门店名也有足够空间显示完整。 */
.ord-row {
  display: grid; grid-template-columns: auto 1fr auto; gap: 3px 10px;
  padding: 11px 0; border-bottom: 1px solid var(--line); cursor: pointer; align-items: center;
}
.ord-row:last-child { border-bottom: none; }
.ord-row > div { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ord-row .c-date { font-size: 13.5px; font-weight: 600; }
.ord-row .c-store { font-size: 13px; color: var(--text); text-align: center; }   /* 门店名标准黑、居中——与第二行居中的【临时加单】上下对位（老板8/26三轮定稿）；本列表全部黑字、不用灰 */
.ord-row .c-end { text-align: right; }

/* ---------- 清零线：历史列表里标出"理论库存在这里清零过"的分隔条 ---------- */
.reset-line {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  margin: 6px 0; padding: 5px 9px; border-radius: 7px;
  background: var(--amber-bg); color: var(--amber);
  font-size: 11.5px; font-weight: 600; line-height: 1.5;
}
.reset-line .who { font-weight: 400; opacity: .8; white-space: nowrap; font-size: 10.5px; }

/* ---------- tags ---------- */
.tag { display: inline-block; font-size: 10.5px; padding: 1px 5px; border-radius: 5px; font-weight: 500; }
.tag.brand { background: var(--brand-light); color: var(--brand); }
.tag.green { background: var(--green-bg); color: var(--green); }
.tag.red { background: var(--red-bg); color: var(--red); }
.tag.blue { background: var(--blue-bg); color: var(--blue); }
.tag.amber { background: var(--amber-bg); color: var(--amber); }
.tag.gray { background: #F0F0EF; color: var(--text-2); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  border: none; border-radius: 10px; font-size: 13.5px; font-weight: 600;
  padding: 8px 14px; cursor: pointer; background: var(--brand); color: #fff;
  font-family: inherit;
}
.btn.block { width: 100%; padding: 10px; font-size: 14px; }
.btn.ghost { background: var(--brand-light); color: var(--brand); }
.btn.plain { background: #F0F0EF; color: var(--text); }
.btn.sm { padding: 4px 10px; font-size: 12px; border-radius: 8px; }
.btn.danger { background: var(--red-bg); color: var(--red); }
.btn:disabled { opacity: .45; cursor: default; }

/* ---------- stepper ---------- */
.stepper { display: flex; align-items: center; gap: 0; }
.stepper button {
  width: 30px; height: 30px; border-radius: 9px; border: none;
  background: var(--brand-light); font-size: 17px; font-weight: 600;
  color: var(--brand); cursor: pointer; line-height: 1;
}
.stepper button:disabled { background: #F2F1EF; color: #CFCECB; }
.stepper .num {
  width: 38px; text-align: center; font-size: 15px; font-weight: 700;
  color: var(--brand); cursor: pointer;
}
.stepper .num.zero { color: #C6C6C4; font-weight: 400; }

/* ---------- mode buttons (预测/午市/全天) ---------- */
.mode-btn {
  border: 1.5px solid var(--brand); background: #fff; color: var(--brand);
  font-weight: 600; border-radius: 10px; padding: 6px 11px;
  font-size: 13px; font-family: inherit; cursor: pointer; white-space: nowrap;
}
.mode-btn.on { background: var(--brand); color: #fff; }

/* ---------- forecast rows ---------- */
.f-row { display: flex; align-items: center; gap: 9px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.f-row:last-child { border-bottom: none; }
.f-row .f-main { flex: 1; min-width: 0; }
.f-row .f-name {
  font-size: 14px; font-weight: 500;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.f-row .f-meta { font-size: 11px; color: #A8A7A3; margin-top: 2px; }
.f-row.filled { margin: 0 -8px; padding: 8px 8px; background: #FFF9F5; border-radius: 10px; border-bottom-color: transparent; }
/* 每日下单菜品列表：信息密度更高的紧凑样式，在上面的全局紧凑基础上再收紧一档 */
.dish-compact .section-title { margin: 7px 2px 3px; font-size: 11px; }
.dish-compact .card { padding: 2px 9px; }
.dish-compact .f-row { padding: 4px 0; gap: 7px; }
.dish-compact .f-row.filled { padding: 5px 5px; margin: 0 -5px; }
.dish-compact .f-name { font-size: 13px; }
.dish-compact .stepper button { width: 26px; height: 26px; font-size: 14px; }
.dish-compact .stepper .num { width: 30px; font-size: 13px; }
/* 理论库存参考列(店长下单参考，仅展示不可编辑) + 停售菜品整行置灰 */
.dish-compact .f-row .f-stock { width: 40px; flex-shrink: 0; text-align: center; font-size: 12px; color: var(--text-2); }
.dish-compact .f-row.off-sale { opacity: .45; }
/* 库存增加额单据详情：分类分组表格(菜品/订货/实销/尾货/库存增量) */
.gap-detail .gap-row { display: grid; grid-template-columns: 1fr 44px 44px 44px 58px; align-items: center; gap: 4px; padding: 7px 0; font-size: 13px; }
.gap-detail .gap-row .num { text-align: right; }
.gap-detail .gap-row.head { color: var(--text-2); font-size: 11px; padding-bottom: 4px; }
/* ---------- 菜品管理列表行：两行式 ----------
   第一行：菜名+售价 ............ 毛利 xx%
   第二行：生产单位  负责人 ............ 在售/停售 */
/* ---------- 菜品行：3列 × 2行 ----------
   第一行：菜名 | 售价 | 毛利      第二行：品类 | 生产单位 | 在售/停售
   后两列用**固定宽度**而不是 auto：每一行都是独立的 grid，用 auto 的话列宽各算各的，
   上下就对不齐了——菜品列表是拿来竖着扫价格和毛利的，对不齐等于白做。 */
.dish-row {
  /* 名字列尽量宽：后两列46/78px已够放"¥25"和"毛利-133.3%"，间距8px——
     原来66/98px+16px间距，在手机开大字体后菜名列只剩约5个字宽，6字菜名(鹌鹑蛋红烧肉)被硬折两行；
     按1.25倍大字体档校过：8字菜名(麻辣烫（火腿肠）/山药胡萝卜炒肉片)也要单行放得下 */
  display: grid; grid-template-columns: 1fr 46px 78px; row-gap: 2px; column-gap: 8px;
  align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); cursor: pointer;
}
.dish-row:last-child { border-bottom: none; }
.dish-row > div { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 菜名不省略、放不下就换行：右边三列宽度是固定的，用户把字号调到特大时名字列会被挤窄，
   这时候截成"砂锅粉丝娃…"比多占一行难受得多——菜名是这一行的主体，宁可行变高也要看全 */
/* 老板定的口径：整行信息字体一致、菜名不加大不加粗、整体再小一号（12.5px统一） */
.dish-row .d-name { font-size: 12.5px; font-weight: 400; white-space: normal; overflow: visible; }
/* 价格列居中：右对齐的话"¥22"会紧贴着右边"毛利64.1%"，两个数字挤在一起分不开。
   最后一列留宽一点，负毛利(毛利-133.3%)也要能完整显示，不能被截成"毛利-133…" */
.dish-row .d-price { font-size: 12.5px; font-weight: 400; text-align: center; }
.dish-row .d-margin { font-size: 12.5px; color: var(--text-2); text-align: right; }
.dish-row .d-margin b { font-weight: 400; }
.dish-row .d-cat, .dish-row .d-maker { font-size: 12.5px; color: var(--text-2); }
.dish-row .d-maker { text-align: center; }
.dish-row .d-status { font-size: 12.5px; white-space: nowrap; text-align: right; }
.dish-row .d-status.on { color: var(--green); }
.dish-row .d-status.off { color: var(--text-2); }
.dish-row.off-sale .d-name { color: var(--text-2); font-weight: 500; }
/* ---------- BOM配料行：两行式 ----------
   第一行：食材名 ...... 类别(居中) ...... 删
   第二行：单价   ...... 用量(居中) ...... 成本 */
.bom-row {
  display: grid; grid-template-columns: 1fr 1fr auto; row-gap: 3px; column-gap: 8px;
  align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line);
}
.bom-row:last-child { border-bottom: none; }
.bom-row .b-name { font-size: 14px; font-weight: 600; }
.bom-row .b-cat { font-size: 12px; color: var(--text-2); text-align: center; }
.bom-row .b-price { font-size: 12px; color: var(--text-2); }
.bom-row .b-qty { text-align: center; font-size: 13px; font-weight: 600; color: var(--brand); cursor: pointer; }
.bom-row .b-qty.ro { color: var(--text); cursor: default; }
.bom-row .b-cost { text-align: right; font-size: 12px; color: var(--text-2); white-space: nowrap; }
.bom-row .b-del { text-align: right; font-size: 12.5px; color: var(--red); cursor: pointer; }
/* ---------- 发货/收货明细表：订单量 | 实发 [| 收货 | 质量]，后几列可填写 ----------
   卡片左右内边距压到2px、表头行同样2px，让菜品名跟表头和分组标题左侧顶格对齐 */
.ship-tbl .ship-row { display: grid; grid-template-columns: 1fr 54px 62px; align-items: center; gap: 6px; padding: 7px 0; font-size: 13px; }
.ship-tbl.c3 .ship-row { grid-template-columns: 1fr 48px 56px 62px; }
.ship-tbl.c4 .ship-row { grid-template-columns: 1fr 40px 40px 54px 58px; gap: 4px; font-size: 12.5px; }
.ship-tbl .card { padding: 2px 2px; }
.ship-tbl .ship-row.head { color: var(--text-2); font-size: 11px; padding: 0 2px 4px; }
.ship-tbl .qsel {
  width: 100%; padding: 4px 2px; font-size: 12.5px; text-align: center;
  border: 1px solid var(--line); border-radius: 7px; background: #fff;
}
.ship-tbl .qsel.unset { border-color: var(--amber); background: var(--amber-bg); }  /* 还没选，提醒必填 */
.ship-tbl .qsel.bad { border-color: var(--red); background: #FFF3F0; color: var(--red); font-weight: 600; }
.ship-tbl .ship-row .num { text-align: center; }
.ship-tbl .ship-in {
  text-align: center; border: 1px solid var(--brand); border-radius: 7px; padding: 4px 0;
  color: var(--brand); font-weight: 600; cursor: pointer; background: #fff;
}
.ship-tbl .ship-in.diff { border-color: var(--red); color: var(--red); background: #FFF3F0; }
.ship-tbl .ship-in.ro { border-color: var(--line); color: var(--text); font-weight: 400; cursor: default; background: #FAF9F7; }
/* ---------- 巡检检查项行（新建表单+详情页共用）----------
   不复用 .f-name——它是 nowrap+ellipsis 的，巡检项标题普遍7-10个字，
   nowrap 会把右侧的合格/不合格按钮顶出屏幕（老板截图里"冰箱库存与效期管控"那行按钮被切掉一半） */
.insp-item { padding: 7px 0; border-bottom: 1px solid var(--line); }
.insp-item:last-child { border-bottom: none; }
/* 合格/不合格按老板手绘稿改成右侧两个"竖排窄条"（合/格、不/合/格 一字一行），
   与整行等高、并排相贴像表格单元格——横排按钮占掉近一半行宽，标题只能挤着换行 */
.insp-item .head { display: flex; align-items: center; gap: 10px; }
.insp-item .t { flex: 1; min-width: 0; font-size: 13.5px; font-weight: 600; line-height: 1.35; }
.insp-item .t .dot { color: var(--red); font-size: 9px; vertical-align: 2px; margin-right: 3px; }
.insp-item .std { font-size: 11px; color: #A8A7A3; line-height: 1.45; margin-top: 2px; font-weight: 400; }
/* 标签即说明：常驻在项目名下方，未选=灰色说明，点选=红色报问题（自动转不合格） */
.insp-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 5px; }
.insp-tags .btn { padding: 4px 10px; font-size: 12px; }
.insp-item .verdict { flex-shrink: 0; font-weight: 600; font-size: 12.5px; }
.insp-badbox { margin-top: 7px; background: #FFF7F5; border-radius: 8px; padding: 8px; }
.insp-badbox .btn { padding: 4px 9px; font-size: 12px; }
.insp-badbox input[type=text] { margin-top: 7px; width: 100%; font-size: 13px; padding: 7px 10px; }
/* ---------- progress bar ---------- */
.progress { height: 8px; background: #F0EFEC; border-radius: 999px; overflow: hidden; }
.progress i {
  display: block; height: 100%; border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), #E8632C);
  transition: width .3s;
}
.progress.good i { background: linear-gradient(90deg, #0F8A4B, #23A55A); }

.chip .cnt {
  display: inline-block; min-width: 16px; text-align: center; margin-left: 4px;
  background: var(--brand); color: #fff; border-radius: 999px;
  font-size: 10px; padding: 1px 4px; line-height: 1.4;
}
.chip.active .cnt { background: rgba(255,255,255,.32); }

/* ---------- chips / filters ---------- */
.chips { display: flex; gap: 6px; overflow-x: auto; padding: 2px 0 6px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex-shrink: 0; padding: 5px 11px; border-radius: 999px; font-size: 12.5px;
  background: var(--card); color: var(--text-2); cursor: pointer; border: 1px solid var(--line);
}
.chip.active { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 500; }

/* ---------- form ---------- */
input[type=date], input[type=time], input[type=text], input[type=number], select, textarea {
  font-family: inherit; font-size: 13.5px; color: var(--text);
  border: 1px solid var(--line); border-radius: 9px; padding: 7px 10px;
  background: #fff; outline: none; width: 100%;
}
/* 统一高度：date/time/select 各家浏览器默认内高不一致（巡检表单"到店时间"曾因漏掉time
   走了系统默认样式，跟旁边的日期框、下拉框大小不一）；textarea 不限高 */
input[type=date], input[type=time], input[type=text], input[type=number], select { height: 37px; box-sizing: border-box; }
input:focus, select:focus, textarea:focus { border-color: var(--brand); }
input[type=date] { width: auto; }
/* 表单字段里的日期/时间框占满字段宽度，跟同一行的下拉框对齐（筛选条里的日期框仍保持auto+flex） */
.field input[type=date], .field input[type=time] { width: 100%; }
.field { margin-bottom: 10px; }
.field label { display: block; font-size: 12px; color: var(--text-2); margin-bottom: 4px; }
.field-row { display: flex; gap: 8px; }
.field-row .field { flex: 1; }

/* ---------- search ---------- */
.searchbar { position: relative; margin-bottom: 8px; }
.searchbar input { padding-left: 32px; border-radius: 10px; }
.searchbar::before { content: "🔍"; position: absolute; left: 9px; top: 8px; font-size: 12.5px; opacity: .5; }

/* ---------- sticky footer bar ---------- */
.sticky-bar {
  position: fixed; bottom: var(--tabbar-h); left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 560px; background: var(--card);
  border-top: 1px solid var(--line); padding: 9px 12px;
  display: flex; align-items: center; gap: 10px; z-index: 40;
}
.sticky-bar .info { flex: 1; font-size: 12.5px; color: var(--text-2); }
.sticky-bar .info b { color: var(--text); font-size: 15px; }
.has-sticky { padding-bottom: calc(var(--tabbar-h) + 78px) !important; }

/* ---------- 弹窗改为全屏页面：不再是悬浮小卡片，覆盖整个视口，和普通页面一致的宽度观感 ---------- */
#modal-root:empty { display: none; }
.modal-mask {
  position: fixed; inset: 0; background: var(--bg); z-index: 100;
  display: flex; justify-content: center;
}
.modal {
  background: var(--card); width: 100%; max-width: 560px;
  height: 100%; display: flex; flex-direction: column;
  animation: slideup .18s ease;
}
@keyframes slideup { from { transform: translateY(24px); opacity: .6; } to { transform: none; opacity: 1; } }
.modal h2 {
  flex: 0 0 auto; font-size: 16px; padding: calc(12px + env(safe-area-inset-top)) 14px 12px;
  border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center;
}
.modal h2 .close { font-size: 22px; color: var(--text-2); cursor: pointer; line-height: 1; padding: 4px; margin: -4px; }
.modal-body { flex: 1 1 auto; overflow-y: auto; padding: 14px 14px calc(14px + env(safe-area-inset-bottom)); }
.modal .actions { display: flex; gap: 8px; margin-top: 14px; }
.modal .actions .btn { flex: 1; }
/* 录入弹窗内粘底的清除/确认按钮，长列表滚动时始终可见 */
/* ---------- 表单底部操作条：常驻悬浮在屏幕底部 ----------
   这套样式原来只写了 `.modal .sticky-actions`。后来（第三十三节）所有弹窗都改成了全屏页面，
   表单不在 .modal 里了，**这条样式从此一次都没生效过**——确认按钮变成普通块级元素，
   堆在几十道菜的长页面最底下，手机上得一路滑到底才看得见，店长直接以为"没有提交按钮"。
   现在改成 fixed 悬浮在底部导航栏之上，页面多长都在可视区内。 */
.sticky-actions {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom));
  width: 100%; max-width: 560px; box-sizing: border-box;
  padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
  background: var(--card); border-top: 1px solid var(--line);
  box-shadow: 0 -2px 8px rgba(0,0,0,.06); z-index: 40;
  display: flex; align-items: center; gap: 8px;
}
/* 详情页没有底部导航栏时（全屏表单同样挂在#view里，导航栏始终存在），保持在导航栏之上即可 */
.sticky-actions .info { flex: 1; min-width: 0; font-size: 12.5px; color: var(--text-2); }
.sticky-actions .info b { color: var(--text); font-size: 15px; }
.sticky-actions .btn { flex: 0 0 auto; }
.sticky-actions .btn:not(.plain) { padding: 8px 16px; }
.sticky-actions .btn:disabled { opacity: .45; cursor: not-allowed; }
/* 有悬浮操作条的页面，底部要多留出它的高度，否则最后几行会被压在条子下面点不到 */
main#view.has-sticky { padding-bottom: calc(var(--tabbar-h) + 78px); }

/* ---------- toast ---------- */
#toast {
  position: fixed; top: 40px; left: 50%; transform: translateX(-50%) translateY(-8px);
  background: rgba(31,35,41,.92); color: #fff; padding: 8px 16px; border-radius: 10px;
  font-size: 13px; z-index: 200; opacity: 0; pointer-events: none; transition: all .2s;
  max-width: 80vw; text-align: center;
}
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- misc ---------- */
.empty { text-align: center; color: var(--text-2); padding: 36px 0; font-size: 13px; }
.empty .big { font-size: 30px; margin-bottom: 6px; }
.section-title { font-size: 11.5px; color: var(--text-2); margin: 8px 2px 5px; font-weight: 500; }
.warn-strip {
  background: var(--red-bg); color: var(--red); border-radius: 10px;
  padding: 8px 11px; font-size: 12.5px; margin-bottom: 10px;
}
.flow-hint { font-size: 11.5px; color: var(--text-2); line-height: 1.8; }
.num-red { color: var(--red); font-weight: 600; }
.num-green { color: var(--green); font-weight: 600; }
.checkline { display: flex; align-items: center; gap: 9px; }
.checkline input[type=checkbox] { width: 19px; height: 19px; accent-color: var(--brand); flex-shrink: 0; }
.done .name, .done .meta { text-decoration: line-through; color: #B9B9B6 !important; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.stat-mini { background: var(--card); border-radius: var(--radius); padding: 8px; text-align: center; }
.stat-mini .v { font-size: 17px; font-weight: 700; }
.stat-mini .l { font-size: 11px; color: var(--text-2); margin-top: 2px; }
