/* Main Container */
.pf-my-designs {
  background: #ffffff;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  margin-bottom: 30px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen",
    "Ubuntu", sans-serif;
  max-width: 100%;
  overflow: hidden;
}

.pf-my-designs h2 {
  font-size: 20px;
  font-weight: 600;
  color: #1a1a1a;
  margin: 0 0 16px 0;
  padding-bottom: 10px;
  border-bottom: 2px solid #f0f0f0;
}

/* Table Wrapper for Horizontal Scroll - CRITICAL FOR SCROLLING */
.design-table-wrapper {
  width: 100%;
  overflow-x: auto !important;
  overflow-y: visible;
  -webkit-overflow-scrolling: touch;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
  display: block !important;
}

/* Table Styles - REDUCED SIZE */
.design-table {
  width: 100%;
  min-width: 900px;
  /* Reduced from 1200px */
  border-collapse: collapse;
  background: #ffffff;
  font-size: 13px;
  /* Reduced from 14px */
  display: table !important;
}

.design-table thead {
  background: linear-gradient(135deg, #0a48b3 0%, #2d6ddf 100%);
  position: sticky;
  top: 0;
  z-index: 10;
}

.design-table th {
  color: #ffffff;
  padding: 12px 10px;
  /* Reduced padding */
  text-align: left;
  font-weight: 600;
  font-size: 12px;
  /* Reduced from 13px */
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
  border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.design-table th:last-child {
  border-right: none;
}

.design-table tbody tr {
  transition: all 0.2s ease;
  border-bottom: 1px solid #f3f4f6;
}

.design-table tbody tr:hover {
  background-color: #f9fafb;
  transform: scale(1.001);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.design-table tbody tr:last-child {
  border-bottom: none;
}

.design-table td {
  padding: 12px 10px;
  /* Reduced padding */
  vertical-align: top;
  color: #374151;
}

/* Column Specific Styles - REDUCED WIDTHS */
.design-table td:nth-child(1) {
  font-weight: 500;
  color: #1f2937;
  min-width: 160px;
  /* Reduced */
  max-width: 180px;
}

.design-table td:nth-child(2) {
  min-width: 160px;
  /* Categories - Reduced */
}

.design-table td:nth-child(3) {
  min-width: 100px;
  /* Mockup - Reduced */
  text-align: center;
}

.design-table td:nth-child(4),
.design-table td:nth-child(5),
.design-table td:nth-child(6) {
  font-weight: 500;
  color: #059669;
  min-width: 90px;
  /* Reduced */
  text-align: center;
}

.design-table td:nth-child(7) {
  min-width: 90px;
  /* Status - Reduced */
  text-align: center;
}

.design-table td:nth-child(8) {
  min-width: 180px;
  /* Actions - Reduced */
}

/* Categories Section - REDUCED SIZE */
.design-categories {
  max-height: 120px;
  /* Reduced from 140px */
  overflow-y: auto;
  border: 1px solid #e5e7eb;
  padding: 6px;
  /* Reduced */
  background: #f9fafb;
  border-radius: 6px;
  min-width: 140px;
  /* Reduced */
  max-width: 160px;
  /* Reduced */
}

.design-categories::-webkit-scrollbar {
  width: 5px;
  /* Smaller scrollbar */
}

.design-categories::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

.design-categories::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}

.design-categories::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

.cat-label {
  display: flex;
  align-items: center;
  margin-bottom: 4px;
  /* Reduced */
  font-size: 12px;
  /* Reduced from 13px */
  color: #4b5563;
  cursor: pointer;
  padding: 3px;
  /* Reduced */
  border-radius: 4px;
  transition: background 0.2s ease;
}

.cat-label:hover {
  background: #ffffff;
}

.cat-label input[type="checkbox"] {
  margin-right: 6px;
  /* Reduced */
  cursor: pointer;
}

.cat-label.user-cat {
  font-weight: 600;
  color: #6366f1;
  background: #eef2ff;
  padding: 5px 6px;
  /* Reduced */
  border-radius: 6px;
  margin-bottom: 6px;
  /* Reduced */
}

/* Mockup Image - REDUCED SIZE */
.col-mockup {
  text-align: center;
}

.design-thumb {
  max-width: 80px;
  /* Reduced from 100px */
  height: auto;
  border: 2px solid #e5e7eb;
  border-radius: 6px;
  /* Reduced */
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
}

.design-thumb:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Status Column */
.col-status {
  font-weight: 500;
  text-transform: capitalize;
}

/* Price Input - REDUCED SIZE */
.sm-artist-price {
  width: 85px;
  /* Reduced from 100px */
  padding: 6px 8px;
  /* Reduced */
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 13px;
  /* Reduced */
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.sm-artist-price:focus {
  outline: none;
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Buttons - REDUCED SIZE */
.button {
  padding: 6px 10px;
  /* Reduced */
  background: #667eea;
  color: #ffffff;
  border: none;
  border-radius: 5px;
  /* Reduced */
  font-size: 12px;
  /* Reduced from 13px */
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  margin: 2px;
  display: inline-block;
  text-decoration: none;
  white-space: nowrap;
}

.button:hover {
  background: #5568d3;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(102, 126, 234, 0.3);
}

.button:active {
  transform: translateY(0);
}

.sm-save-cats,
.sm-save-price {
  background: #10b981;
  margin-top: 6px;
  /* Reduced */
}

.sm-save-cats:hover,
.sm-save-price:hover {
  background: #059669;
}

.sm-start {
  background: #f59e0b;
}

.sm-start:hover {
  background: #d97706;
}

.sm-check {
  background: #3b82f6;
}

.sm-check:hover {
  background: #2563eb;
}

.sm-publish {
  background: #8b5cf6;
}

.sm-publish:hover {
  background: #7c3aed;
}

/* Messages */
.sm-price-msg,
.sm-cat-msg {
  margin-top: 5px;
  /* Reduced */
  font-size: 11px;
  /* Reduced */
  color: #059669;
  font-weight: 500;
}

/* No Designs Message */
.pf-my-designs p {
  color: #6b7280;
  font-size: 14px;
  /* Reduced */
  margin: 16px 0;
  /* Reduced */
}

.pf-my-designs p a {
  color: #667eea;
  text-decoration: none;
  font-weight: 600;
}

.pf-my-designs p a:hover {
  text-decoration: underline;
}

/* Responsive Design */
@media screen and (max-width: 1024px) {
  .pf-my-designs {
    padding: 16px;
  }

  .pf-my-designs h2 {
    font-size: 18px;
  }

  .design-table {
    min-width: 800px;
    /* Reduced */
    font-size: 12px;
  }
}

@media screen and (max-width: 768px) {
  .pf-my-designs {
    padding: 12px;
    border-radius: 8px;
  }

  .pf-my-designs h2 {
    font-size: 16px;
    margin-bottom: 12px;
  }

  .design-table {
    font-size: 11px;
    min-width: 750px;
    /* Reduced */
  }

  .design-table th,
  .design-table td {
    padding: 10px 8px;
  }

  .button {
    padding: 5px 8px;
    font-size: 11px;
  }

  .design-thumb {
    max-width: 70px;
  }
}

@media screen and (max-width: 480px) {
  .pf-my-designs {
    padding: 10px;
  }

  .pf-my-designs h2 {
    font-size: 15px;
  }

  .design-table {
    font-size: 11px;
    min-width: 700px;
    /* Still allows scroll */
  }

  .design-table th,
  .design-table td {
    padding: 8px 6px;
  }

  .button {
    padding: 5px 7px;
    font-size: 10px;
  }
}

/* Smooth Scrollbar for Table - MAKE SURE IT'S VISIBLE */
.design-table-wrapper::-webkit-scrollbar {
  height: 10px;
  /* Increased for easier grabbing */
}

.design-table-wrapper::-webkit-scrollbar-track {
  background: #f1f5f9;
  border-radius: 5px;
}

.design-table-wrapper::-webkit-scrollbar-thumb {
  background: #94a3b8;
  /* Darker for visibility */
  border-radius: 5px;
}

.design-table-wrapper::-webkit-scrollbar-thumb:hover {
  background: #64748b;
}

/* Fix for touch devices */
.design-table-wrapper {
  touch-action: pan-x pan-y;
}

/* Product Name Edit Section */
.product-name-edit {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.sm-product-name {
  width: 160px;
  padding: 6px 8px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 13px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.sm-product-name:focus {
  outline: none;
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.username-label {
  color: #6366f1;
  font-weight: 600;
  white-space: nowrap;
  font-size: 13px;
}

.sm-save-name {
  background: #10b981;
  padding: 6px 10px;
  font-size: 12px;
}

.sm-save-name:hover {
  background: #059669;
}

.sm-name-msg {
  width: 100%;
  margin-top: 3px;
  font-size: 11px;
  font-weight: 500;
}

/* Auto-selected categories (username + override) */
.cat-label.user-cat,
.cat-label.override-cat {
  background: #eef2ff;
  border: 1px solid #c7d2fe;
  padding: 5px 8px;
  border-radius: 6px;
  margin-bottom: 6px;
}

.cat-label.override-cat {
  background: #f0fdf4;
  border-color: #bbf7d0;
  color: #166534;
  font-weight: 500;
}

/* Lumise image-based username categories */
.cat-label.lumise-cat {
  background: #fef3c7;
  border: 1px solid #fde047;
  padding: 5px 8px;
  border-radius: 6px;
  margin-bottom: 6px;
  color: #854d0e;
  font-weight: 500;
}

/* Disabled state when limit reached */
.cat-label input[type="checkbox"]:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}

/* Category limit message */
.category-limit-msg {
  padding: 6px 8px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 6px;
  line-height: 1.4;
}

/* View Product Button */
.sm-view-product {
  background: #059669;
  border: 1px solid #047857;
}

.sm-view-product:hover {
  background: #047857;
  box-shadow: 0 4px 8px rgba(5, 150, 105, 0.3);
}

.sm-view-product::after {
  content: " →";
  font-weight: bold;
}

/* Published button disabled state */
.button.sm-publish:disabled {
  opacity: 0.5 !important;
  cursor: not-allowed !important;
  background: #6c757d !important;
  pointer-events: none;
}

.button.sm-publish:disabled:hover {
  transform: none !important;
  box-shadow: none !important;
}

/* Variant Preview Modal */
#smpf-variant-preview-modal {
  animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

#smpf-variant-preview-modal table {
  font-size: 13px;
}

#smpf-variant-preview-modal th {
  font-weight: 600;
  color: #374151;
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.5px;
}

#smpf-variant-preview-modal td {
  padding: 10px 8px;
  border-bottom: 1px solid #f3f4f6;
}

#smpf-variant-preview-modal tbody tr:last-child td {
  border-bottom: none;
}

#smpf-variant-preview-modal button.button {
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

#smpf-variant-preview-modal button.button:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* ===== Cost Warning Indicators ===== */
.design-table td:nth-child(4) .cost-display {
  font-weight: 600;
}

.design-table td:nth-child(4) .cost-display:has(+ .sm-recalc-cost) {
  color: #dc2626 !important;
  animation: pulse-red 2s infinite;
}

@keyframes pulse-red {
  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.6;
  }
}

.sm-recalc-cost {
  animation: bounce-in 0.5s ease;
}

@keyframes bounce-in {
  0% {
    transform: scale(0);
    opacity: 0;
  }

  50% {
    transform: scale(1.1);
  }

  100% {
    transform: scale(1);
    opacity: 1;
  }
}

/* Cost message styling */
.sm-cost-msg {
  font-size: 11px;
  margin-top: 3px;
  min-height: 16px;
}

/* Highlight successful cost fix */
.design-table tr.cost-fixed td:nth-child(4) {
  background: linear-gradient(90deg, #d4edda 0%, transparent 100%);
  animation: highlight-fade 2s ease;
}

@keyframes highlight-fade {
  0% {
    background: #d4edda;
  }

  100% {
    background: transparent;
  }
}

/* Product Description Edit Section */
.product-desc-edit {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sm-product-desc {
  width: 100%;
  max-width: 300px;
  min-height: 60px;
  padding: 8px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 13px;
  font-family: inherit;
  resize: vertical;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.sm-product-desc:focus {
  outline: none;
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.sm-save-desc {
  background: #10b981;
  padding: 6px 10px;
  font-size: 12px;
  align-self: flex-start;
}

.sm-save-desc:hover {
  background: #059669;
}

.sm-desc-msg {
  font-size: 11px;
  font-weight: 500;
}

/* Pagination Styles */
.smpf-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  padding: 16px 0;
  flex-wrap: wrap;
}

.smpf-pagination .page-btn,
.smpf-pagination .page-number {
  padding: 8px 14px;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  text-decoration: none;
  color: #374151;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s ease;
  cursor: pointer;
}

.smpf-pagination .page-btn:hover,
.smpf-pagination .page-number:hover {
  background: #f9fafb;
  border-color: #667eea;
  color: #667eea;
  transform: translateY(-1px);
}

.smpf-pagination .page-number.current {
  background: linear-gradient(135deg, #0a48b3 0%, #2d6ddf 100%);
  color: #ffffff;
  border-color: #667eea;
  cursor: default;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.smpf-pagination .page-number.current:hover {
  transform: none;
}

@media screen and (max-width: 768px) {
  .smpf-pagination {
    gap: 6px;
  }

  .smpf-pagination .page-btn,
  .smpf-pagination .page-number {
    padding: 6px 10px;
    font-size: 13px;
  }
}

/* ===== Mockup Gallery Styles ===== */
.mockup-gallery {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 4px;
  position: relative;
  max-width: 180px;
  margin: 0 auto;
}

.design-thumb-small {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border: 2px solid #e5e7eb;
  border-radius: 6px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  cursor: pointer;
}

.design-thumb-small:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  border-color: #667eea;
  z-index: 10;
}

.mockup-count-badge {
  position: absolute;
  bottom: 4px;
  right: 4px;
  background: rgba(10, 72, 179, 0.9);
  color: white;
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Single mockup (fallback) */
.design-thumb {
  max-width: 100px;
  height: auto;
  border: 2px solid #e5e7eb;
  border-radius: 6px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
  display: block;
  margin: 0 auto;
}

.design-thumb:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Responsive adjustments */
@media screen and (max-width: 768px) {
  .mockup-gallery {
    max-width: 140px;
    gap: 3px;
  }

  .design-thumb-small {
    border-width: 1px;
  }

  .design-thumb {
    max-width: 70px;
  }
}

/* ========================================
   MOCKUP LIGHTBOX & GALLERY MODALS
   ======================================== */

/* Single Image Lightbox Modal */
.smpf-mockup-lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100000;
  animation: fadeIn 0.2s ease;
  backdrop-filter: blur(4px);
}

.smpf-mockup-lightbox-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.smpf-mockup-lightbox-image-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 90vw;
  max-height: 80vh;
}

.smpf-mockup-lightbox-image {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  animation: zoomIn 0.3s ease;
}

.smpf-mockup-lightbox-label {
  background: rgba(255, 255, 255, 0.95);
  padding: 12px 24px;
  border-radius: 24px;
  font-size: 15px;
  font-weight: 600;
  color: #1a1a1a;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(10px);
}

/* Close Button */
.smpf-mockup-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.95);
  border: none;
  border-radius: 50%;
  font-size: 28px;
  line-height: 1;
  color: #1a1a1a;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  z-index: 10;
}

.smpf-mockup-close:hover {
  background: #ffffff;
  transform: scale(1.1) rotate(90deg);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.3);
}

/* Navigation Arrows */
.smpf-mockup-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 56px;
  height: 56px;
  background: rgba(255, 255, 255, 0.95);
  border: none;
  border-radius: 50%;
  font-size: 24px;
  color: #1a1a1a;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  z-index: 10;
}

