.catering-menu-container {
    max-width: 100%;
    width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    position: relative;
}

.catering-menu-container .container-fluid {
    padding: 50px 20px;
    flex: 1;
}

.content-wrapper {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    overflow: visible;
}

/* Cart Popup Toggle Button */
.cart-popup-toggle {
    display: none; /* Hidden by default, shown only on mobile */
    position: fixed;
    bottom: 20px;
    left: 20px; /* Left-side positioning */
    right: auto;
    background-color: #55200E;
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 1.2em;
    cursor: pointer;
    z-index: 1001;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}
.cart-popup-toggle:hover {
    background-color: #3b160a;
}
.cart-count {
    position: absolute;
    top: -10px;
    right: -10px;
    background: #ff0000;
    color: white;
    border-radius: 50%;
    padding: 3px 8px;
    font-size: 0.9em;
}

/* Left Sidebar for Categories */
.category-sidebar {
    flex: 1;
    min-width: 300px;
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 150px;
    align-self: flex-start;
    margin-top: 40px;
}

.category-sidebar h3 {
    font-size: 25px;
    margin-bottom: 20px;
    font-weight: 300;
    text-align: center;
    color: #000;
}

.category-sidebar ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-sidebar li {
    margin-bottom: 10px;
}

.category-sidebar a {
    text-decoration: none;
    color: #333;
    font-size: 1em;
    display: block;
    padding: 8px 12px;
    border-radius: 5px;
    transition: background-color 0.3s;
}

.category-sidebar a:hover {
    background-color: #e9ecef;
}

.category-sidebar a.active {
    background-color: #2B2B2B;
    color: white;
}

/* Slider Arrows (Hidden) */
.slider-arrow {
    display: none;
}

/* Wrapper for Main Content and Right Sidebar */
.main-content-wrapper {
    flex: 4;
    display: flex;
    gap: 20px;
    min-height: 100vh;
}

.main-content {
    flex: 3;
}

.sidebar {
    flex: 1;
    min-width: 320px;
    background: #f8f9fa;
    padding: 20px 10px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 150px;
    align-self: flex-start;
    margin-top: 40px;
    max-height: calc(100vh - 150px);
    overflow-y: auto;
}

.sidebar-close {
    display: none;
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 1.5em;
    cursor: pointer;
    color: #333;
    background: none;
    border: none;
}
.sidebar-close:hover {
    color: #000;
}

.category-title {
    font-size: 28px;
    font-weight: 300;
    margin-bottom: 20px;
    text-transform: uppercase;
    text-align: center;
}

.container-fluid h1 {
    font-size: 28px;
    font-weight: 300;
    margin-bottom: 20px;
    text-transform: uppercase;
    text-align: center;
    margin-top: 40px;
}

.menu-items {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.menu-item-box {
    min-height: 140px;
    background: var(--color-two) url(../images/resource/pattern-dark.png) center top repeat;
    border: 1px solid var(--color-one);
    border-radius: 10px;
    box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.2s;
    text-align: left;
}

.menu-item-box:hover {
    transform: translateY(-5px);
}

.menu-item-inner {
    display: flex;
    align-items: stretch;
    gap: 10px;
    position: relative;
    height: 100%;
}

.menu-item-details {
    flex: 2;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 15px;
    padding-bottom: 5px;
}

.menu-item-details h3 {
    font-size: 25px;
}

.menu-item-image {
    flex: 1;
    max-width: 160px;
    min-width: 160px;
    width: 100%;
    min-height: 100%;
}

.menu-item-image img {
    min-height: 100%;
    max-height: 150px;
    width: 100%;
    object-fit: cover;
    border-radius: 0 10px 10px 0;
}

.menu-item-content {
    flex-grow: 1;
}

.menu-item-content h2 {
    font-size: 22px;
    font-weight: 500;
    margin: 0;
}

.menu-item-meta {
    display: flex;
    align-items: center;
    gap: 10px;
}

.dietary-tag {
    color: white;
    font-size: 0.8em;
    font-weight: bold;
    padding: 3px 8px;
    border-radius: 5px;
    text-transform: uppercase;
}

.menu-price {
    font-size: 1em;
    font-weight: 600;
    color: #fff;
}

.menu-content {
    font-size: 0.9em;
    color: #fff;
    margin-bottom: 10px;
}

.tray-prices {
    font-size: 0.9em;
    color: #333;
}

.tray-prices p {
    margin: 5px 0;
    font-size: 16px;
}

.tray-buttons {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    position: absolute;
    bottom: 10px;
    right: 10px;
}

.select-item {
    width: 60px;
    height: 40px;
    border: none;
    border-radius: 5px;
    font-size: 0.9em;
    font-weight: 300;
    line-height: 40px;
    text-align: center;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
    padding: 0;
    background-color: #55200E;
    color: white;
}

.select-item:hover {
    transform: scale(1.05);
    background-color: #3b160a;
}

.selected-items {
    text-align: center;
}

.selected-items h3 {
    font-size: 25px;
    font-weight: 300;
    margin-bottom: 20px;
    color: #000;
}

#no-selection-message {
    display: none;
    color: #666;
    font-size: 0.9em;
    margin-bottom: 0;
    text-align: center;
}

