:root {
  --bg: #ededed;
  --card: #fff;
  --text: #111;
  --sub: #7f7f7f;
  --line: #e5e5e5;
  --green: #07c160;
  --green-dark: #06ad56;
  --red: #fa5151;
  --orange: #fa9d3b;
  --badge: #111;
  --mask: rgba(0, 0, 0, 0.5);
  --radius: 10px;
  --safe-b: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font: 16px/1.5 -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", sans-serif;
  -webkit-text-size-adjust: 100%;
}
button, input, textarea, select { font: inherit; color: inherit; }
a { color: #576b95; text-decoration: none; }
img { display: block; max-width: 100%; }
.wx-thumb { position: absolute; left: -10000px; top: 0; width: 300px; height: 300px; overflow: hidden; }

#app { max-width: 640px; margin: 0 auto; min-height: 100vh; padding-bottom: calc(88px + var(--safe-b)); }

/* ---------- common ---------- */
.head { padding: 20px 16px 12px; }
.head h1 { font-size: 22px; margin: 0 0 6px; line-height: 1.3; word-break: break-word; }
.meta { color: var(--sub); font-size: 14px; }
.meta + .meta { margin-top: 2px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.tag { font-size: 12px; padding: 2px 8px; border-radius: 4px; background: #fff; color: #555; }
.banner { margin: 0 16px 12px; padding: 10px 12px; border-radius: 8px; background: #fff3e0; color: #a0570b; font-size: 14px; }
.section { background: var(--card); margin: 0 0 10px; }
.cell { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); background: var(--card); }
.cell:last-child { border-bottom: 0; }
.muted { color: var(--sub); }
.small { font-size: 13px; }
.center { text-align: center; }
.row { display: flex; gap: 10px; align-items: center; }
.grow { flex: 1; min-width: 0; }
.ellipsis { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hidden { display: none !important; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 0; border-radius: 8px; padding: 10px 16px; min-height: 44px;
  background: #f2f2f2; color: var(--text); font-weight: 600; cursor: pointer;
}
.btn:active { opacity: 0.75; }
.btn[disabled] { opacity: 0.4; pointer-events: none; }
.btn.primary { background: var(--green); color: #fff; }
.btn.danger { background: #fff; color: var(--red); }
.btn.warn { background: #fff0f0; color: var(--red); }
.btn.block { display: flex; width: 100%; }
.btn.small { min-height: 32px; padding: 4px 12px; font-size: 14px; border-radius: 6px; }
.btn.big { min-height: 52px; font-size: 17px; }
.link-btn { background: none; border: 0; color: #576b95; padding: 4px 0; cursor: pointer; }

.bottom-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  padding: 10px 16px calc(10px + var(--safe-b));
  background: rgba(247, 247, 247, 0.96); border-top: 1px solid var(--line);
  backdrop-filter: blur(10px);
}
.bottom-bar .inner { max-width: 608px; margin: 0 auto; display: flex; gap: 10px; }
.bottom-bar .btn { flex: 1; }

.chips { display: flex; gap: 8px; padding: 0 16px 10px; overflow-x: auto; }
.chip { flex: none; border: 0; border-radius: 16px; padding: 5px 14px; background: #fff; color: #333; font-size: 14px; cursor: pointer; }
.chip.on { background: var(--text); color: #fff; }

/* ---------- number badge / price / stamps ---------- */
.no {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 30px; height: 26px; padding: 0 7px; border-radius: 6px;
  background: var(--badge); color: #fff; font-weight: 800; font-size: 15px; line-height: 1;
  font-variant-numeric: tabular-nums;
}
.no.big { min-width: 44px; height: 36px; font-size: 20px; border-radius: 8px; }
.price { color: var(--red); font-weight: 700; }
.price.free { color: var(--green); }
.prices { display: inline-flex; align-items: baseline; gap: 6px; }
.orig { color: var(--sub); font-size: 12px; font-weight: 400; }
.item-info .orig { font-size: 15px; }
.stamp {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%) rotate(-14deg);
  border: 3px solid currentColor; border-radius: 8px; padding: 2px 10px;
  font-weight: 800; font-size: 20px; letter-spacing: 2px; background: rgba(255, 255, 255, 0.85); white-space: nowrap;
}
.stamp.reserved { color: var(--orange); }
.stamp.sold { color: #888; }

/* ---------- buyer grid ---------- */
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 0 8px; }
.tile { background: var(--card); border-radius: var(--radius); overflow: hidden; color: inherit; display: flex; flex-direction: column; }
.tile .ph { position: relative; aspect-ratio: 1 / 1; background: #f0f0f0; overflow: hidden; }
.tile .track { display: flex; width: 100%; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.tile .track::-webkit-scrollbar { display: none; }
.tile .track a { flex: none; width: 100%; height: 100%; scroll-snap-align: start; }
.tile .track img { width: 100%; height: 100%; object-fit: cover; }
.tile .ph .no { position: absolute; left: 6px; top: 6px; box-shadow: 0 1px 3px rgba(0,0,0,.3); pointer-events: none; }
.tile .ph .stamp { pointer-events: none; font-size: 17px; }
.tile .ph .badge { position: absolute; left: 6px; top: 6px; background: var(--red); color: #fff; font-size: 12px; font-weight: 700; padding: 1px 7px; border-radius: 9px; box-shadow: 0 1px 3px rgba(0,0,0,.3); pointer-events: none; }
.new-count { color: var(--red); font-weight: 600; }
.tile .dots { position: absolute; left: 0; right: 0; bottom: 6px; display: flex; justify-content: center; gap: 4px; pointer-events: none; }
.tile .dots i { width: 6px; height: 6px; border-radius: 3px; background: rgba(255,255,255,.55); box-shadow: 0 0 2px rgba(0,0,0,.4); }
.tile .dots i.on { background: #fff; width: 14px; }
.tile.sold .track img { filter: grayscale(1); opacity: 0.55; }
.tile .info { padding: 8px 10px 10px; display: flex; flex-direction: column; flex: 1; }
.tile .sub { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; }
.tile .sub .price { font-size: 18px; }
.tile .sub .muted { font-size: 12px; }
.tile .name { color: var(--text); font-size: 15px; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; word-break: break-all; margin-top: 2px; }
.tile .extra { color: var(--sub); font-size: 12px; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile .info .btn { margin-top: auto; width: 100%; min-height: 36px; font-size: 14px; padding: 4px 6px; }
.tile .info > :nth-last-child(2) { margin-bottom: 8px; }
.tile .info .btn.ghost { background: #effaf3; color: var(--green-dark); }
.tile .info .btn.mine-btn { background: #fff7e6; color: #a0570b; }
.fold { display: block; margin: 14px auto; }
.empty { padding: 48px 24px; text-align: center; color: var(--sub); }

/* ---------- buyer item ---------- */
.gallery { position: relative; background: #000; }
.gallery .track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.gallery .track::-webkit-scrollbar { display: none; }
.gallery .track img { flex: none; width: 100%; aspect-ratio: 1 / 1; object-fit: contain; scroll-snap-align: start; background: #000; }
.gallery .count { position: absolute; right: 10px; bottom: 10px; background: rgba(0,0,0,.5); color: #fff; font-size: 12px; padding: 2px 8px; border-radius: 10px; }
.gallery .stamp { font-size: 28px; }
.item-info { background: var(--card); padding: 14px 16px; }
.item-info h1 { font-size: 20px; margin: 10px 0 4px; word-break: break-word; }
.item-info .price { font-size: 24px; }
.back { display: block; padding: 12px 16px; font-size: 15px; }
.contact { margin: 10px 16px; background: var(--card); border-radius: var(--radius); padding: 14px 16px; border: 2px solid var(--green); }
.contact .k { color: var(--sub); font-size: 13px; }
.contact .v { font-size: 18px; font-weight: 700; overflow-wrap: anywhere; }
.contact .row + .row { margin-top: 10px; }

/* ---------- seller ---------- */
.stats { display: flex; background: var(--card); margin: 0 0 10px; }
.stats > * { flex: 1; text-align: center; padding: 12px 0; }
/* The counts double as the list filter: tap one to see only those, tap it again for everything still open. */
.stats .stat { position: relative; border: 0; background: none; color: inherit; font: inherit; cursor: pointer; }
.stats .stat:not(.on) b { color: var(--sub); }
.stats .stat.on::after { content: ''; position: absolute; left: 22%; right: 22%; bottom: 0; height: 3px; border-radius: 2px; background: var(--text); }
.stats b { display: block; font-size: 22px; }
.stats span { color: var(--sub); font-size: 13px; }
.row-item { display: flex; gap: 12px; padding: 10px 16px; background: var(--card); border-bottom: 1px solid var(--line); align-items: center; cursor: pointer; }
.row-item img, .row-item .noimg { width: 56px; height: 56px; border-radius: 6px; object-fit: cover; background: #eee; flex: none; }
.row-item .st { font-size: 13px; }
.st.available { color: var(--green); }
.st.reserved { color: var(--orange); }
.st.sold { color: #999; }
.promo { display: flex; align-items: center; gap: 8px; padding: 8px 12px 8px 4px; background: #f5f5f5; border-bottom: 1px solid var(--line); }
.promo-x { flex: none; width: 32px; height: 32px; border: 0; background: none; color: #484848; font-size: 16px; cursor: pointer; }
.promo-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.35; }
.promo-txt b { font-size: 14px; }
.promo-txt span { font-size: 12px; color: var(--sub); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.promo-fav { flex: none; border: 1px solid #111; color: #111; font-size: 14px; font-weight: 700; padding: 7px 12px; border-radius: 999px; }
.promo-cta { flex: none; background: #111; color: #fff; font-size: 14px; font-weight: 700; padding: 8px 16px; border-radius: 999px; }
.appbar { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px 0; }
.logo { display: inline-flex; align-items: center; gap: 8px; color: var(--text); }
.logo img { width: 34px; height: 34px; flex: none; }
.logo-txt { display: flex; flex-direction: column; line-height: 1.15; }
.logo-txt b { font-size: 17px; font-weight: 900; letter-spacing: .02em; }
.logo-txt small { font-size: 11px; color: var(--sub); letter-spacing: .06em; }
.appbar-my { color: var(--text); font-size: 14px; font-weight: 700; white-space: nowrap; }
.how-line { margin: 0 16px 12px; padding: 8px 12px; background: #f5f5f5; border-radius: 8px; font-size: 13px; color: #484848; line-height: 1.5; }
/* The first three buttons sit together on the left and 推荐朋友 keeps the right end, so a wide screen does not scatter them. */
.topbar { display: flex; align-items: center; gap: 8px; padding: 12px 16px 0; }
.topbar .rec-btn { margin-left: auto; }
.topbar .btn { white-space: nowrap; padding: 8px; font-size: 14px; flex: none; gap: 4px; }
/* On a narrow screen or with large system text the two text buttons give way (ending in …) so the bar never pushes the page sideways. */
.topbar .btn.fit { flex: 0 1 auto; min-width: 0; }
.topbar .btn.fit span { overflow: hidden; text-overflow: ellipsis; }

/* ---------- composer ---------- */
.composer { position: fixed; inset: 0; z-index: 40; background: var(--bg); overflow-y: auto; padding-bottom: calc(150px + var(--safe-b)); }
.composer .inner { max-width: 640px; margin: 0 auto; }
.composer .bar { position: sticky; top: 0; z-index: 2; display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; background: rgba(237,237,237,.96); }
.ccard { margin: 10px 12px; background: var(--card); border-radius: var(--radius); padding: 10px; border: 2px solid transparent; }
.ccard.bad { border-color: var(--red); }
.ccard.done { opacity: 0.5; }
.ccard .top { display: flex; gap: 10px; }
.ccard .thumbs { display: flex; gap: 6px; flex: none; }
.ccard .thumbs .t { position: relative; }
.ccard .thumbs img { width: 84px; height: 84px; object-fit: cover; border-radius: 6px; background: #eee; }
.ccard .thumbs .x { position: absolute; right: -6px; top: -6px; width: 22px; height: 22px; border-radius: 11px; border: 0; background: rgba(0,0,0,.6); color: #fff; font-size: 13px; line-height: 22px; padding: 0; cursor: pointer; }
.ccard .addph { width: 56px; height: 84px; border: 1px dashed #bbb; border-radius: 6px; background: #fafafa; color: #999; font-size: 24px; cursor: pointer; }
.ccard input.line { width: 100%; border: 0; border-bottom: 1px solid var(--line); padding: 8px 2px; font-size: 17px; outline: none; background: transparent; }
.ccard .parsed { font-size: 13px; margin-top: 6px; color: var(--sub); }
.ccard .parsed.err, .ccard .err { color: var(--red); }
.ccard .more { margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--line); }
.composer .footer { position: fixed; left: 0; right: 0; bottom: 0; z-index: 41; padding: 10px 16px calc(10px + var(--safe-b)); background: rgba(247,247,247,.97); border-top: 1px solid var(--line); }
.composer .footer .inner { display: flex; gap: 10px; }
.composer .footer .btn { flex: 1; }

/* ---------- form ---------- */
.form { background: var(--card); margin-bottom: 10px; }
.field { display: block; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.field:last-child { border-bottom: 0; }
.field > span { display: block; font-size: 13px; color: var(--sub); margin-bottom: 4px; }
.field input[type=text], .field input[type=date], .field input[type=number], .field select, .field textarea, .inp {
  width: 100%; border: 0; outline: none; font-size: 17px; padding: 4px 0; background: transparent;
}
.inp.boxed { border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; background: #fff; }
.field .req { color: var(--red); }
/* IKEA-style form: bold labels, bordered inputs, black pills, an accordion for the optional part. */
.ik-head { padding: 16px 16px 4px; background: #fff; }
.ik-head h1 { font-size: 26px; font-weight: 800; margin: 14px 0 4px; }
.ik-sub { font-size: 14px; color: #484848; }
.form.ik { padding: 8px 16px 12px; }
.form.ik .field { padding: 12px 0; border: 0; }
.form.ik .field > span { font-size: 14px; color: #111; font-weight: 700; margin-bottom: 6px; }
.form.ik .req { color: #111; }
.form.ik input[type=text], .form.ik input[type=date], .form.ik select { height: 48px; padding: 0 12px; border: 1px solid #929292; border-radius: 4px; background: #fff; font-size: 16px; }
.form.ik input[type=text]:focus, .form.ik input[type=date]:focus, .form.ik select:focus { border-color: #0058a3; box-shadow: inset 0 0 0 1px #0058a3; }
.form.ik .help { display: block; font-size: 12px; color: #484848; margin-top: 6px; font-weight: 400; }
.form.ik .seg { gap: 8px; }
.form.ik .seg button { border: 0; background: #f5f5f5; color: #111; border-radius: 999px; padding: 8px 14px; font-weight: 700; }
.form.ik .seg button.on { background: #111; color: #fff; }
.form.ik .rule-row { padding: 4px 0; }
.form.ik .rule-row input[type=checkbox], .form.ik .nearby-row input[type=checkbox] { accent-color: #111; }
.form.ik .rule-row .inp { height: 40px; }
.ik-more { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin: 12px 0 4px; }
.ik-more summary { list-style: none; display: flex; justify-content: space-between; align-items: center; padding: 14px 0; cursor: pointer; }
.ik-more summary::-webkit-details-marker { display: none; }
.ik-more summary::after { content: ""; width: 9px; height: 9px; border-right: 2px solid #111; border-bottom: 2px solid #111; transform: rotate(45deg); margin: 0 6px 4px 0; transition: transform .2s; }
.ik-more[open] summary::after { transform: rotate(-135deg); margin-bottom: -4px; }
.ik-more summary .help { margin-top: 2px; }
.form.ik .nearby-row { padding-top: 16px; }
.form.ik .nearby-row .small { font-weight: 400; }
.rule-row { display: flex; align-items: center; gap: 10px; padding: 4px 0; }
.rule-row input[type=checkbox] { width: 20px; height: 20px; accent-color: var(--green); flex: none; }
.seg { display: flex; flex-wrap: wrap; gap: 6px; }
.seg button { border: 1px solid var(--line); background: #fff; border-radius: 16px; padding: 4px 12px; font-size: 14px; cursor: pointer; }
.seg button.on { border-color: var(--green); color: var(--green); background: #effaf3; }
.hint { padding: 8px 16px; color: var(--sub); font-size: 13px; }
.list-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 8px; padding: 0 16px 8px 0; }
.list-bar .hint { padding-top: 0; padding-bottom: 0; flex: 1 1 auto; min-width: 0; }
/* The sort buttons stay on one line; when there's no room beside the counts they move below, on the right. */
.list-bar .seg { flex-wrap: nowrap; flex: none; margin-left: auto; }
.list-bar .seg button { white-space: nowrap; }
.list-bar.end { justify-content: flex-end; }
.seg.small button { padding: 2px 10px; font-size: 13px; }

/* ---------- sheets ---------- */
.mask { position: fixed; inset: 0; z-index: 60; background: var(--mask); display: flex; align-items: flex-end; justify-content: center; animation: fade .15s; }
.sheet { width: 100%; max-width: 640px; max-height: 88vh; overflow-y: auto; background: #f7f7f7; border-radius: 14px 14px 0 0; padding: 16px 16px calc(16px + var(--safe-b)); animation: up .2s ease-out; }
.sheet h2 { font-size: 18px; margin: 0 0 12px; text-align: center; }
.sheet .group { background: #fff; border-radius: var(--radius); overflow: hidden; margin-bottom: 12px; }
.sheet .group .cell { padding: 12px; }
.sheet .actions { display: flex; flex-direction: column; gap: 8px; }
.check-row { background: #fff; border-radius: var(--radius); padding: 10px; margin-bottom: 8px; }
.check-row img { width: 48px; height: 48px; border-radius: 6px; object-fit: cover; flex: none; }
.check-row .btns { display: flex; gap: 6px; margin-top: 8px; }
.check-row .btns .btn { flex: 1; min-height: 38px; padding: 4px 6px; font-size: 14px; }
.check-row.answered { opacity: 0.45; pointer-events: none; }
.qrow { display: flex; gap: 10px; align-items: flex-start; padding: 12px; border-bottom: 1px solid var(--line); background: #fff; }
.qrow:last-child { border-bottom: 0; }
.qrow .pos { width: 26px; height: 26px; border-radius: 13px; background: #eee; text-align: center; line-height: 26px; font-weight: 700; flex: none; font-size: 14px; }
.qrow.head .pos { background: var(--green); color: #fff; }
.qrow .acts { display: flex; gap: 6px; margin-top: 8px; }
.qrow .acts .btn { flex: 1; }
.photo-strip { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; }
.photo-strip .t { position: relative; flex: none; }
.photo-strip img { width: 96px; height: 96px; border-radius: 6px; object-fit: cover; cursor: pointer; }
.photo-strip .x { position: absolute; right: 4px; top: 4px; width: 22px; height: 22px; border-radius: 11px; border: 0; background: rgba(0,0,0,.6); color: #fff; font-size: 13px; padding: 0; cursor: pointer; }
.photo-strip .addph { width: 96px; height: 96px; border: 1px dashed #bbb; border-radius: 6px; background: #fafafa; color: #999; font-size: 28px; cursor: pointer; flex: none; }

/* ---------- overlays ---------- */
.imgview { position: fixed; inset: 0; z-index: 90; background: #111; overflow-y: auto; padding: 16px 12px calc(80px + var(--safe-b)); color: #fff; }
.imgview img { width: 100%; max-width: 540px; margin: 0 auto 16px; border-radius: 4px; }
.imgview .tip { text-align: center; margin: 4px 0 14px; font-size: 15px; }
.toast { position: fixed; left: 50%; top: 40%; transform: translate(-50%, -50%); z-index: 100; background: rgba(17,17,17,.88); color: #fff; padding: 12px 18px; border-radius: 10px; font-size: 15px; max-width: 80vw; text-align: center; animation: fade .15s; pointer-events: none; }
.loading { position: fixed; inset: 0; z-index: 99; display: flex; align-items: center; justify-content: center; background: rgba(255,255,255,.4); }
.loading div { background: rgba(17,17,17,.85); color: #fff; padding: 14px 20px; border-radius: 10px; }

@keyframes up { from { transform: translateY(40px); opacity: .4; } to { transform: none; opacity: 1; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.ph-price { display: none; }
.tile .info .btn b { font-weight: inherit; }
.login-card { margin: 0 16px 12px; padding: 12px 14px; background: var(--card); border-radius: var(--radius); display: flex; flex-direction: column; gap: 10px; }
.sheet .login-card { margin: 0; }
.login-card .gbtn { min-height: 44px; }
.row-item .row-no { flex: none; }
.wx-arrow { position: fixed; right: 14px; top: 4px; z-index: 70; color: #fff; text-align: right; pointer-events: none; text-shadow: 0 1px 4px rgba(0,0,0,.6); }
.wx-arrow span { display: block; font-size: 46px; line-height: 1; }
.wx-arrow b { font-size: 16px; }
.fab { position: fixed; right: 16px; bottom: calc(20px + var(--safe-b)); z-index: 30; border: 0; border-radius: 999px; padding: 12px 20px; background: var(--green); color: #fff; font-weight: 700; font-size: 16px; box-shadow: 0 6px 16px rgba(0,0,0,.25); cursor: pointer; }
.share-text { font-size: 15px; line-height: 1.6; resize: vertical; min-height: 220px; }
.share-step { display: flex; flex-direction: column; gap: 6px; }
.share-step .step-why { margin: 0 4px 6px; }
.share-nudge { margin: 12px 0 16px; padding: 12px; border-radius: var(--radius); background: var(--card); border: 1px solid var(--line); }
.share-nudge-row { display: flex; gap: 8px; align-items: center; margin-top: 8px; }
.share-nudge-row .inp { min-width: 0; }
.share-or { display: flex; align-items: center; gap: 10px; margin: 14px 0 10px; color: var(--sub); font-size: 13px; }
.share-or::before, .share-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.intro-steps { background: var(--card); margin: 0 0 10px; }
.intro-step { display: flex; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.intro-step:last-child { border-bottom: 0; }
.intro-step b { font-size: 17px; }
.step-badge { flex: none; width: 28px; height: 28px; border-radius: 14px; background: var(--green); color: #fff; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.highlight { margin: 0 16px 10px; padding: 14px 16px; background: #fff8cc; border-left: 4px solid #ffdb00; border-radius: 4px; font-size: 14px; line-height: 1.7; }
.highlight b { display: block; font-size: 16px; margin-bottom: 4px; }
.contact-title { font-weight: 800; font-size: 16px; color: var(--green); margin-bottom: 10px; }
.contact-steps { margin: 12px 0 0; padding-left: 20px; font-size: 13px; color: var(--sub); line-height: 1.8; }
.how-to { margin: 0 16px 10px; padding: 10px 12px; background: #f5f5f5; border-radius: 8px; font-size: 13px; line-height: 1.7; color: #333; }
.ai-btn { border: 0; border-radius: 999px; padding: 3px 10px; background: #ffdb00; color: #111; font-size: 13px; font-weight: 700; cursor: pointer; }
.ai-btn[disabled] { opacity: .6; }
.quota-out { font-size: 26px; font-weight: 800; text-align: center; margin: 4px 0 10px; line-height: 1.3; }
.survey-q { margin: 14px 0 0; }
.qr-card { text-align: center; margin: 0 0 12px; }
.share-help { margin-top: 20px; }
.qr-card img { display: block; width: 220px; height: 220px; margin: 0 auto 6px; background: #fff; border-radius: 8px; }
.survey-title { font-weight: 700; margin-bottom: 8px; }
.btn.danger-solid { background: var(--red); color: #fff; }
[data-ui~=nordic] .btn.danger-solid { background: #cc0008; color: #fff; }
.nearby-entry { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 16px 0 8px; padding: 14px 16px; border-radius: var(--radius); background: #fff8cc; border-left: 4px solid #ffdb00; color: var(--text); }
.nearby-entry b { font-size: 16px; }
.nearby-entry > span { font-size: 22px; color: var(--sub); }
.tile .track > span { flex: none; width: 100%; height: 100%; }
.nearby-row { display: flex; gap: 10px; align-items: flex-start; }
.nearby-row input[type=checkbox] { width: 20px; height: 20px; margin-top: 3px; accent-color: var(--green); flex: none; }
.share-opts { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 10px 2px 0; }
.intro { padding: 28px 20px 8px; text-align: center; }
.intro-title { font-size: 30px; line-height: 1.25; margin: 0 0 10px; font-weight: 900; }
.intro-sub { color: var(--sub); font-size: 15px; margin-bottom: 22px; }
.intro-mock { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; padding: 12px; background: #f5f5f5; border-radius: 14px; margin: 0 auto 26px; max-width: 420px; }
.mock-tile { background: #fff; border-radius: 6px; padding: 6px; display: flex; flex-direction: column; gap: 5px; align-items: flex-start; }
.mock-ph { position: relative; width: 100%; aspect-ratio: 1; display: flex; align-items: center; justify-content: center; font-size: 30px; background: #f5f5f5; border-radius: 4px; }
.mock-stamp { position: absolute; transform: rotate(-12deg); font-size: 10px; font-weight: 800; background: #ffdb00; border: 1.5px solid #111; padding: 0 3px; }
.mock-price { background: #ffdb00; font-weight: 900; font-size: 12px; padding: 0 4px; }
.mock-btn { width: 100%; text-align: center; font-size: 11px; font-weight: 700; color: #fff; background: #0058a3; border-radius: 999px; padding: 2px 0; }
.mock-btn.off { background: #fff; color: #0058a3; border: 1px solid #0058a3; }
.intro-steps2 { display: flex; flex-direction: column; gap: 16px; text-align: left; max-width: 360px; margin: 0 auto; }
.intro-step2 { display: flex; gap: 14px; align-items: center; }
.intro-step2 b { font-size: 17px; }
.intro-icon { flex: none; width: 46px; height: 46px; border-radius: 23px; background: #fff8cc; display: flex; align-items: center; justify-content: center; font-size: 22px; }
.intro-free { margin-top: 26px; color: var(--sub); font-size: 13px; }
/* landing page (/ and /en), rendered by the server */
.lp-cta { display: inline-flex; min-width: 240px; padding: 0 28px; margin-top: 2px; }
.lp-sec { padding: 32px 20px 4px; }
.lp-sec h2 { font-size: 22px; font-weight: 900; margin: 0 0 16px; text-align: center; }
.lp-why { display: grid; gap: 10px; max-width: 440px; margin: 0 auto; }
.lp-why div { background: #f5f5f5; padding: 14px 16px; }
.lp-why dt { font-weight: 800; }
.lp-why dd { margin: 2px 0 0; color: var(--sub); font-size: 14px; }
.lp-who { max-width: 440px; margin: 0 auto; padding-left: 22px; }
.lp-who li + li { margin-top: 8px; }
.lp-faq { max-width: 440px; margin: 0 auto; }
.lp-faq details { border-bottom: 1px solid var(--line); padding: 12px 0; }
.lp-faq summary { font-weight: 700; cursor: pointer; }
.lp-faq p { margin: 8px 0 0; color: var(--sub); font-size: 14px; }
.lp-foot { padding: 32px 20px 8px; text-align: center; color: var(--sub); font-size: 13px; }
.lp-foot p { margin: 0 0 6px; }
.save-entry { margin: 24px 16px 8px; padding: 20px; background: #f5f5f5; }
.save-t { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 17px; }
.save-s { font-size: 14px; color: #484848; margin-top: 6px; line-height: 1.6; }
.save-btns { display: flex; gap: 10px; margin-top: 16px; }
.ic { width: 20px; height: 20px; flex: none; }
.pill { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1px solid #111; background: #fff; color: #111; font-size: 14px; font-weight: 700; cursor: pointer; }
.pill.dark { background: #111; color: #fff; }
.pill .ic { width: 18px; height: 18px; }
.menu-guide { position: fixed; inset: 0; z-index: 100; background: rgba(0, 0, 0, .9); color: #fff; display: flex; flex-direction: column; align-items: center; }
.mg-arrow { position: absolute; top: 6px; right: 18px; width: 110px; height: 110px; }
.mg-steps { margin-top: 130px; display: flex; flex-direction: column; gap: 14px; font-size: 18px; }
.mg-step { display: flex; align-items: center; gap: 12px; }
.mg-no { width: 28px; height: 28px; border-radius: 50%; background: #ffdb00; color: #111; font-weight: 900; font-size: 15px; display: flex; align-items: center; justify-content: center; }
.mg-dots { letter-spacing: 2px; background: rgba(255, 255, 255, .18); padding: 0 8px; border-radius: 6px; }
.mg-tip { font-size: 13px; opacity: .8; padding-left: 40px; }
.mg-ok { flex: none; margin-top: 36px; width: 160px; background: transparent; color: #fff; border-color: #fff; }
.nearby-feed { margin-top: 18px; padding-top: 14px; border-top: 8px solid #f5f5f5; }
.feed-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 0 12px 10px; }
.feed-head b { font-size: 18px; }
.feed-head { flex-direction: column; align-items: flex-start; }
.feed-tabs { padding: 0; }
.crow { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.crow .thumbs { flex-wrap: wrap; }
.crow .addph { width: 84px; height: 84px; }
.crow .cside { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; flex: none; }
.cfields { display: flex; gap: 8px; margin-top: 10px; }
.cfields .inp.boxed { flex: 1; min-width: 0; font-size: 16px; }
.ccard .cnote { display: block; width: 100%; margin-top: 8px; font-size: 16px; resize: none; line-height: 1.4; font-family: inherit; }
.corig { display: flex; justify-content: flex-end; align-items: center; gap: 8px; margin-top: 8px; }
.cretail { font-size: 12px; color: var(--sub); text-align: right; }
.cretail:empty { display: none; }
.corig .price-in { width: 128px; }
.corig .price-in span { font-weight: 400; font-size: 13px; white-space: nowrap; }
.price-in { display: flex; align-items: center; gap: 4px; width: 104px; flex: none; border: 1px solid var(--line); border-radius: 8px; padding: 0 10px; background: #fff; }
.price-in span { color: var(--sub); font-weight: 700; }
.price-in input { width: 100%; border: 0; outline: none; font-size: 16px; padding: 8px 0; background: transparent; }
.cstatus { font-size: 13px; color: var(--sub); margin-top: 6px; min-height: 1em; }
.cstatus.err { color: var(--red); }
[data-ui~=nordic] .cstatus.err { color: #cc0008; }

.tip-qr { display: block; width: 200px; max-width: 70%; margin: 8px auto 0; border-radius: 8px; }

/* ---------- keep for later / brand card ---------- */
.sheet .highlight { margin: 0 0 12px; }
.keep-btns { display: flex; gap: 8px; margin: 12px 0 8px; }
.keep-btns .btn { flex: 1; }
.keep-btns .btn.primary { flex: 1.4; }
.brand-card { margin: 22px 12px 0; border: 2px solid var(--text); background: var(--card); }
.brand-card-head { background: var(--badge); color: #fff; padding: 10px 14px; font-weight: 800; }
.brand-card-body { padding: 12px 14px 14px; font-size: 15px; line-height: 2; }
.brand-card-note { background: #fff8cc; padding: 8px 10px; margin-top: 8px; font-size: 13px; line-height: 1.6; }
.keep-bar {
  position: fixed; left: 10px; right: 10px; bottom: calc(14px + var(--safe-b)); z-index: 30; max-width: 620px; margin: 0 auto;
  display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 10px; background: #111; color: #fff;
  transform: translateY(150%); transition: transform .25s;
}
.keep-bar.on { transform: none; }
.keep-bar b { font-size: 15px; }
.keep-bar .grow div { font-size: 12px; color: #bbb; }
.keep-star { font-size: 24px; color: #ffdb00; }
.keep-bar .btn { background: #ffdb00; color: #111; border-radius: 999px; }
.keep-x { background: none; border: 0; color: #888; font-size: 20px; padding: 0 2px; cursor: pointer; }
.stats .stat-earned b { display: inline-block; background: #ffdb00; padding: 0 6px; }
.stats .stat-earned span { display: block; }
.end-summary { background: #fff; border-radius: var(--radius); padding: 14px; margin-bottom: 12px; }
.end-big { font-size: 22px; font-weight: 900; margin: 2px 0 6px; }

/* ---------- top-right keep tag on a buyer's list ---------- */
.head.has-keep-tag { position: relative; }
.head.has-keep-tag h1 { padding-right: 120px; }
.keep-tag {
  position: absolute; right: 12px; top: 14px; display: flex; flex-direction: column; align-items: center;
  padding: 5px 10px; background: #ffdb00; color: #111; font-size: 14px; font-weight: 800; line-height: 1.3;
  box-shadow: 2px 2px 0 rgba(0,0,0,.15);
}
.keep-tag small { font-size: 11px; font-weight: 600; }

/* ---------- 我的清单 ---------- */
.list-row { display: block; padding: 12px 16px; background: var(--card); border-bottom: 1px solid var(--line); color: var(--text); }
.list-row-stats { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 6px; font-size: 13px; color: var(--sub); }
.list-row-stats b { color: var(--text); }
.earned-tag { background: #ffdb00; padding: 0 4px; }
.lists-keep { margin: 0 12px 12px; }
.lists-keep .small { margin-top: 4px; }
.sheet a.cell { color: var(--text); }

/* ---------- 推荐朋友 ---------- */
.btn.rec-btn { background: #ffdb00; color: #111; }
.friend-note { margin: 0 0 18px; padding: 8px 12px; background: #fff8cc; border-left: 4px solid #ffdb00; font-size: 14px; text-align: left; }
.wx-chat { background: #ededed; padding: 12px 10px 14px; border-radius: 8px; margin-bottom: 12px; }
.wx-chat > .small { margin-bottom: 8px; }
.wx-card { display: flex; gap: 10px; align-items: center; max-width: 280px; margin: 0 auto; padding: 10px 12px; background: #fff; border-radius: 6px; box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.wx-card .t { font-size: 15px; font-weight: 600; line-height: 1.35; }
.wx-card .d { font-size: 12px; color: #888; line-height: 1.4; margin-top: 4px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.wx-card img { width: 48px; height: 48px; flex: none; }
.sold-rec { margin: 0 0 12px; padding: 16px; background: #0058a3; color: #fff; }
.sold-rec b { display: block; font-size: 19px; margin-bottom: 2px; }
.sold-rec .small { opacity: .85; }
.sold-rec .btn { margin-top: 12px; background: #ffdb00; color: #111; }

/* ---------- 打码 editor ---------- */
.mosaic-ed { position: fixed; inset: 0; z-index: 100; background: #000; display: flex; flex-direction: column; }
.mosaic-tip { color: #fff; text-align: center; font-size: 14px; padding: 14px 16px 10px; }
.mosaic-stage { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; padding: 0 8px; }
.mosaic-stage canvas { max-width: 100%; max-height: 100%; touch-action: none; display: block; }
.mosaic-bar { display: flex; gap: 10px; justify-content: center; padding: 14px 16px calc(14px + env(safe-area-inset-bottom)); }
.mosaic-bar .pill { min-width: 80px; }
.mosaic-ed .pill:not(.dark) { background: #333; color: #fff; border-color: #333; }
.mosaic-ed .pill.dark { background: #ffdb00; color: #111; border-color: #ffdb00; }
.mosaic-ed .pill:disabled { opacity: .4; }
.crop-wrap { position: relative; overflow: hidden; touch-action: none; }
.crop-wrap canvas { max-width: none; max-height: none; }
.crop-box { position: absolute; box-sizing: border-box; border: 2px solid #fff; box-shadow: 0 0 0 9999px rgba(0, 0, 0, .55); cursor: move; }
.crop-box i { position: absolute; width: 28px; height: 28px; border: 0 solid #ffdb00; }
.crop-box i[data-h=nw] { left: -4px; top: -4px; border-width: 4px 0 0 4px; cursor: nwse-resize; }
.crop-box i[data-h=ne] { right: -4px; top: -4px; border-width: 4px 4px 0 0; cursor: nesw-resize; }
.crop-box i[data-h=sw] { left: -4px; bottom: -4px; border-width: 0 0 4px 4px; cursor: nesw-resize; }
.crop-box i[data-h=se] { right: -4px; bottom: -4px; border-width: 0 4px 4px 0; cursor: nwse-resize; }

/* ---------- Telegram / English ---------- */
.share-target, .share-lang { justify-content: center; margin: 0 0 12px; }
.share-target button { padding: 6px 16px; font-weight: 700; }
.kind-tag { display: inline-block; font-size: 11px; font-weight: 700; line-height: 1; padding: 3px 5px; border-radius: 4px; vertical-align: 1px; }
.kind-tag.tg { background: #e3f2fd; color: #1976d2; }
.kind-tag.wx { background: #e8f5e9; color: #2e7d32; }
.contact > .btn + .row { margin-top: 12px; }
.contact-more { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 10px; }
.contact-more summary { cursor: pointer; font-size: 13px; color: var(--sub); }
.contact-more[open] summary { margin-bottom: 10px; }
.contact-more > .btn + .row { margin-top: 12px; }
.orig-text { margin-top: 8px; }
.orig-text summary { cursor: pointer; }
.lang-bar { display: flex; justify-content: flex-end; padding: 8px 12px 0; }
.head-row { display: flex; align-items: flex-start; gap: 10px; }
.head-row h1 { flex: 1; min-width: 0; }
.head-row .lang-seg { flex: none; margin-top: 3px; }
.lang-seg { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; font-size: 13px; background: #fff; }
.lang-seg b, .lang-seg button { padding: 4px 12px; line-height: 1.4; }
.lang-seg b { background: #111; color: #fff; font-weight: 700; }
.lang-seg button { border: 0; background: none; color: var(--text); cursor: pointer; font: inherit; }
.post-preview { display: block; width: auto; max-width: min(100%, 320px); max-height: 52vh; margin: 0 auto 10px; border-radius: 8px; box-shadow: 0 1px 4px rgba(0,0,0,0.15); }
.switch-row { display: flex; align-items: center; gap: 8px; margin: 4px 4px 8px; font-size: 15px; cursor: pointer; }
.switch-row input { width: 20px; height: 20px; margin: 0; flex: none; }

/* Item sheet: the name in the other language, under the seller's own. */
.alt-box { margin: 0 0 14px; padding: 10px 12px; border-radius: 8px; background: #f6f7f9; }
.alt-box.missing { background: #fff6e0; }
.alt-box .link-btn { margin-top: 4px; }
.field > span small { font-weight: 400; }
/* Edit form: the translation right under its original. */
.alt-line { margin-top: 8px; padding-left: 10px; border-left: 3px solid var(--line); }
.alt-line > span { display: block; font-size: 12px; color: var(--sub); margin-bottom: 2px; }
