

@media (max-width: 991px) {

  .welcome-section {
    display: none !important;
  }

  .main-navbar {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    z-index: 2000 !important;
    background: #fff !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
  }

  body {
    padding-top: 65px !important;
    padding-bottom: 75px !important; /* room for bottom nav */
  }

 /* .main-navbar .post-ad-btn.d-lg-none */
  .main-navbar .login-btn.d-lg-none{
    display: none !important;
  }

  .main-navbar .category-btn {
    display: none !important;
  }

  .main-navbar .category-mega {
    display: block !important;
  }
  
  .main-navbar .category-mega:not(.open) .mega-panel {
    display: none !important;
  }

  .main-navbar:has(.category-mega.open) {
    z-index: 9999 !important;
  }

  .main-navbar .category-mega.open .mega-panel {
    display: flex !important;
    flex-direction: column;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100vh !important;
    z-index: 9000 !important;
    background: #fff !important;
    overflow: hidden !important; 
  }

  .main-navbar .category-mega.open .mega-scroll {
    flex: 1;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 100px !important; 
  }

  .mega-mobile-header {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 16px 20px;
    z-index: 10;
  }

  .main-navbar .nav-links {
    display: none !important;
  }

  .main-navbar .container.d-lg-none {
    display: none;
  }

  .navbar-collapse.collapse,
  .navbar-collapse.collapsing,
  .navbar-collapse.show {
    display: none !important;
    visibility: hidden !important;
  }

  .mobile-bottom-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 62px;
    background: #ffffff;
    border-top: 1px solid #e8ecf0;
    box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.07);
    z-index: 5000;
    justify-content: space-around;
    align-items: center;
    padding: 0 8px;
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }

  .mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    text-decoration: none;
    color: #6b7280;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.3px;
    border: none;
    background: none;
    cursor: pointer;
    padding: 8px 24px;
    border-radius: 12px;
    transition: color 0.2s, background 0.2s;
    -webkit-tap-highlight-color: transparent;
  }

  .mobile-nav-item i {
    font-size: 22px;
    color: #6b7280;
    transition: color 0.2s;
  }

  .mobile-nav-item:hover,
  .mobile-nav-item:active {
    color: #F57E20;
    background: rgba(245, 126, 32, 0.08);
  }

  .mobile-nav-item:hover i,
  .mobile-nav-item:active i {
    color: #F57E20;
  }




  body.search-active .main-navbar .container.d-lg-none {
    display: flex !important;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 8000;
    background: rgba(255, 255, 255, 0.99);
    flex-direction: column;
    justify-content: flex-start;
    padding: 24px 20px 20px;
    overflow-y: auto;
    animation: searchSlideDown 0.25s ease-out forwards;
  }

  @keyframes searchSlideDown {
    from { opacity: 0; transform: translateY(-12px); }
    to   { opacity: 1; transform: translateY(0); }
  }

  .search-overlay-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
  }

  .search-overlay-header h5 {
    font-size: 18px;
    font-weight: 700;
    color: #1a202c;
    margin: 0;
  }

  .search-close-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: none;
    background: #f3f4f6;
    color: #374151;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.2s;
    -webkit-tap-highlight-color: transparent;
  }

  .search-close-btn:hover {
    background: #e5e7eb;
  }

  body.search-active .main-navbar .search-form-mobile {
    width: 100% !important;
    border-radius: 12px !important;
    overflow: hidden;
 
  }

  body.search-active .main-navbar .search-input {
    font-size: 16px;
    padding: 14px 18px 14px 48px !important;
  }





  

  .drawer-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 5999;
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
  }

  .drawer-overlay.show {
    display: block;
    animation: fadeIn 0.2s ease-out;
  }

  @keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
  }

  .mobile-drawer {
    position: fixed;
    top: 0;
    right: -100%;
    width: min(300px, 85vw);
    height: 100%;
    background: #ffffff;
    z-index: 6000;
    box-shadow: -6px 0 24px rgba(0, 0, 0, 0.12);
    transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }

  .mobile-drawer.open {
    right: 0;
  }



  .drawer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 20px 16px;
    background: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
    flex-shrink: 0;
  }

  .drawer-logo {
    font-size: 18px;
    font-weight: 700;
    color: #1a202c;
    letter-spacing: -0.3px;
  }

  .drawer-close-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: none;
    background: #e5e7eb;
    border-radius: 50%;
    color: #374151;
    font-size: 15px;
    cursor: pointer;
    transition: background 0.2s;
    -webkit-tap-highlight-color: transparent;
  }

  .drawer-close-btn:hover {
    background: #d1d5db;
  }

  /* Drawer body */
  .drawer-body {
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 12px 0;
  }

  .drawer-nav {
    list-style: none;
    margin: 0;
    padding: 0;
  }

  .drawer-nav-item {
    margin: 0;
  }

  .drawer-nav-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    text-decoration: none;
    color: #374151;
    font-size: 15px;
    font-weight: 500;
    transition: background 0.15s, color 0.15s;
    -webkit-tap-highlight-color: transparent;
  }

  .drawer-nav-link i {
    font-size: 18px;
    color: #9ca3af;
    width: 22px;
    text-align: center;
    flex-shrink: 0;
    transition: color 0.15s;
  }

  .drawer-nav-link:hover,
  .drawer-nav-link:active {
    background: rgba(245, 126, 32, 0.06);
    color: #F57E20;
  }

  .drawer-nav-link:hover i,
  .drawer-nav-link:active i {
    color: #F57E20;
  }

  .drawer-post-ad {
    color: #F57E20 !important;
    font-weight: 600 !important;
  }

  .drawer-post-ad i {
    color: #F57E20 !important;
  }

  .drawer-nav-divider {
    height: 1px;
    background: #f3f4f6;
    margin: 8px 20px;
    display: block;
  }


  body.drawer-open,
  body.search-active {
    overflow: hidden !important;
  }

}

@media (min-width: 992px) {
  .mobile-bottom-nav,
  .mobile-drawer,
  .drawer-overlay {
    display: none !important;
  }
}





.btn-searchnew{
    background-color: #F57E20 !important;
    color: white !important;
}