/* Keep the whole authored tattoo movie visible. The already blurred poster
   fills the surrounding field while adjacent fields keep their moving joins. */
html body main [data-cr-legible] .cr-motion-media > picture:not(.cr-visible-ambient) img,
html body main [data-cr-legible] .cr-motion-media > video {
  object-fit: contain !important;
  object-position: 50% 50% !important;
}
html body main [data-cr-legible] .cr-motion-media > picture.cr-visible-ambient { z-index: -1; }
html body main [data-cr-legible] .cr-visible-ambient img { object-fit: cover !important; }
html body main .cr-motion-seam-page [data-cr-legible] .cr-motion-media > picture:not(.cr-visible-ambient),
html body main .cr-motion-seam-page [data-cr-legible] .cr-motion-media > video {
  top: var(--cr-seam-half) !important;
  bottom: auto !important;
  height: calc(100% - 2 * var(--cr-seam-half)) !important;
}
/* The artwork is brighter; a feathered local veil protects only the copy. */
html body main .cr-catalogue-work[data-cr-legible] > .cr-motion-wash {
  background: linear-gradient(90deg,rgba(0,0,0,.42),rgba(0,0,0,.16) 48%,rgba(0,0,0,.03) 82%);
}
html body main .cr-catalogue-work[data-cr-legible] .cr-metadata {
  position: relative;
  isolation: isolate;
}
html body main .cr-catalogue-work[data-cr-legible] .cr-metadata::before {
  content: "";
  position: absolute;
  inset: -10px -16px;
  z-index: -1;
  background: radial-gradient(ellipse at center,rgba(0,0,0,.52),rgba(0,0,0,.28) 58%,rgba(0,0,0,.08) 82%,transparent);
  filter: blur(8px);
  pointer-events: none;
}
@media (max-width:767px) {
  html body main .cr-catalogue-work[data-cr-legible] > .cr-motion-wash {
    background: linear-gradient(180deg,rgba(0,0,0,.16),rgba(0,0,0,.2) 60%,rgba(0,0,0,.3));
  }
}

/* Feather the actual contained film rectangle, not the larger seam overlap.
   The complete image ratio is retained; transparent edges reveal the ambient fill. */
