
/* ====================================================
   WooPanel — Fase 1: Limpeza Visual (Neutro)
   ==================================================== */

/* Reset and Base Styles */
*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

/* Trava o scroll da página de fundo quando um modal ou o menu-gaveta mobile
   está aberto. Sem isso, no celular dá para rolar o conteúdo por trás,
   o que faz o modal/menu "fugir" da tela ao tocar. */
body.woopanel-modal-open,
body.woopanel-sidebar-open-lock {
  overflow: hidden;
}

/* Layout */
.woopanel-wrapper {
  min-height: 100vh;
  background: #fff;
  display: flex;
  flex-direction: row;
}

/* Sidebar */
.woopanel-sidebar {
  width: 280px;
  min-width: 280px;
  max-width: 280px;
  background: #fff;
  border-right: 1px solid #ccc;
  display: flex;
  flex-direction: column;
  padding: 16px;
  position: sticky;
  top: 0;
  height: 100vh;
  flex-shrink: 0;
  transition:
    transform 0.28s ease,
    opacity 0.28s ease,
    width 0.28s ease,
    min-width 0.28s ease,
    max-width 0.28s ease,
    padding 0.28s ease,
    border-color 0.28s ease;
  will-change: transform, width;
}

.woopanel-layout {
  position: relative;
  flex: 1;
  min-width: 0;
}

.woopanel-main-content {
  flex: 1;
  min-width: 0;
  transition: width 0.28s ease;
}

.woopanel-sidebar-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(15, 23, 42, 0.45);
  opacity: 0;
  transition: opacity 0.28s ease;
}

.woopanel-sidebar-backdrop.is-visible {
  display: block;
  opacity: 1;
}

/* PDV: sidebar recolhido por padrão */
.woopanel-wrapper.is-pdv-active.is-sidebar-collapsed .woopanel-sidebar {
  width: 0;
  min-width: 0;
  max-width: 0;
  padding-left: 0;
  padding-right: 0;
  border-right-color: transparent;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
  transform: translateX(-100%);
}

.woopanel-wrapper.is-pdv-active.is-sidebar-expanded .woopanel-sidebar {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
}

.woopanel-wrapper.is-pdv-active.is-sidebar-collapsed #woopanel-module-pdv {
  padding-left: 1rem;
  padding-right: 1rem;
}

.woopanel-pdv-header__toolbar {
  margin-bottom: 12px;
}

.woopanel-pdv-sidebar-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #fff;
  color: #111827;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.woopanel-pdv-sidebar-toggle:hover {
  background: #f9fafb;
  border-color: #9ca3af;
}

.woopanel-pdv-sidebar-toggle:focus-visible {
  outline: 2px solid #059669;
  outline-offset: 2px;
}

.woopanel-pdv-sidebar-toggle__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.28s ease;
}

.woopanel-wrapper.is-pdv-active.is-sidebar-expanded .woopanel-pdv-sidebar-toggle__icon {
  transform: rotate(180deg);
}

/* ============================================================
   Barra superior mobile (hambúrguer) — visível em qualquer módulo
   ============================================================ */

.woopanel-mobile-topbar {
  display: none;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid #e5e7eb;
  background: #fff;
  position: sticky;
  top: 0;
  z-index: 80;
}

.woopanel-mobile-menu-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #fff;
  color: #111827;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.18s ease, border-color 0.18s ease;
}

.woopanel-mobile-menu-toggle:hover {
  background: #f9fafb;
  border-color: #9ca3af;
}

.woopanel-mobile-menu-toggle:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
}

.woopanel-mobile-topbar__logo {
  font-size: 16px;
  font-weight: 700;
  color: #111827;
}

/* ============================================================
   Menu lateral em modo "gaveta" (drawer) no mobile
   Aplica-se a TODOS os módulos, não somente ao PDV.
   ============================================================ */

@media (max-width: 900px) {
  .woopanel-mobile-topbar {
    display: flex;
  }

  /* Estado padrão no mobile: menu fora da tela (fechado) */
  .woopanel-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    z-index: 100;
    width: min(280px, 88vw);
    min-width: min(280px, 88vw);
    max-width: min(280px, 88vw);
    height: 100vh;
    padding: 16px;
    transform: translateX(-100%);
    box-shadow: 4px 0 24px rgba(15, 23, 42, 0.18);
  }

  /* Menu aberto (qualquer módulo, via botão hambúrguer) */
  .woopanel-wrapper.is-sidebar-open .woopanel-sidebar {
    transform: translateX(0);
  }

  /* Conteúdo principal sempre ocupa a largura total no mobile,
     já que o menu vira uma sobreposição (position: fixed) */
  .woopanel-main-content {
    width: 100%;
  }

  .woopanel-wrapper.is-pdv-active.is-sidebar-expanded .woopanel-sidebar {
    transform: translateX(0);
  }

  .woopanel-wrapper.is-pdv-active.is-sidebar-collapsed .woopanel-sidebar {
    transform: translateX(-100%);
  }
}

.woopanel-sidebar__brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  padding: 8px;
}

.woopanel-sidebar__brand-icon {
  width: 40px;
  height: 40px;
  border: 1px solid #ccc;
  display: flex;
  align-items: center;
  justify-content: center;
}

.woopanel-sidebar__logo {
  font-size: 20px;
  font-weight: 700;
}

.woopanel-sidebar__tag {
  font-size: 12px;
  color: #666;
}

