:root {
  --bg: #f5f6f8;
  --card: #ffffff;
  --border: #e2e5ea;
  --text: #1f2430;
  --muted: #6b7280;
  --accent: #2f6feb;
  --accent-hover: #2557c4;
  --danger: #c0392b;
  --ok: #1f9d55;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Microsoft YaHei", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
}

header {
  padding: 32px 20px 12px;
  text-align: center;
}
header h1 { margin: 0; font-size: 26px; }
.subtitle { color: var(--muted); margin: 6px 0 0; }

main {
  max-width: 860px;
  margin: 0 auto;
  padding: 12px 20px 60px;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 18px;
}
.card h2 { margin: 0 0 10px; font-size: 17px; }
.hint { color: var(--muted); font-size: 13px; margin: 0 0 12px; }
.hint code {
  background: #eef1f6;
  padding: 1px 5px;
  border-radius: 4px;
  font-size: 12px;
}

label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 14px;
}

input[type="text"], input[type="password"], input[type="number"],
select, textarea {
  width: 100%;
  margin-top: 5px;
  padding: 9px 11px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  background: #fff;
  color: var(--text);
}
textarea { resize: vertical; line-height: 1.45; }
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(47, 111, 235, 0.15);
}

.grid {
  display: grid;
  grid-template-columns: 1fr 1fr 120px;
  gap: 14px;
}
@media (max-width: 620px) {
  .grid { grid-template-columns: 1fr; }
}

/* 标准行 */
.criterion-row {
  display: grid;
  grid-template-columns: 180px 1fr 36px;
  gap: 10px;
  align-items: start;
  margin-bottom: 10px;
}
.criterion-row input { margin-top: 0; }
@media (max-width: 620px) {
  .criterion-row { grid-template-columns: 1fr 1fr 36px; }
}

button {
  cursor: pointer;
  font-family: inherit;
  border-radius: 8px;
  border: none;
  font-size: 14px;
}
.btn-secondary {
  background: #eef1f6;
  color: var(--text);
  padding: 8px 14px;
}
.btn-secondary:hover { background: #e2e7f0; }
.remove-btn {
  background: #f6e7e6;
  color: var(--danger);
  height: 38px;
  font-size: 18px;
  line-height: 1;
}
.remove-btn:hover { background: #f0d5d3; }

.actions { text-align: center; margin-top: 8px; }
#submit-btn, .btn-primary {
  background: var(--accent);
  color: #fff;
  padding: 11px 28px;
  font-size: 15px;
  font-weight: 600;
  display: inline-block;
  text-decoration: none;
}
#submit-btn:hover, .btn-primary:hover { background: var(--accent-hover); }
#submit-btn:disabled { background: #a9bde8; cursor: not-allowed; }

/* 进度条 */
.progress-bar {
  height: 14px;
  background: #eceff4;
  border-radius: 7px;
  overflow: hidden;
  margin-bottom: 10px;
}
#progress-fill {
  height: 100%;
  width: 0%;
  background: var(--accent);
  transition: width 0.3s ease;
}
#progress-text { font-size: 14px; margin: 0 0 10px; }

.error { color: var(--danger); font-size: 14px; }
.hidden { display: none; }
