:root {
  --shop-black: #111111;
  --shop-ink: #18191a;
  --shop-paper: #f4f0e8;
  --shop-paper-strong: #fffdf8;
  --shop-border: #d8d2c7;
  --shop-copper: #a46a3f;
  --shop-muted: #6f6a62;
  --shop-error: #9c2f24;
  --shop-success: #27643e;
}

.shop-main {
  min-height: 72vh;
  padding-top: 118px;
  background: var(--shop-paper);
}

.shop-shell {
  width: min(1240px, calc(100% - 48px));
  margin: 0 auto;
  padding: 64px 0 88px;
}

.shop-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 460px);
  gap: 48px;
  align-items: end;
  margin-bottom: 48px;
}

.shop-heading h1 {
  max-width: 780px;
  margin: 0;
  font-size: clamp(44px, 6vw, 82px);
}

.shop-heading p {
  margin: 0 0 8px;
  color: var(--shop-muted);
  font-size: 18px;
}

.shop-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 34px;
}

.filter-button {
  min-height: 42px;
  border: 1px solid var(--shop-border);
  border-radius: 6px;
  padding: 0 16px;
  background: transparent;
  color: var(--shop-ink);
  font-size: 14px;
}

.filter-button[aria-pressed="true"] {
  border-color: var(--shop-copper);
  background: var(--shop-copper);
  color: var(--shop-paper-strong);
}

.shop-product-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.shop-product-card {
  display: grid;
  grid-template-rows: 220px auto;
  overflow: hidden;
  border: 1px solid var(--shop-border);
  border-radius: 8px;
  background: var(--shop-paper-strong);
}

.shop-product-card figure {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 26px;
  background: #171817;
}

.shop-product-card img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.shop-product-copy {
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  padding: 26px;
}

.shop-product-copy .eyebrow {
  margin-bottom: 10px;
}

.shop-product-copy h2 {
  margin-bottom: 14px;
  font-size: 34px;
}

.shop-product-copy p {
  color: var(--shop-muted);
}

.shop-product-meta,
.shop-price-row,
.shop-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.shop-product-meta {
  margin: 6px 0 20px;
  color: var(--shop-muted);
  font-size: 14px;
}

.shop-product-meta span:not(:last-child)::after {
  content: "·";
  margin-left: 12px;
  color: var(--shop-copper);
}

.shop-price-row {
  justify-content: space-between;
  min-height: 52px;
  border-top: 1px solid var(--shop-border);
  padding-top: 18px;
}

.shop-price {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 28px;
}

.shop-status {
  color: var(--shop-muted);
  font-size: 14px;
}

.shop-status.success { color: var(--shop-success); }
.shop-status.error { color: var(--shop-error); }

.shop-link {
  color: var(--shop-copper);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

button.shop-link {
  display: inline;
  min-height: 0;
  border: 0;
  border-radius: 0;
  padding: 0;
  background: transparent;
  color: var(--shop-copper);
}

.shop-button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--shop-copper);
  border-radius: 6px;
  padding: 0 20px;
  background: var(--shop-copper);
  color: var(--shop-paper-strong);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.shop-button.secondary {
  background: transparent;
  color: var(--shop-ink);
}

.shop-button:disabled,
.shop-button[aria-disabled="true"] {
  border-color: #aaa69f;
  background: #aaa69f;
  color: #f8f6f1;
  cursor: not-allowed;
}

.shop-button:focus-visible,
.shop-link:focus-visible,
.filter-button:focus-visible,
.shop-field input:focus-visible,
.shop-field select:focus-visible,
.shop-field textarea:focus-visible {
  outline: 3px solid rgba(164, 106, 63, 0.32);
  outline-offset: 3px;
}

.product-commerce-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(360px, 0.85fr);
  gap: 56px;
  align-items: center;
}

.product-commerce-hero figure {
  min-height: 420px;
  margin: 0;
  padding: 50px;
  background: #161716;
}

.product-commerce-hero figure img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.product-commerce-copy h1 {
  margin-bottom: 18px;
  font-size: clamp(44px, 5vw, 72px);
}

.product-commerce-copy > p {
  color: var(--shop-muted);
  font-size: 18px;
}

.product-commerce-copy .shop-price-row {
  margin: 30px 0 24px;
}

.shop-specs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 64px;
  border-top: 1px solid var(--shop-border);
}

.shop-specs div {
  display: grid;
  grid-template-columns: minmax(120px, 0.8fr) minmax(0, 1.2fr);
  gap: 18px;
  border-bottom: 1px solid var(--shop-border);
  padding: 18px 20px 18px 0;
}

.shop-specs div:nth-child(odd) { border-right: 1px solid var(--shop-border); }
.shop-specs div:nth-child(even) { padding-left: 20px; }
.shop-specs dt { color: var(--shop-muted); }
.shop-specs dd { margin: 0; font-weight: 650; }

.cart-layout,
.checkout-layout,
.purchase-channel-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 390px);
  gap: 36px;
  align-items: start;
}

.cart-lines,
.checkout-form,
.order-panel {
  border-top: 1px solid var(--shop-border);
}

.cart-line {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) auto;
  gap: 22px;
  align-items: center;
  border-bottom: 1px solid var(--shop-border);
  padding: 22px 0;
}

.cart-line img {
  width: 150px;
  height: 88px;
  object-fit: contain;
  background: #171817;
}

