/* ============================================================
   ICE LOGIX — SHOPPING CART DESIGN SYSTEM
   Clean Mobile Ergonomics + Brand Ice-Glass Luxury (Cyan & Sapphire)
   ============================================================ */

.wb-cart-screen {
  padding-bottom: calc(160px + var(--tg-viewport-safe-area-inset-bottom, env(safe-area-inset-bottom, 0px))) !important;
  max-width: 480px;
  margin: 0 auto;
  position: relative;
  padding-left: 12px;
  padding-right: 12px;
  animation: none !important;
  transform: none !important;
  -webkit-transform: none !important;
  filter: none !important;
  perspective: none !important;
}

/* 1. Clean Cart Header */
.wb-cart-header {
  padding: 10px 0 12px 0;
}

.wb-cart-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wb-cart-title {
  font-size: 19px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.01em;
}

.wb-cart-count-badge {
  font-size: 12px;
  font-weight: 600;
  color: #00e5ff;
  background: rgba(0, 229, 255, 0.12);
  border: 1px solid rgba(0, 229, 255, 0.25);
  padding: 2px 8px;
  border-radius: 9999px;
}

/* 2. Bulk Action Bar (Select All, Wishlist, Share, Delete) */
.wb-bulk-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 2px 14px 2px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 12px;
}

.wb-select-all-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.9);
  cursor: pointer;
  user-select: none;
}

.wb-bulk-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.wb-action-icon-btn {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.7);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  touch-action: manipulation;
  transition: all 0.2s ease;
}

.wb-action-icon-btn:active {
  transform: scale(0.92);
  color: #00e5ff;
  border-color: rgba(0, 229, 255, 0.3);
  background: rgba(0, 229, 255, 0.1);
}

.wb-action-icon-btn.wb-trash-btn:active {
  color: #ff4d6d;
  border-color: rgba(255, 77, 109, 0.3);
  background: rgba(255, 77, 109, 0.1);
}

/* 3. Custom Round Checkbox (Ice Cyan Brand) */
.wb-checkbox {
  appearance: none;
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.05);
  cursor: pointer;
  position: relative;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
  margin: 0;
}

.wb-checkbox:checked {
  background: #00e5ff !important;
  border-color: #00e5ff !important;
  box-shadow: 0 0 12px rgba(0, 229, 255, 0.45) !important;
}

.wb-checkbox:checked::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 6px;
  width: 5px;
  height: 10px;
  border: solid #041019;
  border-width: 0 2.2px 2.2px 0;
  transform: rotate(45deg);
}

/* 4. Product Item Card (Ice-Glass Luxury Grid) */
.wb-cart-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.wb-cart-card {
  background: rgba(14, 20, 32, 0.75);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.wb-cart-card:active {
  border-color: rgba(0, 229, 255, 0.25);
}

.wb-card-main-row {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.wb-card-left {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  flex-shrink: 0;
  padding-top: 2px;
}

.wb-product-thumb-wrap {
  width: 76px !important;
  height: 102px !important;
  aspect-ratio: 3 / 4 !important;
  border-radius: 10px !important;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  position: relative;
  flex-shrink: 0;
}

.wb-product-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.wb-card-right {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-height: 102px;
  gap: 2px;
}

.wb-card-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.wb-card-header-line {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.wb-product-title {
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.92);
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: 1px;
}

.wb-card-actions-top {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-shrink: 0;
}

.wb-menu-btn {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.45);
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  cursor: pointer;
  touch-action: manipulation;
  transition: all 0.2s ease;
}

.wb-menu-btn:active {
  color: #00e5ff;
  background: rgba(0, 229, 255, 0.12);
  transform: scale(0.92);
}

.wb-item-remove-btn {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.4);
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  cursor: pointer;
  touch-action: manipulation;
  transition: all 0.2s ease;
}

.wb-item-remove-btn:active {
  color: #ff4d6d;
  background: rgba(255, 77, 109, 0.12);
}

.wb-product-variant {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.45);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 1px;
}

.wb-delivery-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
  margin-top: 3px;
}

.wb-delivery-date {
  font-size: 11px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
}

.wb-delivery-badge {
  font-size: 10px;
  font-weight: 500;
  color: #34d399;
}

.wb-card-bottom-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 6px;
}

.wb-buy-item-btn {
  height: 28px;
  padding: 0 14px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 700;
  background: rgba(0, 229, 255, 0.12);
  color: #00e5ff;
  border: 1px solid rgba(0, 229, 255, 0.25);
  cursor: pointer;
  transition: all 0.18s ease;
  touch-action: manipulation;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.wb-buy-item-btn:active {
  transform: scale(0.95);
  background: rgba(0, 229, 255, 0.25);
}

/* Bottom line: Price on left, Stepper on right */
.wb-card-bottom-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 6px;
  padding-top: 4px;
}

