/* ------------------------- */
/* ESTILOS PRINCIPALES CARRO */
/* ------------------------- */

/* Contenedor principal del carrito */
.cart-wrapper {
  position: relative;
}

/* Icono del carrito y contador */
.cart-link {
  align-items: center;
  gap: 8px;
  padding: 10px 15px;
  color: #02648f;
  font-size: 25px;
  transition: all 0.3s ease;
}

.cart-link:hover {
  color: #007bff;
  text-decoration: none;
}

.cart-products-count-top-menu {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #fe5000;
  color: white;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  font-size: 13px;
  font-weight: 400;
  flex-wrap: nowrap;
  align-content: center !important;
}

/* Animación para la flecha del carrito */
.cart-arrow {
  transition: transform 0.3s ease;
  margin-left: 0;
}

/* Rotación cuando está activo */
.cart-dropdown.show ~ .cart-link .cart-arrow {
  transform: rotate(180deg);
}

/* ------------------------- */
/* DROPDOWN DEL CARRITO */
/* ------------------------- */

.cart-dropdown {
  width: 420px;
  border: solid 2px #007bff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
  padding: 0;
  left: auto !important;
  right: 0;
  margin-top: 10px;
}

.dropdown-menu.cart-dropdown {
  border-radius: 20px;
  overflow: hidden;
  color: #007bff;
  margin-top: 10px;
}

.cart-dropdown .body {
  padding: 15px;
  background: #fff;
  min-width: 400px;
  border-radius: 20px 20px 20px 20px;
  border: solid 4px cyan;
}

/* Lista de productos */
.cart-dropdown ul {
  list-style: none;
  padding: 0;
  margin: 0 0 15px 0;
  max-height: 500px;
  overflow-y: auto;
}

.cart-dropdown li {
  padding: 12px 0;
  border-bottom: 1px solid #f5f5f5;
  display: flex;
  gap: 15px;
}

.cart-dropdown li:last-child {
  border-bottom: none;
}

/* Efectos hover productos */
.cart-dropdown li:hover {
  background: #f8f9fa;
  border-radius: 4px;
}

/* Scroll personalizado */
.cart-dropdown ul::-webkit-scrollbar {
  width: 6px;
}

.cart-dropdown ul::-webkit-scrollbar-track {
  background: #f1f1f1;
}

.cart-dropdown ul::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 12px;
  overflow: hidden;
}

/* ------------------------- */
/* RESUMEN Y TOTALES */
/* ------------------------- */

.resumen-total {
  background-color: #02648f;
  color: white;
  padding: 0;
  height: 45px;
  align-items: center;
  justify-content: center;
  margin: -10px 0 0;
}

.cont-articulos {
  align-items: center;
  display: flex;
  justify-content: center;
  color: #02648f;
}

/* Subtotales y total */
.cart-subtotals {
  margin: 15px 0;
  padding: 15px 0;
  border-top: 1px solid #eee;
  border-bottom: 1px solid #eee;
}

.cart-subtotals div {
  display: flex;
  justify-content: space-between;
  margin: 8px 0;
  color: #666;
}

.cart-total {
  display: flex;
  justify-content: space-between;
  font-weight: 400;
  font-size: 1.1em;
  margin-top: 15px;
  color: #007bff;
}

.value {
  /* color: #E7357C; */
  font-weight: 400;
}

.cart-total .value {
  color: #e7357c;
  text-align: right;
  margin-left: auto;
}

.div-prime {
  text-align: end;
  justify-content: end;
}

.premium-area {
  height: 75px;
}

/* ------------------------- */
/* FORMULARIO DE CUPONES */
/* ------------------------- */

.block-promo .cart-voucher-area {
  background-color: white;
}

.code-promotion {
  border: solid 1px #02648f !important;
  border-radius: 25px !important;
  width: 60%;
}

.btn-code-promotion {
  background-color: #02648f;
  color: white;
  font-weight: 400;
  border: none;
  border-radius: 25px;
  width: 30%;
  margin-left: 10px;
}

.voucher-messages {
  position: relative;
  z-index: 1001;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  font-size: 20px;
}

.voucher-messages .alert {
  font-size: 14px;
  padding: 8px 12px;
  border-radius: 4px;
  margin: 5px 0;
}

.voucher-messages .alert-danger {
  background: #f8d7da;
  border-color: #f5c6cb;
  color: #721c24;
}

.voucher-messages .alert-warning {
  color: #02648f;
  text-align: center;
}

/* ------------------------- */
/* BOTONES DEL CARRITO */
/* ------------------------- */

/* Botón de finalizar compra */
.text-xs-center a.btn {
  border-radius: 37px;
  background-color: #00a0e6;
  font-size: 20px;
  color: #ffffff;
}

/* OJO */
/* Botón eliminar producto */
.remove-from-cart i.fa-trash-o {
  color: #02648f;
}

/* ------------------------- */
/* ESTILOS PARA INPUT CANTIDAD */
/* ------------------------- */

.block-cart-product-quantity {
  width: 60px;
  text-align: center;
}

.no-gutters > .col,
.no-gutters > [class*="col-"] {
  padding-right: 10px !important;
}

.bootstrap-touchspin .input-group-btn-vertical {
  display: flex;
  flex-direction: column;
  height: 10px;
  width: 10px;
  margin-left: 3px;
  margin-top: 15px !important;
  justify-content: center;
  align-items: baseline;
}

.cart-dropdown {
  pointer-events: auto !important;
  /* Permitir interacción */
  display: none;
  /* Ocultar inicialmente */
  opacity: 1 !important;
  /* Anular cualquier opacidad previa */
}

.cart-dropdown.show {
  display: block !important;
}

a.cart-link.dropdown-toggle {
  color: #02648f !important;
}

i.fa.fa-shopping-cart {
  color: #02648f;
}
