/* ========================================
   COMPONENTE DATATABLE REUTILIZABLE
   ======================================== */

.data-table-container {
  margin-top: 1.5rem;
  overflow-x: auto;
  background-color: #ffffff;
  border-radius: 0.75rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  border: 1px solid #e5e7eb;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  background-color: #ffffff;
  margin: 0;
}

.data-table th {
  background-color: #1f2937;
  padding: 1.25rem 1.5rem;
  text-align: left;
  font-weight: 700;
  color: #ffffff;
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  border: none;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.2;
}

.data-table td {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid #f3f4f6;
  color: #374151;
  font-size: 0.9rem;
  font-weight: 500;
  vertical-align: middle;
  line-height: 1.4;
}

.data-table tbody tr:hover {
  background-color: #f9fafb;
}

.data-table tbody tr:last-child td {
  border-bottom: none;
}

/* Fila removida */
.data-table tbody tr.removed-row {
  background-color: #fef2f2;
  opacity: 0.6;
}

.data-table tbody tr.removed-row td {
  color: #dc2626;
  text-decoration: line-through;
}

.data-table td.no-data {
  text-align: center;
  color: #6b7280;
  font-style: italic;
  padding: 2rem;
}

/* Botón de acción reutilizable */
.action-button {
  width: 2.5rem;
  height: 2.5rem;
  background-color: #3b82f6;
  border: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(59, 130, 246, 0.3);
  margin: 0 auto;
  min-width: 2.5rem;
  min-height: 2.5rem;
}

.action-button:hover {
  background-color: #2563eb;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(59, 130, 246, 0.4);
}

.action-button:active {
  transform: translateY(0);
}

.action-button svg {
  width: 1rem;
  height: 1rem;
  color: #ffffff;
  stroke-width: 2;
}

/* Variantes de botones de acción */
.action-button.success {
  background-color: #10b981;
}

.action-button.success:hover {
  background-color: #059669;
}

.action-button.danger {
  background-color: #ef4444;
}

.action-button.danger:hover {
  background-color: #dc2626;
}

.action-button.warning {
  background-color: #f59e0b;
}

.action-button.warning:hover {
  background-color: #d97706;
}

/* Responsive */
@media (max-width: 768px) {
  .data-table th,
  .data-table td {
    padding: 0.75rem 1rem;
    font-size: 0.8rem;
  }

  .action-button {
    width: 2rem;
    height: 2rem;
    min-width: 2rem;
    min-height: 2rem;
  }

  .action-button svg {
    width: 0.875rem;
    height: 0.875rem;
  }
}
