.product-main {
  padding-block: clamp(20px, 3.5vw, 50px) clamp(62px, 8vw, 116px);
}
.product-wrap {
  max-width: 1160px;
}
.product-toolbar {
  display: flex;
  min-height: 44px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: clamp(20px, 3.2vw, 44px);
}
.product-toolbar nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-weight: 650;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.product-detail {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
  grid-template-rows: auto 1fr;
  grid-template-areas:
    "photos heading"
    "photos purchase";
  column-gap: clamp(34px, 6vw, 94px);
  row-gap: 21px;
  align-items: start;
}
.product-heading { grid-area: heading; padding-top: clamp(8px, 1.7vw, 24px); }
.product-photos { grid-area: photos; min-width: 0; }
.product-purchase { grid-area: purchase; min-width: 0; }
.product-color {
  margin: 0 0 16px;
  color: var(--red);
  font-weight: 700;
}
.product-color a { text-decoration: underline; text-underline-offset: 3px; }
.product-heading .display {
  margin: 0;
  font-size: clamp(2.15rem, 3.9vw, 4.25rem);
  line-height: .98;
  letter-spacing: -.04em;
  text-wrap: balance;
  text-transform: uppercase;
}
.product-price {
  margin: 18px 0 0;
  color: var(--ink);
  font-size: clamp(1.18rem, 2.1vw, 1.5rem);
  font-weight: 750;
}
.product-view {
  overflow: hidden;
  margin: 0;
  background: #fff;
}
.product-view[hidden] { display: none; }
.product-view img {
  display: block;
  width: 100%;
  height: auto;
}
.product-photo-choices {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(5px, 1vw, 10px);
  margin-top: 11px;
}
.product-photo-choices button {
  position: relative;
  display: block;
  min-width: 0;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}
.product-photo-choices button[aria-pressed="true"]::after {
  position: absolute;
  inset: 0;
  border: 2px solid var(--red);
  pointer-events: none;
  content: "";
}
.product-photo-choices button:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}
.product-photo-thumb {
  display: block;
  width: 100%;
  overflow: hidden;
  aspect-ratio: 1;
  background: #fff;
}
.product-photo-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.product-mockup-tile,
.product-photo-thumb--sheet {
  --photo-width: 1;
  position: relative;
  overflow: hidden;
}
.product-mockup-tile {
  aspect-ratio: var(--photo-width);
}
.product-mockup-tile img,
.product-photo-thumb--sheet img {
  position: absolute;
  left: calc((var(--image-column) + (1 - var(--photo-width)) / 2) * -100% / var(--photo-width));
  top: calc(var(--image-row) * -100%);
  width: calc(300% / var(--photo-width));
  max-width: none;
  height: auto;
}
.product-photo-thumb--sheet img {
  top: calc((var(--image-row) + (1 - var(--photo-width)) / 2) * -100% / var(--photo-width));
}
.product-purchase > p:first-child {
  max-width: 39ch;
  margin: 0 0 25px;
  font-size: 1rem;
  line-height: 1.66;
}
.product-size {
  min-inline-size: 0;
  margin: 0;
  padding: 0;
  border: 0;
}
.product-size legend {
  margin-bottom: 10px;
  padding: 0;
  font-weight: 700;
}
.product-one-size {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
}
.product-colors {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 0 0 18px;
}
.product-colors strong { margin-right: 4px; }
.product-colors a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  padding: 0 10px;
  border: 1px solid var(--line);
  text-decoration: none;
}
.product-colors a[aria-current="page"] { border-color: var(--ink); font-weight: 700; }
.product-swatch { width: 14px; height: 14px; border: 1px solid #7e7872; border-radius: 50%; }
.product-swatch-black { background: #171717; }
.product-swatch-white { background: #fff; }
.product-purchase .product-add {
  width: 100%;
  min-height: 52px;
  justify-content: center;
  margin-top: 12px;
  border-color: #9f1b2b;
  background: #9f1b2b;
  color: #fff;
  font-weight: 700;
}
.product-purchase .product-add:enabled:hover {
  border-color: #761320;
  background: #761320;
  color: #fff;
}
.product-purchase .product-add:disabled {
  border-color: var(--line);
  background: #e7e1d9;
  color: #5b514b;
  cursor: default;
}
.product-checkout-note {
  margin: 12px 0 20px;
  color: var(--muted);
  font-size: .85rem;
}
.product-specs {
  margin: 0;
  border-top: 1px solid var(--line);
}
.product-specs div {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 6px 18px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}
.product-specs dt { font-weight: 700; }
.product-specs dd { margin: 0; }

.product-related {
  --related-gap: clamp(9px, 2.5vw, 24px);
  margin-top: clamp(3rem, 7vw, 6rem);
}
.product-related h2 { font-size: clamp(1.35rem, 3vw, 2rem); text-transform: uppercase; }
.product-related-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.product-related-controls { display: flex; flex: none; gap: 8px; }
.product-related-controls .icon-button {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
}
.product-related-controls .icon-button:disabled { opacity: .4; cursor: default; }
.product-related-controls svg { width: 20px; height: 20px; }
.product-related-controls button:first-child svg { transform: rotate(180deg); }
.product-related ul {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--related-gap);
  padding: 0;
  margin: 1rem 0 0;
  list-style: none;
}
.product-related ul.product-related-list {
  grid-template-columns: none;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - var(--related-gap) * 2) / 3);
  overflow-x: auto;
  padding-block-end: 10px;
  scroll-snap-type: x mandatory;
  overscroll-behavior-inline: contain;
}
.product-related-list li { min-width: 0; scroll-snap-align: start; }
.product-related li a {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 5px;
  text-decoration: none;
}
.product-related li a:focus-visible { outline-offset: -2px; }
.product-related li a:hover > span:last-of-type { text-decoration: underline; text-underline-offset: 3px; }
.product-related li a > img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: contain;
  border: 1px solid var(--line);
  background: #fff;
}
.product-related-photo {
  display: block;
  position: relative;
  overflow: hidden;
  aspect-ratio: 1;
  background: #fff;
}
.product-related-photo > img { width: 100%; height: 100%; object-fit: contain; }
.product-related li a > span:last-of-type { font-size: .9rem; font-weight: 700; line-height: 1.35; }
.product-related li small { color: var(--muted); }

@media (max-width: 760px) {
  .product-detail {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto;
    grid-template-areas: "heading" "photos" "purchase";
    row-gap: 22px;
  }
  .product-heading { padding: 0; }
  .product-heading .display { max-width: 14ch; font-size: clamp(2rem, 9.5vw, 3.15rem); }
  .product-color { margin-bottom: 10px; }
  .product-price { margin-top: 12px; }
  .product-toolbar { margin-bottom: 16px; }
  .product-related ul { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .product-related ul.product-related-list { grid-auto-columns: 46%; }
}
