/* ==========================================================================
   Pages Styles - 页面专用样式
   ========================================================================== */

/* ==========================================================================
   Lucide Icons - SVG图标通用样式
   ========================================================================== */

.lucide {
  display: inline-block;
  vertical-align: middle;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

/* 图标大小变体 */
.lucide-sm {
  width: 16px;
  height: 16px;
}

.lucide-md {
  width: 20px;
  height: 20px;
}

.lucide-lg {
  width: 24px;
  height: 24px;
}

.lucide-xl {
  width: 32px;
  height: 32px;
}

/* 图标动画效果 */
.lucide-spin {
  animation: lucide-spin 1s linear infinite;
}

@keyframes lucide-spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

/* Toast 通知样式 */
.cart-toast {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(-20px);
  background: rgba(0, 0, 0, 0.85);
  color: white;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 14px;
  z-index: 10000;
  opacity: 0;
  transition: all 0.3s ease;
  pointer-events: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.cart-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* 图标填充效果（用于评分星星等） */
.star-filled {
  fill: #FFB800;
  stroke: #FFB800;
}

.star-empty {
  fill: none;
  stroke: #E0E0E0;
}

/* 无图片占位符 */
.no-image-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #F5F5F5;
  color: #999;
}

/* 图片懒加载占位效果 */
img[loading="lazy"] {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: img-loading 1.5s infinite;
}

img[loading="lazy"].loaded {
  animation: none;
  background: none;
}

@keyframes img-loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* ==========================================================================
   Common Page Header - 通用页面头部
   ========================================================================== */

.page-header {
  background: white;
  padding: 16px 16px 8px;
  text-align: center;
  border-bottom: 1px solid #EBEDF0;
}

.page-header-title {
  font-size: 20px;
  font-weight: 600;
  color: #323233;
  letter-spacing: 0.5px;
}

/* ==========================================================================
   Product Page - 商品详情页
   ========================================================================== */

.product-page {
  padding-bottom: 80px;
}

/* Product Gallery */
.product-gallery-slider {
  position: relative;
  background: var(--card-bg);
  margin-bottom: var(--spacing-md);
}

.gallery-wrapper {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

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

.gallery-item {
  flex-shrink: 0;
  width: 100%;
  aspect-ratio: 1;
  scroll-snap-align: start;
}

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

.gallery-dots {
  position: absolute;
  bottom: var(--spacing-md);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: var(--spacing-xs);
  padding: var(--spacing-xs) var(--spacing-md);
  background: rgba(0, 0, 0, 0.3);
  border-radius: var(--radius-xl);
}

.gallery-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  transition: all var(--transition-fast);
}

.gallery-dot.active {
  width: 20px;
  border-radius: 3px;
  background: #fff;
}

/* Product Info Section */
.product-info-section {
  margin: 0 var(--spacing-md) var(--spacing-md);
}

.product-title {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: var(--spacing-md);
  line-height: 1.4;
}

.product-price-section {
  margin-bottom: var(--spacing-md);
}

.price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--spacing-sm);
}

.price-label {
  font-size: 14px;
  color: var(--text-secondary);
}

.stock-status {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  padding: var(--spacing-sm) 0;
  margin-bottom: var(--spacing-md);
  font-size: 14px;
}

.in-stock {
  color: var(--success-color);
}

.out-of-stock {
  color: var(--error-color);
}

.stock-quantity {
  color: var(--text-muted);
}

.spec-selector-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--spacing-md);
  background: var(--bg-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  transition: background var(--transition-fast);
}

.spec-selector-btn:active {
  background: var(--border-color);
}

/* Product Reviews Summary */
.product-reviews-summary {
  margin: 0 var(--spacing-md) var(--spacing-md);
}

.reviews-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--spacing-md);
}

.reviews-header h3 {
  font-size: 16px;
  font-weight: 600;
}

.view-all-reviews {
  font-size: 14px;
  color: var(--primary-color);
}

.reviews-rating {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
}

.rating-score {
  font-size: 32px;
  font-weight: 700;
  color: var(--accent-color);
}

/* Product Description */
.product-description {
  margin: 0 var(--spacing-md) var(--spacing-md);
}

.product-description h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: var(--spacing-md);
}

.description-content {
  font-size: 14px;
  line-height: 1.8;
  color: var(--text-secondary);
}

.description-content img {
  margin: var(--spacing-md) 0;
  border-radius: var(--radius-md);
}

/* Product Actions Bar */
.product-actions-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  gap: var(--spacing-md);
  padding: var(--spacing-md);
  background: var(--card-bg);
  box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.1);
  z-index: 99;
  padding-bottom: max(var(--spacing-md), env(safe-area-inset-bottom));
}

.product-actions-bar .btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
}

.btn-add-to-cart {
  flex: 2;
}

/* Specification Selector Modal */
.spec-selector-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
}

.spec-selector-modal.active {
  display: block;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  animation: fadeIn var(--transition-base);
}

.modal-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  max-height: 80vh;
  background: var(--card-bg);
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  animation: slideUp var(--transition-base);
  overflow-y: auto;
}

.modal-header {
  position: sticky;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--spacing-md) var(--spacing-lg);
  background: var(--card-bg);
  border-bottom: 1px solid var(--border-color);
  z-index: 1;
}

.modal-header h3 {
  font-size: 18px;
  font-weight: 600;
}

.modal-close {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--bg-color);
}

.modal-body {
  padding: var(--spacing-lg);
}

.modal-footer {
  position: sticky;
  bottom: 0;
  padding: var(--spacing-md) var(--spacing-lg);
  background: var(--card-bg);
  border-top: 1px solid var(--border-color);
  padding-bottom: max(var(--spacing-md), env(safe-area-inset-bottom));
}

/* Spec Product Info */
.spec-product-info {
  display: flex;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-lg);
  border-bottom: 1px solid var(--border-color);
}

.spec-product-image {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-md);
  object-fit: cover;
}

.spec-product-details {
  flex: 1;
}

.spec-price {
  font-size: 20px;
  font-weight: 700;
  color: var(--secondary-color);
  margin-bottom: var(--spacing-xs);
}

.spec-stock {
  font-size: 14px;
  color: var(--text-muted);
}

/* Variations Form */
.variation-group {
  margin-bottom: var(--spacing-lg);
}

.variation-group label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: var(--spacing-md);
}

.variation-options {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-sm);
}

.variation-option {
  padding: var(--spacing-sm) var(--spacing-md);
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 14px;
  transition: all var(--transition-fast);
}

.variation-option.active {
  background: var(--primary-light);
  border-color: var(--primary-color);
  color: var(--primary-dark);
}

.variation-option.disabled {
  opacity: 0.3;
  pointer-events: none;
}

/* Quantity Group */
.quantity-group {
  margin-bottom: var(--spacing-lg);
}

.quantity-group label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: var(--spacing-md);
}

.quantity-selector {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.quantity-btn {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-color);
  font-size: 20px;
  font-weight: 600;
  color: var(--text-primary);
  transition: background var(--transition-fast);
}

.quantity-btn:active {
  background: var(--border-color);
}

.quantity-input {
  width: 60px;
  height: 40px;
  border: none;
  border-left: 1px solid var(--border-color);
  border-right: 1px solid var(--border-color);
  text-align: center;
  font-size: 16px;
  font-weight: 600;
}

/* ==========================================================================
   Cart Page - WeChat Mini Program Style
   ========================================================================== */

.cart-page {
  padding-bottom: 0;
  min-height: 100vh;
  background: white;
}

/* Empty Cart */
.empty-cart {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 24px 80px;
  background: white;
  text-align: center;
  min-height: calc(100vh - 65px);
}

