/* Estilos del Carrito */

#btn-carrito {
  position: fixed;
  bottom: 20px;
  left: 20px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--gradient-primary);
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
  box-shadow: var(--shadow-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  transition: all 0.3s ease;
}

#btn-carrito:hover {
  transform: scale(1.1);
}

#btn-carrito svg {
  width: 28px;
  height: 28px;
}

.carrito-count {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #ff6b6b;
  color: white;
  border-radius: 50%;
  width: 28px;
  height: 28px;
  display: flex !important;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: bold;
}

.modal-carrito {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 9999;
  align-items: center;
  justify-content: flex-end;
  animation: slideIn 0.3s ease;
}

@keyframes slideIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal-contenido {
  background: var(--color-bg);
  width: 100%;
  max-width: 500px;
  height: 100vh;
  display: flex;
  flex-direction: column;
  animation: slideFromRight 0.3s ease;
  max-height: 100vh;
  overflow: hidden;
}

@keyframes slideFromRight {
  from {
    transform: translateX(100%);
  }
  to {
    transform: translateX(0);
  }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem;
  border-bottom: 1px solid var(--color-border);
}

.modal-header h2 {
  margin: 0;
  font-size: 1.5rem;
}

.btn-cerrar {
  background: none;
  border: none;
  font-size: 28px;
  cursor: pointer;
  color: var(--color-text);
  padding: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: 0.3s;
}

.btn-cerrar:hover {
  color: var(--color-primary);
  transform: rotate(90deg);
}

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 1.5rem;
}

.modal-footer {
  display: flex;
  gap: 1rem;
  padding: 1.5rem;
  border-top: 1px solid var(--color-border);
  background: var(--color-bg-soft);
}

.carrito-vacio {
  text-align: center;
  padding: 2rem;
  color: var(--color-text-muted);
  font-size: 1.1rem;
}

.carrito-items {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.carrito-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 1rem;
  background: var(--color-bg-soft);
  border-radius: 12px;
  border: 1px solid var(--color-border);
  transition: all 0.3s ease;
}

.carrito-item:hover {
  border-color: var(--color-primary);
  background: rgba(232, 124, 135, 0.05);
}

.item-info {
  flex: 1;
}

.carrito-item h4 {
  margin: 0 0 0.5rem 0;
  color: var(--color-text);
  font-size: 1rem;
}

.item-precio {
  margin: 0.25rem 0;
  font-weight: bold;
  color: #fff;
}

.item-categoria {
  margin: 0.25rem 0 0 0;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.btn-eliminar {
  background: #ff6b6b;
  color: white;
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  transition: all 0.3s ease;
  margin-left: 1rem;
  flex-shrink: 0;
}

.btn-eliminar:hover {
  background: #ff5252;
  transform: scale(1.1);
}

.carrito-preferencias {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding: 1.5rem;
  background: var(--color-bg-soft);
  border-radius: 12px;
  border: 1px solid var(--color-border);
  margin-top: 1rem;
}

.carrito-preferencias h3 {
  margin: 0 0 1rem 0;
  font-size: 1.1rem;
}

.carrito-confirmacion {
  margin-top: 1.5rem;
  padding: 1.5rem;
  background: rgba(232, 124, 135, 0.08);
  border: 1px solid rgba(232, 124, 135, 0.2);
  border-radius: 12px;
}

.carrito-confirmacion p {
  margin: 0 0 1rem 0;
  color: var(--color-text);
  line-height: 1.5;
}

.confirmacion-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.confirmacion-actions .btn {
  flex: 1;
}

.preferencia-grupo {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.preferencia-grupo label {
  font-weight: 600;
  color: var(--color-text);
  display: block;
}

.horarios,
.dias {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.horarios label,
.dias label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: normal;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 6px;
  transition: 0.3s;
}

.horarios label:hover,
.dias label:hover {
  background: rgba(232, 124, 135, 0.1);
}

.horarios input,
.dias input {
  cursor: pointer;
  width: 18px;
  height: 18px;
  accent-color: var(--color-primary);
}

.nombre-input,
.hora-input {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: inherit;
  font-size: 1rem;
}

.nombre-input:focus,
.hora-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(232, 124, 135, 0.1);
}

.btn-carrito-item,
.btn-agregar-carrito-item {
  background: var(--color-primary);
  color: white;
  border: none;
  border-radius: 999px;
  padding: 0.7rem 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.btn-carrito-item:hover,
.btn-agregar-carrito-item:hover {
  background: #e963a5;
  transform: translateY(-1px);
}

.btn-agregar-carrito-item {
  min-width: 40px;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
  border-radius: 12px;
}

}

#notas-adicionales {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: inherit;
  resize: vertical;
  margin-top: 0.5rem;
}

#notas-adicionales:focus {
  outline: none;
  border-color: var(--color-primary);
}

.btn {
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  border: none;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.95rem;
  flex: 1;
}

.btn-primary {
  background: var(--gradient-primary);
  color: white;
  box-shadow: var(--shadow-primary);
}

.btn-primary:hover {
  opacity: 0.85;
  transform: translateY(-2px);
}

.btn-secundario {
  background: var(--color-bg-soft);
  color: var(--color-text);
  border: 1px solid var(--color-border);
}

.btn-secundario:hover {
  background: rgba(232, 124, 135, 0.1);
  border-color: var(--color-primary);
}

.notificacion {
  position: fixed;
  bottom: 140px;
  right: 20px;
  background: var(--gradient-primary);
  color: white;
  padding: 1rem 1.5rem;
  border-radius: 8px;
  box-shadow: var(--shadow-primary);
  z-index: 10000;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.3s ease;
}

.notificacion.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 768px) {
  .modal-contenido {
    max-width: 100%;
  }

  .modal-footer {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

  #btn-carrito {
    bottom: 20px;
  }

  .notificacion {
    bottom: 110px;
    right: 10px;
    left: 10px;
  }
}
