.paneld {
  background: #ecf0f3; /* Blanco limpio en vez de #ecf0f3 para mejor contraste */
  border: 1px solid #e2e8f0; /* Borde gris claro sutil */
  border-radius: 16px;
  padding: 20px; /* Quitamos padding general → lo ponemos por sección */
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
  overflow: hidden; /* Para que los bordes redondeados corten bien */
  transition: all 0.3s ease;
}
.cont-header-vent {
  margin-left: -14px;
  margin-right: -14px;
  margin-top: -15px;
  margin-bottom: 24px;
  padding: 12px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  border-bottom: 2px solid #062a56;
}

/* Botón Recargar con animación */
#vtReload {
  position: relative;
  overflow: hidden;
  transition: all 0.25s ease;
  background: var(--btn);
  border: none;
  font-weight: 600;
}

/* Efecto hover */
#vtReload:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(99, 102, 241, 0.4);
  background: #062a56;
}

/* Efecto ripple al hacer click */
#vtReload:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

/* Spinner cuando está cargando */
#vtReload.loading {
  pointer-events: none;
  color: transparent !important;
}

#vtReload.loading::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border: 2.5px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}

@keyframes spin {
  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}
#vtReload {
  display: flex;
  align-items: center;
  gap: 8px;
}

#vtReload.loading::before {
  content: "↻";
  display: inline-block;
  animation: spin 1.2s linear infinite;
  font-weight: bold;
}

.header-modal {
  margin-left: -14px;
  margin-right: -14px;
  margin-top: -15px;
  margin-bottom: 24px;
  padding: 12px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  border-bottom: 2px solid #062a56;
}
.cards input,
select {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1.5px solid #062a56;
  background: transparent;
  transition: all 0.25s ease;
}
.cards label {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 6px;
  display: inline-block;
}
/*mostrar lista clientes*/
.cliente-item {
  padding: 16px 20px;
  border-bottom: 2px solid #0c4594;
  background-color: #ffffff;
  cursor: pointer;
  transition: all 0.25s ease;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* Hover elegante */
.cliente-item:hover {
  background-color: #ecf0f3;
  border-left: 4px solid #062a56;
  padding-left: 16px; /* compensa el border-left */
}

/* Nombre del cliente */
.cliente-nombre {
  font-weight: 700;
  font-size: 1rem;
  color: #0d1f3c;
  letter-spacing: 0.3px;
}

/* Información secundaria */
.cliente-detalle {
  font-size: 0.85rem;
  color: #1d1f23;
}
/* ────────────────────────────────────────────────
   Tabla de items - Estilo Premium Corporativo
──────────────────────────────────────────────── */

.item-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-family: "Inter", "Segoe UI", system-ui, sans-serif;
  font-size: 0.95rem;
  color: #1e293b;
  background: #ffffff;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border-radius: 12px;
  overflow: hidden;
}

/* Cabecera */
.item-table thead th {
  background: #0a1f44; /* azul muy oscuro corporativo */
  color: #f1f5f9;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  font-size: 0.82rem;
  padding: 14px 12px;
  border-bottom: 2px solid #1e40af;
  text-align: left;
}

.item-table thead th:nth-child(3),
.item-table thead th:nth-child(4),
.item-table thead th:nth-child(5),
.item-table thead th:nth-child(6),
.item-table thead th:nth-child(7) {
  text-align: center;
}

/* Filas */
.item-table tbody tr {
  transition: all 0.18s ease;
  background: #ffffff;
}

.item-table tbody tr:hover {
  background: #f8fafc;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px -4px rgba(0, 0, 0, 0.07);
}

/* Celdas base */
.item-table td {
  padding: 14px 12px;
  border-bottom: 1px solid #0c4594;
  vertical-align: middle;
}

/* Última fila sin borde inferior */
.item-table tbody tr:last-child td {
  border-bottom: none;
}

