/* ========== 姜雪的小店 ========== */
.shop-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  flex-wrap: wrap;
  gap: 15px;
}

.shop-header .section-title {
  margin: 40px 0 0;
}

.shop-controls {
  display: flex;
  gap: 10px;
  align-items: center;
}

/* 商品网格 */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.product-card {
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  border: 2px solid rgba(255, 182, 217, 0.3);
  transition: all 0.3s ease;
  position: relative;
}

.product-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-large);
}

.product-image {
  width: 100%;
  height: 160px;
  background: linear-gradient(135deg, var(--pink-100), var(--purple-100));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 64px;
  overflow: hidden;
}

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

.product-info {
  padding: 15px;
}

.product-name {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-desc {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.5;
}

.product-price {
  font-family: 'ZCOOL KuaiLe', cursive;
  font-size: 20px;
  color: var(--pink-600);
  margin-bottom: 12px;
}

.product-actions {
  display: flex;
  gap: 6px;
}

.product-actions button {
  flex: 1;
  padding: 8px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  transition: all 0.3s ease;
}

.btn-add-cart {
  background: linear-gradient(135deg, var(--pink-300), var(--pink-400));
  color: white;
}

.btn-add-cart:hover {
  transform: scale(1.02);
}

.btn-edit {
  background: var(--purple-100);
  color: var(--purple-400);
}

.btn-edit:hover {
  background: var(--purple-200);
}

.btn-delete {
  background: #ffe0e0;
  color: #e85a94;
}

.btn-delete:hover {
  background: #ffc9c9;
}

.product-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: linear-gradient(135deg, #ff6b9d, #c44569);
  color: white;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 11px;
  z-index: 2;
}

/* 购物车 */
.cart-items {
  max-height: 320px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.cart-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--pink-50);
  border-radius: var(--radius-md);
}

.cart-item-image {
  width: 50px;
  height: 50px;
  border-radius: var(--radius-sm);
  background: var(--pink-100);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
  overflow: hidden;
}

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

.cart-item-info {
  flex: 1;
  min-width: 0;
}

.cart-item-name {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cart-item-price {
  font-size: 13px;
  color: var(--pink-600);
  font-weight: 500;
}

.cart-item-qty {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cart-item-qty button {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--pink-100);
  color: var(--pink-500);
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.cart-item-qty button:hover {
  background: var(--pink-200);
}

.cart-item-qty span {
  min-width: 20px;
  text-align: center;
  font-size: 14px;
}

.cart-item-remove {
  color: var(--text-muted);
  font-size: 18px;
  padding: 4px;
  transition: color 0.3s ease;
}

.cart-item-remove:hover {
  color: var(--pink-500);
}

.cart-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-muted);
  font-size: 14px;
}

.cart-empty-icon {
  font-size: 48px;
  margin-bottom: 10px;
}

.cart-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 0;
  border-top: 2px dashed var(--pink-100);
  font-size: 16px;
  margin-bottom: 15px;
}

.cart-total span:last-child {
  font-family: 'ZCOOL KuaiLe', cursive;
  font-size: 22px;
  color: var(--pink-600);
}

#checkoutBtn {
  width: 100%;
}

/* 主人模式标识 */
.master-mode-indicator {
  display: inline-block;
  padding: 4px 12px;
  background: linear-gradient(135deg, var(--purple-300), var(--pink-300));
  color: white;
  border-radius: 20px;
  font-size: 12px;
  margin-left: 10px;
  animation: glow 2s ease-in-out infinite;
}

@keyframes glow {
  0%, 100% { box-shadow: 0 0 5px rgba(197, 163, 255, 0.5); }
  50% { box-shadow: 0 0 15px rgba(197, 163, 255, 0.8); }
}

/* 主人信息 */
.master-info {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: linear-gradient(135deg, rgba(255,182,217,0.2), rgba(197,163,255,0.2));
  border-radius: 20px;
  border: 1px solid rgba(255, 182, 217, 0.4);
}

.master-avatar {
  font-size: 16px;
}

.master-name {
  font-family: 'ZCOOL KuaiLe', cursive;
  font-size: 13px;
  color: var(--pink-600);
}

/* 图片上传区域 */
.image-upload-area {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.image-preview {
  width: 100%;
  height: 140px;
  background: var(--pink-50);
  border: 2px dashed var(--pink-200);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.image-preview img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: var(--radius-sm);
}

.image-preview-placeholder {
  color: var(--text-muted);
  font-size: 13px;
}

.image-upload-options {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.upload-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  background: linear-gradient(135deg, var(--pink-300), var(--purple-300));
  color: white;
  border-radius: var(--radius-md);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
  box-shadow: var(--shadow-soft);
}

.upload-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-medium);
}

.upload-divider {
  color: var(--text-muted);
  font-size: 12px;
}

.url-input {
  flex: 1;
  min-width: 120px;
  padding: 10px 14px;
  border: 2px solid var(--pink-100);
  border-radius: var(--radius-md);
  font-size: 13px;
  transition: border-color 0.3s ease;
}

.url-input:focus {
  border-color: var(--pink-300);
}

/* 修改密码表单 */
.change-pass-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.change-pass-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  color: var(--text-secondary);
}

.change-pass-form input {
  padding: 12px 16px;
  border: 2px solid var(--pink-100);
  border-radius: var(--radius-md);
  font-size: 14px;
  transition: border-color 0.3s ease;
}

.change-pass-form input:focus {
  border-color: var(--pink-300);
}
