/* ========================================
   PÁGINA DE PRODUCTOS
   ======================================== */

/* Header de la página */
.pageHeader {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 3px solid #001D3D;
}

.pageHeader h1 {
  font-family: 'Anton', sans-serif;
  text-transform: uppercase;
  color: #001D3D;
  font-size: 2rem;
  margin: 0;
}

/* Botones principales */
.primaryBtn {
  background-color: #001D3D;
  color: white;
  border: none;
  border-radius: 8px;
  padding: 12px 24px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.primaryBtn:hover {
  background-color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 29, 61, 0.3);
}

.secondaryBtn {
  background-color: #001D3D;
  color: white;
  border: none;
  border-radius: 8px;
  padding: 10px 20px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s ease;
}

.secondaryBtn:hover {
  background-color: #ffffff;
}

.dangerBtn {
  background-color: #dc3545;
  color: white;
  border: none;
  border-radius: 8px;
  padding: 10px 20px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s ease;
}

.dangerBtn:hover {
  background-color: #fff;
  color: #c82333;
  border-color: #c82333;

}

/* Contenedor de tabla */
.tableContainer {
  background-color: #fff;
  border-radius: 15px;
  padding: 2rem;
  box-shadow: 0 4px 6px rgba(0, 29, 61, 0.1);
  border: 1px solid #001d3d20;
}

/* Tabla de productos */
.productsTable {
  width: 100%;
  border-collapse: collapse;
  font-family: Arial, Helvetica, sans-serif;
}

.productsTable thead {
  background-color: #001D3D;
  color: white;
}

.productsTable th {
  padding: 15px;
  text-align: left;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.5px;
}

.productsTable td {
  padding: 15px;
  border-bottom: 1px solid #EBF4FF;
  font-size: 0.95rem;
  color: #001D3D;
}

.productsTable tbody tr:hover {
  background-color: #f8f9fa;
  transition: background-color 0.2s ease;
}

.productsTable tbody tr:nth-child(even) {
  background-color: #fafbfc;
}

/* Botones de acción en tabla */
.actionBtn {
  background-color: transparent;
  border: none;
  color: #001D3D;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 5px 10px;
  margin: 0 3px;
  border-radius: 5px;
  transition: all 0.2s ease;
}

.actionBtn:hover {
  background-color: #EBF4FF;
  transform: scale(1.1);
}

.actionBtn.edit {
  color: #007bff;
}

.actionBtn.delete {
  color: #dc3545;
}

/* Mensaje sin datos */
.noDataMessage {
  text-align: center;
  padding: 3rem;
  font-family: Arial, Helvetica, sans-serif;
  color: #666;
  font-size: 1.1rem;
}

/* ========================================
   MODALES
   ======================================== */

.modal {
  display: none;
  position: fixed;
  z-index: 10000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(3px);
  animation: fadeIn 0.3s ease;
}

.modal.show {
  display: flex;
  justify-content: center;
  align-items: center;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modalContent {
  background-color: white;
  padding: 4%;
  border-radius: 15px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  width: 90%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  animation: slideIn 0.3s ease;
}

.modalSmall {
  max-width: 450px;
}

@keyframes slideIn {
  from {
    transform: translateY(-50px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.modalHeader {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 2rem;
  border-bottom: 2px solid #EBF4FF;
}

.modalHeader h2 {
  font-family: 'Anton', sans-serif;
  text-transform: uppercase;
  color: #001D3D;
  font-size: 1.5rem;
  margin: 0;
}

.closeBtn {
  background: none;
  border: none;
  font-size: 2rem;
  color: #001D3D;
  cursor: pointer;
  padding: 0;
  width: 35px;
  height: 35px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s ease;
}

.closeBtn:hover {
  background-color: #f0f0f0;
  color: #001D3D;
}

.modalBody {
  padding: 2rem;
  font-family: Arial, Helvetica, sans-serif;
}

.modalFooter {
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  padding: 1.5rem 2rem;
  border-top: 1px solid #EBF4FF;
}

/* Formulario */
.formGroup {
  margin-bottom: 1.5rem;
}

.formGroup label {
  display: block;
  font-family: Arial, Helvetica, sans-serif;
  font-weight: 600;
  color: #001D3D;
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.formGroup input,
.formGroup textarea {
  width: 100%;
  padding: 12px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 1rem;
  transition: border-color 0.3s ease;
  box-sizing: border-box;
}

.formGroup input:focus,
.formGroup textarea:focus {
  outline: none;
  border-color: #001D3D;
  box-shadow: 0 0 0 3px rgba(0, 29, 61, 0.1);
}

.formGroup textarea {
  resize: vertical;
  min-height: 100px;
}

/* Textos de advertencia */
.warningText {
  background-color: #fff3cd;
  border: 1px solid #ffc107;
  border-radius: 8px;
  padding: 12px;
  margin: 1rem 0;
  font-family: Arial, Helvetica, sans-serif;
  color: #001D3D;
}

.dangerText {
  color: #dc3545;
  font-weight: 600;
  font-family: Arial, Helvetica, sans-serif;
  margin-top: 0.5rem;
}

/* Responsive */
@media (max-width: 768px) {
  .pageHeader {
    flex-direction: column;
    gap: 1rem;
    align-items: flex-start;
  }

  .pageHeader h1 {
    font-size: 1.5rem;
  }

  .tableContainer {
    overflow-x: auto;
  }

  .productsTable {
    min-width: 700px;
  }

  .modalContent {
    width: 95%;
    max-width: none;
  }
}