:root {
  --bg: #fbfaf8;
  --surface: #ffffff;
  --ink: #17171b;
  --muted: #6b6b73;
  --line: #e7e3dc;
  --accent: #d9451f;
  --accent-soft: #fdeee9;
  --good: #1f7a4d;
  --warn: #8a6100;
  --warn-bg: #fff8e1;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(20,20,25,.05), 0 8px 24px rgba(20,20,25,.06);
  --max: 1180px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.6 ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI",
        Inter, Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* ---------------------------------------------------------------- banner */
.banner {
  background: var(--warn-bg);
  border-bottom: 1px solid #f0e2b8;
  color: var(--warn);
  font-size: 13.5px;
  padding: 9px 0;
  text-align: center;
}
.banner strong { font-weight: 650; }

/* ---------------------------------------------------------------- header */
.header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251,250,248,.88);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; gap: 28px;
  height: 66px;
}
.logo {
  font-size: 20px; font-weight: 750; letter-spacing: -.03em;
  display: flex; align-items: center; gap: 8px;
}
.logo-dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--accent); display: inline-block;
}
.nav { display: flex; gap: 22px; font-size: 14.5px; color: var(--muted); }
.nav a:hover { color: var(--ink); }
.spacer { flex: 1; }
.cart-btn {
  display: inline-flex; align-items: center; gap: 7px;
  border: 1px solid var(--line); background: var(--surface);
  padding: 8px 15px; border-radius: 999px; font-size: 14px; font-weight: 550;
}
.cart-btn:hover { border-color: var(--ink); }
.cart-badge {
  background: var(--accent); color: #fff; font-size: 11.5px; font-weight: 700;
  min-width: 19px; height: 19px; border-radius: 999px;
  display: inline-grid; place-items: center; padding: 0 5px;
}

/* ---------------------------------------------------------------- hero */
.hero { padding: 64px 0 40px; }
.hero h1 {
  font-size: clamp(34px, 5.2vw, 56px); line-height: 1.05;
  letter-spacing: -.035em; margin: 0 0 16px; font-weight: 780;
  max-width: 15ch;
}
.hero p { font-size: 18px; color: var(--muted); margin: 0 0 26px; max-width: 52ch; }
.hero-meta { display: flex; gap: 26px; flex-wrap: wrap; font-size: 13.5px; color: var(--muted); }
.hero-meta b { color: var(--ink); font-weight: 650; }

/* ---------------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--ink); color: #fff; border: 1px solid var(--ink);
  padding: 13px 24px; border-radius: 999px;
  font-size: 15px; font-weight: 600; cursor: pointer;
  transition: transform .06s ease, opacity .15s ease;
  font-family: inherit;
}
.btn:hover { opacity: .9; }
.btn:active { transform: translateY(1px); }
.btn-accent { background: var(--accent); border-color: var(--accent); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-block { width: 100%; }
.btn-lg { padding: 16px 30px; font-size: 16px; }

/* ---------------------------------------------------------------- sections */
.section { padding: 44px 0; }
.section-head {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-bottom: 24px; gap: 16px; flex-wrap: wrap;
}
.section-head h2 {
  font-size: 25px; letter-spacing: -.025em; margin: 0; font-weight: 720;
}
.section-head .sub { color: var(--muted); font-size: 14px; }

/* ---------------------------------------------------------------- grid */
.grid {
  display: grid; gap: 22px;
  grid-template-columns: repeat(auto-fill, minmax(232px, 1fr));
}

