/* cdcee-bug-reports 单页样式（内部工具，紧凑清爽） */
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background: #f2f4f5;
  color: #1f2329;
  font-size: 14px;
}
button {
  font: inherit; cursor: pointer; border: 1px solid #d0d5da; background: #fff;
  border-radius: 6px; padding: 6px 14px; color: #1f2329;
}
button:hover { border-color: #9ca6b1; }
button.primary { background: #16703c; border-color: #16703c; color: #fff; }
button.primary:hover { background: #135c32; }
button.danger { color: #c0392b; border-color: #e5b3ac; }
button.danger:hover { background: #fdf0ee; }
button.ghost { border-color: transparent; background: transparent; color: #57606d; }
button:disabled { opacity: .5; cursor: not-allowed; }
input, select, textarea {
  font: inherit; border: 1px solid #d0d5da; border-radius: 6px; padding: 6px 10px; width: 100%;
  background: #fff; color: #1f2329;
}
textarea { resize: vertical; min-height: 64px; }
label { display: block; font-weight: 600; margin: 12px 0 4px; font-size: 13px; }
label .req { color: #c0392b; }
.hint { color: #7b8794; font-weight: 400; font-size: 12px; }

/* ---------- 布局 ---------- */
.topbar {
  display: flex; align-items: center; gap: 12px;
  background: #fff; border-bottom: 1px solid #e3e7ea;
  padding: 10px 20px; position: sticky; top: 0; z-index: 10;
}
.topbar .brand { font-weight: 700; font-size: 15px; }
.topbar .brand span { color: #16703c; }
.topbar .nav-active { border-color: #16703c; color: #16703c; font-weight: 600; background: #eef7f1; }
.topbar .spacer { flex: 1; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 16px 20px 60px; }
.card { background: #fff; border: 1px solid #e3e7ea; border-radius: 10px; padding: 16px 20px; margin-bottom: 14px; }
.card h3 { margin: 0 0 4px; font-size: 14px; }
.card .sub { color: #7b8794; font-size: 12px; margin-bottom: 10px; }

/* ---------- 登录 ---------- */
.login-box { max-width: 360px; margin: 12vh auto 0; }
.login-box h1 { font-size: 18px; text-align: center; margin: 0 0 4px; }
.login-box .sub { text-align: center; color: #7b8794; margin-bottom: 18px; font-size: 13px; }
.err { color: #c0392b; background: #fdf0ee; border: 1px solid #f0c9c2; border-radius: 6px; padding: 8px 12px; margin: 10px 0; font-size: 13px; }
.ok { color: #16703c; background: #eef7f1; border: 1px solid #bfe0cd; border-radius: 6px; padding: 8px 12px; margin: 10px 0; font-size: 13px; }

/* ---------- 状态页签 ---------- */
.tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.tabs button { border-radius: 999px; padding: 5px 14px; font-size: 13px; }
.tabs button.active { background: #16703c; border-color: #16703c; color: #fff; }
.tabs button .n { opacity: .75; margin-left: 4px; font-size: 12px; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.filters input, .filters select { width: auto; min-width: 130px; }

/* ---------- 列表 ---------- */
table { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid #e3e7ea; border-radius: 10px; overflow: hidden; }
th, td { text-align: left; padding: 9px 12px; border-bottom: 1px solid #eef1f3; font-size: 13px; }
th { background: #f7f9fa; color: #57606d; font-weight: 600; white-space: nowrap; }
tbody tr { cursor: pointer; }
tbody tr:hover { background: #f6f9f7; }
td .tid { color: #7b8794; font-size: 12px; white-space: nowrap; }
td .ttitle { font-weight: 600; }
.empty { text-align: center; color: #7b8794; padding: 30px 0; }

.badge { display: inline-block; border-radius: 999px; padding: 2px 10px; font-size: 12px; white-space: nowrap; }
.st-open     { background: #eef4ff; color: #2f6bd8; }
.st-fixing   { background: #fff6e8; color: #b06f0f; }
.st-fixed    { background: #f3f0ff; color: #6d4fd0; }
.st-pass     { background: #eef7f1; color: #16703c; }
.st-fail     { background: #fdf0ee; color: #c0392b; }
.st-rejected { background: #f1f3f5; color: #7b8794; }
.sev-p0 { background: #c0392b; color: #fff; }
.sev-p1 { background: #fde9e6; color: #c0392b; }
.sev-p2 { background: #fff6e8; color: #b06f0f; }
.sev-p3 { background: #f1f3f5; color: #7b8794; }

/* ---------- 详情 ---------- */
.detail-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.detail-head h2 { margin: 0; font-size: 16px; }
.kv { display: grid; grid-template-columns: 96px 1fr; gap: 6px 12px; font-size: 13px; margin-top: 10px; }
.kv .k { color: #7b8794; }
.kv .v { white-space: pre-wrap; word-break: break-word; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.ai-zone { border-left: 3px solid #6d4fd0; }
.retest-zone { border-left: 3px solid #16703c; }
.row2 { display: flex; gap: 12px; }
.row2 > * { flex: 1; }

/* 轮次时间线 */
.rounds { list-style: none; margin: 8px 0 0; padding: 0; }
.rounds li { position: relative; padding: 6px 0 6px 20px; border-left: 2px solid #e3e7ea; margin-left: 6px; font-size: 13px; }
.rounds li::before {
  content: ""; position: absolute; left: -5px; top: 12px; width: 8px; height: 8px;
  border-radius: 50%; background: #16703c;
}
.rounds .meta { color: #7b8794; font-size: 12px; }
.rounds .kind { font-weight: 600; }

/* 图片 */
.imgs { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.imgs .ph { position: relative; }
.imgs img { width: 120px; height: 90px; object-fit: cover; border-radius: 8px; border: 1px solid #e3e7ea; cursor: zoom-in; }
.imgs .rm {
  position: absolute; top: -6px; right: -6px; width: 20px; height: 20px; border-radius: 50%;
  background: #c0392b; color: #fff; border: none; line-height: 1; font-size: 12px; padding: 0;
}
.imgs img.big { position: fixed; inset: 0; width: auto; height: auto; max-width: 96vw; max-height: 96vh; margin: auto; z-index: 99; cursor: zoom-out; background: rgba(0,0,0,.8); padding: 12px; }

.form-foot { display: flex; gap: 8px; justify-content: flex-end; margin-top: 16px; }

@media (max-width: 640px) {
  .wrap { padding: 12px; }
  .kv { grid-template-columns: 84px 1fr; }
  .row2 { flex-direction: column; gap: 0; }
  th:nth-child(4), td:nth-child(4) { display: none; }
}
