* { box-sizing: border-box; margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  padding-bottom: env(safe-area-inset-bottom);
}

button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; }
a { color: var(--blue); text-decoration: none; }
svg { display: block; }
[hidden] { display: none !important; }

/* ---------- 布局 ---------- */

.shell { min-height: 100vh; display: flex; flex-direction: column; }

.topbar {
  position: sticky; top: 0; z-index: 40;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}

.topbar-inner {
  max-width: 1120px; margin: 0 auto;
  padding: 10px 20px;
  display: flex; align-items: center; gap: 14px;
}

.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }

.brand-mark {
  width: 34px; height: 34px; border-radius: 10px; flex: 0 0 auto;
  background: var(--blue); color: #fff;
  display: grid; place-items: center;
  font-size: 15px; font-weight: 600; letter-spacing: 0.5px;
}

.brand-text { min-width: 0; }
.brand-title { font-size: 15px; font-weight: 500; white-space: nowrap; }
.brand-sub { font-size: 12px; color: var(--muted); white-space: nowrap; }

.top-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }

.nav {
  max-width: 1120px; margin: 0 auto; padding: 0 20px 8px;
  display: flex; gap: 4px; overflow-x: auto;
  scrollbar-width: none;
}
.nav::-webkit-scrollbar { display: none; }

.nav-item {
  flex: 0 0 auto;
  padding: 7px 14px; border-radius: 999px;
  font-size: 14px; color: var(--muted);
  display: flex; align-items: center; gap: 6px;
  position: relative;
}
.nav-item:hover { background: var(--blue-soft); color: var(--blue); }
.nav-item.active { background: var(--blue); color: #fff; }
.nav-item.active:hover { background: var(--blue); color: #fff; }

.nav-badge {
  min-width: 17px; height: 17px; padding: 0 5px;
  border-radius: 9px; background: var(--red); color: #fff;
  font-size: 11px; line-height: 17px; text-align: center;
}
.nav-item.active .nav-badge { background: rgba(255, 255, 255, 0.28); }

.page {
  flex: 1;
  width: 100%; max-width: 1120px;
  margin: 0 auto; padding: 18px 20px 40px;
}

.sync-bar {
  display: flex; align-items: center; gap: 6px;
  font-size: 12px; color: var(--muted);
  padding: 4px 10px; border-radius: 999px;
  background: var(--bg);
}
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
.dot.syncing { background: var(--amber); }
.dot.err { background: var(--red); }

/* ---------- 卡片与文字 ---------- */

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 16px 18px;
}

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

.card-head {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 12px;
}
.card-title { font-size: 15px; font-weight: 500; }
.card-sub { font-size: 12px; color: var(--muted); }
.card-head .spacer { margin-left: auto; }

h2.section {
  font-size: 14px; font-weight: 500; color: var(--muted);
  margin: 22px 0 10px; letter-spacing: 0.2px;
}

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }

.muted { color: var(--muted); }
.small { font-size: 12px; }
.mono { font-variant-numeric: tabular-nums; }
.center { text-align: center; }
.empty {
  padding: 34px 16px; text-align: center; color: var(--faint); font-size: 14px;
}