/* Colores y alineaciones específicas */
.nombre-col {
  font-weight: 600;
  color: #062a56;
}
.catalogo-col {
  color: #252930;
  font-size: 0.92rem;
}
.cantidad-col {
  text-align: center;
  font-weight: 600;
}
.precio-col {
  text-align: right;
  font-weight: 500;
  color: #151a21;
}
.descuento-col {
  text-align: right;
  padding: 8px 12px !important;
}
.subtotal-col {
  text-align: right;
  font-weight: 700;
  color: #0c4594; /* azul corporativo principal */
  font-size: 1.03rem;
  letter-spacing: -0.2px;
}
.envio-fisico-col {
  text-align: center;
}
.eliminar-col {
  text-align: center;
  padding: 8px 12px !important;
}

/* Input descuento - aspecto premium */
.descuento-input {
  width: 100px;
  padding: 8px 10px;
  text-align: right;
  border: 1.5px solid #062a56;
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.94rem;
  font-weight: 500;
  background: #f8fafc;
  transition: all 0.2s ease;
}

.descuento-input:focus {
  outline: none;
  border-color: #1e40af;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.18);
  background: #ffffff;
}

/* Checkbox envío físico */
.envio-fisico-check {
  width: 18px;
  height: 18px;
  accent-color: #0c4594;
  cursor: pointer;
}

/* Botón eliminar - estilo corporativo */
.btn-eliminar {
  width: 32px;
  height: 32px;
  line-height: 32px;
  padding: 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: #ef4444;
  background: #fee2e2;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-eliminar:hover {
  background: #fecaca;
  transform: scale(1.08);
  color: #d90000;
}

.btn-eliminar:active {
  transform: scale(0.96);
}

/* =========================
   MODAL OVERLAY
========================= */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(6, 42, 86, 0.45);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 2000;
  animation: fadeIn 0.25s ease;
}

/* ocultar */
.hidden {
  display: none;
}

/* =========================
   MODAL CARD
========================= */
.modal-card {
  width: 720px;
  max-width: 95vw;
  background: #ffffff;
  border-radius: 18px;
  padding: 28px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(6, 42, 86, 0.08);
  animation: slideUp 0.3s ease;
}

/* =========================
   HEADER
========================= */
.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 25px;
}

.modal-header h3 {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  color: #062a56;
}

.modal-subtitle {
  font-size: 14px;
  color: #6c757d;
  margin-top: 4px;
}

/* =========================
   GRID FORM
========================= */
.modal-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 16px;
}

.form-group {
  grid-column: span 6;
  display: flex;
  flex-direction: column;
}

.form-group.full {
  grid-column: span 12;
}

.form-group label {
  font-size: 13px;
  margin-bottom: 6px;
  color: #062a56;
  font-weight: 600;
}

/* =========================
   INPUTS
========================= */
.modal-card input,
.modal-card select,
.modal-card textarea {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #d0d7e2;
  font-size: 14px;
  transition: all 0.2s ease;
  background: #f9fbfd;
}

.modal-card input:focus,
.modal-card select:focus,
.modal-card textarea:focus {
  outline: none;
  border-color: #062a56;
  box-shadow: 0 0 0 3px rgba(6, 42, 86, 0.15);
  background: #ffffff;
}

/* =========================
   FOOTER
========================= */
.modal-footer {
  margin-top: 30px;
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

/* BOTONES */
.btn-primary {
  background: #062a56;
  color: white;
  border: none;
  padding: 10px 18px;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s ease;
}

.btn-primary:hover {
  background: #0a3a75;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(6, 42, 86, 0.35);
}

.btn-danger {
  background: #dc3545;
  color: white;
  border: none;
  padding: 10px 18px;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s ease;
}

.btn-danger:hover {
  background: #b02a37;
  transform: translateY(-2px);
}

/* =========================
   ANIMACIONES
========================= */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }

  100% {
    background-position: -200% 0;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.cx-kpi-val {
  animation: fadeInUp 0.4s ease forwards;
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 768px) {
  .modal-card {
    padding: 20px;
  }

  .form-group {
    grid-column: span 12;
  }

  .modal-footer {
    flex-direction: column;
  }

  .btn-primary,
  .btn-danger {
    width: 100%;
  }
}
