:root {
  --columns: 6;
  --mobile-columns: 2;
  --header-height: 34px;
  --text: #0c0c0c;
  --muted: #a8a8a8;
  --line: #dedede;
  --panel: #f9f9f9;
  --shadow: 0 2px 16px rgb(0 0 0 / 10%);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  color: var(--text);
  background: #fff;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 10px;
  letter-spacing: 0;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background: #fff;
  color: var(--text);
  text-transform: uppercase;
}

button,
input,
select {
  font: inherit;
  color: inherit;
  text-transform: inherit;
}

button,
a,
select {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  border: 0;
  background: transparent;
  cursor: pointer;
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  right: 0;
  left: 0;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: var(--header-height);
  padding: 7px 18px 6px;
  background: rgb(255 255 255 / 92%);
}

.desktop-nav,
.utility-nav {
  display: flex;
  align-items: center;
  gap: 34px;
  white-space: nowrap;
}

.desktop-nav a,
.utility-nav a,
.utility-nav button {
  padding: 4px 0;
}

.legacy-pill {
  min-width: 86px;
  padding: 5px 14px !important;
  border-radius: 8px;
  background: #e9e9e9;
  text-align: center;
}

.brand {
  display: inline-flex;
  justify-self: center;
  min-width: 132px;
  justify-content: center;
  color: #050505;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .5px;
  line-height: 1;
}

.utility-nav {
  justify-content: flex-end;
  gap: 28px;
}

.search-button {
  position: relative;
  width: 18px;
  height: 18px;
}

.search-button::before {
  position: absolute;
  top: 5px;
  left: 5px;
  width: 6px;
  height: 6px;
  border: 1px solid #111;
  content: "";
}

.search-button::after {
  position: absolute;
  top: 11px;
  left: 11px;
  width: 5px;
  height: 1px;
  background: #111;
  content: "";
  transform: rotate(45deg);
  transform-origin: left center;
}

.cart-link {
  display: inline-flex;
  align-items: baseline;
  gap: 11px;
}

.menu-toggle {
  display: none;
}

.collection-shell {
  min-height: 100vh;
  padding-top: 34px;
}

.collection-controls {
  position: sticky;
  z-index: 10;
  top: var(--header-height);
  display: grid;
  grid-template-columns: 144px minmax(330px, 520px) 190px;
  align-items: start;
  gap: 28px;
  min-height: 92px;
  padding: 44px 15px 0;
  pointer-events: none;
}

.collection-controls button,
.collection-controls select {
  pointer-events: auto;
}

.density-control {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  width: 104px;
  min-height: 30px;
  overflow: hidden;
  border-radius: 7px;
  background: #fff;
  box-shadow: var(--shadow);
}

.density-control button {
  min-width: 34px;
  color: var(--muted);
  font-size: 9px;
}

.density-control button.active {
  color: #000;
  font-weight: 700;
}

.category-tabs {
  display: grid;
  grid-template-columns: .7fr .9fr .75fr .9fr 1.3fr 1.55fr;
  justify-self: center;
  width: 522px;
  min-height: 34px;
  overflow: hidden;
  border-radius: 6px;
  background: #fff;
  box-shadow: var(--shadow);
}

