/* PersonaTrust 移动端与组件补充样式（H5 适配） */

/* ---------- 移动端基础 ---------- */
@media (max-width: 760px) {
  .wrap { padding: 0 14px; }
  .topbar { height: 56px; gap: 8px; }
  .brand { font-size: 15px; }
  .brand small { display: none; }
  nav.links {
    gap: 14px; font-size: 13px; overflow-x: auto; white-space: nowrap;
    -webkit-overflow-scrolling: touch; scrollbar-width: none;
  }
  nav.links::-webkit-scrollbar { display: none; }
  .cartbtn { padding: 6px 12px; font-size: 13px; min-height: 36px; }

  .hero { padding: 22px 0 6px; }
  .hero h1 { font-size: 25px; }
  .hero p { font-size: 14px; }
  .pills { gap: 6px; }
  .pill { font-size: 12px; padding: 4px 10px; }

  .filters { gap: 8px; padding: 14px 0 6px; }
  .filters select, .filters input {
    flex: 1 1 46%; min-width: 0; font-size: 16px; /* 16px 防止 iOS 自动放大 */
    padding: 10px 12px; min-height: 44px;
  }
  .filters input { flex-basis: 100%; }
  .filters .spacer { display: none; }
  .count { width: 100%; text-align: right; }

  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px; padding-bottom: 28px;
  }
  .face { height: 118px; }
  .card-body { padding: 9px 10px 11px; gap: 4px; }
  .name { font-size: 14px; }
  .code { font-size: 10.5px; }
  .tag { font-size: 10.5px; padding: 1px 6px; }
  .price { font-size: 14px; }
  .status { font-size: 10.5px; padding: 2px 6px; }

  .drawer { width: 100%; border-radius: 16px 16px 0 0; top: auto; bottom: 0; height: 88dvh; transform: translateY(102%); }
  .drawer.on { transform: none; }
  .drawer-foot { padding-bottom: calc(14px + env(safe-area-inset-bottom)); }
  .drawer-foot .btn { min-height: 46px; font-size: 16px; }

  .modal { padding: 0; align-items: flex-end; }
  .modal-card { width: 100%; border-radius: 16px 16px 0 0; max-height: 92dvh; }
  .modal-foot { padding-bottom: calc(16px + env(safe-area-inset-bottom)); }
  .modal-foot .btn { flex: 1; min-height: 46px; font-size: 15px; }

  .field input, .field select, .field textarea { font-size: 16px; min-height: 44px; }
  .grid2 { grid-template-columns: 1fr; gap: 10px; }

  table.data { font-size: 12px; }
  table.data th, table.data td { padding: 7px 6px; }
  .panel { padding: 14px; }
  footer { font-size: 11.5px; padding: 18px 0 calc(18px + env(safe-area-inset-bottom)); }
  footer .wrap { flex-direction: column; gap: 6px; }
}

/* iOS 输入框：16px 以上才不会触发自动缩放 */
input, select, textarea { font-size: 16px; }
@media (min-width: 761px) {
  input, select, textarea { font-size: 14px; }
}

* { -webkit-tap-highlight-color: transparent; }

/* ---------- 分步表单（素人入驻） ---------- */
.steps { display: flex; align-items: center; gap: 6px; margin: 18px 0 20px; }
.step {
  flex: 1; display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--grey);
}
.step i {
  width: 22px; height: 22px; border-radius: 50%; border: 1px solid var(--line); background: #fff;
  display: grid; place-items: center; font-style: normal; font-size: 12px; color: var(--grey); flex: none;
}
.step.on { color: var(--blue); font-weight: 700; }
.step.on i { background: var(--blue); border-color: var(--blue); color: #fff; }
.step.done i { background: var(--green-soft); border-color: #bfe0c4; color: var(--green); }
.step-hr { flex: none; width: 14px; height: 1px; background: var(--line); }

.pane { display: none; }
.pane.on { display: block; }
.field-hint { font-size: 12px; color: var(--grey); margin-top: 4px; }
.req { color: var(--red); }

.choice-row { display: flex; flex-wrap: wrap; gap: 8px; }
.choice {
  border: 1px solid var(--line); border-radius: 999px; padding: 8px 14px; font-size: 14px;
  cursor: pointer; background: #fff; min-height: 40px; display: inline-flex; align-items: center;
}
.choice input { display: none; }
.choice.on { border-color: var(--blue); background: var(--blue-soft); color: var(--blue); font-weight: 600; }

.uploader {
  border: 1px dashed #c9d2de; border-radius: 12px; padding: 18px; text-align: center;
  color: var(--grey); font-size: 13.5px; background: #fcfdff; cursor: pointer;
}
.uploader:active { background: var(--blue-soft); }
.thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 10px; }
.thumb { position: relative; aspect-ratio: 3/4; border-radius: 10px; overflow: hidden; background: #eef1f5; }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb button {
  position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; border-radius: 50%;
  border: none; background: rgba(17,24,39,.6); color: #fff; font-size: 13px; line-height: 1; cursor: pointer;
}
.agree { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; line-height: 1.5; margin: 14px 0; }
.agree input { width: 20px; height: 20px; margin-top: 2px; flex: none; accent-color: var(--blue); }

.bottombar {
  position: sticky; bottom: 0; z-index: 15; background: rgba(255,255,255,.96);
  border-top: 1px solid var(--line); padding: 12px 0 calc(12px + env(safe-area-inset-bottom));
  backdrop-filter: blur(8px); margin-top: 20px;
}
.bottombar .wrap { display: flex; gap: 10px; }
.bottombar .btn { flex: 1; min-height: 46px; font-size: 16px; }

/* ---------- 防跳单：水印与遮罩 ---------- */
.wm { position: relative; overflow: hidden; }
.wm::after {
  content: attr(data-wm); position: absolute; inset: -30%;
  transform: rotate(-22deg); color: rgba(31,42,55,.09);
  font-size: 13px; line-height: 2.4; white-space: pre-wrap; word-break: break-all;
  text-align: center; pointer-events: none;
}
.locked { position: relative; }
.locked .lockbar {
  display: flex; align-items: center; gap: 8px; justify-content: center;
  background: #f3f5f8; color: var(--grey); font-size: 12.5px; padding: 10px;
  border-radius: 10px; margin-top: 10px;
}
.notice {
  background: var(--orange-soft); border: 1px solid #f0d9c4; color: #8a4512;
  border-radius: 10px; padding: 10px 12px; font-size: 12.5px; line-height: 1.5; margin: 12px 0;
}
.notice b { color: var(--orange); }

/* ---------- 规则页 ---------- */
.doc h2 { font-size: 17px; margin: 26px 0 8px; color: var(--ink); }
.doc h2 span { color: var(--blue); margin-right: 6px; }
.doc p, .doc li { font-size: 14px; color: var(--ink-2); line-height: 1.75; }
.doc ul, .doc ol { padding-left: 20px; }
.doc .kv { display: grid; grid-template-columns: 118px 1fr; gap: 8px 14px; font-size: 13.5px; margin: 12px 0; }
.doc .kv b { color: var(--ink); font-weight: 600; }
.doc .kv span { color: var(--ink-2); }