.empty-icon-wrapper {
  width: 120px;
  height: 120px;
  background: linear-gradient(135deg, #F7F8FA 0%, #EBEDF0 100%);
  border-radius: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  color: #C8C9CC;
}

.empty-title {
  font-size: 18px;
  font-weight: 600;
  color: #323233;
  margin: 0 0 8px 0;
}

.empty-desc {
  font-size: 14px;
  color: #969799;
  margin: 0 0 24px 0;
  line-height: 1.6;
}

.empty-guest-hint {
  background: #FFF7E6;
  border: 1px solid #FFE7BA;
  border-radius: 8px;
  padding: 12px 16px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 320px;
  width: 100%;
}

.empty-guest-hint .hint-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.empty-guest-hint p {
  font-size: 13px;
  color: #646566;
  margin: 0;
  text-align: left;
  line-height: 1.5;
}

.empty-actions {
  display: flex;
  gap: 12px;
  width: 100%;
  max-width: 320px;
}

.btn-login-outline,
.btn-shop-primary {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 20px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-login-outline {
  background: white;
  color: #07C160;
  border: 1px solid #07C160;
}

.btn-login-outline:hover {
  background: #F0F9FF;
}

.btn-shop-primary {
  background: linear-gradient(135deg, #07C160 0%, #05AD56 100%);
  color: white;
  border: none;
  box-shadow: 0 2px 8px rgba(7, 193, 96, 0.3);
}

.btn-shop-primary:hover {
  opacity: 0.9;
}

.btn-shop-single {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: linear-gradient(135deg, #07C160 0%, #05AD56 100%);
  color: white;
  border: none;
  border-radius: 20px;
  padding: 12px 32px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 2px 8px rgba(7, 193, 96, 0.3);
}

.btn-shop-single:hover {
  opacity: 0.9;
}

.btn-shop-single:active,
.btn-shop-primary:active,
.btn-login-outline:active {
  transform: scale(0.98);
}

/* Legacy button styles for backward compatibility */
.empty-icon {
  font-size: 80px;
  margin-bottom: 16px;
  color: #C8C9CC;
}

.empty-text {
  font-size: 14px;
  color: #969799;
  margin-bottom: 24px;
}

.btn-shop {
  background: linear-gradient(135deg, #07C160 0%, #05AD56 100%);
  color: white;
  border: none;
  border-radius: 20px;
  padding: 12px 32px;
  font-size: 14px;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 2px 8px rgba(7, 193, 96, 0.3);
}

.btn-shop:hover {
  opacity: 0.9;
}

.btn-shop:active {
  transform: scale(0.98);
}

/* Cart Items Container */
.cart-items-container {
  background: white;
  min-height: calc(100vh - 65px); /* Account for bottom navigation height */
}

.cart-item {
  display: flex;
  padding: 16px;
  border-bottom: 1px solid #F7F8FA;
  position: relative;
  background: white;
  transition: background 0.2s;
}

.cart-item:last-child {
  border-bottom: none;
}

.cart-item:active {
  background: #FAFAFA;
}

.cart-checkbox {
  margin-right: 12px;
  margin-top: 12px;
}

.cart-checkbox input,
.item-checkbox {
  width: 20px;
  height: 20px;
  accent-color: #07C160;
  cursor: pointer;
}

.item-image {
  width: 90px;
  height: 90px;
  background: linear-gradient(135deg, #F7F8FA 0%, #EBEDF0 100%);
  border-radius: 8px;
  overflow: hidden;
  margin-right: 12px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #F2F3F5;
}

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

.item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.item-name {
  font-size: 14px;
  color: #323233;
  line-height: 1.4;
  margin-bottom: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}

.item-specs {
  font-size: 12px;
  color: #969799;
  margin-bottom: 8px;
}

.item-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.item-price {
  color: #EE0A24;
  font-size: 16px;
  font-weight: 600;
}

.quantity-stepper {
  display: flex;
  align-items: center;
  gap: 8px;
}

.stepper-btn {
  width: 24px;
  height: 24px;
  border: 1px solid #EBEDF0;
  border-radius: 50%;
  background: white;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #646566;
  transition: all 0.2s;
}

.stepper-btn:active {
  background: #F7F8FA;
}

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

.stepper-input {
  width: 50px;
  min-width: 50px;
  max-width: 60px;
  text-align: center;
  font-size: 14px;
  font-weight: 500;
  border: none;
  color: #323233;
  background: transparent;
  -webkit-appearance: none;
  -moz-appearance: textfield;
  appearance: textfield;
  padding: 0 2px;
}

.stepper-input::-webkit-inner-spin-button,
.stepper-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.item-delete {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  padding: 4px;
  color: #969799;
  transition: all 0.2s;
}

.item-delete:hover {
  color: #EE0A24;
}

/* Bottom Action Bar */
.action-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  border-top: 1px solid #EBEDF0;
  padding: 12px 16px;
  padding-bottom: calc(12px + env(safe-area-inset-bottom));
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Cart Page Specific Action Bar (above bottom navigation) */
.cart-action-bar {
  position: fixed;
  bottom: 78px; /* Position above bottom navigation - increased to fully avoid overlap with badge */
  left: 0;
  right: 0;
  background: white;
  border-top: 1px solid #EBEDF0;
  padding: 12px 16px;
  padding-bottom: 12px;
  z-index: 101; /* Higher than bottom navigation (100) */
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 -2px 12px rgba(0,0,0,0.08);
}

/* Add padding to cart items to prevent overlap */
.cart-page .cart-items-container {
  padding-bottom: 163px; /* Space for action bar (~50px) + navigation (78px) + buffer (35px) */
}

.select-all {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: #323233;
  cursor: pointer;
  user-select: none;
}

.select-all input {
  width: 20px;
  height: 20px;
  accent-color: #07C160;
  cursor: pointer;
}

.total-price-box {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.total-label {
  font-size: 12px;
  color: #969799;
}

.total-price {
  color: #EE0A24;
  font-size: 22px;
  font-weight: 700;
  line-height: 1;
}

.total-price .currency {
  font-size: 14px;
  font-weight: 500;
}

.checkout-btn {
  background: linear-gradient(135deg, #EE0A24 0%, #D90A21 100%);
  color: white;
  border: none;
  border-radius: 24px;
  padding: 12px 28px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(238, 10, 36, 0.3);
  margin-left: 12px;
}

.checkout-btn:active {
  opacity: 0.85;
  transform: scale(0.98);
  box-shadow: 0 1px 4px rgba(238, 10, 36, 0.3);
}

.checkout-btn.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  box-shadow: none;
}

.total-label {
  font-size: 14px;
  color: var(--text-secondary);
}

.total-amount {
  font-size: 20px;
  font-weight: 700;
  color: var(--secondary-color);
}

.btn-checkout {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
}

/* ==========================================================================
   Checkout Page - 结算页
   ========================================================================== */

.checkout-page {
  padding-bottom: var(--spacing-md);
}

/* Guest Checkout Notice */
.guest-checkout-notice {
  background: #FFF7E6;
  border: 1px solid #FFE7BA;
  border-radius: 8px;
  padding: 12px 16px;
  margin: 16px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.guest-checkout-notice .notice-icon {
  font-size: 20px;
  flex-shrink: 0;
  margin-top: 2px;
}

.guest-checkout-notice .notice-content {
  flex: 1;
}

.guest-checkout-notice p {
  margin: 0 0 8px 0;
  font-size: 14px;
  color: #646566;
  line-height: 1.5;
}

.guest-checkout-notice .notice-login-link {
  display: inline-block;
  color: #07C160;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  padding: 4px 12px;
  background: white;
  border-radius: 4px;
  transition: all 0.2s;
}

.guest-checkout-notice .notice-login-link:hover {
  opacity: 0.8;
}

/* Guest Order Tracking */
.guest-order-tracking {
  background: #F0F9FF;
  border: 1px solid #D4E8FC;
  border-radius: 8px;
  padding: 16px;
  margin: 16px 0;
}

.guest-order-tracking h3 {
  font-size: 16px;
  font-weight: 600;
  color: #323233;
  margin: 0 0 8px 0;
}

.guest-order-tracking p {
  font-size: 14px;
  color: #646566;
  line-height: 1.6;
  margin: 0 0 8px 0;
}

.guest-order-tracking .order-tracking-tip {
  font-size: 14px;
  color: #1989FA;
  margin: 0;
}

.checkout-section {
  margin: var(--spacing-md);
}

.checkout-section h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: var(--spacing-md);
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--spacing-md);
}

.btn-link {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  font-size: 14px;
  color: var(--primary-color);
}

/* Address Info */
.address-info {
  padding: var(--spacing-md);
  background: var(--bg-color);
  border-radius: var(--radius-md);
}

.address-details .address-name {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: var(--spacing-xs);
}

.address-phone {
  margin-left: var(--spacing-md);
  font-size: 14px;
  font-weight: normal;
  color: var(--text-secondary);
}

.address-full {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

.no-address {
  font-size: 14px;
  color: var(--text-muted);
  text-align: center;
  padding: var(--spacing-lg) 0;
}

/* Checkout Items */
.checkout-items {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
}

.checkout-item {
  display: flex;
  gap: var(--spacing-md);
}

.checkout-item-image {
  flex-shrink: 0;
  width: 60px;
  height: 60px;
  border-radius: var(--radius-md);
  overflow: hidden;
}

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

.checkout-item-details {
  flex: 1;
}

.checkout-item-name {
  font-size: 14px;
  font-weight: 500;
  margin-bottom: var(--spacing-xs);
}

.checkout-item-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 14px;
}

.checkout-item-quantity {
  color: var(--text-muted);
}

.checkout-item-price {
  font-weight: 600;
  color: var(--secondary-color);
}

/* Payment Methods */
.payment-methods {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

.payment-method {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  padding: var(--spacing-md);
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.payment-method input[type="radio"] {
  width: 20px;
  height: 20px;
}

.payment-icon {
  flex-shrink: 0;
}

.payment-label {
  flex: 1;
  font-size: 14px;
}

.payment-method input:checked ~ svg {
  color: var(--primary-color);
}

/* Order Notes */
.order-notes-input {
  width: 100%;
  padding: var(--spacing-md);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 14px;
  resize: vertical;
}

/* Order Summary */
.order-summary-bottom {
  margin: var(--spacing-md);
  padding: var(--spacing-md);
  background: var(--bg-color);
  border-radius: var(--radius-md);
}

.summary-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--spacing-sm) 0;
  font-size: 14px;
}

.summary-total {
  padding-top: var(--spacing-md);
  border-top: 1px solid var(--border-color);
  font-size: 16px;
  font-weight: 600;
}

.checkout-submit {
  padding: 0 var(--spacing-md) var(--spacing-md);
  padding-bottom: max(var(--spacing-md), env(safe-area-inset-bottom));
}

/* ==========================================================================
   My Account Page - 我的页面
   ========================================================================== */

.my-account-page {
  padding-bottom: var(--spacing-md);
}

/* User Profile Header */
.user-profile-header {
  display: flex;
  align-items: center;
  gap: var(--spacing-lg);
  margin: var(--spacing-md);
  padding: var(--spacing-lg);
}

.user-avatar-wrapper {
  position: relative;
}

.user-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  position: relative;
}

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

.avatar-upload-btn {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-color);
  color: #fff;
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
}

.user-info {
  flex: 1;
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
}

.user-name {
  font-size: 20px;
  font-weight: 600;
}

.btn-edit-name {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-color);
  border-radius: 50%;
  color: var(--text-secondary);
}

/* Order Status Section */
.order-status-section {
  margin: 0 var(--spacing-md) var(--spacing-md);
}

.section-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: var(--spacing-md);
}

.order-status-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--spacing-md);
}

