:root {
  --bg: #f3f4f6;
  --card: #ffffff;
  --ink: #12141a;
  --ink2: #565d6d;
  --ink3: #8b92a3;
  --line: #e9ebf0;
  --red: #df2b2b;
  --red-soft: #fdecec;
  --green: #0f9d58;
  --blue: #1d4ed8;
  --radius: 16px;
  --shadow: 0 1px 2px rgba(16, 24, 40, 0.05), 0 10px 28px -16px rgba(16, 24, 40, 0.18);
  --safe-b: env(safe-area-inset-bottom, 0px);
}

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

html,
body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

input,
textarea,
select {
  font-family: inherit;
  font-size: 15px;
  color: var(--ink);
}

a {
  color: inherit;
  text-decoration: none;
}

.hide {
  display: none !important;
}

.num {
  font-variant-numeric: tabular-nums;
}

/* ---------- 顶部 ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}

.topbar-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 14px 16px 12px;
}

.shop-head {
  display: flex;
  align-items: center;
  gap: 12px;
}

.shop-logo {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  object-fit: cover;
  background: #111827;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 700;
  font-size: 18px;
  overflow: hidden;
}

.shop-name {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.2px;
  line-height: 1.3;
}

.shop-sub {
  font-size: 12px;
  color: var(--ink3);
  margin-top: 2px;
}

.shop-sub b {
  color: var(--red);
  font-weight: 700;
}

/* ---------- 搜索 ---------- */
.search-wrap {
  position: relative;
  margin-top: 12px;
}

.search-wrap input {
  width: 100%;
  height: 42px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #f7f8fa;
  padding: 0 14px 0 38px;
  outline: none;
  transition: border-color 0.15s, background 0.15s;
}

.search-wrap input:focus {
  background: #fff;
  border-color: #c9ced9;
}

.search-icon {
  position: absolute;
  left: 13px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--ink3);
  pointer-events: none;
}

/* ---------- 筛选 ---------- */
.filters {
  max-width: 1080px;
  margin: 0 auto;
  padding: 10px 0 0;
}

.chip-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 0 16px 10px;
  scrollbar-width: none;
}

.chip-row::-webkit-scrollbar {
  display: none;
}

.chip {
  flex: 0 0 auto;
  height: 32px;
  padding: 0 14px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--line);
  font-size: 13px;
  color: var(--ink2);
  white-space: nowrap;
  transition: all 0.15s;
}

.chip.on {
  background: #111827;
  border-color: #111827;
  color: #fff;
  font-weight: 600;
}

.chip-row .spacer {
  flex: 0 0 4px;
}

.result-line {
  max-width: 1080px;
  margin: 0 auto;
  padding: 2px 16px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--ink3);
}

.sort-btn {
  font-size: 12px;
  color: var(--ink2);
  padding: 4px 10px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--line);
}

/* ---------- 车源网格 ---------- */
.grid {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 16px 32px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

@media (min-width: 700px) {
  .grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
  }
}

