/* Tarjeta separada de datos personales */
.carrito-datos-tarjeta-container {
  margin-top: 1.5rem;
  border-top: 2px solid #e5e7eb;
  padding-top: 1.5rem;
}

.carrito-datos-tarjeta {
  background: linear-gradient(135deg, #f8fafc 0%, #e0f2fe 100%);
  border: 2px solid #3b82f6;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

/* Sección de datos de envío dentro de la tarjeta */
.datos-envio-tarjeta {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e5e7eb;
}

.datos-envio-tarjeta h4 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 1rem;
}

.datos-envio-tarjeta h4 i {
  color: #10b981;
  font-size: 1.125rem;
}

.envio-opciones-tarjeta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

.envio-opcion-tarjeta {
  position: relative;
  cursor: pointer;
}

.envio-opcion-tarjeta input[type="radio"] {
  position: absolute;
  opacity: 0;
}

.envio-card-tarjeta {
  padding: 1rem;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  transition: all 0.3s ease;
  background: white;
}

.envio-opcion-tarjeta input[type="radio"]:checked + .envio-card-tarjeta {
  border-color: #10b981;
  background: rgba(16, 185, 129, 0.05);
  transform: scale(1.02);
}

.envio-card-tarjeta i {
  font-size: 1.25rem;
  color: #10b981;
  width: 24px;
  text-align: center;
}

.envio-card-tarjeta div {
  flex: 1;
}

.envio-card-tarjeta strong {
  display: block;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 0.25rem;
}

.envio-card-tarjeta small {
  color: #64748b;
  font-size: 0.875rem;
}

/* Sección de forma de pago dentro de la tarjeta */
.forma-pago-tarjeta {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e5e7eb;
}

.forma-pago-tarjeta h4 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 1rem;
}

.forma-pago-tarjeta h4 i {
  color: #8b5cf6;
  font-size: 1.125rem;
}

.pago-mensaje-tarjeta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem;
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid #8b5cf6;
  border-radius: 6px;
  font-size: 0.875rem;
  color: #5b21b6;
}

.pago-mensaje-tarjeta i {
  color: #8b5cf6;
  font-size: 1rem;
}

.carrito-datos-tarjeta h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.125rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid #3b82f6;
}

.carrito-datos-tarjeta h3 i {
  color: #3b82f6;
  font-size: 1.25rem;
}

/* Formulario dentro de la tarjeta */
.form-datos-tarjeta {
  display: grid;
  gap: 1rem;
}

.form-datos-tarjeta .form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 0;
}

.form-datos-tarjeta .form-group {
  margin-bottom: 0;
}

.form-datos-tarjeta .form-group label {
  display: block;
  font-weight: 500;
  color: #374151;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
}

.form-datos-tarjeta .form-group input,
.form-datos-tarjeta .form-group select {
  width: 100%;
  padding: 0.75rem;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 0.875rem;
  transition: all 0.3s ease;
  background: white;
}

.form-datos-tarjeta .form-group input:focus,
.form-datos-tarjeta .form-group select:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Resumen de datos dentro de la tarjeta */
.datos-resumen-tarjeta {
  display: grid;
  gap: 0.75rem;
}

.resumen-dato-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  background: white;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
}

.resumen-dato-item i {
  color: #3b82f6;
  width: 20px;
  text-align: center;
  font-size: 1rem;
}

.resumen-dato-item span {
  color: #374151;
  font-size: 0.875rem;
}

.resumen-dato-item strong {
  color: #1f2937;
  font-weight: 600;
}

.btn-editar-datos-tarjeta {
  background: #3b82f6;
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1rem;
  width: 100%;
  justify-content: center;
}

.btn-editar-datos-tarjeta:hover {
  background: #2563eb;
  transform: translateY(-1px);
}

/* Responsive para la tarjeta */
@media (max-width: 768px) {
  .form-datos-tarjeta .form-row {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }
  
  .carrito-datos-tarjeta {
    padding: 1rem;
  }
  
  .carrito-datos-tarjeta h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
  }
}

/* Modal de pago exitoso */
.pago-exitoso-contenido {
  text-align: center;
  padding: 2rem;
}

.exito-icono {
  font-size: 4rem;
  color: #10b981;
  margin-bottom: 1.5rem;
}

.exito-icono i {
  animation: checkPulse 0.6s ease-in-out;
}