.status-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-md) 0;
  text-align: center;
  position: relative;
}

.status-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-light);
  border-radius: 50%;
  color: var(--primary-dark);
}

.status-label {
  font-size: 12px;
  color: var(--text-secondary);
}

.status-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  background: var(--secondary-color);
  color: #fff;
  font-size: 10px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Service Section */
.service-section {
  padding: 0 var(--spacing-md);
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--spacing-md);
}

.service-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-md);
  padding: var(--spacing-lg);
  text-align: center;
  transition: transform var(--transition-fast);
}

.service-item:active {
  transform: scale(0.98);
}

.service-icon {
  width: 64px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-color);
  border-radius: 50%;
  color: var(--primary-color);
}

.service-label {
  font-size: 14px;
  font-weight: 500;
}

/* ==========================================================================
   Animations
   ========================================================================== */

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

@keyframes slideDown {
  from {
    transform: translateY(-100%);
  }
  to {
    transform: translateY(0);
  }
}

/* ==========================================================================
   PWA Install Prompt
   ========================================================================== */

.pwa-install-prompt {
  position: fixed;
  bottom: 80px;
  left: var(--spacing-md);
  right: var(--spacing-md);
  z-index: 999;
  animation: slideUp var(--transition-base);
}

.pwa-prompt-content {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  box-shadow: var(--shadow-lg);
}

.pwa-prompt-content h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: var(--spacing-sm);
}

.pwa-prompt-content p {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: var(--spacing-md);
}

.pwa-prompt-actions {
  display: flex;
  gap: var(--spacing-md);
}

.pwa-prompt-actions .btn {
  flex: 1;
}

/* ==========================================================================
   Notification - 通知提示
   ========================================================================== */

.notification {
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%) translateY(-100px);
  padding: var(--spacing-md) var(--spacing-lg);
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  z-index: 9999;
  opacity: 0;
  transition: all var(--transition-base);
  min-width: 280px;
  max-width: 90%;
}

.notification.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.notification.success {
  border-left: 4px solid var(--success-color);
}

.notification.error {
  border-left: 4px solid var(--error-color);
}

.notification.warning {
  border-left: 4px solid var(--warning-color);
}

.notification svg {
  flex-shrink: 0;
  color: var(--success-color);
}

.notification.error svg {
  color: var(--error-color);
}

.notification.warning svg {
  color: var(--warning-color);
}

/* ==========================================================================
   Search Results Dropdown - 搜索结果下拉
   ========================================================================== */

.search-results {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  max-height: 400px;
  overflow-y: auto;
  z-index: 999;
  display: none;
}

.search-results-list {
  padding: var(--spacing-sm);
}

.search-result-item {
  display: flex;
  gap: var(--spacing-md);
  padding: var(--spacing-md);
  border-radius: var(--radius-md);
  transition: background var(--transition-fast);
}

.search-result-item:hover {
  background: var(--bg-color);
}

.search-result-item img {
  width: 60px;
  height: 60px;
  border-radius: var(--radius-md);
  object-fit: cover;
}

.search-result-info {
  flex: 1;
}

