/* COPAE - Estilos principales - Diseño minimalista y profesional */

/* Fuentes y resets */
* {
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  margin: 0;
  padding: 0;
  background-color: #E2F0F1;
  color: #333;
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 300;
  margin: 0 0 1rem 0;
  color: #034ea2;
}

/* Layout principal */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.header {
  background-color: #D9E9F0;
  padding: 1rem 0;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.logo {
  text-align: center;
}

.logo img {
  max-width: 163px;
  height: auto;
}

/* Navegación */
.nav {
  background-color: #fff;
  border-top: 1px solid #ddd;
  border-bottom: 1px solid #ddd;
  padding: 0.75rem 0;
}

.nav-buttons {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.nav-btn {
  background-color: #034ea2;
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  transition: background-color 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.nav-btn:hover {
  background-color: #023e8b;
}

/* Contenido principal */
.main-content {
  padding: 2rem 0;
  min-height: calc(100vh - 200px); /* Ajustar height según header/footer */
}

/* Grid de productos */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin: 2rem 0;
}

.product-card {
  background: white;
  border: 1px solid #ddd;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.product-header {
  background-color: #C8DEEA;
  padding: 1rem;
  text-align: center;
}

.product-title {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 600;
  color: #034ea2;
}

.product-image {
  display: flex;
  justify-content: center;
  padding: 1.5rem;
  background-color: #fafafa;
}

.product-image img {
  max-width: 225px;
  max-height: 225px;
  object-fit: contain;
}

.product-price {
  text-align: center;
  padding: 1rem;
  font-size: 1.1rem;
  font-weight: 700;
  color: #034ea2;
}

.product-actions {
  padding: 1rem;
  text-align: center;
}

/* Formularios */
.form-container {
  background: white;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 2rem;
  margin: 2rem auto;
  max-width: 500px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
}

.form-title {
  text-align: center;
  margin-bottom: 1.5rem;
  font-size: 1.5rem;
  color: #034ea2;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: #555;
}

.form-input {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-input:focus {
  outline: none;
  border-color: #034ea2;
  box-shadow: 0 0 0 2px rgba(3, 78, 162, 0.1);
}

.btn {
  background-color: #034ea2;
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 500;
  text-decoration: none;
  display: inline-block;
  text-align: center;
  transition: background-color 0.3s ease;
}

.btn:hover {
  background-color: #023e8b;
}

.btn-primary {
  background-color: #034ea2;
}

.btn-primary:hover {
  background-color: #023e8b;
}

.btn-secondary {
  background-color: #6c757d;
}

.btn-secondary:hover {
  background-color: #5a6268;
}

.btn-full {
  width: 100%;
  margin-bottom: 0.5rem;
}

/* Checkbox styles */
.checkbox-container {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 0.9rem;
  color: #555;
}

.checkbox-container input[type="checkbox"] {
  margin-top: 0.1rem;
  flex-shrink: 0;
}

.terms-link {
  color: #034ea2;
  text-decoration: none;
  font-weight: 500;
}

.terms-link:hover {
  text-decoration: underline;
}

/* Forgot password link */
.forgot-password-link {
  color: #034ea2;
  text-decoration: underline;
  font-size: 0.85rem;
  font-weight: 500;
  display: inline-block;
  margin-top: 0.25rem;
  margin-bottom: 1rem;
  cursor: pointer;
}

.forgot-password-link:hover {
  color: #023e8b;
  text-decoration: underline;
}

/* Footer */
.footer {
  background-color: #D9E9F0;
  padding: 1rem 0;
  text-align: center;
  border-top: 1px solid #ddd;
  color: #666;
  font-size: 0.9rem;
}

/* Utilidades */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }

/* Responsive */
@media (max-width: 768px) {
  .nav-buttons {
    justify-content: center;
  }

  .products-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
  }

  .form-container {
    margin: 1rem;
    padding: 1.5rem;
  }
}

@media (max-width: 480px) {
  .products-grid {
    grid-template-columns: 1fr;
  }

  .nav-btn {
    padding: 0.4rem 0.8rem;
    font-size: 0.8rem;
  }
}

/* Carrito de Compras */
.cart-items {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  margin-bottom: 2rem;
}

.cart-item {
  display: flex;
  align-items: center;
  padding: 1.5rem;
  border-bottom: 1px solid #eee;
  gap: 1rem;
}

.cart-item:last-child {
  border-bottom: none;
}

.cart-item-info {
  flex: 1;
}

.cart-item-info h4 {
  margin: 0 0 0.5rem 0;
  color: #034ea2;
  font-size: 1.1rem;
}

.cart-item-detail {
  margin: 0;
  color: #666;
  font-size: 0.9rem;
}

.cart-item-price {
  min-width: 100px;
  text-align: right;
  font-weight: 600;
  color: #034ea2;
}

.cart-item-actions {
  min-width: 100px;
}

.cart-total {
  background: white;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 2rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  text-align: center;
}

.total-amount {
  margin-bottom: 1.5rem;
}

.total-amount h3 {
  margin: 0;
  color: #034ea2;
  font-size: 1.5rem;
}

/* Tabla de compras (mis_compras) */
.purchases-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.purchases-table th {
  background-color: #C8DEEA;
  color: #034ea2;
  font-weight: 600;
  padding: 1rem 0.5rem;
  text-align: left;
  font-size: 0.9rem;
}

.purchases-table td {
  padding: 1rem 0.5rem;
  border-bottom: 1px solid #eee;
  font-size: 0.9rem;
}

.purchases-table tr:hover {
  background-color: #f9f9f9;
}

.reembolso-btn {
  background-color: #dc3545;
  color: white;
  border: none;
  padding: 0.4rem 0.8rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.8rem;
  transition: background-color 0.3s ease;
}

.reembolso-btn:hover {
  background-color: #c82333;
}

/* Estilos legacy para compatibilidad */
/* Mantener algunos estilos para no romper funcionalidad existente */
.Estilo1 {
  font-size: 18px;
  font-weight: bold;
}

.cmbforms {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  font-size: 11px;
}

.OKcampo {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  font-size: 11px;
}
