.floating-cart {
  position: fixed;
  right: 16px;
  top: 45%;
  transform: translateY(-50%);
  z-index: 999;
  width: 290px;
}

.floating-cart.is-hidden {
  display: none;
}

.floating-cart-toggle {
  /* width: 100%; */
  border: 0;
  background: #c62828;
  color: #fff;
  border-radius: 10px;
  padding: 10px 12px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  position: absolute;
  right: 0;
  top: -38px;
  display:none;
}

.floating-cart-list {
  margin-top: 8px;
  background: #fff;
  border: 1px solid #eee;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  max-height: 360px;
  overflow: auto;
  padding: 10px;
}

.floating-cart-list.is-hidden {
  display: none;
}

#floatingCartItems .item-cart {
  border-bottom: 1px solid #f1f1f1;
  padding-bottom: 8px;
  margin-bottom: 8px;
  position: relative;
}

#floatingCartItems .item-cart:last-child {
  border-bottom: 0;
  margin-bottom: 0;
  padding-bottom: 0;
}

#floatingCartItems .item-cart a {
  display: flex;
  gap: 8px;
  text-decoration: none;
  color: #222;
}

#floatingCartItems .item-cart a > div {
  flex: 1;
  min-width: 0;
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "title title"
    "qty price";
  align-items: center;
  column-gap: 8px;
}

#floatingCartItems .item-cart img {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border-radius: 6px;
}

#floatingCartItems .item-cart span {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.3;
  display: block;
  grid-area: title;
  margin-right: 42px;
  margin-bottom: 5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: auto;
}

#floatingCartItems .item-cart p {
  margin: 2px 0 0;
  color: #c62828;
  font-weight: 600;
  font-size: 12px;
}

#floatingCartItems .item-cart p.qty {
  grid-area: qty;
  margin-right: 8px;
}

#floatingCartItems .item-cart p.qty + p {
  grid-area: price;
  text-align: right;
  white-space: nowrap;
}

#floatingCartItems .btn-remove-cart-item {
  position: absolute;
  right: 0;
  top: 0;
  border: 0;
  background: transparent;
  color: #b71c1c;
  font-size: 14px;
  padding: 2px 4px;
  line-height: 1;
}

.floating-cart-link {
    margin-top: 10px;
    display: block;
    text-decoration: none;
    color: #fff;
    text-align: center;
    font-family: var(--font-malik-medium);
    background: var(--bg-gradient-red);
    width: 115px;
    padding: 7px 10px 6px;
    border-radius: 30px;
    margin: 0px auto;
    margin-top: 16px;
    position: absolute;
    top: -45px;
    right: 0;
    text-transform: uppercase;
    font-size: 14px;
    line-height: 18px;
    box-shadow: 0 8px 18px rgba(194, 1, 22, 0.24);
    overflow: hidden;
    transition: transform .22s ease, box-shadow .22s ease, color .22s ease;
    animation: spMobilePulse 1.9s ease-in-out infinite;
}
.floating-cart-link::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.18) 36%, rgba(255, 255, 255, 0.55) 50%, rgba(255, 255, 255, 0.18) 64%, rgba(255, 255, 255, 0) 100%);
    transform: translateX(-140%);
    animation: spMobileShine 2.6s ease-in-out infinite;
}
.floating-cart-link:hover {
  background: var(--bg-gradient-red2);
  color: #fff;
}

.mobile-hotline {
  display: none;
}

@media (max-width: 768px) {
  .floating-cart {
	right: 15px;
	left: auto;
	top: auto;
	bottom: 12px;
	transform: none;
	width: 250px;
  }
	#floatingCartItems .item-cart span{
		font-size: 12px;
        overflow: initial;
        text-overflow: inherit;
        white-space: initial;
	}
	.floating-cart-toggle{
		display:none;
	}
	.floating-cart-list {
		max-height: 140px;
	}
	.floating-cart-link{
		position: absolute;
        top: -50px;
        right: 0;
	}

  .mobile-hotline {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 1001;
    width: 54px;
    height: 54px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: var(--bg-gradient-red);
    box-shadow: 0 8px 20px rgba(194, 1, 22, 0.32);
    text-decoration: none;
    font-size: 22px;
    line-height: 1;
    animation: spMobilePulse 1.9s ease-in-out infinite;
  }

  #floatingCart:not(.is-hidden) + .mobile-hotline {
    bottom: 200px;
  }

  .mobile-hotline:hover,
  .mobile-hotline:focus {
    color: #fff;
    background: var(--bg-gradient-red2);
  }
}
