@media (max-width: 991px) {

  /* ===============================
     WRAPPER
  =============================== */

  .nav-wrapper {
      display: flex;
      justify-content: flex-start;
      align-items: center;
      gap: var(--space-sm);
      width: 100%;
  }

  .nav-wrapper .nav-right {
      margin-left: auto;
  }

  .nav-wrapper .nav-left {
      flex: 1 1 auto;
      min-width: 0;
  }

  /* Desktop ausblenden */
  .nav-desktop {
      display: none;
  }

  /* ===============================
     BURGER
  =============================== */

  .nav-toggle {
      display: block;
      font-size: 24px;
      background: none;
      border: none;
      color: white;
      cursor: pointer;
  }

  /* ===============================
     DRAWER
  =============================== */

  .mobile-drawer {
      position: fixed;
      top: 0;
      left: -100%;
      width: 80%;
      height: 100vh;

      background: var(--color-primary);
      padding: var(--space-xl);

      transition: left 0.3s ease;
      z-index: 2000;

      display: flex;
      flex-direction: column;
      gap: var(--space-lg);
  }

  .mobile-drawer.open {
      left: 0;
  }

  .nav-close {
      align-self: flex-end;
      background: none;
      border: none;
      color: white;
      font-size: 24px;
      cursor: pointer;
  }

  /* ===============================
     NAV VERTIKAL
  =============================== */

  .mobile-drawer .main-nav {
      width: 100%;
  }

  .mobile-drawer .nav-root {
      display: flex;
      flex-direction: column;
      gap: var(--space-md);
  }

  .mobile-drawer .nav-item {
      width: 100%;
      display: flex;
      flex-wrap: wrap;
      align-items: center;
  }

  .mobile-drawer .nav-item > a {
      flex: 1;
      display: block;
      padding: 0.75rem 0;
      color: white;
      text-decoration: none;
      min-width: 0;
  }

  /* Toggle-Button: sichtbar und klickbar (nicht vom Link überdeckt) */
  .mobile-drawer .submenu-toggle {
      flex-shrink: 0;
      display: flex;
      align-items: center;
      justify-content: center;
      width: 44px;
      height: 44px;
      margin: -0.75rem 0;
      padding: 0;
      background: none;
      border: none;
      color: white;
      cursor: pointer;
      font-size: 1.2rem;
      position: relative;
      z-index: 2;
  }

  .mobile-drawer .submenu-toggle::before {
      content: '+';
  }

  .mobile-drawer .has-children.open > .submenu-toggle::before {
      content: '−';
  }

  /* ===============================
     SUBMENU (Accordion)
  =============================== */

  .mobile-drawer .submenu {
      display: none;
      flex-basis: 100%;
      width: 100%;
      padding-left: 1rem;
      margin-top: 0.25rem;
      margin-bottom: 0.5rem;
      list-style: none;
      /* Kein weißer Kasten: Drawer-Farben übernehmen */
      background: transparent;
      position: static;
      box-shadow: none;
      min-width: 0;
      border-left: 2px solid rgba(255,255,255,0.3);
  }

  .mobile-drawer .has-children.open > .submenu {
      display: block;
  }

  .mobile-drawer .submenu .nav-item > a {
      padding: 0.5rem 0;
      opacity: 0.9;
      color: white;
  }

  /* Language Switcher */
  .mobile-drawer .lang-list {
      flex-direction: row;
      gap: calc(var(--space-sm) * 2);
  }

  /* ===============================
     Listing-Suche: Desktop-Kaskade ausblenden (Mega-Menü)
  =============================== */

  .listing-search-form__main {
      touch-action: pan-x;
  }

  .listing-type-btn {
      touch-action: manipulation;
      cursor: pointer;
  }

  #listingCascadeStep2,
  .listing-search-submit-wrap {
      display: none !important;
  }

  .listing-search-mega[hidden] {
      display: none !important;
  }

  .listing-search-mega:not([hidden]) {
      display: block;
  }

  /* top wird per JS an .nav-wrapper-Unterkante gesetzt (viewport-fixed) */
  .listing-search-mega {
      position: fixed;
      z-index: 10050;
      left: 0;
      right: 0;
      top: 0;
      bottom: 0;
      -webkit-transform: translateZ(0);
      transform: translateZ(0);
      pointer-events: none;
  }

  .listing-search-mega:not([hidden]) {
      pointer-events: auto;
  }

  .listing-search-mega__backdrop {
      position: absolute;
      inset: 0;
      border: 0;
      padding: 0;
      margin: 0;
      background: rgba(15, 23, 42, 0.48);
      cursor: pointer;
      -webkit-tap-highlight-color: transparent;
  }

  .listing-search-mega__sheet {
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      max-height: min(78vh, 560px);
      min-height: 0;
      background: #fff;
      border-radius: 0 0 18px 18px;
      box-shadow: 0 16px 48px rgba(0, 0, 0, 0.22);
      display: flex;
      flex-direction: column;
      overflow: hidden;
      animation: listingMegaSheetIn 0.22s ease-out;
  }

  @keyframes listingMegaSheetIn {
      from {
          opacity: 0;
          transform: translateY(-10px);
      }
      to {
          opacity: 1;
          transform: translateY(0);
      }
  }

  .listing-search-mega__header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      padding: 12px 14px;
      border-bottom: 1px solid #e5e7eb;
      flex-shrink: 0;
  }

  .listing-search-mega__title {
      margin: 0;
      font-size: 1.05rem;
      font-weight: 700;
      color: var(--color-primary, #1a365d);
      line-height: 1.25;
  }

  .listing-search-mega__close {
      flex-shrink: 0;
      width: 44px;
      height: 44px;
      margin: -6px -8px -6px 0;
      border: none;
      border-radius: 10px;
      background: transparent;
      color: #64748b;
      font-size: 1.75rem;
      line-height: 1;
      cursor: pointer;
      -webkit-tap-highlight-color: transparent;
  }

  .listing-search-mega__close:hover,
  .listing-search-mega__close:focus-visible {
      background: #f1f5f9;
      color: #0f172a;
      outline: none;
  }

  /* Eine Zeile mit fester Flex-Höhe, sonst wächst das Grid mit dem Inhalt und scrollt nicht (v. a. iOS) */
  .listing-search-mega__grid {
      display: grid;
      grid-template-columns: 1fr 1fr;
      grid-template-rows: minmax(0, 1fr);
      gap: 0;
      flex: 1 1 auto;
      min-height: 0;
      overflow: hidden;
  }

  .listing-search-mega__col {
      padding: 10px 12px 14px;
      min-width: 0;
      min-height: 0;
      max-height: 100%;
      overflow-x: hidden;
      overflow-y: auto;
      -webkit-overflow-scrolling: touch;
      overscroll-behavior: contain;
      touch-action: pan-y;
      border-right: 1px solid #e5e7eb;
  }

  .listing-search-mega__col:last-child {
      border-right: 0;
  }

  .listing-search-mega__col-label {
      margin: 0 0 8px;
      font-size: 11px;
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.05em;
      color: #64748b;
  }

  .listing-search-mega__list {
      list-style: none;
      margin: 0;
      padding: 0;
  }

  .listing-search-mega__itembtn {
      display: block;
      width: 100%;
      text-align: left;
      padding: 12px 10px;
      margin: 0 0 6px;
      border: 1px solid #e2e8f0;
      border-radius: 10px;
      background: #f8fafc;
      color: #0f172a;
      font: inherit;
      font-size: 15px;
      font-weight: 500;
      line-height: 1.3;
      cursor: pointer;
      -webkit-tap-highlight-color: transparent;
  }

  .listing-search-mega__itembtn:hover,
  .listing-search-mega__itembtn:focus-visible {
      border-color: #cbd5e1;
      background: #f1f5f9;
      outline: none;
  }

  .listing-search-mega__itembtn.is-active {
      background: var(--color-primary, #1a365d);
      color: #fff;
      border-color: transparent;
  }

  .listing-search-mega__hint {
      margin: 0;
      font-size: 14px;
      color: #64748b;
      line-height: 1.45;
  }

  .listing-search-mega__empty {
      margin: 0;
      font-size: 14px;
      color: #64748b;
      line-height: 1.45;
  }

}

@media (min-width: 992px) {

  .listing-search-mega {
      display: none !important;
  }

}
