/************************************************
* Template Name: menu pro - Premium Redesign
* Version: 2.3
* Author: BOT.LY
*************************************************/

/* ---------------------------------------------------
 GENERAL & TYPOGRAPHY
----------------------------------------------------- */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
    --font-main: 'Outfit', sans-serif;
    --color-bg: #F9FAFB;
    --color-text-main: #1A1A1A;
    --color-text-sub: #6B7280;
    --color-primary: var(--theme-color-1);
    /* Defined dynamically */
    --color-white: #FFFFFF;
    --color-border: #E5E7EB;
    --shadow-soft: 0 10px 40px -10px rgba(0, 0, 0, 0.08);
    --shadow-card: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    --radius-lg: 16px;
    --radius-md: 12px;
    --radius-sm: 8px;
    --nav-height: 60px;
}

body {
    font-family: var(--font-main);
    background: var(--color-bg);
    font-size: 15px;
    color: var(--color-text-sub);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    padding-bottom: 80px;
    /* Space for bottom cart */
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--color-text-main);
    font-weight: 600;
    margin-bottom: 0.5rem;
}

a {
    text-decoration: none;
    transition: all 0.2s ease;
}

a:hover {
    text-decoration: none;
}

/* ---------------------------------------------------
 UTILITIES
----------------------------------------------------- */
.none {
    display: none !important;
}

.noscroll {
    overflow: hidden;
}

/* ---------------------------------------------------
 HEADER SECTION
----------------------------------------------------- */
.header-wrapper {
    position: relative;
    background: var(--color-white);
    padding-bottom: 20px;
    margin-bottom: 0;
}

.cover-image {
    height: 200px;
    width: 100%;
    background-size: cover;
    background-position: center;
    position: relative;
}

.cover-image::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100px;
    background: linear-gradient(to bottom, transparent, var(--color-white));
}

.restaurant-info {
    padding: 0 20px;
    margin-top: -50px;
    position: relative;
    z-index: 2;
    text-align: center;
}

.restaurant-logo {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 4px solid var(--color-white);
    box-shadow: var(--shadow-card);
    object-fit: cover;
    margin: 0 auto 15px;
    background: #fff;
}

.restaurant-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 5px;
}

.restaurant-subtitle {
    font-size: 14px;
    color: var(--color-text-sub);
    margin-bottom: 15px;
}

.restaurant-meta {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    font-size: 13px;
    color: var(--color-text-sub);
}

.restaurant-meta i {
    color: var(--color-primary);
    margin-right: 5px;
}

/* ---------------------------------------------------
 STICKY NAVIGATION
----------------------------------------------------- */
.category-nav-wrapper {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--color-border);
    padding: 10px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

.category-nav {
    display: flex;
    overflow-x: auto;
    padding: 0 15px;
    gap: 10px;
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
    /* IE 10+ */
}

.category-nav::-webkit-scrollbar {
    display: none;
    /* Chrome/Safari */
}

.nav-item-link {
    white-space: nowrap;
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text-sub);
    background: transparent;
    border: 1px solid transparent;
    transition: all 0.3s ease;
}

.nav-item-link.active,
.nav-item-link:hover {
    background: var(--color-primary);
    color: var(--color-white);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* ---------------------------------------------------
 CONTENT & MENU ITEMS
----------------------------------------------------- */
.content-wrap {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px 15px;
}

.category-section {
    margin-bottom: 40px;
    scroll-margin-top: 80px;
    /* Offset for sticky nav */
}

.category-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--color-border);
    display: inline-block;
}

/* Premium Card Design */
.menu-item-card {
    background: var(--color-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    padding: 15px;
    margin-bottom: 20px;
    display: flex;
    gap: 15px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 1px solid transparent;
}

.menu-item-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-soft);
    border-color: rgba(0, 0, 0, 0.05);
}

.menu-card-image {
    width: 110px;
    height: 110px;
    border-radius: var(--radius-md);
    object-fit: contain;
    object-position: center;
    flex-shrink: 0;
    background: #f5f5f5;
    padding: 5px;
}


.menu-card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.menu-card-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--color-text-main);
    margin-bottom: 5px;
    line-height: 1.3;
}

.menu-card-desc {
    font-size: 13px;
    color: var(--color-text-sub);
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-clamp: 2;
    /* Standard property */
}

.menu-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

.menu-card-price {
    font-size: 16px;
    font-weight: 700;
    color: var(--color-text-main);
}

.btn-add {
    background: var(--color-primary);
    color: var(--color-white);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    transition: transform 0.2s;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.btn-add:hover {
    transform: scale(1.1);
}

.btn-add i {
    font-size: 14px;
}

/* ---------------------------------------------------
 MODALS & BOTTOM SHEETS (Fixed Visibility)
----------------------------------------------------- */
.sidenav {
    height: 100%;
    width: 0;
    position: fixed;
    z-index: 1050;
    top: 0;
    left: 0;
    background-color: #fff;
    overflow-x: hidden;
    transition: 0.3s;
}

.sidenav.bottom {
    width: 100%;
    height: auto;
    max-height: 85vh;
    top: auto;
    bottom: -100%;
    /* Hidden by default */
    left: 0;
    border-radius: 20px 20px 0 0;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.1);
    display: block;
    overflow-y: auto;
}

.sidenav.active {
    bottom: 0 !important;
}

.sidebar-header {
    background: var(--color-white);
    border-bottom: 1px solid var(--color-border);
    padding: 15px 20px;
    position: sticky;
    top: 0;
    z-index: 10;
}

