:root {
  --bg: #f4f1eb;
  --paper: #fffcf7;
  --ink: #1c1b19;
  --muted: #5f5a54;
  --line: #d9d2c8;
  --accent: #b56b3c;
  --accent-ink: #8a4d28;
  --disabled: #9a948c;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  color-scheme: light;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
}

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

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

a:hover {
  color: var(--accent-ink);
}

.wrap {
  width: min(1080px, calc(100% - 2rem));
  margin: 0 auto;
}

.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4rem;
}

.wordmark {
  font-weight: 700;
  letter-spacing: 0.04em;
  font-size: 1.15rem;
}

.nav {
  display: flex;
  gap: 1.25rem;
  font-size: 0.95rem;
}

.nav a[aria-current="page"] {
  color: var(--accent-ink);
  border-bottom: 2px solid var(--accent);
}

main {
  flex: 1;
  padding: 2rem 0 3rem;
}

h1 {
  font-size: 1.75rem;
  font-weight: 650;
  letter-spacing: -0.02em;
  margin: 0 0 1.25rem;
}

h2 {
  font-size: 1.15rem;
  font-weight: 650;
  margin: 0 0 0.25rem;
}

.lede {
  color: var(--muted);
  margin: -0.5rem 0 1.5rem;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.25rem;
}

.product-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.product-card a {
  display: block;
  color: inherit;
}

.product-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background: #ece7df;
}

.product-card .meta {
  padding: 0.9rem 1rem 1.1rem;
}

.product-card .category {
  margin: 0;
  color: var(--muted);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.product-card .price {
  margin: 0.35rem 0 0;
  font-weight: 600;
}

.product-card.featured {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
}

.product-card.featured img {
  aspect-ratio: 4 / 3;
}

.product-card.featured .meta {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 1.5rem;
}

.product-card.featured h2 {
  font-size: 1.6rem;
}

.pdp {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 2rem;
  align-items: start;
}

.gallery {
  display: grid;
  gap: 0.75rem;
}

.gallery .hero {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.gallery .hero img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.thumbs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(72px, 1fr));
  gap: 0.5rem;
}

.thumbs img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
}

.facts {
  margin: 0 0 1.25rem;
  padding-left: 1.15rem;
  color: var(--ink);
}

.facts li + li {
  margin-top: 0.4rem;
}

.price-line {
  font-size: 1.2rem;
  font-weight: 650;
  margin: 0 0 1rem;
}

.buy,
a.buy {
  display: inline-block;
  border: 0;
  border-radius: 8px;
  padding: 0.7rem 1.1rem;
  font: inherit;
  font-weight: 650;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
}

a.buy:hover {
  color: #fff;
  filter: brightness(0.95);
}

.buy:disabled,
.buy[aria-disabled="true"] {
  background: var(--disabled);
  cursor: not-allowed;
}

.crumb {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 0 0 0.75rem;
}

.crumb a:hover {
  color: var(--accent-ink);
}

.not-found {
  text-align: center;
  padding: 3rem 0;
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 1.25rem 0;
  color: var(--muted);
  font-size: 0.9rem;
  background: var(--paper);
}

.empty {
  color: var(--muted);
}

@media (max-width: 720px) {
  .site-header .wrap {
    flex-wrap: wrap;
    padding: 0.75rem 0;
  }

  .product-card.featured,
  .pdp {
    grid-template-columns: 1fr;
  }

  .thumbs {
    grid-template-columns: repeat(3, 1fr);
  }
}

.colors {
  border: 0;
  margin: 0 0 1.25rem;
  padding: 0;
}

.colors legend {
  font-weight: 650;
  margin-bottom: 0.4rem;
}

.colors label {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-right: 1rem;
  cursor: pointer;
}

.thumbs .thumb {
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  cursor: pointer;
  overflow: hidden;
}

.thumbs .thumb img {
  border: 0;
  border-radius: 0;
}

.thumbs .thumb:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.pdp .price {
  font-size: 1.2rem;
  font-weight: 650;
  margin: 0 0 1rem;
}

.sub {
  margin: -0.75rem 0 0.75rem;
  color: var(--muted);
  font-size: 1.05rem;
}