html body main [data-cr-legible] .cr-motion-media > video,
html body main [data-cr-legible] .cr-motion-media > picture:not(.cr-visible-ambient),
html body main .cr-motion-seam-page [data-cr-legible] .cr-motion-media > video,
html body main .cr-motion-seam-page [data-cr-legible] .cr-motion-media > picture:not(.cr-visible-ambient) {
  left:var(--cr-frame-left,0px)!important;right:auto!important;
  top:var(--cr-frame-top,0px)!important;bottom:auto!important;
  width:var(--cr-frame-width,100%)!important;height:var(--cr-frame-height,100%)!important;
  -webkit-mask-image:linear-gradient(90deg,transparent,rgba(0,0,0,.148) 2%,rgba(0,0,0,.852) 4%,#000 6%,#000 94%,rgba(0,0,0,.852) 96%,rgba(0,0,0,.148) 98%,transparent),linear-gradient(180deg,transparent,rgba(0,0,0,.148) 2%,rgba(0,0,0,.852) 4%,#000 6%,#000 94%,rgba(0,0,0,.852) 96%,rgba(0,0,0,.148) 98%,transparent);
  mask-image:linear-gradient(90deg,transparent,rgba(0,0,0,.148) 2%,rgba(0,0,0,.852) 4%,#000 6%,#000 94%,rgba(0,0,0,.852) 96%,rgba(0,0,0,.148) 98%,transparent),linear-gradient(180deg,transparent,rgba(0,0,0,.148) 2%,rgba(0,0,0,.852) 4%,#000 6%,#000 94%,rgba(0,0,0,.852) 96%,rgba(0,0,0,.148) 98%,transparent);
  -webkit-mask-composite:source-in;mask-composite:intersect;
}

/* The moving join is opaque only at the shared scene edge. Its outer band
   must melt back into the native field rather than end as a straight strip.
   Quintic alpha samples match the soft-brush principle of the home reference.
   This changes composition only: no photo or movie pixels are regenerated. */
html body main .cr-motion-seam-page .cr-motion-seam-bottom {
  -webkit-mask-image: linear-gradient(180deg,transparent 0%,rgba(0,0,0,.00856) 7%,rgba(0,0,0,.05792) 14%,rgba(0,0,0,.16308) 21%,rgba(0,0,0,.31744) 28%,rgba(0,0,0,.5) 35%,rgba(0,0,0,.68256) 42%,rgba(0,0,0,.83692) 49%,rgba(0,0,0,.94208) 56%,rgba(0,0,0,.99144) 63%,#000 70%,#000 100%);
  mask-image: linear-gradient(180deg,transparent 0%,rgba(0,0,0,.00856) 7%,rgba(0,0,0,.05792) 14%,rgba(0,0,0,.16308) 21%,rgba(0,0,0,.31744) 28%,rgba(0,0,0,.5) 35%,rgba(0,0,0,.68256) 42%,rgba(0,0,0,.83692) 49%,rgba(0,0,0,.94208) 56%,rgba(0,0,0,.99144) 63%,#000 70%,#000 100%);
}
html body main .cr-motion-seam-page .cr-motion-seam-top {
  -webkit-mask-image: linear-gradient(0deg,transparent 0%,rgba(0,0,0,.00856) 7%,rgba(0,0,0,.05792) 14%,rgba(0,0,0,.16308) 21%,rgba(0,0,0,.31744) 28%,rgba(0,0,0,.5) 35%,rgba(0,0,0,.68256) 42%,rgba(0,0,0,.83692) 49%,rgba(0,0,0,.94208) 56%,rgba(0,0,0,.99144) 63%,#000 70%,#000 100%);
  mask-image: linear-gradient(0deg,transparent 0%,rgba(0,0,0,.00856) 7%,rgba(0,0,0,.05792) 14%,rgba(0,0,0,.16308) 21%,rgba(0,0,0,.31744) 28%,rgba(0,0,0,.5) 35%,rgba(0,0,0,.68256) 42%,rgba(0,0,0,.83692) 49%,rgba(0,0,0,.94208) 56%,rgba(0,0,0,.99144) 63%,#000 70%,#000 100%);
}

/* Native veils differ between the intro and artwork fields. Fade only their
   join-facing edges to transparent so the same shared pixels cannot acquire
   two different tints at the scene boundary. Editorial cores stay unchanged. */
html body main .cr-motion-seam-page .cr-motion-wash {
  --cr-wash-top: linear-gradient(180deg,transparent,rgba(0,0,0,.05792) calc(var(--cr-seam-half)*.14),rgba(0,0,0,.31744) calc(var(--cr-seam-half)*.28),rgba(0,0,0,.68256) calc(var(--cr-seam-half)*.42),rgba(0,0,0,.94208) calc(var(--cr-seam-half)*.56),#000 calc(var(--cr-seam-half)*.7),#000);
  --cr-wash-bottom: linear-gradient(0deg,transparent,rgba(0,0,0,.05792) calc(var(--cr-seam-half)*.14),rgba(0,0,0,.31744) calc(var(--cr-seam-half)*.28),rgba(0,0,0,.68256) calc(var(--cr-seam-half)*.42),rgba(0,0,0,.94208) calc(var(--cr-seam-half)*.56),#000 calc(var(--cr-seam-half)*.7),#000);
  -webkit-mask-image: var(--cr-wash-top),var(--cr-wash-bottom);
  mask-image: var(--cr-wash-top),var(--cr-wash-bottom);
  -webkit-mask-composite: source-in;
  mask-composite: intersect;
}
html body main .cr-motion-seam-page [data-cr-motion-work="cover"] > .cr-motion-wash {
  -webkit-mask-image: var(--cr-wash-bottom);
  mask-image: var(--cr-wash-bottom);
}
html body main .cr-motion-seam-page [data-cr-motion-work="cr-012"] > .cr-motion-wash {
  -webkit-mask-image: var(--cr-wash-top);
  mask-image: var(--cr-wash-top);
}

/* The long transition is independent of the native player/ambient overscan.
   Preserve each accepted contained design and its existing background framing. */
html body main .cr-motion-seam-page .cr-motion-media {
  top:calc(-1 * var(--cr-native-half,198px));
  bottom:calc(-1 * var(--cr-native-half,198px));
}

/* Finish the catalogue at the shared footer's black without dimming the copy.
   The last scene alone gets a soft tail; media geometry and joins stay intact. */
html body main .cr-motion-seam-page .cr-catalogue > #cr-012[data-cr-legible]:last-child::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: clamp(200px, 34vh, 380px);
  height: clamp(200px, 34svh, 380px);
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(to bottom,
    transparent 0%, rgba(0,0,0,.02) 10%, rgba(0,0,0,.10) 20%,
    rgba(0,0,0,.24) 30%, rgba(0,0,0,.43) 40%, rgba(0,0,0,.62) 50%,
    rgba(0,0,0,.79) 60%, rgba(0,0,0,.91) 70%, rgba(0,0,0,.98) 83%, #000 96%, #000 100%);
}

/* Continue the existing artwork overscan into the empty head of the footer.
   Dissolve the artwork itself into black before the clip's fractional edge. */
@supports (clip-path: inset(0px 0px -1px 0px)) and (mask-image: linear-gradient(#000, transparent)) {
  html body main .cr-motion-seam-page:has(.cr-catalogue > #cr-012[data-cr-legible]:last-child) {
    --cr-footer-bleed: clamp(48px, 7.5svh, 80px);
    overflow: visible;
  }
  html body main .cr-motion-seam-page .cr-catalogue > #cr-012[data-cr-legible]:last-child {
    overflow: visible;
    background: #000;
    clip-path: inset(0 0 calc(-1 * var(--cr-footer-bleed)) 0);
  }
  html body main .cr-motion-seam-page .cr-catalogue > #cr-012[data-cr-legible]:last-child > .cr-motion-wash {
    bottom: calc(-1 * var(--cr-footer-bleed));
  }
  html body main .cr-motion-seam-page .cr-catalogue > #cr-012[data-cr-legible]:last-child::after {
    content: none;
  }
  html body main .cr-motion-seam-page .cr-catalogue > #cr-012[data-cr-legible]:last-child > .cr-motion-media {
    --cr-close-start: calc(100% - var(--cr-native-half, 198px) - clamp(220px, 34svh, 350px));
    --cr-close-span: calc(clamp(220px, 34svh, 350px) + var(--cr-footer-bleed) - 8px);
    --cr-close-mask: linear-gradient(to bottom,
      #000 calc(var(--cr-close-start) + var(--cr-close-span)*.08),
      rgba(0,0,0,.956) calc(var(--cr-close-start) + var(--cr-close-span)*.20),
      rgba(0,0,0,.868) calc(var(--cr-close-start) + var(--cr-close-span)*.30),
      rgba(0,0,0,.734) calc(var(--cr-close-start) + var(--cr-close-span)*.40),
      rgba(0,0,0,.565) calc(var(--cr-close-start) + var(--cr-close-span)*.50),
      rgba(0,0,0,.388) calc(var(--cr-close-start) + var(--cr-close-span)*.60),
      rgba(0,0,0,.223) calc(var(--cr-close-start) + var(--cr-close-span)*.70),
      rgba(0,0,0,.091) calc(var(--cr-close-start) + var(--cr-close-span)*.80),
      rgba(0,0,0,.016) calc(var(--cr-close-start) + var(--cr-close-span)*.90),
      transparent calc(var(--cr-close-start) + var(--cr-close-span)));
    -webkit-mask-image: var(--cr-close-mask);
    mask-image: var(--cr-close-mask);
  }
}

/* Catalogue IDs are a white index, not the inherited warm text or hover tint. */
html body main .cr-motion-page .cr-metadata :is(h1[translate="no"],h2[translate="no"],h2[translate="no"] > a[href]) {
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  opacity: 1 !important;
}

@media (max-width:767px) {
  /* Give the entire portrait its own full-width field before the text. The
     ambient layer still crosses the seam; the native plate is never cropped. */
  html body main .cr-motion-seam-page .cr-catalogue > [data-cr-legible] {
    --cr-phone-art-top: clamp(34px, 6.5svh, 60px);
    --cr-phone-art-height: min(177.7778vw, 85svh);
    align-items: flex-start;
  }
  html body main .cr-motion-seam-page .cr-catalogue > [data-cr-legible] .cr-motion-media > :is(video,picture:not(.cr-visible-ambient)) {
    top: calc(var(--cr-native-half, 198px) + var(--cr-phone-art-top)) !important;
    left: 0 !important;
    width: 100% !important;
    height: var(--cr-phone-art-height) !important;
  }
  html body main .cr-motion-seam-page .cr-catalogue > [data-cr-legible] > .cr-motion-content {
    width: 100%;
    margin: 0 auto;
    padding: calc(var(--cr-phone-art-top) + var(--cr-phone-art-height) + 14px)
             max(clamp(20px, 6vw, 38px), env(safe-area-inset-right))
             clamp(58px, 9svh, 86px)
             max(clamp(20px, 6vw, 38px), env(safe-area-inset-left));
  }
  html body main .cr-motion-seam-page .cr-catalogue > [data-cr-legible] > .cr-motion-wash {
    --cr-phone-copy-start: calc(var(--cr-phone-art-top) + var(--cr-phone-art-height));
    background: linear-gradient(to bottom, transparent calc(var(--cr-phone-copy-start) - 100px),
      rgba(0,0,0,.58) var(--cr-phone-copy-start),
      rgba(0,0,0,.91) calc(var(--cr-phone-copy-start) + 65px),
      rgba(0,0,0,.93) calc(100% - 68px), rgba(0,0,0,.7) 100%);
  }
  html body main .cr-motion-seam-page .cr-catalogue .cr-metadata {
    max-width: min(42ch, 100%);
    margin-inline: auto !important;
  }
  html body main .cr-motion-seam-page .cr-catalogue .cr-metadata::before {
    /* A single full-page gradient covers text; avoid per-record filter blur. */
    content: none;
  }
  html body main .cr-motion-seam-page .cr-catalogue .cr-metadata :is(p,.cr-description) {
    margin-bottom: 12px;
  }
  html body main .cr-motion-seam-page .cr-catalogue .cr-metadata .cr-subtitle {
    margin-bottom: 18px !important;
  }
  html body main .cr-motion-seam-page .cr-catalogue .cr-metadata .cr-description {
    margin-top: 18px !important;
  }
  html body main .cr-motion-seam-page .cr-catalogue > #cr-012[data-cr-legible]:last-child > .cr-motion-wash {
    /* The accepted closing mask still fades the ambient overscan into black. */
    background-color: #0000;
  }
}


/* A brief forward-looking note, in the established cover's serif typography. */
html body main .cr-motion-intro .cr-series-framework {
  max-width: 39em;
  margin: clamp(24px, 4svh, 40px) auto 0;
}