@keyframes checkPulse {
  0% { transform: scale(0); opacity: 0; }
  50% { transform: scale(1.2); }
  100% { transform: scale(1); opacity: 1; }
}

.pago-exitoso-contenido h3 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 1rem;
}

.pago-exitoso-contenido p {
  color: #6b7280;
  font-size: 1rem;
  margin-bottom: 0.75rem;
  line-height: 1.6;
}

.btn-finalizar-exito {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: white;
  border: none;
  padding: 1rem 2rem;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 2rem;
}

.btn-finalizar-exito:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(16, 185, 129, 0.3);
}

.btn-finalizar-exito:active {
  transform: translateY(0);
}

/* Estilos para el Sistema de Carrito de Compras */

/* Formulario de datos del carrito */
.carrito-datos-form {
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 1rem;
  margin-top: 1rem;
}

.carrito-datos-form h3 {
  font-size: 1rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.form-group {
  margin-bottom: 0.75rem;
}

.form-group label {
  display: block;
  font-weight: 500;
  margin-bottom: 0.25rem;
  color: #374151;
  font-size: 0.875rem;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 0.5rem;
  border: 2px solid #e5e7eb;
  border-radius: 6px;
  font-size: 0.875rem;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: #3b82f6;
}
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 1000;
}

.modal.active {
  display: flex;
  opacity: 1;
  visibility: visible;
}

.compra-modal-content {
  max-width: 800px;
  width: 90%;
  max-height: 95vh;
  overflow-y: auto;
  background: white;
  border-radius: 16px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  position: relative;
  margin: auto;
  display: flex;
  flex-direction: column;
}

.compra-modal-header {
  padding: 1rem 1.5rem 0.75rem;
  border-bottom: 1px solid #e5e7eb;
  text-align: center;
}

.compra-modal-header h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 0.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.compra-resumen {
  color: #6b7280;
  font-size: 0.875rem;
}

.compra-modal-body {
  padding: 0.75rem 1.5rem 1.5rem;
  max-height: none;
  overflow-y: visible;
}

.compra-section {
  margin-bottom: 2rem;
}

.compra-section h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.125rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #3b82f6;
}

