.ppc-anim-flip {
  animation: ppc-flip var(--ppc-anim-duration, 0.3s) ease-in-out;
}

.ppc-slider-wrap {
  position: relative;
  display: block;
  overflow: hidden; /* Contains the absolute elements */
}

/* --- Premium Slider Controls --- */
.ppc-slider-controls {
  /* Override default boxy look with Glassmorphism Pill */
  background: rgba(255, 255, 255, 0.85) !important;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.5) !important;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  padding: 4px 12px !important;
  border-radius: 999px !important;
  transition: all 0.2s ease;
}
.ppc-slider-controls:hover {
  background: rgba(255, 255, 255, 0.95) !important;
  transform: translateX(-50%) scale(1.02) !important;
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
}

/* --- Premium Bottom Sheet UI --- */
.ppc-bottom-sheet-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.3);
  z-index: 90;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}
.ppc-bottom-sheet-overlay.open {
  opacity: 1;
  visibility: visible;
}

.ppc-bottom-sheet {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: #fff;
  border-radius: 24px 24px 0 0;
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.19, 1, 0.22, 1); /* iOS-like spring */
  z-index: 100;
  padding: 12px 24px 32px 24px;
  box-shadow: 0 -10px 40px rgba(0,0,0,0.15);
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  max-height: 85%;
  overflow-y: auto;
}
.ppc-bottom-sheet.open {
  transform: translateY(0);
}

/* Handle */
.ppc-sheet-handle-bar {
  width: 100%;
  display: flex;
  justify-content: center;
  padding-bottom: 20px;
  cursor: grab;
}
.ppc-sheet-handle {
  width: 40px;
  height: 5px;
  background: #e5e7eb;
  border-radius: 10px;
}

/* Layout Grid */
.ppc-sheet-grid {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 16px;
  margin-bottom: 24px;
  align-items: start;
}

/* Thumbnail */
.ppc-sheet-thumb-wrap {
  width: 80px;
  height: 80px;
  border-radius: 12px;
  overflow: hidden;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
}
.ppc-sheet-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Info */
.ppc-sheet-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.ppc-sheet-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #111827;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.ppc-sheet-price {
  font-size: 18px;
  font-weight: 700;
  color: #111827;
  margin-top: 4px;
}

/* Actions Row */
.ppc-sheet-actions {
  display: flex;
  gap: 12px;
  align-items: center;
}

/* Custom Stepper */
.ppc-qty-stepper {
  display: flex;
  align-items: center;
  background: #f3f4f6;
  border-radius: 12px;
  padding: 4px;
  height: 48px;
  box-sizing: border-box;
}
.ppc-qty-btn {
  width: 32px;
  height: 100%;
  border: none;
  background: transparent;
  font-size: 18px;
  font-weight: 600;
  color: #374151;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  transition: background 0.2s;
}
.ppc-qty-btn:hover {
  background: rgba(0,0,0,0.05);
  color: #000;
}
.ppc-qty-val {
  width: 30px;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  color: #111;
  font-variant-numeric: tabular-nums;
}

/* Add to Cart Button */
.ppc-sheet-atc {
  flex: 1;
  height: 48px;
  background: #111827;
  color: #ffffff;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.ppc-sheet-atc:hover {
  background: #000000;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.2);
}
.ppc-sheet-atc:active {
  transform: translateY(1px);
}

/* Close Button (Absolute) */
.ppc-sheet-close-abs {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 30px;
  height: 30px;
  background: #f3f4f6;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  color: #6b7280;
  font-size: 18px;
  transition: all 0.2s;
}
.ppc-sheet-close-abs:hover {
  background: #e5e7eb;
  color: #111;
}

/* Shop Builder CSS */
.ppc-sb-grid {
    display: grid;
    gap: 20px;
}
.ppc-sb-card {
    display: flex;
    flex-direction: column;
}
@media (max-width: 768px) {
    .ppc-sb-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}
@media (max-width: 480px) {
    .ppc-sb-grid {
        grid-template-columns: 1fr !important;
    }
}

/* --- Pagination Slider --- */
.ppc-pagination-slider-wrap {
  position: absolute;
  bottom: 12px;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 20;
  padding: 0 20px;
  box-sizing: border-box;
}

