body {
    margin: 0;
    padding: 0;
    font-family: 'Poppins', sans-serif;
    background-color: #FFECB3;
}

.desktop-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: #2c3e50;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    border-top: 1px solid #34495e;
    z-index: 1000;
    transition: transform 0.3s ease;
    height: 60px;
    width: 100%;
}

.desktop-footer .footer-content {
    display: flex;
    justify-content: space-around;
    align-items: center;
    width: 90%;
    max-width: 1000px;
    padding: 25px 5px;
}

.footer-link {
    color: #FFECB3;
    text-decoration: none;
    font-size: 0.9rem;
    text-align: center;
    transition: color 0.3s ease, transform 0.2s ease, background-color 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 4px 5px;
    border-radius: 8px;
}

.footer-icon {
    font-size: 24px;
}

.cart-popup {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    padding: 5px 10px;
    border-radius: 30px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    font-size: 14px;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, bottom 0.3s ease;
    bottom: -70px; /* Start off-screen */
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-popup.show {
    opacity: 1;
    visibility: visible;
    bottom: 65px; /* Final position above footer */
}

/* Slide-up Animation */
@keyframes slideUp {
    0% { opacity: 0; bottom: -70px; }
    100% { opacity: 1; bottom: 65px; }
}

/* Apply animation only on first show */
.cart-popup.first-show {
    animation: slideUp 0.5s ease forwards;
}

.proceed-content {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    position: relative;
    width: 100%;
    height: fit-content;
}

.popup-product-image {
    max-width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #E67E22;
}

.popup-product-title {
    font-size: 14px;
    font-weight: bold;
}

.navCartBtn {
    background: none;
    border: none;
    color: #FFECB3;
    font-size: 24px;
    cursor: pointer;
    position: relative;
}

.badge {
    font-size: 12px;
}

.navCartBtn {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 10px;
    border-radius: 8px;
    background-color: transparent;
    border: none;
    cursor: pointer;
    transition: transform 0.3s ease, color 0.3s ease;
}

.navCartBtn i {
    font-size: 1.4rem;
}

.whatsapp-icon, .fa-list, .fa-book {
    font-size: 1.4rem;
    font-weight: 600;
    transition: color 0.3s ease;
}

.popup-item-image-container {
    position: relative;
    z-index: 1;
    margin-left: -40px; /* Overlap with the previous image */
}

.popup-item-image-container:first-child {
    margin-left: 0; /* The first image is fully visible and not overlapped */
}

.popup-header {
    flex-shrink: 0;
    margin-left: 15px;
    text-align: center;
    align-self: center;
}

.popup-header h4 {
    font-size: 16px;
    font-weight: bold;
    color: #FFECB3;
    margin: 0;
    align-self: center;
}

.popup-icon {
    font-size: 2rem;
    font-weight: 700;
    color: #FFECB3;
    padding: 0px 15px;
    background-color: #8E1616;
    height: 50px;
    width: 50px;
    border-radius: 50%;
    align-self: center;
    margin-left: 10px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.popup-icon:hover {
    transform: scale(1.1);
    cursor: pointer;
    transition: transform 0.3s ease, background-color 0.3s ease;
}
@keyframes fadeIn {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

@keyframes fadeOut {
    0% { opacity: 1; }
    100% { opacity: 0; }
}

/* Removing oldest item */
.popup-item-image-container.removed {
    animation: slideOutToLeft 0.8s ease forwards;
}

/* Popup image stack styling */
.popup-image-stack {
    display: flex;
    flex-direction: row;
    position: relative;
    overflow: hidden;
}

.popup-item-image-container.new-item {
    animation: slideInFromRight 1.2s ease; /* Animation for new items */
}

.popup-item-image-container.shift-item {
    animation: shiftLeft 1.2s ease; /* Animation for shifting items */
}

/* Popup header and right arrow styling */
.popup-header h4 {
    font-size: 16px;
    font-weight: bold;
    color: #FFECB3;
    margin: 0;
    align-items: center;
    justify-content: center;
}

/* Responsive Adjustments for Cart Popup */
@media (max-width: 414px) {
    .cart-popup {
        padding: 3px 5px;
        font-size: 0.80rem;
    }
    .cart-popup.show {
        bottom: 65px; /* Adjust as needed */
    }
    .popup-icon {
        font-size: 0.90rem;
        height: 35px;
        width: 35px;
    }
    .popup-header h4 {
        font-size: 0.70rem;
    }
    .popup-item-image-container {
        margin-left: -40px;
    }
    .popup-product-image {
        max-width: 35px;
        height: 35px;
    }
}

@media (min-width: 415px) and (max-width: 576px) {
    .cart-popup {
        padding: 3px 5px;
        font-size: 1rem;
    }
    .cart-popup.show {
        bottom: 65px; /* Adjust as needed */
    }
    .popup-icon {
        font-size: 0.90rem;
        height: 45px;
        width: 45px;
    }
    .popup-header h4 {
        font-size: 0.70rem;
    }
    .popup-item-image-container {
        margin-left: -40px;
    }
    .popup-product-image {
        max-width: 45px;
        height: 45px;
    }
}