.smpf-mockup-nav:hover {
  background: #ffffff;
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.3);
}

.smpf-mockup-nav:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  pointer-events: none;
}

.smpf-mockup-nav.prev {
  left: 20px;
}

.smpf-mockup-nav.next {
  right: 20px;
}

/* Gallery Modal */
.smpf-mockup-gallery-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100000;
  animation: fadeIn 0.2s ease;
  padding: 20px;
  overflow-y: auto;
}

.smpf-mockup-gallery-content {
  background: white;
  border-radius: 16px;
  padding: 32px;
  max-width: 1000px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  position: relative;
  animation: slideUp 0.3s ease;
}

.smpf-mockup-gallery-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 2px solid #f0f0f0;
}

.smpf-mockup-gallery-title {
  font-size: 22px;
  font-weight: 600;
  color: #1a1a1a;
  margin: 0;
}

.smpf-mockup-gallery-count {
  font-size: 14px;
  color: #667eea;
  font-weight: 600;
  background: #eef2ff;
  padding: 6px 12px;
  border-radius: 20px;
}

.smpf-mockup-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 20px;
}

.smpf-mockup-gallery-item {
  background: #f9fafb;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  padding: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.smpf-mockup-gallery-item:hover {
  border-color: #667eea;
  box-shadow: 0 8px 24px rgba(102, 126, 234, 0.2);
  transform: translateY(-4px);
}