/* ---------- 按钮 ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 38px; padding: 0 14px;
  border-radius: 10px; border: 1px solid var(--line-strong);
  background: #fff; color: var(--text);
  font-size: 14px; white-space: nowrap;
  transition: background 0.15s, border-color 0.15s;
}
.btn:hover { background: #f7f9fd; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn.primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn.primary:hover { background: var(--blue-dark); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--muted); }
.btn.ghost:hover { background: var(--bg); color: var(--text); }
.btn.danger { color: var(--red); border-color: #f3c9c9; }
.btn.danger:hover { background: var(--red-soft); }
.btn.sm { min-height: 32px; padding: 0 10px; font-size: 13px; border-radius: 8px; }
.btn.block { width: 100%; }
.btn.lg { min-height: 46px; font-size: 15px; }

.icon-btn {
  width: 34px; height: 34px; border-radius: 9px;
  display: grid; place-items: center; color: var(--muted);
}
.icon-btn:hover { background: var(--bg); color: var(--text); }

/* 标题栏的「完成」胶囊：状态操作放在顶部，与底部的保存/移出/删除彻底分开 */
.done-btn {
  display: inline-flex; align-items: center; gap: 4px;
  height: 30px; padding: 0 11px 0 9px; border-radius: 15px;
  flex: 0 0 auto; white-space: nowrap; cursor: pointer;
  border: 1px solid var(--line-strong); background: #fff;
  color: var(--muted); font-size: 12.5px; font-family: inherit; line-height: 1;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.done-btn:hover { border-color: #b7e2c9; background: #f5fbf7; color: #18a058; }
.done-btn.on { background: #eef9f2; border-color: #b7e2c9; color: #18a058; }
.done-btn:disabled { opacity: 0.6; cursor: default; }

/* ---------- 表单 ---------- */

.field { display: block; margin-bottom: 14px; }
.field > .label {
  display: block; font-size: 12px; color: var(--muted); margin-bottom: 6px;
}
.input, .select, .textarea {
  width: 100%; min-height: 42px; padding: 9px 12px;
  border: 1px solid var(--line-strong); border-radius: 10px;
  background: #fff; font-size: 16px; /* 防 iOS 缩放 */
  outline: none; transition: border-color 0.15s, box-shadow 0.15s;
}
.input:focus, .select:focus, .textarea:focus {
  border-color: var(--blue); box-shadow: 0 0 0 3px rgba(59, 110, 240, 0.12);
}
.textarea { min-height: 74px; resize: vertical; line-height: 1.5; font-size: 15px; }
.select { appearance: none; background-image: none; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.hint { font-size: 12px; color: var(--faint); margin-top: 6px; line-height: 1.5; }
.err-text { font-size: 13px; color: var(--red); margin-top: 8px; min-height: 18px; }

/* ---------- 徽标 ---------- */

.tag {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 7px; border-radius: 6px;
  font-size: 11.5px; line-height: 1.6; white-space: nowrap;
  background: var(--bg); color: var(--muted);
}
.tag.code { font-variant-numeric: tabular-nums; background: #f2f4f9; color: #5c6579; }
.tag.high { background: var(--red-soft); color: var(--red); }
.tag.mid { background: var(--amber-soft); color: var(--amber); }
.tag.low { background: #f1f3f8; color: var(--muted); }
.tag.done { background: var(--green-soft); color: var(--green); }
.tag.doing { background: var(--blue-soft); color: var(--blue); }
.tag.overdue { background: var(--red-soft); color: var(--red); }
.tag.due { background: var(--amber-soft); color: var(--amber); }
.tag.daily { background: var(--purple-soft); color: var(--purple); }
.tag.private { background: #eef0f4; color: #6b7280; }
.tag.wtype { background: var(--blue-soft); color: var(--blue); }
.tag.wtype.none { background: #fdf5e6; color: #9a6b1f; }
select.unclassified { color: #9a6b1f; border-color: #e7cfa6; background: #fffaf0; }
.tag.urge { background: var(--red-soft); color: var(--red); }
.tag.pause { background: #eef0f4; color: #6b7280; }
/* 已暂停的任务整体淡化，明确区别于"未开始/进行中" */
.task.paused .task-title { color: var(--faint); }
.board-card.paused { opacity: .6; }
.board-card.paused:hover { opacity: 1; }

.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 11px; border-radius: 999px;
  border: 1px solid var(--line-strong); background: #fff;
  font-size: 13px; color: var(--muted);
}
.pill.active { background: var(--blue-soft); border-color: #c9d8ff; color: var(--blue); }

/* ---------- 任务行 ---------- */

.task-list { display: flex; flex-direction: column; }

.task {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 13px 2px;
  border-bottom: 1px solid var(--line);
}
.task:last-child { border-bottom: 0; }

.check {
  flex: 0 0 auto; width: 26px; height: 26px; margin-top: 1px;
  border-radius: 50%; border: 1.5px solid var(--line-strong);
  display: grid; place-items: center; color: transparent;
  transition: all 0.15s;
}
.check:hover { border-color: var(--blue); }
.check.on { background: var(--green); border-color: var(--green); color: #fff; }

.task-main { flex: 1; min-width: 0; }
.task-title {
  font-size: 14.5px; line-height: 1.45;
  word-break: break-word;
}
.task.done .task-title { color: var(--faint); text-decoration: line-through; }
.task-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 6px; }
.task-meta { flex: 0 0 auto; font-size: 12px; color: var(--muted); text-align: right; }

/* ---------- 统计 ---------- */

.stat {
  background: var(--card); border: 1px solid var(--line); border-radius: 14px;
  padding: 13px 14px;
}
.stat-label { font-size: 12px; color: var(--muted); }
.stat-value { font-size: 22px; font-weight: 500; font-variant-numeric: tabular-nums; line-height: 1.3; }
.stat-value small { font-size: 12px; color: var(--faint); font-weight: 400; margin-left: 3px; }

.ring-wrap { display: flex; align-items: center; gap: 18px; }
.ring { position: relative; width: 92px; height: 92px; flex: 0 0 auto; }
.ring-center {
  position: absolute; inset: 0; display: grid; place-items: center;
  font-size: 18px; font-weight: 500; font-variant-numeric: tabular-nums;
}
.ring-center small { font-size: 11px; color: var(--faint); display: block; text-align: center; }

.bar { height: 6px; background: #eef1f7; border-radius: 4px; overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: 4px; background: var(--blue); transition: width 0.4s; }
.bar > i.green { background: var(--green); }
.bar > i.amber { background: var(--amber); }

/* 进度加减：进度条上方一行，点一次记 1 次 */
.prog-row { display: flex; align-items: center; gap: 6px; }
.prog-row .spacer { flex: 1; }
.step-btn {
  flex: 0 0 auto; width: 30px; height: 30px; padding: 0;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line-strong); border-radius: 9px; background: #fff;
  color: var(--muted); font-size: 17px; line-height: 1; font-family: inherit;
  cursor: pointer; transition: border-color .15s, color .15s, background .15s;
}
.step-btn:hover { border-color: var(--blue); color: var(--blue); background: var(--blue-soft); }
.step-btn:active { transform: scale(.95); }
.step-btn:disabled { opacity: .45; cursor: default; }
.step-num {
  width: 56px; height: 30px; padding: 0 2px; text-align: center;
  border: 1px solid var(--line-strong); border-radius: 9px; background: #fff;
  color: var(--text); font-size: 15px; font-family: inherit; outline: none;
  -moz-appearance: textfield;
}
.step-num::-webkit-outer-spin-button,
.step-num::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.step-num:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(59, 110, 240, .12); }

/* ---------- 表格 ---------- */

.table { width: 100%; }
.table-head, .trow {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr) 96px 110px 96px 88px 82px 64px;
  align-items: center; gap: 10px;
}
.table-head {
  font-size: 12px; color: var(--muted);
  padding: 8px 10px; border-bottom: 1px solid var(--line);
}
.trow {
  padding: 10px; border-bottom: 1px solid var(--line);
  font-size: 13.5px;
}
.trow:hover { background: #f8fafd; }
.trow.done .t-title { color: var(--faint); text-decoration: line-through; }
.t-title { min-width: 0; word-break: break-word; line-height: 1.4; }
.t-title .task-tags { margin-top: 4px; }
.trow .cell { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; color: #4a5468; }
.trow select {
  width: 100%; min-height: 30px; padding: 2px 6px;
  border: 1px solid transparent; border-radius: 7px;
  background: transparent; font-size: 13px; color: #4a5468;
}
.trow select:hover { border-color: var(--line-strong); background: #fff; }
.row-actions { display: flex; gap: 2px; justify-content: flex-end; }
.row-actions .icon-btn { width: 28px; height: 28px; border-radius: 7px; }

/* ---------- 看板 ---------- */

.board { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.board-col { background: #eff2f8; border-radius: 14px; padding: 10px; min-height: 120px; }
.board-col h3 { font-size: 13px; font-weight: 500; color: #4a5468; margin-bottom: 9px; display: flex; gap: 6px; }
.board-card {
  background: #fff; border: 1px solid var(--line); border-radius: 11px;
  padding: 10px 11px; margin-bottom: 8px; font-size: 13px; line-height: 1.45;
  word-break: break-word;
}
.board-card .task-tags { margin-top: 6px; }

/* ---------- 抽屉 ---------- */

.mask {
  position: fixed; inset: 0; z-index: 60;
  background: rgba(17, 24, 39, 0.34);
  opacity: 0; pointer-events: none; transition: opacity 0.24s;
}
.mask.open { opacity: 1; pointer-events: auto; }

.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 61;
  width: 440px; max-width: 94vw;
  background: var(--card);
  display: flex; flex-direction: column;
  transform: translateX(102%); transition: transform 0.26s cubic-bezier(0.32, 0.72, 0, 1);
  box-shadow: -8px 0 32px rgba(17, 24, 39, 0.12);
}
.drawer.open { transform: translateX(0); }
.drawer-head {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 18px; border-bottom: 1px solid var(--line);
}
.drawer-head .title { font-size: 15px; font-weight: 500; flex: 1; min-width: 0; }
.drawer-head .title > div:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.drawer-body { flex: 1; overflow-y: auto; padding: 16px 18px; -webkit-overflow-scrolling: touch; }
.drawer-foot {
  padding: 12px 18px calc(12px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  display: flex; flex-wrap: wrap; gap: 8px;
}
.drawer-foot .btn { flex: 1 1 auto; min-width: 0; padding: 0 10px; }
.drawer-acts { display: flex; gap: 8px; flex: 1 1 100%; }
.drawer-acts .btn { flex: 1 1 0; min-width: 0; padding: 0 8px; font-size: 13px; }

/* ---------- 标签页 ---------- */

.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 14px; }
.tab {
  padding: 9px 12px; font-size: 14px; color: var(--muted);
  border-bottom: 2px solid transparent; margin-bottom: -1px;
}
.tab.active { color: var(--blue); border-color: var(--blue); }

/* ---------- 提示 ---------- */

.toast {
  position: fixed; left: 50%; bottom: 28px; z-index: 90;
  transform: translate(-50%, 20px);
  background: #1f2937; color: #fff;
  padding: 10px 18px; border-radius: 999px;
  font-size: 13.5px; max-width: 86vw; text-align: center;
  opacity: 0; pointer-events: none; transition: all 0.24s;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.banner {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 11px 14px; border-radius: 12px;
  font-size: 13px; line-height: 1.5; margin-bottom: 14px;
}
.banner.warn { background: var(--amber-soft); color: #8a5a00; }
.banner.err { background: var(--red-soft); color: #a12b2b; }
.banner.info { background: var(--blue-soft); color: #2451b5; }

/* ---------- 登录 ---------- */

.auth-wrap {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  padding: 24px 18px;
  background: radial-gradient(circle at 50% 0%, #eef3ff 0%, var(--bg) 46%);
}
.auth-card {
  width: 100%; max-width: 400px;
  background: var(--card); border: 1px solid var(--line);
  border-radius: 20px; padding: 26px 24px 22px;
  box-shadow: 0 10px 30px rgba(27, 35, 51, 0.06);
}
.auth-logo {
  width: 44px; height: 44px; border-radius: 13px;
  background: var(--blue); color: #fff;
  display: grid; place-items: center; font-size: 18px; font-weight: 600;
  margin-bottom: 16px;
}
.auth-title { font-size: 20px; font-weight: 500; margin-bottom: 4px; }
.auth-sub { font-size: 13px; color: var(--muted); margin-bottom: 22px; }
.auth-tabs { display: flex; gap: 4px; background: var(--bg); padding: 3px; border-radius: 10px; margin-bottom: 18px; }
.auth-tab { flex: 1; text-align: center; padding: 7px; border-radius: 8px; font-size: 13.5px; color: var(--muted); }
.auth-tab.active { background: #fff; color: var(--text); box-shadow: var(--shadow); }
.code-row { display: flex; gap: 8px; }
.code-row .input { flex: 1; }
.code-row .btn { flex: 0 0 auto; min-width: 106px; }
.auth-foot { margin-top: 16px; font-size: 12px; color: var(--faint); text-align: center; line-height: 1.6; }
.auth-forgot {
  align-self: flex-start; margin-top: -4px; padding: 2px 0;
  background: none; border: 0; cursor: pointer;
  color: var(--blue); font-size: 13px; font-family: inherit;
}
.auth-forgot:hover { text-decoration: underline; }

/* ---------- 批量分配 ---------- */

.bulk-bar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  background: var(--blue-soft); border: 1px solid #c9d8ff;
  border-radius: 12px; padding: 10px 14px; margin: 12px 0 4px;
  font-size: 13.5px; color: #2451b5;
}
.bulk-bar .spacer { margin-left: auto; }

.modal-mask {
  position: fixed; inset: 0; z-index: 70;
  background: rgba(17, 24, 39, 0.34);
}
.modal-wrap {
  position: fixed; inset: 0; z-index: 71;
  display: flex; align-items: flex-end; justify-content: center;
}
.modal {
  background: #fff; width: 100%; max-width: 460px;
  border-radius: 18px 18px 0 0;
  padding: 18px 18px calc(18px + env(safe-area-inset-bottom));
  max-height: 82vh; overflow-y: auto;
}
.modal-title { font-size: 15px; font-weight: 500; margin-bottom: 4px; }
.modal-sub { font-size: 12px; color: var(--muted); margin-bottom: 14px; }
.modal-actions { display: flex; gap: 10px; margin-top: 18px; }
.modal-actions .btn { flex: 1; }
.chip-grid { display: flex; flex-wrap: wrap; gap: 8px; }

.check-box {
  width: 18px; height: 18px; flex: 0 0 auto;
  border: 1.5px solid var(--line-strong); border-radius: 5px;
  display: grid; place-items: center; color: transparent;
  background: #fff;
}
.check-box.on { background: var(--blue); border-color: var(--blue); color: #fff; }

@media (min-width: 600px) {
  .modal-wrap { align-items: center; }
  .modal { border-radius: 18px; }
}

/* ---------- 手机端 ---------- */

.bottom-nav { display: none; }

@media (max-width: 900px) {
  .grid-4 { grid-template-columns: 1fr 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
  .board { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  body { font-size: 15px; }
  .topbar-inner { padding: 9px 14px; }
  .nav { display: none; }
  .page { padding: 12px 14px 92px; }
  .card { padding: 14px 14px; border-radius: 14px; }
  .grid-2 { grid-template-columns: 1fr; }
  .brand-sub { display: none; }
  .sync-bar span.lbl { display: none; }

  .table-head { display: none; }
  .trow {
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "code code"
      "title title"
      "meta meta"
      "actions actions";
    gap: 6px; padding: 13px 4px; border-bottom: 1px solid var(--line);
  }
  .trow .c-code { grid-area: code; }
  .trow .c-title { grid-area: title; }
  .trow .c-meta { grid-area: meta; display: flex; flex-wrap: wrap; gap: 8px; }
  .trow .c-hide { display: none; }
  .trow .row-actions { grid-area: actions; justify-content: flex-start; }

  .drawer { width: 100%; max-width: 100%; transform: translateY(102%); border-radius: 0; }
  .drawer.open { transform: translateY(0); }
  .drawer-body { padding-bottom: 30px; }

  .ring-wrap { flex-direction: column; align-items: stretch; gap: 14px; }
  .ring-wrap .ring { align-self: center; }
  .ring-wrap .grid-2 { grid-template-columns: 1fr 1fr; width: 100%; }
  .stat-value { font-size: 20px; }
  .stat .small { display: none; }

  .bottom-nav {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: saturate(180%) blur(12px);
    border-top: 1px solid var(--line);
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  }
  .bn-item {
    flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px;
    padding: 6px 2px; border-radius: 10px; font-size: 11px; color: var(--faint);
    position: relative; min-height: var(--tap);
    justify-content: center;
  }
  .bn-item.active { color: var(--blue); }
  .bn-item .nav-badge { position: absolute; top: 2px; right: 50%; margin-right: -20px; }
  .auth-wrap { align-items: flex-start; padding-top: 8vh; }
}

@media (max-width: 400px) {
  .grid-4 { grid-template-columns: 1fr 1fr; gap: 8px; }
  .stat { padding: 11px 12px; }
  .stat-value { font-size: 19px; }
}

/* ---------- 任务清单：分组 + 精简行 ---------- */

.tgroup-head {
  display: flex; align-items: center; gap: 8px;
  padding: 16px 4px 8px; font-size: 12.5px; color: var(--muted);
  cursor: pointer; user-select: none;
}
.tgroup-head b { font-size: 13px; color: var(--text); font-weight: 600; }
.tgroup-head .n { color: var(--faint); font-variant-numeric: tabular-nums; }
.tgroup-head .n.ok { color: #18a058; }
.tgroup-head .check-box { width: 16px; height: 16px; }
.gdot { width: 7px; height: 7px; border-radius: 50%; flex: 0 0 auto; }
.garrow { display: grid; place-items: center; color: var(--faint); transition: transform 0.18s; }
.garrow.open { transform: rotate(180deg); }

.titem {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 6px; border-bottom: 1px solid var(--line); cursor: pointer;
}
.titem:hover { background: #f8fafd; }
.titem-main { flex: 1; min-width: 0; }
.titem-title { font-size: 14px; line-height: 1.4; word-break: break-word; }
.titem.done .titem-title { color: var(--faint); text-decoration: line-through; }
.titem-sub { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 5px; font-size: 12px; color: var(--muted); }
.titem-sub .c { white-space: nowrap; }
.titem-sub .c.hi { color: var(--red); }
.titem-status { flex: 0 0 auto; display: flex; align-items: center; gap: 6px; font-size: 12px; white-space: nowrap; }
.sdot { width: 6px; height: 6px; border-radius: 50%; flex: 0 0 auto; }
.tlist { padding: 6px 16px 12px; }
.tlist .tgroup-head:first-child { padding-top: 10px; }
.tlist .titem:last-child { border-bottom: 0; }

/* ---------- 周报 ---------- */

.wk-nav { display: flex; align-items: center; gap: 10px; margin: 2px 0 10px; }
.wk-nav .btn { min-width: 44px; }
.wk-range { flex: 1; text-align: center; font-size: 14px; font-weight: 600; }
.wk-sum { font-size: 12.5px; color: var(--muted); }
.wk-note { font-size: 11.5px; color: var(--faint); margin-top: 6px; line-height: 1.6; }
.wk-phead { display: flex; align-items: center; gap: 10px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.wk-av {
  width: 32px; height: 32px; border-radius: 50%; flex: 0 0 auto;
  background: var(--blue-soft); color: var(--blue);
  display: grid; place-items: center; font-size: 13px;
}
.wk-name { display: flex; align-items: baseline; gap: 8px; font-size: 14px; font-weight: 600; }
.wk-count { font-size: 12px; font-weight: 400; color: var(--muted); }
.wk-psub { font-size: 12px; color: var(--faint); margin-top: 3px; }
.wk-day { display: flex; align-items: baseline; gap: 8px; font-size: 12px; color: var(--muted); padding: 12px 0 4px; }
.wk-dayfull { font-size: 11px; color: var(--faint); }
.wk-item { display: flex; align-items: flex-start; gap: 10px; padding: 7px 0; }
.wk-item + .wk-item { border-top: 1px dashed var(--line); }
.wk-title { font-size: 13.5px; line-height: 1.45; word-break: break-word; }
.wk-code { font-size: 11.5px; color: var(--faint); margin-right: 6px; font-variant-numeric: tabular-nums; }
.wk-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 4px; }
.wk-qty { flex: 0 0 auto; font-size: 12px; color: var(--muted); white-space: nowrap; }

/* ---------- 任务层级：新建与向下拆分 ---------- */

.lv-add {
  width: 22px; height: 22px; padding: 0; border-radius: 7px;
  display: grid; place-items: center; font-size: 14px; line-height: 1;
  background: #fff; border: 1px solid var(--line-strong); color: var(--muted);
}
.lv-add:hover { color: var(--blue); border-color: #c9d8ff; background: var(--blue-soft); }
.lv-split {
  width: 100%; margin-top: 7px; padding: 4px 8px; border-radius: 7px;
  font-size: 12px; background: #fff; color: var(--muted);
  border: 1px dashed var(--line-strong);
}
.lv-split:hover { color: var(--blue); border-color: #c9d8ff; background: var(--blue-soft); }
.lv-acts { display: flex; gap: 5px; margin-top: 7px; }
.lv-acts .lv-split { flex: 1 1 0; min-width: 0; margin-top: 0; padding: 4px 3px; font-size: 11.5px; white-space: nowrap; }
/* ---------- 挂载已有任务 ---------- */
.lk-list { max-height: 48vh; overflow: auto; border-top: 1px solid var(--line); }
.lk-row { display: flex; align-items: flex-start; gap: 9px; padding: 9px 2px; border-bottom: 1px dashed var(--line); cursor: pointer; }
.lk-row input { margin: 3px 0 0; flex: 0 0 auto; }
.lk-title { font-size: 13.5px; line-height: 1.45; word-break: break-word; }
.lk-sub { font-size: 11.5px; color: var(--faint); margin-top: 3px; }
.titem-sub .c-lvl { color: var(--blue); background: var(--blue-soft); padding: 0 6px; border-radius: 5px; }