.category-tabs button {
  min-width: 0;
  padding: 0 9px;
  overflow: hidden;
  color: var(--muted);
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-tabs button.active {
  color: #000;
}

.sort-control {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  align-items: center;
  color: var(--muted);
  font-size: 9px;
  opacity: 0;
  transition: opacity 140ms ease;
}

.collection-controls:hover .sort-control,
.sort-control:focus-within {
  opacity: 1;
}

.sort-control select {
  width: 92px;
  height: 30px;
  padding: 0 17px 0 8px;
  border: 0;
  border-radius: 6px;
  outline: 0;
  background: #fff;
  box-shadow: var(--shadow);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(var(--columns), minmax(0, 1fr));
  column-gap: clamp(42px, 7vw, 90px);
  row-gap: clamp(145px, 12vh, 175px);
  padding: 55px 32px 160px;
}

.product-card {
  position: relative;
  min-width: 0;
}

.product-image-link {
  display: grid;
  align-items: center;
  justify-items: center;
  width: 100%;
  aspect-ratio: 3 / 4;
  outline-offset: 8px;
}

.product-card img {
  display: block;
  width: min(100%, 240px);
  max-height: 100%;
  object-fit: contain;
  opacity: .98;
  transition: opacity 180ms ease, transform 180ms ease;
}

.product-card:hover img,
.product-card:focus-within img {
  opacity: .74;
  transform: translateY(-2px);
}

.product-meta {
  display: grid;
  gap: 7px;
  min-height: 72px;
  margin-top: 18px;
  font-size: 10px;
  line-height: 1.45;
}

.product-title,
.product-color,
.product-price {
  margin: 0;
}

.product-title {
  display: block;
  min-height: 14px;
}

.product-color {
  color: #222;
}

.quick-add {
  justify-self: start;
  min-width: 98px;
  height: 23px;
  margin-top: 2px;
  padding: 0;
  color: var(--muted);
  text-align: left;
}

.quick-add:hover,
.quick-add:focus-visible {
  color: #000;
}

.product-card.sold-out img {
  opacity: .45;
}

.product-card.sold-out::after {
  display: none;
}

.mobile-density {
  display: none;
}

.site-footer {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  gap: 40px;
  padding: 56px 18px 22px;
  border-top: 1px solid transparent;
  font-size: 10px;
  line-height: 1.55;
}

.site-footer p {
  margin: 0;
}

.site-footer nav {
  display: flex;
  align-items: end;
  gap: 18px;
}

.menu-drawer {
  position: fixed;
  z-index: 40;
  inset: 0 auto 0 0;
  display: grid;
  grid-auto-rows: max-content;
  gap: 22px;
  width: min(88vw, 320px);
  padding: 21px 22px;
  background: #fff;
  box-shadow: 12px 0 38px rgb(0 0 0 / 10%);
  transform: translateX(-105%);
  transition: transform 180ms ease;
}

.menu-drawer.open {
  transform: translateX(0);
}

.drawer-close {
  justify-self: start;
  padding: 0;
  color: #111;
  font-size: 10px;
}

.drawer-meta {
  display: grid;
  gap: 7px;
  margin-top: 24px;
  color: var(--muted);
}

dialog {
  width: min(520px, calc(100vw - 28px));
  max-width: none;
  padding: 0;
  border: 0;
  background: transparent;
}

dialog::backdrop {
  background: rgb(255 255 255 / 72%);
}

.search-panel,
.cart-panel {
  display: grid;
  gap: 18px;
  padding: 22px;
  background: #fff;
  box-shadow: var(--shadow);
}

.search-panel label {
  color: var(--muted);
}

.search-panel input {
  width: 100%;
  height: 38px;
  border: 0;
  border-bottom: 1px solid #000;
  border-radius: 0;
  outline: 0;
  background: transparent;
  font-size: 12px;
}

.cart-panel {
  min-height: 340px;
}

.cart-panel h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 400;
}

.cart-view-link {
  justify-self: start;
}

.cart-items {
  display: grid;
  gap: 12px;
}

.cart-item {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  gap: 12px;
  align-items: center;
}

.cart-item img {
  width: 48px;
  height: 64px;
  object-fit: contain;
}

.cart-item p {
  margin: 0;
}

