/* back to top btn */
#backToTop {
    display: none; /* Hidden initially */
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: linear-gradient(45deg, #ff416c, #ff4b2b);
    color: white;
    border: none;
    padding: 15px;
    font-size: 22px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2);
    opacity: 0.8;
    outline: none;
    z-index: 1000;
}

#backToTop:hover {
    background: linear-gradient(45deg, #ff4b2b, #ff416c);
    transform: scale(1.1);
    opacity: 1;
    box-shadow: 0px 6px 15px rgba(0, 0, 0, 0.3);
}

/* Add smooth bouncing effect */
@keyframes bounce {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

#backToTop.show {
    display: block;
    animation: bounce 1s infinite;
}

/* end */

.cart-count {
    font-size: 14px; /* Adjust the size of the superscript */
    color: red; /* Optional: Change the color */
    position: absolute;
    top: -5px; /* Adjust position vertically */
    right: -10px; /* Adjust position horizontally */
    background: #fff; /* Optional: Add a background color */
    border-radius: 50%; /* Make it circular */
    padding: 2px 6px; /* Add padding */
    font-weight: bold; /* Make the count bold */
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.2); /* Optional: Add shadow for a decent look */
}
.mini-cart {
    position: absolute;
    top: 50px;
    right: 0;
    width: 300px;
    background: #fff;
    border: 1px solid #ddd;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    padding: 15px;
    display: none;
    z-index: 1000;
}

.mini-cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #ddd;
    margin-bottom: 10px;
}

.mini-cart-header h4 {
    margin: 0;
}

.close-mini-cart {
    font-size: 18px;
    cursor: pointer;
}

.mini-cart-items {
    max-height: 200px;
    overflow-y: auto;
}

.mini-cart-item {
    display: flex;
    margin-bottom: 10px;
}

.mini-cart-item img {
    width: 50px;
    height: 50px;
    object-fit: cover;
    margin-right: 10px;
}

.mini-cart-details p {
    margin: 0;
}

.mini-cart-footer {
    border-top: 1px solid #ddd;
    padding-top: 10px;
    text-align: center;
}

.view-cart-btn,
.checkout-btn {
    display: block;
    margin: 5px 0;
    padding: 8px 10px;
    background: #007bff;
    color: #fff;
    text-align: center;
    text-decoration: none;
    border-radius: 5px;
}

.view-cart-btn:hover,
.checkout-btn:hover {
    background: #0056b3;
}

/*  */
.mini-cart-details {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 14px;
}

.mini-cart-details a {
    text-decoration: none;
    color: #333;
}

.mini-cart-details .brand-name {
    font-weight: bold;
    font-size: 13px;
    color: #555;
    text-transform: uppercase;
}

.mini-cart-details .product-name {
    font-weight: normal;
    font-size: 14px;
    color: #000;
}

.price-quantity {
    display: flex;
    justify-content: space-between;
    margin-top: 5px;
}

.price-quantity p {
    margin: 0;
    font-size: 13px;
    color: #333;
}

.price-quantity .price {
    font-weight: bold;
    color: #007bff;
}

.price-quantity .quantity {
    font-weight: bold;
    color: #28a745;
}
.mini-cart-separator {
    border: none;
    border-top: 1px solid #ddd;
    margin: 10px 0;
}
/* loader */
.loading {
    background: rgba(255, 255, 255, 0.8); /* Semi-transparent background */
    display: none; /* Hidden by default */
    height: 100vh; /* Full viewport height */
    width: 100vw; /* Full viewport width */
    position: fixed; /* Stays on top */
    top: 0; /* Align to the top of the viewport */
    left: 0; /* Align to the left of the viewport */
    z-index: 9999; /* Ensure it’s above all other elements */
}

.loading img {
    position: absolute; /* Absolutely positioned */
    top: 50%; /* Center vertically */
    left: 50%; /* Center horizontally */
    transform: translate(-50%, -50%); /* Adjust for image size */
    max-width: 64px; /* Optional: Limit max width */
    max-height: 64px; /* Optional: Limit max height */
}

/* loader end */

/* index page products by category */
/* Improved Overall Section Styling */
.categories-products {
    padding: 60px 0;
    background-color: #f8f9fa;
}

/* Section Title Styling */
.section-title {
    font-size: 32px;
    font-weight: 700;
    color: #333;
    margin-bottom: 10px;
}