.selected-items ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.selected-items li {
    padding: 10px;
    border-bottom: 1px solid #ddd;
    text-align: left;
    font-size: 16px;
}

.item-title {
    font-weight: 600;
    margin-bottom: 5px;
}

.tray-qty {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
    margin-bottom: 5px;
}

.tray-qty span {
    font-size: 0.9em;
    color: #333;
}

.increase-qty, .decrease-qty {
    background-color: #55200E;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1em;
    line-height: 30px;
    text-align: center;
    cursor: pointer;
    transition: background-color 0.3s;
    width: 30px;
    height: 30px;
    padding: 0;
}

.increase-qty:hover, .decrease-qty:hover {
    background-color: #3b160a;
}

#proceed-to-form {
    background-color: #55200E;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 20px;
    width: 100%;
}

#proceed-to-form:hover {
    background-color: #3b160a;
}

/* Popup styles */
.form-popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.form-popup.active {
    display: flex;
    opacity: 1;
}

.form-popup-content {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    width: 90%;
    max-width: 600px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-height: 80vh;
    overflow-y: auto;
}

.close-popup {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 1.5em;
    cursor: pointer;
    color: #333;
}

.close-popup:hover {
    color: #000;
}

.form-container {
    padding: 0;
}

.form-container h2 {
    text-align: center;
    margin-bottom: 20px;
    font-size: 28px;
    font-weight: 300;
}

.form-container p {
    margin-bottom: 20px;
}

.form-step {
    display: none;
}

.form-step.active {
    display: block;
}

.form-container label {
    display: block;
    margin: 10px 0 5px;
}

.form-container input {
    width: 100%;
    padding: 8px;
    margin-bottom: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.form-container button {
    background-color: #55200E;
    color: white;
    padding: 12px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    margin: 10px 5px;
}

.prev-step {
    background-color: #6c757d;
}

.prev-step:hover {
    background-color: #5a6268;
}

.next-step:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

#form-message {
    margin-top: 20px;
    font-weight: bold;
    text-align: center;
}

#confirmation-details {
    margin: 20px 0;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 5px;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .category-sidebar {
        position: sticky;
        top: -1px;
        z-index: 100;
        background: #fff;
        padding: 10px 0;
    }

    .main-content-wrapper {
        flex: 1;
        width: 100%;
        flex-wrap: wrap-reverse;
    }
}

@media (max-width: 768px) {
    .catering-menu-container .container-fluid {
        width: 100%;
    }

    .cart-popup-toggle {
        display: flex; /* Show only on mobile */
    }

    .category-sidebar {
        position: sticky;
        top: -1px;
        z-index: 100;
        padding: 10px 15px;
        margin-top: 0;
        background: #fff;
        border-bottom: 1px solid #e6e6e6;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
        border-radius: 0;
    }

    .category-sidebar h2 {
        display: none; /* Hide title on mobile */
    }

    .category-sidebar ul {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x proximity;
        -webkit-overflow-scrolling: touch;
        padding: 0 10px;
        scrollbar-width: none; /* Firefox */
    }

    .category-sidebar ul::-webkit-scrollbar {
        display: none; /* Chrome, Safari */
    }

    .category-sidebar li {
        flex: 0 0 auto;
        min-width: 120px;
        margin: 0 5px;
        scroll-snap-align: start;
    }

    .category-sidebar a {
        text-align: center;
        padding: 8px 16px;
        font-size: 0.9em;
        font-weight: 500;
        white-space: nowrap;
        background-color: #e6e6e6;
        color: #333;
        border-radius: 20px;
        transition: background-color 0.3s, color 0.3s;
    }

    .category-sidebar a:hover {
        background-color: #d0d0d0;
    }

    .category-sidebar a.active {
        background-color: #2b2b2b;
        color: white;
    }

    .main-content {
        overflow-y: visible;
    }

    .sidebar {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 320px;
        height: 100vh;
        max-height: 100%;
        z-index: 1000;
        background: #f8f9fa;
        transition: right 0.3s ease;
        overflow-y: auto;
        margin-top: 0;
        border-radius: 0;
    }

    .sidebar.active {
        right: 0;
    }

    .sidebar-close {
        display: block;
    }

    .menu-items {
        grid-template-columns: 1fr;
    }

    .menu-item-image {
        max-width: 100%;
        order: 1;
    }

    .menu-item-image img {
        border-radius: 0 0 10px 10px;
        height: 200px;
    }

    .menu-item-details {
        padding: 15px;
        padding-bottom: 5px;
        order: 0;
    }

    .tray-buttons {
        margin-top: 10px;
    }

    .select-item {
        width: 60px;
    }

    .tray-qty {
        align-items: center;
        gap: 12px;
    }

    .form-container h2 {
        font-size: 20px;
    }
}