:root {
  --primary: #4361ee; --primary-dark: #3a4fd0; --primary-soft: #eef1fe;
  --bg: #f3f5fa; --card: #ffffff; --line: #e6e9f0;
  --txt: #23293a; --muted: #8b93a7;
  --green: #16884a; --green-soft: #e5f5ec;
  --amber: #b7791f; --amber-soft: #fdf3e0;
  --red: #c0392b; --red-soft: #fdecea;
  --shadow: 0 1px 3px rgba(35,41,58,.06), 0 8px 24px rgba(35,41,58,.06);
}
* { box-sizing: border-box; }
body { margin:0; background:var(--bg); color:var(--txt);
  font:16px/1.7 -apple-system,"PingFang SC","Microsoft YaHei",sans-serif;
  -webkit-font-smoothing: antialiased; }
.wrap { max-width:680px; margin:0 auto; padding:28px 16px 80px; }
.wrap.wide { max-width:860px; }

/* 页头 */
.hero { display:flex; align-items:center; gap:14px; margin-bottom:6px; }
.hero .logo { width:46px; height:46px; border-radius:14px; flex:none;
  background:linear-gradient(135deg,var(--primary),#7048e8);
  display:flex; align-items:center; justify-content:center; font-size:24px;
  box-shadow:0 4px 14px rgba(67,97,238,.35); }
h1 { font-size:22px; margin:0; letter-spacing:.5px; }
.sub { color:var(--muted); font-size:13.5px; margin:2px 0 0; }
.nav { display:flex; gap:6px; margin:18px 0 20px; flex-wrap:wrap; }
.nav a { font-size:13.5px; color:var(--muted); text-decoration:none;
  padding:6px 14px; border-radius:20px; background:#fff; border:1px solid var(--line); }
.nav a.on { color:#fff; background:var(--primary); border-color:var(--primary); font-weight:600; }

/* 卡片 */
.card { background:var(--card); border:1px solid var(--line); border-radius:16px;
  padding:22px; margin-bottom:16px; box-shadow:var(--shadow); }
.card h3 { margin:0 0 6px; font-size:16px; }

/* 表单 */
label { display:block; font-size:13.5px; color:var(--muted); margin:16px 0 6px; font-weight:600; }
label:first-child { margin-top:0; }
input[type=text], input[type=password], textarea, select {
  width:100%; padding:11px 14px; border:1.5px solid var(--line); border-radius:10px;
  font-size:16px; background:#fff; color:var(--txt); outline:none;
  transition:border-color .15s, box-shadow .15s; }
input:focus, textarea:focus { border-color:var(--primary); box-shadow:0 0 0 3px var(--primary-soft); }
textarea { min-height:90px; resize:vertical; }
button, .btn { display:inline-flex; align-items:center; justify-content:center; gap:6px;
  background:var(--primary); color:#fff; border:none; border-radius:10px;
  padding:12px 26px; font-size:16px; font-weight:600; cursor:pointer;
  text-decoration:none; transition:background .15s, transform .05s; }
button:hover, .btn:hover { background:var(--primary-dark); }
button:active { transform:scale(.98); }
button:disabled { background:#b9c4e8; cursor:default; }
.btn-ghost { background:#fff; color:var(--primary); border:1.5px solid var(--primary); }
.btn-ghost:hover { background:var(--primary-soft); }
.btn-sm { padding:7px 16px; font-size:14px; border-radius:8px; }
.btn-danger { background:var(--red); }
.btn-danger:hover { background:#a93226; }

/* 状态与标签 */
.tag { display:inline-block; font-size:12px; padding:2.5px 10px; border-radius:20px;
  background:#eef1f6; color:var(--muted); white-space:nowrap; font-weight:600; }
.tag.pending { background:var(--red-soft); color:var(--red); }      /* 待拉取 */
.tag.synced  { background:var(--primary-soft); color:var(--primary); } /* 批改中 */
.tag.graded  { background:var(--amber-soft); color:var(--amber); }  /* 待反馈：还差一步 */
.tag.relayed { background:var(--green-soft); color:var(--green); }  /* 已反馈：闭环 */
.chip { display:inline-flex; align-items:center; gap:4px; font-size:12.5px;
  padding:3px 12px; border-radius:20px; background:var(--primary-soft);
  color:var(--primary); font-weight:600; }
.chip.pick { background:#fff; color:var(--muted); border:1.5px solid var(--line); cursor:pointer; }
.chip.pick.on { background:var(--primary); color:#fff; border-color:var(--primary); }
.chip .x { cursor:pointer; opacity:.55; font-weight:700; }
.chip .x:hover { opacity:1; }

/* 列表行 */
.row { display:flex; justify-content:space-between; align-items:center; gap:12px;
  padding:13px 4px; border-bottom:1px solid var(--line); }
.row:last-child { border-bottom:none; }
.row.rowlink { cursor:pointer; border-radius:10px; transition:background .12s; margin:0 -8px; padding-left:12px; padding-right:12px; }
.row.rowlink:hover { background:var(--primary-soft); }
.row .main { min-width:0; }
.row a { color:var(--txt); text-decoration:none; font-weight:600; }
.row a:hover { color:var(--primary); }
.avatar { width:38px; height:38px; border-radius:50%; flex:none;
  background:var(--primary-soft); color:var(--primary); font-weight:700;
  display:flex; align-items:center; justify-content:center; font-size:16px; }

/* 上传区 */
.dropzone { border:2px dashed #c9d2e8; border-radius:12px; padding:26px 16px;
  text-align:center; color:var(--muted); font-size:14.5px; cursor:pointer;
  background:#fafbfe; transition:all .15s; }
.dropzone.on { border-color:var(--primary); background:var(--primary-soft); color:var(--primary); }
.dropzone b { color:var(--primary); }
.thumbs { display:flex; flex-wrap:wrap; gap:10px; margin-top:12px; }
.thumb { position:relative; width:86px; }
.thumb .box { width:86px; height:86px; border-radius:10px; border:1px solid var(--line);
  overflow:hidden; background:#f2f4f9; display:flex; align-items:center;
  justify-content:center; font-size:30px; }
.thumb img { width:100%; height:100%; object-fit:cover; }
.thumb .name { font-size:11px; color:var(--muted); white-space:nowrap; overflow:hidden;
  text-overflow:ellipsis; margin-top:3px; text-align:center; }
.thumb .del { position:absolute; top:-7px; right:-7px; width:22px; height:22px;
  border-radius:50%; background:#3c4257; color:#fff; border:2px solid #fff;
  font-size:12px; line-height:18px; text-align:center; cursor:pointer; }

/* 杂项 */
a { color:var(--primary); }
.ok { color:var(--green); font-weight:600; } .err { color:var(--red); font-weight:600; }
.muted { color:var(--muted); font-size:13px; }
pre.fb { white-space:pre-wrap; font:15px/1.8 inherit; background:#fafbfd;
  border:1px solid var(--line); border-radius:12px; padding:16px; margin:10px 0 0; }
.merge-notice { margin:12px 0 10px; padding:12px 14px; border-radius:11px;
  border:1px solid #e6c77e; background:var(--amber-soft); color:#7a5418;
  font-size:14px; line-height:1.65; font-weight:600; }
.imgprev { max-width:100%; border:1px solid var(--line); border-radius:10px; margin:8px 0; }
.toolbar { display:flex; gap:10px; align-items:center; flex-wrap:wrap; margin-bottom:14px; }
.toolbar input[type=text] { flex:1; min-width:160px; }
.empty { text-align:center; color:var(--muted); padding:34px 0; font-size:14.5px; }
.divider { height:1px; background:var(--line); margin:16px 0; }
.toast { position:fixed; left:50%; bottom:34px; transform:translateX(-50%);
  background:#2b3040; color:#fff; padding:11px 22px; border-radius:12px;
  font-size:14.5px; box-shadow:0 8px 30px rgba(0,0,0,.25); opacity:0;
  pointer-events:none; transition:opacity .25s; z-index:99; }
.toast.show { opacity:1; }
@media (max-width:520px) { .card { padding:16px; } .wrap { padding-top:18px; } }