.section-subtitle {
    font-size: 16px;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

/* Improved Category Section */
.category-section {
    background: #fff;
    padding: 25px;
    margin-bottom: 30px;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    height: 100%;
}

.category-section:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

/* Categories Text Styling */
.categories__text h2 {
    font-size: 28px;
    font-weight: 800;
    line-height: 1.3;
    color: #333;
    margin-bottom: 15px;
}

.categories__text span {
    color: #d9534f;
}

.category-explore-btn {
    display: inline-block;
    background: #d9534f;
    color: white;
    padding: 10px 20px;
    border-radius: 30px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s;
}

.category-explore-btn:hover {
    background: #c9302c;
    transform: translateY(-2px);
    color: white;
}

/* Hot Deal Styling */
.categories__hot__deal {
    position: relative;
}

.hot__deal__sticker {
    position: absolute;
    top: 20px;
    right: 20px;
    background: #d9534f;
    color: white;
    padding: 10px 15px;
    border-radius: 50%;
    text-align: center;
    width: 80px;
    height: 80px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transform: rotate(10deg);
}

.hot__deal__sticker span {
    font-size: 12px;
    font-weight: 600;
}

.hot__deal__sticker h5 {
    font-size: 18px;
    margin: 0;
    font-weight: 700;
}

/* Deal of the Week Styling */
.categories__deal__countdown {
    text-align: center;
}

.deal-label {
    display: inline-block;
    background: #f8d7da;
    color: #d9534f;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 15px;
}

.deal-title {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin-bottom: 20px;
}

/* Countdown Timer Styling */
.countdown-container {
    background: rgba(217, 83, 79, 0.1);
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
}

.categories__deal__countdown__timer {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.cd-item {
    background: white;
    padding: 10px;
    border-radius: 8px;
    min-width: 60px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.cd-item span {
    font-size: 24px;
    font-weight: 700;
    color: #d9534f;
    display: block;
}

.cd-item p {
    margin: 0;
    font-size: 12px;
    color: #666;
}

/* Price Container Styling */
.price-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.price {
    font-size: 24px;
    font-weight: 700;
    color: #28a745;
}

.old-price {
    font-size: 16px;
    color: #999;
    text-decoration: line-through;
}

.discount-percent {
    background: #28a745;
    color: white;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}

/* Primary Button Styling */
.primary-btn {
    display: inline-block;
    background: #d9534f;
    color: white;
    padding: 12px 30px;
    border-radius: 30px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
}

.primary-btn:hover {
    background: #c9302c;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    color: white;
}

/* Rating Styling */
.rating {
    color: #ffc107;
}

.rating-count {
    color: #777;
    font-size: 14px;
    margin-left: 5px;
}

/* Category Header Styling */
.category-header {
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f1f1f1;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.category-title {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin: 0;
}

.see-all {
    color: #d9534f;
    font-weight: 600;
    text-decoration: none;
    transition: 0.3s;
    display: flex;
    align-items: center;
    gap: 5px;
}

.see-all:hover {
    color: #c9302c;
    transform: translateX(3px);
}

/* Product Slider Styling */
.product-slider {
    position: relative;
    margin: 0 10px;
}

/* Product Card Styling */
.product-card {
    background: #fff;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    transition: 0.3s ease;
    border: 1px solid #f1f1f1;
    height: 100%;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* Product Image Styling */
.product-img {
    position: relative;
    margin-bottom: 15px;
    overflow: hidden;
    border-radius: 8px;
}

.product-img img {
    width: 100%;
    border-radius: 8px;
    transition: 0.5s;
}

.product-card:hover .product-img img {
    transform: scale(1.1);
}

.discount-badge {
    background: #d9534f;
    color: white;
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 3px;
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 1;
}

/* Product Title Styling */
.product-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 15px 0 10px;
    height: 40px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* Add to Cart Button */
.add-to-cart-btn {
    background: transparent;
    color: #d9534f;
    border: 1px solid #d9534f;
    padding: 8px 15px;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
    width: 100%;
    margin-top: 10px;
}

.add-to-cart-btn:hover {
    background: #d9534f;
    color: white;
}

/* Swiper Navigation Styling */
.swiper-button-next,
.swiper-button-prev {
    background: rgba(255, 255, 255, 0.9);
    color: #d9534f;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.swiper-button-next:after,
.swiper-button-prev:after {
    font-size: 18px;
}

.swiper-button-next:hover,
.swiper-button-prev:hover {
    background: #d9534f;
    color: white;
}

/* Responsive Styling */
@media (max-width: 1024px) {
    .section-title {
        font-size: 28px;
    }

    .categories__text h2 {
        font-size: 24px;
    }

    .deal-title {
        font-size: 20px;
    }
}

@media (max-width: 768px) {
    .categories-products {
        padding: 40px 0;
    }

    .category-section {
        padding: 20px;
    }

    .cd-item {
        min-width: 50px;
    }

    .cd-item span {
        font-size: 20px;
    }

    .price {
        font-size: 20px;
    }
}

@media (max-width: 576px) {
    .section-title {
        font-size: 24px;
    }

    .section-subtitle {
        font-size: 14px;
    }

    .categories__text h2 {
        font-size: 20px;
    }

    .hot__deal__sticker {
        width: 60px;
        height: 60px;
    }

    .categories__deal__countdown__timer {
        gap: 8px;
    }

    .cd-item {
        min-width: 40px;
        padding: 8px;
    }

    .cd-item span {
        font-size: 16px;
    }

    .cd-item p {
        font-size: 10px;
    }
}
