/* Public catalog — responsive */
.catalog-section { overflow: visible; }
.catalog-layout {
  display: grid;
  grid-template-columns: minmax(220px, 260px) minmax(0, 1fr);
  gap: 24px 28px;
  align-items: start;
}
.cat-filters-toggle {
  display: none;
  width: 100%;
  box-sizing: border-box;
  border: 1px solid var(--mk-line, #e2e8f0);
  background: #fff;
  border-radius: 12px;
  padding: 12px 16px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  color: #0f172a;
  text-align: left;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.cat-filters-toggle-label { flex: 1; }
.cat-filters-chevron {
  flex: 0 0 auto;
  width: 1.1em;
  height: 1.1em;
  border-right: 2px solid #64748b;
  border-bottom: 2px solid #64748b;
  transform: rotate(45deg);
  transition: transform .2s ease;
  margin-top: -4px;
}
.cat-filters-toggle[aria-expanded="true"] .cat-filters-chevron {
  transform: rotate(-135deg);
  margin-top: 4px;
}
.catalog-filters {
  position: sticky;
  top: 88px;
  padding: 18px;
  border-radius: 16px;
  background: #fff;
  border: 1px solid var(--mk-line, #e2e8f0);
  max-height: calc(100vh - 110px);
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}
.catalog-filters form { display: grid; gap: 16px; }
.cat-search span,
.cat-filter-group h2,
.cat-seo-links h2 {
  display: block;
  margin: 0 0 8px;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--mk-muted, #64748b);
}
.cat-search input,
.cat-select-label select {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  border: 1px solid var(--mk-line, #e2e8f0);
  border-radius: 12px;
  padding: 11px 12px;
  font: inherit;
  font-size: 16px; /* iOS zoom fix */
}
.cat-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.cat-chip {
  display: inline-flex;
  align-items: center;
  padding: 7px 11px;
  border-radius: 999px;
  border: 1px solid var(--mk-line, #e2e8f0);
  color: var(--mk-text, #0f172a);
  text-decoration: none;
  font-size: 0.88rem;
  background: #f8fafc;
  line-height: 1.2;
}
.cat-chip.is-active {
  background: #0b2f55;
  border-color: #0b2f55;
  color: #fff;
  font-weight: 700;
}
.cat-select-label {
  display: grid;
  gap: 6px;
  margin-top: 10px;
  font-size: 0.85rem;
  color: var(--mk-muted, #64748b);
}
.cat-reset {
  text-align: center;
  color: var(--mk-blue, #1e5fa8);
  text-decoration: none;
  font-size: 0.9rem;
}
.cat-seo-links {
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid var(--mk-line, #e2e8f0);
}
.cat-seo-links ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.cat-seo-links a { color: var(--mk-blue, #1e5fa8); text-decoration: none; font-size: 0.9rem; }
.catalog-results { min-width: 0; }
.catalog-count { margin: 0 0 16px; color: var(--mk-muted, #64748b); }

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.product-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--mk-line, #e2e8f0);
  border-radius: 16px;
  overflow: hidden;
  min-width: 0;
}
.product-card-media {
  position: relative;
  display: block;
  aspect-ratio: 4 / 3;
  background: #eef3f8;
  overflow: hidden;
}
.product-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.product-card-placeholder {
  display: grid;
  place-items: center;
  height: 100%;
  color: #94a3b8;
  font-size: 0.9rem;
}
.product-badge {
  position: absolute;
  left: 10px;
  top: 10px;
  background: rgba(11, 47, 85, 0.88);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 999px;
}
.product-card-body {
  padding: 14px 16px 16px;
  display: grid;
  gap: 6px;
  flex: 1;
  min-width: 0;
}
.product-brand { margin: 0; font-size: 0.82rem; color: var(--mk-muted, #64748b); }
.product-brand a { color: inherit; text-decoration: none; }
.product-card-body h2,
.product-card-body h3 {
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.3;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.product-card-body h2 a,
.product-card-body h3 a { color: inherit; text-decoration: none; }
.product-card-body h2 a:hover,
.product-card-body h3 a:hover { color: var(--mk-blue, #1e5fa8); }
.product-area { margin: 0; font-size: 0.88rem; color: var(--mk-blue, #1e5fa8); font-weight: 600; }
.product-short {
  margin: 0;
  color: var(--mk-muted, #64748b);
  font-size: 0.9rem;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.product-card-foot {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 10px;
  margin-top: auto;
  padding-top: 10px;
  flex-wrap: wrap;
}
.product-price strong { font-size: 1.1rem; }
.product-price .old {
  display: block;
  color: #94a3b8;
  text-decoration: line-through;
  font-size: 0.85rem;
}
.catalog-empty {
  padding: 36px 24px;
  text-align: center;
  background: #fff;
  border-radius: 16px;
  border: 1px dashed var(--mk-line, #e2e8f0);
}
.catalog-empty h2 { margin: 0 0 8px; }

.catalog-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: center;
  margin: 28px 0 8px;
}
.page-btn {
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  border: 1px solid var(--mk-line, #e2e8f0);
  background: #fff;
  color: #0f172a;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.92rem;
}
.page-btn.is-current {
  background: #0b2f55;
  border-color: #0b2f55;
  color: #fff;
}
.page-ellipsis { color: #94a3b8; padding: 0 4px; }

/* Product page */
.product-page { padding-top: 20px; padding-bottom: 48px; }
.product-page .crumb {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin-bottom: 20px;
  font-size: 0.88rem;
  color: var(--mk-muted, #64748b);
}
.product-page .crumb a {
  color: var(--mk-blue, #1e5fa8);
  text-decoration: none;
}
.product-page .crumb a:hover { text-decoration: underline; }
.crumb-sep { color: #94a3b8; }

/* Top: gallery + buy card */
.product-top {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
  gap: 28px 40px;
  align-items: start;
  margin-bottom: 8px;
}
.product-gallery { position: sticky; top: 88px; min-width: 0; }
.carousel-main {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  background: #eef3f8;
  aspect-ratio: 1 / 1;
  border: 1px solid var(--mk-line, #e2e8f0);
}
.carousel-viewport { position: relative; width: 100%; height: 100%; }
.carousel-slide {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
}
.carousel-slide.is-active { opacity: 1; pointer-events: auto; }
.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #f8fafc;
  display: block;
}
.carousel-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 50%;
  background: rgba(255,255,255,.94);
  box-shadow: 0 6px 18px rgba(15,23,42,.12);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  color: #0f172a;
}
.carousel-nav.prev { left: 10px; }
.carousel-nav.next { right: 10px; }
.carousel-counter {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  background: rgba(15,23,42,.65);
  color: #fff;
  font-size: 0.8rem;
  padding: 4px 8px;
  border-radius: 999px;
}
.carousel-thumbs {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  overflow-x: auto;
  padding-bottom: 4px;
  -webkit-overflow-scrolling: touch;
}
.carousel-thumb {
  flex: 0 0 68px;
  width: 68px;
  height: 68px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  background: #eef3f8;
}
.carousel-thumb.is-active { border-color: #1e5fa8; }
.carousel-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.carousel-empty {
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 20px;
  background: #eef3f8;
  color: #94a3b8;
  border: 1px solid var(--mk-line, #e2e8f0);
}

/* Buy panel */
.product-buy {
  min-width: 0;
  padding: 24px 26px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid var(--mk-line, #e2e8f0);
  box-shadow: 0 10px 32px rgba(15, 23, 42, 0.05);
}
.product-buy .product-brand {
  margin: 0 0 6px;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.product-buy .product-brand a {
  color: var(--mk-blue, #1e5fa8);
  text-decoration: none;
}
.product-title {
  margin: 0 0 14px;
  font-size: clamp(1.35rem, 3.2vw, 1.85rem);
  line-height: 1.22;
  overflow-wrap: anywhere;
  color: #0f172a;
}
.product-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 18px;
}
.product-tag {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 600;
  text-decoration: none;
  background: #eff6ff;
  color: #1e5fa8;
  border: 1px solid #dbeafe;
}
.product-tag-muted {
  background: #f8fafc;
  color: #64748b;
  border-color: #e2e8f0;
}
.product-price-card {
  padding: 16px 18px;
  margin: 0 0 16px;
  border-radius: 14px;
  background: linear-gradient(160deg, #f0f7ff 0%, #f8fafc 100%);
  border: 1px solid #dbeafe;
}
.product-price-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px;
}
.price-now {
  font-size: clamp(1.5rem, 4vw, 1.95rem);
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
}
.price-old {
  color: #94a3b8;
  text-decoration: line-through;
  font-size: 1rem;
}
.price-note {
  margin: 6px 0 0;
  color: var(--mk-muted, #64748b);
  font-size: 0.86rem;
  line-height: 1.4;
}
.product-lead {
  margin: 0 0 18px;
  line-height: 1.55;
  color: #334155;
  font-size: 0.96rem;
}
.product-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}
.product-actions .btn {
  flex: 1 1 auto;
  min-width: min(100%, 150px);
  justify-content: center;
  text-align: center;
}
.product-trust {
  margin: 0;
  padding: 14px 0 0;
  list-style: none;
  display: grid;
  gap: 8px;
  border-top: 1px solid var(--mk-line, #e2e8f0);
  color: #475569;
  font-size: 0.9rem;
}
.product-trust li {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  line-height: 1.4;
}
.product-trust li::before {
  content: "✓";
  flex: 0 0 auto;
  color: #0d9488;
  font-weight: 800;
}
.product-jump {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--mk-line, #e2e8f0);
}
.product-jump a {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--mk-blue, #1e5fa8);
  text-decoration: none;
}
.product-jump a:hover { text-decoration: underline; }

/* Content blocks */
.product-block {
  margin-top: 28px;
  padding: 24px 26px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid var(--mk-line, #e2e8f0);
}
.product-block-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 16px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--mk-line, #e2e8f0);
}
.product-block-head h2 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
}
.product-block-sub {
  margin: 0;
  font-size: 0.88rem;
  color: var(--mk-muted, #64748b);
}

/* Key highlights */
.product-highlights { background: #f8fafc; }
.highlight-grid {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
}
.highlight-card {
  padding: 14px 16px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--mk-line, #e2e8f0);
  display: grid;
  gap: 6px;
}
.highlight-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: .03em;
  text-transform: uppercase;
  color: #64748b;
  line-height: 1.3;
}
.highlight-value {
  font-size: 1.05rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.product-desc-body {
  max-width: 68ch;
  color: #334155;
}
.product-desc-body p {
  margin: 0 0 12px;
  line-height: 1.65;
  font-size: 0.98rem;
}
.product-desc-body p:last-child { margin-bottom: 0; }

.specs-table {
  margin: 0;
  border: 1px solid var(--mk-line, #e2e8f0);
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
}
.specs-row {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 12px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--mk-line, #e2e8f0);
}
.specs-row:nth-child(even) { background: #f8fafc; }
.specs-row:last-child { border-bottom: 0; }
.specs-row dt { margin: 0; color: var(--mk-muted, #64748b); overflow-wrap: anywhere; }
.specs-row dd { margin: 0; font-weight: 600; color: #0f172a; overflow-wrap: anywhere; }

.product-brand-block { background: #f8fafc; }
.brand-about-text {
  margin: 0 0 14px;
  max-width: 68ch;
  line-height: 1.6;
  color: #475569;
}
.brand-about-link {
  font-weight: 700;
  color: var(--mk-blue, #1e5fa8);
  text-decoration: none;
}
.brand-about-link:hover { text-decoration: underline; }

.product-related { padding-bottom: 28px; }
.product-grid-related { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.product-lead-panel { margin-top: 32px; }

/* Legacy aliases kept for list cards */
.product-layout { display: contents; }
.product-info { min-width: 0; }
.product-specs-preview,
.specs-inline-title,
.specs-compact,
.specs-more-btn,
.specs-extra,
.brand-about { display: none; }

@media (max-width: 1100px) {
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .product-grid-related { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  .catalog-layout {
    grid-template-columns: 1fr;
  }
  .cat-filters-toggle { display: flex; }
  .catalog-filters {
    display: none;
    position: static;
    max-height: none;
    margin-bottom: 4px;
  }
  .catalog-filters.is-open { display: block; }
  .product-top { grid-template-columns: 1fr; gap: 20px; }
  .product-gallery { position: static; }
  .product-buy { padding: 20px; }
  .product-block { padding: 20px; }
}

@media (max-width: 560px) {
  .product-grid,
  .product-grid-related { grid-template-columns: 1fr; }
  .specs-row { grid-template-columns: 1fr; gap: 4px; }
  .carousel-nav { width: 36px; height: 36px; font-size: 1.25rem; }
  .product-card-foot { flex-direction: column; align-items: stretch; }
  .product-card-foot .btn { width: 100%; }
  .catalog-pagination .page-btn { min-width: 36px; height: 36px; }
  .highlight-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .product-actions .btn { width: 100%; }
}

@supports not (aspect-ratio: 1) {
  .product-card-media::before,
  .carousel-main::before {
    content: "";
    display: block;
    padding-top: 75%;
  }
  .carousel-main::before { padding-top: 100%; }
  .product-card-media img,
  .carousel-viewport {
    position: absolute;
    inset: 0;
  }
  .product-card-media,
  .carousel-main { position: relative; }
}

.price-montage {
  margin: 10px 0 0;
  font-size: 0.9rem;
  color: #334155;
  line-height: 1.4;
}
.price-montage strong { color: #0f172a; }
