/* g24 — deck "Category Bar · Mega-menu" (30-09-2026). Loaded by
   partials/menu/lazy_script, i.e. by both storefront layouts. */

/* ── Slide 3: the black bar — names never cut ─────────────────────────────── */
.market-place-navbar ul li a {
  white-space: nowrap;
}
/* The edge that still hides categories fades instead of slicing a name in two
   ("Componer…"); odb-mega-products.js sets the classes from the scroll position. */
.marketplace-scrollbar-horizontal-scroll.odb-bar-more-right {
  -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 48px), transparent);
  mask-image: linear-gradient(to right, #000 calc(100% - 48px), transparent);
}
.marketplace-scrollbar-horizontal-scroll.odb-bar-more-left {
  -webkit-mask-image: linear-gradient(to left, #000 calc(100% - 48px), transparent);
  mask-image: linear-gradient(to left, #000 calc(100% - 48px), transparent);
}
.marketplace-scrollbar-horizontal-scroll.odb-bar-more-left.odb-bar-more-right {
  -webkit-mask-image: linear-gradient(to right, transparent, #000 48px, #000 calc(100% - 48px), transparent);
  mask-image: linear-gradient(to right, transparent, #000 48px, #000 calc(100% - 48px), transparent);
}
.marketplace-scrollbar-btn.is-end {
  opacity: 0.35;
  cursor: default;
}

/* The department list on the left of the mega-menu: now links. */
.market-place-mega-left ul li a {
  color: inherit;
  flex: 1;
  text-decoration: none;
}

/* ── Slide 4: subcategory list, scrolls INSIDE the menu ───────────────────── */
.odb-mm .menu-left-panel-box {
  display: flex;
  flex-direction: column;
}
.odb-mm .main-category-group {
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
  margin-bottom: 0;
}
.odb-mm .odb-mm-subs {
  flex: 1 1 auto;
  min-height: 0;
  max-height: 340px;
  overflow-y: auto;
  overscroll-behavior: contain; /* the page does not move */
  align-content: flex-start;
  padding-right: 4px;
}
.odb-mm .odb-mm-subs::-webkit-scrollbar {
  width: 4px;
}
.odb-mm .odb-mm-subs::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 4px;
}
.odb-mm .odb-mm-sub {
  border: 2px solid transparent;
  border-radius: 8px;
  padding: 6px 2px;
}
.odb-mm .odb-mm-sub > a {
  display: block;
  color: #333;
  text-decoration: none;
}
/* Slide 5: the hovered / active subcategory is highlighted in orange. */
.odb-mm .odb-mm-sub.is-active {
  border-color: #f99e1c;
}
.odb-mm .odb-mm-sub.is-active p,
.odb-mm .odb-mm-sub:hover p {
  color: #f99e1c;
}

/* ── Slide 5: the products of the active subcategory ──────────────────────── */
.odb-mm .menu-right-panel {
  display: flex;
  flex-direction: column;
}
.odb-mm .odb-mm-products {
  display: flex;
  flex-direction: column;
  max-height: 380px;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.odb-mm .odb-mm-heading a {
  color: #f99e1c;
  text-decoration: none;
}
.odb-mm-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.odb-mm-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  color: #222;
  text-decoration: none;
}
.odb-mm-card:hover .odb-mm-name {
  color: #f99e1c;
}
.odb-mm-img {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 96px; /* two rows of four fit the 420 px menu without scrolling */
  background: #f5f5f5;
  border-radius: 8px;
  overflow: hidden;
}
.odb-mm-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.odb-mm-name {
  margin-top: 6px;
  font-size: 12px;
  line-height: 16px;
  max-height: 16px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 1; /* full name in the card's title attribute */
  -webkit-box-orient: vertical;
}
.odb-mm-price {
  margin-top: 2px;
  font-size: 13px;
  font-weight: 600;
  color: #f99e1c;
}
.odb-mm-empty {
  margin: 8px 0 12px;
  color: #777;
  font-size: 13px;
}
.odb-mm-all {
  align-self: flex-end;
  margin-top: 10px;
  font-size: 13px;
  font-weight: 600;
  color: #f99e1c !important;
  text-decoration: none;
}

/* Skeleton while a panel loads. */
.odb-mm-skel .odb-mm-img,
.odb-mm-skel .odb-mm-name,
.odb-mm-skel .odb-mm-price,
.odb-mm-skel-line {
  background: linear-gradient(90deg, #f0f0f0 25%, #e6e6e6 37%, #f0f0f0 63%);
  background-size: 400% 100%;
  animation: odb-mm-shimmer 1.2s ease infinite;
  border-radius: 6px;
}
.odb-mm-skel .odb-mm-name {
  height: 12px;
  width: 80%;
}
.odb-mm-skel .odb-mm-price {
  height: 12px;
  width: 45%;
}
.odb-mm-skel-line {
  height: 12px;
  width: 30%;
  border: 0 !important;
}
@keyframes odb-mm-shimmer {
  0% { background-position: 100% 50%; }
  100% { background-position: 0 50%; }
}

@media (max-width: 1199px) {
  .odb-mm-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* ── Slide 5, mobile: the drawer's categories ─────────────────────────────── */
.odb-mnav-section {
  display: block;
  padding: 12px 20px 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #8a8f98;
}
.odb-mnav-cat .odb-mnav-sub a.odb-mnav-cat-all {
  font-weight: 600;
  color: #e08a10;
}

/* ── g53 — deck "MegaMenu and Smart Search" (02-10-2026) slide 2: smaller tiles, more products ──
   ≈100×60 thumbnails showing the WHOLE picture (contain, never cropped), 6 per row, up to 18
   (3 rows) with the grid scrolling inside the panel, name on one line (ellipsis) + price in Kz below,
   "View all products ›" kept. */
.odb-mm .odb-mm-products {
  max-height: none;
  overflow: visible;
}
.odb-mm-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px 10px;
  max-height: 336px; /* 3 rows */
  overflow-y: auto;
  overscroll-behavior: contain; /* the page does not move */
  padding-right: 4px;
}
.odb-mm-grid::-webkit-scrollbar {
  width: 4px;
}
.odb-mm-grid::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 4px;
}
.odb-mm-img {
  height: 60px;
  background: #fff;
  border: 1px solid #f0f0f0;
  border-radius: 6px;
}
.odb-mm-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.odb-mm-name {
  display: block;
  margin-top: 4px;
  font-size: 11px;
  line-height: 15px;
  max-height: 15px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.odb-mm-price {
  margin-top: 1px;
  font-size: 11px;
  line-height: 15px;
  white-space: nowrap;
}
.odb-mm-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
}
.odb-mm-foot .odb-mm-all {
  margin-top: 0;
}
.odb-mm-more {
  display: none;
  font-size: 12px;
  color: #777;
}
.odb-mm-more.is-wide {
  display: inline;
}
@media (max-width: 1199px) {
  .odb-mm-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .odb-mm-more {
    display: inline;
  }
}