.ppc-pagination-slider {
  -webkit-appearance: none;
  width: 100%;
  max-width: 200px; /* Optional: limit width */
  height: var(--ppc-slider-height, 4px);
  background: var(--ppc-slider-track-bg, rgba(255,255,255,0.3));
  border-radius: 99px;
  outline: none;
  cursor: pointer;
  transition: opacity 0.2s;
}

/* Slider Thumb */
.ppc-pagination-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--ppc-slider-thumb-color, #ffffff);
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0,0,0,0.3);
  transition: transform 0.1s;
}

.ppc-pagination-slider::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--ppc-slider-thumb-color, #ffffff);
  cursor: pointer;
  border: none;
  box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.ppc-pagination-slider:active::-webkit-slider-thumb {
  transform: scale(1.2);
}

/* --- Missing Slider UI Styles --- */

.ppc-slider-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: var(--ppc-overlay-bg, rgba(0,0,0,0));
  opacity: var(--ppc-overlay-opacity, 1);
  transition: background 0.3s;
  z-index: 10;
}

.ppc-slider-overlay > * {
  pointer-events: auto;
}

.ppc-slider-btn {
  background: transparent;
  border: none;
  color: var(--ppc-controls-text, #111);
  cursor: pointer;
  font-size: var(--ppc-controls-font-size, 14px);
  padding: 0 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  min-width: 24px;
}

.ppc-slider-btn:hover {
  color: var(--ppc-controls-hover-text, #000);
  transform: scale(var(--ppc-btn-hover-scale, 1.1));
}

.ppc-slider-speed {
  font-size: 10px;
  margin-left: 4px;
  cursor: pointer;
  opacity: 0.8;
  color: var(--ppc-controls-text, #111);
  min-width: 20px;
  text-align: center;
}

.ppc-slider-loaded-play {
  position: absolute;
  bottom: var(--ppc-play-bottom, 10px);
  left: 50%;
  transform: translateX(-50%);
  width: var(--ppc-play-size, 40px);
  height: var(--ppc-play-size, 40px);
  border-radius: 50%;
  background: var(--ppc-play-bg, rgba(0,0,0,0.6));
  color: var(--ppc-play-color, #fff);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  cursor: pointer;
  opacity: 0;
  transition: all 0.3s;
  z-index: 20;
}

.ppc-slider-wrap:hover .ppc-slider-loaded-play {
  opacity: 1;
}

.ppc-slider-loaded-play:hover {
  background: var(--ppc-play-hover-bg, rgba(0,0,0,0.8));
  color: var(--ppc-play-hover-color, #fff);
  transform: translateX(-50%) scale(1.1);
}

.ppc-slider-loading-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: var(--ppc-spinner-size, 30px);
  height: var(--ppc-spinner-size, 30px);
  border: var(--ppc-spinner-border-width, 3px) solid var(--ppc-spinner-track-color, rgba(255,255,255,0.5));
  border-top-color: var(--ppc-spinner-color, #fff);
  border-radius: 50%;
  animation: ppc-spin 1s linear infinite;
  display: none;
  z-index: 30;
}

.ppc-slider-wrap.loading .ppc-slider-loading-icon {
  display: block;
}

@keyframes ppc-spin {
  to { transform: translate(-50%, -50%) rotate(360deg); }
}

.ppc-slider-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 5;
}

/* Ensure images fit the wrapper */
.ppc-slider-wrap img {
  width: 100%;
  height: auto;
  display: block;
  user-select: none;
  -webkit-user-drag: none;
  user-drag: none;
  -webkit-touch-callout: none;
}

/* Toast */
.ppc-toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: #333;
  color: #fff;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 14px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
  z-index: 9999;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}
.ppc-toast.show {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}
.ppc-toast-success { background: #10b981; }
.ppc-toast-error { background: #ef4444; }

/* Pagination Dots */
.ppc-pagination-dots {
  position: absolute;
  bottom: 12px;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  gap: 6px;
  z-index: 20;
  pointer-events: none;
}
.ppc-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,0.4);
  transition: all 0.2s;
}
.ppc-dot.active {
  background: #fff;
  transform: scale(1.2);
}

/* Container No1 Fixes */
.containerNo1 {
  box-sizing: border-box;
}
.ppc-cart-icon {
  cursor: pointer;
  background: none;
  border: none;
  transition: opacity 0.2s;
}
.ppc-cart-icon:hover {
  opacity: 0.7 !important;
}