.woopanel-sidebar__nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.woopanel-sidebar__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.woopanel-module-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  font-size: 15px;
  color: #000;
  width: 100%;
  text-align: left;
}

.woopanel-module-btn.is-active {
  background: #eee;
  border-color: #ccc;
}

/* Main Content */
.woopanel-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  padding: 16px;
}

.woopanel-module-content {
  display: none;
}

.woopanel-module-content:not(.hidden) {
  display: block;
}

/* Header */
.woopanel-page-header,
.woopanel-header {
  margin-bottom: 24px;
}

.woopanel-page-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: #666;
  margin-bottom: 8px;
}

.woopanel-page-title {
  font-size: 24px;
  font-weight: 700;
  color: #000;
  margin: 0 0 8px 0;
}

.woopanel-page-description {
  font-size: 14px;
  color: #666;
  margin: 0;
}

/* Cards */
.woopanel-card {
  background: #fff;
  border: 1px solid #ccc;
  padding: 16px;
  margin-bottom: 16px;
}

.woopanel-cards-grid,
.woopanel-stats-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

@media (min-width: 640px) {
  .woopanel-cards-grid,
  .woopanel-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

.woopanel-card-title {
  font-size: 14px;
  font-weight: 600;
  color: #666;
  text-transform: uppercase;
  margin: 0 0 8px 0;
}

.woopanel-card-value {
  font-size: 24px;
  font-weight: 700;
  color: #000;
  margin: 0;
  line-height: 1.1;
}

.woopanel-card-icon {
  width: 48px;
  height: 48px;
  border: 1px solid #ccc;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

/* Campos do Modo Personalizado */
.woopanel-custom-fields-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 16px;
}

.woopanel-custom-fields-grid .fashion-group-wrapper {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.woopanel-custom-fields-grid .fashion-group-items {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 16px;
}

.woopanel-custom-fields-grid .woopanel-custom-fields-group-header {
  grid-column: 1 / -1;
}

.woopanel-custom-fields-grid .woopanel-size-config {
  grid-column: 1 / -1;
}

.woopanel-field-help {
  margin: -2px 0 8px;
  font-size: 12px;
  color: #6b7280;
}

.woopanel-field-error {
  margin: 6px 0 0;
  font-size: 12px;
  color: #b91c1c;
}

.woopanel-money-input {
  position: relative;
}

.woopanel-money-input__prefix {
  position: absolute;
  top: 50%;
  left: 16px;
  z-index: 1;
  color: #6b7280;
  font-size: 14px;
  transform: translateY(-50%);
  pointer-events: none;
}

.woopanel-wrapper .woopanel-money-input input#product_price,
.woopanel-wrapper .woopanel-money-input input {
  padding-left: 2.75rem !important;
}

.woopanel-wrapper .woopanel-quantity-input {
  display: flex;
  align-items: center;
  gap: 8px;
}

.woopanel-wrapper .woopanel-quantity-input input {
  min-width: 0;
  width: 80px;
  max-width: 80px;
  text-align: center;
}

.woopanel-wrapper .woopanel-quantity-input__button {
  flex: 0 0 44px;
  min-width: 44px;
  min-height: 44px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: #f9fafb;
  color: #374151;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.woopanel-wrapper .woopanel-quantity-input__button:hover {
  background: #f3f4f6;
}

.woopanel-wrapper .woopanel-quantity-input__unit {
  display: block;
  margin-top: 5px;
  color: #6b7280;
  font-size: 12px;
  text-align: center;
}

.woopanel-size-category-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 16px;
}

.woopanel-size-category {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #374151;
}

@media (max-width: 760px) {
  .woopanel-custom-fields-grid {
    grid-template-columns: 1fr;
  }

  .woopanel-custom-fields-grid .fashion-group-wrapper,
  .woopanel-custom-fields-grid .fashion-group-items {
    grid-template-columns: 1fr;
  }

  .woopanel-size-category-list {
    grid-template-columns: 1fr;
  }
}

/* Toolbar */
.woopanel-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.woopanel-toolbar-left,
.woopanel-toolbar-right {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
}

.woopanel-search-wrapper {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  border: 1px solid #ccc;
  padding: 8px 12px;
}

.woopanel-filters-wrapper {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.woopanel-filter-select {
  padding: 8px 12px;
  border: 1px solid #ccc;
  background: #fff;
  font-size: 14px;
  color: #000;
}

/* Buttons */
.woopanel-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 16px;
  border: 1px solid #ccc;
  background: #fff;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.5;
}

.woopanel-btn-primary {
  background: #000;
  color: #fff;
  border-color: #000;
}

.woopanel-btn-secondary {
  background: #eee;
}

.woopanel-btn-outline {
  background: transparent;
}

/* Forms */
.woopanel-form-group {
  margin-bottom: 16px;
}

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

.woopanel-input,
.woopanel-select,
.woopanel-textarea {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #ccc;
  background: #fff;
  font-size: 14px;
  color: #000;
  outline: none;
}

.woopanel-textarea {
  resize: vertical;
}

/* Tables */
.woopanel-table-container {
  background: #fff;
  border: 1px solid #ccc;
  overflow: hidden;
}

.woopanel-table-wrapper {
  overflow-x: auto;
}

.woopanel-table {
  width: 100%;
  border-collapse: collapse;
}

.woopanel-table thead th {
  background: #eee;
  text-align: left;
  padding: 12px 16px;
  font-size: 12px;
  font-weight: 600;
  color: #666;
  text-transform: uppercase;
  border-bottom: 1px solid #ccc;
}

.woopanel-table tbody tr {
  border-bottom: 1px solid #ccc;
}

.woopanel-table tbody tr:last-child {
  border-bottom: none;
}

.woopanel-table tbody td {
  padding: 12px 16px;
  font-size: 14px;
  color: #000;
}

.woopanel-empty-state {
  text-align: center;
  padding: 32px 16px;
  color: #666;
  font-size: 14px;
}

.woopanel-state {
  min-width: 0;
}

.woopanel-state__spinner {
  vertical-align: -5px;
}

.woopanel-state__retry {
  cursor: pointer;
}

.woopanel-wrapper .woopanel-products-filters {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(0, 3fr) auto;
  align-items: center;
  gap: 12px;
}

.woopanel-wrapper .woopanel-products-search {
  min-width: 240px;
}

.woopanel-wrapper .woopanel-products-filter-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.woopanel-wrapper .woopanel-product-filter-select {
  flex: 1 1 180px;
  min-width: 180px;
  max-width: 192px;
}

.woopanel-wrapper .woopanel-product-filters-clear {
  white-space: nowrap;
}

.woopanel-wrapper .woopanel-products-table .product-title-header,
.woopanel-wrapper .woopanel-products-table .product-title-cell {
  min-width: 240px;
  max-width: 320px;
}

.woopanel-wrapper .woopanel-products-table {
  min-width: 820px;
}

.woopanel-wrapper .woopanel-products-table thead tr {
  background-color: #facc15;
  background-image: linear-gradient(135deg, #facc15 0%, #f59e0b 100%);
  border-bottom-color: #f59e0b;
  border-bottom-width: 2px;
}

.woopanel-wrapper .woopanel-products-table thead th {
  color: #111827;
  font-weight: 700;
  background: transparent;
}

.woopanel-wrapper .woopanel-products-table .product-category-cell {
  max-width: 160px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.woopanel-wrapper .woopanel-product-card {
  display: flex;
  gap: 12px;
  padding: 12px;
  margin-bottom: 10px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #fff;
}

.woopanel-wrapper .woopanel-product-card__image {
  flex: 0 0 64px;
  width: 64px;
  height: 64px;
  border: 1px solid #e5e7eb;
  border-radius: 7px;
  object-fit: cover;
  background: #f9fafb;
}

.woopanel-wrapper .woopanel-product-card__body {
  flex: 1;
  min-width: 0;
}

.woopanel-wrapper .woopanel-product-card__title,
.woopanel-wrapper .woopanel-product-card__meta {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.woopanel-wrapper .woopanel-product-card__title {
  margin: 0;
  color: #111827;
  font-size: 14px;
  font-weight: 600;
}

.woopanel-wrapper .woopanel-product-card__meta {
  margin: 2px 0 8px;
  color: #6b7280;
  font-size: 11px;
}

.woopanel-wrapper .woopanel-product-card__details {
  display: flex;
  gap: 18px;
  color: #111827;
  font-size: 13px;
}

.woopanel-wrapper .woopanel-product-card__details span {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.woopanel-wrapper .woopanel-product-card__details strong {
  color: #6b7280;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
}

.woopanel-wrapper .woopanel-product-card__category {
  margin-top: 7px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.woopanel-wrapper .woopanel-product-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 9px;
}

.woopanel-wrapper .woopanel-product-card__footer select {
  min-width: 0;
  max-width: 130px;
  padding: 4px 6px;
  font-size: 11px;
}

.woopanel-wrapper .woopanel-product-card__actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

@media (max-width: 782px) {
  .woopanel-wrapper .woopanel-products-filters {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .woopanel-wrapper .woopanel-products-search,
  .woopanel-wrapper .woopanel-products-filter-group,
  .woopanel-wrapper .woopanel-product-filter-select,
  .woopanel-wrapper .woopanel-product-filters-clear {
    width: 100%;
    max-width: none;
  }
}

#woopanel-size-buttons .woopanel-size-btn {
  min-width: 44px;
  min-height: 36px;
}

#woopanel-size-buttons .woopanel-size-btn.selected-var {
  box-shadow: 0 0 0 2px rgba(147, 197, 253, 0.55), 0 1px 2px rgba(0, 0, 0, 0.05);
  font-weight: 600;
}

.woopanel-upload-zone:focus-visible {
  outline: 3px solid rgba(59, 130, 246, 0.45);
  outline-offset: 2px;
}

/* Table Action Buttons */
.woopanel-table-actions {
  display: flex;
  gap: 8px;
  justify-content: center;
}

.woopanel-table-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid #ccc;
  cursor: pointer;
  background: #fff;
  border-radius: 8px;
  transition: background-color .14s ease, color .14s ease, border-color .14s ease;
}

.woopanel-table-btn svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  display: block;
}

.woopanel-table-btn.btn-view {
  border-color: #fde68a;
  background: #fef3c7;
  color: #b45309;
}
.woopanel-table-btn.btn-view:hover {
  background: #f59e0b;
  border-color: #f59e0b;
  color: #fff;
}

.woopanel-table-btn.btn-edit {
  border-color: #bbf7d0;
  background: #dcfce7;
  color: #15803d;
}
.woopanel-table-btn.btn-edit:hover {
  background: #16a34a;
  border-color: #16a34a;
  color: #fff;
}

.woopanel-table-btn.btn-delete {
  border-color: #fecaca;
  background: #fee2e2;
  color: #b91c1c;
}
.woopanel-table-btn.btn-delete:hover {
  background: #dc2626;
  border-color: #dc2626;
  color: #fff;
}

/* Badges */
.woopanel-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border: 1px solid #ccc;
  font-size: 12px;
  font-weight: 500;
}

/* Modal */
.woopanel-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 16px;
  opacity: 0;
  visibility: hidden;
}

