body.bestel-restaurant-layout .restaurant-menu-categories {
    flex-direction: row;
    flex-wrap: nowrap;
    overflow-x: hidden;
    gap: 1.5rem;
    margin-left: 0px !important;
    margin-right: 0px !important;
    background: none !important;
    max-width: 100%;
    width: 100%;
}


.restaurant-menu-categories
.categorie-menu-nav-item {
    transition: all .5s;
}

.categorie-menu-nav-item {
    -webkit-transform: translateX(0);
    transform: translateX(0);
}

.fa-arrow-circle-right, .fa-arrow-circle-left {
    display: none;
}

.swiper-button-prev:after, .swiper-button-next:after {
    font-size: 10px !important;
    background: white;
    padding: 1.2rem 1.5rem;
    border-radius: 50%;
    color: black;
    font-weight: bolder;
    top: 60px;
    position: absolute;
}

.swiper-button-disabled {
    opacity: .35px !important;
}

.swiper-button-prev, .swiper-button-next {

    height: calc(100% + 50px) !important;
    width: 35px !important;
    top: 0 !important;
    opacity: 1 !important;
}

.swiper-button-next {
    right: 0 !important;
    width: 40px !important;
}

.swiper-button-prev {
    left: 0 !important;
}

body.bestel-restaurant-layout .restaurant-menu-categories a:focus:before {
    left: 0px !important;
    right: 0px !important;
    transform: scale(1.05) translateX(13px);
}

body.bestel-restaurant-layout .restaurant-menu-categories a {
    min-width: 120px;
    left: -45px !important;
    height: 90px;
    transform: translateX(45px);
    display: block;
}

body.bestel-restaurant-layout-2.restaurants-enabled-false .restaurant-menu-categories {
    padding-right: 60px;
    
}


.restaurant-menu-categories a span {
    text-align: center;
    display: block;
    z-index: 12;
    position: absolute;
    top: 100%;
    font-weight: bold;
    left: 0;
    width: 100%;
    font-size: 1.2rem;
    text-transform: capitalize;
}

.restaurant-menu-category-pic {
    content: " " !important;
    color: var(--primary-color) !important;
    font-size: 1.6rem !important;
    transition: all 0.3s !important;
    background-size: cover !important;
    height: 82% !important;
    z-index: 10;
    border-radius: 1rem;
    overflow: hidden;
    width: 100% !important;
    opacity: 1 !important;
}

.restaurant-menu-categories a:focus::before {
    left: 0px !important;
}

body.bestel-restaurant-layout .restaurant-menu-categories {
    padding-bottom: 4.5rem !important;
    background: white;
}







body.bestel-restaurant-layout .restaurant-menu-categories {
    display: flex !important;
    max-width: 100vw !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
}

.restaurant-menu-categories::-webkit-scrollbar {
    border-radius: 1rem;
    height: 10px;
}

.restaurant-menu-categories::-webkit-scrollbar-track {
    background: none;
}

.restaurant-menu-categories::-webkit-scrollbar-thumb {
    background: none;
}

@media (max-width:992px) {
    body.bestel-restaurant-layout .restaurant-menu-categories::-webkit-scrollbar {
        display: none;
    }

    body.bestel-restaurant-layout .restaurant-menu-categories::before {
        transform: translateY(-50%) translateX(2px);
    }
}



/* Parent element sticky solution - preserve dynamic background */
body.bestel-restaurant-layout .NewMenuStructure,
body.bestel-restaurant-layout-2.restaurants-enabled-true .NewMenuStructure,
body.bestel-restaurant-layout-2.restaurants-enabled-false .NewMenuStructure {
    position: -webkit-sticky !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 100 !important; /* Lower z-index to allow modals/popups to overlay */
    /* Box shadow for sticky effect without changing background */
    box-shadow: 0 2px 5px rgba(0,0,0,0.1) !important;
    /* Background color comes from @Model.Settings.choise_background_1 */
    max-width: 100%;
}


/* Style adjustments for better appearance */
body.bestel-restaurant-layout .restaurant-menu-categories .swiper-button-prev,
body.bestel-restaurant-layout .restaurant-menu-categories .swiper-button-next {
    opacity: 0.3 !important;
    transition: opacity 0.3s ease !important;
    transform: scale(0.6) !important;
}

body.bestel-restaurant-layout .restaurant-menu-categories:hover .swiper-button-prev,
body.bestel-restaurant-layout .restaurant-menu-categories:hover .swiper-button-next {
    opacity: 0.7 !important;
}

/* Fix image aspect ratio - prevent repeat */
body.bestel-restaurant-layout .restaurant-menu-category-pic {
    background-size: contain !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
}

/* Reduce container height */
body.bestel-restaurant-layout .restaurant-menu-categories {
    max-height: 120px !important;
    overflow: hidden !important;
}

body.bestel-restaurant-layout .restaurant-menu-categories .swiper-slide {
    height: auto !important;
}

body.bestel-restaurant-layout .restaurant-menu-categories .swiper-slide a {
    padding: 10px 5px !important;
}

