/* 美化商店 · 电脑端
   全部颜色与圆角走站点 CSS 变量，换主题时自动跟随。 */

.bs-page {
  --bs-radius: var(--ls-radius, 14px);
  --bs-radius-sm: var(--ls-radius-sm, 10px);
  --bs-line: var(--ls-border, rgba(15, 23, 42, 0.08));
  --bs-surface: var(--ls-card-bg, #fff);
  --bs-ink: var(--ls-text, #1f2937);
  --bs-ink-2: var(--ls-text-secondary, #4b5563);
  --bs-ink-3: var(--ls-text-muted, #94a3b8);
  --bs-brand: var(--ls-primary, #3e7a4e);
  --bs-brand-soft: var(--ls-primary-light, rgba(62, 122, 78, 0.12));
  --bs-brand-rgb: var(--ls-primary-rgb, 62, 122, 78);
  max-width: 1180px;
  margin: 0 auto;
  padding: 24px 20px 72px;
  color: var(--bs-ink);
  font-size: 14px;
}

/* ---------- 页头 ---------- */
.bs-hero {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding: 30px 32px;
  border-radius: calc(var(--bs-radius) + 6px);
  border: 1px solid var(--bs-line);
  background:
    radial-gradient(120% 140% at 0% 0%, rgba(var(--bs-brand-rgb), 0.16), transparent 62%),
    radial-gradient(90% 120% at 100% 10%, rgba(var(--bs-brand-rgb), 0.10), transparent 58%),
    var(--bs-surface);
  overflow: hidden;
}
.bs-hero::after {
  content: "";
  position: absolute;
  inset: auto -60px -80px auto;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  background: rgba(var(--bs-brand-rgb), 0.07);
  pointer-events: none;
}
.bs-hero-txt { position: relative; z-index: 1; min-width: 260px; }
.bs-kicker {
  margin: 0 0 8px;
  font-size: 11px;
  letter-spacing: 0.22em;
  font-weight: 700;
  color: var(--bs-brand);
  opacity: 0.75;
}
.bs-hero-title {
  margin: 0 0 8px;
  font-size: 30px;
  line-height: 1.2;
  font-weight: 800;
  letter-spacing: -0.01em;
}
.bs-hero-intro {
  margin: 0;
  max-width: 54ch;
  font-size: 14px;
  line-height: 1.7;
  color: var(--bs-ink-2);
}
.bs-hero-meta { position: relative; z-index: 1; display: flex; gap: 10px; }
.bs-meta-cell {
  min-width: 108px;
  padding: 12px 16px;
  border-radius: var(--bs-radius-sm);
  background: rgba(255, 255, 255, 0.66);
  border: 1px solid var(--bs-line);
  backdrop-filter: blur(6px);
}
.bs-meta-label { display: block; font-size: 11px; color: var(--bs-ink-3); margin-bottom: 4px; }
.bs-meta-value { font-size: 16px; font-weight: 700; }
.bs-meta-money { color: var(--bs-brand); font-variant-numeric: tabular-nums; }

/* ---------- 页签 ---------- */
.bs-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 22px 0 18px;
  padding: 6px;
  border-radius: var(--bs-radius);
  border: 1px solid var(--bs-line);
  background: var(--bs-surface);
}
.bs-tab {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 16px;
  border: 0;
  border-radius: calc(var(--bs-radius) - 4px);
  background: transparent;
  color: var(--bs-ink-2);
  font-size: 13.5px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease;
}
.bs-tab:hover { background: var(--ls-bg-hover, rgba(15, 23, 42, 0.045)); color: var(--bs-ink); }
.bs-tab.active { background: var(--bs-brand); color: #fff; }
.bs-tab.active .bs-tab-count { background: rgba(255, 255, 255, 0.24); color: #fff; }
.bs-tab i { font-size: 15px; }
.bs-tab-count {
  padding: 1px 6px;
  border-radius: 999px;
  background: var(--bs-brand-soft);
  color: var(--bs-brand);
  font-size: 11px;
  font-style: normal;
  font-weight: 700;
}

/* ---------- 网格与卡片 ---------- */
.bs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(228px, 1fr));
  gap: 16px;
}
.bs-card {
  display: flex;
  flex-direction: column;
  border-radius: var(--bs-radius);
  border: 1px solid var(--bs-line);
  background: var(--bs-surface);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.bs-card:hover {
  transform: translateY(-3px);
  border-color: rgba(var(--bs-brand-rgb), 0.35);
  box-shadow: 0 14px 32px -18px rgba(15, 23, 42, 0.32);
}
.bs-card.is-wearing { border-color: var(--bs-brand); box-shadow: 0 0 0 1px var(--bs-brand) inset; }

.bs-cover {
  position: relative;
  aspect-ratio: 16 / 10;
  background: var(--ls-bg-2, #f3f4f6);
  overflow: hidden;
}
.bs-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* 未上传截图时的自动预览 */
.bs-auto {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.94);
  text-align: center;
}
.bs-auto b { font-size: 19px; font-weight: 800; letter-spacing: 0.02em; }
.bs-auto span { font-size: 11px; opacity: 0.8; letter-spacing: 0.16em; }
.bs-auto i { font-size: 26px; opacity: 0.9; }
.bs-auto.theme { background: linear-gradient(135deg, #3e7a4e, #6cae7d); }
.bs-auto.cursor { background: linear-gradient(135deg, #4b5f8a, #7d93c4); }
.bs-auto.font_title { background: linear-gradient(135deg, #8a5a3b, #c99166); }
.bs-auto.font_content { background: linear-gradient(135deg, #5b4a7a, #9385bd); }

.bs-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.62);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  backdrop-filter: blur(4px);
}
.bs-badge.on { background: var(--bs-brand); }

.bs-card-body { padding: 14px 15px 15px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.bs-card-name { font-size: 15px; font-weight: 700; margin: 0; }
.bs-card-desc { margin: 0; font-size: 12.5px; line-height: 1.6; color: var(--bs-ink-3); flex: 1; }
.bs-card-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 4px; }
.bs-price { font-size: 15px; font-weight: 800; color: var(--bs-brand); font-variant-numeric: tabular-nums; }
.bs-price small { font-size: 11px; font-weight: 600; color: var(--bs-ink-3); margin-left: 2px; }
.bs-price.free { color: var(--ls-success, #16a34a); }

.bs-btn {
  padding: 8px 16px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--bs-brand);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: filter 0.16s ease, opacity 0.16s ease;
}
.bs-btn:hover { filter: brightness(1.06); }
.bs-btn:disabled { opacity: 0.5; cursor: default; filter: none; }
.bs-btn.ghost { background: transparent; color: var(--bs-ink-2); border-color: var(--bs-line); }
.bs-btn.ghost:hover { border-color: rgba(var(--bs-brand-rgb), 0.4); color: var(--bs-brand); }
.bs-btn.block { width: 100%; padding: 11px 16px; border-radius: var(--bs-radius-sm); }

/* ---------- 空态 ---------- */
.bs-empty {
  padding: 64px 20px;
  text-align: center;
  color: var(--bs-ink-3);
}
.bs-empty i { font-size: 34px; display: block; margin-bottom: 10px; opacity: 0.5; }

/* ---------- 弹窗 ---------- */
.bs-mask {
  position: fixed;
  inset: 0;
  z-index: 9990;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.52);
  backdrop-filter: blur(3px);
}
.bs-dialog {
  width: min(760px, 100%);
  max-height: min(86vh, 780px);
  display: flex;
  flex-direction: column;
  border-radius: calc(var(--bs-radius) + 4px);
  background: var(--bs-surface);
  box-shadow: 0 30px 80px -30px rgba(15, 23, 42, 0.55);
  overflow: hidden;
}
.bs-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--bs-line);
}
.bs-dialog-title { margin: 0; font-size: 16px; font-weight: 700; }
.bs-dialog-close {
  width: 32px; height: 32px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: 50%;
  background: transparent; color: var(--bs-ink-3); font-size: 18px; cursor: pointer;
}
.bs-dialog-close:hover { background: var(--ls-bg-hover, rgba(15,23,42,.06)); color: var(--bs-ink); }
.bs-dialog-body { padding: 20px; overflow: auto; }
.bs-dialog-foot { padding: 14px 20px; border-top: 1px solid var(--bs-line); display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

.bs-dialog-preview {
  aspect-ratio: 16 / 9;
  border-radius: var(--bs-radius-sm);
  overflow: hidden;
  background: var(--ls-bg-2, #f3f4f6);
  margin-bottom: 16px;
  position: relative;
}
.bs-dialog-preview img { width: 100%; height: 100%; object-fit: cover; display: block; }

.bs-opt-title { font-size: 12.5px; font-weight: 700; color: var(--bs-ink-2); margin: 0 0 10px; }
.bs-opts { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.bs-opt {
  position: relative;
  padding: 12px 14px;
  border: 1px solid var(--bs-line);
  border-radius: var(--bs-radius-sm);
  background: var(--bs-surface);
  text-align: left;
  font-family: inherit;
  cursor: pointer;
  transition: border-color 0.16s ease, background 0.16s ease;
}
.bs-opt:hover { border-color: rgba(var(--bs-brand-rgb), 0.4); }
.bs-opt.active { border-color: var(--bs-brand); background: var(--bs-brand-soft); }
.bs-opt-label { display: block; font-size: 13px; font-weight: 600; color: var(--bs-ink); }
.bs-opt-price { display: block; margin-top: 4px; font-size: 14px; font-weight: 800; color: var(--bs-brand); }
.bs-opt-price s { font-size: 11px; color: var(--bs-ink-3); font-weight: 500; margin-left: 5px; }

.bs-note { margin: 14px 0 0; font-size: 12px; line-height: 1.7; color: var(--bs-ink-3); }
.bs-total { font-size: 13px; color: var(--bs-ink-2); }
.bs-total b { font-size: 20px; color: var(--bs-brand); font-weight: 800; margin-left: 6px; font-variant-numeric: tabular-nums; }

/* ---------- 老三店 ---------- */
.bs-legacy-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  flex-wrap: wrap; margin-bottom: 14px;
}
.bs-legacy-tip { font-size: 12.5px; color: var(--bs-ink-3); margin: 0; }
.bs-legacy-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; }
.bs-legacy-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px; border: 1px solid var(--bs-line); border-radius: var(--bs-radius-sm);
  background: var(--bs-surface);
}
.bs-legacy-thumb {
  width: 44px; height: 44px; flex: none; border-radius: 8px; overflow: hidden;
  background: var(--ls-bg-2, #f3f4f6); display: flex; align-items: center; justify-content: center;
  color: var(--bs-brand); font-size: 18px;
}
.bs-legacy-thumb img { width: 100%; height: 100%; object-fit: cover; }
.bs-legacy-txt { min-width: 0; flex: 1; }
.bs-legacy-name { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bs-legacy-price { font-size: 12px; color: var(--bs-brand); font-weight: 700; margin-top: 2px; }

@media (max-width: 720px) {
  .bs-page { padding: 16px 14px 56px; }
  .bs-hero { padding: 22px 20px; }
  .bs-hero-title { font-size: 23px; }
  .bs-hero-meta { width: 100%; }
  .bs-meta-cell { flex: 1; min-width: 0; }
  .bs-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
}

/* bs-extra-v1 */
.bs-sec { margin-top: 26px; }
.bs-sec:first-child { margin-top: 0; }
.bs-sec-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; margin: 0 0 12px;
}
.bs-sec-title { margin: 0; font-size: 15.5px; font-weight: 700; }
.bs-sec-sub { margin: 0; font-size: 12.5px; color: var(--bs-ink-3); }
.bs-legacy-sec { margin-top: 26px; }
.bs-legacy-sec:first-child { margin-top: 0; }
.bs-legacy-wrap { display: block; }
.bs-empty.slim { padding: 28px 16px; font-size: 12.5px; }

.bs-toast {
  position: fixed; left: 50%; bottom: 42px; z-index: 10000;
  transform: translateX(-50%);
  max-width: min(420px, 86vw);
  padding: 11px 20px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.9);
  color: #fff; font-size: 13px; line-height: 1.5; text-align: center;
  box-shadow: 0 12px 30px -12px rgba(15, 23, 42, 0.6);
  animation: bs-toast-in 0.22s ease;
}
.bs-toast.ok { background: var(--ls-success, #16a34a); }
.bs-toast.err { background: var(--ls-danger, #dc2626); }
.bs-toast.bs-toast-out { opacity: 0; transition: opacity 0.26s ease; }
@keyframes bs-toast-in { from { opacity: 0; transform: translate(-50%, 8px); } to { opacity: 1; transform: translate(-50%, 0); } }

/* cursor states */
.bs-states { display: flex; flex-wrap: wrap; gap: 6px; }
.bs-state {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 10px; border-radius: 999px;
  border: 1px dashed var(--bs-line);
  font-size: 11.5px; color: var(--bs-ink-3);
}
.bs-state.on {
  border-style: solid;
  border-color: rgba(var(--bs-brand-rgb), 0.45);
  background: var(--bs-brand-soft);
  color: var(--bs-brand);
  font-weight: 600;
}
.bs-state i { font-size: 12px; }

/* reload prompt */
.bs-dialog-sm { width: min(430px, 100%); }
.bs-reload-body { text-align: center; padding: 26px 22px 10px; }
.bs-reload-icon {
  width: 56px; height: 56px; margin: 0 auto 14px;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: var(--bs-brand-soft); color: var(--bs-brand); font-size: 26px;
}
.bs-reload-title { margin: 0 0 6px; font-size: 15px; font-weight: 700; }
.bs-reload-sub { margin: 0; font-size: 12.5px; color: var(--bs-ink-3); line-height: 1.7; }
.bs-reload-foot { justify-content: center; gap: 10px; }
.bs-reload-foot .bs-btn { min-width: 110px; }
