.whatsapp-btn {
    background-color: #25D366;
    border-color: #25D366;
    position: relative;
    overflow: hidden;
    padding: 5px 10px;
    border-radius: 5px;
    transition: all 0.3s ease;
}

/* Pulse Animation */
.whatsapp-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 5px;
    background-color: #25D366;
    animation: pulse 2s infinite;
    z-index: -1;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 0.8;
    }

    70% {
        transform: scale(1.1);
        opacity: 0;
    }

    100% {
        transform: scale(1);
        opacity: 0;
    }
}

/* Bounce effect on hover */
.whatsapp-btn:hover {
    animation: bounce 0.6s ease-in-out;
    background-color: #1ea952;
    border-color: #1ea952;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(37, 211, 102, 0.3);
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(-2px);
    }

    50% {
        transform: translateY(2px);
    }
}

/* Icon shake animation */
.whatsapp-btn .bi-whatsapp {
    display: inline-block;
    margin: 0px 8px;
    animation: shake 4s infinite;
    transform-origin: 50% 50%;
    /* increase the icon size */
    font-size: 1.5em;
}

@keyframes shake {

    0%,
    85%,
    100% {
        transform: rotate(0deg);
    }

    88% {
        transform: rotate(-15deg);
    }

    90% {
        transform: rotate(15deg);
    }

    92% {
        transform: rotate(-15deg);
    }

    94% {
        transform: rotate(15deg);
    }

    96% {
        transform: rotate(-15deg);
    }

    98% {
        transform: rotate(15deg);
    }
}

/* Shine effect */
.whatsapp-btn::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(to right,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.3) 50%,
            rgba(255, 255, 255, 0) 100%);
    transform: rotate(45deg);
    animation: shine 3s infinite;
}

@keyframes shine {
    0% {
        transform: translateX(-100%) rotate(45deg);
    }

    40%,
    100% {
        transform: translateX(100%) rotate(45deg);
    }
}

/*--------------------------------------------------------------
# Related Products Section
--------------------------------------------------------------*/
.related-products {
    padding-bottom: 40px !important;
    padding-top: 40px !important;
}

.related-products .container {
    padding-bottom: 20px !important;
}

.related-products .category-slider {
    position: relative;
    padding: 1rem 0;
}

.related-products .category-slider .container {
    position: relative;
}

.related-products .category-slider .swiper-wrapper {
    height: auto !important;
}

