/*!
 * Boer Leads · 询价单样式
 * 复用主题 CSS 变量，未定义时回落到品牌蓝。
 */

/* 悬浮入口：右下角方形快捷键，样式与主题侧栏「电话 / 询价」一致（2026-10-29） */
.boer-cart-fab {
  position: fixed;
  right: 22px;
  bottom: 126px;
  z-index: 900;
  width: 46px;
  height: 46px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 0;
  border: 0;
  border-radius: 14px;
  background: #fff;
  color: var(--c-text, #4a5563);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.1;
  box-shadow: 0 6px 20px rgba(31, 39, 51, .16);
  cursor: pointer;
  transition: all .2s ease;
}
.boer-cart-fab:hover { background: var(--c-primary, #2f7bff); color: #fff; }
.boer-cart-fab__ico { font-size: 17px; line-height: 1; }
.boer-cart-fab__num {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--c-price, #ff6a00);
  color: #fff;
  font-size: 11px;
  line-height: 18px;
  text-align: center;
}

/* 抽屉 */
.boer-cart { position: fixed; inset: 0; z-index: 1250; display: none; }
.boer-cart.is-on { display: block; }
.boer-cart__mask {
  position: absolute; inset: 0;
  background: rgba(16, 22, 32, .5);
  backdrop-filter: blur(2px);
  animation: cart-fade .2s ease;
}
@keyframes cart-fade { from { opacity: 0; } to { opacity: 1; } }
.boer-cart__panel {
  position: absolute; top: 0; right: 0; bottom: 0;
  width: 400px; max-width: 100%;
  display: flex; flex-direction: column;
  background: #fff;
  box-shadow: -8px 0 32px rgba(16, 22, 32, .18);
  animation: cart-in .26s cubic-bezier(.22, .61, .36, 1);
}
@keyframes cart-in { from { transform: translateX(24px); opacity: .6; } to { transform: none; opacity: 1; } }
.boer-cart__head {
  flex: none;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 20px;
  border-bottom: 1px solid var(--c-line, #e8ecf2);
}
.boer-cart__title { font-size: 17px; font-weight: 700; color: var(--c-ink, #1f2733); }
.boer-cart__num {
  display: inline-block; margin-left: 4px; padding: 1px 8px;
  border-radius: 10px; background: #eaf1ff; color: #1b5fd9;
  font-size: 12px; font-weight: 700;
}
.boer-cart__close {
  width: 32px; height: 32px; border: 0; border-radius: 50%;
  background: var(--c-bg, #f5f7fa); color: var(--c-text, #4a5563);
  font-size: 16px; cursor: pointer;
}
.boer-cart__close:hover { background: var(--c-line, #e8ecf2); }

.boer-cart__body { flex: 1 1 auto; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 8px 0; }
.boer-cart__list { list-style: none; margin: 0; padding: 0; }
.boer-cart__item {
  display: flex; gap: 12px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--c-line, #f0f3f7);
}
.boer-cart__thumb { flex: none; width: 64px; height: 64px; border-radius: 8px; overflow: hidden; background: #f5f7fa; }
.boer-cart__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.boer-cart__info { flex: 1 1 auto; min-width: 0; }
.boer-cart__name {
  display: block;
  font-size: 14px; font-weight: 600; color: var(--c-ink, #1f2733);
  line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.boer-cart__price { margin-top: 4px; font-size: 13px; color: var(--c-price, #ff6a00); font-weight: 600; }
.boer-cart__qty { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.boer-cart__step {
  width: 26px; height: 26px; border: 1px solid var(--c-line, #dde3ec); border-radius: 6px;
  background: #fff; color: var(--c-text, #4a5563); font-size: 15px; line-height: 1; cursor: pointer;
}
.boer-cart__step:hover { border-color: #2f7bff; color: #2f7bff; }
.boer-cart__q { min-width: 22px; text-align: center; font-size: 14px; font-weight: 600; }
.boer-cart__del {
  margin-left: auto; border: 0; background: transparent;
  color: var(--c-muted, #8b95a1); font-size: 12px; cursor: pointer;
}
.boer-cart__del:hover { color: #e5484d; }

.boer-cart__empty { padding: 60px 24px; text-align: center; color: var(--c-muted, #8b95a1); }
.boer-cart__empty p { margin: 0 0 12px; font-size: 14px; }
.boer-cart__golink { color: #2f7bff; font-size: 14px; font-weight: 600; }

.boer-cart__foot {
  flex: none;
  padding: 16px 20px calc(16px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--c-line, #e8ecf2);
  background: #fff;
}
.boer-cart__foot-tip { margin-top: 8px; text-align: center; font-size: 12px; color: var(--c-muted, #8b95a1); }
.boer-cart__clear {
  display: block; margin: 10px auto 0; border: 0; background: transparent;
  color: var(--c-muted, #8b95a1); font-size: 12px; text-decoration: underline; cursor: pointer;
}
.boer-cart__clear:hover { color: #e5484d; }

/* 商品卡内的「加入询价单」 */
.p-card__cart {
  display: block; width: 100%; margin-top: 8px;
  padding: 8px 10px;
  border: 1px solid var(--c-line, #dde3ec); border-radius: 8px;
  background: #fff; color: var(--c-ink, #1f2733);
  font-size: 13px; font-weight: 600; cursor: pointer;
  transition: all .18s ease;
}
.p-card__cart:hover { border-color: #2f7bff; color: #2f7bff; background: #f4f8ff; }
.p-card__cart.is-added { border-color: #17a673; color: #17a673; background: #f0fbf6; }

/* 详情页按钮组内的样式（与 btn 并排） */
.btn.boer-cart-add--detail { background: #fff; color: #1b5fd9; border: 1px solid #cfe0ff; }
.btn.boer-cart-add--detail:hover { background: #f4f8ff; }

/* 移动端 */
@media (max-width: 992px) {
  .boer-cart-fab { right: 14px; left: auto; bottom: 96px; font-size: 11px; }
  .boer-cart__panel { width: 100%; }
  .boer-cart__item { padding: 12px 16px; }
  .boer-cart__head { padding: 16px; }
  .boer-cart__foot { padding: 14px 16px calc(14px + env(safe-area-inset-bottom, 0px)); }
}