.woopanel-modal-backdrop:not(.hidden) {
  opacity: 1;
  visibility: visible;
}

.woopanel-modal-panel {
  background: #fff;
  border: 1px solid #ccc;
  width: 100%;
  max-width: 800px;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

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

.woopanel-modal-title {
  font-size: 18px;
  font-weight: 700;
  color: #000;
  margin: 0;
}

.woopanel-modal-close {
  width: 40px;
  height: 40px;
  border: 1px solid #ccc;
  background: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.woopanel-modal-close--danger,
.woopanel-wrapper #btn-close-edit-modal {
  width: 38px !important;
  height: 38px !important;
  min-width: 38px !important;
  min-height: 38px !important;
  max-width: 38px !important;
  max-height: 38px !important;
  padding: 0 !important;
  border-radius: 8px !important;
  background-color: #ef4444 !important;
  background-image: linear-gradient(135deg, #f87171 0%, #ef4444 100%) !important;
  border: 1px solid #dc2626 !important;
  color: #ffffff !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  box-shadow: 0 2px 6px rgba(239, 68, 68, 0.4) !important;
  transition: background 0.18s ease, background-color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.15s ease !important;
  flex-shrink: 0 !important;
  line-height: 1 !important;
}

.woopanel-modal-close--danger:hover,
.woopanel-modal-close--danger:focus,
.woopanel-wrapper #btn-close-edit-modal:hover,
.woopanel-wrapper #btn-close-edit-modal:focus {
  background-color: #dc2626 !important;
  background-image: linear-gradient(135deg, #ef4444 0%, #dc2626 100%) !important;
  border-color: #b91c1c !important;
  color: #ffffff !important;
  box-shadow: 0 4px 10px rgba(220, 38, 38, 0.55) !important;
  transform: scale(1.05) !important;
}

.woopanel-modal-close--danger:active,
.woopanel-wrapper #btn-close-edit-modal:active {
  background-color: #b91c1c !important;
  background-image: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%) !important;
  transform: translateY(1px) scale(0.98) !important;
}

