/* 电商单量记录 · 移动端样式 */
:root {
  --brand: #4F46E5;
  --brand-2: #7C3AED;
  --brand-soft: #EEF0FF;
  --accent: #F59E0B;
  --text: #131829;
  --text-2: #4B5468;
  --muted: #858CA3;
  --line: #E9EBF3;
  --bg: #F4F5FA;
  --card: #FFFFFF;
  --card-2: #F8F9FD;
  --ok: #10B981;
  --danger: #EF4444;
  --radius: 18px;
  --shadow: 0 6px 22px rgba(23, 30, 64, .07);
  --shadow-sm: 0 2px 8px rgba(23, 30, 64, .05);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
}

@media (prefers-color-scheme: dark) {
  :root {
    --brand: #7A7BFF;
    --brand-2: #A78BFA;
    --brand-soft: #23234A;
    --accent: #FBBF24;
    --text: #EDEFF7;
    --text-2: #B6BCD0;
    --muted: #8A90A8;
    --line: #2A2F45;
    --bg: #10131F;
    --card: #191D2E;
    --card-2: #202538;
    --ok: #34D399;
    --danger: #F87171;
    --shadow: 0 6px 22px rgba(0, 0, 0, .35);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, .25);
  }
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; padding: 0; height: 100%; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: contain;
}
button, input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; }
input, select, textarea {
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 12px;
  padding: 10px 12px;
  width: 100%;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
}
.hidden, [hidden] { display: none !important; }
.num { font-variant-numeric: tabular-nums; letter-spacing: -.5px; }

/* ---------------- 登录 / 初始化 ---------------- */
.auth-wrap {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 28px 22px calc(28px + var(--safe-b));
  background:
    radial-gradient(1100px 520px at 50% -12%, rgba(124, 58, 237, .55), transparent 62%),
    linear-gradient(165deg, #4F46E5 0%, #5B21B6 52%, #1E1B4B 100%);
}
.auth-logo {
  width: 74px; height: 74px; border-radius: 22px; margin: 0 auto 16px;
  background: rgba(255, 255, 255, .16);
  border: 1px solid rgba(255, 255, 255, .3);
  display: flex; align-items: center; justify-content: center;
  font-size: 34px;
  backdrop-filter: blur(8px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .22);
}
.auth-title { color: #fff; text-align: center; font-size: 22px; font-weight: 700; margin: 0 0 4px; }
.auth-sub { color: rgba(255, 255, 255, .72); text-align: center; font-size: 13px; margin: 0 0 22px; }
.auth-card {
  background: var(--card);
  border-radius: 22px;
  padding: 20px 18px 18px;
  box-shadow: 0 18px 44px rgba(9, 9, 40, .3);
}
.field { margin-bottom: 12px; }
.field label { display: block; font-size: 12.5px; color: var(--muted); margin: 0 0 6px 2px; }
.btn {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  width: 100%; height: 48px; border-radius: 14px;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff; font-weight: 600; font-size: 16px;
  box-shadow: 0 8px 20px rgba(79, 70, 229, .3);
  transition: transform .12s, opacity .15s;
}
.btn:active { transform: scale(.98); }
.btn[disabled] { opacity: .55; box-shadow: none; }
.btn.ghost {
  background: var(--card-2); color: var(--text-2); box-shadow: none; border: 1px solid var(--line);
}
.btn.danger { background: var(--card); color: var(--danger); box-shadow: none; border: 1px solid var(--line); }
.btn.sm { height: 38px; width: auto; padding: 0 14px; font-size: 14px; border-radius: 11px; }
.auth-foot { text-align: center; color: rgba(255, 255, 255, .6); font-size: 12px; margin-top: 16px; }
.auth-err {
  background: rgba(239, 68, 68, .1); color: var(--danger);
  border-radius: 11px; padding: 9px 12px; font-size: 13px; margin-bottom: 12px;
}

/* ---------------- 主框架 ---------------- */
.shell { min-height: 100vh; min-height: 100dvh; padding-bottom: calc(84px + var(--safe-b)); }
.topbar {
  position: sticky; top: 0; z-index: 30;
  padding: calc(10px + var(--safe-t)) 16px 10px;
  background: var(--bg);
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}
.topbar.stuck { border-bottom-color: var(--line); }
.topbar-in { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.topbar h1 {
  margin: 0; font-size: 17px; font-weight: 700;
  display: flex; align-items: center; gap: 7px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.topbar h1 .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--ok); flex: none;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, .18);
}
.avatar {
  width: 34px; height: 34px; border-radius: 50%; flex: none;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 14px;
}
.topbar-btn {
  flex: none; width: 34px; height: 34px; border-radius: 50%;
  background: var(--card); color: var(--brand); font-size: 17px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-sm);
  transition: transform .3s;
}
.topbar-btn:active { background: var(--brand-soft); }
.topbar-btn.spin { animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.content { padding: 4px 16px 8px; }

/* ---------------- 底部导航 ---------------- */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: flex;
  padding: 6px 6px calc(6px + var(--safe-b));
  background: var(--card);
  background: color-mix(in srgb, var(--card) 90%, transparent);
  -webkit-backdrop-filter: blur(18px) saturate(1.6);
  backdrop-filter: blur(18px) saturate(1.6);
  border-top: 1px solid var(--line);
}
.tabbar button {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 5px 0 3px; color: var(--muted); font-size: 10.5px; font-weight: 500;
  border-radius: 12px; transition: color .15s;
}
.tabbar button svg { width: 23px; height: 23px; stroke-width: 1.9; }
.tabbar button.active { color: var(--brand); }
.tabbar button.active svg { stroke-width: 2.3; }

