/* 兼容性：不使用 CSS Grid / CSS 变量 / flex gap。
 * 使用 float / display:inline-block / table 布局 + 传统盒模型，兼容 IE9+、360 兼容模式、QQ/火狐/Chrome。
 * 不使用 :is/:where/:has 等新选择器。 */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: #f4f6fb;
  color: #1f2937;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
.wrap { max-width: 760px; margin: 0 auto; padding: 24px 16px 64px; }

.header {
  background: #ffffff;
  border-radius: 14px;
  padding: 26px 26px 22px;
  margin-bottom: 18px;
  border: 1px solid #e6e9f0;
  box-shadow: 0 2px 10px rgba(31,41,55,.05);
}
.brand { font-size: 13px; color: #6b7280; letter-spacing: .5px; margin-bottom: 8px; }
.title { font-size: 24px; font-weight: 700; color: #111827; margin: 0 0 10px; line-height: 1.35; }
.subtitle { font-size: 15px; color: #4b5563; margin: 0; }
.req-note { display: inline-block; margin-top: 14px; font-size: 13px; color: #b45309; background: #fffbeb; border: 1px solid #fde68a; padding: 3px 10px; border-radius: 999px; }

.card {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid #e6e9f0;
  box-shadow: 0 2px 10px rgba(31,41,55,.05);
  padding: 22px 26px;
  margin-bottom: 14px;
}
.card:after { content: ""; display: block; clear: both; }
.q-label { font-size: 16px; font-weight: 600; color: #111827; margin: 0 0 4px; }
.q-label .star { color: #e11d48; margin-left: 2px; }
.q-hint { font-size: 13px; color: #9ca3af; font-weight: normal; }
.q-error { color: #e11d48; font-size: 13px; margin: 8px 0 0; display: none; }
.q-error.show { display: block; }

/* 单选 / 多选用 label 包裹，整行可点，兼容旧浏览器 */
.opt {
  display: block;
  position: relative;
  padding: 10px 14px 10px 40px;
  margin: 8px 0 0;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  cursor: pointer;
  background: #fbfcfe;
  -webkit-tap-highlight-color: transparent;
  transition: border-color .15s, background-color .15s;
}
.opt:hover { border-color: #a5b4fc; background: #f5f7ff; }
.opt input { position: absolute; left: 14px; top: 50%; margin-top: -7px; width: 15px; height: 15px; margin-left: 0; }
.opt.checked { border-color: #4f46e5; background: #eef2ff; }
.opt span { display: inline; vertical-align: middle; }

.text-input, .textarea {
  width: 100%;
  margin-top: 10px;
  padding: 11px 13px;
  font-size: 15px;
  font-family: inherit;
  color: #111827;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #fbfcfe;
  outline: none;
  -webkit-appearance: none;
  border-radius: 10px;
}
.text-input:focus, .textarea:focus { border-color: #4f46e5; background: #fff; box-shadow: 0 0 0 3px rgba(79,70,229,.12); }
.textarea { min-height: 88px; resize: vertical; }

.invalid { border-color: #e11d48 !important; background: #fff5f7 !important; }

.actions { text-align: center; margin-top: 8px; }
.btn {
  display: inline-block;
  min-width: 200px;
  padding: 14px 28px;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
  background: #4f46e5;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  outline: none;
  -webkit-appearance: none;
  box-shadow: 0 4px 14px rgba(79,70,229,.3);
}
.btn:hover { background: #4338ca; }
.btn:active { background: #3730a3; }
.btn[disabled] { background: #a5b4fc; cursor: not-allowed; box-shadow: none; }

.form-error {
  display: none;
  margin: 16px 0 0;
  padding: 12px 16px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #b91c1c;
  border-radius: 10px;
  font-size: 14px;
}
.form-error.show { display: block; }

.success {
  display: none;
  text-align: center;
  padding: 56px 26px;
}
.success.show { display: block; }
.success .check {
  width: 72px; height: 72px; line-height: 72px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background: #ecfdf5;
  color: #059669;
  font-size: 38px;
  font-weight: 700;
}
.success h2 { font-size: 22px; color: #111827; margin: 0 0 10px; }
.success p { color: #4b5563; margin: 0 0 24px; }
.link-btn { color: #4f46e5; background: none; border: none; font-size: 15px; cursor: pointer; text-decoration: underline; padding: 0; }

.foot { text-align: center; color: #9ca3af; font-size: 12px; margin-top: 22px; }

/* 小屏适配（不使用媒体查询嵌套，简单 max-width） */
@media screen and (max-width: 480px) {
  .wrap { padding: 14px 10px 48px; }
  .header { padding: 20px 18px; }
  .card { padding: 18px 16px; }
  .title { font-size: 20px; }
  .btn { width: 100%; min-width: 0; }
}
