body {
  font-family: Arial, sans-serif;
  background-color: #fffaf0;
  margin: 0;
  padding: 0;
  color: #333;
}

.navbar {
  background-color: #fecd39;
  padding: 15px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.navbar a {
  text-decoration: none;
  color: #4e3300;
  font-weight: bold;
  font-size: 16px;
}

h2, h3 {
  text-align: center;
  margin-top: 20px;
}

.carrito {
  max-width: 800px;
  margin: 20px auto;
  padding: 20px;
  background-color: #fff;
  box-shadow: 0 0 15px rgba(0,0,0,0.1);
  border-radius: 15px;
}

.item-carrito {
  display: flex;
  align-items: center;
  border-bottom: 1px solid #eee;
  padding: 15px 0;
  gap: 15px;
}

.imagen-item {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 10px;
  flex-shrink: 0;
}

.info-item {
  flex-grow: 1;
}

.info-item h4 {
  margin: 0 0 5px 0;
  color: #2d5a27;
  font-size: 18px;
}

.precio-unitario {
  color: #666;
  font-size: 14px;
  margin-bottom: 10px;
}

.precio-total {
  color: #e63946;
  font-weight: bold;
  font-size: 16px;
}


.cantidad-container {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 10px 0;
}

.btn-cantidad {
  background-color: #fecd39;
  border: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  cursor: pointer;
  font-weight: bold;
  color: #4e3300;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.btn-cantidad:hover {
  background-color: #ffc107;
  transform: scale(1.1);
}

.btn-cantidad:disabled {
  background-color: #ccc;
  cursor: not-allowed;
  transform: none;
}

.cantidad-numero {
  background-color: #f8f9fa;
  border: 2px solid #fecd39;
  border-radius: 8px;
  padding: 5px 15px;
  font-weight: bold;
  color: #2d5a27;
  min-width: 40px;
  text-align: center;
}

.total-container {
  background-color: #f8f9fa;
  padding: 20px;
  border-radius: 10px;
  margin: 20px 0;
  border-left: 4px solid #28a745;
}

.total-resumen {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 16px;
}

.total-final {
  display: flex;
  justify-content: space-between;
  font-size: 20px;
  font-weight: bold;
  color: #2d5a27;
  border-top: 2px solid #28a745;
  padding-top: 10px;
}

/* ===== BOTONES PRINCIPALES ===== */
.botones-container {
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 20px;
}

.boton {
  background: linear-gradient(145deg, #28a745, #20c997);
  color: white;
  border: none;
  padding: 15px 30px;
  border-radius: 25px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 5px 15px rgba(40, 167, 69, 0.3);
}

.boton:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(40, 167, 69, 0.4);
}

.boton:disabled {
  background: #ccc;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.boton-limpiar {
  background: linear-gradient(145deg, #dc3545, #c82333);
  box-shadow: 0 5px 15px rgba(220, 53, 69, 0.3);
}

.boton-limpiar:hover {
  box-shadow: 0 8px 25px rgba(220, 53, 69, 0.4);
}

.carrito-vacio {
  text-align: center;
  padding: 40px;
  color: #666;
}

.carrito-vacio img {
  width: 100px;
  opacity: 0.5;
  margin-bottom: 20px;
}

.alert-confirmacion {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(5px);
  z-index: 9999;
  display: none;
  justify-content: center;
  align-items: center;
}

.alert-confirmacion .alert-container {
  background: white;
  border-radius: 15px;
  padding: 30px;
  max-width: 400px;
  width: 90%;
  text-align: center;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
}

.alert-confirmacion h3 {
  color: #2d5a27;
  margin-bottom: 15px;
}

.alert-confirmacion .botones-alert {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 20px;
}

.btn-confirmar {
  background: #28a745;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
  transition: all 0.2s;
}

.btn-confirmar:hover {
  background: #218838;
  transform: translateY(-1px);
}

.btn-cancelar {
  background: #6c757d;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
  transition: all 0.2s;
}

.btn-cancelar:hover {
  background: #5a6268;
  transform: translateY(-1px);
}

@media (max-width: 768px) {
  .item-carrito {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .imagen-item {
    width: 60px;
    height: 60px;
  }

  .botones-container {
    flex-direction: column;
    align-items: center;
  }

  .boton {
    width: 100%;
    max-width: 300px;
  }

  .navbar {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }

  .carrito {
    margin: 10px;
    padding: 15px;
  }

  .total-container {
    margin: 10px;
  }

  .cantidad-container {
    justify-content: center;
  }

  .total-resumen,
  .total-final {
    font-size: 14px;
  }

  .total-final {
    font-size: 18px;
  }
}

@media (max-width: 480px) {
  .alert-confirmacion .alert-container {
    padding: 20px;
    margin: 20px;
  }

  .alert-confirmacion .botones-alert {
    flex-direction: column;
  }

  .btn-confirmar,
  .btn-cancelar {
    width: 100%;
    margin: 5px 0;
  }
}