/* ---------------- 通用卡片 ---------------- */
.card {
  background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); padding: 14px;
  margin-bottom: 12px;
}
.sec-title {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 13px; color: var(--muted); margin: 16px 2px 8px; font-weight: 600;
}
.sec-title .link { color: var(--brand); font-weight: 600; font-size: 13px; }

/* ---------------- 今日录入 ---------------- */
.datebar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 8px; margin: 6px 0 12px;
}
.datebar .nav {
  width: 38px; height: 38px; border-radius: 12px; flex: none;
  background: var(--card); box-shadow: var(--shadow-sm);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-2); font-size: 17px;
}
.datebar .nav[disabled] { opacity: .35; }
.datebar .center {
  flex: 1; text-align: center; background: var(--card);
  border-radius: 13px; padding: 7px 10px; box-shadow: var(--shadow-sm);
  position: relative; overflow: hidden;
}
.datebar .center input[type="date"] {
  position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%;
  border: 0; padding: 0;
}
.datebar .d1 { font-size: 16px; font-weight: 700; }
.datebar .d2 { font-size: 11px; color: var(--muted); margin-top: 1px; }

.hero {
  border-radius: 20px; padding: 16px 18px;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff; margin-bottom: 14px;
  box-shadow: 0 12px 26px rgba(79, 70, 229, .28);
  position: relative; overflow: hidden;
}
.hero::after {
  content: ""; position: absolute; width: 190px; height: 190px; border-radius: 50%;
  right: -70px; top: -95px; background: rgba(255, 255, 255, .12);
}
.hero .lab { font-size: 12.5px; opacity: .82; letter-spacing: .4px; }
.hero .big { font-size: clamp(34px, 11.5vw, 46px); font-weight: 800; line-height: 1.06; margin: 2px 0 4px; }
.hero .meta { font-size: 12.5px; opacity: .88; display: flex; gap: 14px; flex-wrap: wrap; }
.hero .meta b { font-weight: 700; }

