:root {
  --stock-red: #c5262f;
  --stock-ink: #9e1923;
  --stock-paper: #f1efe7;
}
.stock-graphic {
  position: absolute;
  z-index: 2;
  pointer-events: none;
  text-align: center;
  font-family: Archivo, Arial, sans-serif;
  font-weight: 950;
  font-stretch: 70%;
  text-transform: uppercase;
  line-height: .95;
  letter-spacing: -.035em;
}
.stock-graphic-almost_sold_out {
  inset: auto 0 0;
  padding: .7rem .5rem;
  background: var(--stock-red);
  color: var(--stock-paper);
  font-size: clamp(1.05rem, 2.1vw, 2rem);
  border-top: 1px solid #f1efe75e;
}
.stock-graphic-sold_out {
  left: 7%;
  width: 86%;
  top: 53%;
  transform: rotate(-9deg);
  padding: .1em .15em .15em;
  color: var(--stock-red);
  background: #f1efe7f0;
  border: .075em solid currentColor;
  box-shadow: 0 0 0 2px var(--stock-paper);
  font-size: clamp(2.3rem, 6vw, 5.8rem);
  text-shadow: 1px 0 currentColor;
}
.first-drop-details .stock-confirmation {
  grid-column: 1 / -1;
  grid-row: 3;
}
.stock-confirmation {
  margin: .3rem 0 0;
  padding: .2rem .5rem;
  width: fit-content;
  max-width: 100%;
  font-family: Archivo, Arial, sans-serif;
  font-size: 1rem;
  font-weight: 850;
  font-stretch: 80%;
  line-height: 1.2;
  letter-spacing: .03em;
  color: #f1efe7;
  background: var(--stock-ink);
}
.stock-detail-stage {
  position: relative;
  overflow: hidden;
}
.stock-detail-stage > img { width: 100%; display: block; }
[data-stock-state="sold_out"] > img { opacity: .66; }
.first-drop-details[data-stock-state="sold_out"] .first-drop-price { color: #b8b8b1; }
.catalog-preview-item .item-details .stock-confirmation {
  margin-bottom: .75rem;
  font-size: clamp(1.45rem, 3.3vw, 2.6rem);
  padding: .3rem .55rem .4rem;
}
.stock-detail-stage .stock-graphic-sold_out { font-size: clamp(2.5rem, 6vw, 6.3rem); }
.stock-disabled-order {
  width: min(100%, 22rem);
  min-height: 54px;
  padding: .8rem 1.2rem;
  border: 2px solid var(--stock-red);
  background: #272222;
  color: var(--stock-paper);
  font: 850 1.3rem/1 Archivo, Arial, sans-serif;
  letter-spacing: .08em;
  cursor: not-allowed;
}
@media (max-width: 600px) {
  .first-drop-stage .stock-graphic-almost_sold_out { font-size: clamp(1rem, 4.2vw, 1.45rem); padding: .6rem .2rem; }
  .first-drop-stage .stock-graphic-sold_out { font-size: clamp(2rem, 8vw, 3.8rem); left: 5%; width: 90%; }
  .first-drop-cards .stock-confirmation { font-size: .875rem; }
  .stock-detail-stage .stock-graphic-almost_sold_out { font-size: 1.5rem; }
  .stock-detail-stage .stock-graphic-sold_out { font-size: clamp(2.4rem, 12vw, 4.5rem); }
}

@media (max-width: 940px) {
  .first-drop-details .stock-confirmation { grid-row: 4; }
}

.first-drop-stage, .stock-detail-stage { container-type: inline-size; }
.stock-graphic-sold_out,
.first-drop-stage .stock-graphic-sold_out,
.stock-detail-stage .stock-graphic-sold_out {
  font-size: clamp(1.25rem, 15cqw, 6rem);
  white-space: nowrap;
}

/* The compact catalog stacks photos before details by default. Availability
   must precede the gallery on phones, including the two-photo shorts page. */
@media (max-width: 720px) {
  .catalog-preview-item .item-details { grid-row: 1; }
  .catalog-preview-item .stock-product-photos { min-width: 0; }
}
@media (max-width: 600px) {
  /* Keep the full-width shorts confirmation clear of the fixed Home tab. */
  .first-drop-cards > [data-product-id="sweatshorts"] .stock-confirmation { justify-self: end; }
}
@media (max-width: 600px) {
  /* A fixed side tab can mask availability at arbitrary scroll positions.
     Keep the same Home control in the Shop heading's reserved right corner. */
  body[data-trace-route="shop"] > .shop-edge-tab {
    position: absolute;
    left: auto;
    right: 19px;
    top: calc(var(--trace-header-height, 4.15rem) + 1.2rem);
    width: 64px;
    height: 44px;
  }
  body[data-trace-route="shop"] > .shop-edge-tab .shop-edge-header {
    inset: 0;
    width: 100%;
    height: 100%;
    transform: none;
  }
  body[data-trace-route="shop"] > .shop-edge-tab .shop-tab-label { transform: none; font-size: .75rem; }
  body[data-trace-route="shop"] > .shop-edge-tab .shop-edge-header::before {
    inset: 0;
    width: 100%;
    height: 100%;
    transform: none;
  }
}

/* Studio cutouts sit directly against the collection backdrop. */
.first-drop-stage.has-garment-cutout,
.first-drop-card:hover .first-drop-stage.has-garment-cutout {
  background: transparent;
  box-shadow: none;
}
.first-drop-stage.has-garment-cutout::after { content: none; }
.first-drop-stage.has-garment-cutout img {
  width: 92%;
  mask-image: none;
}
.has-garment-cutout > img {
  filter: drop-shadow(0 .35rem .28rem #08080850) drop-shadow(0 .9rem 1.1rem #08080860);
}
.stock-detail-stage.has-garment-cutout {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
}
.commerce .stock-detail-stage.has-garment-cutout > .gallery-image {
  width: 92%;
  height: auto;
  background: transparent;
}
.stock-detail-stage.has-garment-cutout > img[hidden] { display: none; }
.garment-view-controls {
  display: flex;
  justify-content: center;
  gap: .5rem;
}
.garment-view-controls button {
  min-width: 5.5rem;
  min-height: 44px;
  padding: .5rem .9rem;
  border: 1px solid #f1efe780;
  background: #161616;
  color: #f1efe7;
  cursor: pointer;
  font: inherit;
  text-transform: uppercase;
}
.garment-view-controls button[aria-pressed="true"] {
  background: #f1efe7;
  color: #161616;
}
.garment-view-controls button:focus-visible {
  outline: 2px solid #b5d2e4;
  outline-offset: 3px;
}
@media (max-width: 600px) {
  [data-product-id="sweatshorts"] .first-drop-stage.has-garment-cutout img { width: 65%; }
}
.garment-view-status { text-align: center; }
.garment-view-status:empty { display: none; }

/* Reserve space below the silhouette so the red banner clears the hem.
   Shop cards reserve the same space to keep their details aligned. */
.first-drop-stage.has-garment-cutout,
.stock-detail-stage.has-garment-cutout[data-stock-state="almost_sold_out"] {
  box-sizing: content-box;
  padding-bottom: clamp(2.6rem, 4vw, 3.5rem);
}
@media (max-width: 600px) {
  .first-drop-stage.has-garment-cutout { padding-bottom: 2.4rem; }
}