.smpf-mockup-gallery-item-image {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 8px;
  background: #ffffff;
}

.smpf-mockup-gallery-item-label {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
  text-align: center;
  padding: 4px 8px;
  background: #ffffff;
  border-radius: 6px;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes zoomIn {
  from {
    opacity: 0;
    transform: scale(0.8);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive Design */
@media screen and (max-width: 768px) {
  .smpf-mockup-lightbox-content {
    max-width: 95vw;
    max-height: 95vh;
  }

  .smpf-mockup-lightbox-image {
    max-height: 70vh;
  }

  .smpf-mockup-close {
    width: 40px;
    height: 40px;
    font-size: 24px;
    top: 10px;
    right: 10px;
  }

  .smpf-mockup-nav {
    width: 44px;
    height: 44px;
    font-size: 20px;
  }

  .smpf-mockup-nav.prev {
    left: 10px;
  }

  .smpf-mockup-nav.next {
    right: 10px;
  }

  .smpf-mockup-gallery-content {
    padding: 20px;
    max-height: 95vh;
  }

  .smpf-mockup-gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 12px;
  }

  .smpf-mockup-gallery-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}

/* Make badge clickable indicator */
.mockup-count-badge {
  cursor: pointer;
  transition: all 0.2s ease;
}

.mockup-count-badge:hover {
  background: rgba(10, 72, 179, 1);
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(10, 72, 179, 0.4);
}

/* ===== ENHANCED SAVE BUTTON STYLES ===== */
/* Save button base styles */
#pf-save-btn {
  position: relative;
  transition: all 0.3s ease;
  font-weight: 600;
}

/* Unsaved changes indicator dot */
.save-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  background: #f59e0b;
  border-radius: 50%;
  margin-right: 8px;
  animation: pulse-dot 2s infinite;
  box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.7);
}

