* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  margin: 0; padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background: #f5f7fb; color: #1d2333;
  -webkit-text-size-adjust: 100%;
}

.wrap { max-width: 560px; margin: 0 auto; padding: 18px 16px 60px; }

.head { padding: 4px 4px 16px; }
.back { display: inline-block; color: #4f6ef7; text-decoration: none; font-size: 14px; margin-bottom: 8px; }
.back:hover { text-decoration: underline; }
.head h1 { margin: 0; font-size: 22px; }
.lead { color: #6b7280; margin: 8px 0 0; font-size: 14px; }

.card { background: #fff; border-radius: 12px; padding: 18px; margin-bottom: 14px; box-shadow: 0 1px 3px rgba(0,0,0,.04); }

.form { display: flex; flex-direction: column; gap: 12px; }

.field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; color: #1d2333; }
.field span { color: #374151; font-size: 13px; }
.field b { color: #ef4444; font-weight: normal; margin-left: 2px; }
.field input, .field textarea {
  width: 100%; padding: 10px 12px;
  border: 1px solid #d1d5db; border-radius: 8px;
  font-size: 15px; font-family: inherit; background: #fff; color: #1d2333;
  -webkit-appearance: none; appearance: none;
}
.field input:focus, .field textarea:focus { outline: none; border-color: #4f6ef7; box-shadow: 0 0 0 3px rgba(79,110,247,.15); }

.field-row { display: flex; gap: 10px; }
.field-row .field { flex: 1; }

.upload-block { background: #f8fafc; border: 1px dashed #cbd5e1; border-radius: 10px; padding: 12px; }
.upload-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; font-size: 14px; font-weight: 500; }
.upload-row { display: flex; align-items: center; gap: 10px; }

.btn { display: inline-block; padding: 10px 16px; border: 0; border-radius: 8px; font-size: 14px; font-family: inherit; cursor: pointer; background: #f1f5f9; color: #1d2333; transition: background .15s; }
.btn:hover { background: #e2e8f0; }
.btn.primary { background: #4f6ef7; color: #fff; }
.btn.primary:hover { background: #3b5be0; }
.btn.ghost { background: #eef1f7; }
.btn.block { width: 100%; }
.btn:disabled { opacity: .6; cursor: not-allowed; }

.upload-preview {
  width: 72px; height: 72px; border-radius: 8px;
  background: #fff; border: 1px solid #e2e8f0;
  display: flex; align-items: center; justify-content: center;
  color: #94a3b8; font-size: 12px; overflow: hidden;
  flex-shrink: 0;
}
.upload-preview img { width: 100%; height: 100%; object-fit: cover; }
.upload-preview.empty { color: #94a3b8; }

.form-tip { line-height: 1.5; }

.closed-icon, .ok-icon { font-size: 48px; text-align: center; margin: 0 0 12px; }
#closedHint p, #success p { text-align: center; }
#success h2 { text-align: center; margin: 0 0 12px; }

.muted { color: #6b7280; }
.small { font-size: 12px; }
.hidden { display: none !important; }

/* toast */
.toast {
  position: fixed; left: 50%; bottom: 80px;
  transform: translate(-50%, 20px);
  background: rgba(0,0,0,.78); color: #fff;
  padding: 10px 18px; border-radius: 22px;
  font-size: 14px; pointer-events: none;
  opacity: 0; transition: opacity .2s, transform .2s;
  z-index: 9999; max-width: 80vw; text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 480px) {
  .field-row { flex-direction: column; gap: 12px; }
}
/* ===== ICP 备案号页脚 ===== */
.site-footer {
  text-align: center;
  /* 为 iOS Safari 底部工具栏 + 安全区留出空间，避免备案号被遮挡 */
  padding: 18px 16px calc(64px + env(safe-area-inset-bottom));
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted, #8a91a3);
}
.site-footer a {
  color: inherit;
  text-decoration: none;
}
.site-footer a:hover {
  text-decoration: underline;
}