.woopanel-modal-close--danger svg,
.woopanel-wrapper #btn-close-edit-modal svg {
  width: 20px !important;
  height: 20px !important;
  color: #ffffff !important;
  stroke: #ffffff !important;
  fill: none !important;
  stroke-width: 2.2px !important;
  display: block !important;
  pointer-events: none !important;
}

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

.woopanel-modal-footer {
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  border-top: 1px solid #ccc;
}

/* Modal de Progresso (otimização de imagens / salvamento do produto) */
.woopanel-progress-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(15, 23, 42, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  /* Precisa ficar acima do modal de edição de produto (z-index: 9999) */
  z-index: 100000;
  padding: 16px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.15s ease;
}

.woopanel-progress-modal-backdrop:not(.hidden) {
  opacity: 1;
  visibility: visible;
}

.woopanel-progress-modal-panel {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
  width: 100%;
  max-width: 340px;
  padding: 32px 28px 26px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.woopanel-progress-modal-spinner {
  width: 36px;
  height: 36px;
  color: #2563eb;
}

/* Photo Uploader */
.woopanel-photo-wrapper {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 120px;
  height: 120px;
  border: 1px dashed #ccc;
  overflow: hidden;
  position: relative;
  cursor: pointer;
}

.woopanel-photo-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.woopanel-photo-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: #666;
}

.woopanel-photo-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  border: 1px solid #ccc;
  background: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Pagination */
.woopanel-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 16px;
  border-top: 1px solid #ccc;
}

.woopanel-pagination-info {
  font-size: 14px;
  color: #666;
}

.woopanel-pagination-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.woopanel-pagination-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  border: 1px solid #ccc;
  background: #fff;
  color: #000;
  cursor: pointer;
}

.woopanel-pagination-btn.is-active {
  background: #000;
  color: #fff;
  border-color: #000;
}

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



/* Utilities */
.hidden {
  display: none !important;
}

/* ============================================================
   Modal grande (2 colunas) — usado pelo cadastro de Devedores.
   ============================================================ */

.woopanel-modal-panel--wide {
  max-width: 1180px;
  width: 95vw;
  max-height: 92vh;
}

.woopanel-modal-subtitle {
  margin: 4px 0 0;
  font-size: 13px;
  color: #666;
}

.woopanel-form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px 28px;
}

.woopanel-form-span-2 {
  grid-column: 1 / -1;
}

.woopanel-form-subtitle {
  font-size: 15px;
  font-weight: 700;
  margin: 4px 0 14px;
  padding-top: 18px;
  border-top: 1px solid #e5e5e5;
}

.woopanel-form-hint {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #777;
  margin: 8px 0 16px;
}

@media (max-width: 760px) {
  .woopanel-form-grid-2 {
    grid-template-columns: 1fr;
  }
}

/* Resumo de pagamentos */

.woopanel-payment-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 12px;
}

.woopanel-payment-stat {
  border: 1px solid #e5e5e5;
  border-radius: 8px;
  padding: 12px 14px;
  background: #fafafa;
}

.woopanel-payment-stat__label {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #888;
  margin-bottom: 4px;
}

