@charset "utf-8";
/* ==========================================================================
 * jicart for 智简魔方业务系统 —— 购物车主题 · 公共设计系统
 * --------------------------------------------------------------------------
 * 1. 所有类名统一 jic- 前缀、CSS 变量统一 --jic- 前缀，避免与业务系统
 *    （客户中心主题 / Element UI / 其他插件）样式互相污染。
 * 2. 只负责"皮肤"，不参与任何业务逻辑，保证移植后功能与官方 default 一致。
 * 3. 变量与配色沿用 jicart 原主题（蓝色玻璃态）。
 * ========================================================================== */

/* ---------- 设计令牌（作用域限定在 .jic-scope，避免全局污染） ---------- */
.jic-scope {
  --jic-brand-50: #eef5ff;
  --jic-brand-100: #dbeafe;
  --jic-brand-200: #bfdbfe;
  --jic-brand-300: #93c5fd;
  --jic-brand-400: #60a5fa;
  --jic-brand-500: #3b82f6;
  --jic-brand-600: #2563eb;
  --jic-brand-700: #1d4ed8;

  --jic-ink-900: #0b1226;
  --jic-ink-700: #1a2342;
  --jic-ink-500: #3a4b7a;
  --jic-ink-300: #64748b;

  --jic-danger: #ef4444;
  --jic-warn: #f59e0b;
  --jic-ok: #10b981;

  --jic-card-shadow: 0 10px 30px rgba(37, 99, 235, .12), 0 2px 8px rgba(16, 24, 40, .06);
  --jic-card-shadow-hover: 0 14px 34px rgba(37, 99, 235, .18), 0 4px 12px rgba(16, 24, 40, .08);

  --jic-radius-lg: 18px;
  --jic-radius-md: 14px;
  --jic-radius-sm: 10px;
}

.jic-scope * {
  box-sizing: border-box;
}

/* ==========================================================================
 * 页面头部（玻璃态标题栏，jicart 标志性视觉）
 * ========================================================================== */
.jic-header {
  display: flex;
  align-items: center;
  gap: 16px;
  background: rgba(255, 255, 255, .92);
  border-radius: var(--jic-radius-lg, 18px);
  border: 1px solid rgba(37, 99, 235, .12);
  box-shadow: var(--jic-card-shadow, 0 10px 30px rgba(37, 99, 235, .12));
  padding: 18px 22px;
  margin-bottom: 16px;
}