@keyframes pulse-dot {
  0% {
    box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.7);
  }

  50% {
    box-shadow: 0 0 0 6px rgba(245, 158, 11, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(245, 158, 11, 0);
  }
}

/* Button state: has unsaved changes */
#pf-save-btn.has-changes {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  border-color: #d97706;
  animation: glow-orange 2s infinite;
}

@keyframes glow-orange {
  0%,
  100% {
    box-shadow: 0 0 5px rgba(245, 158, 11, 0.5);
  }

  50% {
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.8);
  }
}

/* Button state: saving */
#pf-save-btn.saving {
  background: #6b7280;
  cursor: wait;
  pointer-events: none;
}

.spinner {
  display: inline-block;
  width: 12px;
  height: 12px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #ffffff;
  border-radius: 50%;
  margin-right: 8px;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Button state: success */
#pf-save-btn.success {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  border-color: #059669;
}

.checkmark {
  display: inline-block;
  margin-right: 6px;
  font-size: 16px;
  animation: checkmark-pop 0.3s ease;
}

@keyframes checkmark-pop {
  0% {
    transform: scale(0);
  }

  50% {
    transform: scale(1.2);
  }

  100% {
    transform: scale(1);
  }
}

/* Button state: error */
#pf-save-btn.error {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  border-color: #dc2626;
  animation: shake 0.5s ease;
}