.cart-total {
  display: flex;
  justify-content: space-between;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.cart-note {
  margin: 0;
  color: var(--muted);
}

.checkout-button {
  height: 38px;
  background: #000;
  color: #fff;
}

.product-page .site-header {
  background: transparent;
}

.product-detail {
  display: grid;
  grid-template-columns: 50vw 1fr;
  min-height: 100vh;
  background: #fff;
}

.product-gallery {
  position: relative;
  min-width: 0;
  overflow: hidden;
  background: #f5f5f5;
}

.product-gallery-frame {
  display: grid;
  min-height: 100vh;
  align-items: center;
  justify-items: center;
  padding: 78px 52px 72px;
}

.product-gallery-frame img {
  display: block;
  width: min(150%, 1060px);
  max-height: calc(100vh + 520px);
  object-fit: contain;
  transform: translateY(-190px);
}

.product-thumbs {
  position: sticky;
  z-index: 4;
  bottom: 18px;
  left: 12px;
  display: grid;
  gap: 4px;
  width: 32px;
  margin-top: calc(-1 * min(44vh, 260px));
  padding-bottom: 18px;
}

.product-thumbs button {
  display: grid;
  width: 32px;
  height: 42px;
  place-items: center;
  border: 1px solid transparent;
  background: #fff;
}

.product-thumbs button.active {
  border-color: #000;
}

.product-thumbs img {
  max-width: 24px;
  max-height: 36px;
  object-fit: contain;
}

.product-info-pane {
  position: sticky;
  top: 0;
  display: grid;
  align-self: start;
  height: 100vh;
  min-height: 100vh;
  align-content: start;
  padding: 390px 36px 58px;
}

.product-back {
  position: absolute;
  top: 50px;
  left: 18px;
  display: inline-flex;
  gap: 18px;
  align-items: center;
  font-size: 10px;
}

.product-back::before {
  content: "<";
  font-size: 10px;
}

.product-buy-box {
  display: grid;
  grid-template-columns: 86px minmax(260px, 340px) minmax(80px, 1fr);
  gap: 20px;
  align-items: start;
  max-width: 690px;
  margin-left: auto;
}

.product-summary {
  grid-column: 2 / 4;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  min-height: 86px;
}

.product-summary h1,
.product-summary p {
  margin: 0;
  font-size: 10px;
  font-weight: 400;
  line-height: 1.65;
}

.product-color-label {
  color: var(--muted);
}

.variant-row {
  grid-column: 1 / 4;
  display: grid;
  grid-template-columns: 86px 1fr auto;
  gap: 20px;
  align-items: center;
}

.variant-row label,
.product-size-guide {
  color: #777;
}

.size-options {
  display: flex;
  gap: 19px;
  align-items: center;
}

.size-options button {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  background: #f1f1f1;
  color: #444;
}

.size-options button.active {
  background: #000;
  color: #fff;
}

.size-options button:disabled {
  color: #d7d7d7;
  cursor: default;
}

.product-size-guide {
  justify-self: end;
}

.product-actions {
  grid-column: 2 / 4;
  display: grid;
  gap: 14px;
  margin-top: 8px;
}

.product-add-button {
  height: 40px;
  background: #111;
  color: #fff;
}

.product-add-button:disabled {
  opacity: .45;
  cursor: default;
}

.product-share-button {
  justify-self: start;
  color: #777;
}

.product-accordions {
  grid-column: 1 / 4;
  display: grid;
  gap: 18px;
  margin-top: 24px;
}

.product-accordions details {
  max-width: 570px;
}

.product-accordions summary {
  cursor: pointer;
  list-style: none;
}

.product-accordions summary::-webkit-details-marker {
  display: none;
}

.accordion-content {
  margin-top: 18px;
  color: #333;
  font-size: 10px;
  line-height: 1.7;
  text-transform: none;
}

.accordion-content p {
  margin: 0 0 12px;
}

.related-products {
  grid-column: 1 / -1;
  padding: 54px 16px 110px;
  background: #f5f5f5;
}

.related-products h2 {
  margin: 0 0 48px;
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0;
}

.related-products h2::before {
  content: "▪";
  margin-right: 18px;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 64px;
}

.related-card {
  display: grid;
  gap: 18px;
}

.related-card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: contain;
}

.related-card span {
  font-size: 10px;
  line-height: 1.45;
}

@media (hover: hover) and (min-width: 800px) {
  .product-meta {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    left: 0;
    opacity: 0;
    transition: opacity 140ms ease;
  }

  .product-card:hover .product-meta,
  .product-card:focus-within .product-meta {
    opacity: 1;
  }
}

@media (max-width: 1100px) {
  .collection-controls {
    grid-template-columns: 112px minmax(320px, 520px) 1fr;
  }

  .sort-control span {
    display: none;
  }
}