.woopanel-payment-stat__value {
  display: block;
  font-size: 17px;
  font-weight: 700;
  color: #111;
}

.woopanel-payment-progress {
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background: #e5e5e5;
  overflow: hidden;
  margin-bottom: 4px;
}

.woopanel-payment-progress__bar {
  height: 100%;
  background: #16a34a;
  transition: width .3s ease;
}

/* Histórico de pagamentos */

.woopanel-payment-history {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
  max-height: 220px;
  overflow-y: auto;
}

.woopanel-payment-history__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid #e5e5e5;
  border-radius: 8px;
  padding: 10px 12px;
}

.woopanel-payment-history__info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.woopanel-payment-history__amount {
  font-weight: 700;
  color: #15803d;
}

.woopanel-payment-history__meta {
  font-size: 12px;
  color: #888;
}

.woopanel-payment-history__remove {
  border: none;
  background: transparent;
  color: #aaa;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
  border-radius: 6px;
}

.woopanel-payment-history__remove:hover {
  color: #dc2626;
  background: #fef2f2;
}

.woopanel-empty-state-inline {
  font-size: 13px;
  color: #999;
  text-align: center;
  padding: 16px 0;
  margin: 0;
}

/* Linha para adicionar um novo pagamento */

.woopanel-payment-add-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1.4fr auto;
  gap: 10px;
  align-items: center;
}

@media (max-width: 900px) {
  .woopanel-payment-add-row {
    grid-template-columns: 1fr 1fr;
  }
}

/* ================================================================== 
   View Debt Modal — Redesign (layout 2 colunas, quase tela cheia) 
   ================================================================== */ 
.woopanel-modal-panel--invoice { 
    width: 94vw; 
    max-width: 1240px; 
    height: 90vh; 
    max-height: 90vh; 
    border-radius: 12px; 
    overflow: hidden; 
    box-shadow: 0 24px 64px -12px rgba(15, 23, 42, .28), 0 0 0 1px rgba(15, 23, 42, .05); 
    border: none; 
} 

.vd-header { 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    padding: 18px 28px; 
    border-bottom: 1px solid #e5e7eb; 
    background: #fff; 
    flex-shrink: 0; 
} 

.vd-header-left { display: flex; align-items: center; gap: 12px; min-width: 0; } 

.vd-header-eyebrow { 
    font-size: 11px; 
    font-weight: 600; 
    letter-spacing: .06em; 
    text-transform: uppercase; 
    color: #94a3b8; 
    margin: 0 0 3px 0; 
} 

.vd-header-title { 
    font-size: 17px; 
    font-weight: 600; 
    color: #0f172a; 
    margin: 0; 
    line-height: 1.3; 
    white-space: nowrap; 
    overflow: hidden; 
    text-overflow: ellipsis; 
} 

.vd-header-right { display: flex; align-items: center; gap: 14px; flex-shrink: 0; } 

