/* Materials catalog — filter chips + compact grid */
.fab-mat-filter-wrap {
  margin: 0 0 1.25rem;
  position: relative;
}

.fab-mat-filter {
  position: relative;
  perspective: 520px;
  padding: 0 1.65rem;
}

.fab-mat-filter--wrap {
  padding: 0;
  perspective: none;
}

.fab-mat-filter--wrap .fab-mat-filter__nav {
  display: none;
}

.fab-mat-filter--wrap .fab-mat-filter__viewport {
  overflow: visible;
  mask-image: none;
  -webkit-mask-image: none;
}

.fab-mat-filter--wrap .fab-mat-filter__track {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 0.65rem;
  padding: 0;
  min-height: 0;
  transform-style: flat;
}

.fab-mat-filter__viewport {
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}

.fab-mat-filter__viewport::-webkit-scrollbar {
  display: none;
}

.fab-mat-filter__track {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.3rem;
  padding: 0.15rem 0.1rem;
  min-height: 1.75rem;
  transform-style: preserve-3d;
}

.fab-mat-filter__group {
  flex: 0 0 100%;
  font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #55617a;
  line-height: 1.2;
  margin: 0.15rem 0 0.1rem;
}

.fab-mat-filter__group:first-child {
  margin-top: 0;
}

.fab-mat-filter__chip {
  flex: 0 0 auto;
  padding: 0.55rem 1.05rem;
  border: 1px solid #94a3b8;
  border-radius: 0;
  background: #fff;
  color: #1e3a5f;
  font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 0.8125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  line-height: 1.25;
  cursor: pointer;
  white-space: nowrap;
  transform: translateZ(0);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.15s, color 0.15s, border-color 0.15s;
  box-shadow: 3px 3px 0 #cbd5e1;
}

.fab-mat-filter__chip:hover {
  transform: translate(-1px, -1px);
  border-color: #2563eb;
  color: #2563eb;
  box-shadow: 4px 4px 0 #bfdbfe;
}

.fab-mat-filter__chip.is-active {
  background: #2563eb;
  color: #fff;
  border-color: #1e40af;
  box-shadow: 4px 4px 0 #1e40af;
  transform: none;
}

.fab-mat-filter__chip:disabled {
  opacity: 0.5;
  pointer-events: none;
}

.fab-mat-filter__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 1.35rem;
  height: 1.35rem;
  padding: 0;
  border: 1px solid #cbd5e1;
  border-radius: 2px;
  background: #fff;
  color: #0c2340;
  cursor: pointer;
  box-shadow: 2px 2px 0 #cbd5e1;
  z-index: 2;
  display: grid;
  place-items: center;
  font-size: 0.85rem;
  line-height: 1;
}

.fab-mat-filter__nav--prev {
  left: 0;
}

.fab-mat-filter__nav--next {
  right: 0;
}

.fab-mat-filter__nav:hover {
  border-color: #2563eb;
  color: #2563eb;
}

/* Compact product grid */
#productsBlock.fab-layout-static-grid {
  padding-top: 2.5rem;
  padding-bottom: 2.5rem;
}

#productsBlock #mainLayoutM #elementsList {
  margin-top: 0.25rem;
}

#productsBlock #mainLayoutM #elementsList > .fab-mat-grid__item--hidden {
  display: none !important;
}

#productsBlock .fab-card.product,
.fab-bp-mat-strip .fab-card.product {
  padding: 0.85rem 0.95rem 0.95rem;
  height: 100%;
  border-radius: 0;
}

#productsBlock .fab-card.product .fab-card-product__title,
.fab-bp-mat-strip .fab-card.product .fab-card-product__title {
  margin: 0 0 0.35rem;
  font-size: 1.0625rem;
  line-height: 1.2;
}

#productsBlock .fab-card.product .fab-card__content .text,
.fab-bp-mat-strip .fab-card.product .fab-card__content .text {
  margin: 0 0 0.65rem;
  font-size: 0.8125rem;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

#productsBlock .fab-card.product .fab-card__content .footer,
.fab-bp-mat-strip .fab-card.product .fab-card__content .footer {
  gap: 0.35rem;
  margin-top: auto;
}

#productsBlock .fab-card.product .fab-card__content .footer > *,
.fab-bp-mat-strip .fab-card.product .fab-card__content .footer > * {
  padding: 0.4rem 0.55rem;
  border-radius: 0;
  flex: 1 1 auto;
  min-width: 0;
}

#productsBlock .fab-card.product .fab-card__content .footer > .price,
.fab-bp-mat-strip .fab-card.product .fab-card__content .footer > .price {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
}

#productsBlock .fab-card.product .fab-card__content .footer > .time,
.fab-bp-mat-strip .fab-card.product .fab-card__content .footer > .time {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

#productsBlock .fab-card.product .fab-card__content .footer .fab-text-sm,
.fab-bp-mat-strip .fab-card.product .fab-card__content .footer .fab-text-sm {
  font-size: 0.6875rem;
}

#productsBlock .fab-card.product .fab-card__content .footer .fab-text-button,
.fab-bp-mat-strip .fab-card.product .fab-card__content .footer .fab-text-button {
  font-size: 0.8125rem;
}

.fab-mat-grid-more-wrap .fab-btn {
  min-width: 11rem;
  padding: 0.65rem 1.35rem;
  font-size: 0.8125rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-radius: 0;
  box-shadow: 3px 3px 0 #cbd5e1;
}

.fab-mat-grid-more-wrap .fab-btn:hover {
  box-shadow: 4px 4px 0 #bfdbfe;
  transform: translate(-1px, -1px);
}

#mainLayoutM #elementsList.overlay {
  position: relative;
  min-height: 100px;
  opacity: 0.45;
  pointer-events: none;
}

#mainLayoutM #elementsList.overlay::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(37, 99, 235, 0.08), transparent);
  animation: fab-mat-shimmer 0.9s linear infinite;
}

@keyframes fab-mat-shimmer {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

@media (min-width: 960px) {
  .fab-mat-filter--wrap .fab-mat-filter__group {
    flex: 0 0 auto;
    margin: 0 0.35rem 0 0;
    padding-right: 0.5rem;
    border-right: 1px solid #e2e8f0;
  }

  .fab-mat-filter--wrap .fab-mat-filter__group:not(:first-child) {
    margin-left: 0.35rem;
  }
}

@media (max-width: 640px) {
  .fab-mat-filter {
    padding: 0 1.4rem;
  }

  .fab-mat-filter--wrap {
    padding: 0;
  }

  .fab-mat-filter__chip {
    font-size: 0.75rem;
    padding: 0.48rem 0.85rem;
  }
}