.search-result-info h4 {
  font-size: 14px;
  font-weight: 500;
  margin-bottom: var(--spacing-xs);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.search-result-price {
  font-size: 14px;
  font-weight: 600;
  color: var(--secondary-color);
}

.no-results {
  padding: var(--spacing-lg);
  text-align: center;
  color: var(--text-muted);
}

/* ==========================================================================
   Category Filter - 分类筛选
   ========================================================================== */

.category-filter {
  margin: var(--spacing-md);
  padding: var(--spacing-md);
  overflow: hidden;
}

.filter-scroll {
  display: flex;
  gap: var(--spacing-sm);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: var(--spacing-xs);
}

.filter-scroll::-webkit-scrollbar {
  display: none;
}

.filter-btn {
  flex-shrink: 0;
  padding: var(--spacing-sm) var(--spacing-md);
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  font-size: 14px;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.filter-btn.active {
  background: var(--primary-color);
  border-color: var(--primary-color);
  color: #fff;
}

/* ==========================================================================
   Sort Filter Bar - 排序筛选栏
   ========================================================================== */

.sort-filter-bar {
  margin: 0 var(--spacing-md) var(--spacing-md);
  padding: var(--spacing-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.sort-btn {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-sm) var(--spacing-md);
  background: var(--bg-color);
  border-radius: var(--radius-md);
  font-size: 14px;
}

.filter-options {
  display: flex;
  gap: var(--spacing-sm);
}

.filter-option-btn {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: var(--spacing-sm) var(--spacing-md);
  background: var(--bg-color);
  border-radius: var(--radius-md);
  font-size: 14px;
}

/* Sort Dropdown */
.sort-dropdown {
  position: fixed;
  inset: 0;
  z-index: 1000;
}

.sort-dropdown-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
}

.sort-dropdown-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--card-bg);
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  padding: var(--spacing-lg);
  padding-bottom: max(var(--spacing-lg), env(safe-area-inset-bottom));
}

.sort-option {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--spacing-md);
  background: transparent;
  border-radius: var(--radius-md);
  font-size: 14px;
  text-align: left;
  transition: background var(--transition-fast);
}

.sort-option:hover {
  background: var(--bg-color);
}

.sort-option svg {
  opacity: 0;
  color: var(--primary-color);
  transition: opacity var(--transition-fast);
}

.sort-option.active svg {
  opacity: 1;
}

/* ==========================================================================
   Archive Page - 归档页
   ========================================================================== */

.archive-page .page-header {
  padding: var(--spacing-md) var(--spacing-lg);
  background: var(--card-bg);
  margin-bottom: var(--spacing-md);
}

.archive-description {
  margin-top: var(--spacing-sm);
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

.no-products-message {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--spacing-xl);
  text-align: center;
  grid-column: 1 / -1;
}

.no-products-message p {
  font-size: 16px;
  color: var(--text-muted);
  margin-bottom: var(--spacing-lg);
}

/* ==========================================================================
   Login Section - 登录区域
   ========================================================================== */

.login-section {
  margin: var(--spacing-md);
  padding: var(--spacing-lg);
}

.login-section h2 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: var(--spacing-lg);
  text-align: center;
}

.login-section .form-row {
  margin-bottom: var(--spacing-md);
}

.login-section label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: var(--spacing-sm);
}

.login-section input[type="text"],
.login-section input[type="password"],
.login-section input[type="email"] {
  width: 100%;
  padding: var(--spacing-md);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 14px;
}

.login-section .button {
  width: 100%;
  padding: var(--spacing-md);
  background: var(--primary-color);
  color: #fff;
  border: none;
  border-radius: var(--radius-md);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition-fast);
}

.login-section .button:hover {
  background: var(--primary-dark);
}

/* ==========================================================================
   Responsive Adjustments - 响应式调整
   ========================================================================== */

@media (max-width: 375px) {
  .products-grid {
    gap: var(--spacing-sm);
  }
  
  .product-card {
    font-size: 13px;
  }
  
  .service-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-sm);
  }
  
  .order-status-grid {
    gap: var(--spacing-sm);
  }
}