@media (max-width: 760px) {
  :root {
    --header-height: 31px;
  }

  body {
    overflow-x: hidden;
  }

  .site-header {
    grid-template-columns: 34px 1fr 34px;
    min-height: var(--header-height);
    padding: 9px 14px 6px;
  }

  .desktop-nav,
  .utility-nav {
    display: none;
  }

  .menu-toggle {
    display: grid;
    width: 18px;
    height: 18px;
    align-content: center;
    gap: 5px;
  }

  .menu-toggle span {
    display: block;
    width: 11px;
    height: 1px;
    background: #111;
  }

  .brand {
    min-width: 120px;
    font-size: 11px;
  }

  .collection-shell {
    padding-top: 31px;
  }

  .collection-controls {
    top: var(--header-height);
    display: block;
    min-height: 42px;
    padding: 18px 0 0;
    overflow-x: auto;
    background: rgb(255 255 255 / 95%);
    scrollbar-width: none;
  }

  .collection-controls::-webkit-scrollbar {
    display: none;
  }

  .density-control,
  .sort-control {
    display: none;
  }

  .category-tabs {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 108px;
    grid-template-columns: none;
    justify-self: stretch;
    width: max-content;
    min-width: 100vw;
    min-height: 25px;
    border-radius: 0;
    box-shadow: none;
  }

  .category-tabs button {
    position: relative;
    padding: 0 15px 10px;
    text-align: left;
  }

  .category-tabs button.active::after {
    position: absolute;
    right: 15px;
    bottom: 0;
    left: 15px;
    height: 1px;
    background: #111;
    content: "";
  }

  .product-grid {
    grid-template-columns: repeat(var(--mobile-columns), minmax(0, 1fr));
    column-gap: 56px;
    row-gap: 54px;
    padding: 30px 14px 126px;
  }

  .product-card img {
    width: min(100%, 210px);
  }

  .product-meta {
    min-height: 84px;
    margin-top: 22px;
    gap: 6px;
    font-size: 10px;
    line-height: 1.55;
  }

  .quick-add {
    display: none;
  }

  .mobile-density {
    position: fixed;
    z-index: 30;
    bottom: 16px;
    left: 15px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 86px;
    height: 36px;
    overflow: hidden;
    border-radius: 6px;
    background: #fff;
    box-shadow: var(--shadow);
  }

  .mobile-density button {
    color: #555;
    font-size: 14px;
    font-weight: 700;
  }

  .site-footer {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
    padding-bottom: 76px;
  }

  .site-footer nav {
    flex-wrap: wrap;
    justify-content: start;
  }

  .product-detail {
    display: block;
  }

  .product-gallery {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 100%;
    min-height: 636px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }

  .product-gallery::-webkit-scrollbar {
    display: none;
  }

  .product-gallery-frame {
    min-height: 636px;
    padding: 68px 0 28px;
    scroll-snap-align: start;
  }

  .product-gallery-frame img {
    width: min(142vw, 560px);
    max-width: none;
    max-height: 560px;
    transform: none;
  }

  .product-thumbs {
    position: absolute;
    right: 0;
    bottom: 14px;
    left: 0;
    display: flex;
    justify-content: center;
    width: auto;
    margin: 0;
    padding: 0;
    gap: 0;
  }

  .product-thumbs button {
    width: 48px;
    height: 12px;
    border: 0;
    border-bottom: 1px solid #c8c8c8;
    background: transparent;
  }

  .product-thumbs button.active {
    border-bottom-color: #000;
  }

  .product-thumbs img {
    display: none;
  }

  .product-info-pane {
    position: static;
    height: auto;
    min-height: 0;
    padding: 22px 16px 56px;
  }

  .product-back {
    display: none;
  }

  .product-buy-box {
    display: grid;
    grid-template-columns: 1fr;
    gap: 26px;
    max-width: none;
    margin: 0;
  }

  .product-summary {
    grid-column: 1;
    display: grid;
    grid-template-columns: 1fr;
    min-height: 58px;
    gap: 6px;
  }

  .product-color-label {
    display: none;
  }

  .variant-row {
    grid-column: 1;
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .variant-row label,
  .product-size-guide,
  .product-share-button {
    display: none;
  }

  .size-options {
    gap: 18px;
    padding-left: 8px;
  }

  .size-options button {
    width: 25px;
    height: 25px;
  }

  .product-actions {
    grid-column: 1;
    margin-top: 0;
  }

  .product-add-button {
    height: 41px;
  }

  .product-accordions {
    grid-column: 1;
    gap: 22px;
    margin-top: 18px;
    padding-top: 18px;
  }

  .accordion-content {
    line-height: 1.6;
  }

  .related-products {
    padding: 54px 16px 84px;
  }

  .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 52px 46px;
  }
}

@media (max-width: 430px) {
  .product-grid {
    column-gap: 58px;
    padding-right: 0;
  }

  .product-card {
    width: calc((100vw - 30px - 58px) / var(--mobile-columns));
  }
}

@media (max-width: 360px) {
  .category-tabs {
    grid-auto-columns: 96px;
  }

  .product-grid {
    column-gap: 34px;
  }
}
