@font-face {
  font-family: "Hanken";
  src: url("/fonts/hanken-grotesk-var.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --paper: #f7f7f5;
  --card: #f4f4f2;
  --ink: #131514;
  --muted: #5c5f58;
  --line: #e4e4e0;
  --hint: #9f321b;
  color-scheme: light;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body.shop {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Hanken, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }

button, input { font: inherit; color: inherit; }

button { cursor: pointer; }

a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: 12px;
  top: -40px;
  background: var(--ink);
  color: var(--paper);
  padding: 8px 12px;
  z-index: 50;
}

.skip:focus { top: 12px; }

.bar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  min-height: 68px;
  padding: 0 clamp(14px, 2vw, 28px);
  background: rgba(247, 247, 245, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.brand { justify-self: start; display: flex; }

.brand img { width: 148px; height: auto; }

.drop {
  margin: 0;
  justify-self: center;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.bag-open {
  justify-self: end;
  border: 0;
  background: transparent;
  padding: 8px 0;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.notice {
  margin: 0;
  padding: 12px 16px;
  background: var(--ink);
  color: var(--paper);
  text-align: center;
  font-size: 13px;
}

.notice[hidden] { display: none !important; }

.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  width: min(1680px, 100%);
  margin: 0 auto;
  padding: 10px;
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  color: inherit;
}

.card-link,
.card-meta {
  color: inherit;
  text-decoration: none;
}

.card-frame { position: relative; }

.card-media {
  display: block;
  position: relative;
  aspect-ratio: 4 / 5;
  background: var(--card);
  overflow: hidden;
}

.card-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-lead,
.card-hover {
  transition: opacity .32s ease;
}

.card-hover { opacity: 0; }

.edition-badge {
  position: absolute;
  z-index: 2;
  top: 10px;
  left: 10px;
  padding: 5px 7px;
  background: rgba(247, 247, 245, .92);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.quick {
  position: absolute;
  z-index: 2;
  left: 8px;
  right: 8px;
  bottom: 8px;
  display: flex;
  gap: 4px;
  opacity: 0;
  transform: translateY(6px);
  pointer-events: none;
  transition: opacity .28s ease, transform .28s ease;
}

.quick button {
  flex: 1;
  min-width: 0;
  height: 34px;
  padding: 0;
  border: 0;
  background: rgba(247, 247, 245, .94);
  font-size: 12px;
  letter-spacing: .04em;
}

.quick button:hover,
.quick button:focus-visible { background: var(--ink); color: var(--paper); }

.card:focus-within .quick {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

@media (hover: hover) {
  .card:hover .card-hover,
  .card:focus-within .card-hover { opacity: 1; }
  .card:hover .quick,
  .card:focus-within .quick {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }
}

@media (hover: none) {
  .quick {
    position: static;
    opacity: 1;
    transform: none;
    pointer-events: auto;
    margin: 8px 0 0;
  }
}

.card-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 2px 18px;
  font-size: 13.5px;
  font-weight: 540;
  letter-spacing: -.01em;
}

.card-price { font-variant-numeric: tabular-nums; white-space: nowrap; }

.card-price span { color: var(--muted); font-weight: 500; }

.product {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, .72fr);
  gap: clamp(28px, 4vw, 72px);
  align-items: start;
  width: min(1440px, 100%);
  margin: 0 auto;
  padding: clamp(18px, 2.4vw, 36px) clamp(14px, 2.4vw, 36px) 72px;
}

.back {
  grid-column: 1 / -1;
  display: inline-block;
  margin-bottom: 4px;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: .16em;
  text-transform: uppercase;
  text-decoration: none;
}

.back:hover { text-decoration: underline; text-underline-offset: 3px; }

.stage {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  aspect-ratio: 4 / 5;
  background: var(--card);
  cursor: zoom-in;
  overflow: hidden;
}

.stage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 1;
  transition: opacity .28s ease;
}

.stage img.is-fading { opacity: 0; }

.thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.thumbs button {
  width: 84px;
  flex: none;
  padding: 0;
  border: 1px solid transparent;
  background: var(--card);
  aspect-ratio: 4 / 5;
  overflow: hidden;
}

.thumbs button[aria-current="true"] { border-color: var(--ink); }

.thumbs img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.buy {
  position: sticky;
  top: 92px;
}

.buy h1 {
  margin: 0;
  font-size: clamp(40px, 4.4vw, 64px);
  font-weight: 520;
  letter-spacing: -.055em;
  line-height: .92;
}

.color {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.price {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 16px 0 0;
}

.price strong {
  font-size: 22px;
  font-weight: 560;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
}

.price span {
  font-size: 12px;
  font-weight: 650;
  letter-spacing: .14em;
}

.edition {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.sizes {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 26px;
}

.sizes button {
  min-width: 48px;
  height: 40px;
  padding: 0 12px;
  border: 1px solid #d4d4ce;
  background: transparent;
  font-size: 13px;
  letter-spacing: .04em;
}

.sizes button[aria-pressed="true"] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

.sizes button:active { transform: scale(.97); }

.size-hint {
  min-height: 1.3em;
  margin: 8px 0 0;
  color: var(--hint);
  font-size: 13px;
}

.add, .checkout {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 48px;
  margin-top: 14px;
  border: 0;
  background: var(--ink);
  color: var(--paper);
  font-size: 12px;
  font-weight: 650;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.add:hover, .checkout:hover:not(:disabled) { background: #2c2f2c; }

.checkout:disabled { opacity: .38; cursor: not-allowed; }

.checkout.is-busy {
  position: relative;
  color: transparent;
  opacity: 1;
  cursor: progress;
}

.checkout.is-busy::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(247, 247, 245, .35);
  border-top-color: var(--paper);
  border-radius: 50%;
  animation: shop-spin .7s linear infinite;
}

@keyframes shop-spin { to { transform: rotate(360deg); } }

.summary {
  margin: 28px 0 0;
  max-width: 38em;
  color: #3c3f39;
  font-size: 15px;
  line-height: 1.5;
}

.facts {
  margin: 18px 0 0;
  padding: 16px 0 0;
  border-top: 1px solid var(--line);
  list-style: none;
}

.facts li {
  padding: 6px 0;
  color: #3c3f39;
  font-size: 14px;
  line-height: 1.45;
}

.notes { margin-top: 8px; border-top: 1px solid var(--line); }

.notes details { border-bottom: 1px solid var(--line); }

.notes summary {
  padding: 14px 0;
  cursor: pointer;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: .14em;
  text-transform: uppercase;
  list-style: none;
}

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

.notes p {
  margin: 0 0 16px;
  color: #3c3f39;
  font-size: 14px;
  line-height: 1.55;
}

.shop-foot {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  width: min(1680px, 100%);
  margin: 0 auto;
  padding: 22px clamp(14px, 2vw, 28px) 32px;
  border-top: 1px solid var(--line);
  font-size: 11px;
  font-weight: 650;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.shop-foot nav { display: flex; gap: 18px; }

.shop-foot a { text-decoration: none; }

.shop-foot a:hover { text-decoration: underline; text-underline-offset: 3px; }

.bag[hidden] { display: none !important; }

.bag {
  position: fixed;
  inset: 0;
  z-index: 40;
}

.bag-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(19, 21, 20, .28);
}

.bag-panel {
  position: absolute;
  top: 0;
  right: 0;
  display: flex;
  flex-direction: column;
  width: min(420px, 100%);
  height: 100%;
  background: var(--paper);
  border-left: 1px solid var(--line);
  transform: translateX(12px);
  opacity: 0;
  transition: transform .32s ease, opacity .32s ease;
}

.bag.is-open .bag-panel {
  transform: none;
  opacity: 1;
}

.bag-head, .bag-foot { padding: 18px 18px 16px; }

.bag-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--line);
}

.bag-head h2 {
  margin: 0;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.bag-close {
  border: 0;
  background: transparent;
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.bag-body {
  flex: 1;
  overflow: auto;
  overscroll-behavior: contain;
  padding: 8px 18px 18px;
}

.bag-empty {
  margin: 28px 0;
  color: var(--muted);
  font-size: 14px;
}

.line {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.line img {
  width: 72px;
  height: 90px;
  object-fit: cover;
  background: var(--card);
}

.line-name {
  margin: 0;
  font-size: 15px;
  font-weight: 560;
  letter-spacing: -.02em;
}

.line-size, .line-price {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.line-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
}

.qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid #d4d4ce;
}

.qty button {
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
}

.qty span {
  min-width: 18px;
  text-align: center;
  font-variant-numeric: tabular-nums;
  font-size: 13px;
}

.remove {
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.bag-foot { border-top: 1px solid var(--line); }

.bag-sub {
  display: flex;
  justify-content: space-between;
  margin: 0;
  font-size: 14px;
  font-weight: 560;
  font-variant-numeric: tabular-nums;
}

.bag-note {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.bag-status {
  min-height: 1.3em;
  margin: 10px 0 0;
  font-size: 13px;
  line-height: 1.4;
}

.bag-status[data-kind="problem"] { color: var(--hint); }

.confirm {
  width: min(760px, 100%);
  margin: 0 auto;
  padding: clamp(48px, 8vw, 96px) clamp(18px, 4vw, 36px) 96px;
}

.confirm .eyebrow {
  margin: 0;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.confirm h1 {
  margin: 10px 0 0;
  font-size: clamp(48px, 8vw, 88px);
  font-weight: 520;
  letter-spacing: -.055em;
  line-height: .9;
}

.confirm .lead {
  max-width: 28em;
  margin: 18px 0 0;
  font-size: 18px;
  line-height: 1.45;
}

.confirm-back {
  display: inline-block;
  margin-top: 28px;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: .16em;
  text-transform: uppercase;
  text-decoration: none;
}

.confirm-back:hover { text-decoration: underline; text-underline-offset: 3px; }

.receipt { margin-top: 32px; }

.receipt-lines {
  margin: 0;
  padding: 0;
  list-style: none;
}

.receipt-lines li,
.receipt-total {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin: 0;
  padding: 12px 0;
  border-top: 1px solid var(--line);
  font-variant-numeric: tabular-nums;
}

.receipt-total { font-weight: 560; }

.light {
  width: min(1080px, calc(100vw - 20px));
  height: min(92vh, 1280px);
  max-width: none;
  max-height: none;
  margin: auto;
  padding: 0;
  border: 0;
  background: #111;
  color: var(--paper);
}

.light::backdrop { background: rgba(19, 21, 20, .84); }

.light-stage {
  margin: 0;
  height: 100%;
  overflow: auto;
}

.light-zoom {
  display: block;
  width: 100%;
  min-height: 100%;
  padding: 48px 56px;
  border: 0;
  background: transparent;
  cursor: zoom-in;
}

.light-zoom img {
  width: 100%;
  height: auto;
  max-height: calc(92vh - 96px);
  margin: 0 auto;
  object-fit: contain;
}

.light.is-zoomed .light-zoom { cursor: zoom-out; }

.light.is-zoomed .light-zoom img {
  width: 175%;
  max-width: none;
  max-height: none;
}

.light-close,
.light-nav {
  position: absolute;
  z-index: 2;
  border: 0;
  background: transparent;
  color: var(--paper);
  font-size: 11px;
  font-weight: 650;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.light-close { top: 12px; right: 14px; }

.light-prev { top: 50%; left: 8px; }

.light-next { top: 50%; right: 8px; }

@media (max-width: 800px) {
  .bar {
    grid-template-columns: 1fr auto;
    grid-template-areas: "brand bag" "drop drop";
    min-height: 0;
    padding-top: 14px;
    padding-bottom: 12px;
    row-gap: 8px;
  }
  .brand { grid-area: brand; }
  .bag-open { grid-area: bag; }
  .drop { grid-area: drop; justify-self: start; }
  .brand img { width: 124px; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; padding: 8px; }
  .quick {
    position: static;
    opacity: 1;
    transform: none;
    pointer-events: auto;
    margin: -6px 0 16px;
  }
  .quick button { height: 32px; font-size: 11px; background: transparent; border: 1px solid #d4d4ce; }
  .light-zoom { padding: 48px 12px 16px; }
  .product { grid-template-columns: 1fr; gap: 8px; }
  .buy { position: static; padding-top: 8px; }
  .shop-foot { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .card-lead, .card-hover, .quick, .bag-panel, .stage img { transition: none; }
  .checkout.is-busy::after { animation: none; }
}