@media (min-width: 768px) {
  .container {
    max-width: 750px;
  }
  
  .products-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

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

/* ==========================================================================
   Category Page - 分类页面
   ========================================================================== */

.category-page {
  height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* Search Bar */
.search-bar {
  background: white;
  padding: 8px 16px;
  flex-shrink: 0;
  height: 54px;
  border-bottom: 1px solid #EBEDF0;
  display: flex;
  align-items: center;
}

.search-form {
  display: flex;
  align-items: center;
  width: 100%;
  gap: 8px;
  background: #F7F8FA;
  border-radius: 18px;
  padding: 8px 12px;
}

.search-icon {
  color: #969799;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.search-input {
  background: transparent;
  border: none;
  flex: 1;
  height: 22px;
  font-size: 14px;
  color: #323233;
  font-family: var(--font-family);
  outline: none;
}

.search-input::placeholder {
  color: #C8C9CC;
}

.search-input:focus {
  outline: none;
  background: #EBEDF0;
}

/* Main Container */
.main-container {
  height: calc(100vh - 54px);
  display: flex;
  overflow: hidden;
}

/* Category Sidebar */
.category-sidebar {
  width: 90px;
  background: #F7F8FA;
  overflow-y: auto;
  flex-shrink: 0;
}

.category-item {
  padding: 16px 12px;
  text-align: center;
  font-size: 14px;
  color: #646566;
  cursor: pointer;
  background: transparent;
  border-left: 3px solid transparent;
  transition: all 0.2s;
  user-select: none;
}

.category-item.active {
  background: white;
  color: #07C160;
  border-left-color: #07C160;
  font-weight: 500;
}

.category-item:hover {
  background: rgba(255,255,255,0.5);
}

/* Product Area */
.product-area {
  flex: 1;
  background: white;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

/* Product List */
.product-list {
  padding: 16px;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.product-card {
  background: #F7F8FA;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s;
}

.product-card:active {
  transform: scale(0.98);
}

.product-image {
  width: 100%;
  aspect-ratio: 1;
  background: #E6E6E6;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}

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

.product-info {
  padding: 12px;
}

.product-name {
  font-size: 14px;
  color: #323233;
  margin: 0 0 8px 0;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 1.4;
  min-height: 39px;
}

.product-price-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.product-price {
  color: #EE0A24;
  font-size: 16px;
  font-weight: 600;
}

.product-price .woocommerce-Price-amount {
  font-size: 16px;
}

.product-price .woocommerce-Price-currencySymbol {
  font-size: 12px;
  font-weight: normal;
}

.product-regular-price {
  color: #969799;
  font-size: 13px;
  text-decoration: line-through;
  font-weight: normal;
}

.product-regular-price .woocommerce-Price-amount {
  font-size: 13px;
}

.product-regular-price .woocommerce-Price-currencySymbol {
  font-size: 11px;
}

/* 分类页面专用 - 较小字体以适应百万级老挝币 */
.category-page .product-price-row {
  gap: 4px !important;
  flex-wrap: wrap !important;
}

.category-page .product-price {
  font-size: 13px !important;
  white-space: nowrap !important;
}

.category-page .product-price .woocommerce-Price-amount {
  font-size: 13px !important;
}

.category-page .product-price .woocommerce-Price-currencySymbol {
  font-size: 10px !important;
}

.category-page .product-regular-price {
  font-size: 10px !important;
  white-space: nowrap !important;
}

.category-page .product-regular-price .woocommerce-Price-amount {
  font-size: 10px !important;
}

.category-page .product-regular-price .woocommerce-Price-currencySymbol {
  font-size: 9px !important;
}

.product-tag {
  background: linear-gradient(135deg, #FF6034 0%, #EE0A24 100%);
  color: white;
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 3px;
  font-weight: normal;
}

.product-sales {
  font-size: 12px;
  color: #969799;
}

/* No Products */
.no-products {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 20px;
  text-align: center;
}

.no-products-icon {
  font-size: 64px;
  margin-bottom: 16px;
  opacity: 0.3;
}

.no-products-text {
  font-size: 14px;
  color: #969799;
  margin: 0;
}

/* ==========================================================================
   My Account Page - 我的页面
   ========================================================================== */

.my-account-page {
  background: #F7F8FA;
  min-height: 100vh;
  padding-bottom: 56px;
}

/* User Card */
.user-card {
  background: linear-gradient(135deg, #07C160 0%, #05AD56 100%);
  padding: 40px 16px 32px;
  color: white;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.user-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: rgba(255,255,255,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  margin: 0 auto 16px;
  overflow: hidden;
}

.user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.user-icon-placeholder {
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.user-icon-placeholder svg {
  width: 80px;
  height: 80px;
}

.user-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.user-name {
  font-size: 20px;
  font-weight: 600;
}

.edit-profile-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  background: rgba(255,255,255,0.2);
  border-radius: 16px;
  font-size: 13px;
  cursor: pointer;
  transition: background 0.2s;
}

.edit-profile-btn:hover {
  background: rgba(255,255,255,0.3);
}

.edit-profile-btn svg {
  flex-shrink: 0;
}

/* Order Section */
.order-section {
  background: white;
  padding: 16px;
  margin-top: 8px;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.section-title {
  font-size: 16px;
  font-weight: 600;
  color: #323233;
}

.section-more {
  font-size: 13px;
  color: #969799;
  cursor: pointer;
}

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

.order-item {
  text-align: center;
  cursor: pointer;
  padding: 8px;
  transition: background 0.2s;
  border-radius: 8px;
}

.order-item:active {
  background: #F7F8FA;
}

.order-icon-wrapper {
  position: relative;
  display: inline-block;
  margin-bottom: 8px;
}

.order-icon {
  font-size: 28px;
}

.order-badge {
  position: absolute;
  top: -4px;
  right: -8px;
  background: #EE0A24;
  color: white;
  font-size: 10px;
  padding: 2px 5px;
  border-radius: 10px;
  min-width: 16px;
  text-align: center;
  font-weight: 500;
}

.order-label {
  font-size: 13px;
  color: #646566;
}

/* Service Section */
.service-section {
  background: white;
  padding: 16px;
  margin-top: 8px;
}

.service-list {
  display: flex;
  flex-direction: column;
}

.service-section .service-item {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid #F7F8FA;
  cursor: pointer;
  transition: background 0.2s;
  text-align: left;
}

.service-section .service-item:last-child {
  border-bottom: none;
}

.service-section .service-section .service-item:active {
  background: #F7F8FA;
}

.service-section .service-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.service-section .service-icon {
  font-size: 22px;
  width: auto;
  height: auto;
  background: transparent;
  border-radius: 0;
}

.service-section .service-name {
  font-size: 14px;
  color: #323233;
}

.service-section .service-arrow {
  color: #C8C9CC;
  font-size: 16px;
}

/* Guest User Card */
.guest-user-card {
  background: linear-gradient(135deg, #07C160 0%, #05AD56 100%);
}

.guest-user-card .user-icon-placeholder {
  color: rgba(255, 255, 255, 0.9);
}

.guest-welcome-text {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.9);
  margin-top: 4px;
}

/* Guest Features Section */
.guest-features-section {
  background: white;
  padding: 16px;
  margin-top: 8px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.feature-card {
  background: #F7F8FA;
  border-radius: 8px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  transition: all 0.2s;
}

.feature-card:active {
  background: #EBEDF0;
  transform: scale(0.98);
}

.feature-icon {
  width: 48px;
  height: 48px;
  background: white;
  border-radius: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #07C160;
}

.feature-content {
  flex: 1;
}

.feature-title {
  font-size: 14px;
  font-weight: 600;
  color: #323233;
  margin: 0 0 4px 0;
}

.feature-desc {
  font-size: 12px;
  color: #969799;
  margin: 0;
  line-height: 1.4;
}

/* Guest Login Actions */
.guest-login-actions {
  padding: 16px;
  background: white;
  margin-top: 8px;
  display: flex;
  gap: 12px;
}

.btn-login-main,
.btn-register-outline {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 24px;
  border-radius: 24px;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-login-main {
  background: linear-gradient(135deg, #07C160 0%, #05AD56 100%);
  color: white;
  border: none;
  box-shadow: 0 4px 12px rgba(7, 193, 96, 0.3);
}

.btn-login-main:active {
  opacity: 0.85;
  transform: translateY(1px);
  box-shadow: 0 2px 8px rgba(7, 193, 96, 0.3);
}

.btn-register-outline {
  background: white;
  color: #07C160;
  border: 1px solid #07C160;
}

.btn-register-outline:active {
  background: #F0F9FF;
  transform: scale(0.98);
}

/* Guest Service Section */
.guest-service {
  margin-top: 8px;
}

/* Login Prompt (Legacy) */
.login-prompt {
  background: white;
  padding: 80px 20px;
  text-align: center;
  margin: 80px 16px 100px;
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  min-height: 300px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.login-prompt p {
  font-size: 15px;
  color: #646566;
  margin-bottom: 32px;
  line-height: 1.6;
  max-width: 280px;
}

.btn-login {
  display: inline-block;
  background: linear-gradient(135deg, #07C160 0%, #05AD56 100%);
  color: white;
  padding: 14px 48px;
  border-radius: 24px;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s;
  box-shadow: 0 4px 12px rgba(7, 193, 96, 0.3);
}

.btn-login:active {
  opacity: 0.85;
  transform: translateY(1px);
  box-shadow: 0 2px 8px rgba(7, 193, 96, 0.3);
}

/* ==========================================================================
   Product Detail Page - 商品详情页
   ========================================================================== */

.product-detail-page {
  background: #F7F8FA;
  padding-bottom: 70px;
}

/* Gallery Slider */
.product-gallery-slider {
  position: relative;
  background: white;
}

.gallery-wrapper {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

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

.gallery-item {
  flex-shrink: 0;
  width: 100%;
  aspect-ratio: 1;
  scroll-snap-align: start;
  display: flex;
  align-items: center;
  justify-content: center;
  background: white;
}

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

.gallery-indicator {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: rgba(0,0,0,0.5);
  color: white;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 12px;
}

/* Product Info Card */
.product-info-card {
  background: white;
  padding: 16px;
  margin-top: 8px;
}

.product-price-box {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.product-price-box .product-price {
  color: #EE0A24;
  font-size: 24px;
  font-weight: 700;
}

.product-price-box .product-price .woocommerce-Price-amount {
  font-size: 24px;
}

.product-price-box .product-price .woocommerce-Price-currencySymbol {
  font-size: 16px;
}

.product-badge {
  background: linear-gradient(135deg, #FF6034 0%, #EE0A24 100%);
  color: white;
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 3px;
}

.product-title {
  font-size: 16px;
  color: #323233;
  line-height: 1.5;
  margin: 0 0 8px 0;
  font-weight: 500;
}

.product-sales {
  font-size: 13px;
  color: #969799;
}

/* Spec Section */
.spec-section {
  background: white;
  padding: 0 16px;
  margin-top: 8px;
}

.spec-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  cursor: pointer;
  border-bottom: 1px solid #EBEDF0;
}

.spec-row:last-child {
  border-bottom: none;
}

.spec-label {
  font-size: 14px;
  color: #646566;
}

.spec-value {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  color: #323233;
}

.spec-arrow {
  color: #C8C9CC;
  font-size: 16px;
}

/* Detail Section */
.detail-section {
  background: white;
  padding: 16px;
  margin-top: 8px;
}

.detail-title {
  font-size: 16px;
  font-weight: 600;
  color: #323233;
  margin-bottom: 12px;
}

.detail-content {
  font-size: 14px;
  color: #646566;
  line-height: 1.6;
}

.detail-content img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  margin: 12px 0;
}

/* Review Section */
.review-section {
  background: white;
  padding: 16px;
  margin-top: 8px;
}

.review-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.review-title {
  font-size: 16px;
  font-weight: 600;
  color: #323233;
}

.review-count {
  font-size: 13px;
  color: #969799;
  cursor: pointer;
}

.review-item {
  padding: 12px 0;
  border-top: 1px solid #EBEDF0;
}

.review-item:first-of-type {
  border-top: none;
}

.review-user {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.review-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #E6E6E6;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.review-username {
  font-size: 14px;
  color: #323233;
  flex: 1;
}

.review-rating {
  font-size: 14px;
}

.review-content {
  font-size: 14px;
  color: #646566;
  line-height: 1.5;
}

.review-more {
  text-align: center;
  padding: 12px 0;
  color: #969799;
  font-size: 13px;
  cursor: pointer;
  border-top: 1px solid #EBEDF0;
}

.no-reviews {
  text-align: center;
  padding: 40px 0;
  color: #969799;
  font-size: 14px;
}

/* Action Bar (Product Detail) */
.product-detail-page .action-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  border-top: 1px solid #EBEDF0;
  display: flex;
  padding: 8px 16px;
  padding-bottom: calc(8px + env(safe-area-inset-bottom));
  z-index: 1000;
  gap: 12px;
}

.action-icon-group {
  display: flex;
  gap: 16px;
}

.action-icon {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  cursor: pointer;
  padding: 4px 8px;
}

.action-icon .icon {
  font-size: 20px;
  color: #646566;
}

.action-icon .icon-label {
  font-size: 11px;
  color: #646566;
}

.action-buttons {
  flex: 1;
  display: flex;
  gap: 8px;
}

.action-buttons .btn {
  flex: 1;
  border: none;
  border-radius: 20px;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.action-buttons .btn-cart {
  background: linear-gradient(135deg, #EE0A24 0%, #D90A21 100%);
  color: white;
}

.action-buttons .btn:active {
  opacity: 0.8;
  transform: scale(0.98);
}

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

/* ==========================================================================
   Home Page - 首页
   ========================================================================== */

.home-page {
  background: #F7F8FA;
  padding-bottom: 56px;
}

/* Store Name */
.store-name {
  background: white;
  padding: 16px 16px 8px;
  text-align: center;
}

.store-logo-img {
  height: 60px;
  width: auto;
  max-width: 200px;
  object-fit: contain;
}

.store-logo-text {
  font-size: 20px;
  font-weight: 600;
  color: #07C160;
  letter-spacing: 1px;
}

/* Search Bar */
.home-page .search-bar {
  position: sticky;
  top: 0;
  background: white;
  padding: 0 16px 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 12px;
}

.store-logo {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, #07C160 0%, #05AD56 100%);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 600;
  color: white;
  flex-shrink: 0;
}

.search-input-wrapper {
  flex: 1;
  position: relative;
}

.home-page .search-input {
  background: #F7F8FA;
  border: none;
  border-radius: 20px;
  padding: 10px 16px;
  width: 100%;
  font-size: 14px;
  color: #323233;
}

.home-page .search-input::placeholder {
  color: #C8C9CC;
}

.add-to-home-btn {
  width: 36px;
  height: 36px;
  background: #F7F8FA;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
  border: 1px solid #EBEDF0;
}

.add-to-home-btn:active {
  background: #EBEDF0;
  transform: scale(0.95);
}


/* ========================================
   Language Selector - 语言选择器
   ======================================== */

/* 语言选择按钮（替换原H按钮） */
.language-selector {
  width: 36px;
  height: 36px;
  background: #F7F8FA;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
  border: 1px solid #EBEDF0;
  user-select: none;
}

.language-selector:active {
  background: #EBEDF0;
  transform: scale(0.95);
}

.current-flag {
  line-height: 1;
}

/* 语言选择弹框遮罩层 */
.language-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex !important;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.language-modal-overlay.show {
  opacity: 1;
  pointer-events: auto;
}

/* 语言选择弹框 */
.language-modal {
  background: white;
  border-radius: 16px;
  width: 90%;
  max-width: 360px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  transform: scale(0.9);
  transition: transform 0.3s ease;
  overflow: hidden;
}

.language-modal-overlay.show .language-modal {
  transform: scale(1);
}

/* 弹框头部 */
.language-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px;
  border-bottom: 1px solid #EBEDF0;
}

.language-modal-header h3 {
  font-size: 18px;
  font-weight: 600;
  color: #323233;
  margin: 0;
}

.language-close-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #646566;
  background: transparent;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  padding: 0;
}

.language-close-btn:hover {
  background: #F7F8FA;
}

/* 语言选项列表 */
.language-options {
  padding: 8px;
}

.language-option {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s;
  user-select: none;
}

.language-option:hover {
  background: #F7F8FA;
}

.language-option:active {
  background: #EBEDF0;
}

.language-flag {
  font-size: 28px;
  line-height: 1;
  flex-shrink: 0;
}

.language-name {
  flex: 1;
  font-size: 16px;
  font-weight: 500;
  color: #323233;
}

.language-check {
  color: #07C160;
  display: none;
  flex-shrink: 0;
}

.language-option.active .language-check {
  display: block;
}

/* Banner Swiper */
.banner-swiper {
  position: relative;
  height: 180px;
  overflow: hidden;
  background: white;
}

.banner-container {
  display: flex;
  transition: transform 0.3s ease;
  height: 100%;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.banner-container::-webkit-scrollbar {
  display: none;
}

.banner-item {
  min-width: 100%;
  height: 100%;
  background: #E6E6E6;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  flex-shrink: 0;
  scroll-snap-align: start;
}

.banner-item a {
  display: block;
  width: 100%;
  height: 100%;
}

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

.banner-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
}

.dot {
  width: 6px;
  height: 6px;
  border-radius: 3px;
  background: rgba(255,255,255,0.5);
  transition: all 0.3s;
}

.dot.active {
  width: 16px;
  background: white;
}

/* Category Navigation */
.category-nav {
  background: white;
  padding: 16px 0;
  position: relative;
  overflow: hidden;
}

.category-wrapper {
  display: flex;
  align-items: center;
  position: relative;
}

.category-scroll {
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
  flex: 1;
  padding: 0 16px;
  margin-right: 72px; /* Space for fixed button */
}

.category-scroll::-webkit-scrollbar {
  display: none;
}

.category-list {
  display: flex;
  gap: 24px;
  padding-bottom: 4px;
}

.category-item {
  text-align: center;
  flex-shrink: 0;
  cursor: pointer;
}

.category-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 8px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  transition: transform 0.2s;
}

/* 只给默认图标添加背景色 */
.category-icon:not(:has(img)) {
  background: linear-gradient(135deg, #FFE6E6 0%, #FFD6D6 100%);
}

.category-item:active .category-icon {
  transform: scale(0.95);
}

/* 自定义图标样式 */
.category-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 50%;
}

/* 移除按索引的背景色配置 - 使用默认统一背景 */
.category-item:nth-child(2) .category-icon:not(:has(img)) {
  background: linear-gradient(135deg, #E6F7FF 0%, #D6EFFF 100%);
}

.category-item:nth-child(3) .category-icon:not(:has(img)) {
  background: linear-gradient(135deg, #FFF7E6 0%, #FFEFD6 100%);
}

.category-item:nth-child(4) .category-icon:not(:has(img)) {
  background: linear-gradient(135deg, #F0E6FF 0%, #E6D6FF 100%);
}

.category-item:nth-child(5) .category-icon:not(:has(img)) {
  background: linear-gradient(135deg, #E6FFF7 0%, #D6FFEF 100%);
}

.category-item:nth-child(6) .category-icon:not(:has(img)) {
  background: linear-gradient(135deg, #FFE6F0 0%, #FFD6E6 100%);
}

.category-item:nth-child(7) .category-icon:not(:has(img)) {
  background: linear-gradient(135deg, #F0FFE6 0%, #E6FFD6 100%);
}

.category-item:nth-child(8) .category-icon:not(:has(img)) {
  background: linear-gradient(135deg, #E6F0FF 0%, #D6E6FF 100%);
}

.category-name {
  font-size: 12px;
  color: #646566;
  white-space: nowrap;
}

/* Fixed All Category Button */
.fixed-all-category {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.95) 15%, rgba(255,255,255,1) 25%, rgba(255,255,255,1) 100%);
  padding-left: 24px;
  padding-right: 16px;
}

.all-category-item {
  text-align: center;
  flex-shrink: 0;
  cursor: pointer;
}

.all-category-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 8px;
  background: linear-gradient(135deg, #07C160 0%, #05AD56 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: white;
  box-shadow: 0 2px 8px rgba(7, 193, 96, 0.3);
  transition: all 0.2s;
}

.all-category-item:active .all-category-icon {
  transform: scale(0.95);
}

.all-category-name {
  font-size: 12px;
  color: #07C160;
  white-space: nowrap;
  font-weight: 500;
}

/* Product Section */
.product-section {
  padding: 12px 16px 0;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.section-title {
  font-size: 16px;
  font-weight: 600;
  color: #323233;
  margin: 0;
}

/* Product Grid (Home) - reuse category page styles */
.home-page .product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.home-page .product-card {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s;
}

.home-page .product-card:active {
  transform: scale(0.98);
}

.home-page .product-image {
  width: 100%;
  aspect-ratio: 1;
  background: #F7F8FA;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

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

.home-page .product-info {
  padding: 12px;
}

.home-page .product-name {
  font-size: 14px;
  color: #323233;
  margin: 0 0 8px 0;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 1.4;
  min-height: 39px;
}

.home-page .product-price-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.home-page .product-price {
  color: #EE0A24;
  font-size: 18px !important;
  font-weight: 700;
}

.home-page .product-price .woocommerce-Price-amount {
  font-size: 18px !important;
}

.home-page .product-price .woocommerce-Price-currencySymbol {
  font-size: 14px !important;
}

.home-page .product-regular-price {
  color: #969799;
  font-size: 13px !important;
  text-decoration: line-through;
  font-weight: normal;
}

.home-page .product-regular-price .woocommerce-Price-amount {
  font-size: 13px !important;
}

.home-page .product-regular-price .woocommerce-Price-currencySymbol {
  font-size: 11px;
}

.home-page .product-tag {
  background: linear-gradient(135deg, #FF6034 0%, #EE0A24 100%);
  color: white;
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 3px;
}

.home-page .product-sales {
  font-size: 12px;
  color: #969799;
}

.home-page .no-products {
  text-align: center;
  padding: 40px 20px;
  color: #969799;
  font-size: 14px;
}

/* ==========================================================================
   Checkout Page - 结算页面
   ========================================================================== */

.checkout-page {
  background: #F7F8FA;
  padding-bottom: 80px;
}

/* Navigation Bar */
.nav-bar {
  position: sticky;
  top: 0;
  background: white;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  z-index: 100;
}

.nav-back {
  font-size: 20px;
  cursor: pointer;
  color: #323233;
}

.nav-title {
  flex: 1;
  text-align: center;
  font-size: 16px;
  font-weight: 500;
  color: #323233;
}

.nav-placeholder {
  width: 20px;
}

/* Address Section */
.address-section {
  background: white;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}

.address-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.address-info {
  flex: 1;
}

.address-top {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.address-name {
  font-size: 15px;
  font-weight: 500;
  color: #323233;
}

.address-phone {
  font-size: 14px;
  color: #646566;
}

.address-detail {
  font-size: 13px;
  color: #969799;
  line-height: 1.4;
}

.address-arrow {
  color: #C8C9CC;
  font-size: 20px;
  flex-shrink: 0;
}

/* Product Section */
.checkout-page .product-section {
  background: white;
  margin-top: 8px;
}

.checkout-page .section-header {
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid #F7F8FA;
}

.store-icon {
  font-size: 18px;
}

.store-name {
  font-size: 14px;
  color: #323233;
  font-weight: 500;
}

.product-list {
  display: flex;
  flex-direction: column;
}

.checkout-page .product-item {
  display: flex;
  padding: 16px;
  border-bottom: 1px solid #F7F8FA;
}

.checkout-page .product-item:last-child {
  border-bottom: none;
}

.checkout-page .product-image {
  width: 80px;
  height: 80px;
  background: #F2F3F5;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  margin-right: 12px;
  overflow: hidden;
  flex-shrink: 0;
}

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

.checkout-page .product-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.checkout-page .product-name {
  font-size: 14px;
  color: #323233;
  line-height: 1.4;
  margin-bottom: 4px;
}

.product-spec {
  font-size: 12px;
  color: #969799;
  margin-bottom: 8px;
}

.product-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.checkout-page .product-price {
  color: #323233;
  font-size: 14px;
}

.product-qty {
  font-size: 14px;
  color: #969799;
}

/* Payment Section */
.payment-section {
  background: white;
  padding: 16px;
  margin-top: 8px;
}

.checkout-page .section-title {
  font-size: 15px;
  font-weight: 500;
  color: #323233;
  margin-bottom: 12px;
}

.payment-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.payment-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
  background: #F7F8FA;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid transparent;
}

.payment-item.active {
  background: #E6F9F0;
  border-color: #07C160;
}

.payment-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.payment-icon {
  font-size: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.payment-icon img {
  max-height: 30px;
  max-width: 100px;
  height: auto;
  width: auto;
  object-fit: contain;
}

.payment-name {
  font-size: 14px;
  color: #323233;
}

.payment-radio {
  display: none;
}

.payment-check {
  width: 20px;
  height: 20px;
  border: 2px solid #C8C9CC;
  border-radius: 50%;
  transition: all 0.2s;
  position: relative;
}

.payment-item.active .payment-check {
  background: #07C160;
  border-color: #07C160;
}

.payment-item.active .payment-check::after {
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 12px;
}

/* Coupon Section */
.coupon-section {
  background: white;
  padding: 16px;
  margin-top: 8px;
}

.coupon-input-wrapper {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.coupon-input {
  flex: 1;
  border: 1px solid #EBEDF0;
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 14px;
  color: #323233;
}

.coupon-input::placeholder {
  color: #C8C9CC;
}

.coupon-btn {
  background: linear-gradient(135deg, #EE0A24 0%, #D90A21 100%);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
}

.coupon-btn:disabled {
  background: #C8C9CC;
  cursor: not-allowed;
}

.applied-coupons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.coupon-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #FFF4E5;
  border: 1px solid #FFD700;
  border-radius: 16px;
  padding: 6px 12px;
  font-size: 13px;
  color: #FF8C00;
}

.coupon-code {
  font-weight: 500;
}

.remove-coupon {
  background: none;
  border: none;
  color: #FF8C00;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  margin: 0;
  width: 16px;
  height: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Remark Section */
.remark-section {
  background: white;
  padding: 16px;
  margin-top: 8px;
}

.remark-input {
  width: 100%;
  border: 1px solid #EBEDF0;
  border-radius: 8px;
  padding: 12px;
  font-size: 14px;
  resize: none;
  font-family: inherit;
  color: #323233;
}

.remark-input::placeholder {
  color: #C8C9CC;
}

.remark-input:focus {
  outline: none;
  border-color: #07C160;
}

/* Cost Section */
.cost-section {
  background: white;
  padding: 16px;
  margin-top: 8px;
}

.cost-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
}

.cost-label {
  font-size: 14px;
  color: #646566;
}

.cost-value {
  font-size: 14px;
  color: #323233;
}

.cost-value.discount {
  color: #07C160;
}

.cost-row.total-row {
  padding-top: 12px;
  border-top: 1px dashed #EBEDF0;
  margin-top: 8px;
}

.cost-label.total {
  font-size: 15px;
  font-weight: 500;
  color: #323233;
}

.cost-value.total {
  font-size: 18px;
  font-weight: 600;
  color: #EE0A24;
}

/* Bottom Action Bar */
.checkout-page .action-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  border-top: 1px solid #EBEDF0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  padding-bottom: calc(12px + env(safe-area-inset-bottom));
  z-index: 1000;
  gap: 16px;
}

.total-box {
  flex: 1;
}

.total-label {
  font-size: 12px;
  color: #646566;
  margin-bottom: 4px;
}

.checkout-page .total-price {
  font-size: 20px;
  font-weight: 700;
  color: #EE0A24;
}

.submit-btn {
  background: linear-gradient(135deg, #EE0A24 0%, #D90A21 100%);
  color: white;
  border: none;
  border-radius: 20px;
  padding: 12px 32px;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.submit-btn:active {
  opacity: 0.8;
  transform: scale(0.98);
}

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

/* ==========================================================================
   Product Specs Popup - 规格选择弹窗
   ========================================================================== */

.spec-popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 9999;
  display: flex;
  align-items: flex-end;
}

.spec-popup {
  background: white;
  border-radius: 16px 16px 0 0;
  width: 100%;
  max-height: 80vh;
  overflow-y: auto;
  animation: slideUp 0.3s ease;
  position: relative;
}

@keyframes slideUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

.close-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 28px;
  height: 28px;
  background: #F7F8FA;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 20px;
  color: #969799;
  z-index: 10;
}

.close-btn:hover {
  background: #EBEDF0;
}

/* Product Info in Popup */
.product-info-spec {
  display: flex;
  gap: 16px;
  padding: 20px 16px;
  border-bottom: 1px solid #F7F8FA;
}

.product-image-spec {
  width: 100px;
  height: 100px;
  background: #F7F8FA;
  border-radius: 8px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

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

.product-details-spec {
  flex: 1;
}

.product-price-spec {
  font-size: 24px;
  color: #EE0A24;
  font-weight: 600;
  margin-bottom: 8px;
}

.product-stock-spec {
  font-size: 13px;
  color: #969799;
  margin-bottom: 8px;
}

.product-selected-spec {
  font-size: 13px;
  color: #646566;
  line-height: 1.5;
}

/* Spec Selection in Popup */
.spec-section-popup {
  padding: 16px;
  border-bottom: 1px solid #F7F8FA;
}

.spec-title-popup {
  font-size: 14px;
  color: #323233;
  font-weight: 600;
  margin-bottom: 12px;
}

.spec-options-popup {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.spec-option-popup {
  padding: 8px 16px;
  border: 1px solid #EBEDF0;
  border-radius: 4px;
  font-size: 13px;
  color: #646566;
  background: white;
  cursor: pointer;
  transition: all 0.2s;
  user-select: none;
}

.spec-option-popup:hover {
  border-color: #07C160;
}

.spec-option-popup.active {
  background: #E8F5EF;
  border-color: #07C160;
  color: #07C160;
  font-weight: 500;
}

.spec-option-popup.disabled {
  background: #F7F8FA;
  color: #C8C9CC;
  cursor: not-allowed;
  border-color: #EBEDF0;
}

/* 缺货规格样式 */
.spec-option-popup.out-of-stock {
  position: relative;
  background: #F7F8FA;
  color: #C8C9CC;
  cursor: not-allowed;
  border-color: #EBEDF0;
  opacity: 0.7;
}

.spec-option-popup.out-of-stock::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: #C8C9CC;
  transform: rotate(-15deg);
}

.spec-option-popup .stock-badge {
  display: inline-block;
  font-size: 10px;
  color: #ee4d2d;
  margin-left: 4px;
  font-weight: 500;
}

/* 分享按钮样式 */
.product-share-section {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #f0f0f0;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: #F7F8FA;
  border: 1px solid #EBEDF0;
  border-radius: 20px;
  font-size: 13px;
  color: #646566;
  cursor: pointer;
  transition: all 0.2s;
}

.share-btn:hover {
  background: #E8F5EF;
  border-color: #07C160;
  color: #07C160;
}

.share-btn svg {
  width: 18px;
  height: 18px;
}

/* Quantity Selection in Popup */
.quantity-section-popup {
  padding: 16px;
  border-bottom: 1px solid #F7F8FA;
}

.quantity-row-popup {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.quantity-label-popup {
  font-size: 14px;
  color: #323233;
  font-weight: 600;
}

.quantity-stepper-popup {
  display: flex;
  align-items: center;
  gap: 12px;
}

.quantity-stepper-popup .stepper-btn {
  width: 32px;
  height: 32px;
  border: 1px solid #EBEDF0;
  border-radius: 50%;
  background: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 18px;
  color: #646566;
  transition: all 0.2s;
}

.quantity-stepper-popup .stepper-btn:active {
  background: #F7F8FA;
}

.quantity-stepper-popup .stepper-btn.disabled {
  background: #F7F8FA;
  color: #C8C9CC;
  cursor: not-allowed;
}

.quantity-stepper-popup .stepper-input {
  width: 50px;
  text-align: center;
  border: none;
  font-size: 16px;
  color: #323233;
  font-weight: 500;
  background: transparent;
}

/* Action Bar in Popup */
.action-bar-popup {
  padding: 12px 16px 20px;
  background: white;
}

.action-buttons-popup {
  display: flex;
  gap: 12px;
}

.btn-cart-popup {
  flex: 1;
  height: 48px;
  border-radius: 24px;
  border: none;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  background: linear-gradient(135deg, #FF6034 0%, #EE0A24 100%);
  color: white;
}

.btn-cart-popup:active {
  opacity: 0.8;
  transform: scale(0.98);
}

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

/* ==========================================================================
   Profile Editor Modal
   ========================================================================== */

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 9999;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.modal-container {
  background: white;
  width: 100%;
  max-width: 600px;
  border-radius: 16px 16px 0 0;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #EBEDF0;
}

.modal-title {
  font-size: 17px;
  font-weight: 600;
  color: #323233;
}

.modal-close {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: #969799;
  cursor: pointer;
  border-radius: 50%;
  transition: background 0.2s;
}

.modal-close:hover {
  background: #F7F8FA;
}

.modal-body {
  padding: 20px;
  overflow-y: auto;
}

.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 14px;
  color: #646566;
  margin-bottom: 8px;
  font-weight: 500;
}

.form-input {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #EBEDF0;
  border-radius: 8px;
  font-size: 15px;
  color: #323233;
  background: #F7F8FA;
  transition: all 0.2s;
}

.form-input:focus {
  outline: none;
  border-color: #07C160;
  background: white;
}

.avatar-upload {
  display: flex;
  align-items: center;
  gap: 16px;
}

.avatar-preview {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  background: #F7F8FA;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

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

.btn-upload-avatar {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  background: #07C160;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-upload-avatar:hover {
  background: #06AD56;
}

.btn-upload-avatar svg {
  flex-shrink: 0;
}

.form-actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}

.btn-cancel,
.btn-save {
  flex: 1;
  height: 44px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
}

.btn-cancel {
  background: #F7F8FA;
  color: #646566;
}

.btn-cancel:hover {
  background: #EBEDF0;
}

.btn-save {
  background: #07C160;
  color: white;
}

.btn-save:hover {
  background: #06AD56;
}

.btn-save:active,
.btn-cancel:active {
  transform: scale(0.98);
}
