/* Предметные фото сохраняют полный кадр на всех ширинах. */
.product-visual { background: #080808; }
.product-image, .custom-image { height: auto; aspect-ratio: 3 / 2; object-fit: contain; }
.product-visual:hover .product-image { transform: none; }
.custom-image { align-self: center; mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent); }

/* Тонкая фактура остается под текстом и не меняет его контраст. */
body { background-image: linear-gradient(#080808df, #080808df), url('../../images/chernyy_gofrokarton_tekstura.webp'); background-size: auto, 627px 627px; }
.section-dark { background: #0d0d0de8; }
.custom.section-dark { background: #080808; }
.hero { background: #080808; }
.hero-inner { min-height: 800px; padding-top: 66px; }
.hero-copy { width: 51%; max-width: 680px; }
.hero h1 { font-size: clamp(54px, 4.8vw, 72px); }
.hero-description { max-width: 520px; }
.hero-art { inset: 0; right: 0; bottom: 0; display: flex; align-items: center; width: 100%; max-width: 1560px; margin: auto; opacity: 1; mask-image: none; }
.hero-art picture { display: block; width: 100%; }
.hero-art img { position: static; display: block; width: 100%; max-width: 100%; height: auto; max-height: 800px; margin: auto; object-fit: contain; filter: none; }
.hero-facts { width: 100%; }

/* Декор движется только в пределах секции и не принимает нажатия. */
.custom, .advantages, .industries, .process { position: relative; isolation: isolate; overflow: clip; }
.ambient-art { position: absolute; z-index: -1; width: clamp(200px, 24vw, 380px); top: 15%; pointer-events: none; opacity: .085; transform: translate3d(0, var(--parallax-y, 0px), 0); }
.ambient-art img { width: 100%; transform: rotate(-18deg); }
.ambient-left { left: -7%; }
.ambient-right { right: -7%; }
.ambient-right img { transform: rotate(16deg); }
.custom .ambient-art { top: 68%; opacity: .06; }
.process .ambient-art { top: 2%; }

/* На страницах каталога у каждого направления свое изображение. */
.detail-hero-grid { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 24px; }
.detail-hero-grid > div { min-width: 0; }
.detail-hero h1 { font-size: clamp(38px, 3.8vw, 58px); }
.detail-product-image { width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: contain; mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent); }

/* Растушевка только свободных полей, без обрезки силуэта товара. */
.hero-art img, .product-image, .custom-image, .detail-product-image {
  mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent), linear-gradient(180deg, transparent, #000 7%, #000 93%, transparent);
  mask-composite: intersect;
}

@media (max-width: 1099px) {
  .hero-inner { min-height: 0; padding-top: 48px; padding-bottom: 40px; }
  .hero-copy { width: 100%; max-width: 760px; }
  .hero h1 { font-size: clamp(48px, 7vw, 68px); }
  .hero-description { max-width: 600px; }
  .hero-art { position: relative; inset: auto; z-index: 0; display: block; flex: 0 0 auto; width: 100%; height: auto; max-width: 800px; margin: 8px auto 0; overflow: visible; }
  .hero-art img { position: static; inset: auto; width: 100%; height: auto; max-height: none; max-width: 100%; }
  .hero-facts { margin-top: 12px; }
  .detail-hero-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .detail-product-image { max-width: 800px; margin: auto; }
}
@media (max-width: 767px) {
  .hero-inner { padding-top: 36px; padding-bottom: 36px; }
  .hero h1 { font-size: clamp(38px, 10.5vw, 58px); }
  .hero-art { width: calc(100% + 32px); max-width: none; margin: 12px -16px 0; }
  .hero-facts { margin-top: 8px; }
  .custom-image { aspect-ratio: 3 / 2; }
  .ambient-art { width: 180px; opacity: .055; }
  .ambient-left { left: -95px; }
  .ambient-right { right: -95px; }
  .detail-hero h1 { font-size: clamp(36px, 9.5vw, 52px); }
}
@media (prefers-reduced-motion: reduce) { .ambient-art { transform: none; } }