.cart-line h2 { margin-bottom: 8px; font-size: 26px; }
.cart-line p { margin: 0; color: var(--shop-muted); }

.quantity-control {
  display: grid;
  grid-template-columns: 44px 40px 44px;
  align-items: center;
  text-align: center;
}

.quantity-control button {
  width: 44px;
  min-height: 44px;
  border-color: var(--shop-border);
  background: transparent;
  color: var(--shop-ink);
  padding: 0;
}

.order-summary,
.purchase-channel,
.legal-document {
  border: 1px solid var(--shop-border);
  border-radius: 8px;
  background: var(--shop-paper-strong);
  padding: 28px;
}

.order-summary {
  position: sticky;
  top: 142px;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid var(--shop-border);
  padding: 12px 0;
}

.summary-row.total {
  border-bottom: 0;
  font-size: 20px;
  font-weight: 760;
}

.shop-notice {
  margin: 20px 0;
  border-left: 4px solid var(--shop-copper);
  padding: 14px 18px;
  background: #ebe5da;
  color: #4e4942;
}

.shop-notice.error { border-left-color: var(--shop-error); }
.shop-notice.success { border-left-color: var(--shop-success); }

.shop-form-section {
  border-bottom: 1px solid var(--shop-border);
  padding: 26px 0;
}

.shop-form-section h2 { margin-bottom: 20px; font-size: 30px; }

.shop-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.shop-field {
  display: grid;
  gap: 7px;
}

.shop-field.full { grid-column: 1 / -1; }
.shop-field span { font-size: 14px; font-weight: 700; }
.shop-field small { color: var(--shop-muted); }

.shop-field input,
.shop-field select,
.shop-field textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid #aaa69f;
  border-radius: 6px;
  padding: 10px 12px;
  background: #fff;
  color: var(--shop-ink);
  font: inherit;
}

.check-row {
  display: grid;
  grid-template-columns: 22px 1fr;
  gap: 11px;
  align-items: start;
  margin: 14px 0;
}

.check-row input { width: 20px; height: 20px; margin: 2px 0 0; }

.purchase-channel-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.purchase-channel h2 { font-size: 34px; }
.purchase-channel p { color: var(--shop-muted); }
.channel-list { display: grid; gap: 10px; margin-top: 18px; }

.shop-footer {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 32px;
  padding: 42px 7vw;
  background: #111;
  color: rgba(244, 240, 232, 0.78);
}

.shop-footer nav { justify-content: flex-end; flex-wrap: wrap; }
.shop-footer p { margin: 0; }

.cookie-panel {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 50;
  width: min(430px, calc(100% - 36px));
  border: 1px solid var(--shop-border);
  border-radius: 8px;
  padding: 20px;
  background: var(--shop-paper-strong);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.22);
}

.cookie-panel p { margin-bottom: 15px; color: var(--shop-muted); }

.empty-state {
  min-height: 300px;
  border-top: 1px solid var(--shop-border);
  padding: 44px 0;
}

.legal-document {
  max-width: 900px;
}

.legal-document h1 {
  overflow-wrap: anywhere;
}

.legal-document h2 { margin-top: 42px; font-size: 30px; }
.legal-document li { margin-bottom: 8px; }

@media (max-width: 860px) {
  body:has(.shop-main) .site-header {
    grid-template-columns: minmax(150px, 1fr) auto;
    align-items: center;
  }

  body:has(.shop-main) .site-header nav {
    display: flex;
    grid-column: 1 / -1;
    grid-row: 2;
    justify-content: flex-start;
    max-width: 100%;
    overflow-x: auto;
    padding: 4px 0;
    white-space: nowrap;
  }

  .shop-main { padding-top: 154px; }
  .shop-heading,
  .product-commerce-hero,
  .cart-layout,
  .checkout-layout,
  .purchase-channel-grid { grid-template-columns: 1fr; }
  .shop-product-grid { grid-template-columns: 1fr; }
  .order-summary { position: static; }
  .shop-specs { grid-template-columns: 1fr; }
  .shop-specs div:nth-child(odd) { border-right: 0; }
  .shop-specs div:nth-child(even) { padding-left: 0; }
  .shop-footer { grid-template-columns: 1fr; }
  .shop-footer nav { justify-content: flex-start; }
}

@media (max-width: 560px) {
  body:has(.shop-main) .site-header {
    grid-template-columns: 1fr;
  }

  body:has(.shop-main) .site-header nav {
    grid-row: 2;
    gap: 18px;
  }

  body:has(.shop-main) .site-header nav a:nth-child(n + 5) { display: none; }

  .shop-main { padding-top: 166px; }
  .shop-shell { width: min(100% - 28px, 1240px); padding-top: 42px; }
  .shop-heading { gap: 20px; }
  .shop-heading h1 { font-size: 44px; }
  .legal-document h1 { font-size: 36px; line-height: 1.04; }
  .shop-product-card { grid-template-rows: 170px auto; }
  .shop-product-card figure { padding: 16px; }
  .shop-product-copy { padding: 20px; }
  .shop-product-copy h2 { font-size: 28px; }
  .product-commerce-hero figure { min-height: 250px; padding: 22px; }
  .cart-line { grid-template-columns: 90px minmax(0, 1fr); }
  .cart-line img { width: 90px; height: 64px; }
  .cart-line .quantity-control { grid-column: 2; }
  .shop-form-grid { grid-template-columns: 1fr; }
  .shop-field.full { grid-column: auto; }
}
