/* Let the paper and the page content bracket the fixed ink layer. */
body { isolation: isolate; }

body::after {
  content: "";
  pointer-events: none;
  left: 50%;
  width: max(128vw, 59svh);
  aspect-ratio: 94 / 43;
  background: linear-gradient(116deg, transparent 5%, var(--forest) 36%, var(--forest) 65%, transparent 96%);
  -webkit-mask: url("/assets/images/logo.png") center / contain no-repeat;
  mask: url("/assets/images/logo.png") center / contain no-repeat;
  opacity: .07;
}

body::after {
  position: fixed;
  z-index: -1;
  top: 50%;
  transform: translate3d(-50%, calc(-50% + var(--watermark-offset, 0px)), 0) rotate(-3deg);
}

main :is(.brand-watermark, .product-story.brand-watermark)::after { content: none; }

:is(.board-catalogue, .related-shapes, .product-gallery-shell, .product-gallery, .size-chart-section) {
  background-color: transparent;
}

@supports (animation-timeline: scroll(root block)) and (animation-range: 0px 90svh) {
  @media (prefers-reduced-motion: no-preference) {
    body::after {
      animation: page-watermark-parallax linear both;
      animation-timeline: scroll(root block);
      animation-range: 0px 90svh;
    }
  }
}

@keyframes page-watermark-parallax {
  from { transform: translate3d(-50%, calc(-50% + 2.7svh), 0) rotate(-3deg); }
  to { transform: translate3d(-50%, calc(-50% - 2.8svh), 0) rotate(-3deg); }
}

@media (prefers-reduced-motion: reduce) {
  body::after {
    transform: translate3d(-50%, -50%, 0) rotate(-3deg);
  }
}

@media print, (forced-colors: active) {
  body::after {
    display: none;
  }
}