.compra-section h3 i {
  color: #3b82f6;
  font-size: 1.25rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: #1f2937;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.75rem;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: #3b82f6;
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

/* Opciones de envío */
.envio-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.envio-option {
  position: relative;
  cursor: pointer;
}

.envio-option input[type="radio"] {
  position: absolute;
  opacity: 0;
}

.envio-card {
  padding: 1rem;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  text-align: center;
  transition: all 0.3s ease;
  background: white;
}

.envio-option input[type="radio"]:checked + .envio-card {
  border-color: #3b82f6;
  background: rgba(59, 130, 246, 0.05);
  transform: scale(1.02);
}

.envio-titulo {
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 0.5rem;
}

.envio-tiempo {
  font-size: 0.875rem;
  color: #6b7280;
  margin-bottom: 0.5rem;
}

.envio-precio {
  font-weight: 700;
  color: #3b82f6;
}

/* Opciones de pago */
.pago-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.pago-option {
  position: relative;
  cursor: pointer;
}

.pago-option input[type="radio"] {
  position: absolute;
  opacity: 0;
}

.pago-card {
  padding: 1rem;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  text-align: center;
  transition: all 0.3s ease;
  background: white;
}

.pago-option input[type="radio"]:checked + .pago-card {
  border-color: #3b82f6;
  background: rgba(59, 130, 246, 0.05);
  transform: scale(1.02);
}

.pago-titulo {
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 0.5rem;
}

.pago-descuento {
  font-size: 0.875rem;
  color: #10b981;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.pago-detalles {
  font-size: 0.75rem;
  color: #6b7280;
  text-align: left;
  margin-top: 0.5rem;
}

/* Resumen del pedido */
.resumen-pedido {
  background: #f9fafb;
  padding: 1.5rem;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
}

.resumen-item {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
}

.resumen-item.total {
  font-weight: 700;
  font-size: 1.125rem;
  color: #1f2937;
  padding-top: 0.5rem;
  border-top: 2px solid #e5e7eb;
  margin-top: 0.5rem;
}

/* Términos y condiciones */
.terminos-checkbox {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.875rem;
  color: #6b7280;
}

.terminos-checkbox input[type="checkbox"] {
  margin: 0;
}

.metodos-pago {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.metodo-pago {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.metodo-pago:hover {
  border-color: #3b82f6;
}

.metodo-pago input[type="radio"] {
  margin: 0;
}

.metodo-pago input[type="radio"]:checked + span {
  color: #3b82f6;
  font-weight: 600;
}

.resumen-compra {
  background: #f9fafb;
  padding: 1.5rem;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
}

.resumen-item {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
}

.resumen-item.total {
  font-weight: 700;
  font-size: 1.125rem;
  color: #1f2937;
  padding-top: 0.5rem;
  border-top: 2px solid #e5e7eb;
  margin-top: 0.5rem;
}

.compra-modal-footer {
  padding: 1.5rem 2rem;
  border-top: 1px solid #e5e7eb;
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  align-items: center;
}

/* Productos en el carrito */
.carrito-productos {
  max-height: 400px;
  overflow-y: auto;
  margin-bottom: 20px;
}

.carrito-vacio {
  text-align: center;
  padding: 40px 20px;
  color: #6b7280;
}

.carrito-vacio i {
  font-size: 48px;
  margin-bottom: 15px;
  color: #d1d5db;
}

.carrito-producto-item {
  display: flex;
  align-items: center;
  padding: 15px;
  border-bottom: 1px solid #e5e7eb;
  gap: 15px;
  background: white;
  border-radius: 8px;
  margin-bottom: 10px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.carrito-producto-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.carrito-producto-info {
  flex: 1;
}

.carrito-producto-info h4 {
  font-size: 16px;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 5px;
}

.carrito-producto-precio {
  font-size: 14px;
  color: #6b7280;
  font-weight: 500;
}

.carrito-producto-cantidad {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-cantidad {
  background: #f3f4f6;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s ease;
}

.btn-cantidad:hover {
  background: #e5e7eb;
}

.btn-cantidad:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.carrito-producto-cantidad span {
  min-width: 20px;
  text-align: center;
  font-weight: 600;
}

.carrito-producto-subtotal {
  font-weight: 600;
  color: #1f2937;
  min-width: 80px;
  text-align: right;
}

.btn-eliminar {
  background: none;
  border: none;
  color: #ef4444;
  cursor: pointer;
  padding: 5px;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.btn-eliminar:hover {
  background: #fef2f2;
}

/* Modal close button */
.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 28px;
  cursor: pointer;
  color: #6b7280;
  padding: 1rem;
  border-radius: 8px;
  transition: all 0.2s ease;
  z-index: 9999;
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  pointer-events: auto !important;
}

.modal-close:hover {
  background: #f3f4f6;
  color: #1f2937;
  transform: scale(1.1);
}

/* Contador del carrito flotante */
.carrito-contenedor {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 1000;
}

.carrito-btn {
  background: #3b82f6;
  color: white;
  border: none;
  border-radius: 50%;
  width: 60px;
  height: 60px;
  font-size: 24px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
  transition: all 0.3s ease;
  position: relative;
}

.carrito-btn:hover {
  background: #2563eb;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(59, 130, 246, 0.4);
}

.carrito-contador {
  position: absolute;
  top: -5px;
  right: -5px;
  background: #ef4444;
  color: white;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: bold;
}

body.carrito-abierto .carrito-contenedor {
  display: none !important;
}

/* Modal del carrito */
.carrito-content {
  max-width: 600px;
  width: 90%;
  max-height: 80vh;
  overflow-y: auto;
}

.carrito-productos {
  max-height: 400px;
  overflow-y: auto;
  margin-bottom: 20px;
}

.carrito-vacio {
  text-align: center;
  padding: 40px 20px;
  color: #6b7280;
}

.carrito-vacio i {
  font-size: 48px;
  margin-bottom: 15px;
  color: #d1d5db;
}

/* Productos en el carrito */
.carrito-producto {
  display: flex;
  align-items: center;
  padding: 15px;
  border-bottom: 1px solid #e5e7eb;
  gap: 15px;
}

.carrito-producto:last-child {
  border-bottom: none;
}

.carrito-producto-info {
  flex: 1;
}

.carrito-producto-info h4 {
  font-size: 16px;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 5px;
}

.carrito-producto-precio {
  font-size: 14px;
  color: #6b7280;
  font-weight: 500;
}

.carrito-producto-cantidad {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-cantidad {
  background: #f3f4f6;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s ease;
}

.btn-cantidad:hover {
  background: #e5e7eb;
}

.btn-cantidad:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.carrito-producto-cantidad span {
  min-width: 20px;
  text-align: center;
  font-weight: 600;
}

.carrito-producto-subtotal {
  font-weight: 600;
  color: #1f2937;
  min-width: 80px;
  text-align: right;
}

.btn-eliminar {
  background: none;
  border: none;
  color: #ef4444;
  cursor: pointer;
  padding: 5px;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.btn-eliminar:hover {
  background: #fef2f2;
}

/* Acciones del carrito */
.carrito-acciones {
  display: flex;
  gap: 10px;
  padding: 15px 0;
  border-top: 1px solid #e5e7eb;
  margin-top: 15px;
}

/* Totales del carrito */
.carrito-totales {
  background: #f9fafb;
  padding: 20px;
  border-top: 1px solid #e5e7eb;
}

.total-item {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 14px;
}

.total-item:last-child {
  margin-bottom: 0;
}

.total-final {
  font-weight: 700;
  font-size: 18px;
  color: #1f2937;
  padding-top: 10px;
  border-top: 1px solid #e5e7eb;
}

/* Notificaciones */
.notificacion-carrito {
  position: fixed;
  top: 80px;
  right: 20px;
  background: #10b981;
  color: white;
  padding: 15px 20px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
  z-index: 2000;
  opacity: 0;
  transform: translateY(-20px);
  transition: all 0.3s ease;
}

.notificacion-carrito.active {
  opacity: 1;
  transform: translateY(0);
}

/* Botón agregar otro producto */
.btn-secondary {
  background: #6b7280;
  color: white;
  border: none;
  padding: 12px 20px;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-secondary:hover {
  background: #4b5563;
  transform: translateY(-2px);
}

/* Responsive */
@media (max-width: 640px) {
  .carrito-contenedor {
    bottom: 15px;
    right: 15px;
  }
  
  .carrito-btn {
    width: 50px;
    height: 50px;
    font-size: 20px;
  }
  
  .carrito-contador {
    width: 20px;
    height: 20px;
    font-size: 12px;
  }
  
  .compra-modal-content {
    width: 95%;
    margin: 1rem;
    max-height: 95vh;
  }
  
  .compra-modal-header,
  .compra-modal-body,
  .compra-modal-footer {
    padding: 1rem;
  }
  
  .form-row {
    grid-template-columns: 1fr;
  }
  
  .envio-options,
  .pago-options {
    grid-template-columns: 1fr;
  }
  
  .compra-modal-footer {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .compra-modal-footer .btn {
    width: 100%;
  }
  
  .carrito-producto-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  
  .carrito-producto-cantidad {
    align-self: center;
  }
  
  .carrito-producto-subtotal {
    align-self: flex-end;
  }
}

/* Responsive para tablet */
@media (max-width: 768px) {
  .compra-modal-content {
    width: 95%;
    margin: 1rem;
  }
  
  .compra-modal-header,
  .compra-modal-body {
    padding: 1.5rem 1rem;
  }
  
  .compra-modal-footer {
    padding: 1rem;
  }
  
  .envio-options,
  .pago-options {
    grid-template-columns: 1fr;
  }
  
  .carrito-producto-item {
    padding: 12px;
  }
  
  .carrito-producto-info h4 {
    font-size: 14px;
  }
}

/* Responsive para móvil */
@media (max-width: 480px) {
  .compra-modal-content {
    width: 98%;
    margin: 0.5rem;
    max-height: 98vh;
  }
  
  .compra-modal-header,
  .compra-modal-body,
  .compra-modal-footer {
    padding: 1rem;
  }
  
  .compra-modal-header h2 {
    font-size: 1.5rem;
  }
  
  .compra-section h3 {
    font-size: 1rem;
  }
  
  .form-group input,
  .form-group textarea,
  .form-group select {
    padding: 0.6rem;
    font-size: 16px; /* Previene zoom en iOS */
  }
  
  .compra-modal-footer {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .compra-modal-footer .btn {
    width: 100%;
    padding: 0.8rem;
  }
  
  .carrito-producto-item {
    flex-direction: column;
    align-items: flex-start;
    padding: 10px;
    gap: 8px;
  }
  
  .carrito-producto-cantidad {
    align-self: center;
  }
  
  .carrito-producto-subtotal {
    align-self: flex-end;
    font-size: 14px;
  }
  
  .resumen-pedido {
    padding: 1rem;
  }
  
  .resumen-item {
    font-size: 0.8rem;
  }
  
  .resumen-item.total {
    font-size: 1rem;
  }
}
