/* Shop Sandbox: catalog grid, product page, homepage merch teaser. Uses the tokens in site.css. */

.chips { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 10px; margin: 0 -2px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: 0 0 auto; min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1.5px solid #d9cdb8;
  background: var(--white); color: var(--ink); font: 600 .95rem var(--font); cursor: pointer; white-space: nowrap;
}
.chip:hover { border-color: var(--gold); }
.chip[aria-pressed="true"] { background: var(--black); border-color: var(--black); color: var(--white); }
.shop-count { color: var(--muted); font-size: .9rem; margin: 6px 0 16px; }

.product-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
@media (min-width: 640px) { .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; } }
@media (min-width: 1000px) { .product-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; } }
.product-grid--row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 860px) { .product-grid--row { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.product-card[hidden] { display: none; }
.product-card a { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: inherit; border-radius: var(--radius); }
.product-card a:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.product-img { aspect-ratio: 1; background: #f3efe8; border-radius: var(--radius); overflow: hidden; position: relative; }
.img-failed { position: relative; }
.img-failed img { opacity: 0; }
.img-failed::after { content: "Photo unavailable right now"; position: absolute; inset: 0; display: grid; place-items: center; padding: 12px; text-align: center; font-size: .85rem; color: #6b5a4a; }
.product-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s var(--ease); }
.product-card a:hover .product-img img { transform: scale(1.035); }
.product-meta { padding: 10px 2px 0; display: flex; flex-direction: column; gap: 2px; }
.product-name { font-size: .95rem; font-weight: 600; line-height: 1.3; margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.product-price { font-weight: 800; font-size: 1rem; }
.swatch-dots { display: flex; gap: 4px; align-items: center; margin-top: 4px; }
.swatch-dots span { width: 12px; height: 12px; border-radius: 50%; border: 1px solid rgba(0, 0, 0, .2); }
.swatch-dots small { font-size: .75rem; color: var(--muted); margin-left: 2px; }

.shop-info { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 48px; padding-top: 32px; border-top: 1px solid #ece6dc; }
.shop-info h2 { font-size: 1.05rem; margin-bottom: .35em; }
.shop-info p { color: var(--muted); font-size: .95rem; margin: 0; }
@media (max-width: 760px) { .shop-info { grid-template-columns: 1fr; } }

/* Product page */
.crumbs { display: flex; gap: 8px; font-size: .9rem; padding-top: 16px; color: var(--muted); }
.crumbs { align-items: center; }
.crumbs a { color: var(--muted); text-decoration: none; font-weight: 600; display: inline-block; padding: 6px 0; }
.crumbs a:hover { color: var(--gold-dark); text-decoration: underline; }
.pdp { padding-top: 12px; }
.pdp-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: clamp(20px, 4vw, 56px); align-items: start; }
@media (max-width: 860px) { .pdp-grid { grid-template-columns: minmax(0, 1fr); } }
.gallery-wrap { position: sticky; top: calc(var(--header-h) + 16px); min-width: 0; }
@media (max-width: 860px) { .gallery-wrap { position: static; margin: 0 calc(var(--gutter) * -1); } }
.pdp-gallery {
  list-style: none; margin: 0; padding: 0; display: flex; overflow-x: auto; scroll-snap-type: x mandatory;
  border-radius: var(--radius); background: #f3efe8; scrollbar-width: none; overscroll-behavior-x: contain;
}
.pdp-gallery::-webkit-scrollbar { display: none; }
.pdp-gallery li { flex: 0 0 100%; scroll-snap-align: start; aspect-ratio: 1; }
.pdp-gallery img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 860px) { .pdp-gallery { border-radius: 0; } }
.pdp-thumbs { display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; scrollbar-width: none; padding: 2px; }
@media (max-width: 860px) { .pdp-thumbs { padding: 2px var(--gutter); } }
.pdp-thumbs button { flex: 0 0 64px; height: 64px; padding: 0; border: 2px solid transparent; border-radius: 10px; overflow: hidden; background: #f3efe8; cursor: pointer; }
.pdp-thumbs button[aria-current="true"] { border-color: var(--black); }
.pdp-thumbs img { width: 100%; height: 100%; object-fit: cover; }
.pdp-info h1 { font-size: clamp(1.6rem, 4vw, 2.3rem); margin-bottom: .3em; }
.pdp-price { font-size: 1.4rem; font-weight: 800; margin-bottom: 18px; }
.opt { border: 0; padding: 0; margin: 0 0 18px; min-width: 0; }
.opt legend { font-weight: 700; margin-bottom: 8px; padding: 0; }
.opt-chosen { font-weight: 500; color: var(--muted); }
.opt-values { display: flex; flex-wrap: wrap; gap: 8px; }
.opt input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.pill span {
  display: inline-flex; align-items: center; justify-content: center; min-width: 52px; min-height: 44px; padding: 0 14px;
  border: 1.5px solid #d9cdb8; border-radius: 10px; font-weight: 600; cursor: pointer; background: var(--white);
}
.pill input:checked + span { background: var(--black); color: var(--white); border-color: var(--black); }
.swatch { display: inline-flex; width: 44px; height: 44px; border-radius: 50%; padding: 3px; border: 2px solid transparent; cursor: pointer; }
.swatch .sw { display: block; width: 100%; height: 100%; border-radius: 50%; border: 1px solid rgba(0, 0, 0, .2); }
.swatch:has(input:checked) { border-color: var(--black); }
.opt input:focus-visible + span, .swatch:has(input:focus-visible) { outline: 3px solid var(--gold); outline-offset: 2px; }
.is-out span { opacity: .45; }
.pill.is-out span { text-decoration: line-through; }
.opt-single { margin: 0 0 12px; }
.pdp-status { min-height: 1.5em; margin: 0 0 8px; color: var(--muted); font-size: .92rem; }
.pdp-status.is-warn { color: #8a1c14; font-weight: 600; }
.size-table { overflow-x: auto; }
.size-table table { border-collapse: collapse; font-size: .88rem; min-width: 100%; }
.size-table th, .size-table td { padding: 6px 8px; border-bottom: 1px solid #ece6dc; text-align: left; white-space: nowrap; }
.size-table thead th { font-weight: 700; }
.pdp-more h3 { font-size: 1rem; margin: 14px 0 4px; }
.pdp-buy { width: 100%; min-height: 54px; font-size: 1.05rem; }
.pdp-buy[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
.pdp-note { font-size: .88rem; color: var(--muted); margin: 10px 0 20px; }
.pdp-more { border-top: 1px solid #ece6dc; }
.pdp-more:last-of-type { border-bottom: 1px solid #ece6dc; }
.pdp-more summary { cursor: pointer; font-weight: 700; padding: 14px 0; min-height: 44px; list-style: none; display: flex; justify-content: space-between; }
.pdp-more summary::-webkit-details-marker { display: none; }
.pdp-more summary::after { content: "+"; font-size: 1.3rem; line-height: 1; }
.pdp-more[open] summary::after { content: "−"; }
.pdp-more .prose { padding-bottom: 14px; font-size: .95rem; }
.pdp-more ul { padding-left: 1.2em; }

/* Homepage teaser */
.merch-teaser .lead { margin: 0; }

