/* 个人工作台 v2 · Product Teal */
:root {
  --brand: #12B886;
  --brand-deep: #0CA678;
  --brand-soft: #E6F7F0;
  --accent: #228BE6;
  --ink: #1F2937;
  --muted: #6B7280;
  --line: #E5E7EB;
  --bg: #F6F8F7;
  --card: #FFFFFF;
  --danger: #FA5252;
  --warn: #F59F00;
  --ok: #12B886;
  --shadow: 0 1px 3px rgba(16, 24, 40, .06), 0 1px 2px rgba(16, 24, 40, .04);
  --radius: 14px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 16px; line-height: 1.55; color: var(--ink);
  background: var(--bg);
  padding-bottom: calc(76px + env(safe-area-inset-bottom));
  min-height: 100vh;
}
.hidden { display: none !important; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
input, textarea { font: inherit; color: inherit; }
.hint { font-size: .82rem; color: var(--muted); }
.empty { font-size: .9rem; color: var(--muted); text-align: center; padding: 18px 0; }

/* 顶栏 */
.topbar {
  position: sticky; top: 0; z-index: 20;
  background: rgba(246, 248, 247, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
  padding-top: env(safe-area-inset-top);
}
.topbar__inner {
  max-width: 720px; margin: 0 auto; padding: 10px 16px;
  display: flex; align-items: center; justify-content: space-between;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand__logo {
  width: 38px; height: 38px; border-radius: 10px;
  background: var(--brand); color: #fff; font-weight: 700;
  display: flex; align-items: center; justify-content: center; font-size: 20px;
}
.brand__name { font-weight: 700; font-size: 1.02rem; line-height: 1.2; }
.brand__sub { font-size: .76rem; color: var(--muted); }
.topbar__actions { display: flex; align-items: center; gap: 10px; }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--muted); display: inline-block; }
.dot--ok { background: var(--ok); box-shadow: 0 0 0 3px rgba(18, 184, 134, .18); }
.dot--bad { background: var(--danger); box-shadow: 0 0 0 3px rgba(250, 82, 82, .18); }

/* 布局 */
.main { max-width: 720px; margin: 0 auto; padding: 14px 16px 24px; }
.view { display: flex; flex-direction: column; gap: 12px; }

.card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px;
}
.card--soft { background: var(--brand-soft); border-color: transparent; }
.card__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.card h2 { font-size: 1rem; }
.card h3 { font-size: .95rem; margin-bottom: 6px; }
.linkbtn { font-size: .84rem; color: var(--accent); min-height: 44px; display: flex; align-items: center; }

/* 按钮 */
.btn {
  min-height: 44px; padding: 0 18px; border-radius: 10px;
  background: #EEF1F0; font-weight: 600; font-size: .95rem;
  transition: filter .15s, transform .05s;
}
.btn:active { transform: scale(.97); }
.btn--primary { background: var(--brand); color: #fff; }
.btn--primary:hover { filter: brightness(1.05); }
.btn--ghost { background: transparent; border: 1px solid var(--line); }
.btn--sm { min-height: 36px; padding: 0 12px; font-size: .84rem; }
.btn--block { width: 100%; margin-top: 12px; }
.btn[disabled] { opacity: .55; pointer-events: none; }

.input, .textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 10px;
  padding: 11px 13px; background: #fff; font-size: 16px; outline: none;
}
.input:focus, .textarea:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(18, 184, 134, .12); }
.textarea { resize: vertical; min-height: 110px; }

/* 今日三件事 */
.addrow { display: flex; gap: 10px; margin-top: 12px; }
.addrow .input { flex: 1; }
.todo { list-style: none; }
.todo__item {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 10px 0; border-bottom: 1px dashed var(--line);
}
.todo__item:last-child { border-bottom: 0; }
.todo__item.dragging { opacity: .4; }
.todo__check {
  width: 22px; height: 22px; margin-top: 2px; flex: none;
  border: 2px solid #C6CDD2; border-radius: 50%; background: #fff;
  display: flex; align-items: center; justify-content: center; color: #fff; font-size: 13px;
}
.todo__item.done .todo__check { background: var(--brand); border-color: var(--brand); }
.todo__body { flex: 1; min-width: 0; }
.todo__text { font-size: .95rem; word-break: break-word; }
.todo__item.done .todo__text { color: var(--muted); text-decoration: line-through; }
.todo__src { font-size: .72rem; color: var(--muted); background: var(--bg); border-radius: 5px; padding: 1px 6px; display: inline-block; margin-top: 3px; }
.todo__ops { display: flex; gap: 2px; flex: none; }
.todo__ops button { width: 32px; height: 32px; border-radius: 8px; color: var(--muted); font-size: .9rem; }
.todo__ops button:hover { background: var(--bg); color: var(--ink); }