.jic-header-icon {
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: linear-gradient(135deg, #60a5fa, #2563eb);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .6), 0 8px 20px rgba(37, 99, 235, .28);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: .5px;
}

.jic-header-text {
  flex: 1 1 auto;
  min-width: 0;
}

.jic-header-title {
  margin: 0;
  font-size: 22px;
  line-height: 1.3;
  font-weight: 700;
  color: var(--jic-ink-900, #0b1226);
  letter-spacing: .2px;
}

.jic-header-sub {
  margin: 4px 0 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--jic-ink-500, #3a4b7a);
  font-weight: 500;
}

.jic-header-sub * {
  max-width: 100%;
}

.jic-header-badge {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(59, 130, 246, .1);
  color: #1d4ed8;
  font-weight: 700;
  font-size: 12px;
  border: 1px solid rgba(59, 130, 246, .25);
  max-width: 40%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.jic-header-badge .dot {
  width: 8px;
  height: 8px;
  flex: 0 0 8px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #93c5fd, #1d4ed8);
  box-shadow: 0 0 10px rgba(59, 130, 246, .6);
}

/* 页头右侧搜索区 */
.jic-header-search {
  flex: 0 0 auto;
  width: 280px;
  max-width: 100%;
}

.jic-header-search .el-input__inner {
  height: 36px;
  line-height: 36px;
  border-radius: 10px;
}
.jic-notice {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: rgba(59, 130, 246, .05);
  border: 1px solid rgba(59, 130, 246, .12);
  border-radius: 12px;
  padding: 12px 16px;
  margin-bottom: 16px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--jic-brand-600, #2563eb);
}

.jic-notice > i {
  color: var(--jic-brand-500, #3b82f6);
  font-size: 15px;
  line-height: 1.7;
}

.jic-notice-con {
  flex: 1 1 auto;
  min-width: 0;
  word-break: break-word;
}

.jic-notice-con * {
  max-width: 100%;
}

/* ==========================================================================
 * 通用卡片 / 按钮 / 空态
 * ========================================================================== */
.jic-card {
  background: #fff;
  border: 1px solid rgba(37, 99, 235, .1);
  border-radius: var(--jic-radius-lg, 18px);
  box-shadow: var(--jic-card-shadow, 0 10px 30px rgba(37, 99, 235, .12));
}

.jic-btn {
  border-radius: 10px !important;
  font-weight: 600 !important;
}

.jic-btn.is-plain:hover,
.jic-btn.is-plain:focus {
  border-color: var(--jic-brand-500, #3b82f6) !important;
  color: var(--jic-brand-600, #2563eb) !important;
}

/* 主行动按钮（立即购买 / 去结算 / 提交订单） */
.jic-primary-btn.el-button {
  border: none !important;
  border-radius: 12px !important;
  background: linear-gradient(135deg, var(--jic-brand-500, #3b82f6), var(--jic-brand-700, #1d4ed8)) !important;
  color: #fff !important;
  font-weight: 600 !important;
  box-shadow: 0 8px 20px rgba(37, 99, 235, .3) !important;
  transition: transform .15s, box-shadow .2s, filter .2s;
}

.jic-primary-btn.el-button:hover:not(.is-disabled) {
  transform: translateY(-1px);
  box-shadow: 0 12px 26px rgba(37, 99, 235, .42) !important;
  filter: brightness(1.04);
}

.jic-primary-btn.el-button.is-disabled {
  opacity: .55;
  box-shadow: none !important;
}

.jic-empty {
  padding: 40px 0;
}

.jic-empty .el-empty__description p {
  color: var(--jic-ink-300, #64748b);
  font-size: 13px;
}

.jic-tips {
  text-align: center;
  color: var(--jic-ink-300, #64748b);
  font-size: 12px;
  padding: 12px 0 4px;
  margin: 0;
}

/* ==========================================================================
 * 商品（选购页）卡片
 * ========================================================================== */
.jic-goods-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 16px;
}

.jic-goods-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #ffffff 0%, #fafbff 100%);
  border: 1px solid rgba(59, 130, 246, .16);
  border-radius: var(--jic-radius-lg, 18px);
  padding: 16px;
  box-shadow: 0 4px 14px rgba(16, 24, 40, .05);
  transition: box-shadow .2s, transform .2s, border-color .2s;
  overflow: hidden;
}

.jic-goods-card:hover {
  border-color: rgba(59, 130, 246, .35);
  box-shadow: var(--jic-card-shadow-hover, 0 14px 34px rgba(37, 99, 235, .18));
  transform: translateY(-2px);
}

.jic-card-flag {
  position: absolute;
  top: 0;
  right: 0;
  padding: 4px 12px 5px;
  border-bottom-left-radius: 12px;
  background: var(--jic-brand-500, #3b82f6);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  max-width: 60%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  z-index: 2;
}

.jic-goods-desc {
  font-size: 13px;
  line-height: 1.7;
  color: var(--jic-ink-500, #3a4b7a);
  max-height: 92px;
  overflow: hidden;
  margin-bottom: 12px;
}

.jic-goods-desc * {
  max-width: 100%;
  font-size: 13px;
  line-height: 1.7;
}

.jic-goods-desc img {
  max-width: 100%;
  height: auto;
}

.jic-goods-body {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
}

.jic-goods-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
  min-height: 1px;
}

.jic-tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 6px;
  background: rgba(59, 130, 246, .1);
  color: var(--jic-brand-600, #2563eb);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.6;
  border: 1px solid rgba(59, 130, 246, .18);
}

.jic-tag.is-plain {
  background: #f1f5fb;
  color: var(--jic-ink-500, #3a4b7a);
  border-color: rgba(15, 23, 42, .06);
  cursor: default;
}

.jic-goods-name {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.jic-goods-name-text {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 16px;
  font-weight: 700;
  color: var(--jic-ink-900, #0b1226);
  line-height: 1.45;
  word-break: break-word;
}

.jic-goods-name.is-sold-out .jic-goods-name-text {
  color: var(--jic-ink-300, #64748b);
}

.jic-stock {
  flex: 0 0 auto;
  font-size: 11px;
  font-weight: 600;
  color: #92400e;
  background: linear-gradient(135deg, #fef3c7, #fde68a);
  padding: 3px 8px;
  border-radius: 8px;
  white-space: nowrap;
}

.jic-stock img {
  width: 44px;
  height: auto;
  display: block;
}

.jic-goods-active {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.jic-active-name {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 6px;
  background: rgba(245, 158, 11, .1);
  color: #b45309;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.6;
  cursor: default;
}

.jic-goods-price {
  display: flex;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 8px;
  margin: 4px 0 12px;
}

.jic-price {
  display: flex;
  align-items: baseline;
  color: #dc2626;
  font-weight: 700;
}

.jic-price-cur {
  font-size: 14px;
  margin-right: 1px;
}

.jic-price-num {
  font-size: 24px;
  line-height: 1.1;
}

.jic-price-cycle {
  font-size: 13px;
  color: var(--jic-ink-500, #3a4b7a);
  font-weight: 500;
  margin-left: 2px;
}

.jic-price-origin {
  font-size: 12px;
  color: var(--jic-ink-300, #64748b);
  text-decoration: line-through;
  line-height: 1.6;
}

.jic-goods-buy {
  margin-top: auto;
}

.jic-goods-buy .el-button {
  width: 100%;
  height: 38px;
  border-radius: 10px !important;
  font-weight: 600 !important;
}

/* ==========================================================================
 * 筛选条（一级 / 二级分组 + 搜索）
 * ========================================================================== */
.jic-filter {
  border: 1px solid rgba(37, 99, 235, .1);
  border-radius: var(--jic-radius-md, 14px);
  background: #fff;
  box-shadow: 0 4px 14px rgba(16, 24, 40, .04);
  padding: 14px 16px;
  margin-bottom: 16px;
}

.jic-filter-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 6px 0;
}

.jic-filter-label {
  flex: 0 0 auto;
  min-width: 62px;
  padding-top: 5px;
  font-size: 13px;
  font-weight: 600;
  color: var(--jic-ink-500, #3a4b7a);
}

.jic-chips {
  flex: 1 1 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
}

.jic-chip {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 999px;
  background: #f1f5fb;
  border: 1px solid rgba(15, 23, 42, .06);
  color: var(--jic-ink-700, #1a2342);
  font-size: 13px;
  line-height: 1.6;
  cursor: pointer;
  transition: all .18s;
  user-select: none;
}

.jic-chip:hover {
  background: rgba(59, 130, 246, .1);
  color: var(--jic-brand-600, #2563eb);
  border-color: rgba(59, 130, 246, .25);
}

.jic-chip.is-active {
  background: linear-gradient(135deg, var(--jic-brand-500, #3b82f6), var(--jic-brand-700, #1d4ed8));
  border-color: transparent;
  color: #fff;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(37, 99, 235, .28);
}

.jic-chips-empty {
  font-size: 13px;
  color: var(--jic-ink-300, #64748b);
  line-height: 1.9;
}

.jic-search {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0 2px;
  border-top: 1px dashed rgba(37, 99, 235, .12);
  margin-top: 6px;
}

.jic-search-input {
  flex: 1 1 auto;
  max-width: 420px;
}

.jic-search-input .el-input__inner {
  height: 38px;
  line-height: 38px;
  border-radius: 10px;
}

/* ==========================================================================
 * 购物车 / 结算页 商品条目
 * ========================================================================== */
.jic-cart-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.jic-cart-item {
  position: relative;
  background: linear-gradient(180deg, #ffffff 0%, #fafbff 100%);
  border: 1px solid rgba(59, 130, 246, .18);
  border-radius: var(--jic-radius-md, 14px);
  padding: 14px 16px 12px;
  box-shadow: 0 4px 14px rgba(16, 24, 40, .05);
  transition: box-shadow .2s, transform .2s, border-color .2s;
}

.jic-cart-item:hover {
  border-color: rgba(59, 130, 246, .35);
  box-shadow: 0 8px 22px rgba(37, 99, 235, .12);
  transform: translateY(-1px);
}

.jic-cart-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.jic-cart-head .el-checkbox {
  display: flex;
  align-items: flex-start;
  flex: 1 1 auto;
  min-width: 0;
  margin-right: 0;
}

.jic-cart-head .el-checkbox__label {
  flex: 1 1 auto;
  min-width: 0;
  word-break: break-word;
  white-space: normal;
  line-height: 1.5;
}

.jic-cart-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--jic-ink-900, #0b1226);
  line-height: 1.5;
  word-break: break-word;
}

.jic-cart-name.is-plain {
  flex: 1 1 auto;
  min-width: 0;
  padding-left: 24px;
}

.jic-cart-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.jic-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #f1f5fb;
  color: var(--jic-brand-600, #2563eb);
  cursor: pointer;
  transition: background .18s, color .18s, box-shadow .18s, transform .18s;
  font-size: 15px;
  line-height: 1;
}

.jic-icon-btn:hover {
  transform: translateY(-1px);
}

.jic-icon-btn.is-edit {
  background: rgba(59, 130, 246, .12);
  color: var(--jic-brand-600, #2563eb);
}

.jic-icon-btn.is-edit:hover {
  background: var(--jic-brand-500, #3b82f6);
  color: #fff;
  box-shadow: 0 4px 10px rgba(59, 130, 246, .3);
}

.jic-icon-btn.is-del {
  background: rgba(239, 68, 68, .1);
  color: var(--jic-danger, #ef4444);
}

.jic-icon-btn.is-del:hover {
  background: var(--jic-danger, #ef4444);
  color: #fff;
  box-shadow: 0 4px 10px rgba(239, 68, 68, .3);
}

/* ---------- 配置预览 ---------- */
.jic-cart-configs {
  padding: 6px 0 10px;
  border-top: 1px dashed #e2e8f0;
}

.jic-cart-config {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  font-size: 13px;
  line-height: 1.9;
  color: var(--jic-ink-700, #1a2342);
}

.jic-cfg-key {
  color: var(--jic-ink-300, #64748b);
  flex: 0 0 auto;
}

.jic-cfg-val {
  color: var(--jic-ink-900, #0b1226);
  word-break: break-word;
  text-align: right;
}

.jic-cfg-price {
  flex: 0 0 auto;
  margin-left: 10px;
  color: var(--jic-ink-700, #1a2342);
  font-weight: 500;
}

/* ---------- 价格区 ---------- */
.jic-cart-price {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 12px 24px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed #e2e8f0;
}

.jic-price-cell {
  min-width: 120px;
}

.jic-cell-label {
  font-size: 12px;
  color: var(--jic-ink-300, #64748b);
  margin-bottom: 4px;
}

.jic-cell-value {
  font-size: 13px;
  color: var(--jic-ink-900, #0b1226);
  line-height: 1.6;
}

.jic-cell-value .price {
  font-weight: 600;
}

.jic-cell-value .default-color {
  color: var(--jic-ink-300, #64748b);
}

.jic-cell-value.is-total {
  font-size: 18px;
  font-weight: 700;
  color: var(--jic-brand-600, #2563eb);
}

.jic-cell-value .original-price {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  font-weight: 400;
  color: var(--jic-ink-300, #64748b);
  text-decoration: line-through;
}

.jic-cell-value .discount-codeNumber {
  display: inline-block;
  margin-top: 4px;
  padding: 1px 8px;
  border-radius: 6px;
  background: rgba(245, 158, 11, .12);
  color: #b45309;
  font-size: 12px;
  font-weight: 600;
}

.jic-total-icon {
  margin-left: 4px;
  color: var(--jic-warn, #f59e0b);
  cursor: pointer;
  font-size: 14px;
}

.jic-qty-tip {
  margin: 4px 0 0;
  font-size: 12px;
  color: var(--jic-ink-300, #64748b);
}

.jic-qty-tip.red-text,
.jic-qty-tip.is-error {
  color: var(--jic-danger, #ef4444);
}

.jic-discount-box {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
}

.jic-cart-off {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 1px dashed rgba(239, 68, 68, .3);
  border-radius: 12px;
  background: rgba(239, 68, 68, .03);
}

.jic-off-text {
  flex: 1 1 auto;
  font-size: 13px;
  color: var(--jic-ink-500, #3a4b7a);
}

.jic-off-btn.el-button {
  border-radius: 10px !important;
  font-weight: 600 !important;
}

/* ---------- 底部结算条 ---------- */
.jic-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
  padding: 14px 18px;
  border-radius: var(--jic-radius-md, 14px);
  background: linear-gradient(135deg, #eef5ff 0%, #ffffff 100%);
  border: 1px solid rgba(59, 130, 246, .16);
  box-shadow: 0 -2px 14px rgba(37, 99, 235, .06);
}

.jic-footer-left {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 13px;
  color: var(--jic-ink-500, #3a4b7a);
}

.jic-footer-left .text-red {
  color: var(--jic-danger, #ef4444);
  font-weight: 700;
  margin: 0 2px;
}

.jic-footer-right {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
}

.jic-total-text {
  font-size: 13px;
  color: var(--jic-ink-500, #3a4b7a);
}

.jic-total-price {
  font-size: 24px;
  font-weight: 700;
  color: var(--jic-brand-600, #2563eb);
  margin-left: 4px;
}

.jic-check-btn.el-button {
  height: 42px;
  padding: 0 26px;
  border: none !important;
  border-radius: 12px !important;
  background: linear-gradient(135deg, var(--jic-brand-500, #3b82f6), var(--jic-brand-700, #1d4ed8)) !important;
  color: #fff !important;
  font-weight: 600 !important;
  font-size: 15px !important;
  box-shadow: 0 8px 20px rgba(37, 99, 235, .32) !important;
}

.jic-check-btn.el-button:hover:not(.is-disabled) {
  transform: translateY(-1px);
  box-shadow: 0 12px 26px rgba(37, 99, 235, .42) !important;
}

.jic-agree {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  color: var(--jic-ink-500, #3a4b7a);
}

.jic-agree .bule-text {
  color: var(--jic-brand-600, #2563eb);
  cursor: pointer;
}

/* ==========================================================================
 * 响应式
 * ========================================================================== */
@media (max-width: 768px) {
  .jic-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 16px;
  }

  .jic-header-badge {
    max-width: 100%;
    white-space: normal;
  }

  .jic-header-title {
    font-size: 19px;
  }

  .jic-goods-grid {
    grid-template-columns: 1fr;
  }

  .jic-header-search {
    width: 100%;
  }

  .jic-filter-label {
    min-width: 54px;
  }

  .jic-cart-price {
    gap: 10px 16px;
  }

  .jic-price-cell {
    min-width: 100px;
  }

  .jic-footer {
    flex-direction: column;
    align-items: stretch;
  }

  .jic-footer-right {
    justify-content: space-between;
  }

  .jic-check-btn.el-button {
    flex: 1 1 auto;
  }
}
