
:root {
    --primary: #f8c811;
    --primary-dark: #e7b700;
    --secondary: #f9a825;
    --dark: #2d3436;
    --light: #f5f6fa;
    --white: #ffffff;
    --gray: #61757d; /* Updated Color */
    --text: #2d3436;
    --glass-bg: rgba(255, 255, 255, 0.75);
    --glass-border: rgba(255, 255, 255, 0.5);
    --footer-bg-start: #1a1a1a;
    --footer-bg-end: #373737;
    --gold: #f8ca1b;
    --gold-light: #f3e5ab;
}

        * { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
        body { font-family: 'Vazirmatn', sans-serif; background-color: var(--light); color: var(--text); max-width: 600px; margin: 0 auto; position: relative; overflow-x: hidden; padding-bottom: 70px; }
        body.no-scroll { overflow: hidden; }
        img { display: block; max-width: 100%; }
        a { text-decoration: none; color: inherit; }
        .no-scrollbar::-webkit-scrollbar { display: none; }
        .no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

        /* --- Header --- */
        header { background: linear-gradient(135deg, var(--footer-bg-start) 0%, var(--footer-bg-end) 100%); padding: 15px; display: flex; justify-content: space-between; align-items: center; position: sticky; top: 0; z-index: 100; box-shadow: 0 4px 15px rgba(0,0,0,0.2); }
        .menu-btn, .cart-btn { font-size: 24px; color: var(--gold); cursor: pointer; background: none; border: none; }
        .logo { font-size: 24px; font-weight: 900; color: var(--gold-light); text-shadow: 0 2px 4px rgba(0,0,0,0.3); display: flex; align-items: center; gap: 10px; min-width: 0; }
        .logo img { height: 38px; width: auto; display: block; flex-shrink: 0; }
        /* وقتی نام کسب‌وکار به‌جای «دلیج» می‌نشیند، اسم‌های بلند به‌جای برهم‌ریختن هدر سه‌نقطه می‌شوند */
        .logo span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
        .header-icons { display: flex; align-items: center; gap: 15px; }
        .header-icons i { font-size: 20px; color: var(--gold); cursor: pointer; transition: color 0.3s; }
        .header-icons i:hover { color: var(--gold-light); }

        .desktop-nav { display: none; gap: 25px; align-items: center; }
        .nav-link { color: #dcdcdc; font-size: 14px; font-weight: 500; display: flex; align-items: center; gap: 6px; cursor: pointer; transition: color 0.3s, transform 0.2s; }
        .nav-link:hover { color: var(--gold); transform: translateY(-2px); }
        .nav-link i { font-size: 14px; }

        /* --- Notifications Popup (bell, works on mobile + desktop) --- */
        .notif-menu-wrap { position: relative; display: flex; align-items: center; }
        .notif-btn { position: relative; background: none; border: none; padding: 0; cursor: pointer; display: flex; align-items: center; }
        .notif-badge { position: absolute; top: -6px; left: -8px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--primary); color: #fff; font-size: 10px; font-weight: bold; display: flex; align-items: center; justify-content: center; border: 2px solid var(--footer-bg-start); }
        .notif-badge.hidden { display: none; }
        /* In RTL the header icons sit at the LEFT edge, so the popup must open toward the right. */
        .notif-popup { position: absolute; top: calc(100% + 18px); left: -10px; width: min(320px, calc(100vw - 30px)); background: var(--white); border-radius: 16px; box-shadow: 0 15px 40px rgba(0,0,0,0.25); z-index: 200; opacity: 0; visibility: hidden; transform: translateY(-10px); transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease; }
        .notif-popup.active { opacity: 1; visibility: visible; transform: translateY(0); }
        .notif-popup::before { content: ''; position: absolute; top: -7px; left: 16px; width: 14px; height: 14px; background: var(--white); transform: rotate(45deg); border-radius: 3px 0 0 0; }
        .notif-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 15px; border-bottom: 1px solid rgba(0,0,0,0.07); position: relative; background: var(--white); border-radius: 16px 16px 0 0; }
        .notif-head h4 { font-size: 15px; color: var(--dark); display: flex; align-items: center; gap: 8px; }
        .notif-head h4 i { color: var(--primary); font-size: 14px; }
        .notif-mark-read { background: none; border: none; font-family: inherit; font-size: 12px; color: var(--primary); cursor: pointer; padding: 4px; }
        .notif-mark-read:disabled { color: var(--gray); cursor: default; }
        .notif-list { max-height: 320px; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }
        .notif-item { display: flex; gap: 11px; padding: 13px 15px; border-bottom: 1px solid rgba(0,0,0,0.05); cursor: pointer; transition: background 0.2s; }
        .notif-item:last-child { border-bottom: none; }
        .notif-item:hover { background: var(--light); }
        .notif-item.unread { background: rgba(239, 58, 75, 0.05); }
        .notif-item.unread:hover { background: rgba(239, 58, 75, 0.09); }
        .notif-icon { width: 36px; height: 36px; border-radius: 10px; background: var(--light); color: var(--primary); display: flex; align-items: center; justify-content: center; font-size: 15px; flex-shrink: 0; }
        .notif-body { flex: 1; min-width: 0; }
        .notif-title { font-size: 13px; font-weight: 700; color: var(--dark); margin-bottom: 3px; display: flex; align-items: center; gap: 6px; }
        .notif-title .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--primary); flex-shrink: 0; }
        .notif-text { font-size: 12px; color: #666; line-height: 1.6; }
        .notif-time { font-size: 11px; color: var(--gray); margin-top: 5px; display: flex; align-items: center; gap: 5px; }
        .notif-empty { padding: 35px 15px; text-align: center; color: var(--gray); font-size: 13px; }
        .notif-empty i { font-size: 32px; color: #dfe3e6; display: block; margin-bottom: 10px; }
        .notif-footer { padding: 11px; text-align: center; border-top: 1px solid rgba(0,0,0,0.07); background: var(--light); border-radius: 0 0 16px 16px; }
        .notif-footer span, .notif-footer a { font-size: 13px; color: var(--primary); font-weight: 500; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 6px; transition: color 0.2s; }
        .notif-footer a:hover { color: var(--primary-dark); }
        .notif-footer a i { font-size: 11px; }

        /* --- Desktop User Popup (avatar on the left of the header) --- */
        .user-menu-wrap { position: relative; display: none; }
        .user-avatar-btn { width: 38px; height: 38px; padding: 0; border-radius: 50%; border: 2px solid var(--gold); background: none; cursor: pointer; display: block; overflow: hidden; transition: transform 0.2s, box-shadow 0.2s; }
        .user-avatar-btn img { width: 100%; height: 100%; object-fit: cover; }
        .user-avatar-btn:hover { transform: scale(1.05); box-shadow: 0 0 0 3px rgba(248, 202, 27, 0.25); }
.user-popup {
    position: absolute;
    top: calc(100% + 14px);
    left: 0;
    width: 290px;
    background: var(--white);
    border-radius: 16px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.25);
    padding: 15px;
    z-index: 200;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease;
    max-height: 500px;
    overflow-y: auto;
}
        .user-popup.active { opacity: 1; visibility: visible; transform: translateY(0); }
        .user-popup::before { content: ''; position: absolute; top: -7px; left: 14px; width: 14px; height: 14px; background: var(--white); transform: rotate(45deg); border-radius: 3px 0 0 0; }
        .user-popup-head { display: flex; align-items: center; gap: 10px; padding-bottom: 12px; border-bottom: 1px solid rgba(0,0,0,0.07); }
        .user-popup-head img { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; border: 2px solid var(--gold); }
        .user-popup-head h4 { font-size: 14px; color: var(--dark); margin-bottom: 3px; }
        .user-popup-head p { font-size: 12px; color: var(--gray); direction: ltr; text-align: right; }
        .user-popup-menu { margin-top: 8px; }
        .user-popup-item { display: flex; align-items: center; gap: 12px; padding: 11px 8px; font-size: 14px; color: var(--dark); cursor: pointer; border-radius: 10px; transition: background 0.2s, color 0.2s; }
        .user-popup-item:hover { background: var(--light); color: var(--primary); }
        .user-popup-item i { width: 18px; text-align: center; color: var(--gray); font-size: 15px; transition: color 0.2s; }
        .user-popup-item:hover i { color: var(--primary); }
        .user-popup-item.logout { color: var(--primary); border-top: 1px solid rgba(0,0,0,0.07); margin-top: 6px; padding-top: 12px; border-radius: 0 0 10px 10px; }
        .user-popup-item.logout i { color: var(--primary); }
.user-popup::-webkit-scrollbar {
    width: 10px;
}

.user-popup::-webkit-scrollbar-track {
    background-color: var(--white);
}

.user-popup::-webkit-scrollbar-thumb {
    box-shadow: inset 0 0 20px var(--primary);
}

        /* --- Wallet Card (shared: desktop popup + mobile drawer) --- */
        .wallet-card { background: linear-gradient(135deg, var(--gold) 0%, #e0a800 100%); border-radius: 14px; padding: 14px; color: var(--footer-bg-start); box-shadow: 0 6px 18px rgba(248, 202, 27, 0.3); }
        .wallet-label { font-size: 12px; font-weight: 500; display: flex; align-items: center; gap: 7px; opacity: 0.85; }
        .wallet-balance { font-size: 20px; font-weight: 800; margin: 8px 0 12px; }
        .wallet-balance span { font-size: 12px; font-weight: 500; }
        .wallet-charge-btn { width: 100%; background: var(--footer-bg-start); color: var(--gold); border: none; border-radius: 10px; padding: 9px; font-family: inherit; font-size: 13px; font-weight: bold; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 7px; transition: background 0.3s; }
        .wallet-charge-btn:hover { background: #000; }
        .wallet-actions.with-payout { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
        .wallet-payout-btn { width: 100%; background: rgba(255, 255, 255, .88); color: var(--footer-bg-start); border: none; border-radius: 10px; padding: 9px 6px; font-family: inherit; font-size: 12px; font-weight: bold; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 6px; transition: background 0.3s, color 0.3s; }
        .wallet-payout-btn:hover { background: #fff; color: #000; }

        /* --- Overlays & Drawers Common --- */
        .drawer-overlay { position: fixed; top: 0; right: 0; left: 0; bottom: 0; background: rgba(0,0,0,0.3); backdrop-filter: blur(5px); -webkit-backdrop-filter: blur(5px); z-index: 999; opacity: 0; visibility: hidden; transition: all 0.3s ease; }
        .drawer-overlay.active { opacity: 1; visibility: visible; }

        /* --- Main Drawer --- */
        .drawer { position: fixed; top: 0; bottom: 0; right: -300px; width: 280px; z-index: 1000; transition: right 0.3s ease; padding: 20px; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; background: linear-gradient(135deg, var(--footer-bg-start) 0%, var(--footer-bg-end) 100%); border-left: 1px solid var(--gold); box-shadow: -5px 0 20px rgba(0,0,0,0.3); }
        .drawer.active { right: 0; }
        .drawer-header { display: flex; align-items: center; gap: 10px; margin-bottom: 30px; padding-bottom: 20px; border-bottom: 1px solid rgba(212, 175, 55, 0.3);}
        .drawer-header img { width: 50px; height: 50px; border-radius: 50%; border: 2px solid var(--gold); object-fit: cover; }
        .drawer-header h3 { font-size: 16px; color: var(--gold-light); }
        .drawer-header p { font-size: 12px; color: #ccc; }
        .drawer-menu-item { display: flex; align-items: center; gap: 15px; padding: 15px 0; border-bottom: 1px solid rgba(255,255,255,0.1); cursor: pointer; color: #dcdcdc; transition: all 0.3s ease; }
        .drawer-menu-item:hover { color: var(--gold); padding-right: 10px; }
        .drawer-menu-item i { color: var(--gold); width: 20px; text-align: center; }
        .drawer-section-title { margin-top: 20px; font-size: 14px; color: #aaa; margin-bottom: 10px; display: flex; align-items: center; gap: 10px; }
        .drawer-section-title::after { content: ''; flex: 1; height: 1px; background: linear-gradient(90deg, var(--gold), transparent); }
        .drawer-newsletter-text { font-size: 12px; color: #ccc; line-height: 1.8; margin-bottom: 12px; }
        .drawer-logout { width: 100%; margin-top: 20px; background: none; border: none; border-top: 1px solid rgba(255,255,255,0.1); font-family: inherit; font-size: inherit; text-align: right; color: var(--primary); }
        .drawer-logout i { color: var(--primary); }
        .drawer-logout:hover, .drawer-logout:hover i { color: var(--primary-dark); }
        .footer-info-drawer { font-size: 12px; color: #ccc; line-height: 1.8; margin-top: 20px; }
        .footer-info-drawer h4 { color: var(--gold); margin-bottom: 5px; }
        .footer-info-drawer i { color: var(--gold); }
        .drawer-social { margin-top: 15px; display: flex; gap: 18px; }
        .drawer-social i { font-size: 36px; color: var(--gold); cursor: pointer; transition: color 0.3s, transform 0.2s; }
        .drawer-social i:hover { color: var(--gold-light); transform: translateY(-2px); }

        /* --- Search Drawer --- */
        .search-drawer { position: fixed; top: 0; bottom: 0; right: 0; left: 0; z-index: 1001; transform: translateY(-100%); transition: transform 0.3s ease; background: var(--glass-bg); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); padding: 20px; display: flex; flex-direction: column; }
        .search-drawer.active { transform: translateY(0); }
        .search-drawer-head { display: flex; gap: 10px; margin-bottom: 20px; flex-shrink: 0; }
        .search-drawer-input { flex: 1; display: flex; align-items: center; background: rgba(255,255,255,0.6); border-radius: 15px; padding: 12px 15px; border: 1px solid var(--glass-border); }
        .search-drawer-input input { border: none; background: none; outline: none; width: 100%; font-family: inherit; font-size: 16px; color: var(--dark); }
        .search-drawer-input i { color: var(--gray); font-size: 18px; margin-left: 10px; }
        .search-close-btn { background: var(--primary); color: white; border: none; border-radius: 12px; padding: 0 15px; font-size: 18px; cursor: pointer; }
        .search-content { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; padding-bottom: 80px; }
        .search-title { font-size: 14px; color: var(--gray); margin: 20px 0 10px; }
        .search-tags { display: flex; flex-wrap: nowrap; gap: 10px; padding-bottom: 5px; }
        .search-tag { background: rgba(255,255,255,0.6); padding: 8px 15px; border-radius: 20px; font-size: 13px; color: var(--dark); border: 1px solid var(--glass-border); flex-shrink: 0; white-space: nowrap; cursor: pointer; transition: all 0.2s; }
        .search-tag:active { transform: scale(0.95); background: var(--primary); color: white; }

        /* Horizontal drag-scroll utility (search tags, filter pills, category groups) */
        .drag-scroll { overflow-x: auto; scroll-behavior: smooth; touch-action: pan-x; }
        .drag-scroll.dragging { scroll-behavior: auto; cursor: grabbing; user-select: none; }
        .drag-scroll.dragging * { pointer-events: none; }
        @media (hover: hover) and (pointer: fine) { .drag-scroll { cursor: grab; } }

        /* Search title with an inline action (e.g. reset) */
        .search-title-row { display: flex; justify-content: space-between; align-items: center; margin: 20px 0 10px; }
        .search-title-row .search-title { margin: 0; }
        .search-reset-btn { background: none; border: none; font-family: inherit; font-size: 12px; color: var(--primary); cursor: pointer; display: flex; align-items: center; gap: 5px; padding: 4px; }

        /* Sort / choice segments inside the search drawer */
        .seg-group { display: flex; flex-wrap: wrap; gap: 8px; }
        .seg-btn { background: rgba(255,255,255,0.6); border: 1px solid var(--glass-border); border-radius: 20px; padding: 9px 14px; font-family: inherit; font-size: 13px; color: var(--dark); cursor: pointer; display: flex; align-items: center; gap: 6px; transition: all 0.2s; }
        .seg-btn i { font-size: 12px; color: var(--gray); transition: color 0.2s; }
        .seg-btn.active { background: var(--primary); border-color: var(--primary-dark); color: #fff; box-shadow: 0 4px 10px rgba(239, 58, 75, 0.25); }
        .seg-btn.active i { color: #fff; }

        /* Price range */
        .price-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 10px; }
        .glass-input-wrap { display: flex; align-items: center; gap: 6px; background: rgba(255,255,255,0.6); border: 1px solid var(--glass-border); border-radius: 15px; padding: 12px 15px; }
        .glass-input-wrap label { font-size: 12px; color: var(--gray); flex-shrink: 0; }
        .glass-input-wrap input { flex: 1; min-width: 0; border: none; background: none; outline: none; font-family: inherit; font-size: 14px; color: var(--dark); }
        .glass-input-wrap span { font-size: 11px; color: var(--gray); flex-shrink: 0; }

        /* Toggle row (only available) */
        .toggle-row { display: flex; align-items: center; justify-content: space-between; background: rgba(255,255,255,0.6); border: 1px solid var(--glass-border); border-radius: 15px; padding: 12px 15px; margin-top: 10px; cursor: pointer; }
        .toggle-row span { font-size: 14px; color: var(--dark); display: flex; align-items: center; gap: 8px; }
        .toggle-row span i { color: var(--gray); font-size: 14px; }
        .toggle-switch { width: 44px; height: 24px; border-radius: 12px; background: #cfd6da; position: relative; transition: background 0.25s; flex-shrink: 0; }
        .toggle-switch::after { content: ''; position: absolute; top: 3px; right: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform 0.25s; box-shadow: 0 1px 3px rgba(0,0,0,0.3); }
        .toggle-row.on .toggle-switch { background: var(--primary); }
        .toggle-row.on .toggle-switch::after { transform: translateX(-20px); }

        /* Location Selectors */
        .location-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 10px; }
        .glass-select { width: 100%; padding: 12px 15px; border-radius: 15px; background: rgba(255,255,255,0.6); border: 1px solid var(--glass-border); font-family: inherit; font-size: 14px; color: var(--dark); outline: none; cursor: pointer; appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b2bec3' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e"); background-repeat: no-repeat; background-position: left 15px center; background-size: 14px; }

        .search-splash { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: var(--white); z-index: 3000; display: none; flex-direction: column; justify-content: center; align-items: center; opacity: 0; transition: opacity 0.3s ease; }
        .search-splash.active { display: flex; opacity: 1; }

        /* --- Category Grid --- */
        .category-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
        .cat-item { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; background: rgba(255,255,255,0.5); border: 1px solid var(--glass-border); border-radius: 15px; padding: 15px 5px; cursor: pointer; transition: all 0.2s ease; position: relative; }
        .cat-item i { font-size: 24px; color: var(--primary); transition: color 0.2s ease; }
        .cat-item span { font-size: 12px; color: var(--dark); text-align: center; font-weight: 500; }
        .cat-item.selected { background: var(--primary); border-color: var(--primary-dark); box-shadow: 0 4px 10px rgba(239, 58, 75, 0.3); }
        .cat-item.selected i, .cat-item.selected span { color: white; }
        .cat-item .check-icon { position: absolute; top: 5px; left: 5px; color: white; font-size: 12px; display: none; }
        .cat-item.selected .check-icon { display: block; }

        .apply-filters-btn { position: absolute; bottom: 20px; left: 20px; right: 20px; background: var(--primary); color: white; border: none; padding: 15px; border-radius: 15px; font-family: inherit; font-size: 16px; font-weight: bold; cursor: pointer; box-shadow: 0 10px 20px rgba(239, 58, 75, 0.3); display: flex; align-items: center; justify-content: center; gap: 10px; }

        /* --- Cart Drawer --- */
        .cart-drawer { position: fixed; top: 0; bottom: 0; left: -350px; width: 350px; z-index: 1000; transition: left 0.3s ease; display: flex; flex-direction: column; background: var(--glass-bg); backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px); border-right: 1px solid var(--glass-border); box-shadow: 5px 0 20px rgba(0,0,0,0.1); }
        .cart-drawer.active { left: 0; }
        .cart-header { padding: 20px; border-bottom: 1px solid rgba(0,0,0,0.05); display: flex; justify-content: space-between; align-items: center; flex-shrink: 0; }
        .cart-header h3 { font-size: 18px; color: var(--dark); }
        .cart-header i { font-size: 20px; color: var(--gray); cursor: pointer; }
        .vendor-tabs-swiper { width: 100%; padding: 15px 0; border-bottom: 1px solid rgba(0,0,0,0.05); flex-shrink: 0; background: rgba(255,255,255,0.3); }
        .vendor-tabs-swiper .swiper-wrapper { align-items: center; }
        .vendor-tab { padding: 8px 18px; border-radius: 20px; font-size: 13px; white-space: nowrap; cursor: pointer; background: var(--light); color: var(--dark); border: 1px solid transparent; transition: all 0.3s ease; display: inline-block; user-select: none; }
        .vendor-tab.active { background: var(--primary); color: white; border-color: var(--primary-dark); transform: scale(1.05); box-shadow: 0 4px 10px rgba(239, 58, 75, 0.2); }
        .cart-items { flex: 1; padding: 15px; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }
        .cart-item { display: flex; flex-direction: column; gap: 10px; background: rgba(255,255,255,0.6); padding: 12px; border-radius: 12px; margin-bottom: 15px; border: 1px solid var(--glass-border); }
        .cart-item-top { display: flex; gap: 12px; align-items: flex-start; }
        .cart-item img { width: 70px; height: 70px; border-radius: 8px; object-fit: cover; flex-shrink: 0; }
        .cart-item-info { flex: 1; display: flex; flex-direction: column; gap: 4px; }
        .cart-item-info h4 { font-size: 14px; color: var(--dark); }
        .cart-item-cat { font-size: 11px; color: var(--gray); background: var(--light); padding: 2px 8px; border-radius: 8px; width: fit-content; }
        .cart-remove-btn { color: #b2bec3; cursor: pointer; font-size: 16px; transition: color 0.2s; padding: 5px; }
        .cart-remove-btn:hover { color: var(--primary); }
        .cart-item-bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 10px; border-top: 1px dashed rgba(0,0,0,0.1); }
        .cart-qty-selector { display: flex; align-items: center; gap: 12px; background: var(--white); border-radius: 10px; padding: 4px; border: 1px solid var(--glass-border); }
        .qty-btn { width: 28px; height: 28px; background: var(--light); border: none; border-radius: 6px; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--dark); font-weight: bold; font-size: 14px; transition: background 0.2s; }
        .qty-btn:hover { background: var(--primary); color: white; }
        .qty-num { font-size: 14px; font-weight: bold; min-width: 24px; text-align: center; }
        .cart-item-price { font-size: 16px; font-weight: 800; color: var(--primary); }
        .cart-footer { padding: 20px; border-top: 1px solid rgba(0,0,0,0.05); flex-shrink: 0; background: rgba(255,255,255,0.4); }
        .cart-total { display: flex; justify-content: space-between; margin-bottom: 15px; font-size: 16px; font-weight: bold; color: var(--dark); }
        .cart-checkout-btn { width: 100%; background: var(--primary); color: white; border: none; padding: 15px; border-radius: 12px; font-family: inherit; font-size: 16px; font-weight: bold; cursor: pointer; transition: background 0.3s; }
        .cart-checkout-btn:hover { background: var(--primary-dark); }

        /* --- Main Slider --- */
        .main-slider-container { position: relative; overflow: hidden; }
        .swiper-main { width: 100%; height: 220px; border-radius: 0 0 20px 20px; overflow: hidden; }
        .swiper-main .swiper-slide { display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; }
        .swiper-main .slide-bg { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-size: cover; background-position: center; transform: scale(1.1); transition: transform 5s ease; }
        .swiper-main .slide-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.4); }
        .swiper-main .slide-content { position: relative; z-index: 2; color: white; text-align: center; padding: 20px; animation: fadeInUp 0.8s ease; }
        .swiper-slide-active .slide-content { animation: fadeInUp 1s ease; }
        .swiper-main .slide-content h2 { font-size: 24px; margin-bottom: 10px; text-shadow: 0 2px 4px rgba(0,0,0,0.5); }
        .swiper-main .slide-content p { font-size: 14px; margin-bottom: 15px; }
        .swiper-main .slide-content button { background: var(--primary); color: white; border: none; padding: 8px 20px; border-radius: 20px; font-family: inherit; font-size: 14px; cursor: pointer; box-shadow: 0 4px 15px rgba(239, 58, 75, 0.4); }
        /* بدون اسلاید اختصاصی: نمایش تصویر cover کسب‌وکار به‌جای اسلایدر، با همان ابعاد و گردی گوشه */
        .main-cover-static { width: 100%; height: 220px; border-radius: 0 0 20px 20px; overflow: hidden; }
        .main-cover-static img { width: 100%; height: 100%; object-fit: cover; display: block; }
        @keyframes kenburns { 0% { transform: scale(1) translate(0, 0); } 100% { transform: scale(1.15) translate(-1%, -1%); } }
        .swiper-slide-active .slide-bg { animation: kenburns 5s ease-out forwards; }
        @keyframes fadeInUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
        .swiper-pagination-bullet { background: white !important; opacity: 0.5; }
        .swiper-pagination-bullet-active { opacity: 1; width: 20px; border-radius: 5px; }

        /* --- Business Hero (sits over the slider, like the old stories strip) --- */
        .biz-hero { background: var(--white); margin-top: -15px; position: relative; z-index: 5; border-radius: 20px 20px 0 0; padding: 18px 15px 15px; }
        .biz-hero-top { display: flex; gap: 14px; align-items: flex-start; }
        .biz-logo { width: 76px; height: 76px; border-radius: 18px; object-fit: cover; border: 3px solid var(--white); box-shadow: 0 6px 18px rgba(0,0,0,0.15); flex-shrink: 0; margin-top: -40px; background: var(--light); }
        .biz-hero-info { flex: 1; min-width: 0; }
        .biz-title { font-size: 19px; font-weight: 800; color: var(--dark); display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
        .biz-verified { font-size: 14px; color: #2d9cdb; }
        .biz-tag-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
        .biz-tag { font-size: 11px; color: var(--gray); background: var(--light); padding: 4px 10px; border-radius: 10px; }
        .biz-hero-meta { display: flex; align-items: center; gap: 12px; margin-top: 9px; flex-wrap: wrap; }
        .biz-score { font-size: 13px; font-weight: bold; color: var(--secondary); display: flex; align-items: center; gap: 4px; }
        .biz-score small { color: var(--gray); font-weight: 400; font-size: 11px; }
        .status-badge { font-size: 11px; font-weight: bold; padding: 4px 10px; border-radius: 10px; display: inline-flex; align-items: center; gap: 5px; }
        .status-badge.open { background: rgba(39, 174, 96, 0.12); color: #219653; }
        .status-badge.closed { background: rgba(239, 58, 75, 0.1); color: var(--primary); }
        .status-badge i { font-size: 7px; }
        .biz-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 15px; background: var(--light); border-radius: 15px; padding: 12px 5px; }
        .biz-stat { text-align: center; border-left: 1px solid rgba(0,0,0,0.06); }
        .biz-stat:last-child { border-left: none; }
        .biz-stat b { display: block; font-size: 15px; color: var(--dark); }
        .biz-stat span { font-size: 10px; color: var(--gray); }
        .biz-actions { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-top: 12px; }
        .biz-action { background: var(--light); border: 1px solid transparent; border-radius: 12px; padding: 10px 2px; font-family: inherit; font-size: 10.5px; color: var(--dark); cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 5px; transition: all 0.2s; white-space: nowrap; }
        .biz-action i { font-size: 16px; color: var(--primary); }
            .biz-action:hover {
                background: rgb(243 184 1 / 18%);
                border-color: rgb(255 171 5 / 46%);
            }
        .biz-action.active { background: rgba(239, 58, 75, 0.1); border-color: rgba(239, 58, 75, 0.35); }
        .biz-action.active i { color: var(--primary-dark); }
#chatOpenBtn {
    background: rgb(243 184 1 / 18%);
    border-color: rgb(255 171 5 / 46%);
    font-weight: 600;
}
        .biz-action.saved i { color: var(--primary-dark); }
        .biz-note { margin-top: 12px; background: rgba(248, 202, 27, 0.14); border: 1px solid rgba(248, 202, 27, 0.5); border-radius: 12px; padding: 10px 12px; font-size: 12px; color: #7a5c00; display: flex; align-items: center; gap: 8px; line-height: 1.7; }
        .biz-note i { color: #b58900; }

        /* --- Search Section (Trigger) --- */
        .search-section { padding: 20px 15px; background: var(--white); }
        .search-trigger { display: flex; align-items: center; background: var(--light); border-radius: 15px; padding: 12px 15px; margin-bottom: 15px; cursor: pointer; }
        .search-trigger i { color: var(--gray); font-size: 18px; margin-left: 10px; }
        .search-trigger span { color: var(--gray); font-size: 14px; }
        .filter-pills { display: flex; gap: 10px; padding-bottom: 5px; }
        .pill { background: var(--light); padding: 8px 15px; border-radius: 30px; font-size: 13px; color: var(--dark); white-space: nowrap; flex-shrink: 0; border: 1px solid transparent; cursor: pointer; display: flex; align-items: center; gap: 5px; }
            .pill.active {
                background: rgb(250 209 7 / 30%);
                color: var(--gray);
                border-color: var(--gray);
                font-weight: bold;
            }
        .pill i { font-size: 12px; }

        /* --- Product & Service Category Groups (under the search box) --- */
        .cat-group-block { margin-top: 20px; padding-top: 18px; border-top: 1px solid rgba(0,0,0,0.06); }
        .cat-group-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 13px; }
        .cat-group-head .section-title { font-size: 16px; }
        .cat-group-clear { background: none; border: none; font-family: inherit; font-size: 12px; color: var(--primary); cursor: pointer; display: none; align-items: center; gap: 5px; }
        .cat-group-clear.show { display: flex; }
        .cat-group-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
        .cat-group-item { background: var(--light); border: 1px solid transparent; border-radius: 15px; padding: 12px 4px; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 7px; transition: all 0.2s ease; position: relative; }
        .cat-group-item i { font-size: 20px; color: var(--primary); transition: color 0.2s; }
        .cat-group-item span { font-size: 11px; color: var(--dark); text-align: center; font-weight: 500; line-height: 1.4; }
        .cat-group-item b { font-size: 10px; color: var(--gray); font-weight: 400; }
        .cat-group-item.selected { background: var(--primary); border-color: var(--primary-dark); box-shadow: 0 6px 14px rgba(239, 58, 75, 0.25); }
        .cat-group-item.selected i, .cat-group-item.selected span, .cat-group-item.selected b { color: #fff; }

        /* --- Section Styles --- */
        .section { padding: 25px 0; }
        .section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; padding: 0 15px; }
        .section-title { font-size: 18px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
        .section-title i { color: var(--primary); }
        .section-more { font-size: 13px; color: var(--primary); display: inline-flex; align-items: center; gap: 5px; text-decoration: none; }
        .section-more i { font-size: 11px; }
        .section-more:hover { color: var(--primary-dark); }

        /* --- Primary CTA: go to this business's shop page --- */
        .shop-cta {
            display: flex; align-items: center; gap: 14px;
            margin: 0 15px 15px; padding: 16px 18px;
            border-radius: 16px; text-decoration: none;
            background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
            box-shadow: 0 8px 22px rgba(239, 58, 75, 0.28);
            position: relative; overflow: hidden;
            transition: transform 0.2s, box-shadow 0.2s;
        }
        .shop-cta:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(239, 58, 75, 0.36); }
        .shop-cta:active { transform: translateY(0); }
        .shop-cta-icon {
            flex-shrink: 0; width: 48px; height: 48px; border-radius: 14px;
            background: rgba(255,255,255,0.18); display: flex; align-items: center; justify-content: center;
            color: #fff; font-size: 22px;
        }
        .shop-cta-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
        .shop-cta-text b { color: var(--text); font-size: 15px; font-weight: 900; line-height: 1.5; }
        .shop-cta-text span { color: var(--gray); font-size: 11.5px; line-height: 1.7; }
        .shop-cta-go {
            flex-shrink: 0; background: #fff; color: var(--gray);
            border-radius: 30px; padding: 9px 16px; font-size: 12.5px; font-weight: bold;
            display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
        }
        .shop-cta-go i { font-size: 11px; }
        @media (max-width: 520px) {
            .shop-cta { flex-wrap: wrap; }
            .shop-cta-go { width: 100%; justify-content: center; padding: 11px 16px; }
        }
        .swiper-carousel { padding: 0 15px !important; padding-right: 0 !important; }
        .swiper-carousel .swiper-slide { width: 85%; margin-left: 15px !important; }

        /* Cards */
        .biz-card { background: var(--white); border-radius: 15px; overflow: hidden; box-shadow: 0 4px 15px rgba(0,0,0,0.05); height: 100%; }
        .biz-img { width: 100%; height: 140px; object-fit: cover; }
        .biz-info { padding: 12px; }
        .biz-name { font-size: 15px; font-weight: 700; margin-bottom: 5px; }
        .biz-meta { display: flex; justify-content: space-between; align-items: center; }
        .biz-cat { font-size: 11px; color: var(--gray); background: var(--light); padding: 3px 8px; border-radius: 10px; }
        .biz-rate { font-size: 12px; color: var(--secondary); font-weight: bold; display: flex; align-items: center; gap: 3px; }

        .prod-card { background: var(--white); border-radius: 15px; overflow: hidden; box-shadow: 0 4px 15px rgba(0,0,0,0.05); height: 100%; position: relative; display: block; text-decoration: none; color: inherit; transition: transform 0.2s, box-shadow 0.2s; }
        .prod-card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(0,0,0,0.1); }
        .prod-img { width: 100%; height: 180px; object-fit: cover; }
        .prod-info { padding: 12px; }
        .prod-name { font-size: 14px; font-weight: 500; margin-bottom: 8px; height: 40px; overflow: hidden; }
        .prod-price { font-size: 15px; font-weight: 800; color: var(--primary); }
        .prod-old-price { font-size: 12px; color: var(--gray); text-decoration: line-through; margin-right: 5px; }

        .disc-card { background: var(--white); border-radius: 15px; overflow: hidden; box-shadow: 0 4px 15px rgba(0,0,0,0.05); height: 100%; position: relative; display: block; text-decoration: none; color: inherit; transition: transform 0.2s, box-shadow 0.2s; }
        .disc-card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(0,0,0,0.1); }
        .disc-badge { position: absolute; top: 10px; right: 10px; background: var(--primary); color: white; padding: 5px 10px; border-radius: 20px; font-size: 11px; font-weight: bold; z-index: 2; }
        .disc-img { width: 100%; height: 160px; object-fit: cover; }
        .disc-info { padding: 12px; }
        .disc-timer { font-size: 12px; color: var(--dark); display: flex; align-items: center; gap: 5px; margin-top: 5px; }
        .disc-timer i { color: var(--primary); }

        .comment-card { background: var(--white); border-radius: 15px; padding: 15px; box-shadow: 0 4px 15px rgba(0,0,0,0.05); height: 100%; }
        .comment-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
        .comment-avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
        .comment-user h4 { font-size: 14px; }
        .comment-user span { font-size: 11px; color: var(--gray); }
        .comment-stars { color: var(--secondary); font-size: 12px; margin-right: auto; }
        .comment-text { font-size: 13px; color: #555; line-height: 1.6; }

        /* --- Products & Services Result Grid --- */
        .products-toolbar { display: flex; justify-content: space-between; align-items: center; padding: 0 15px; margin-bottom: 12px; gap: 10px; }
        .products-count { font-size: 13px; color: var(--gray); }
        .products-count b { color: var(--dark); }
        .products-sort-btn { background: var(--white); border: 1px solid rgba(0,0,0,0.08); border-radius: 20px; padding: 7px 13px; font-family: inherit; font-size: 12px; color: var(--dark); cursor: pointer; display: flex; align-items: center; gap: 6px; white-space: nowrap; }
        .products-sort-btn i { color: var(--primary); font-size: 12px; }
        .active-chips { display: flex; gap: 8px; padding: 0 15px 12px; }
        .active-chips:empty { display: none; }
        .active-chip { background: rgba(239, 58, 75, 0.1); color: var(--primary); border: 1px solid var(--primary); border-radius: 20px; padding: 6px 12px; font-size: 12px; white-space: nowrap; flex-shrink: 0; display: flex; align-items: center; gap: 6px; cursor: pointer; }
        .active-chip i { font-size: 11px; }
        .products-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; padding: 0 15px; }
        .item-card { background: var(--white); border-radius: 15px; overflow: hidden; box-shadow: 0 4px 15px rgba(0,0,0,0.05); position: relative; display: flex; flex-direction: column; text-decoration: none; color: inherit; transition: transform 0.2s, box-shadow 0.2s; }
        .item-card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(0,0,0,0.1); }
        .item-card .item-img { width: 100%; height: 130px; object-fit: cover; }
        .item-badge { position: absolute; top: 8px; right: 8px; background: var(--primary); color: #fff; padding: 4px 9px; border-radius: 20px; font-size: 10px; font-weight: bold; z-index: 2; }
        .item-type { position: absolute; top: 8px; left: 8px; background: rgba(0,0,0,0.55); color: #fff; padding: 4px 9px; border-radius: 20px; font-size: 10px; z-index: 2; }
        .item-body { padding: 10px 11px 12px; display: flex; flex-direction: column; flex: 1; }
        .item-name { font-size: 13px; font-weight: 600; color: var(--dark); line-height: 1.6; height: 42px; overflow: hidden; margin-bottom: 6px; }
        .item-meta { display: flex; align-items: center; gap: 8px; font-size: 11px; color: var(--gray); margin-bottom: 8px; }
        .item-meta .item-rate { color: var(--secondary); font-weight: bold; display: flex; align-items: center; gap: 3px; }
        .item-price-row { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 6px; }
        .item-price { font-size: 14px; font-weight: 800; color: var(--primary); }
        .item-price small { font-size: 10px; font-weight: 500; color: var(--gray); }
        .item-old { display: block; font-size: 11px; color: var(--gray); text-decoration: line-through; }
        .item-add { width: 32px; height: 32px; flex-shrink: 0; border: none; border-radius: 10px; background: var(--primary); color: #fff; font-size: 13px; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: background 0.2s; }
        .item-add:hover { background: var(--primary-dark); }
        .item-card.out .item-img { filter: grayscale(1); opacity: 0.6; }
        .item-unavailable { font-size: 11px; color: var(--gray); background: var(--light); border-radius: 8px; padding: 7px; text-align: center; }
        .products-empty { grid-column: 1 / -1; text-align: center; padding: 45px 15px; color: var(--gray); font-size: 13px; }
        .products-empty i { display: block; font-size: 38px; color: #dfe3e6; margin-bottom: 12px; }

        /* --- Business Detail Blocks (about / contact / hours / features) --- */
        .info-card { background: var(--white); border-radius: 15px; box-shadow: 0 4px 15px rgba(0,0,0,0.05); padding: 15px; margin: 0 15px 15px; }
        .info-card h4 { font-size: 15px; color: var(--dark); margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
        .info-card h4 i { color: var(--primary); font-size: 14px; }
        /* Row wrapper: stacked on mobile, becomes a 2-column grid on desktop */
        .info-row { display: block; }
        .info-row > .info-card { margin-left: 15px; margin-right: 15px; }
        .about-text { font-size: 13px; color: #555; line-height: 2; }
        .about-text.clamped { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
        .about-toggle { background: none; border: none; font-family: inherit; font-size: 12px; color: var(--primary); cursor: pointer; margin-top: 8px; padding: 0; }
        .info-list { list-style: none; }
        .info-list li { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; color: #555; padding: 10px 0; border-bottom: 1px dashed rgba(0,0,0,0.07); line-height: 1.9; }
        .info-list li:last-child { border-bottom: none; }
        .info-list li i { color: var(--gray); width: 16px; text-align: center; margin-top: 5px; flex-shrink: 0; }
        .info-list li b { color: var(--dark); font-weight: 600; }
        .info-list li .ltr { direction: ltr; text-align: right; }
        .hours-row { display: flex; justify-content: space-between; align-items: center; font-size: 13px; padding: 9px 0; border-bottom: 1px dashed rgba(0,0,0,0.07); }
        .hours-row:last-child { border-bottom: none; }
        .hours-row.today { color: var(--primary); font-weight: bold; }
        .hours-row span:last-child { direction: ltr; }
        .hours-row .closed-txt { color: var(--gray); }
        .feature-chips { display: flex; flex-wrap: wrap; gap: 8px; }
        .feature-chip { background: var(--light); border-radius: 10px; padding: 8px 12px; font-size: 12px; color: var(--dark); display: flex; align-items: center; gap: 7px; }
        .feature-chip i { color: #219653; font-size: 12px; }
        .social-row { display: flex; gap: 14px; margin-top: 5px; }
        .social-row i { font-size: 28px; color: var(--primary); cursor: pointer; transition: transform 0.2s, color 0.2s; }
        .social-row i:hover { transform: translateY(-2px); color: var(--primary-dark); }
        .map-box { position: relative; border-radius: 12px; overflow: hidden; height: 160px; background: #eef3f4; }
        .map-box img { width: 100%; height: 100%; object-fit: cover; }
        .map-box .map-pin { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 34px; color: var(--primary); text-shadow: 0 3px 6px rgba(0,0,0,0.35); }
        .map-box.business-map { width: 100%; height: 160px; }
        .map-box.business-map.leaflet-container { z-index: 0; }
        .map-box.business-map .leaflet-control-attribution { font-size: 9px; }
        .map-box-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 18px; text-align: center; color: var(--gray); }
        .map-box-empty i { font-size: 30px; color: #aab7bb; }
        .map-box-empty span { font-size: 11.5px; line-height: 1.8; }
        .map-btn { width: 100%; margin-top: 12px; background: var(--primary); color: #fff; border: none; border-radius: 12px; padding: 12px; font-family: inherit; font-size: 14px; font-weight: bold; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; }
        .map-btn:hover { background: var(--primary-dark); }

        /* --- Full shop information moved from the shop page --- */
        .place-shop-settings { background: var(--white); padding: 0 15px 25px; }
        .place-shop-settings-title { margin-bottom: 15px; }
        .place-shop-settings-title h3 { display: flex; align-items: center; gap: 8px; color: var(--dark); font-size: 18px; }
        .place-shop-settings-title h3 i { color: var(--primary); font-size: 16px; }
        .place-shop-settings-title span { display: block; color: var(--gray); font-size: 12px; line-height: 1.8; margin-top: 5px; }
        .place-shop-settings-summary { display: grid; grid-template-columns: 1fr; gap: 10px; }
        .place-shop-settings-row { display: flex; align-items: flex-start; gap: 12px; background: var(--light); border-radius: 14px; padding: 12px; }
        .place-shop-settings-row > i { width: 34px; height: 34px; border-radius: 10px; background: var(--white); color: var(--primary); display: flex; align-items: center; justify-content: center; font-size: 14px; flex-shrink: 0; }
        .place-shop-settings-row > div { min-width: 0; flex: 1; }
        .place-shop-settings-row h5 { font-size: 12px; color: var(--gray); font-weight: 500; margin-bottom: 4px; }
        .place-shop-settings-row p { font-size: 13px; color: var(--dark); line-height: 1.8; word-break: break-word; }
        .place-shop-settings-more { overflow: hidden; max-height: 0; transition: max-height 0.45s ease; }
        .place-shop-settings-more.open { max-height: 5000px; }
        .place-shop-settings-panel { margin-top: 15px; border: 1.5px solid var(--primary); border-radius: 18px; background: linear-gradient(180deg, var(--footer-bg-start) 0%, var(--footer-bg-end) 100%); padding: 14px; box-shadow: 0 6px 20px var(--footer-bg-end); }
        .place-shop-settings-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; padding-bottom: 11px; border-bottom: 1px dashed rgba(239, 58, 75, 0.3); }
        .place-shop-settings-head h4 { font-size: 14px; font-weight: 800; color: var(--primary); display: flex; align-items: center; gap: 8px; }
        .place-shop-settings-head > span { font-size: 11.5px; color: var(--gray); background: var(--white); padding: 4px 11px; border-radius: 20px; }
        .place-shop-settings-boxes { display: grid; grid-template-columns: 1fr; gap: 12px; }
        .place-shop-settings-box { background: var(--white); border-radius: 15px; padding: 14px; box-shadow: 0 4px 14px rgba(0,0,0,0.05); display: flex; flex-direction: column; min-width: 0; }
        .place-shop-settings-wide { margin-top: 12px; }
        .place-shop-settings-box-head { display: flex; align-items: center; gap: 9px; margin-bottom: 11px; }
        .place-shop-settings-box-head i { width: 30px; height: 30px; border-radius: 9px; background: rgba(239, 58, 75, 0.09); color: var(--primary); display: flex; align-items: center; justify-content: center; font-size: 13px; flex-shrink: 0; }
        .place-shop-settings-box-head h5 { font-size: 13px; font-weight: 700; color: var(--dark); }
        .place-shop-settings-empty { font-size: 12px; color: var(--gray); }
        .place-shop-settings-list { list-style: none; display: flex; flex-direction: column; gap: 9px; }
        .place-shop-settings-list li { display: flex; align-items: flex-start; gap: 9px; font-size: 12.5px; color: var(--dark); line-height: 1.9; }
        .place-shop-settings-list li > i { color: var(--primary); font-size: 12px; margin-top: 4px; flex-shrink: 0; width: 14px; text-align: center; }
        .place-shop-settings-list a { color: var(--dark); word-break: break-all; transition: color 0.2s; }
        .place-shop-settings-list a:hover { color: var(--primary); }
        .place-shop-settings-list .ltr { direction: ltr; text-align: right; unicode-bidi: embed; }
        .place-shop-settings-social { display: flex; gap: 12px; margin-top: 12px; padding-top: 11px; border-top: 1px solid rgba(0,0,0,0.05); }
        .place-shop-settings-social a { width: 34px; height: 34px; border-radius: 10px; background: var(--light); color: var(--primary); display: flex; align-items: center; justify-content: center; font-size: 16px; transition: background 0.2s, color 0.2s, transform 0.2s; }
        .place-shop-settings-social a:hover { background: var(--primary); color: #fff; transform: translateY(-2px); }
        .place-shop-settings-hours { background: var(--light); border-radius: 12px; overflow: hidden; }
        .place-shop-settings-hours-row { display: flex; justify-content: space-between; align-items: center; padding: 9px 12px; font-size: 12.5px; border-bottom: 1px solid rgba(0,0,0,0.05); }
        .place-shop-settings-hours-row:last-child { border-bottom: none; }
        .place-shop-settings-hours-row.today { background: rgba(239, 58, 75, 0.09); font-weight: bold; color: var(--primary); }
        .place-shop-settings-hours-row span:last-child { color: var(--gray); direction: ltr; }
        .place-shop-settings-hours-row.today span:last-child { color: var(--primary); }
        .place-shop-settings-hours-row.closed span:last-child { color: var(--primary); font-weight: bold; }
        .place-shop-settings-tags { display: flex; flex-wrap: wrap; gap: 8px; }
        .place-shop-settings-tags span { font-size: 12px; background: var(--light); color: var(--dark); padding: 7px 12px; border-radius: 20px; display: flex; align-items: center; gap: 6px; }
        .place-shop-settings-tags span i { color: var(--primary); font-size: 11px; }
        .place-shop-settings-facts { margin-top: auto; padding-top: 12px; display: flex; flex-direction: column; gap: 8px; }
        .place-shop-settings-facts > div { display: flex; align-items: center; justify-content: space-between; gap: 10px; background: var(--light); border-radius: 10px; padding: 8px 11px; }
        .place-shop-settings-facts span { font-size: 11.5px; color: var(--gray); }
        .place-shop-settings-facts b { font-size: 12px; color: var(--dark); text-align: left; }
        .place-shop-settings-map-box .map-btn { margin-top: auto; }
        .place-shop-settings-toggle { width: calc(100% - 0px); margin-top: 15px; background: var(--primary); border: 1px dashed rgba(0,0,0,0.15); border-radius: 12px; padding: 11px; font-family: inherit; font-size: 13px; color: var(--footer-bg-end); cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; }
        .place-shop-settings-toggle i { transition: transform 0.3s; }
        .place-shop-settings-toggle.open i { transform: rotate(180deg); }

        /* Products and services are a carousel on the business page. */
        .place-products-carousel { padding-top: 0 !important; }
        .place-products-carousel .swiper-slide { width: 85%; height: auto; display: flex; margin-left: 12px !important; }
        .place-products-carousel .item-card { width: 100%; }
        .place-products-carousel .products-empty { width: 100%; }

        /* Rating summary */
        .rate-summary { display: flex; gap: 18px; align-items: center; }
        .rate-big { text-align: center; flex-shrink: 0; }
        .rate-big b { font-size: 32px; color: var(--dark); display: block; line-height: 1.2; }
        .rate-big .stars { color: var(--secondary); font-size: 12px; }
        .rate-big span { font-size: 11px; color: var(--gray); display: block; margin-top: 4px; }
        .rate-bars { flex: 1; min-width: 0; }
        .rate-bar-row { display: flex; align-items: center; gap: 8px; font-size: 11px; color: var(--gray); margin-bottom: 6px; }
        .rate-bar { flex: 1; height: 6px; border-radius: 3px; background: var(--light); overflow: hidden; }
        .rate-bar i { display: block; height: 100%; background: var(--secondary); border-radius: 3px; }

        /* Gallery (opens in Fancybox) */
        .gallery-swiper .swiper-slide { width: 180px; margin-left: 12px !important; }
        .gallery-item { position: relative; display: block; border-radius: 15px; overflow: hidden; box-shadow: 0 4px 15px rgba(0,0,0,0.08); cursor: zoom-in; }
        .gallery-item img { width: 100%; height: 130px; object-fit: cover; transition: transform 0.4s ease; }
        .gallery-item:hover img { transform: scale(1.07); }
        .gallery-zoom-badge { position: absolute; top: 8px; left: 8px; width: 28px; height: 28px; border-radius: 9px; background: rgba(0,0,0,0.5); color: #fff; font-size: 12px; display: flex; align-items: center; justify-content: center; backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
        .gallery-caption { position: absolute; right: 0; left: 0; bottom: 0; padding: 18px 10px 9px; font-size: 11px; color: #fff; background: linear-gradient(0deg, rgba(0,0,0,0.75), transparent); opacity: 0; transition: opacity 0.3s ease; }
        .gallery-item:hover .gallery-caption { opacity: 1; }
        @media (hover: none) { .gallery-caption { opacity: 1; } }

        /* Fancybox theming to match the Dalij look */
        .fancybox__container { --f-button-hover-bg: var(--primary); --f-button-active-bg: var(--primary-dark); --f-spinner-color-2: var(--primary); font-family: 'Vazirmatn', sans-serif; }
        .fancybox__caption { font-family: 'Vazirmatn', sans-serif; font-size: 14px; line-height: 1.9; }
        .f-thumbs__slide__button { border-radius: 10px; overflow: hidden; }
        .fancybox__counter { direction: ltr; }

        /* نشان پیام خوانده‌نشده روی دکمه چت در نوار عملیات کسب و کار */
        .action-badge { position: absolute; top: 5px; left: 6px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: var(--primary); color: #fff; font-size: 9px; font-weight: bold; display: flex; align-items: center; justify-content: center; }
        .action-badge.hidden { display: none; }
        .biz-action { position: relative; }


        /* --- Advertising Section --- */
        .advert-section { padding: 40px 0; background: white; overflow: hidden; }
        .ad-swiper-container { padding: 20px 0; perspective: 1200px; }
        .ad-swiper { overflow: visible !important; padding: 0 15px !important; }
        .ad-swiper .swiper-slide { width: 85%; height: 180px; transition: transform 0.3s ease; }
        .advert-box { border-radius: 15px; overflow: hidden; position: relative; height: 100%; width: 100%; box-shadow: 0 10px 30px rgba(0,0,0,0.15); }
        .advert-box img { width: 100%; height: 100%; object-fit: cover; }
        .advert-overlay { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0,0,0,0.7), transparent); display: flex; flex-direction: column; justify-content: center; padding: 20px; }

        /* Custom Advert h3 Style */
        .advert-overlay h3 {
            color: #FFFFFF;
            background: #0000002e;
            text-shadow: #434343 1px 2px 2px;
            font-size: 18px;
            margin-bottom: 5px;
            padding: 5px 10px;
            align-self: flex-start;
            border-radius: 5px;
        }

        /* Custom Advert p Style */
        .advert-overlay p {
            color: #000000;
            font-size: 12px;
            background: #ffcf007a;
            align-self: flex-start;
            padding: 5px 10px;
            border-radius: 5px;
        }

        /* --- Desktop Footer & Wave --- */
        .footer-wave { display: none; line-height: 0; }
        .footer-wave svg { width: 100%; height: 80px; display: block; }
        footer { display: none; background: linear-gradient(135deg, var(--footer-bg-start) 0%, var(--footer-bg-end) 100%); color: #ccc; padding: 0 5% 40px; }
        footer .footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.5fr; gap: 40px; max-width: 1200px; margin: 0 auto; padding-top: 20px; }
        footer h4 { color: var(--gold); font-size: 18px; margin-bottom: 20px; display: flex; align-items: center; gap: 10px; }
        footer h4::after { content: ''; flex: 1; height: 2px; background: linear-gradient(90deg, var(--gold), transparent); }
        footer ul { list-style: none; }
        footer ul li { margin-bottom: 12px; font-size: 14px; color: #dcdcdc; cursor: pointer; display: flex; align-items: center; gap: 10px; transition: color 0.3s, padding-right 0.3s; }
        footer ul li:hover { color: var(--gold); padding-right: 5px; }
        footer ul li i { color: var(--gold); width: 16px; text-align: center; }
        .footer-contact li { align-items: flex-start; }
        .newsletter-form { display: flex; background: rgba(255,255,255,0.1); border-radius: 10px; padding: 5px; margin-bottom: 20px; border: 1px solid rgba(212, 175, 55, 0.3); }
        .newsletter-form input { flex: 1; min-width: 0; background: none; border: none; outline: none; color: white; padding: 10px; font-family: inherit; font-size: 14px; }
        .newsletter-form input::placeholder { color: #aaa; }
        .newsletter-form button { flex-shrink: 0; background: var(--gold); color: var(--footer-bg-start); border: none; padding: 0 15px; border-radius: 8px; cursor: pointer; font-family: inherit; font-weight: bold; transition: background 0.3s; }
        .newsletter-form button:hover { background: var(--gold-light); }
        .footer-badges { display: flex; gap: 15px; margin-top: 20px; }
        .badge-placeholder { width: 90px; height: 100px; background: white; border-radius: 8px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 10px; box-shadow: 0 4px 10px rgba(0,0,0,0.2); }
        .badge-placeholder i { font-size: 30px; color: #555; margin-bottom: 5px; }
        .badge-placeholder span { font-size: 10px; color: #333; font-weight: bold; }
        .footer-copyright { text-align: center; margin-top: 40px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,0.1); font-size: 13px; color: #888; }

        /* Bottom Navigation */
        .bottom-nav { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 600px; background: linear-gradient(135deg, var(--footer-bg-start) 0%, var(--footer-bg-end) 100%); display: flex; justify-content: space-around; padding: 10px 0; box-shadow: 0 -2px 10px rgba(0,0,0,0.2); z-index: 100; }
        .nav-item { display: flex; flex-direction: column; align-items: center; gap: 4px; color: #dcdcdc; cursor: pointer; }
        .nav-item i { font-size: 20px; }
        .nav-item span { font-size: 10px; }
        .nav-item.active { color: var(--gold); }

        @media (min-width: 768px) {
            body { max-width: 100%; }
            .swiper-carousel .swiper-slide { width: 250px; }
            header { max-width: 100%; padding: 15px 5%; }
            /* Removed background from main-slider-container in desktop */
            .main-slider-container { padding: 20px 5%; }
            .swiper-main { border-radius: 20px; height: 350px; }
            .main-cover-static { border-radius: 20px; height: 350px; }
            .biz-hero { border-radius: 20px; margin: 20px 5%; padding: 20px; }
            .biz-logo { margin-top: 0; width: 90px; height: 90px; }
            .search-section, .section-header { padding-left: 5%; padding-right: 5%; }
            .section { padding: 30px 0; }
            .category-grid { grid-template-columns: repeat(6, 1fr); }
            .cat-group-grid { grid-template-columns: repeat(8, 1fr); }
            .products-grid { grid-template-columns: repeat(4, 1fr); padding-left: 5%; padding-right: 5%; }
            .products-toolbar, .active-chips { padding-left: 5%; padding-right: 5%; }
            .info-card { margin-left: 5%; margin-right: 5%; }
            .shop-cta { margin-left: 5%; margin-right: 5%; padding: 20px 24px; }
            .shop-cta-text b { font-size: 17px; }
            .shop-cta-text span { font-size: 12.5px; }
            /* Contact/address (right, wider) next to working hours (left).
               In RTL the first grid item lands in the right-hand column. */
            .info-row-contact-hours {
                display: grid;
                grid-template-columns: 1.4fr 1fr;
                gap: 15px;
                align-items: start;
                margin: 0 5% 15px;
            }
            .info-row-contact-hours > .info-card { margin: 0; height: 100%; }
            /* Features / social / map, three across (RTL order: right → left) */
            .info-row-triple {
                display: grid;
                grid-template-columns: repeat(3, 1fr);
                gap: 15px;
                align-items: start;
                margin: 0 5% 15px;
            }
            .info-row-triple > .info-card {
                margin: 0;
                height: 100%;
                display: flex;
                flex-direction: column;
            }
            /* Push the directions button to the bottom so the map card lines up */
             .info-row-triple .map-btn { margin-top: auto; }
             .info-row-triple .map-box { margin-bottom: 12px; }
             .biz-stats { grid-template-columns: repeat(4, 1fr); }
             .place-shop-settings { margin: 0 5%; border-radius: 18px; padding: 0 25px 25px; }
             .place-shop-settings-summary { grid-template-columns: repeat(2, 1fr); }
             .place-shop-settings-boxes { grid-template-columns: repeat(2, 1fr); }
             .ad-swiper .swiper-slide { width: calc((100% - 40px) / 3); height: 220px; }
         }
        @media (max-width: 767px) {
            .swiper-main { border-radius: 0px; height: 350px; }
            .main-cover-static { border-radius: 0px; height: 350px; }
        }

        /* Real desktop only: horizontal top menu replaces the drawer, bottom-nav
           gives way to the full footer. Tablet keeps the mobile-style bottom-nav + drawer. */
        @media (min-width: 1024px) {
            .menu-btn { display: none; }
            .desktop-nav { display: flex; }
            .user-menu-wrap { display: block; }
            body { padding-bottom: 0; }
            .bottom-nav { display: none; }
            .footer-wave, footer { display: block; }
            .place-shop-settings-summary { grid-template-columns: repeat(4, 1fr); }
            .place-shop-settings-boxes { grid-template-columns: repeat(3, 1fr); }
        }