/* Ensure parent containers allow sticky to work */
body.bestel-restaurant-layout .restaurants-container,
body.bestel-restaurant-layout .restaurant-order-menu,
body.bestel-restaurant-layout .order-wrapper,
body.bestel-restaurant-layout-2.restaurants-enabled-true .restaurants-container,
body.bestel-restaurant-layout-2.restaurants-enabled-true .restaurant-order-menu,
body.bestel-restaurant-layout-2.restaurants-enabled-true .order-wrapper,
body.bestel-restaurant-layout-2.restaurants-enabled-false .restaurants-container,
body.bestel-restaurant-layout-2.restaurants-enabled-false .restaurant-order-menu,
body.bestel-restaurant-layout-2.restaurants-enabled-false .order-wrapper {
    overflow: visible !important;
    position: relative !important;
}

/* Mobile: Ensure sticky context is not disrupted */
@media screen and (max-width: 767px) {
    body.bestel-restaurant-layout .restaurants-container,
    body.bestel-restaurant-layout .restaurant-order-menu,
    body.bestel-restaurant-layout .order-wrapper,
    body.bestel-restaurant-layout .container,
    body.bestel-restaurant-layout .container-fluid,
    body.bestel-restaurant-layout-2.restaurants-enabled-true .restaurants-container,
    body.bestel-restaurant-layout-2.restaurants-enabled-true .restaurant-order-menu,
    body.bestel-restaurant-layout-2.restaurants-enabled-true .order-wrapper,
    body.bestel-restaurant-layout-2.restaurants-enabled-true .container,
    body.bestel-restaurant-layout-2.restaurants-enabled-true .container-fluid,
    body.bestel-restaurant-layout-2.restaurants-enabled-false .restaurants-container,
    body.bestel-restaurant-layout-2.restaurants-enabled-false .restaurant-order-menu,
    body.bestel-restaurant-layout-2.restaurants-enabled-false .order-wrapper,
    body.bestel-restaurant-layout-2.restaurants-enabled-false .container,
    body.bestel-restaurant-layout-2.restaurants-enabled-false .container-fluid {
        overflow: visible !important;
        position: relative !important;
    }
}

/* Make sure container-fluid doesn't interfere */
body.bestel-restaurant-layout .order-wrapper.container-fluid {
    overflow: visible !important;
    max-height: none !important;
    height: auto !important;
    max-width: 100%;
}

/* Mobile specific styles */
@media screen and (max-width: 767px) {
    .mobile-categories {
        display: none !important;
    }

    /* Force fixed positioning on mobile instead of sticky - more reliable */
    body.bestel-restaurant-layout .NewMenuStructure,
    body.bestel-restaurant-layout-2.restaurants-enabled-true .NewMenuStructure,
    body.bestel-restaurant-layout-2.restaurants-enabled-false .NewMenuStructure {
        position: fixed !important;
        top: 50px !important; /* Account for mobile header height (header.small.bestel = 50px) */
        left: 0 !important;
        right: 0 !important;
        z-index: 500 !important;
        width: 100% !important;
        background: inherit !important;
    }

    /* Fallback to fixed if sticky doesn't work on mobile browsers */
    @supports not (position: sticky) {
        body.bestel-restaurant-layout .NewMenuStructure,
        body.bestel-restaurant-layout-2.restaurants-enabled-true .NewMenuStructure,
        body.bestel-restaurant-layout-2.restaurants-enabled-false .NewMenuStructure {
            position: fixed !important;
            top: 50px !important; /* Account for mobile header height (header.small.bestel = 50px) */
            left: 0 !important;
            right: 0 !important;
            z-index: 100 !important;
            width: 100% !important;
        }

    /* Add top padding to prevent content being hidden behind fixed header */
    body.bestel-restaurant-layout .restaurant-order-menu,
    body.bestel-restaurant-layout-2.restaurants-enabled-true .restaurant-order-menu,
    body.bestel-restaurant-layout-2.restaurants-enabled-false .restaurant-order-menu {
        padding-top: 170px !important; /* Header (50px) + Carousel (~120px) */
    }

    /* Mobile carousel adjustments */
    body.bestel-restaurant-layout .restaurant-menu-categories {
        max-width: 100vw !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important; /* Smooth scrolling on iOS */
    }
}

/* Tablet and larger mobile devices (768px - 992px) */
@media screen and (min-width: 768px) and (max-width: 992px) {
    body.bestel-restaurant-layout .NewMenuStructure,
    body.bestel-restaurant-layout-2.restaurants-enabled-true .NewMenuStructure,
    body.bestel-restaurant-layout-2.restaurants-enabled-false .NewMenuStructure {
        position: -webkit-sticky !important;
        position: sticky !important;
        top: 0 !important;
        z-index: 100 !important;
    }
}



/* Swiper container width constraint */
.swiper-container {
    max-width: 100%;
    overflow: hidden;
}

.swiper-wrapper {
    max-width: 100%;
}

.swiper-slide {
    width: 100px !important;
    height: 90px !important;
    position: relative;
    flex-shrink: 0;
}

p.prod-title {
    word-break: break-word;
}