.shop {
  background: var(--card); border-radius: 16px; padding: 12px;
  margin-bottom: 10px; box-shadow: var(--shadow-sm);
  border: 1px solid transparent;
  transition: border-color .2s;
}
.shop.dirty { border-color: rgba(245, 158, 11, .6); }
.shop.locked { opacity: .72; }
.shop-top { display: flex; align-items: center; gap: 8px; margin-bottom: 9px; }
.shop-name {
  font-weight: 650; font-size: 15.5px; flex: 1; min-width: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.chip {
  font-size: 10.5px; padding: 2px 7px; border-radius: 7px;
  background: var(--brand-soft); color: var(--brand); font-weight: 600; flex: none;
}
.chip.gray { background: var(--card-2); color: var(--muted); }
.shop-row { display: flex; align-items: center; gap: 8px; }
.shop-input {
  flex: 1; display: flex; align-items: center; gap: 6px;
  background: var(--card-2); border-radius: 13px; padding: 3px 4px 3px 12px;
  border: 1px solid transparent;
}
.shop-input:focus-within { border-color: var(--brand); background: var(--card); }
.shop-input input {
  border: 0; background: none; padding: 7px 0; font-size: 21px; font-weight: 700;
  letter-spacing: .5px; box-shadow: none !important;
}
.shop-input input::placeholder { color: var(--muted); font-weight: 400; font-size: 15px; letter-spacing: 0; }
.shop-input .unit { color: var(--muted); font-size: 12px; padding-right: 4px; }

/* 两场并排输入 + 昨天参照 */
.slot2 { display: flex; gap: 8px; }
.slot-cell { flex: 1; min-width: 0; }
.sc-label { font-size: 11px; color: var(--muted); margin: 0 0 4px 3px; }
.sc-input {
  display: flex; align-items: center; gap: 4px;
  background: var(--card-2); border-radius: 12px; padding: 2px 10px 2px 12px;
  border: 1px solid transparent; transition: border-color .15s, background .15s;
}
.sc-input:focus-within { border-color: var(--brand); background: var(--card); }
.sc-input input {
  flex: 1; min-width: 0; border: 0; background: none; box-shadow: none !important;
  padding: 9px 0; font-size: 20px; font-weight: 700; letter-spacing: .3px;
  font-variant-numeric: tabular-nums;
}
.sc-input input::placeholder { color: var(--muted); font-weight: 400; font-size: 15px; }
.sc-input .sc-unit { flex: none; color: var(--muted); font-size: 11px; }
.sc-prev {
  font-size: 10.5px; color: var(--muted); margin: 4px 0 0 3px;
}
.sc-prev b { color: var(--text-2); font-weight: 600; }

/* 链接数量 + 状态圆点 */
.link-row { display: flex; align-items: center; gap: 8px; margin-top: 9px; }
.lr-label { flex: none; width: 42px; font-size: 11px; color: var(--muted); }
.lr-input {
  flex: 1; display: flex; align-items: center; gap: 4px;
  background: var(--card-2); border-radius: 10px; padding: 1px 9px 1px 11px;
  border: 1px solid transparent; transition: border-color .15s, background .15s;
}
.lr-input:focus-within { border-color: var(--brand); background: var(--card); }
.lr-input input {
  flex: 1; min-width: 0; border: 0; background: none; box-shadow: none !important;
  padding: 7px 0; font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums;
}
.lr-input input::placeholder { color: var(--muted); font-weight: 400; font-size: 12px; }
.lr-input .lr-unit { flex: none; font-size: 10.5px; color: var(--muted); }
.dot { flex: none; width: 9px; height: 9px; border-radius: 50%; transition: background .2s; }
.dot.miss { background: #EF4444; box-shadow: 0 0 0 3px rgba(239, 68, 68, .16); }
.dot.ok { background: #10B981; box-shadow: 0 0 0 3px rgba(16, 185, 129, .16); }

.prog-row {
  display: flex; gap: 8px; margin-bottom: 10px;
}
.prog-row .pg {
  flex: 1; display: flex; align-items: baseline; gap: 6px;
  background: var(--card); border-radius: 11px; padding: 8px 12px;
  box-shadow: var(--shadow-sm); font-size: 12px;
}
.prog-row .pg i { font-style: normal; color: var(--muted); }
.prog-row .pg b { margin-left: auto; font-size: 13.5px; font-weight: 700; color: var(--text-2); }
.prog-row .pg.done b { color: var(--ok); }
.prog-row .pg em { font-style: normal; color: var(--ok); font-size: 11px; }
.shop-foot {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 7px; gap: 8px;
}
.shop-foot .upd { font-size: 11px; color: var(--muted); }
.note-btn {
  font-size: 11.5px; color: var(--muted); display: flex; align-items: center; gap: 3px;
  padding: 3px 8px; border-radius: 8px; background: var(--card-2);
}
.note-btn.has { color: var(--accent); }
.note { margin-top: 8px; }
.note input { font-size: 13px; padding: 8px 10px; }

.savebar {
  position: fixed; left: 0; right: 0; z-index: 35;
  bottom: calc(68px + var(--safe-b));
  padding: 8px 16px;
  display: flex; align-items: center; gap: 10px;
  transform: translateY(140%); transition: transform .22s ease;
  pointer-events: none;
}
.savebar.show { transform: translateY(0); pointer-events: auto; }
.savebar .inner {
  flex: 1; display: flex; align-items: center; gap: 10px;
  background: rgba(24, 28, 48, .94); color: #fff;
  border-radius: 15px; padding: 8px 8px 8px 15px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .28);
}
@media (prefers-color-scheme: dark) { .savebar .inner { background: rgba(48, 54, 84, .97); } }
.savebar .txt { flex: 1; font-size: 13px; }
.savebar .txt b { color: var(--accent); }
.savebar .go {
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff; border-radius: 11px; padding: 9px 18px; font-weight: 700; font-size: 14px;
}
.savebar .go[disabled] { opacity: .6; }

/* ---------------- 统计 ---------------- */
.seg {
  display: flex; gap: 4px; background: var(--card-2);
  padding: 4px; border-radius: 13px; margin-bottom: 13px;
}
.seg button {
  flex: 1; padding: 8px 4px; border-radius: 10px;
  font-size: 13px; font-weight: 600; color: var(--muted);
  transition: background .15s, color .15s;
}
.seg button.on { background: var(--card); color: var(--brand); box-shadow: var(--shadow-sm); }
.stat-hero {
  display: flex; gap: 10px; margin-bottom: 12px;
}
.stat-box {
  flex: 1; background: var(--card); border-radius: 16px; padding: 13px 14px;
  box-shadow: var(--shadow-sm);
}
.stat-box .k { font-size: 11.5px; color: var(--muted); margin-bottom: 3px; }
.stat-box .v { font-size: 26px; font-weight: 800; line-height: 1.1; }
.stat-box .v small { font-size: 12px; font-weight: 500; color: var(--muted); margin-left: 3px; }
.stat-box.hl { background: linear-gradient(135deg, var(--brand), var(--brand-2)); box-shadow: 0 10px 24px rgba(79,70,229,.24); }
.stat-box.hl .k { color: rgba(255,255,255,.8); }
.stat-box.hl .v { color: #fff; }
.stat-box.hl .v small { color: rgba(255,255,255,.75); }

.chart { display: flex; align-items: flex-end; gap: 3px; height: 132px; padding: 6px 0 0; }
.chart .col { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 3px; height: 100%; min-width: 0; }
.chart .bar {
  width: 100%; max-width: 26px; border-radius: 6px 6px 3px 3px;
  background: linear-gradient(180deg, var(--brand), var(--brand-2));
  min-height: 2px; transition: height .3s;
}
.chart .bar.zero { background: var(--line); }
.chart .col.today .bar { background: linear-gradient(180deg, var(--accent), #EF7C08); }
.chart-x { display: flex; justify-content: space-between; font-size: 10.5px; color: var(--muted); margin-top: 5px; }

.rank { display: flex; flex-direction: column; gap: 11px; }
.rank-row .t { display: flex; justify-content: space-between; gap: 8px; font-size: 13.5px; margin-bottom: 5px; }
.rank-row .t .n { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-row .t .v { font-weight: 700; font-variant-numeric: tabular-nums; }
.rank-track { height: 7px; border-radius: 5px; background: var(--card-2); overflow: hidden; }
.rank-fill { height: 100%; border-radius: 5px; background: linear-gradient(90deg, var(--brand), var(--brand-2)); }
.rank-fill.a2 { background: linear-gradient(90deg, #06B6D4, #3B82F6); }
.rank-fill.a3 { background: linear-gradient(90deg, var(--accent), #EF7C08); }

.empty {
  text-align: center; color: var(--muted); font-size: 13px; padding: 26px 10px;
}
.empty .ico { font-size: 30px; display: block; margin-bottom: 8px; opacity: .6; }

/* ---------------- 明细 ---------------- */
.filter-row { display: flex; gap: 8px; margin-bottom: 12px; }
.filter-row input[type="date"] { flex: 1; font-size: 13.5px; padding: 9px 10px; }
.filter-row select { flex: 1; font-size: 13.5px; padding: 9px 10px; }

.day-group { margin-bottom: 14px; }
.day-head {
  display: flex; align-items: baseline; justify-content: space-between;
  padding: 0 3px 7px;
}
.day-head .l { font-size: 14px; font-weight: 700; }
.day-head .l span { font-size: 11.5px; color: var(--muted); font-weight: 500; margin-left: 6px; }
.day-head .r { font-size: 14px; font-weight: 800; color: var(--brand); }
.rec {
  display: flex; align-items: center; gap: 10px;
  background: var(--card); border-radius: 13px; padding: 10px 12px;
  margin-bottom: 7px; box-shadow: var(--shadow-sm);
}
.rec .info { flex: 1; min-width: 0; }
.rec .n { font-size: 14.5px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.rec .m { font-size: 11.5px; color: var(--muted); margin-top: 1px; }
.rec .qty { font-size: 19px; font-weight: 800; font-variant-numeric: tabular-nums; }

/* ---------------- 我的 ---------------- */
.me-card { display: flex; align-items: center; gap: 12px; }
.me-card .avatar { width: 52px; height: 52px; font-size: 20px; }
.me-card .nm { font-size: 17px; font-weight: 700; }
.me-card .rl { font-size: 12px; color: var(--muted); margin-top: 2px; }
.list { background: var(--card); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }
.list-item {
  display: flex; align-items: center; gap: 11px; padding: 13px 14px;
  border-bottom: 1px solid var(--line); width: 100%; text-align: left;
}
.list-item:last-child { border-bottom: 0; }
.list-item:active { background: var(--card-2); }
.list-item .ico { width: 26px; text-align: center; font-size: 16px; }
.list-item .tx { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.list-item .tx .a { font-size: 14.5px; }
.list-item .tx .b { font-size: 11.5px; color: var(--muted); margin-top: 0; }
.list-item .arrow { color: var(--muted); font-size: 14px; }
.list-item.danger .tx .a { color: var(--danger); }

.member { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.member:last-child { border-bottom: 0; }
.member .avatar { width: 36px; height: 36px; font-size: 14px; }
.member .info { flex: 1; min-width: 0; }
.member .nm { font-size: 14.5px; font-weight: 600; }
.member .un { font-size: 11.5px; color: var(--muted); }
.member .ops { display: flex; gap: 6px; }
.mini {
  font-size: 11.5px; padding: 5px 9px; border-radius: 9px;
  background: var(--card-2); color: var(--text-2); border: 1px solid var(--line);
}
.mini.danger { color: var(--danger); }

/* ---------------- 底部弹层 ---------------- */
.sheet-mask {
  position: fixed; inset: 0; z-index: 60;
  background: rgba(10, 12, 24, .45);
  display: flex; align-items: flex-end;
  backdrop-filter: blur(2px);
  animation: fade .18s;
}
@keyframes fade { from { opacity: 0; } }
.sheet {
  width: 100%; background: var(--card);
  border-radius: 22px 22px 0 0;
  padding: 6px 18px calc(20px + var(--safe-b));
  max-height: 88vh; overflow-y: auto;
  animation: up .24s cubic-bezier(.2, .9, .3, 1);
}
@keyframes up { from { transform: translateY(100%); } }
.sheet-head {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 16px; font-weight: 700; padding: 10px 0 14px;
  position: sticky; top: 0; background: var(--card); z-index: 2;
}
.sheet-close {
  width: 30px; height: 30px; border-radius: 50%; background: var(--card-2);
  color: var(--muted); font-size: 13px; display: flex; align-items: center; justify-content: center;
}
.sheet-body .btn { margin-top: 6px; }
.sheet-body .row2 { display: flex; gap: 8px; }
.sheet-body .row2 > * { flex: 1; }

/* ---------------- Toast ---------------- */
.toast {
  position: fixed; left: 50%; bottom: calc(96px + var(--safe-b));
  transform: translate(-50%, 20px);
  background: rgba(24, 28, 48, .95); color: #fff;
  padding: 10px 18px; border-radius: 13px; font-size: 13.5px;
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
  z-index: 80; max-width: 82vw; text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.err { background: rgba(190, 40, 40, .96); }
.toast.ok { background: rgba(13, 130, 92, .96); }

/* ---------------- 场次 / 员工组 / 流水（v2） ---------------- */

.seg.slotseg { gap: 6px; padding: 5px; }
.seg.slotseg button {
  display: flex; flex-direction: column; align-items: center; gap: 1px;
  padding: 7px 4px; line-height: 1.25;
}
.slotseg .sl-name { font-size: 13.5px; font-weight: 700; }
.slotseg .sl-time { font-size: 10.5px; opacity: .65; font-weight: 500; }
.slotseg .sl-prog { font-size: 10.5px; color: var(--muted); font-weight: 600; }
.slotseg .sl-prog.done { color: var(--ok); }
.slotseg button.on .sl-prog { color: var(--brand); }
.slotseg button.on .sl-prog.done { color: var(--ok); }

.today-tag {
  font-size: 10.5px; color: var(--brand); background: var(--brand-soft);
  padding: 1px 6px; border-radius: 6px; font-weight: 600; vertical-align: 2px;
}

.hint-bar {
  background: rgba(245, 158, 11, .13); color: #8a5300;
  border-radius: 12px; padding: 8px 13px; font-size: 12.5px; margin-bottom: 10px;
}
.hint-bar b { font-weight: 800; }
.hint-bar.ok { background: rgba(16, 185, 129, .13); color: #067a55; }

.hero .meta .late-txt {
  background: rgba(255, 255, 255, .18); padding: 1px 8px; border-radius: 8px; font-weight: 600;
}

.filter-line { display: flex; justify-content: flex-end; margin: -2px 0 10px; }
.filter-line .mini.on { background: var(--brand); color: #fff; border-color: var(--brand); }

.late-tag {
  display: inline-block; font-size: 10px; padding: 1px 5px; border-radius: 5px;
  background: rgba(239, 68, 68, .14); color: var(--danger); font-weight: 600;
  vertical-align: 1px;
}
.ok-tag { font-size: 10px; color: var(--ok); font-weight: 600; }
.wait-tag { font-size: 11px; color: var(--muted); }

.other-slot {
  display: flex; align-items: center; gap: 7px; margin-top: 9px; padding-top: 8px;
  border-top: 1px dashed var(--line); font-size: 11.5px; color: var(--muted);
}
.other-slot .os-label { flex: none; }
.other-slot .os-val { font-weight: 700; color: var(--text-2); font-size: 13px; }
.other-slot .os-by { margin-left: auto; font-size: 11px; }

.slot-tag {
  display: inline-block; font-size: 10px; padding: 1px 6px; border-radius: 6px;
  font-weight: 600; vertical-align: 1px;
}
.slot-tag.noon { background: rgba(79, 70, 229, .12); color: var(--brand); }
.slot-tag.night { background: rgba(245, 158, 11, .18); color: #a8590a; }

.log-row {
  background: var(--card); border-radius: 13px; padding: 10px 12px;
  margin-bottom: 7px; box-shadow: var(--shadow-sm);
  border-left: 3px solid transparent;
}
.log-row.late { border-left-color: var(--danger); }
.log-top { display: flex; align-items: center; gap: 6px; font-size: 12px; margin-bottom: 4px; }
.log-top .lg-who { font-weight: 700; font-size: 13px; }
.log-top .lg-time { color: var(--muted); margin-left: auto; font-size: 11px; }
.log-body { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.log-body .lg-shop { font-size: 13.5px; color: var(--text-2); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.log-body .lg-act { font-size: 12.5px; color: var(--muted); flex: none; }
.log-body .lg-act b { color: var(--text); font-weight: 700; }

.chk-list {
  display: flex; flex-direction: column; gap: 2px;
  background: var(--card-2); border-radius: 12px; padding: 8px 11px;
  max-height: 210px; overflow-y: auto; border: 1px solid var(--line);
}
.chk { display: flex; align-items: center; gap: 9px; font-size: 14px; padding: 6px 0; }
.chk input {
  width: 19px; height: 19px; min-width: 19px; padding: 0; margin: 0;
  accent-color: var(--brand); border-radius: 5px; box-shadow: none !important;
}
.chk span { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.chk i { font-style: normal; font-size: 11px; color: var(--muted); }

.slot-card { padding: 13px 14px; }
.slot-spec { display: flex; gap: 9px; font-size: 12.5px; color: var(--text-2); padding: 4px 0; }
.slot-spec b { flex: none; width: 48px; color: var(--text); font-weight: 700; }
.slot-spec span { flex: 1; }
.slot-spec.small {
  display: block; color: var(--muted); font-size: 11.5px;
  border-top: 1px dashed var(--line); padding-top: 9px; margin-top: 6px;
}

.legend { display: flex; gap: 14px; font-size: 11px; color: var(--muted); margin-top: 7px; }
.legend i {
  display: inline-block; width: 9px; height: 9px; border-radius: 3px;
  margin-right: 4px; vertical-align: middle;
}
.legend .lg-blue { background: linear-gradient(180deg, var(--brand), var(--brand-2)); }
.legend .lg-amber { background: rgba(245, 158, 11, .9); }

/* 我的小组 / 今日各小组 */
.mine-card {
  display: flex; align-items: center; gap: 12px;
  background: var(--card); border-radius: 16px; padding: 12px 16px;
  margin-bottom: 12px; box-shadow: var(--shadow-sm);
  border-left: 3px solid var(--brand);
}
.mine-card .mc-left { flex: 1; min-width: 0; }
.mine-card .mc-left .k { font-size: 11.5px; color: var(--muted); }
.mine-card .mc-left .v { font-size: 30px; font-weight: 800; line-height: 1.15; color: var(--brand); }
.mine-card .mc-right { flex: none; display: flex; flex-direction: column; gap: 3px; }
.mine-card .mc-line {
  display: flex; gap: 10px; justify-content: space-between;
  font-size: 11.5px; color: var(--muted); min-width: 100px;
}
.mine-card .mc-line b { color: var(--text-2); font-weight: 700; }

.power-card { padding: 4px 14px; }
.pw-row {
  display: flex; align-items: center; gap: 8px; padding: 11px 0;
  border-bottom: 1px solid var(--line); cursor: pointer;
  transition: background .15s;
}
.pw-row:last-child { border-bottom: 0; }
.pw-row:active { background: var(--card-2); }
.pw-name { font-size: 14px; font-weight: 650; flex: none; min-width: 56px; }
.pw-sub { flex: 1; font-size: 11.5px; color: var(--muted); }
.pw-val { font-size: 16px; font-weight: 800; color: var(--brand); }
.pw-arrow { flex: none; color: var(--muted); font-size: 14px; margin-left: 2px; }
.pw-del {
  flex: none; width: 24px; height: 24px; border-radius: 50%;
  color: var(--danger); background: rgba(239, 68, 68, .1);
  font-size: 11px; line-height: 1;
  display: flex; align-items: center; justify-content: center;
  margin-left: 2px;
}
.pw-del:active { background: rgba(239, 68, 68, .22); }

.shop-del {
  flex: none; width: 24px; height: 24px; border-radius: 50%;
  color: var(--danger); background: rgba(239, 68, 68, .1);
  font-size: 11px; line-height: 1;
  display: flex; align-items: center; justify-content: center;
  margin-left: 4px;
}
.shop-del:active { background: rgba(239, 68, 68, .22); }

/* ---------------- 搜索 ---------------- */
.search-wrap { margin-top: 10px; }
.search-box {
  display: flex; align-items: center; gap: 8px;
  background: var(--card); border-radius: 12px; padding: 0 12px;
  box-shadow: var(--shadow-sm); border: 1px solid var(--line);
}
.search-box:focus-within { border-color: var(--brand); }
.search-box .sb-ico { font-size: 14px; opacity: .55; flex: none; }
.search-box input {
  flex: 1; border: 0; background: none; box-shadow: none !important;
  padding: 10px 0; font-size: 14px; min-width: 0;
}
.search-box .sb-clear {
  flex: none; width: 22px; height: 22px; border-radius: 50%;
  background: var(--card-2); color: var(--muted); font-size: 11px; line-height: 1;
  display: flex; align-items: center; justify-content: center;
}

.search-sum { font-size: 12.5px; color: var(--muted); margin: 2px 2px 10px; }
.search-sum b { color: var(--text-2); font-weight: 700; }

.sr-card {
  background: var(--card); border-radius: 16px; padding: 13px 14px;
  margin-bottom: 11px; box-shadow: var(--shadow-sm); cursor: pointer;
}
.sr-card:active { background: var(--card-2); }
.sr-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.sr-name {
  font-size: 16px; font-weight: 700; flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.sr-owner {
  flex: none; font-size: 11.5px; padding: 2px 8px; border-radius: 8px;
  background: var(--brand-soft); color: var(--brand); font-weight: 600;
}
.sr-owner.pub { background: var(--card-2); color: var(--muted); }
.sr-stat { font-size: 12.5px; color: var(--muted); margin-bottom: 9px; }
.sr-stat b { color: var(--brand); font-size: 17px; font-weight: 800; }
.sr-days { border-top: 1px dashed var(--line); padding-top: 4px; }
.sr-day {
  display: flex; align-items: center; gap: 8px;
  padding: 5px 0; font-size: 12.5px; border-bottom: 1px solid var(--line);
}
.sr-day:last-child { border-bottom: 0; }
.sr-day.today .sd-date { color: var(--brand); font-weight: 700; }
.sd-date { flex: none; width: 78px; color: var(--muted); }
.sd-slot { flex: 1; color: var(--text-2); font-size: 12px; }
.sd-total { flex: none; font-weight: 800; font-size: 14px; min-width: 50px; text-align: right; }

/* 只看某个小组 */
.filter-chip {
  display: flex; align-items: center; gap: 8px;
  background: var(--brand-soft); color: var(--brand);
  border-radius: 11px; padding: 8px 12px; font-size: 12.5px; margin-bottom: 10px;
}
.filter-chip b { font-weight: 700; }
.filter-chip button {
  margin-left: auto; color: var(--brand); font-weight: 700;
  font-size: 12px; padding: 2px 4px;
}

/* 员工小组详情页 */
.backbar { display: flex; align-items: center; gap: 10px; margin: 4px 0 12px; }
.back-btn {
  flex: none; font-size: 13.5px; font-weight: 600; color: var(--brand);
  background: var(--card); border-radius: 11px; padding: 8px 13px;
  box-shadow: var(--shadow-sm);
}
.bb-date-wrap {
  flex: 1; position: relative; text-align: center;
  background: var(--card); border-radius: 11px; padding: 8px 10px;
  box-shadow: var(--shadow-sm); overflow: hidden;
}
.bb-date-wrap span { font-size: 13.5px; font-weight: 600; }
.bb-date-wrap input[type="date"] {
  position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%; border: 0; padding: 0;
}

.owner-hero {
  border-radius: 18px; padding: 14px 18px; margin-bottom: 12px;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff; box-shadow: 0 10px 24px rgba(79, 70, 229, .26);
}
.oh-name { font-size: 13px; opacity: .85; }
.oh-total { font-size: 40px; font-weight: 800; line-height: 1.1; margin: 2px 0 2px; }
.oh-sub { font-size: 12px; opacity: .92; }
.oh-sub b { font-weight: 700; }

.mc-arrow { flex: none; color: var(--brand); font-size: 16px; margin-left: 4px; }
.mine-card { cursor: pointer; }
.mine-card:active { background: var(--brand-soft); }

/* 旧版弹层样式（保留兼容） */
.gd-name { font-size: 14px; color: var(--muted); margin-bottom: 2px; }
.gd-total { font-size: 44px; font-weight: 800; color: var(--brand); line-height: 1.08; }
.gd-sub { font-size: 12px; color: var(--muted); margin-top: 5px; line-height: 1.6; }
.gd-list { display: flex; flex-direction: column; gap: 10px; }
.gd-shop { background: var(--card-2); border-radius: 14px; padding: 11px 13px; }
.gd-shop-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
.gd-shop-name { font-size: 14.5px; font-weight: 650; }
.gd-shop-total { font-size: 17px; font-weight: 800; color: var(--brand); }
.gd-slot {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 0; font-size: 12.5px; border-top: 1px dashed var(--line);
}
.gd-slot:first-of-type { border-top: 0; }
.gd-slot-label { flex: none; width: 46px; color: var(--muted); }
.gd-slot b { font-size: 15px; font-weight: 700; min-width: 54px; }
.gd-slot-meta { flex: 1; text-align: right; font-size: 11px; color: var(--muted); }
.gd-slot.empty b { color: var(--muted); font-weight: 500; }
.gd-lock { font-size: 11px; color: var(--muted); margin-top: 6px; }

.newshop-row { display: flex; gap: 6px; margin-top: 8px; align-items: stretch; }
.newshop-row input { flex: 1; font-size: 13px; padding: 9px 10px; min-width: 0; }
.newshop-row .mini { flex: none; font-size: 12px; padding: 0 12px; white-space: nowrap; }

@media (prefers-color-scheme: dark) {
  .hint-bar { background: rgba(251, 191, 36, .14); color: #fbbf24; }
  .hint-bar.ok { background: rgba(52, 211, 153, .14); color: #34d399; }
  .slot-tag.night { background: rgba(251, 191, 36, .18); color: #fbbf24; }
}
