/* PRANATARA card identity-strip clearance and transparency v003 — chat-200.
 *
 * v001 was rejected because its generic material selector lost the inherited
 * !important cascade. v002 corrected the normal gallery, featured-card, and
 * modal surfaces, but browser QA found that Windows forced-colors adds a
 * three-pixel double border to the non-Relic card shell. This accepted
 * successor compensates only that accessibility geometry while preserving the
 * normal rendering, Relic geometry, hero, modal, NFT media, metadata, special
 * raster serial plates, and .frame-signature ability panel.
 */

/* Gallery geometry. The explicit 8px CSS clearance renders at about 9px after
 * the inherited one-pixel frame boundary is included. */
body[data-card-identity-strip="spaced-transparent-v003"][data-reference-portrait-fidelity="v003"]
  #grid
  > article.holo-card:not([data-rarity="Relic"])
  > .protected-media
  > .preview-mark {
  left: calc(20.4cqw + 8px) !important;
}

body[data-card-identity-strip="spaced-transparent-v003"][data-relic-literal-frame="full-frame-v006"][data-relic-frame-boundary="source-canvas-v001"]
  #grid
  > article.holo-card[data-rarity="Relic"]
  > .protected-media
  > .preview-mark {
  left: calc(22.7097906cqw + 8px) !important;
}

/* Featured C001 uses the full literal-frame coordinate space. */
body[data-card-identity-strip="spaced-transparent-v003"][data-relic-literal-frame="full-frame-v006"][data-relic-frame-boundary="source-canvas-v001"]
  #museumFeature
  > .museum-feature-image.reference-feature-card[data-rarity="Relic"]
  > .museum-feature-watermark {
  left: calc(26.4397906cqw + 8px) !important;
}

/* Surface-specific selectors deliberately include the owning IDs. Older
 * theme layers use !important plus #grid, so a generic final selector is not
 * sufficient even when its stylesheet loads last. */
body[data-card-identity-strip="spaced-transparent-v003"]
  #grid
  > article.holo-card
  > .protected-media
  > .preview-mark,
body[data-card-identity-strip="spaced-transparent-v003"]
  #museumFeature
  > .museum-feature-image.reference-feature-card
  > .museum-feature-watermark,
body[data-card-identity-strip="spaced-transparent-v003"]
  #cardDialog
  .collectible-card.holo-card
  > .collectible-art.protected-media
  > .preview-mark {
  background: transparent !important;
  border-color: transparent !important;
  box-shadow: none !important;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
  color: rgba(238, 226, 200, .88) !important;
  text-shadow: 0 1px 1px rgba(0, 0, 0, .92), 0 0 2px rgba(0, 0, 0, .62) !important;
}

@media (prefers-reduced-motion: reduce) {
  body[data-card-identity-strip="spaced-transparent-v003"] #grid .preview-mark,
  body[data-card-identity-strip="spaced-transparent-v003"] #museumFeature .museum-feature-watermark,
  body[data-card-identity-strip="spaced-transparent-v003"] #cardDialog .preview-mark {
    transition: none !important;
  }
}

/* In forced-colour mode a transparent overlay can erase attribution. Restore
 * a system-colour panel only for that accessibility mode. */
@media (forced-colors: active) {
  body[data-card-identity-strip="spaced-transparent-v003"]
    #grid
    > article.holo-card
    > .protected-media
    > .preview-mark,
  body[data-card-identity-strip="spaced-transparent-v003"]
    #museumFeature
    > .museum-feature-image.reference-feature-card
    > .museum-feature-watermark,
  body[data-card-identity-strip="spaced-transparent-v003"]
    #cardDialog
    .collectible-card.holo-card
    > .collectible-art.protected-media
    > .preview-mark {
    background: Canvas !important;
    border-color: CanvasText !important;
    color: CanvasText !important;
    box-shadow: none !important;
    text-shadow: none !important;
    forced-color-adjust: none;
  }

  /* The forced-colors shell uses a 3px double border instead of the normal
   * boundary. Move only non-Relic gallery strips by the same 3px so their
   * rendered clearance remains about 9px. */
  body[data-card-identity-strip="spaced-transparent-v003"][data-reference-portrait-fidelity="v003"]
    #grid
    > article.holo-card:not([data-rarity="Relic"])
    > .protected-media
    > .preview-mark {
    left: calc(20.4cqw + 11px) !important;
  }
}