.related-products .category-slider .swiper-button-next,
.related-products .category-slider .swiper-button-prev {
    width: 40px;
    height: 40px;
    background-color: var(--surface-color);
    border-radius: 50%;
    color: var(--heading-color);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.related-products .category-slider .swiper-button-next::after,
.related-products .category-slider .swiper-button-prev::after {
    font-size: 1rem;
    font-weight: bold;
}

.related-products .category-slider .swiper-button-next:hover,
.related-products .category-slider .swiper-button-prev:hover {
    background-color: var(--accent-color);
    color: var(--contrast-color);
}

.related-products .category-slider .swiper-button-prev {
    left: 0;
}

.related-products .category-slider .swiper-button-next {
    right: 0;
}

.related-products .product-card {
    position: relative;
    height: 100%;
    background-color: var(--surface-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.related-products .product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.related-products .product-card:hover .default-image {
    opacity: 0;
}

.related-products .product-card:hover .hover-image {
    opacity: 1;
}

.related-products .product-image {
    position: relative;
    padding-top: 100%;
    overflow: hidden;
    background-color: #f8f9fa;
}

.related-products .product-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.5s ease;
}

.related-products .product-image .default-image {
    opacity: 1;
    transition: opacity 0.5s ease;
}

.related-products .product-image .hover-image {
    opacity: 0;
    transition: opacity 0.5s ease;
}

.related-products .product-tags {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
}

.related-products .product-tags .badge {
    display: inline-block;
    padding: 0.35em 0.65em;
    font-size: 0.75em;
    font-weight: 500;
    border-radius: 4px;
    margin-right: 5px;
}

.related-products .product-tags .bg-accent {
    background-color: var(--accent-color);
    color: var(--contrast-color);
}

.related-products .product-tags .bg-sale {
    background-color: #ff6b6b;
    color: var(--contrast-color);
}

.related-products .product-tags .bg-sold-out {
    background-color: #6c757d;
    color: var(--contrast-color);
}

.related-products .product-actions {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    flex-direction: column;
    z-index: 2;
    opacity: 0;
    transform: translateX(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.related-products .product-actions button {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: var(--surface-color);
    border: none;
    color: var(--heading-color);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
    transition: background-color 0.3s ease, color 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    cursor: pointer;
}

.related-products .product-actions button:hover {
    background-color: var(--accent-color);
    color: var(--contrast-color);
}

.related-products .product-actions button i {
    font-size: 1rem;
}

.related-products .product-card:hover .product-actions {
    opacity: 1;
    transform: translateX(0);
}

.related-products .product-info {
    padding: 1.25rem;
}

.related-products .product-title {
    font-family: var(--heading-font);
    font-size: 1rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
    height: 2.4rem;
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
}

.related-products .product-title a {
    color: var(--heading-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.related-products .product-title a:hover {
    color: var(--accent-color);
}

.related-products .product-price {
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.related-products .product-price .current-price {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--heading-color);
}

.related-products .product-price .original-price {
    font-size: 0.875rem;
    text-decoration: line-through;
    color: color-mix(in srgb, var(--default-color), transparent 40%);
}

.related-products .product-rating {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
    color: #ffc107;
    font-size: 0.875rem;
}

.related-products .product-rating i {
    margin-right: 2px;
}

.related-products .product-rating .rating-count {
    margin-left: 4px;
    color: color-mix(in srgb, var(--default-color), transparent 40%);
    font-size: 0.75rem;
}

.related-products .btn-add-to-cart {
    width: 100%;
    padding: 0.6rem;
    background-color: var(--accent-color);
    color: var(--contrast-color);
    border: none;
    border-radius: 4px;
    font-size: 0.875rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease;
}

.related-products .btn-add-to-cart:hover {
    background-color: color-mix(in srgb, var(--accent-color), #000 10%);
}

.related-products .btn-add-to-cart i {
    font-size: 1rem;
}

.related-products .btn-add-to-cart.btn-disabled {
    background-color: #e9ecef;
    color: #6c757d;
    cursor: not-allowed;
}

.related-products .btn-add-to-cart.btn-disabled:hover {
    background-color: #e9ecef;
}

@media (max-width: 991.98px) {
    .related-products .category-slider .swiper-button-prev {
        left: -15px;
    }

    .related-products .category-slider .swiper-button-next {
        right: -15px;
    }

    .related-products .category-card {
        padding: 0.75rem;
    }

    .related-products .category-card .category-image {
        height: 100px;
        margin-bottom: 0.75rem;
    }

    .related-products .category-card .category-title {
        font-size: 0.9rem;
        margin-bottom: 0.25rem;
    }

    .related-products .category-card .category-count {
        font-size: 0.8rem;
    }

    .related-products .product-title {
        font-size: 0.95rem;
    }
}

@media (max-width: 767.98px) {

    .related-products .category-slider .swiper-button-prev,
    .related-products .category-slider .swiper-button-next {
        width: 35px;
        height: 35px;
    }

    .related-products .category-slider .swiper-button-prev::after,
    .related-products .category-slider .swiper-button-next::after {
        font-size: 0.85rem;
    }

    .related-products .category-card .category-image {
        height: 90px;
    }

    .related-products .product-card {
        max-width: 320px;
        margin: 0 auto;
    }

    .related-products .product-actions {
        opacity: 1;
        transform: translateX(0);
    }

    /* Make the product-card contents stack and push add-to-cart to bottom */
    .related-products .product-card {
        display: flex;
        flex-direction: column;
    }

    .related-products .product-info {
        flex: 1;
        /* pushes add-to-cart down */
        display: flex;
        flex-direction: column;
    }

    .related-products .btn-add-to-cart {
        margin-top: auto;
        /* forces it to bottom */
    }

    /* Price adjustments */
    .related-products .product-price {
        flex-direction: column;
        /* original price below */
        align-items: flex-start;
        gap: 2px;
    }

    /* Reduce font sizes of prices */
    .related-products .product-price .current-price {
        font-size: 1rem;
    }

    .related-products .product-price .original-price {
        font-size: 0.75rem;
    }
}

@media (max-width: 575.98px) {
    .related-products .category-slider .swiper-button-prev {
        left: -10px;
    }

    .related-products .category-slider .swiper-button-next {
        right: -10px;
    }

    .related-products .category-card {
        padding: 0.5rem;
    }

    .related-products .category-card .category-image {
        height: 80px;
        margin-bottom: 0.5rem;
    }

    .related-products {
        padding-bottom: 20px !important;
        padding-top: 20px !important;
    }

    .related-products .container {
        padding-bottom: 10px !important;
    }
}