/* Keep the full article page wide and the dialog compact. */
body[data-page] .piece-page {width:min(100%,78rem);max-width:78rem;}
body[data-page] #detail:has(.piece-sheet) {
  width:min(48rem,calc(100vw - 24px));
  max-height:min(78vh,calc(100dvh - 32px));
  padding:0;
  overscroll-behavior:contain;
}
body[data-page] #detail:has(.piece-sheet) > .close {
  position:sticky;
  display:block;
  top:0;
  z-index:5;
  margin-inline:auto 0;
  background-color:#171616;
}
body .piece-sheet {
  --felt-frame:url('/images/cadre-collection-smuggler.svg');
  position:relative;isolation:isolate;container-type:inline-size;
  min-width:0;width:100%;margin-inline:auto;padding:clamp(12px,2.2vw,32px);
  background:#171616;color:#fff8f0;
}
.piece-sheet::before, .piece-provenance::before {
  content:"";position:absolute;inset:0;z-index:-1;pointer-events:none;
  background-repeat:no-repeat;filter:grayscale(1);mix-blend-mode:screen;
}
.piece-sheet::before {
  background-image:var(--piece-outline);background-position:center;
  background-size:cover;opacity:.48;
}
body .piece-sheet .piece-marker {
  display:inline-block;box-sizing:border-box;max-width:100%;padding:.23em .62em .27em;
  background:transparent url('/images/feutres-bordes.svg') center var(--piece-ink-row,0%) / 100% 3000% no-repeat;
}
body .piece-sheet .piece-name {text-align:center;margin:0 auto clamp(14px,2.3vw,30px);}
body .piece-sheet .piece-title-separator {font-size:.75em;}
body .piece-sheet .product-detail {width:100%;}
body .piece-sheet .piece-copy {width:100%;max-width:none;align-self:center;}
body .piece-sheet .piece-notes {
  width:100%;max-width:none;margin:clamp(20px,3vw,40px) 0 0;padding:0;border:0;
}
body .piece-sheet .piece-notes::after {
  inset:0 0 auto;width:100%;height:9px;background:transparent url('/images/trait-marqueur-rouge.svg') center / 100% 100% no-repeat;
  mask:none;clip-path:none;
}
.piece-sheet .piece-provenance {
  --piece-ink-row:34.48%;position:relative;isolation:isolate;
  padding:clamp(25px,3vw,42px) clamp(8px,2.3vw,32px) clamp(18px,2.3vw,32px);
}
.piece-provenance::before {
  background-image:var(--piece-second);background-position:var(--piece-side) center;
  background-size:contain;opacity:.21;
}
body .piece-sheet .piece-notes h3 {margin:0 0 .55em;text-align:center;}
body .piece-sheet .piece-provenance p {
  width:100%;max-width:none;margin:.65em 0;text-align:start;text-wrap:pretty;
}
.piece-sheet .piece-question {
  --piece-ink-row:68.97%;position:relative;isolation:isolate;
  padding:clamp(32px,5vw,66px) clamp(16px,6vw,78px);color:#1a1717;
}
.piece-question::before {
  content:"";position:absolute;z-index:-1;inset:0;pointer-events:none;
  background:#e6dfd2 url('/images/papier-ivoire.webp') center / cover;
  mask:url('/images/papier-perfore-decoupe.svg') center / 100% 100% no-repeat;
}
body .piece-sheet .write-me {display:flex;align-items:center;justify-content:center;gap:clamp(3px,1.3vw,20px);}
body .piece-sheet .write-me .piece-bomb {
  flex:0 0 auto;width:clamp(31px,6vw,78px);height:auto;max-height:none;margin:0;
  background:none;border:0;box-shadow:none;
}
.piece-bomb:first-child {transform:scaleX(-1);}
body .piece-sheet .inquiry {
  max-width:36rem;width:100%;margin:0 auto;display:grid;
  grid-template-columns:minmax(0,1fr);gap:1.05rem;
}
.piece-sheet .inquiry label {display:grid;align-content:start;gap:.3rem;min-width:0;}
body .piece-sheet .inquiry-label,.piece-sheet .inquiry-send,.piece-sheet .inquiry :is(input:not([type=hidden]),textarea) {
  border:5px solid #a71528;border-image:var(--felt-frame) 11 15 / 5px 7px stretch;
  border-radius:0;background:#171415;color:white;
}
body .piece-sheet .inquiry-label {width:fit-content;max-width:100%;padding:.12em .55em;}
body .piece-sheet .inquiry :is(input:not([type=hidden]),textarea) {
  width:100%;padding:.6em .8em;min-height:46px;
  font:400 1rem/1.5 system-ui,sans-serif;color:white;box-shadow:none;
}
body .piece-sheet .inquiry textarea {min-height:8em;resize:vertical;}
.piece-sheet .inquiry textarea::placeholder {color:#ded5cd;opacity:1;}
body .piece-sheet .inquiry-send {
  justify-self:center;margin:.25rem 0 0;padding:.2em 1em .3em;
  border-width:8px;border-image-width:8px 12px;min-height:48px;
}
body .piece-sheet .piece-contact-links {
  display:flex;align-items:center;justify-content:center;gap:.3rem 1.8rem;flex-wrap:wrap;
  width:100%;max-width:none;margin:.45rem 0 clamp(1.2rem, 3vw, 2rem);
}
body .piece-sheet .piece-contact-links a {
  display:inline-grid;align-content:center;min-height:44px;padding:.35em .25em .6em;
  background:url('/images/trait-marqueur-rouge.svg') center bottom / 98% .46em no-repeat;
  text-decoration:none;
}
body .piece-sheet :is(input,textarea,button,a):focus-visible {outline:3px solid #a71528;outline-offset:2px;}
@layer framed-lettering {
  html:root body[data-page] :is(#main-content,#detail) .piece-sheet .piece-name {
    padding:0;font:400 clamp(25px,5.7cqi,64px)/1.35 var(--site-lettering) !important;
    letter-spacing:.025em !important;overflow-wrap:normal;text-wrap:balance;
  }
  html:root body[data-page] :is(#main-content,#detail) .piece-sheet .piece-name-long {
    font-size:clamp(14px,4.05cqi,48px) !important;
  }
  html:root body[data-page] :is(#main-content,#detail) .piece-sheet .piece-notes h3 {
    font:400 clamp(21px,4.4cqi,43px)/1.3 var(--site-lettering) !important;
  }
  @media screen and (forced-colors:none) {
    html:root body[data-page] :is(#main-content,#detail) .piece-sheet .piece-marker,
    html:root body[data-page] :is(#main-content,#detail) .piece-sheet .piece-marker :where(*) {
      color:#fffaf4 !important;-webkit-text-fill-color:currentColor !important;
      -webkit-text-stroke:.09em #131011 !important;paint-order:stroke fill;text-shadow:none !important;
    }
    html:root body[data-page] :is(#main-content,#detail) .piece-sheet .piece-marker .sale-initial {
      color:#a71528 !important;
    }
    html:root body[data-page] :is(#main-content,#detail) .piece-sheet :is(.piece-description,.piece-fulfillment,.piece-provenance p),
    html:root body[data-page] :is(#main-content,#detail) .piece-sheet :is(.piece-description,.piece-fulfillment,.piece-provenance p) :where(*) {
      color:#fff8ef !important;-webkit-text-fill-color:currentColor !important;
      -webkit-text-stroke:.085em #161213 !important;paint-order:stroke fill;text-shadow:none !important;
      font:400 clamp(21px,2.7cqi,30px)/1.5 var(--site-lettering) !important;
    }
    html:root body[data-page] :is(#main-content,#detail) .piece-sheet :is(.inquiry-label,.inquiry-send),
    html:root body[data-page] :is(#main-content,#detail) .piece-sheet :is(.inquiry-label,.inquiry-send) :where(*) {
      font:400 clamp(20px,2.7cqi,30px)/1.25 var(--site-lettering) !important;
      color:white !important;-webkit-text-fill-color:white !important;-webkit-text-stroke:.12em #a71528 !important;
      paint-order:stroke fill;text-shadow:none !important;
    }
    html:root body[data-page] :is(#main-content,#detail) .piece-sheet .piece-contact-links :is(a,a *) {
      color:#211719 !important;-webkit-text-fill-color:currentColor !important;-webkit-text-stroke:0 !important;
      text-shadow:none !important;
    }
  }
}
@media (max-width:600px) {
  body .piece-sheet {padding:12px 9px;}
  body .piece-sheet .write-me {gap:4px;}
  body .piece-sheet .piece-question {padding:36px 15px;}

}

/* The white archive drawing belongs to the whole product page. */
body[data-page].piece-full-page {
  min-height: 100svh;
  isolation: isolate;
}
body.piece-full-page::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: #080808 var(--piece-outline) center / cover no-repeat;
}
body.piece-full-page :is(main, .piece-sheet) { background: transparent; }
body.piece-full-page .piece-sheet::before { display: none; }
body.piece-full-page > .archive-page-outline { display: none; }

body .piece-sheet .piece-description-panel {
  margin:.6rem 0 1rem;
  border:1px solid #75424b;
  background:#171415;
}
body .piece-sheet .piece-description-panel > summary {
  padding:.55rem .85rem;
  cursor:pointer;
  line-height:1.35;
  color:#fff8ef;
}
body .piece-sheet .piece-description-panel > summary::marker { color:#ef5366; }
body .piece-sheet .piece-description-panel > summary:focus-visible {
  outline:2px solid #ef5366;
  outline-offset:2px;
}
body .piece-sheet .piece-description-body {
  padding:.35rem .85rem .8rem;
  border-block-start:1px solid #75424b;
}
body .piece-sheet .piece-description-body .piece-provenance { padding:.65rem 0 0; }
body .piece-sheet .piece-description-body .piece-provenance h3 {margin:.55em 0;text-align:start;}
@media (forced-colors:active) {
  body .piece-sheet .piece-contact-links a { text-decoration:underline; }
}