.sidebar-header h4 {
    margin: 0;
    font-size: 18px;
}

/* Overlay */
.overlay {
    display: none;
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1040;
    backdrop-filter: blur(2px);
}

.overlay.active {
    display: block;
}

/* ---------------------------------------------------
 FORMS & INPUTS
----------------------------------------------------- */
.form-control {
    border-radius: 10px;
    padding: 12px 15px;
    border: 1px solid var(--color-border);
    background-color: #F9FAFB;
    font-size: 14px;
}

.form-control:focus {
    box-shadow: none;
    border-color: var(--color-primary);
    background-color: #fff;
}

/* Order Type Toggle Group */
.ordering-type-group .btn {
    border-radius: 50px;
    margin: 0 5px;
    border: 1px solid var(--color-border);
    color: var(--color-text-sub);
    font-weight: 500;
    font-size: 14px;
    padding: 8px 15px;
    background: #fff;
}

.ordering-type-group .btn.active {
    background: var(--color-primary);
    color: #fff;
    border-color: var(--color-primary);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.ordering-type-group .btn:hover {
    background: #f0f0f0;
}

.ordering-type-group .btn.active:hover {
    background: var(--color-primary);
}

/* ---------------------------------------------------
 EXTRAS
----------------------------------------------------- */
.preloading {
    background: var(--color-white);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.badge-custom {
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-veg {
    background: #e6f4ea;
    color: #1e8e3e;
}

.badge-non-veg {
    background: #fce8e6;
    color: #d93025;
}

/* Restaurant Loader */
.restaurant-loader {
    position: relative;
    width: 60px;
    height: 60px;
    margin: 0 auto 15px;
}

.spinning-plate {
    font-size: 50px;
    color: var(--color-primary);
    animation: spin 2s linear infinite;
    display: block;
}

.cutlery-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 20px;
    color: var(--color-text-main);
    animation: bounce 1s ease-in-out infinite;
}

.loader-text {
    color: var(--color-text-sub);
    font-weight: 500;
    letter-spacing: 1px;
    font-size: 14px;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes bounce {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
    }

    50% {
        transform: translate(-50%, -50%) scale(1.2);
    }
}

/* ---------------------------------------------------
 LIGHTGALLERY FIXES - Display images fully contained
----------------------------------------------------- */
/* Override lightGallery zoom animation that causes cropping */
body:not(.lg-from-hash) .lg-outer.lg-start-zoom .lg-object {
    -webkit-transform: scale3d(1, 1, 1) !important;
    transform: scale3d(1, 1, 1) !important;
    opacity: 1 !important;
    -webkit-transition: none !important;
    transition: none !important;
}

body:not(.lg-from-hash) .lg-outer.lg-start-zoom .lg-item.lg-complete .lg-object {
    -webkit-transform: scale3d(1, 1, 1) !important;
    transform: scale3d(1, 1, 1) !important;
    opacity: 1 !important;
}

/* Main image container */
.lg-outer {
    background-color: #000 !important;
}

/* Image wrapper to center and contain images */
.lg-outer .lg-img-wrap {
    position: absolute !important;
    padding: 0 5px !important;
    left: 0 !important;
    right: 0 !important;
    top: 0 !important;
    bottom: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    height: 100% !important;
    overflow: hidden !important;
}

/* Main image element */
.lg-outer .lg-image {
    display: block !important;
    margin: 0 auto !important;
    max-width: 100% !important;
    max-height: 100% !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
    object-position: center !important;
}

/* Image object fallback */
.lg-outer .lg-object,
.lg-outer img.lg-object {
    max-width: 100% !important;
    max-height: 100% !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
    object-position: center !important;
    display: block !important;
    margin: 0 auto !important;
}

/* Video object */
.lg-outer .lg-video .lg-object {
    object-fit: cover !important;
    /* Keep videos as cover */
}

/* Item container */
.lg-outer .lg-item {
    display: inline-block !important;
    width: 100% !important;
    height: 100% !important;
    text-align: center !important;
}

/* Fullscreen and responsive fixes */
@media (max-height: 500px) {
    .lg-outer .lg-img-wrap {
        padding: 0 2px !important;
    }
}

@media (max-width: 768px) {
    /* Disable zoom animation on mobile completely */
    body:not(.lg-from-hash) .lg-outer.lg-start-zoom .lg-object {
        -webkit-transform: scale3d(1, 1, 1) !important;
        transform: scale3d(1, 1, 1) !important;
        opacity: 1 !important;
        -webkit-transition: none !important;
        transition: none !important;
    }
    
    body:not(.lg-from-hash) .lg-outer.lg-start-zoom .lg-item.lg-complete .lg-object {
        -webkit-transform: scale3d(1, 1, 1) !important;
        transform: scale3d(1, 1, 1) !important;
        opacity: 1 !important;
    }
}

@media (max-width: 576px) {
    /* Mobile optimizations */
    .lg-outer .lg-img-wrap {
        padding: 0 !important;
    }

    .lg-outer .lg-image,
    .lg-outer .lg-object {
        max-width: 95vw !important;
        max-height: 85vh !important;
    }
}

/* Responsive Tweaks */
@media (max-width: 576px) {
    .cover-image {
        height: 160px;
    }

    .restaurant-logo {
        width: 80px;
        height: 80px;
        margin-top: -40px;
    }

    .menu-item-card {
        padding: 12px;
        gap: 12px;
    }

    .menu-card-image {
        width: 110px;
        height: 110px;
    }
}