@keyframes shake {
  0%,
  100% {
    transform: translateX(0);
  }

  25% {
    transform: translateX(-5px);
  }

  75% {
    transform: translateX(5px);
  }
}

.error-icon {
  display: inline-block;
  margin-right: 6px;
  font-size: 16px;
  animation: error-pulse 0.5s ease;
}

@keyframes error-pulse {
  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.3);
  }
}

/* Disabled state */
#pf-save-btn:disabled:not(.saving):not(.success):not(.error) {
  background: #9ca3af;
  border-color: #9ca3af;
  cursor: not-allowed;
  opacity: 0.6;
}

/* Status message styles */
#pf-status {
  margin-top: 8px;
  font-size: 13px;
  min-height: 20px;
  transition: all 0.3s ease;
}

.status-progress {
  color: #3b82f6;
  font-weight: 500;
}

.status-success {
  color: #10b981;
  font-weight: 600;
  animation: fade-in 0.3s ease;
}

.status-error {
  color: #ef4444;
  font-weight: 600;
  animation: fade-in 0.3s ease;
}

@keyframes fade-in {
  from {
    opacity: 0;
    transform: translateY(-5px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}


/* ========================================
   DELETE & UNPUBLISH BUTTONS
   ======================================== */

/* Delete Button */
.sm-delete {
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
  border-color: #b91c1c;
  color: #ffffff;
}

.sm-delete:hover {
  background: linear-gradient(135deg, #b91c1c 0%, #991b1b 100%);
  box-shadow: 0 4px 12px rgba(220, 38, 38, 0.3);
}

/* Unpublish Button */
.sm-unpublish {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  border-color: #d97706;
  color: #ffffff;
}

.sm-unpublish:hover {
  background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

/* Row deletion animation */
.design-table tbody tr.deleting {
  opacity: 0;
  transform: translateX(-20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}