.wb-price-block {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.wb-current-price {
  font-size: 16px;
  font-weight: 800;
  color: #00e5ff;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}

.wb-old-price {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.35);
  text-decoration: line-through;
  font-variant-numeric: tabular-nums;
}

.wb-current-price .byn-sign,
.wb-old-price .byn-sign,
.wb-checkout-cta .byn-sign {
  height: 0.68em;
  vertical-align: -0.02em;
  margin-left: 2px;
  display: inline-block;
  aspect-ratio: 650 / 800;
  fill: currentColor;
}

/* Stepper Component */
.wb-stepper {
  display: inline-flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 9999px;
  padding: 2px 4px;
  gap: 2px;
}

.wb-stepper-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.85);
  font-size: 16px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  touch-action: manipulation;
  transition: all 0.15s ease;
}

.wb-stepper-btn:active {
  background: rgba(0, 229, 255, 0.2);
  color: #00e5ff;
  transform: scale(0.9);
}

.wb-stepper-value {
  font-size: 13px;
  font-weight: 700;
  color: #ffffff;
  padding: 0 4px;
  font-variant-numeric: tabular-nums;
  min-width: 20px;
  text-align: center;
}

/* 5. Sticky Bottom Checkout Bar (Permanently Fixed Above Navigation Tab Bar) */
.wb-sticky-dock {
  position: fixed !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 76px !important;
  z-index: 99 !important;
  pointer-events: auto !important;
  padding: 0 12px !important;
  display: flex !important;
  justify-content: center !important;
  transition: opacity 0.18s ease, transform 0.18s ease !important;
  will-change: transform, opacity;
}

.wb-sticky-dock.hidden {
  opacity: 0 !important;
  pointer-events: none !important;
  transform: translateY(20px) !important;
  display: none !important;
}

.wb-sticky-content {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  padding: 6px;
  background: rgba(10, 16, 28, 0.94);
  backdrop-filter: blur(24px) saturate(190%);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid rgba(0, 229, 255, 0.28);
  border-radius: 20px;
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.65), 0 0 24px rgba(0, 229, 255, 0.15);
}

.wb-checkout-cta {
  width: 100%;
  height: 48px;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  cursor: pointer;
  touch-action: manipulation;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
  background: linear-gradient(135deg, #00b4d8 0%, #00e5ff 100%);
  color: #041019;
}

.wb-checkout-cta.active {
  background: linear-gradient(135deg, #00b4d8 0%, #00e5ff 100%) !important;
  color: #041019 !important;
  box-shadow: 0 4px 18px rgba(0, 229, 255, 0.38);
}

.wb-checkout-cta.active:active {
  transform: scale(0.985);
  box-shadow: 0 2px 10px rgba(0, 229, 255, 0.5);
}

.wb-checkout-cta.disabled {
  background: rgba(255, 255, 255, 0.08) !important;
  color: rgba(255, 255, 255, 0.55) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  box-shadow: none !important;
  cursor: not-allowed;
}

/* 6. Context Action Sheet (••• menu) */
.wb-sheet-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(4, 10, 18, 0.72);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 120;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  animation: screenFadeIn 0.2s ease;
}

.wb-sheet-backdrop.closing {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.wb-sheet {
  background: #0d1522;
  border-top-left-radius: 24px;
  border-top-right-radius: 24px;
  border: 1px solid rgba(0, 229, 255, 0.2);
  border-bottom: none;
  padding: 12px 16px calc(24px + var(--tg-viewport-safe-area-inset-bottom, env(safe-area-inset-bottom, 0px))) 16px;
  max-width: 480px;
  margin: 0 auto;
  width: 100%;
  box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.6);
  animation: slideUp 0.24s cubic-bezier(0.16, 1, 0.3, 1);
}

.wb-sheet-handle {
  width: 36px;
  height: 4px;
  background: rgba(255, 255, 255, 0.25);
  border-radius: 2px;
  margin: 4px auto 14px auto;
}

.wb-sheet-title {
  font-size: 13px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.9);
  padding: 0 4px 12px 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 6px;
}

.wb-sheet-action {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 10px;
  background: transparent;
  border: none;
  border-radius: 12px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  touch-action: manipulation;
  transition: all 0.15s ease;
}

.wb-sheet-action:active {
  background: rgba(0, 229, 255, 0.1);
  color: #00e5ff;
}

.wb-sheet-action.danger {
  color: #ff4d6d;
}

.wb-sheet-action.danger:active {
  background: rgba(255, 77, 109, 0.12);
}

/* 7. Empty State */
.wb-empty-cart {
  text-align: center;
  padding: 56px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.wb-empty-icon-wrap {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: rgba(0, 229, 255, 0.08);
  border: 1px solid rgba(0, 229, 255, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  color: #00e5ff;
}

.wb-empty-title {
  font-size: 19px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 8px;
}

.wb-empty-desc {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.55);
  max-width: 280px;
  line-height: 1.45;
  margin-bottom: 22px;
}

.wb-empty-btn {
  background: linear-gradient(135deg, #00b4d8 0%, #00e5ff 100%);
  color: #041019;
  font-size: 14px;
  font-weight: 700;
  padding: 12px 28px;
  border-radius: 9999px;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(0, 229, 255, 0.35);
}

.wb-empty-btn:active {
  transform: scale(0.96);
}

