/* Production-only corrections. The original visual system remains authoritative. */
html,
body { overflow-x: clip; }
img, video, svg { max-width: 100%; }
img { height: auto; }
button, a, input, select, textarea { touch-action: manipulation; }
.button, .header-cta, .cart-link, .mobile-menu-toggle, .catalog-tool-btn,
.product-card-add, .product-qty-btn, .checkout-submit { min-height: 44px; }
input, select, textarea { font-size: max(16px, 1em); }
.product-card h3, .product-title, .cart-item-title, .checkout-line strong {
  overflow-wrap: anywhere;
}

@media (max-width: 768px) {
  :root {
    --site-header-top: 8px;
    --site-header-space: 18px;
  }
  .section { scroll-margin-top: var(--site-header-offset); }
  .hero-visual, .hero-showcase, .showcase-media { min-width: 0; }
  .catalog-layout, .catalog-results, .cart-layout, .checkout-layout { min-width: 0; }
  .catalog-toolbar, .hero-actions { align-items: stretch; }
  .hero-actions .button, .checkout-submit { width: 100%; }
  .product-card-image, .category-product, .featured-product-card img {
    object-fit: cover;
  }
}

@media (max-width: 390px) {
  .site-header { max-width: calc(100vw - 16px); }
  .catalog-toolbar-actions { width: 100%; }
  .catalog-tool-btn { flex: 1 1 auto; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Targeted visual repairs shared with the Prokub geometry. */
.section { scroll-margin-top: calc(var(--site-header-offset, 112px) + 12px); }
.catalog-controls { position: relative; top: auto; }
.intro-grid--story h2 { font-size: clamp(2.15rem, 4vw, 3.2rem); line-height: 1.05; }
@media (min-width: 981px) {
  .intro-grid--story {
    grid-template-columns: minmax(280px, .72fr) minmax(0, 1.45fr);
    align-items: start;
    gap: clamp(34px, 5vw, 72px);
  }
  .intro-grid--story .section-heading { grid-column: auto; margin: 0; }
  .intro-grid--story .about-story { max-width: none; }
}
.about-story { box-sizing: border-box; width: 100%; }
.catalog-controls { margin-bottom: 16px; padding: 10px 12px; border-radius: 18px; }
.catalog-toolbar--minimal { display: flex; align-items: center; gap: 10px; }
.catalog-search-minimal { flex: 1 1 auto; display: flex; align-items: center; gap: 10px; min-width: 0; min-height: 44px; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); }
.catalog-search-minimal input { flex: 1; min-width: 0; height: 40px; padding: 0; border: 0; background: transparent; box-shadow: none; outline: none; }
.catalog-toolbar-actions { display: flex; flex-shrink: 0; gap: 8px; }
.catalog-tool-btn { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0; border: 1px solid var(--line); border-radius: 50%; color: var(--text); background: var(--surface-muted); cursor: pointer; }
.catalog-tool-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.catalog-sort-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.catalog-freshness {
  width: fit-content;
  margin: -6px 0 14px;
  padding: 7px 11px;
  border-radius: 999px;
  color: #1e5a38;
  background: #e8f7ee;
  font-size: .78rem;
  font-weight: 700;
}
.catalog-freshness.is-stale { color: #8a3d16; background: #fff1e8; }
.product-price-freshness {
  margin: 2px 0 0;
  color: #1e5a38;
  font-size: .76rem;
  font-weight: 700;
  line-height: 1.4;
}
.product-price-freshness.is-stale { color: #8a3d16; }

.catalog-sidebar-wrap,
.cart-summary-wrap { align-self: stretch; }
.cart-layout { grid-template-areas: "main summary"; }
.cart-layout .cart-main { grid-area: main; min-width: 0; }
.cart-layout .cart-summary-wrap { grid-area: summary; min-width: 0; }
.catalog-sidebar { position: sticky; top: calc(var(--site-header-offset, 128px) + 8px); }
.cart-summary:not([hidden]) { position: sticky; top: calc(var(--site-header-offset, 112px) + 12px); }

.product-card-cart-control { margin-top: auto; padding: 0 14px 14px; }
.product-card-cart-control .product-card-add { width: 100%; min-height: 42px; }
.product-card-stepper { display: flex; align-items: center; gap: 4px; width: 100%; padding: 4px; }
.product-card-stepper .product-qty-display { flex: 1; min-width: 0; width: auto; }
.catalog-page .product-card-media { order: 1; position: relative; flex-shrink: 0; overflow: hidden; width: 100%; height: 188px; background: #eef1f5; }
.catalog-page .product-card-media .product-card-image { width: 100%; height: 100%; padding: 0; object-fit: cover; object-position: center; }
.product-card-head { padding: 14px 16px 8px; }
.product-card-info { padding: 0 62px 14px 16px; }

.cart-item .product-qty-stepper {
  display: inline-grid;
  grid-template-columns: 38px minmax(72px, auto) 38px;
  gap: 4px;
  padding: 4px;
  border: 1px solid rgba(37, 99, 235, .14);
  border-radius: 14px;
  background: var(--steel-soft);
}
.cart-item .product-qty-btn {
  width: 38px;
  height: 38px;
  min-height: 38px;
  border: 1px solid rgba(37, 99, 235, .18);
  border-radius: 10px;
  color: var(--steel);
  background: var(--surface);
  box-shadow: 0 4px 12px rgba(37, 99, 235, .08);
}
.cart-item .product-qty-btn:hover,
.cart-item .product-qty-btn:focus-visible {
  color: #fff;
  border-color: var(--steel);
  background: var(--steel);
  outline: none;
}
.cart-page .cart-item-remove {
  display: inline-grid;
  place-items: center;
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  min-width: 38px;
  min-height: 38px;
  padding: 0;
  border: 1px solid rgba(180, 35, 24, .14);
  border-radius: 50%;
  color: #9f2d24;
  background: rgba(180, 35, 24, .05);
}
.cart-page .cart-item-remove:hover,
.cart-page .cart-item-remove:focus-visible {
  color: #fff;
  border-color: #b42318;
  background: #b42318;
  outline: none;
}
.cart-summary #cartCheckout {
  min-height: 50px;
  box-shadow: 0 12px 26px rgba(37, 99, 235, .22);
}
.cart-summary #cartCheckout:hover { transform: translateY(-1px); }

.conversion-cta {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 900;
  display: grid;
  gap: 10px;
  width: min(360px, calc(100vw - 32px));
  padding: 22px;
  border: 1px solid rgba(37, 99, 235, .24);
  border-radius: 20px;
  color: var(--text);
  background: rgba(255, 255, 255, .97);
  box-shadow: var(--shadow-strong);
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .25s ease, transform .25s ease;
}
.conversion-cta[hidden] { display: none; }
.conversion-cta.is-visible { opacity: 1; transform: translateY(0); }
.conversion-cta > strong { padding-right: 30px; font-size: 1.15rem; }
.conversion-cta > span { color: var(--muted); line-height: 1.5; }
.conversion-cta .button { width: 100%; justify-content: center; }
.conversion-cta-close {
  position: absolute;
  top: 10px;
  right: 10px;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: var(--muted);
  background: var(--surface-muted);
  font-size: 1.35rem;
  cursor: pointer;
}
.conversion-cta-close:hover,
.conversion-cta-close:focus-visible { color: #fff; background: var(--steel); outline: none; }

.cart-layout:has(#cartEmpty:not([hidden])) { display: block; max-width: 720px; }
.cart-empty { padding: 32px 26px; }
.cart-empty h2 { font-size: clamp(1.7rem, 4vw, 2.3rem); }

.footer-panel { grid-template-columns: minmax(280px, .9fr) minmax(0, 1.4fr); }
.footer-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; }
.footer-grid .footer-col { min-width: 0; }

@media (max-width: 980px) {
  .catalog-hero { margin-bottom: 18px; }
  .intro-grid--story { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .intro-grid--story .section-heading { margin-bottom: 0; }
  .about-story { padding: 24px 22px; }
  .catalog-sidebar { position: fixed; top: auto; }
  .cart-summary:not([hidden]) { position: static; }
  .cart-layout { grid-template-areas: "main" "summary"; }
  .cart-layout .cart-main { grid-area: main; }
  .cart-layout .cart-summary-wrap { grid-area: summary; }
}

@media (min-width: 360px) and (max-width: 768px) {
  .product-card-head { padding: 14px 15px 8px; }
  .product-card-info { padding: 0 50px 14px 15px; }
  .product-card-cart-control { padding: 0 14px 14px; }
  .product-card h3 { font-size: clamp(.8rem, 2.8vw, .96rem); line-height: 1.35; }
}

@media (max-width: 720px) {
  .cart-empty { padding: 26px 18px; }
  .cart-empty .button { min-width: 0; width: 100%; }
  .footer-panel { display: block; padding: 0; }
  .footer-brand, .footer-col { padding: 22px; }
  .footer-grid { grid-template-columns: 1fr; gap: 0; }
  .footer-col { border-left: 0; border-top: 1px solid var(--line); }
  .cookie-banner-inner { flex-direction: row; align-items: center; gap: 10px; padding: 10px 12px; }
  .cookie-banner-text { font-size: .75rem; line-height: 1.35; }
  .cookie-banner-accept { width: auto; height: 44px; min-width: 92px; padding-inline: 12px; }
  .conversion-cta {
    right: calc(10px + env(safe-area-inset-right));
    bottom: calc(10px + env(safe-area-inset-bottom));
    left: calc(10px + env(safe-area-inset-left));
    width: auto;
    padding: 16px;
  }
  .conversion-cta > span { font-size: .86rem; }
  .conversion-cta-close { width: 40px; height: 40px; }
}

/* Keep the final footer and conversion controls identical across both brands. */
.conversion-cta-close {
  width: 44px;
  min-width: 44px;
  height: 44px;
  min-height: 44px;
  padding: 0;
  border-radius: 50%;
  aspect-ratio: 1;
}

@media (max-width: 768px) {
  .footer-panel {
    display: grid;
    grid-template-columns: 1fr !important;
    gap: 22px;
    padding: 22px 18px;
  }

  .footer-brand,
  .footer-col {
    padding: 0;
  }

  .footer-grid,
  .site-footer.footer--compact .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .footer-col {
    border: 0;
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 12px !important;
  }
}

@media (max-width: 359px) {
  .footer-grid,
  .site-footer.footer--compact .footer-grid,
  .product-grid {
    grid-template-columns: 1fr;
  }
}

/* Strict shared production geometry: catalog, filters, footer and consent. */
.footer-brand .brand-mark img {
  display: block;
  width: 48px;
  height: 48px;
  object-fit: contain;
}

.lead-form .consent-checkbox {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  align-items: start;
  gap: 12px;
  padding: 14px;
}

.lead-form .consent-checkbox input[type="checkbox"] {
  width: 22px;
  height: 22px;
  min-height: 22px;
  margin: 2px 0 0;
  padding: 0;
}

.lead-form .consent-checkbox span {
  min-width: 0;
  text-align: left;
}

@media (max-width: 980px) {
  .catalog-hero {
    min-height: 0;
    margin: 0 0 8px;
    padding: 14px 0 6px;
  }

  .catalog-hero h1 {
    margin: 0;
    font-size: clamp(2rem, 10vw, 2.65rem);
    line-height: 1;
  }

  .catalog-section {
    padding-top: 8px !important;
  }

  .catalog-controls {
    margin-top: 0;
  }

  .catalog-tool-btn.catalog-filter-toggle {
    position: relative;
  }

  .catalog-filter-count {
    position: absolute;
    top: -7px;
    right: -7px;
    z-index: 2;
  }

  .catalog-sidebar {
    position: fixed !important;
    inset: 0 !important;
    z-index: 1500;
    display: grid !important;
    grid-template-rows: auto minmax(0, 1fr) auto;
    width: 100vw !important;
    height: 100dvh !important;
    max-width: none !important;
    max-height: none !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    opacity: 0;
    visibility: hidden;
    transform: translateY(100%) !important;
    overflow: hidden;
  }

  .catalog-sidebar.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) !important;
  }

  #sidebarFilters {
    max-height: none !important;
    overflow-y: auto;
    overscroll-behavior: contain;
  }

  .catalog-page .product-card-media {
    position: relative;
    height: 188px !important;
    padding: 0 !important;
    overflow: hidden;
  }

  .catalog-page .product-card-media .product-card-image {
    position: absolute;
    inset: 0;
    display: block;
    width: 100% !important;
    height: 100% !important;
    padding: 0 !important;
    object-fit: cover !important;
    object-position: center;
  }

  .footer-nav {
    grid-template-columns: 1fr !important;
    gap: 10px !important;
  }

  .footer-nav a,
  .footer-contacts a,
  .footer-contacts span {
    line-height: 1.35;
    overflow-wrap: anywhere;
  }

  .footer-bottom-copy {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    align-items: center;
  }

  .footer-bottom-copy p {
    margin: 0;
  }

  .product-detail {
    padding-top: 0 !important;
  }

  .product-gallery {
    height: clamp(280px, 82vw, 360px) !important;
    min-height: 0 !important;
    max-height: none !important;
    padding: 0 !important;
    overflow: hidden;
  }

  .product-detail-media {
    position: absolute;
    inset: 0;
  }

  .product-gallery img {
    position: absolute;
    inset: 0;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
  }

  .product-gallery-badge {
    display: none !important;
  }
}
