:root {
  --cream: #f5f2ec;   /* bone: lighter + cooler than the tan pieces */
  --cream-2: #ebe7df;
  --ink: #1f1b16;
  --muted: #8b8072;
  --line: rgba(31, 27, 22, 0.12);
  --glass: rgba(255, 251, 244, 0.5);
  --glass-edge: rgba(255, 255, 255, 0.65);
  --r: 20px;
  --pill: 999px;
  --pad: clamp(16px, 3vw, 40px);
  /* Yeezy's settle curve: fast start, soft landing */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --font: "Helvetica Neue", Helvetica, Arial, sans-serif;
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--cream);
  font-size: 11px;
  letter-spacing: 0.04em;
  text-transform: lowercase;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
button, input { font: inherit; letter-spacing: inherit; color: inherit; text-transform: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; -webkit-tap-highlight-color: transparent; }
img { display: block; max-width: 100%; }

/* ── Background: cream gradient + grain (after Skylrk) ──── */
.bg {
  position: fixed; inset: 0; z-index: -2; overflow: hidden;
  background: radial-gradient(130% 100% at 50% 0%, #faf8f4 0%, var(--cream) 50%, var(--cream-2) 100%);
}
.bg span { position: absolute; border-radius: 50%; filter: blur(100px); animation: drift 32s ease-in-out infinite alternate; }
.bg span:nth-child(1) { width: 60vw; height: 60vw; left: -20vw; top: 25vh; background: #e4ddd2; opacity: .55; }
.bg span:nth-child(2) { width: 46vw; height: 46vw; right: -12vw; top: -14vh; background: #ffffff; opacity: .9; animation-delay: -11s; }
.bg span:nth-child(3) { width: 52vw; height: 40vw; right: 4vw; bottom: -22vh; background: #dcd6cc; opacity: .45; animation-delay: -21s; }
@keyframes drift { to { transform: translate3d(7vw, -5vh, 0) scale(1.1); } }
.grain { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -1; opacity: .14; mix-blend-mode: multiply; pointer-events: none; }
@media (prefers-reduced-motion: reduce) { .bg span { animation: none; } }

.glass, .pill {
  background: var(--glass); border: 1px solid var(--glass-edge);
  backdrop-filter: blur(16px) saturate(1.1); -webkit-backdrop-filter: blur(16px) saturate(1.1);
}
.pill { border-radius: var(--pill); }

/* ── Header ─────────────────────────────────────────────── */
.top {
  position: sticky; top: 0; z-index: 20;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  padding: 14px var(--pad);
}
.left { display: flex; align-items: center; }
.mark { font-weight: 700; font-size: 13px; letter-spacing: .38em; padding: 10px 18px 10px calc(18px + .38em); }
.cart-btn { justify-self: end; display: flex; align-items: center; gap: 7px; height: 38px; padding: 0 15px; }
.cart-btn.bump { animation: bump .35s var(--ease); }
@keyframes bump { 40% { transform: scale(1.1); } }

/* Viewfinder toggle: corners sit tight on the 6-col grid, spread out when zoomed to 3 */
.toggle { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; transition: transform .15s var(--ease); }
.toggle .c { transition: transform .22s var(--ease); }
.toggle .tl { transform: translate(1.5px, 1.5px); }
.toggle .tr { transform: translate(-1.5px, 1.5px); }
.toggle .bl { transform: translate(1.5px, -1.5px); }
.toggle .br { transform: translate(-1.5px, -1.5px); }
body.big .toggle .c { transform: translate(0, 0); }
body.big .toggle .tl { transform: translate(-1px, -1px); }
body.big .toggle .tr { transform: translate(1px, -1px); }
body.big .toggle .bl { transform: translate(-1px, 1px); }
body.big .toggle .br { transform: translate(1px, 1px); }
.toggle:hover { background: rgba(255, 255, 255, .85); }
.toggle:active { transform: scale(.9); }
.back-btn { display: none; width: 38px; height: 38px; place-items: center; font-size: 26px; line-height: 1; margin-top: -3px; }
body.on-pdp .toggle { display: none; }
body.on-pdp .back-btn { display: grid; }

/* ── Grid ───────────────────────────────────────────────── */
main { padding: 6px var(--pad) 40px; min-height: 72vh; }
.grid {
  display: grid; grid-template-columns: repeat(var(--cols, 6), minmax(0, 1fr));
  column-gap: clamp(8px, 2vw, 32px); row-gap: clamp(16px, 3vw, 40px);
}
body.big .grid { --cols: 3; }
@media (max-width: 760px) {
  .grid { --cols: 3; }
  body.big .grid { --cols: 2; }
}

.item { display: block; animation: rise .5s var(--ease) both; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }
.item-img { aspect-ratio: 1 / 1; display: grid; place-items: center; padding: 8%; }
.item-img img {
  width: 100%; height: 100%; object-fit: contain;
  transition: transform .2s var(--ease);
}
.item:hover .item-img img { transform: scale(1.05); }
.item:active .item-img img { transform: scale(.98); }
.item-meta { display: grid; gap: 4px; justify-items: center; padding-top: 6px; text-align: center; }
.item-meta span:last-child { color: var(--muted); }
/* The "settle" after a column switch: starts the same frame as the click */
.grid.settle .item-img img { animation: settle .22s var(--ease); }
@keyframes settle { from { transform: scale(.94); opacity: .6; } }

/* ── Product page (centered, after Yeezy) ───────────────── */
.pdp { max-width: 980px; margin: 0 auto; display: grid; justify-items: center; gap: 26px; animation: rise .4s var(--ease) both; }
.carousel { position: relative; width: 100%; }
.viewport { overflow: hidden; width: min(560px, 78vw); margin: 0 auto; }
.track { display: flex; transition: transform .45s var(--ease); touch-action: pan-y; }
.slide { flex: 0 0 100%; aspect-ratio: 1 / 1; display: grid; place-items: center; padding: 6%; cursor: zoom-in; }
.slide img { width: 100%; height: 100%; object-fit: contain; user-select: none; -webkit-user-drag: none; }
.arrow { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; }
.arrow:active { scale: .9; }
.arrow.prev { left: 0; } .arrow.next { right: 0; }
.dots { display: flex; justify-content: center; gap: 6px; margin-top: 4px; }
.dots button { width: 5px; height: 5px; border-radius: 3px; background: var(--ink); opacity: .2; transition: opacity .2s, width .2s var(--ease); }
.dots button.on { opacity: .75; width: 16px; }

.info { width: min(380px, 100%); display: grid; gap: 18px; text-align: center; }
.info h1 { margin: 0; font-size: 13px; font-weight: 700; letter-spacing: .12em; }
.info .kind { color: var(--muted); margin-top: 6px; }
.measure { display: grid; grid-template-columns: 1fr 1fr; border-radius: var(--r); overflow: hidden; }
.measure div { padding: 14px 10px; display: grid; gap: 6px; }
.measure div + div { border-left: 1px solid var(--line); }
.measure span:first-child { color: var(--muted); font-size: 10px; }
.measure span:last-child { font-size: 15px; letter-spacing: .02em; }
.price { font-size: 13px; }
.details { text-align: left; border-top: 1px solid var(--line); }
.details summary { list-style: none; cursor: pointer; padding: 14px 0; text-align: center; }
.details summary::-webkit-details-marker { display: none; }
.details p { margin: 0 0 14px; line-height: 1.8; color: #5a5146; text-align: center; }

.btn {
  display: flex; align-items: center; justify-content: center; height: 46px; padding: 0 22px;
  border-radius: var(--pill); background: var(--ink); color: var(--cream); font-weight: 500;
  transition: opacity .15s, transform .15s var(--ease);
}
.btn:hover { opacity: .88; }
.btn:active { transform: scale(.98); }
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid rgba(31,27,22,.35); }
.btn.disabled { opacity: .35; pointer-events: none; }

/* ── Footer / email ─────────────────────────────────────── */
.foot { padding: 70px var(--pad) 26px; display: grid; gap: 46px; justify-items: center; }
.signup { width: min(440px, 100%); display: grid; gap: 12px; text-align: center; }
.signup-row { display: flex; padding: 4px; }
.signup input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 0 16px; outline: none; }
.signup input::placeholder { color: var(--muted); }
.signup button { height: 38px; padding: 0 20px; border-radius: var(--pill); background: var(--ink); color: var(--cream); }
.signup-msg { margin: 0; min-height: 1em; color: var(--muted); }
.foot-meta { width: 100%; display: flex; justify-content: space-between; color: var(--muted); font-size: 10px; }

/* ── Cart drawer ────────────────────────────────────────── */
.scrim { position: fixed; inset: 0; background: rgba(31, 27, 22, .14); opacity: 0; pointer-events: none; transition: opacity .25s; z-index: 40; }
.drawer {
  position: fixed; top: 10px; right: 10px; bottom: 10px; width: min(380px, calc(100vw - 20px)); z-index: 41;
  display: flex; flex-direction: column; border-radius: calc(var(--r) + 4px);
  background: rgba(248, 243, 235, .82); box-shadow: 0 30px 80px rgba(40, 28, 14, .16);
  transform: translateX(calc(100% + 20px)); transition: transform .35s var(--ease);
}
body.cart-open .scrim { opacity: 1; pointer-events: auto; }
body.cart-open .drawer { transform: none; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; padding: 18px 20px; }
.x { width: 32px; height: 32px; border-radius: 50%; font-size: 18px; line-height: 1; display: grid; place-items: center; background: rgba(255,255,255,.6); }
.drawer-items { flex: 1; overflow: auto; padding: 0 20px; display: grid; align-content: start; gap: 8px; }
.empty { color: var(--muted); padding: 40px 0; text-align: center; }
.line { display: grid; grid-template-columns: 64px 1fr auto; gap: 14px; align-items: center; padding: 8px; border-radius: 16px; background: rgba(255,255,255,.45); }
.line img { width: 64px; height: 64px; object-fit: contain; padding: 4px; }
.line small { display: block; color: var(--muted); margin-top: 4px; font-size: 10px; }
.line .rm { color: var(--muted); font-size: 16px; padding: 6px; }
.drawer-foot { padding: 16px 20px 20px; display: grid; gap: 14px; border-top: 1px solid var(--line); }
.total { display: flex; justify-content: space-between; font-size: 12px; }
.note { color: var(--muted); font-size: 10px; text-align: center; margin: -4px 0 0; }

/* ── Zoom ───────────────────────────────────────────────── */
.zoom {
  position: fixed; inset: 0; z-index: 60; background: rgba(245, 242, 236, .94);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  opacity: 0; pointer-events: none; transition: opacity .2s;
}
.zoom.open { opacity: 1; pointer-events: auto; }
.zoom .x { position: absolute; top: 16px; right: 16px; z-index: 2; }
.zoom-stage { width: 100%; height: 100%; overflow: hidden; display: grid; place-items: center; cursor: zoom-in; touch-action: none; }
.zoom-stage img {
  max-width: 88vw; max-height: 88vh; object-fit: contain; transform: scale(.96);
  transition: transform .3s var(--ease); user-select: none; -webkit-user-drag: none;
}
.zoom.open .zoom-stage img { transform: scale(1); }
.zoom-stage.deep { cursor: zoom-out; }
.zoom-stage.deep img { transition: transform .08s linear; }

/* ── Cookie banner ──────────────────────────────────────── */
.cookie {
  position: fixed; left: 14px; bottom: 14px; z-index: 50; width: min(340px, calc(100vw - 28px));
  padding: 18px; border-radius: calc(var(--r) + 2px); display: grid; gap: 14px;
  background: rgba(250, 246, 239, .7); box-shadow: 0 20px 60px rgba(40, 28, 14, .12);
  animation: rise .4s var(--ease) .5s both;
}
.cookie p { margin: 0; line-height: 1.7; color: #4f473d; font-size: 10px; }
.cookie-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.cookie .btn { height: 38px; font-size: 10px; }

:focus-visible { outline: 1.5px solid var(--ink); outline-offset: 3px; border-radius: 6px; }

/* ── Filter ─────────────────────────────────────────────── */
.filter { display: flex; justify-content: center; gap: 18px; padding: 2px 0 22px; }
.filter button { color: var(--muted); padding: 4px 0; transition: color .15s; }
.filter button.on { color: var(--ink); box-shadow: inset 0 -1px 0 var(--ink); }
.filter button:hover { color: var(--ink); }

/* ── Sold ───────────────────────────────────────────────── */
.item.sold .item-img img { opacity: .42; filter: grayscale(.4); }
.item.sold .item-meta { color: var(--muted); }

/* ── PDP fits one screen; scroll steps pieces ───────────── */
body.on-pdp { overflow: hidden; height: 100svh; }
body.on-pdp .foot { display: none; }
body.on-pdp main { padding-top: 0; padding-bottom: 0; height: calc(100svh - 66px); display: grid; align-items: center; }
.pdp { gap: 14px; position: relative; }
.viewport { width: min(500px, 80vw, calc(100svh - 430px)); min-width: 200px; }
.info { gap: 14px; }
.desc { margin: 0; line-height: 1.7; color: #5a5146; text-transform: none; letter-spacing: .02em; font-size: 12px; }
.thanks { margin: 0; color: var(--muted); padding: 14px 0; }
.pdp .signup-row input { padding: 0 16px; border: 0; background: transparent; outline: none; flex: 1; min-width: 0; }
.pdp .signup-row button { height: 38px; padding: 0 20px; border-radius: var(--pill); background: var(--ink); color: var(--cream); }
.pager { position: fixed; right: var(--pad); bottom: 22px; color: var(--muted); font-size: 10px; }
.pdp.from-below { animation: fromBelow .3s var(--ease) both; }
.pdp.from-above { animation: fromAbove .3s var(--ease) both; }
@keyframes fromBelow { from { opacity: 0; transform: translateY(28px); } }
@keyframes fromAbove { from { opacity: 0; transform: translateY(-28px); } }
@media (max-width: 760px) {
  .viewport { width: min(80vw, calc(100svh - 420px)); }
  .arrow { display: none; }
  .pager { display: none; }
}
.cookie[hidden] { display: none; }

/* Compact add button (smaller than the full-width version) */
.btn.small { height: 36px; padding: 0 20px; font-size: 10px; justify-self: center; min-width: 150px; }
.btn.small.added { background: transparent; color: var(--ink); border: 1px solid rgba(31,27,22,.3); }
.info .kind { letter-spacing: .14em; }
.note { margin: 0; }

/* Photo arrows sit outside the image; up/down pieces on the right edge */
.carousel { display: flex; align-items: center; justify-content: center; gap: clamp(14px, 6vw, 90px); }
.viewport { margin: 0; }
.arrow { position: static; translate: none; flex: none; width: 46px; height: 46px; font-size: 0; transition: background .15s, transform .15s var(--ease); }
.arrow:hover, .vnav button:hover { background: rgba(255, 255, 255, .85); }
.arrow:active, .vnav button:active { transform: scale(.92); }
.vnav { position: fixed; right: var(--pad); top: 50%; translate: 0 -50%; display: grid; gap: 8px; z-index: 5; }
.vnav button { width: 46px; height: 46px; display: grid; place-items: center; transition: background .15s, transform .15s var(--ease); }
@media (max-width: 760px) {
  .arrow { display: grid; place-items: center; width: 36px; height: 36px; }
  .carousel { gap: 6px; }
  .viewport { width: min(68vw, calc(100svh - 420px)); }
  .vnav { top: auto; bottom: 18px; translate: none; right: 14px; }
  .vnav button { width: 38px; height: 38px; }
}

.item-img, .slide { position: relative; }
.fig { position: relative; height: 100%; width: 100%; display: grid; place-items: center; }
.fig img { width: 100%; height: 100%; object-fit: contain; }

/* Measurement slide: hairlines + tiny numbers */
.measure-slide .fig { width: 80%; height: 80%; margin-bottom: 6%; }
.dimlines { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.dimlines line { stroke: var(--ink); stroke-width: 1; vector-effect: non-scaling-stroke; opacity: .55; }
.dim { position: absolute; translate: -50% -50%; font-size: 11px; padding: 2px 6px; border-radius: 999px; background: rgba(245, 242, 236, .9); }
.dim-b { translate: -50% -50%; }

/* Quiet measurements, set like a price tag */
.dims { color: var(--muted); font-size: 11px; letter-spacing: .08em; margin-top: 6px; }
.info { gap: 16px; }

/* Lighter add button */
.btn.small { height: 32px; padding: 0 18px; min-width: 128px; font-weight: 400; letter-spacing: .1em; }

/* Back button matches the round frosted controls */
.back-btn { width: 38px; height: 38px; border-radius: 50%; font-size: 0; margin-top: 0; transition: background .15s, transform .15s var(--ease); }
.back-btn:hover { background: rgba(255, 255, 255, .85); }
.back-btn:active { transform: scale(.92); }

/* all lowercase: wordmark tracking tuned for lowercase letters */
.mark { letter-spacing: .2em; padding: 10px 18px 10px calc(18px + .2em); font-size: 14px; }
.info h1 { letter-spacing: .08em; }

/* 1:11 reservation: one quiet line under the cart pieces */
.hold { margin: 6px 0 0; text-align: center; color: var(--muted); font-size: 10px; }
.hold b { font-weight: 500; color: var(--ink); font-variant-numeric: tabular-nums; }
.hold.low b { color: #a2552f; }

/* Lock every grid photo inside the same square so labels line up, whatever the photo's shape */
.item-img { position: relative; padding: 0; }
.item-img img { position: absolute; inset: 8%; width: 84%; height: 84%; object-fit: contain; }

/* ── Type, with numbers tuned to sit with lowercase letters ──
   Syne (current):           font "Syne"          · text 450 · numbers .85 · boost 50 · one weight for all text
   Space Grotesk (saved):    font "Space Grotesk" · text 300 · numbers .72 · boost 100 · product no. = text
   To switch, swap the four values below.                                         */
:root {
  --font: "Syne", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --text-w: 450;      /* weight of regular text */
  --num-size: .85;    /* numbers as a fraction of the text size */
  --num-boost: 50;    /* extra weight on numbers so shrunk digits don't look thinner */
}
body { --w: var(--text-w); font-weight: var(--w); letter-spacing: .02em; }
.n { font-size: calc(var(--num-size) * 1em); font-weight: calc(var(--w) + var(--num-boost)); }
.mark { font-weight: 700; letter-spacing: .12em; padding: 10px 18px 10px calc(18px + .12em); font-size: 15px; }
.info h1 { --w: 600; font-weight: var(--w); letter-spacing: .04em; }
.hold b { --w: calc(var(--text-w) + 100); font-weight: var(--w); }
.cart-btn span { --w: 500; font-weight: 500; }

/* ── Type scale, raised so shrunk numbers stay readable (numbers = text × --num-size) ── */
body { font-size: 13px; }                         /* grid labels, filter, cart, footer */
.mark { font-size: 17px; }
.info h1 { font-size: 17px; }
.dims, .hold, .line small, .signup-msg, .note { font-size: 12px; }
.foot-meta, .cookie p, .cookie .btn { font-size: 11px; }
.btn.small { font-size: 12px; height: 34px; }
.total { font-size: 14px; }
.dim { font-size: 12px; }
@media (max-width: 760px) { body { font-size: 12px; } }

/* One weight for all text (Syne widens as it gets bolder, so mixed weights read as mixed fonts).
   Hierarchy comes from size; only the "dariz" wordmark is heavier. */
.info h1, .hold b, .cart-btn span { --w: var(--text-w); font-weight: var(--w); }
.btn, .btn.small, .signup button { font-weight: var(--text-w); }
.n { letter-spacing: .04em; }  /* a little air so the smaller, heavier digits don't crowd */

/* Cart count sits inside a thin ring that drains over the 1:11 hold */
.count-ring { position: relative; display: grid; place-items: center; width: 22px; height: 22px; }
.count-ring svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.count-ring circle { fill: none; stroke-width: 1.2; }
.count-ring .track { stroke: transparent; }
.count-ring .left { stroke: var(--ink); stroke-dasharray: 100; stroke-dashoffset: 100; stroke-linecap: round; transition: stroke-dashoffset .25s linear; opacity: 0; }
.cart-btn.holding .count-ring .track { stroke: rgba(31, 27, 22, .12); }
.cart-btn.holding .count-ring .left { opacity: .85; }
.cart-btn.low .count-ring .left { stroke: #a2552f; }
#cartCount { font-size: 11px; line-height: 1; }

/* Countdown inside the "in cart" button */
.held { font-weight: inherit; font-variant-numeric: tabular-nums; }
.held.low { color: #a2552f; }
.add.added { gap: .4em; }

/* Ring around the cart count drains in the flowing hold color */
.count-ring .left { stroke: var(--hold, var(--ink)); }
.cart-btn.low .count-ring .left { stroke: var(--hold, var(--ink)); }
.held, .held.low, #hold b, .hold.low b { color: var(--hold, var(--ink)); }
