/* 错见网页端 — 复刻小程序品牌风格 */
:root {
  --blue: #1D4ED8;
  --bg: #FFF6EA;
  --card: #FFFAF2;
  --amber: #F59E0B;
  --text: #262626;
  --muted: #6B7280;
  --green: #16A34A;
  --red: #DC2626;
  --border: #F0E6D2;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, "PingFang SC", "Helvetica Neue", "Segoe UI", Roboto, sans-serif;
  font-size: 15px;
  line-height: 1.5;
}

/* 顶栏（复刻小程序蓝色导航条） */
.topbar {
  background: var(--blue);
  color: #fff;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  font-weight: 700;
  position: sticky;
  top: 0;
  z-index: 10;
}
.topbar .back { position: absolute; left: 16px; color: #fff; text-decoration: none; font-weight: 400; font-size: 15px; }

.container { max-width: 640px; margin: 0 auto; padding: 16px; }

/* 卡片 / 按钮 */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
  margin-bottom: 14px;
}
.btn-primary {
  display: block; width: 100%;
  background: var(--blue); color: #fff;
  border: none; border-radius: 10px;
  font-size: 16px; padding: 12px 0;
  text-align: center; cursor: pointer;
}
.btn-primary:disabled { background: #9CA3AF; color: #eee; cursor: not-allowed; }
.btn-ghost {
  display: block; width: 100%;
  background: transparent; color: var(--blue);
  border: 1.5px solid var(--blue); border-radius: 10px;
  font-size: 15px; padding: 11px 0;
  text-align: center; cursor: pointer;
}
.btn-row { display: flex; gap: 12px; }
.btn-row > * { flex: 1; }
.act { margin-top: 16px; }

/* 文本 / 布局 */
.muted { color: var(--muted); font-size: 13px; }
.row { display: flex; align-items: center; }
.between { justify-content: space-between; }
.center { text-align: center; }
.mt8 { margin-top: 8px; } .mt16 { margin-top: 16px; }

/* 徽标（状态色由 JS 用 theme.statusColor 注入 background） */
.badge {
  display: inline-block; font-size: 12px; font-weight: 600;
  color: #fff; padding: 2px 10px; border-radius: 999px;
}
.badge.amber { background: var(--amber); }
.badge.green { background: var(--green); }
.badge.red { background: var(--red); }
.badge.gray { background: #9CA3AF; }

/* 作业码 */
.code { font-family: "SF Mono", Menlo, Consolas, monospace; color: var(--blue);
        font-weight: 700; letter-spacing: 3px; }
.code-big { font-size: 40px; letter-spacing: 6px; text-align: center; margin: 12px 0; }

/* 表单 */
.field { margin-bottom: 14px; }
.label { font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.input, input[type=text], input[type=datetime-local] {
  width: 100%; padding: 10px 12px; font-size: 15px;
  border: 1px solid #E5DCC5; border-radius: 10px; background: #fff; color: var(--text);
}
.input.code-input { letter-spacing: 4px; text-transform: uppercase; }
.file-pick {
  border: 2px dashed #C9BEA5; border-radius: 12px; padding: 22px 12px;
  text-align: center; color: var(--muted); cursor: pointer; background: #fff;
}
.file-pick.picked { border-style: solid; border-color: var(--blue); color: var(--blue); }
.file-pick input[type=file] { display: none; }

/* 角色选择 */
.title-xl { font-size: 30px; font-weight: 800; text-align: center; margin: 28px 0 4px; }
.slogan { text-align: center; color: var(--muted); margin-bottom: 24px; }
.role-grid { display: flex; gap: 12px; }
.role-card { flex: 1; text-align: center; padding: 24px 12px; cursor: pointer; }
.role-card.selected { border-color: var(--blue); background: #EEF3FF; }
.emoji { font-size: 44px; }

/* 气泡 / 提示 */
.bubble { background: var(--card); border: 1px solid var(--border); border-radius: 14px;
          padding: 12px 14px; display: inline-block; max-width: 90%; margin-bottom: 14px; }
.hint { color: var(--muted); font-size: 13px; margin-top: 10px; }
.empty { color: var(--muted); text-align: center; padding: 32px 0; }
.err { color: var(--red); margin: 10px 0; }

/* AI 生成标注（合规） */
.ai-note { display: inline-block; font-size: 12px; color: #92400e;
           background: #fffbeb; border: 1px solid #fcd34d; border-radius: 8px; padding: 5px 12px; }

/* 批改状态卡 */
.stage-text { font-size: 17px; font-weight: 600; margin: 6px 0; }
.stage-text.done { color: var(--green); }
.stage-text.fail { color: var(--red); }
.dot { width: 10px; height: 10px; border-radius: 50%; }
.bar { height: 8px; background: #EEE7D6; border-radius: 6px; overflow: hidden; margin: 12px 0; }
.bar-fill { height: 100%; background: var(--amber); transition: width .4s; }
.score { font-size: 30px; font-weight: 800; color: var(--green); margin: 8px 0; }
.score .of { font-size: 16px; color: var(--muted); font-weight: 400; }

/* 列表项 */
.item { padding: 12px 0; border-bottom: 1px solid var(--border); }
.item:last-child { border-bottom: none; }
.sub-detail { margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--border); }
.loading { text-align: center; color: var(--muted); margin: 40px 0; }
