/* Product page only. Reserve the cover box before the image decodes
   so a late load does not shove the title and grids down mid-scroll.
   Desktop loupe still uses the existing #pmain size; we just make that
   size available up front. */
.pdp .zoomw{
  aspect-ratio:var(--cover-w, 2) / var(--cover-h, 3);
  width:min(520px, 52vw, calc((96dvh - 30px) * var(--cover-w, 2) / var(--cover-h, 3)));
  max-width:100%;
  height:auto;
  transition:none;
}
.pdp .pd-main img#pmain{
  width:100%;
  height:auto;
  max-width:none;
  max-height:none;
  aspect-ratio:var(--cover-w, auto) / var(--cover-h, auto);
  transition:none;
}
/* Mobile: size from column width + aspect-ratio only. Do not use dvh/vh —
   those grow when the browser toolbar collapses mid-scroll and the cover
   "tries to enlarge." Width-based sizing stays identical if only height changes. */
@media (max-width:760px){
  .pdp .zoomw{
    width:100%;
    max-width:100%;
    height:auto;
    max-height:none;
  }
  .pdp .pd-main img#pmain{
    width:100%;
    height:auto;
    max-width:100%;
    max-height:none;
  }
}
/* A handful of suggestion cards should not relayout when content-visibility unskeips them on scroll. */
.pdp-sug .card{
  content-visibility:visible;
  contain-intrinsic-size:auto;
}

/* In-flow shop search on product pages, directly under the Shop / Museum
   row (8px gap via main padding). Height is reserved in CSS. After this
   row scrolls away, the banner tab panel provides the same search. */
form.pdp-search{
  flex:none;
  width:auto;
  position:relative;
  margin:8px 16px 0;
  min-height:40px;
  box-sizing:border-box;
}
form.pdp-search input[type=search]{
  display:block;
  width:100%;
  height:40px;
  box-sizing:border-box;
  margin:0;
  background:var(--card);
  color:var(--txt);
  border:1px solid var(--line);
  border-radius:8px;
  padding:8px 40px 8px 12px;
  font:inherit;
  font-size:14px;
  line-height:1.2;
}
form.pdp-search input[type=search]::-webkit-search-cancel-button{
  -webkit-appearance:none;
  appearance:none;
  display:none;
}
form.pdp-search input[type=search]:focus{
  outline:2px solid var(--acc);
  outline-offset:1px;
  border-color:var(--acc);
}
form.pdp-search .pdp-sugs{
  position:absolute;
  left:0;
  right:0;
  top:100%;
  z-index:8;
  margin:4px 0 0;
  padding:4px;
  list-style:none;
  background:#1b1b22;
  border:1px solid var(--line);
  border-radius:8px;
  box-shadow:0 8px 24px #000c;
  max-height:min(320px, 50dvh);
  overflow:auto;
}
form.pdp-search .pdp-sugs[hidden]{display:none}
form.pdp-search .pdp-sugs li{margin:0}
form.pdp-search .pdp-sugs a{
  display:flex;
  align-items:center;
  gap:10px;
  padding:6px 8px;
  border-radius:6px;
  color:var(--txt);
  text-decoration:none;
  font-size:13px;
  font-weight:600;
  line-height:1.3;
}
form.pdp-search .pdp-sugs a .sug-text{flex:1 1 auto;min-width:0}
form.pdp-search .pdp-sugs a .mut{display:block;font-weight:500;font-size:12px;margin-top:1px}
form.pdp-search .pdp-sugs a:hover,
form.pdp-search .pdp-sugs li[aria-selected=true] a{
  background:#f5a52422;
  color:var(--acc);
}

/* Status bars (Preorder / Incoming) match the cover width.
   Limited print runs are a details "Print run" row, not a full-width band,
   so pages with only a print run reserve no bar space.
   Mobile: in-flow under the cover (between image and title), height reserved
   only when a Preorder or Incoming bar is present.
   Desktop: pinned to the bottom edge of the cover so a tall image does not
   push the bar below the fold. */
.pdp-spec .ltd-badge{
  display:inline-block;
  vertical-align:middle;
  background:var(--acc2,#ff6a1a);
  color:#1a0800;
  font-size:10px;
  font-weight:800;
  letter-spacing:.06em;
  line-height:1.2;
  padding:2px 7px;
  border-radius:4px;
  margin-right:8px;
  text-transform:uppercase;
}
.pdp .pd-main{
  position:relative;
  width:fit-content;
  max-width:100%;
}
.pdp .pdp-status{
  display:block;
  box-sizing:border-box;
  width:100%;
  min-height:36px;
  margin:8px 0 0;
  padding:8px 12px;
  border-radius:8px;
  text-align:center;
  font-size:14px;
  font-weight:800;
  letter-spacing:.06em;
  line-height:1.25;
  background:var(--acc);
  color:#000;
}
.pdp .pdp-status.incoming{background:#3d9adf;color:#041018}
.pdp .pdp-status.limited{background:var(--acc2,#ff6a1a);color:#1a0800}
.pdp .pdp-status.example{background:var(--card);color:var(--txt);border:1px solid var(--line)}
@media (max-width:760px){
  .pdp .pd-main{width:100%}
}
@media (min-width:761px){
  /* Sit on the cover, flush with its bottom when the whole cover is
     visible; if a tall cover extends past the viewport, lift the bar
     so it stays on-screen (~header+search offset 180px). */
  .pdp .pdp-status{
    position:absolute;
    left:0;
    right:0;
    bottom:max(0px, calc(100% - 100dvh + 80px));
    margin:0;
    border-radius:0;
    z-index:4;
  }
}

/* Related / complete-issue tiles: compact short labels on mobile only. */
.pdp-sug .card .card-title-short{display:none}
@media (min-width:761px) and (max-width:1099px){
  .pdp-sug{grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}
}
@media (min-width:1100px){
  .pdp-sug{grid-template-columns:repeat(6,minmax(0,1fr));gap:12px}
}
@media (max-width:760px){
  .pdp-sug{grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
  .pdp-sug .card{contain-intrinsic-size:auto}
  .pdp-sug .card .i{padding:6px 5px 7px;font-size:11px;line-height:1.25}
  .pdp-sug .card .card-title-full,
  .pdp-sug .card .mut{display:none}
  .pdp-sug .card .card-title-short{display:block;font-size:11px;font-weight:700;line-height:1.25}
  .pdp-sug .card-price{display:block;margin-top:3px;font-size:11px}
  .pdp-sug .card-price .price-was{margin-right:.25em;font-size:10px}
  .pdp-sug .badge,.pdp-sug .bstk{transform:scale(.78);transform-origin:top left}
  .pdp-sug .ribbon>i{font-size:9px;padding:3px 4px}
}