.vd-close-btn { 
    width: 32px; 
    height: 32px; 
    border-radius: 8px; 
    border: 1px solid #e5e7eb; 
    background: #fff; 
    color: #64748b; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    cursor: pointer; 
    font-size: 16px; 
    line-height: 1; 
    transition: background .12s ease, color .12s ease; 
} 
.vd-close-btn:hover { background: #f8fafc; color: #0f172a; } 

.vd-status-pill { 
    display: inline-flex; 
    align-items: center; 
    gap: 6px; 
    padding: 5px 12px; 
    border-radius: 100px; 
    font-size: 12px; 
    font-weight: 600; 
    white-space: nowrap; 
} 
.vd-status-pill::before { 
    content: ''; 
    width: 6px; 
    height: 6px; 
    border-radius: 50%; 
    background: currentColor; 
} 
.vd-status-open    { background: #fee2e2; color: #b91c1c; } 
.vd-status-partial { background: #fef3c7; color: #b45309; } 
.vd-status-paid     { background: #dcfce7; color: #15803d; } 

.vd-body { 
    flex: 1; 
    min-height: 0; 
    display: grid; 
    grid-template-columns: 1fr 320px; 
    overflow: hidden; 
} 

.vd-main { 
    overflow-y: auto; 
    padding: 24px 28px; 
} 

.vd-sidebar { 
    overflow-y: auto; 
    background: #f8fafc; 
    border-left: 1px solid #e5e7eb; 
    padding: 24px; 
} 

.vd-section { margin-bottom: 28px; } 
.vd-section:last-child { margin-bottom: 0; } 

.vd-section-title { 
    font-size: 11px; 
    font-weight: 600; 
    letter-spacing: .06em; 
    text-transform: uppercase; 
    color: #94a3b8; 
    margin: 0 0 14px 0; 
} 

/* Sidebar: resumo financeiro */ 
.vd-balance-label { 
    font-size: 11px; 
    font-weight: 600; 
    letter-spacing: .05em; 
    text-transform: uppercase; 
    color: #94a3b8; 
    margin: 0 0 6px 0; 
} 
.vd-balance-amount { 
    font-size: 30px; 
    font-weight: 700; 
    color: #0f172a; 
    font-variant-numeric: tabular-nums; 
    letter-spacing: -.02em; 
    line-height: 1.1; 
    margin-bottom: 16px; 
} 
.vd-mini-stats { display: flex; flex-direction: column; gap: 10px; padding-top: 14px; border-top: 1px solid #e2e8f0; } 
.vd-mini-stat { display: flex; align-items: center; justify-content: space-between; } 
.vd-mini-stat-label { font-size: 12.5px; color: #64748b; } 
.vd-mini-stat-value { font-size: 13.5px; font-weight: 600; color: #334155; font-variant-numeric: tabular-nums; } 

/* Sidebar: campos info (cliente / venda) */ 
.vd-info-item + .vd-info-item { margin-top: 14px; } 
.vd-info-label { font-size: 12px; color: #94a3b8; margin: 0 0 3px 0; } 
.vd-info-value { font-size: 14px; font-weight: 500; color: #1e293b; } 

/* Coluna principal: tabela de produtos */ 
.vd-items-table { width: 100%; border-collapse: collapse; } 
.vd-items-table thead th { 
    text-align: left; 
    font-size: 10.5px; 
    font-weight: 600; 
    letter-spacing: .04em; 
    text-transform: uppercase; 
    color: #94a3b8; 
    padding: 0 0 10px 0; 
    border-bottom: 1px solid #e2e8f0; 
} 
.vd-items-table thead th.vd-num { text-align: right; } 
.vd-items-table tbody td { 
    padding: 13px 0; 
    font-size: 14px; 
    color: #1e293b; 
    border-bottom: 1px solid #f1f5f9; 
} 
.vd-items-table tbody tr:last-child td { border-bottom: none; } 
.vd-items-table td.vd-num { text-align: right; font-variant-numeric: tabular-nums; color: #334155; } 
.vd-item-name { font-weight: 500; } 

/* Coluna principal: histórico de pagamentos */ 
.vd-payments-list { display: flex; flex-direction: column; } 
.vd-payment-row { 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    padding: 13px 0; 
    border-bottom: 1px solid #f1f5f9; 
} 
.vd-payment-row:last-child { border-bottom: none; } 
.vd-payment-left { display: flex; flex-direction: column; gap: 2px; } 
.vd-payment-method { font-size: 14px; font-weight: 500; color: #1e293b; } 
.vd-payment-meta { font-size: 12.5px; color: #94a3b8; } 
.vd-payment-amount { font-size: 14.5px; font-weight: 600; color: #15803d; font-variant-numeric: tabular-nums; } 

.vd-empty { font-size: 13px; color: #94a3b8; padding: 12px 0; text-align: center; } 

.vd-footer { 
    display: flex; 
    justify-content: flex-end; 
    gap: 10px; 
    padding: 16px 28px; 
    background: #fff; 
    border-top: 1px solid #e5e7eb; 
    flex-shrink: 0; 
} 

@media (max-width: 900px) { 
    .woopanel-modal-panel--invoice { width: 100vw; height: 100vh; max-height: 100vh; border-radius: 0; } 
    .vd-body { grid-template-columns: 1fr; overflow-y: auto; } 
    .vd-sidebar { border-left: none; border-top: 1px solid #e5e7eb; } 
    .vd-balance-amount { font-size: 26px; } 
}

/* ====================================================
   Histórico de Compras de Clientes — Timeline & Cards
   ==================================================== */

.woopanel-purchases-timeline {
    display: flex;
    flex-direction: column;
    gap: 16px;
    position: relative;
    padding: 4px 0;
}

.woopanel-purchases-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 32px 16px;
    color: var(--wp-text-muted, #64748b);
    font-size: 14px;
    gap: 10px;
}

.woopanel-loading-spinner {
    width: 28px;
    height: 28px;
    border: 3px solid rgba(99, 102, 241, 0.2);
    border-top-color: var(--wp-primary, #6366f1);
    border-radius: 50%;
    animation: wpSpin 0.8s linear infinite;
}

@keyframes wpSpin {
    to { transform: rotate(360deg); }
}

.woopanel-purchases-empty {
    text-align: center;
    padding: 36px 20px;
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.woopanel-purchases-empty svg {
    width: 36px;
    height: 36px;
    color: #94a3b8;
    margin-bottom: 4px;
}

.woopanel-purchases-empty .title {
    font-size: 15px;
    font-weight: 600;
    color: var(--wp-text, #1e293b);
    margin: 0;
}

.woopanel-purchases-empty .subtitle {
    font-size: 13px;
    color: var(--wp-text-muted, #64748b);
    margin: 0;
    max-width: 320px;
}

/* Purchase Card */
.purchase-card {
    display: flex;
    background: #ffffff;
    border: 1px solid var(--wp-border, #e2e8f0);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.purchase-card:hover {
    border-color: #cbd5e1;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.purchase-card.is-cancelled {
    background: #fafafa;
    border-color: #f1f5f9;
    opacity: 0.75;
}

.purchase-card.is-cancelled:hover {
    opacity: 1;
}

.purchase-card-left {
    width: 90px;
    min-width: 90px;
    background: #f8fafc;
    border-right: 1px solid var(--wp-border, #e2e8f0);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 14px 8px;
    text-align: center;
    flex-shrink: 0;
}

.purchase-date-badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1.1;
}

.purchase-date-badge .date-day {
    font-size: 20px;
    font-weight: 800;
    color: var(--wp-text, #1e293b);
}

.purchase-date-badge .date-month {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--wp-primary, #6366f1);
    text-transform: uppercase;
    margin-top: 2px;
}

.purchase-date-badge .date-year {
    font-size: 11px;
    color: #94a3b8;
    margin-top: 2px;
}

.purchase-time {
    font-size: 11px;
    font-weight: 600;
    color: #64748b;
    margin-top: 8px;
    padding: 2px 6px;
    background: rgba(148, 163, 184, 0.15);
    border-radius: 4px;
}

.purchase-card-body {
    flex: 1;
    min-width: 0;
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.purchase-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid #f1f5f9;
}

.purchase-badges-wrap {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.source-badge {
    display: inline-flex;
    align-items: center;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.source-badge.source-pdv {
    background: #e0f2fe;
    color: #0369a1;
}

.source-badge.source-fiado {
    background: #fef3c7;
    color: #b45309;
}

.source-badge.source-manual {
    background: #f1f5f9;
    color: #475569;
}

.source-badge.source-woocommerce {
    background: #ede9fe;
    color: #6d28d9;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 6px;
}

.status-badge.status-cancelled {
    background: #fee2e2;
    color: #b91c1c;
}

.status-badge.status-refunded {
    background: #e0e7ff;
    color: #4338ca;
}

.status-badge.status-pending {
    background: #fef9c3;
    color: #854d0e;
}

.purchase-order-ref {
    font-size: 12px;
    font-weight: 600;
    color: var(--wp-primary, #6366f1);
    background: rgba(99, 102, 241, 0.08);
    padding: 2px 7px;
    border-radius: 6px;
}

.purchase-card-total-badge {
    font-size: 14px;
}

.purchase-card-total-badge .total-label {
    font-size: 12px;
    color: var(--wp-text-muted, #64748b);
}

.purchase-card-total-badge .total-value {
    font-size: 15px;
    font-weight: 700;
    color: var(--wp-text, #0f172a);
}

.purchase-card-items-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 13px;
    color: var(--wp-text, #334155);
}

.purchase-card-item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.item-name-col {
    display: flex;
    align-items: baseline;
    gap: 6px;
    min-width: 0;
    flex: 1;
}

.item-bullet {
    color: #94a3b8;
    font-size: 14px;
}

.item-name {
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.item-variation {
    font-size: 11.5px;
    color: var(--wp-text-muted, #64748b);
    background: #f1f5f9;
    padding: 1px 5px;
    border-radius: 4px;
    white-space: nowrap;
}

.item-qty-col {
    font-size: 12px;
    color: var(--wp-text-muted, #64748b);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    text-align: right;
}

.purchase-card-no-items {
    font-size: 12.5px;
    color: var(--wp-text-muted, #94a3b8);
    padding: 4px 0;
}

.purchase-card-notes {
    font-size: 12px;
    color: #78350f;
    background: #fffbeb;
    border: 1px solid #fef3c7;
    border-radius: 6px;
    padding: 6px 10px;
    margin-top: 2px;
}

.purchase-card-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding-top: 6px;
    border-top: 1px dashed #f1f5f9;
}

.purchase-card-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}

.btn-card-action {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 500;
    color: #475569;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 4px 8px;
    cursor: pointer;
    transition: all 0.15s ease;
}

.btn-card-action:hover {
    background: #e2e8f0;
    color: #0f172a;
}

.btn-card-action svg {
    width: 13px;
    height: 13px;
}

/* Mobile Responsiveness for Purchases Timeline */
@media (max-width: 640px) {
    .purchase-card {
        flex-direction: column;
    }

    .purchase-card-left {
        width: 100%;
        min-width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--wp-border, #e2e8f0);
        flex-direction: row;
        justify-content: space-between;
        padding: 8px 14px;
    }

    .purchase-date-badge {
        flex-direction: row;
        gap: 6px;
    }

    .purchase-date-badge .date-day {
        font-size: 16px;
    }

    .purchase-time {
        margin-top: 0;
    }

    .purchase-card-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .purchase-card-item-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 2px;
    }

    .manual-item-row {
        grid-template-columns: 1fr !important;
        gap: 6px !important;
    }
}

/* ====================================================
   Galeria de Imagens do Produto (Edição / Criação)
   ==================================================== */
.existing-image-wrapper,
.new-local-image {
    position: relative;
    border-radius: 0.5rem;
    overflow: hidden;
    background-color: #f9fafb;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.existing-image-wrapper.is-capa,
.new-local-image.is-capa {
    border: 2px solid #eab308 !important;
}

.woopanel-btn-remove-img {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 26px;
    height: 26px;
    border-radius: 9999px;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(0, 0, 0, 0.12);
    color: #374151;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.18);
    transition: background-color 0.18s ease, color 0.18s ease, transform 0.18s ease, border-color 0.18s ease;
    z-index: 25;
    padding: 0;
    line-height: 1;
}

.woopanel-btn-remove-img:hover {
    background-color: #ef4444;
    border-color: #dc2626;
    color: #ffffff;
    transform: scale(1.1);
}

.woopanel-btn-remove-img svg {
    width: 14px;
    height: 14px;
    pointer-events: none;
}

.woopanel-badge-capa {
    position: absolute;
    top: 6px;
    left: 6px;
    background-color: #facc15;
    color: #713f12;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    z-index: 20;
    pointer-events: none;
    line-height: 1.2;
}

/* ====================================================
   Botão "Salvar Produto" / "Atualizar Produto"
   ==================================================== */
.woopanel-wrapper #btn-save-product,
.woopanel-wrapper #btn-save-product-top {
  min-height: 44px;
  background-color: #1d4ed8 !important;
  background-image: none !important;
  border-color: #1e40af !important;
    color: #ffffff !important;
  box-shadow: 0 2px 5px rgba(30, 64, 175, 0.25) !important;
    transition: background 0.2s ease, background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease !important;
}

.woopanel-wrapper #btn-save-product:hover,
.woopanel-wrapper #btn-save-product:focus,
.woopanel-wrapper #btn-save-product-top:hover,
.woopanel-wrapper #btn-save-product-top:focus {
    background-color: #1e40af !important;
    background-image: none !important;
    border-color: #1e3a8a !important;
    color: #ffffff !important;
    box-shadow: 0 4px 10px rgba(30, 64, 175, 0.35) !important;
    filter: none !important;
}

.woopanel-wrapper #btn-save-product:active,
.woopanel-wrapper #btn-save-product-top:active {
    background-color: #1e3a8a !important;
    background-image: none !important;
    transform: translateY(1px) !important;
}

/* ====================================================
   Barra de Pesquisa de Produtos (Meus Produtos)
   ==================================================== */
.woopanel-wrapper .woopanel-products-search {
    position: relative;
    display: block;
}

.woopanel-wrapper .woopanel-products-search > svg {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    pointer-events: none;
    z-index: 1;
}

.woopanel-wrapper .woopanel-products-search #woopanel-search-products,
.woopanel-wrapper .woopanel-products-search input {
    padding-left: 2.5rem; /* ~40px, espaço para o ícone */
}

/* ====================================================
   Tabela e Cards de Produtos (Meus Produtos)
   ==================================================== */
.woopanel-wrapper .woopanel-products-table-wrap {
    display: block;
    width: 100%;
    overflow-x: auto;
}

.woopanel-wrapper .woopanel-products-cards-wrap {
    display: none;
}

@media (max-width: 767px) {
    .woopanel-wrapper .woopanel-products-table-wrap {
        display: none;
    }
    .woopanel-wrapper .woopanel-products-cards-wrap {
        display: block;
    }
}

/* ====================================================
   Botões de Ação da Tabela Meus Produtos (Neon Palette)
   ==================================================== */
.woopanel-wrapper .btn-fast-edit,
.woopanel-wrapper .btn-fast-duplicate,
.woopanel-wrapper .btn-fast-delete {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 6px !important;
    min-width: 42px !important;
    min-height: 42px !important;
    padding: 10px !important;
    border: none !important;
    cursor: pointer !important;
    line-height: 1 !important;
    transition: background 0.18s ease, background-color 0.18s ease, box-shadow 0.18s ease, transform 0.15s ease !important;
}

.woopanel-wrapper .btn-fast-delete {
  margin-left: 8px !important;
  border-left: 1px solid rgba(107, 114, 128, 0.35) !important;
}

.woopanel-wrapper .btn-fast-edit svg,
.woopanel-wrapper .btn-fast-duplicate svg,
.woopanel-wrapper .btn-fast-delete svg {
    width: 16px !important;
    height: 16px !important;
    color: #ffffff !important;
    stroke: #ffffff !important;
    fill: none !important;
    stroke-width: 2px !important;
    pointer-events: none !important;
}

/* 1. Editar (Amarelo Neon) */
.woopanel-wrapper .btn-fast-edit {
    background-color: #f59e0b !important;
    background-image: linear-gradient(135deg, #facc15 0%, #f59e0b 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 2px 6px -1px rgba(245, 158, 11, 0.45) !important;
}

.woopanel-wrapper .btn-fast-edit:hover,
.woopanel-wrapper .btn-fast-edit:focus {
    background-color: #d97706 !important;
    background-image: linear-gradient(135deg, #f59e0b 0%, #d97706 100%) !important;
    box-shadow: 0 4px 10px -2px rgba(217, 119, 6, 0.6) !important;
    transform: translateY(-1px) scale(1.05) !important;
}

.woopanel-wrapper .btn-fast-edit:active {
    background-color: #b45309 !important;
    background-image: linear-gradient(135deg, #d97706 0%, #b45309 100%) !important;
    transform: translateY(1px) scale(0.98) !important;
}

/* 2. Duplicar (Verde Neon) */
.woopanel-wrapper .btn-fast-duplicate {
    background-color: #10b981 !important;
    background-image: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 2px 6px -1px rgba(16, 185, 129, 0.45) !important;
}

.woopanel-wrapper .btn-fast-duplicate:hover,
.woopanel-wrapper .btn-fast-duplicate:focus {
    background-color: #047857 !important;
    background-image: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
    box-shadow: 0 4px 10px -2px rgba(4, 120, 87, 0.6) !important;
    transform: translateY(-1px) scale(1.05) !important;
}

.woopanel-wrapper .btn-fast-duplicate:active {
    background-color: #065f46 !important;
    background-image: linear-gradient(135deg, #047857 0%, #065f46 100%) !important;
    transform: translateY(1px) scale(0.98) !important;
}

/* 3. Excluir (Vermelho Neon) */
.woopanel-wrapper .btn-fast-delete {
    background-color: #ef4444 !important;
    background-image: linear-gradient(135deg, #f87171 0%, #ef4444 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 2px 6px -1px rgba(239, 68, 68, 0.45) !important;
}

.woopanel-wrapper .btn-fast-delete:hover,
.woopanel-wrapper .btn-fast-delete:focus {
    background-color: #dc2626 !important;
    background-image: linear-gradient(135deg, #ef4444 0%, #dc2626 100%) !important;
    box-shadow: 0 4px 10px -2px rgba(220, 38, 38, 0.6) !important;
    transform: translateY(-1px) scale(1.05) !important;
}

.woopanel-wrapper .btn-fast-delete:active {
    background-color: #b91c1c !important;
    background-image: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%) !important;
    transform: translateY(1px) scale(0.98) !important;
}