@media (min-width: 1000px) {
  .grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.vcard {
  background: var(--card);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  display: block;
  position: relative;
}

.vcard:active {
  transform: scale(0.993);
}

.vcard-img {
  position: relative;
  aspect-ratio: 4 / 3;
  background: linear-gradient(135deg, #eceef3, #e2e5ec);
  overflow: hidden;
}

.vcard-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.vcard-img .ph {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: #b6bcc9;
  font-size: 12px;
  letter-spacing: 2px;
}

.badge {
  position: absolute;
  left: 10px;
  top: 10px;
  height: 24px;
  padding: 0 9px;
  border-radius: 7px;
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  background: rgba(17, 24, 39, 0.82);
  color: #fff;
  backdrop-filter: blur(6px);
  letter-spacing: 0.3px;
}

.badge.sold {
  background: rgba(107, 114, 128, 0.9);
}

.badge.booked {
  background: rgba(217, 119, 6, 0.92);
}

.badge.hot {
  background: rgba(223, 43, 43, 0.92);
}

.vcard-body {
  padding: 12px 14px 14px;
}

.vcard-title {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.vcard-meta {
  margin-top: 5px;
  font-size: 12px;
  color: var(--ink3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.vcard-foot {
  margin-top: 10px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.price {
  color: var(--red);
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.4px;
  line-height: 1;
}

.price small {
  font-size: 12px;
  font-weight: 700;
  margin-left: 1px;
}

.price-old {
  font-size: 11px;
  color: var(--ink3);
  text-decoration: line-through;
  margin-left: 6px;
  font-weight: 400;
}

.tag-mini {
  font-size: 11px;
  color: var(--ink2);
  background: #f3f4f7;
  border-radius: 6px;
  padding: 3px 7px;
}

/* ---------- 空状态 ---------- */
.empty {
  max-width: 480px;
  margin: 48px auto;
  padding: 0 24px;
  text-align: center;
  color: var(--ink3);
}

.empty .ico {
  font-size: 40px;
  opacity: 0.5;
  margin-bottom: 10px;
}

.empty h3 {
  color: var(--ink2);
  font-size: 15px;
  font-weight: 600;
  margin: 0 0 6px;
}

.empty p {
  font-size: 13px;
  margin: 0;
  line-height: 1.7;
}

/* ---------- 页脚 ---------- */
.site-foot {
  border-top: 1px solid var(--line);
  background: #fff;
  padding: 22px 16px calc(26px + var(--safe-b));
  text-align: center;
  color: var(--ink3);
  font-size: 12px;
}

.site-foot .foot-name {
  color: var(--ink);
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 4px;
}

.site-foot a {
  color: var(--blue);
}

.admin-link {
  display: inline-block;
  margin-top: 14px;
  font-size: 11px;
  color: #b9bfcc;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
}

/* ---------- 详情页 ---------- */
.detail-top {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #f3f4f7;
  color: var(--ink);
  flex: 0 0 auto;
}

.detail-top .t {
  font-size: 15px;
  font-weight: 600;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.gallery {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  aspect-ratio: 4 / 3;
  background: #eceef3;
}

.gallery::-webkit-scrollbar {
  display: none;
}

.gallery .slide {
  flex: 0 0 100%;
  scroll-snap-align: center;
  position: relative;
  display: grid;
  place-items: center;
}

.gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gal-count {
  position: absolute;
  right: 12px;
  bottom: 12px;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 12px;
  padding: 3px 10px;
  border-radius: 999px;
  z-index: 5;
  font-variant-numeric: tabular-nums;
}

.dots {
  display: flex;
  justify-content: center;
  gap: 5px;
  padding: 10px 0 0;
}

.dots i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #d3d7e0;
  transition: all 0.2s;
}

.dots i.on {
  background: #111827;
  width: 16px;
  border-radius: 3px;
}

.detail-wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 0 96px;
}

.panel {
  background: #fff;
  margin-top: 10px;
  padding: 16px;
}

@media (min-width: 760px) {
  .detail-wrap {
    padding-left: 16px;
    padding-right: 16px;
  }
  .panel {
    border-radius: var(--radius);
    box-shadow: var(--shadow);
  }
}

.price-row {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.big-price {
  font-size: 30px;
  font-weight: 800;
  color: var(--red);
  letter-spacing: -1px;
  line-height: 1;
}

.big-price small {
  font-size: 15px;
  font-weight: 700;
}

.d-head-title {
  font-size: 19px;
  font-weight: 700;
  line-height: 1.35;
  margin: 10px 0 8px;
}

.mini-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.mini-tag {
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 6px;
  background: #f3f4f7;
  color: var(--ink2);
}

.spec-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border-radius: 12px;
  overflow: hidden;
  margin-top: 4px;
}

@media (max-width: 380px) {
  .spec-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.spec-cell {
  background: #fff;
  padding: 12px 10px;
  text-align: center;
}

.spec-cell .k {
  font-size: 11px;
  color: var(--ink3);
  margin-bottom: 3px;
}

.spec-cell .v {
  font-size: 14px;
  font-weight: 600;
}

.panel-title {
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.panel-title::before {
  content: "";
  width: 3px;
  height: 14px;
  border-radius: 2px;
  background: #111827;
}

.desc-text {
  font-size: 14px;
  color: var(--ink2);
  line-height: 1.85;
  white-space: pre-wrap;
  word-break: break-word;
}

.shop-card {
  display: flex;
  gap: 12px;
  align-items: center;
}

.shop-card .info {
  flex: 1;
  min-width: 0;
}

.shop-card .n {
  font-weight: 700;
  font-size: 15px;
}

.shop-card .a {
  font-size: 12px;
  color: var(--ink3);
  margin-top: 3px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.action-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(14px);
  border-top: 1px solid var(--line);
  padding: 10px 14px calc(10px + var(--safe-b));
  display: flex;
  gap: 10px;
  align-items: center;
}

.btn {
  height: 46px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: opacity 0.15s, transform 0.1s;
  padding: 0 18px;
  white-space: nowrap;
}

.btn:active {
  opacity: 0.85;
  transform: scale(0.99);
}

.btn-dark {
  background: #111827;
  color: #fff;
  flex: 1;
}

.btn-red {
  background: var(--red);
  color: #fff;
  flex: 1;
}

.btn-ghost {
  background: #f3f4f7;
  color: var(--ink);
  border: 1px solid var(--line);
  flex: 0 0 auto;
}

.btn-line {
  background: #fff;
  color: var(--ink);
  border: 1.5px solid #111827;
  flex: 1;
}

.btn-block {
  width: 100%;
}

.btn-sm {
  height: 34px;
  font-size: 13px;
  border-radius: 9px;
  padding: 0 13px;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ---------- 管理端 ---------- */
.admin-shell {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 0 60px;
}

.admin-head {
  background: #111827;
  color: #fff;
  padding: 20px 16px 18px;
}

.admin-head .row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-head h1 {
  font-size: 19px;
  margin: 0;
  font-weight: 700;
  letter-spacing: -0.3px;
}

.admin-head p {
  margin: 4px 0 0;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.55);
}

.auth-wrap {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px 16px;
  background: linear-gradient(180deg, #111827 0%, #111827 42%, var(--bg) 42%, var(--bg) 100%);
}

.auth-card {
  width: 100%;
  max-width: 380px;
  background: #fff;
  border-radius: 20px;
  padding: 26px 22px 24px;
  box-shadow: 0 24px 60px -24px rgba(0, 0, 0, 0.4);
}

.auth-card h2 {
  margin: 0 0 6px;
  font-size: 20px;
  letter-spacing: -0.4px;
}

.auth-card .sub {
  font-size: 13px;
  color: var(--ink3);
  margin: 0 0 20px;
  line-height: 1.6;
}

.field {
  margin-bottom: 14px;
}

.field label {
  display: block;
  font-size: 12px;
  color: var(--ink2);
  font-weight: 600;
  margin-bottom: 6px;
}

.field input,
.field textarea,
.field select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 11px 13px;
  background: #fbfbfc;
  outline: none;
  transition: border-color 0.15s, background 0.15s;
}

.field input:focus,
.field textarea:focus,
.field select:focus {
  background: #fff;
  border-color: #9aa2b5;
}

.field textarea {
  resize: vertical;
  min-height: 84px;
  line-height: 1.6;
}

.field .hint {
  font-size: 11px;
  color: var(--ink3);
  margin-top: 5px;
  line-height: 1.6;
}

.field-err {
  font-size: 12px;
  color: var(--red);
  margin-top: 6px;
}

.code-row {
  display: flex;
  gap: 8px;
}

.code-row input {
  flex: 1;
  min-width: 0;
}

.code-row .btn {
  flex: 0 0 auto;
  height: 44px;
  font-size: 13px;
  padding: 0 14px;
  background: #f3f4f7;
  border: 1px solid var(--line);
  color: var(--ink);
  border-radius: 10px;
}

.divider {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink3);
  font-size: 11px;
  margin: 16px 0;
}

.divider::before,
.divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

.tabs {
  display: flex;
  gap: 4px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  padding: 0 12px;
  position: sticky;
  top: 0;
  z-index: 20;
}

.tab {
  padding: 13px 14px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink3);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}

.tab.on {
  color: var(--ink);
  border-bottom-color: #111827;
}

.admin-body {
  padding: 14px 16px;
}

.stat-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 14px;
}

.stat {
  background: #fff;
  border-radius: 12px;
  padding: 13px 14px;
  box-shadow: var(--shadow);
}

.stat .n {
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.5px;
  font-variant-numeric: tabular-nums;
}

.stat .l {
  font-size: 11px;
  color: var(--ink3);
  margin-top: 2px;
}

.vrow {
  background: #fff;
  border-radius: 14px;
  padding: 10px;
  display: flex;
  gap: 12px;
  margin-bottom: 10px;
  box-shadow: var(--shadow);
  align-items: center;
}

.vrow .thumb {
  width: 88px;
  height: 66px;
  border-radius: 10px;
  object-fit: cover;
  background: #eceef3;
  flex: 0 0 auto;
}

.vrow .mid {
  flex: 1;
  min-width: 0;
}

.vrow .t {
  font-size: 14px;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vrow .m {
  font-size: 11px;
  color: var(--ink3);
  margin-top: 4px;
}

.vrow .acts {
  display: flex;
  gap: 6px;
  margin-top: 8px;
}

.mini-btn {
  font-size: 11px;
  padding: 5px 10px;
  border-radius: 7px;
  background: #f3f4f7;
  color: var(--ink2);
  border: 1px solid transparent;
}

.mini-btn.danger {
  color: var(--red);
  background: var(--red-soft);
}

.mini-btn.dark {
  background: #111827;
  color: #fff;
}

.status-pill {
  font-size: 10px;
  padding: 2px 7px;
  border-radius: 999px;
  font-weight: 700;
  margin-left: 6px;
  vertical-align: 1px;
}

.st-在售 {
  background: #e7f6ee;
  color: #0f7b46;
}

.st-已售 {
  background: #f1f2f5;
  color: #6b7280;
}

.st-已定 {
  background: #fef3c7;
  color: #92400e;
}

.fab {
  position: fixed;
  right: 18px;
  bottom: calc(22px + var(--safe-b));
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: #111827;
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 12px 26px -8px rgba(17, 24, 39, 0.55);
  z-index: 45;
  font-size: 26px;
  line-height: 1;
}

/* 抽屉 / 弹层 */
.sheet-mask {
  position: fixed;
  inset: 0;
  background: rgba(12, 15, 22, 0.45);
  z-index: 90;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s;
}

.sheet-mask.on {
  opacity: 1;
  pointer-events: auto;
}

.sheet {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 100;
  background: #fff;
  border-radius: 20px 20px 0 0;
  max-height: 94vh;
  overflow-y: auto;
  transform: translateY(101%);
  transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
  padding-bottom: calc(18px + var(--safe-b));
}

.sheet.on {
  transform: translateY(0);
}

@media (min-width: 760px) {
  .sheet {
    left: 50%;
    transform: translate(-50%, 101%);
    width: 640px;
    border-radius: 20px;
    bottom: 24px;
    max-height: 88vh;
  }
  .sheet.on {
    transform: translate(-50%, 0);
  }
}

.sheet-head {
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
  padding: 16px 18px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  z-index: 2;
}

.sheet-head h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
}

.sheet-body {
  padding: 16px 18px 4px;
}

.sheet-foot {
  position: sticky;
  bottom: 0;
  padding: 12px 18px calc(4px + var(--safe-b));
  background: #fff;
  border-top: 1px solid var(--line);
  display: flex;
  gap: 10px;
}

.row2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.form-sec {
  margin: 4px 0 18px;
}

.form-sec > .st {
  font-size: 12px;
  font-weight: 700;
  color: var(--ink2);
  margin: 0 0 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.form-sec > .st::before {
  content: "";
  width: 3px;
  height: 12px;
  border-radius: 2px;
  background: #111827;
}

.ai-box {
  border: 1px dashed #c9ced9;
  border-radius: 12px;
  padding: 12px;
  background: #fafbfc;
}

.ai-box textarea {
  width: 100%;
  border: none;
  background: transparent;
  outline: none;
  resize: vertical;
  min-height: 76px;
  font-size: 13px;
  line-height: 1.7;
}

.ai-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 8px;
}

.ai-hint {
  font-size: 11px;
  color: var(--ink3);
  line-height: 1.5;
}

.photos {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

@media (max-width: 380px) {
  .photos {
    grid-template-columns: repeat(3, 1fr);
  }
}

.photo-item {
  position: relative;
  aspect-ratio: 1;
  border-radius: 10px;
  overflow: hidden;
  background: #f1f2f5;
}

.photo-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-item .del {
  position: absolute;
  right: 3px;
  top: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font-size: 13px;
  line-height: 1;
  display: grid;
  place-items: center;
}

.photo-item .cover-tag {
  position: absolute;
  left: 0;
  bottom: 0;
  right: 0;
  background: rgba(17, 24, 39, 0.78);
  color: #fff;
  font-size: 10px;
  text-align: center;
  padding: 2px 0;
}

.photo-add {
  aspect-ratio: 1;
  border-radius: 10px;
  border: 1px dashed #c9ced9;
  background: #fafbfc;
  display: grid;
  place-items: center;
  color: var(--ink3);
  font-size: 22px;
  font-weight: 300;
}

.photo-add small {
  display: block;
  font-size: 10px;
  font-weight: 400;
  margin-top: 2px;
}

/* 加载 */
.spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: inline-block;
}

.spinner.dark {
  border-color: #dfe2e8;
  border-top-color: #111827;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.loading-block {
  padding: 60px 0;
  text-align: center;
  color: var(--ink3);
  font-size: 13px;
}

/* toast */
.toast-wrap {
  position: fixed;
  left: 50%;
  top: 22px;
  transform: translateX(-50%);
  z-index: 300;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  pointer-events: none;
  width: max-content;
  max-width: calc(100vw - 32px);
}

.toast {
  background: rgba(17, 24, 39, 0.94);
  color: #fff;
  font-size: 13px;
  padding: 10px 16px;
  border-radius: 10px;
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
  animation: tin 0.22s ease;
  line-height: 1.5;
}

.toast.err {
  background: rgba(190, 30, 30, 0.96);
}

@keyframes tin {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
}

/* 分享卡片 */
.share-preview {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
  background: #fafbfc;
  font-size: 13px;
  line-height: 1.8;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--ink2);
  max-height: 260px;
  overflow-y: auto;
}

.qr-holder {
  display: grid;
  place-items: center;
  padding: 12px;
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--line);
}

.qr-holder svg {
  width: 180px;
  height: 180px;
}

.mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
  word-break: break-all;
}

/* ---------------- 语言切换 ---------------- */
.head-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.head-row .shop-head {
  flex: 1;
  min-width: 0;
}

.lang-btn {
  flex: 0 0 auto;
  height: 32px;
  padding: 0 13px;
  border-radius: 16px;
  background: #f3f4f7;
  border: 1px solid var(--line);
  font-size: 12px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: 0.2px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.lang-btn:active {
  transform: scale(0.96);
}

.detail-top .lang-btn {
  margin-left: 2px;
}

/* 后台：已生成英文的标记 */
.st-en {
  background: #eef2ff;
  color: #3b5bdb;
}

/* 英文文案更长：底部价格行允许换行，避免撑破卡片 */
.vcard-foot {
  flex-wrap: wrap;
  row-gap: 6px;
}

.vcard-foot > div:first-child {
  min-width: 0;
}

.tag-mini {
  white-space: nowrap;
  flex: 0 0 auto;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ---------------- 后台：收件箱待确认 ---------------- */
.inbox-card {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 12px 0 4px;
  padding: 12px;
  border-radius: 14px;
  background: #eef4ff;
  border: 1px solid #d6e2ff;
}

.inbox-ico {
  font-size: 20px;
  line-height: 1.2;
}

.inbox-mid {
  flex: 1;
  min-width: 0;
}

.inbox-mid b {
  display: block;
  font-size: 14px;
  color: #14306b;
  margin-bottom: 3px;
}

.inbox-mid p {
  font-size: 12px;
  line-height: 1.5;
  color: #4a5a7a;
  margin: 0 0 6px;
}

.inbox-names {
  font-size: 12px;
  color: #1d4ed8;
  line-height: 1.5;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* ---------- WhatsApp / 联系方式 ---------- */
.btn-wa {
  background: #25d366;
  color: #08331f;
  flex: 1;
  text-decoration: none;
}

.btn-wa:active {
  opacity: 0.9;
}

/* 页脚：标语 + 联系按钮 */
.foot-tag {
  font-size: 11px;
  color: #9aa1b0;
  margin-bottom: 6px;
  letter-spacing: 0.2px;
}

.foot-contacts {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.foot-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 38px;
  padding: 0 15px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink) !important;
  font-size: 12.5px;
  font-weight: 600;
  text-decoration: none;
}

.foot-btn.wa {
  background: #25d366;
  border-color: #25d366;
  color: #08331f !important;
}

.foot-btn:active {
  transform: scale(0.97);
}

.foot-social {
  margin-top: 10px;
  font-size: 11.5px;
  color: #9aa1b0;
  line-height: 1.8;
}

/* 详情页：卖家联系信息 */
.shop-rows {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.shop-rows .srow {
  font-size: 12.5px;
  color: var(--ink2);
  line-height: 1.5;
}

/* ---------- 首页放大联系方式 ---------- */
.contact-hero {
  margin: 12px 12px 0;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 16px 16px 15px;
}

.contact-hero .ch-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.contact-hero .ch-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
}

.contact-hero .ch-sub {
  font-size: 11.5px;
  color: var(--ink3);
}

.contact-hero .ch-number {
  display: inline-block;
  margin-top: 8px;
  font-size: 26px;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: #0e7a42;
  text-decoration: none;
  font-variant-numeric: tabular-nums;
}

.contact-hero .ch-btns {
  margin-top: 12px;
  display: flex;
  gap: 10px;
}

.contact-hero .ch-btn {
  flex: 1;
  height: 46px;
  font-size: 15.5px;
  font-weight: 700;
  justify-content: center;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.contact-hero .ch-btn .btn-wa,
.contact-hero .ch-btn-wa {
  background: #25d366;
  border-color: #25d366;
  color: #08331f;
}

.contact-hero .ch-extra {
  margin-top: 10px;
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  font-size: 12.5px;
  color: var(--ink2);
}

.contact-hero .ch-btn:active {
  transform: scale(0.97);
}