.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform .14s ease, box-shadow .14s ease, border-color .14s ease;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow); border-color: #d8d3ca;
}
.card-media { position: relative; aspect-ratio: 1/1; background: #f2efe9; }
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.card-body { padding: 14px 15px 16px; display: flex; flex-direction: column; flex: 1; }
.card-title {
  font-size: 15px; font-weight: 600; line-height: 1.35; margin: 0 0 4px;
  letter-spacing: -.01em;
  /* Reserve two lines whether the title needs them or not. Without this a
     one-line title sits beside a two-line one and the whole row goes ragged. */
  min-height: calc(2 * 1.35em);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
.card-cat { font-size: 12px; color: var(--muted); text-transform: capitalize; margin-bottom: 10px; }
.card-foot { margin-top: auto; display: flex; align-items: baseline; gap: 8px; }
.price { font-size: 17px; font-weight: 700; letter-spacing: -.02em; }
.compare { font-size: 13.5px; color: var(--muted); text-decoration: line-through; }

.badge {
  position: absolute; top: 10px; left: 10px;
  background: var(--ink); color: #fff;
  font-size: 11px; font-weight: 650; letter-spacing: .02em;
  padding: 5px 10px; border-radius: 999px;
}
.badge-hot { background: var(--accent); }
.badge-save {
  position: absolute; top: 10px; right: 10px; left: auto;
  background: var(--accent-soft); color: var(--accent);
}

/* ---------------------------------------------------------------- product */
.product { display: grid; grid-template-columns: 1.05fr 1fr; gap: 52px; padding: 44px 0; }
.product-media {
  border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--line); background: #f2efe9; aspect-ratio: 1/1;
}
.product-media img { width: 100%; height: 100%; object-fit: cover; }
.product h1 {
  font-size: clamp(27px, 3.4vw, 38px); letter-spacing: -.03em;
  line-height: 1.12; margin: 0 0 10px; font-weight: 760;
}
.product .hook { color: var(--muted); font-size: 17px; margin: 0 0 22px; }
.price-row { display: flex; align-items: baseline; gap: 12px; margin-bottom: 6px; }
.price-lg { font-size: 32px; font-weight: 760; letter-spacing: -.03em; }
.save-pill {
  background: var(--accent-soft); color: var(--accent);
  font-size: 12.5px; font-weight: 650; padding: 4px 10px; border-radius: 999px;
}
.ship-note { font-size: 14px; color: var(--muted); margin-bottom: 24px; }

.bullets { list-style: none; padding: 0; margin: 24px 0; }
.bullets li {
  padding: 9px 0 9px 27px; position: relative;
  border-bottom: 1px solid var(--line); font-size: 14.5px;
}
.bullets li:last-child { border-bottom: 0; }
.bullets li::before {
  content: "✓"; position: absolute; left: 2px; top: 9px;
  color: var(--good); font-weight: 700;
}

.trust-row {
  display: flex; gap: 18px; flex-wrap: wrap; margin-top: 20px;
  font-size: 13px; color: var(--muted);
}
.desc { white-space: pre-line; color: #35353c; font-size: 15px; margin-top: 26px; }

.qty {
  display: flex; align-items: center; gap: 0; border: 1px solid var(--line);
  border-radius: 999px; overflow: hidden; background: var(--surface);
}
.qty input {
  width: 52px; text-align: center; border: 0; font-size: 15px;
  font-family: inherit; padding: 12px 0; background: transparent;
}
.qty input:focus { outline: none; }
.buy-row { display: flex; gap: 12px; align-items: stretch; margin-top: 8px; }

/* ---------------------------------------------------------------- table */
.table { width: 100%; border-collapse: collapse; }
.table th {
  text-align: left; font-size: 12px; text-transform: uppercase;
  letter-spacing: .07em; color: var(--muted); font-weight: 600;
  padding: 0 0 12px; border-bottom: 1px solid var(--line);
}
.table td { padding: 16px 0; border-bottom: 1px solid var(--line); vertical-align: middle; }
.line-item { display: flex; gap: 14px; align-items: center; }
.line-thumb {
  width: 62px; height: 62px; border-radius: 10px; overflow: hidden;
  background: #f2efe9; flex-shrink: 0; border: 1px solid var(--line);
}

/* ---------------------------------------------------------------- layout aux */
.split { display: grid; grid-template-columns: 1.3fr .85fr; gap: 42px; align-items: start; }
.panel {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 24px;
}
.panel h3 { margin: 0 0 16px; font-size: 17px; letter-spacing: -.02em; }
.row { display: flex; justify-content: space-between; padding: 8px 0; font-size: 14.5px; }
.row.total {
  border-top: 1px solid var(--line); margin-top: 10px; padding-top: 15px;
  font-size: 18px; font-weight: 720;
}
.muted { color: var(--muted); }

/* ---------------------------------------------------------------- forms */
.field { margin-bottom: 15px; }
.field label {
  display: block; font-size: 13px; font-weight: 600;
  margin-bottom: 6px; color: #3a3a42;
}
.field input {
  width: 100%; padding: 12px 14px; font-size: 15px; font-family: inherit;
  border: 1px solid var(--line); border-radius: 10px; background: var(--surface);
  color: var(--ink);
}
.field input:focus {
  outline: none; border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(23,23,27,.07);
}
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.error {
  background: #fdeceb; border: 1px solid #f6c9c4; color: #9e2418;
  padding: 12px 15px; border-radius: 10px; font-size: 14px; margin-bottom: 18px;
}

/* Filenames like .env otherwise break across lines as ". env". */
code {
  white-space: nowrap;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: .92em;
  background: rgba(0, 0, 0, .05);
  padding: 1px 5px; border-radius: 4px;
}

/* ---------------------------------------------------------------- search */
.searchbar { display: flex; align-items: center; gap: 6px; margin-right: 14px; }
.searchbar input {
  width: 210px; padding: 8px 14px; font: inherit; font-size: 14px;
  border: 1px solid var(--line); border-radius: 999px;
  background: var(--surface); color: var(--ink);
}
.searchbar input:focus {
  outline: none; border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(23,23,27,.07);
}
.searchbar button {
  border: 0; background: transparent; color: var(--muted);
  font: inherit; font-size: 14px; cursor: pointer; padding: 8px 4px;
}
.searchbar button:hover { color: var(--ink); }
@media (max-width: 980px) { .searchbar input { width: 140px; } }

/* ---------------------------------------------------------------- pager */
.pager {
  display: flex; align-items: center; justify-content: center; gap: 14px;
  margin-top: 34px; padding-top: 24px; border-top: 1px solid var(--line);
}
.pager-state { font-size: 13.5px; color: var(--muted); }

/* ---------------------------------------------------------------- departments */
.departments { padding-top: 8px; }
.dept-grid {
  display: grid; gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}
.dept {
  position: relative; display: block; overflow: hidden;
  border-radius: var(--radius); aspect-ratio: 4/5;
  background: #f2efe9; border: 1px solid var(--line);
}
.dept img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .5s cubic-bezier(.2,.7,.3,1);
}
.dept:hover img { transform: scale(1.04); }
.dept-label {
  position: absolute; inset: auto 0 0 0; padding: 34px 18px 16px;
  display: flex; align-items: baseline; gap: 10px; color: #fff;
  /* A flat overlay washes the photograph out; a gradient keeps the product
     visible while still guaranteeing the label is legible over it. */
  background: linear-gradient(to top, rgba(12,12,14,.78), rgba(12,12,14,0));
}
.dept-name { font-size: 19px; font-weight: 680; letter-spacing: -.02em; }
.dept-count { font-size: 12.5px; opacity: .82; }

/* ---------------------------------------------------------------- gallery */
.gallery { display: flex; flex-direction: column; gap: 12px; }
.thumbs { display: flex; gap: 10px; flex-wrap: wrap; }
.thumb {
  width: 72px; height: 72px; padding: 0; cursor: pointer;
  border: 1px solid var(--line); border-radius: 10px; overflow: hidden;
  background: var(--surface); transition: border-color .12s ease;
}
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb:hover { border-color: var(--muted); }
.thumb.on { border-color: var(--ink); box-shadow: 0 0 0 2px rgba(23,23,27,.09); }

/* ---------------------------------------------------------------- options */
.buy-form { margin-top: 8px; }
.options { margin-bottom: 18px; }
.options-head {
  display: flex; justify-content: space-between; align-items: baseline;
  font-size: 13px; font-weight: 600; margin-bottom: 9px;
}
.options-count { color: var(--muted); font-weight: 400; }
.option-list { display: flex; flex-wrap: wrap; gap: 8px; }
.option input { position: absolute; opacity: 0; pointer-events: none; }
.option span {
  display: inline-block; cursor: pointer;
  border: 1px solid var(--line); background: var(--surface);
  padding: 8px 14px; border-radius: 999px; font-size: 13.5px;
  transition: border-color .12s ease, background .12s ease;
}
.option span:hover { border-color: var(--muted); }
.option input:checked + span {
  border-color: var(--ink); background: var(--ink); color: #fff;
}
/* Keyboard users need to see focus even though the radio itself is hidden. */
.option input:focus-visible + span { box-shadow: 0 0 0 3px rgba(23,23,27,.18); }

/* ---------------------------------------------------------------- specs */
.specs {
  margin: 22px 0 0; padding: 0;
  border-top: 1px solid var(--line);
}
.spec {
  display: flex; gap: 16px; padding: 11px 0;
  border-bottom: 1px solid var(--line); font-size: 14.5px;
}
.spec dt { color: var(--muted); min-width: 130px; margin: 0; }
.spec dd { margin: 0; color: var(--ink); font-weight: 550; }

/* ---------------------------------------------------------------- reviews */
.review-list { display: grid; gap: 16px; max-width: 760px; }
.review {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px 20px;
}
.review-head {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  margin-bottom: 8px; font-size: 13.5px;
}
.review-score { color: var(--accent); letter-spacing: 1px; }
.review-score .dim { color: var(--line); }
.review-who { color: var(--muted); }
.review-tag {
  background: #e8f5ee; color: var(--good);
  font-size: 11.5px; font-weight: 650;
  padding: 3px 9px; border-radius: 999px;
}
/* A supplier review is real but is not our customer, and must not wear the
   same badge as somebody who actually bought from this store. */
.review-tag.muted-tag { background: rgba(0,0,0,.05); color: var(--muted); }
.review-body { margin: 0; font-size: 14.5px; color: #35353c; }

/* ---------------------------------------------------------------- misc */
.empty { text-align: center; padding: 80px 20px; }
.empty h2 { font-size: 24px; letter-spacing: -.02em; margin: 0 0 10px; }
.empty p { color: var(--muted); margin: 0 0 24px; }

.sortbar { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  border: 1px solid var(--line); background: var(--surface);
  padding: 7px 15px; border-radius: 999px; font-size: 13.5px; color: var(--muted);
}
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip.on { background: var(--ink); color: #fff; border-color: var(--ink); }

.success-icon {
  width: 62px; height: 62px; border-radius: 50%;
  background: #e8f5ee; color: var(--good);
  display: grid; place-items: center; font-size: 30px; margin: 0 auto 20px;
}

.footer {
  border-top: 1px solid var(--line); margin-top: 72px;
  padding: 44px 0 30px; font-size: 13.5px; color: var(--muted);
}
.footer-inner { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.footer a:hover { color: var(--ink); }
.footer-cols {
  display: grid; gap: 30px;
  grid-template-columns: 1.6fr repeat(3, 1fr);
}
.footer-col { display: flex; flex-direction: column; gap: 9px; }
.footer-col h4 {
  margin: 0 0 2px; font-size: 12px; letter-spacing: .07em;
  text-transform: uppercase; color: var(--ink); font-weight: 650;
}
.footer-brand {
  font-size: 17px; font-weight: 720; color: var(--ink);
  letter-spacing: -.02em; margin-bottom: 4px;
}
.footer-note { margin: 0; max-width: 34ch; line-height: 1.6; }
.footer-base {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  margin-top: 34px; padding-top: 20px; border-top: 1px solid var(--line);
}
@media (max-width: 780px) {
  .footer-cols { grid-template-columns: 1fr 1fr; }
}

/* ---------------------------------------------------------------- prose */
.prose { max-width: 68ch; }
.prose h1 { font-size: clamp(28px, 4vw, 38px); letter-spacing: -.03em; margin: 0 0 8px; }
.prose-lead { font-size: 17px; color: var(--muted); margin: 0 0 28px; }
.prose h2 {
  font-size: 18px; letter-spacing: -.02em; margin: 32px 0 10px;
  padding-top: 22px; border-top: 1px solid var(--line);
}
.prose p { margin: 0 0 14px; font-size: 15.5px; line-height: 1.68; color: #35353c; }
.prose ul { margin: 0 0 16px; padding-left: 20px; }
.prose li { margin-bottom: 9px; font-size: 15.5px; line-height: 1.6; color: #35353c; }

@media (max-width: 860px) {
  .product { grid-template-columns: 1fr; gap: 30px; }
  .split { grid-template-columns: 1fr; gap: 28px; }
  .nav { display: none; }
  .hero { padding: 40px 0 26px; }
}