/* 状态与异动 */
.strow { padding: 7px 0; border-bottom: 1px dashed var(--line); }
.strow:last-child { border-bottom: 0; }
.strow__label { font-size: .78rem; color: var(--muted); margin-bottom: 5px; }
.strow__pills { display: flex; flex-wrap: wrap; gap: 7px; }
.pill {
  font-size: .8rem; padding: 4px 11px; border-radius: 999px;
  background: var(--bg); border: 1px solid var(--line); white-space: nowrap;
}
.pill--ok { background: var(--brand-soft); color: var(--brand-deep); border-color: transparent; }
.pill--info { background: #E7F0FC; color: var(--accent); border-color: transparent; }
.pill--warn { background: #FDF3E0; color: #B8860B; border-color: transparent; }
.pill--danger { background: #FEECEC; color: var(--danger); border-color: transparent; }

/* 最近文档 */
.files { list-style: none; }
.files li {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 0; border-bottom: 1px dashed var(--line);
}
.files li:last-child { border-bottom: 0; }
.files__ico { flex: none; width: 34px; height: 34px; border-radius: 8px; background: var(--bg); display: flex; align-items: center; justify-content: center; font-size: .68rem; font-weight: 700; color: var(--muted); }
.files__body { flex: 1; min-width: 0; }
.files__name { font-size: .9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.files__meta { font-size: .74rem; color: var(--muted); }

/* 采集 */
.tabs { display: flex; gap: 6px; margin-bottom: 14px; }
.tab {
  flex: 1; min-height: 40px; border-radius: 10px;
  background: var(--bg); font-size: .9rem; color: var(--muted);
}
.tab--active { background: var(--brand-soft); color: var(--brand-deep); font-weight: 600; }
.cappane { display: flex; flex-direction: column; gap: 10px; }
.uploader {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  border: 1.5px dashed #C6CDD2; border-radius: 12px;
  padding: 30px 16px; color: var(--muted); cursor: pointer;
}
.uploader:active, .uploader:hover { border-color: var(--brand); color: var(--brand-deep); background: var(--brand-soft); }
.uploader__icon { font-size: 26px; }
.uploader__t { font-weight: 600; font-size: .95rem; }
.hiddenfile { display: none; }

/* 收集箱 */
.inbox { list-style: none; }
.inbox__item { border-bottom: 1px dashed var(--line); }
.inbox__item:last-child { border-bottom: 0; }
.inbox__row {
  width: 100%; display: flex; align-items: center; gap: 10px;
  padding: 11px 0; text-align: left;
}
.inbox__ico { flex: none; width: 34px; height: 34px; border-radius: 8px; background: var(--bg); display: flex; align-items: center; justify-content: center; font-size: 15px; }
.inbox__body { flex: 1; min-width: 0; }
.inbox__name { font-size: .88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.inbox__meta { font-size: .74rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.inbox__archive {
  flex: none; min-height: 36px; padding: 0 12px; border-radius: 9px;
  background: var(--brand-soft); color: var(--brand-deep); font-size: .82rem; font-weight: 600;
}
.inbox__detail { padding: 0 0 12px 44px; }
.inbox__content {
  font-size: .85rem; white-space: pre-wrap; word-break: break-word;
  background: var(--bg); border-radius: 10px; padding: 10px 12px;
  max-height: 260px; overflow: auto; color: #374151;
}
.inbox__img { max-width: 100%; border-radius: 10px; }

/* 底部导航 */
.nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom);
  display: flex; justify-content: space-around;
}
.nav__btn {
  flex: 1; max-width: 180px; min-height: 56px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px;
  font-size: .7rem; color: var(--muted); position: relative;
}
.nav__btn svg { width: 23px; height: 23px; fill: currentColor; }
.nav__btn.active { color: var(--brand-deep); font-weight: 600; }
.nav__btn--fab { color: var(--muted); }
.nav__btn--fab svg {
  width: 46px; height: 46px; fill: var(--brand);
  filter: drop-shadow(0 2px 5px rgba(18, 184, 134, .35));
  margin-top: -18px;
}
.nav__btn--fab.active svg { fill: var(--brand-deep); }
.nav__badge {
  position: absolute; top: 4px; right: calc(50% - 26px);
  min-width: 17px; height: 17px; border-radius: 999px;
  background: var(--danger); color: #fff; font-size: .64rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center; padding: 0 4px;
}

/* 横幅与提示 */
.banner {
  position: sticky; top: 0; z-index: 40;
  background: #FDF3E0; color: #92600A; font-size: .84rem;
  text-align: center; padding: 7px 14px;
}
.toast {
  position: fixed; left: 50%; bottom: calc(84px + env(safe-area-inset-bottom));
  transform: translateX(-50%); z-index: 50;
  background: rgba(31, 41, 55, .94); color: #fff; font-size: .88rem;
  border-radius: 999px; padding: 10px 20px; max-width: 86vw;
  text-align: center; box-shadow: 0 4px 14px rgba(0, 0, 0, .25);
}

/* iOS 安装提示 */
.sheet {
  position: fixed; inset: 0; z-index: 60;
  background: rgba(17, 24, 39, .45);
  display: flex; align-items: flex-end; justify-content: center;
}
.sheet__card {
  background: #fff; border-radius: 18px 18px 0 0; width: 100%; max-width: 720px;
  padding: 22px 20px calc(20px + env(safe-area-inset-bottom));
}
.sheet__card h3 { margin-bottom: 8px; }

/* 桌面端 */
@media (min-width: 760px) {
  body { padding-bottom: 32px; }
  .nav { position: sticky; top: 61px; border-top: 0; background: transparent; backdrop-filter: none; }
  .nav__btn { max-width: 130px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; min-height: 44px; margin: 10px 6px 0; flex-direction: row; gap: 7px; font-size: .86rem; }
  .nav__btn svg { width: 18px; height: 18px; }
  .nav__btn--fab svg { width: 18px; height: 18px; filter: none; margin-top: 0; }
  .nav__badge { position: static; margin-left: 2px; }
}

/* ===== M3 文档阅读与编辑 ===== */
.input--sm { min-height: 38px; padding: 8px 11px; font-size: 15px; }
.row { display: flex; gap: 10px; margin-top: 12px; }
.row--end { justify-content: flex-end; }

.docs {
  display: flex; align-items: stretch;
  height: calc(100vh - 200px); min-height: 440px;
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden;
}
.docs__pane { min-width: 0; display: flex; flex-direction: column; overflow: hidden; }
.docs__tree { width: 264px; flex: none; border-right: 1px solid var(--line); background: #FCFDFC; }
.docs__editor { flex: 1 1 auto; }
.docs__preview { width: 380px; flex: none; border-left: 1px solid var(--line); background: #FCFDFC; }

.splitter { width: 6px; flex: none; cursor: col-resize; position: relative; z-index: 2; background: transparent; }
.splitter::after { content: ''; position: absolute; left: 2px; top: 0; bottom: 0; width: 2px; background: transparent; }
.splitter:hover::after, .splitter.dragging::after { background: var(--brand); }

.docs__treehead { display: flex; gap: 8px; padding: 10px 10px 8px; }
.docs__treehead .input { flex: 1; }
.crumb { display: flex; flex-wrap: wrap; gap: 2px; padding: 0 12px 8px; font-size: .76rem; color: var(--muted); }
.crumb__seg { cursor: pointer; color: var(--accent); }
.crumb__seg:last-child { color: var(--muted); cursor: default; }
.crumb__seg + .crumb__seg::before { content: '/'; margin: 0 3px; color: var(--line); }

.doclist { list-style: none; overflow: auto; flex: 1; padding: 0 6px 10px; }
.doclist__row { width: 100%; display: flex; align-items: center; gap: 8px; padding: 8px 9px; text-align: left; border-radius: 9px; }
.doclist__row:hover { background: var(--bg); }
.doclist__row.active { background: var(--brand-soft); }
.doclist__ico { flex: none; width: 26px; height: 26px; border-radius: 7px; background: var(--bg); display: flex; align-items: center; justify-content: center; font-size: 13px; }
.doclist__body { flex: 1; min-width: 0; }
.doclist__name { font-size: .84rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.doclist__meta { font-size: .7rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.docs__bar { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border-bottom: 1px solid var(--line); flex: none; }
.docs__bar--slim { justify-content: space-between; }
.docs__title { flex: 1; min-width: 0; }
.docs__name { font-size: .92rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.docs__sub { font-size: .72rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.docs__tools { display: flex; align-items: center; gap: 6px; flex: none; }
.docs__body { flex: 1; min-height: 0; display: flex; flex-direction: column; }

.doceditor {
  flex: 1; width: 100%; border: 0; outline: none; resize: none;
  padding: 16px 18px; font-size: 16px; line-height: 1.75; background: #fff; color: var(--ink);
  font-family: ui-monospace, "Cascadia Mono", Consolas, "Microsoft YaHei", monospace;
}
.docx { flex: 1; overflow: auto; padding: 18px 20px; font-size: 16px; line-height: 1.8; }
.docx [contenteditable] { outline: none; padding: 2px 4px; border-radius: 5px; white-space: pre-wrap; }
.docx [contenteditable]:focus { background: var(--brand-soft); box-shadow: 0 0 0 2px rgba(18, 184, 134, .25); }
.docx__h1 { font-size: 1.35rem; font-weight: 700; margin: 14px 0 6px; }
.docx__h2 { font-size: 1.15rem; font-weight: 700; margin: 12px 0 5px; }
.docx__h3 { font-size: 1.02rem; font-weight: 600; margin: 10px 0 4px; }
.docx__p { margin: 4px 0; }
.docplaceholder { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; color: var(--muted); text-align: center; padding: 24px; }
.docplaceholder__ico { font-size: 34px; }
.notice { padding: 8px 14px; font-size: .8rem; background: #FDF3E0; color: #92600A; border-bottom: 1px solid var(--line); }
.notice--danger { background: #FEECEC; color: var(--danger); }

.preview { flex: 1; overflow: auto; padding: 16px 20px; font-size: .9rem; line-height: 1.75; }
.preview h1 { font-size: 1.3rem; margin: 6px 0 10px; }
.preview h2 { font-size: 1.12rem; margin: 14px 0 8px; }
.preview h3 { font-size: 1rem; margin: 12px 0 6px; }
.preview p { margin: 8px 0; }
.preview ul { margin: 8px 0 8px 20px; }
.preview ol { margin: 8px 0 8px 22px; }
.preview li { margin: 3px 0; }
.preview blockquote { border-left: 3px solid var(--brand); background: var(--brand-soft); padding: 6px 12px; margin: 10px 0; color: #374151; }
.preview code { background: var(--bg); border-radius: 4px; padding: 1px 5px; font-size: .85em; font-family: ui-monospace, Consolas, monospace; }
.preview pre { background: #1F2937; color: #E5E7EB; border-radius: 10px; padding: 12px 14px; overflow: auto; margin: 10px 0; }
.preview pre code { background: none; color: inherit; padding: 0; }
.preview a { color: var(--accent); }
.preview hr { border: 0; border-top: 1px solid var(--line); margin: 14px 0; }
.preview table { border-collapse: collapse; margin: 10px 0; width: 100%; font-size: .84rem; }
.preview th, .preview td { border: 1px solid var(--line); padding: 5px 8px; text-align: left; }
.preview th { background: var(--bg); }
.preview mark { background: #FFF3BF; padding: 0 2px; border-radius: 3px; }

.annopanel { flex: none; max-height: 208px; display: flex; flex-direction: column; border-top: 1px solid var(--line); background: #FCFDFC; }
.annopanel__head { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px 4px; font-size: .82rem; font-weight: 600; }
.annopanel .hint { padding: 0 12px 8px; }
.annolist { list-style: none; overflow: auto; padding: 0 12px 10px; }
.annolist li { padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px; margin-bottom: 7px; background: #fff; }
.annolist li.stale { border-color: #F1C40F; background: #FFFDF3; }
.anno__quote { font-size: .8rem; color: #374151; background: var(--bg); border-radius: 6px; padding: 4px 8px; margin-bottom: 5px; word-break: break-word; }
.anno__note { font-size: .82rem; word-break: break-word; }
.anno__meta { font-size: .7rem; color: var(--muted); margin-top: 4px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.anno__ops { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.anno__ops button { font-size: .74rem; min-height: 30px; padding: 0 10px; border-radius: 7px; background: var(--bg); }
.anno__ops button.primary { background: var(--brand-soft); color: var(--brand-deep); font-weight: 600; }
.annoquote { border-left: 3px solid var(--brand); background: var(--brand-soft); padding: 6px 12px; margin: 8px 0 12px; font-size: .84rem; color: #374151; max-height: 120px; overflow: auto; }

.seltool {
  position: fixed; z-index: 70; display: flex; gap: 4px;
  background: rgba(31, 41, 55, .96); border-radius: 10px; padding: 5px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .28);
}
.seltool button { color: #fff; font-size: .8rem; min-height: 34px; padding: 0 11px; border-radius: 7px; }
.seltool button:hover { background: rgba(255, 255, 255, .16); }

/* 手机端：单栏轻编辑 */
@media (max-width: 759px) {
  .docs { height: calc(100vh - 210px); min-height: 400px; display: block; position: relative; }
  .docs__tree, .docs__preview { position: absolute; inset: 0; width: 100%; z-index: 5; display: none; }
  .docs--tree .docs__tree { display: flex; }
  .docs--preview .docs__preview { display: flex; }
  .docs__editor { display: flex; height: 100%; }
  .docs__tree { border-right: 0; }
  .docs__preview { border-left: 0; }
  .splitter { display: none; }
  .docs__onlymobile { display: inline-flex; }
  .docs__name { font-size: .86rem; }
  .annopanel { max-height: 168px; }
}
@media (min-width: 760px) {
  .docs__onlymobile { display: none; }
}

/* ---------- 任务下发与远程操控（M4） ---------- */
.field { display: flex; flex-direction: column; gap: 6px; margin-top: 14px; }
.field__label { font-size: .78rem; color: var(--muted); }
select.input { appearance: none; -webkit-appearance: none; padding-right: 34px;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; }
.taskmeta { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 12px; }
.taskdesc { margin-top: 8px; }
.taskparams { display: flex; flex-direction: column; gap: 12px; margin-top: 4px; }
.checkline { display: flex; align-items: center; gap: 9px; margin-top: 14px; font-size: .88rem; }
.checkline input { width: 20px; height: 20px; accent-color: var(--brand); flex: none; }

/* 执行日志面板 */
.log {
  margin-top: 12px; max-height: 320px; overflow: auto;
  background: #10161C; color: #D8E0E6; border-radius: 10px;
  padding: 12px 13px; font-size: .78rem; line-height: 1.65;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  white-space: pre-wrap; word-break: break-word;
}
.log__line { display: block; }
.log__line--err { color: #FF9B9B; }
.log__line--ok { color: #6BE3B8; }
.taskresult {
  margin-top: 10px; padding: 10px 12px; border-radius: 10px;
  background: var(--brand-soft); color: var(--brand-deep); font-size: .82rem;
  white-space: pre-wrap; word-break: break-word;
}
.taskresult.fail { background: #FEECEC; color: var(--danger); }

/* 任务历史表格 */
.tablewrap { overflow-x: auto; margin-top: 6px; }
.tasktable { width: 100%; border-collapse: collapse; font-size: .82rem; min-width: 480px; }
.tasktable th, .tasktable td { text-align: left; padding: 9px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tasktable th { font-size: .74rem; color: var(--muted); font-weight: 600; background: var(--bg); }
.tasktable td.tname { white-space: normal; min-width: 120px; }
.tasktable td.tops { text-align: right; }
.tasktable .op { font-size: .76rem; min-height: 30px; padding: 0 9px; border-radius: 7px; background: var(--bg); color: var(--accent); margin-left: 4px; }
.tasktable .op--warn { color: var(--danger); }
.tasktable tr.active td { background: var(--brand-soft); }
.tasktable .tmono { font-family: "SFMono-Regular", Consolas, monospace; font-size: .74rem; color: var(--muted); }

/* 覆盖文件清单 */
.ovlist { list-style: none; margin: 6px 0 4px; }
.ovlist li {
  font-size: .82rem; padding: 7px 10px; margin-bottom: 6px;
  background: #FDF3E0; color: #8A6100; border-radius: 8px; word-break: break-all;
}

/* 对话式指令（M5） */
.chatter {
  margin-top: 12px; max-height: 360px; overflow-y: auto;
  display: flex; flex-direction: column; gap: 9px;
  padding: 4px 2px;
}
.bubble {
  max-width: 86%; padding: 9px 12px; border-radius: 12px;
  font-size: .88rem; line-height: 1.6; white-space: pre-wrap; word-break: break-word;
}
.bubble--sys { align-self: flex-start; background: var(--bg); color: var(--ink); border: 1px solid var(--line); border-top-left-radius: 4px; }
.bubble--me { align-self: flex-end; background: var(--brand); color: #fff; border-top-right-radius: 4px; }
.bubble--warn { align-self: flex-start; background: #FDF3E0; color: #8A6100; border: 1px solid #F3E2C0; border-top-left-radius: 4px; }
.bubble--ok { align-self: flex-start; background: var(--brand-soft); color: var(--brand-deep); border: 1px solid #CFEFE2; border-top-left-radius: 4px; }

.chatter__row { flex-wrap: wrap; gap: 8px; }
.chatter__row .btn { min-height: 40px; padding: 0 16px; }
.chatter__row .linkbtn { padding: 0 4px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.chip {
  font-size: .8rem; padding: 7px 12px; border-radius: 999px;
  background: var(--bg); color: var(--accent); border: 1px solid var(--line);
  min-height: 34px;
}
.chip:active { background: var(--brand-soft); }

.draftbox { margin-top: 4px; }
.draftrow { display: flex; gap: 10px; padding: 8px 0; border-bottom: 1px dashed var(--line); }
.draftrow:last-child { border-bottom: 0; }
.draftrow__k { flex: none; width: 68px; font-size: .8rem; color: var(--muted); }
.draftrow__v { flex: 1; font-size: .86rem; word-break: break-word; }

.warnbox {
  margin-top: 10px; padding: 10px 12px; border-radius: 10px;
  background: #FDF3E0; color: #8A6100; font-size: .82rem; line-height: 1.6;
}
.warnbox--danger { background: #FEECEC; color: var(--danger); }

/* ===== M6 多视图看板 ===== */

/* 筛选条 */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.filters .input { min-height: 38px; padding: 7px 11px; font-size: 15px; }
.filters__kw { flex: 1 1 200px; min-width: 150px; }
.filters__sel { flex: 0 0 auto; min-width: 106px; }
.chip--toggle { background: #fff; color: var(--muted); }
.chip--toggle.active { background: var(--brand-soft); color: var(--brand-deep); border-color: #CFEFE2; font-weight: 600; }
.filters .linkbtn { align-self: center; }

/* 投影切换 */
.projs { display: flex; gap: 6px; margin-top: 12px; padding: 4px; background: var(--bg); border-radius: 11px; }
.projbtn { flex: 1; min-height: 36px; border-radius: 8px; font-size: .84rem; color: var(--muted); }
.projbtn:hover { color: var(--brand-deep); }
.projbtn.active { background: #fff; color: var(--brand-deep); font-weight: 600; box-shadow: 0 1px 3px rgba(0, 0, 0, .08); }

.bdwrap { margin-top: 12px; }

/* 看板投影 */
.kanban { display: flex; gap: 12px; align-items: flex-start; }
.kcol {
  flex: 1 1 0; min-width: 0; background: var(--card);
  border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); display: flex; flex-direction: column;
}
.kcol__head {
  display: flex; align-items: center; gap: 7px;
  padding: 11px 13px; font-size: .86rem; font-weight: 600;
  border-bottom: 1px solid var(--line);
}
.kcol__n { margin-left: auto; font-size: .74rem; font-weight: 500; color: var(--muted); background: var(--bg); border-radius: 999px; padding: 1px 8px; }
.kdot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.kdot--todo { background: var(--warn); }
.kdot--doing { background: var(--accent); }
.kdot--done { background: var(--ok); }
.kcol__body { flex: 1; min-height: 90px; padding: 10px; display: flex; flex-direction: column; gap: 9px; }
.kcol__body.over { background: var(--brand-soft); outline: 2px dashed var(--brand); outline-offset: -4px; border-radius: 0 0 var(--radius) var(--radius); }
.kcol__empty { font-size: .78rem; color: var(--muted); text-align: center; padding: 12px 0; }

.kcard {
  background: #fff; border: 1px solid var(--line); border-radius: 11px;
  padding: 10px 11px; cursor: pointer; position: relative;
  transition: box-shadow .15s, border-color .15s;
}
.kcard:hover { border-color: var(--brand); box-shadow: 0 2px 8px rgba(18, 184, 134, .15); }
.kcard.dragging { opacity: .5; }
.kcard--unread { border-left: 3px solid var(--brand); }
.kcard__t { font-size: .86rem; line-height: 1.5; word-break: break-word; padding-right: 26px; }
.kunread { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--danger); margin-right: 6px; vertical-align: middle; }
.kcard__m { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 7px; }
.ktag { font-size: .7rem; color: var(--muted); background: var(--bg); border-radius: 6px; padding: 2px 7px; }
.ktag--warn { background: #FFF6E5; color: #92600A; }
.ktag--danger { background: #FEECEC; color: var(--danger); }
.ktag--later { background: #EAF3FE; color: #1C6FB8; }
.kcard__adv {
  position: absolute; top: 8px; right: 8px; width: 24px; height: 24px;
  border-radius: 7px; background: var(--bg); color: var(--accent);
  font-size: 15px; line-height: 1; display: flex; align-items: center; justify-content: center;
}
.kcard__adv:hover { background: var(--brand-soft); color: var(--brand-deep); }
.kanban__more { width: 100%; font-size: .74rem; color: var(--accent); padding: 6px 0; text-align: center; }

/* 列表投影 */
.batchbar {
  display: flex; align-items: center; flex-wrap: wrap; gap: 8px;
  background: var(--brand-soft); border: 1px solid #CFEFE2; border-radius: 11px;
  padding: 9px 12px; margin-bottom: 10px;
}
.batchbar__count { font-size: .8rem; font-weight: 600; color: var(--brand-deep); margin-right: 4px; }
.bdlist { display: flex; flex-direction: column; gap: 6px; }
.bdlist:empty { display: none; }
.lrow {
  display: flex; align-items: center; gap: 10px;
  background: var(--card); border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 12px;
}
.lrow--unread { border-left: 3px solid var(--brand); }
.lchk { width: 19px; height: 19px; accent-color: var(--brand); flex: none; }
.lrow__t { flex: 1; min-width: 0; font-size: .87rem; word-break: break-word; }
.lrow__d { font-size: .76rem; color: var(--muted); flex: none; white-space: nowrap; }
.lrow__s { font-size: .74rem; color: var(--muted); flex: none; white-space: nowrap; }
.lrow .op { flex: none; font-size: .76rem; min-height: 30px; padding: 0 9px; border-radius: 7px; background: var(--bg); color: var(--accent); }

/* 日历投影 */
.calhead { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.calhead__m { font-size: .95rem; font-weight: 600; }
.calendar {
  display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 10px;
}
.cwd { text-align: center; font-size: .72rem; color: var(--muted); font-weight: 600; padding-bottom: 4px; }
.cday {
  min-height: 84px; border: 1px solid var(--line); border-radius: 9px;
  padding: 5px 6px; display: flex; flex-direction: column; gap: 3px; background: #fff; overflow: hidden;
}
.cday--blank { background: transparent; border-color: transparent; }
.cday--today { border-color: var(--brand); background: var(--brand-soft); }
.cday.over { outline: 2px dashed var(--brand); outline-offset: -2px; }
.cday__n { font-size: .74rem; color: var(--muted); font-weight: 600; }
.cday--today .cday__n { color: var(--brand-deep); }
.cev {
  font-size: .68rem; line-height: 1.35; background: var(--bg); border-radius: 5px;
  padding: 2px 5px; cursor: grab; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.cev--unread { background: #EAF7F1; color: var(--brand-deep); font-weight: 600; }
.cev--more { background: transparent; color: var(--muted); cursor: default; }
#bdCalUndated { margin-top: 10px; }

/* 表格投影 */
.bdtable { min-width: 660px; }
.bdtable td { vertical-align: middle; }
.bdtable .cellsel { font-size: .8rem; }
.cellsel, .cellinp {
  font-size: .8rem; border: 1px solid var(--line); border-radius: 7px;
  padding: 5px 7px; background: #fff; color: var(--ink); min-height: 32px;
}
.cellsel { appearance: none; -webkit-appearance: none; padding-right: 24px; }
.cellinp { width: 132px; }
.cellinp--tag { width: 104px; }

/* 记录详情抽屉 */
.sheet--side { align-items: stretch; justify-content: flex-end; }
.sheet__card--side {
  border-radius: 16px 0 0 16px; max-width: 480px; width: 100%;
  display: flex; flex-direction: column; overflow: hidden;
}
.drawer__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.drawer__body { flex: 1; overflow: auto; }
.fld { display: flex; flex-direction: column; gap: 6px; margin-top: 12px; }
.fld > span { font-size: .78rem; color: var(--muted); }
.fld--plain { flex-direction: row; align-items: center; gap: 8px; font-size: .84rem; }
.fld--plain > span:first-child { color: var(--muted); }
.changelog { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 12px; flex: none; }
.changelog__h { font-size: .82rem; font-weight: 600; margin-bottom: 8px; }
.changelog__list { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.changelog__list li { font-size: .78rem; color: #374151; background: var(--bg); border-radius: 8px; padding: 6px 10px; }
.changelog__t { color: var(--muted); margin-right: 8px; font-family: "SFMono-Regular", Consolas, monospace; }
.changelog__empty { font-size: .8rem; color: var(--muted); }

/* 导入来源 */
.implist { display: flex; flex-direction: column; gap: 10px; margin: 14px 0; }
.impitem { border: 1px solid var(--line); border-radius: 11px; padding: 12px 13px; }
.impitem__h { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.impitem__h b { font-size: .9rem; }
.impitem__n { font-size: .76rem; color: var(--muted); white-space: nowrap; }
.imp__sample { font-size: .78rem; color: var(--muted); margin: 7px 0 4px; word-break: break-word; }
.impitem .btn { margin-top: 10px; }
.impitem .btn[disabled] { opacity: .55; }

/* 手机端：看板与表格降级为横向滚动 */
@media (max-width: 759px) {
  .kanban { overflow-x: auto; padding-bottom: 4px; -webkit-overflow-scrolling: touch; }
  .kcol { flex: 0 0 78%; min-width: 236px; }
  .filters__kw { flex: 1 1 100%; }
  .filters__sel { flex: 1 1 40%; min-width: 96px; }
  .calendar { gap: 3px; padding: 7px; }
  .cday { min-height: 66px; padding: 4px; }
  .cev { font-size: .62rem; }
  .sheet--side { align-items: flex-end; }
  .sheet__card--side { max-width: 100%; border-radius: 18px 18px 0 0; }
  .cellinp { width: 118px; }
}

/* 安全与会话（M7） */
.secstate { display: flex; flex-direction: column; margin-top: 4px; }
.secstate__row {
  display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
  padding: 8px 0; border-bottom: 1px dashed var(--line);
}
.secstate__row:last-child { border-bottom: 0; }
.secstate__k { font-size: .84rem; color: var(--muted); flex: none; }
.secstate__v { font-size: .88rem; text-align: right; word-break: break-word; }
.secstate__url { font-size: .74rem; color: var(--muted); word-break: break-all; font-family: "SFMono-Regular", Consolas, monospace; }
.pwdform { display: flex; flex-direction: column; gap: 10px; margin: 12px 0 6px; }
.pwdform .row { margin-top: 2px; }
.seclist, .auditlist { margin-top: 8px; }
.seclist__ul, .auditlist__ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.secrow {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 12px;
  border: 1px solid var(--line); border-radius: 11px; padding: 11px 13px;
}
.secrow__main { min-width: 0; }
.secrow__name { font-size: .9rem; font-weight: 600; }
.secrow__meta { font-size: .75rem; color: var(--muted); margin-top: 3px; word-break: break-all; }
.secrow__ops { display: flex; align-items: center; gap: 8px; flex: none; }
.auditrow { border: 1px solid var(--line); border-radius: 11px; padding: 10px 12px; }
.auditrow__top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.auditrow__t {
  font-size: .74rem; color: var(--muted); white-space: nowrap;
  font-family: "SFMono-Regular", Consolas, monospace;
}
.auditrow__meta { font-size: .75rem; color: var(--muted); margin-top: 5px; word-break: break-all; }
.auditrow__detail { font-size: .78rem; color: #374151; margin-top: 4px; }
.hint--danger { color: var(--danger); }
#loginMsg:empty { display: none; }

/* 离线同步队列（M8） */
#offlineBanner { cursor: pointer; }
#syncList li { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.syncitem__t { flex: 1 1 auto; word-break: break-all; }

/* ---------- 定时任务中心（M9） ---------- */

.schstats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.schstat {
  flex: 1 1 88px;
  min-width: 88px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  font-size: .78rem;
  color: var(--muted);
  text-align: center;
}
.schstat b {
  display: block;
  font-size: 1.25rem;
  color: var(--text);
  line-height: 1.3;
}
.schstat--info b { color: var(--accent); }
.schstat--danger b { color: var(--danger); }

.schlist {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 10px;
}
.schrow {
  display: flex;
  align-items: stretch;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
}
.schrow--off { opacity: .62; }
.schrow__main {
  flex: 1;
  min-width: 0;
  padding: 11px 12px;
  cursor: pointer;
}
.schrow__main:active { background: var(--bg); }
.schrow__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.schrow__name {
  font-weight: 600;
  font-size: .95rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.schrow__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  margin-top: 6px;
  font-size: .8rem;
  color: var(--muted);
}
.schrow__time { color: var(--brand-deep); font-weight: 600; }
.schrow__next { color: var(--text); }
.schrow__sum {
  margin-top: 6px;
  font-size: .78rem;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.schrow__art {
  margin-top: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.schrow__acts {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  padding: 10px 10px 10px 0;
}

.schform {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 10px 0 4px;
}
.schfield {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1 1 96px;
  font-size: .76rem;
  color: var(--muted);
}
.schfield .input { min-height: 40px; }
.schpush { margin-top: 12px; }

.schdetail { margin-top: 14px; }
.schdetail h4 {
  font-size: .82rem;
  color: var(--muted);
  font-weight: 600;
  margin-bottom: 4px;
}
.schdetail p {
  font-size: .82rem;
  line-height: 1.5;
  color: var(--text);
  max-height: 200px;
  overflow: auto;
}
.schitem__t {
  display: inline;
  color: var(--text);
}

.pill--muted { background: var(--bg); color: var(--muted); border-color: transparent; }
