:root {
  --paper: #fbf7f2;
  --paper-2: #e6ded4;
  --taupe: #c4ae92;
  --ink: #7a5c46;
  --ink-strong: #3f2e22;
  --muted: #6b4e3a;
  --forest: #2c463d;
  --forest-deep: #22382f;
  --ivory: #fff8ec;
  --line: rgb(122 92 70 / 16%);
  --danger: #8c2f2a;
  --serif: "Libre Caslon Text", "Iowan Old Style", Georgia, serif;
  --sans: Inter, "Avenir Next", "Segoe UI", sans-serif;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  color-scheme: light;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  letter-spacing: 0;
}

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

a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }

a:hover { color: var(--forest); }

:focus-visible {
  outline: 2px solid var(--forest);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: 16px;
  top: 8px;
  transform: translateY(-140%);
  background: var(--ivory);
  color: var(--forest);
  padding: 10px 14px;
  z-index: 80;
}

.skip:focus { transform: none; }

h1, h2, h3, .display {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--ink-strong);
  text-wrap: balance;
}

p { text-wrap: pretty; }

.announcement {
  background: var(--forest);
  color: var(--ivory);
  text-align: center;
  padding: 9px 16px;
  font-size: 13px;
  letter-spacing: 0.02em;
}

.site-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 4%;
  min-height: 78px;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 40;
}

.logo {
  font-family: var(--serif);
  font-size: clamp(15px, 1.7vw, 26px);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink-strong);
  line-height: 1.1;
  min-width: 0;
}

.site-header nav {
  display: flex;
  flex: 1;
  flex-wrap: wrap;
  gap: 8px 22px;
  font-size: 13.5px;
  font-weight: 500;
}

.site-header nav a {
  text-decoration: none;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
}

.site-header nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 4px; }

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-actions a,
.icon-button,
.currency select {
  min-height: 44px;
  min-width: 44px;
}

.icon-button,
.menu-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink-strong);
  text-decoration: none;
}

.bag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  font-size: 14px;
  min-height: 44px;
  padding-inline: 4px;
}

.currency select {
  background: transparent;
  color: var(--ink-strong);
  border: 1px solid var(--line);
  font: inherit;
  font-size: 13px;
  letter-spacing: 0.02em;
  padding: 0 8px;
  min-width: 76px;
}

.menu-toggle { display: none; }

.hero {
  position: relative;
  min-height: clamp(500px, 70vw, 660px);
  display: flex;
  align-items: center;
  color: var(--ivory);
  isolation: isolate;
}

.hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgb(44 70 61 / 78%) 0%, rgb(44 70 61 / 42%) 48%, rgb(44 70 61 / 22%) 100%);
  z-index: -1;
}

.hero-copy {
  width: min(1360px, calc(100% - 2.5rem));
  margin-inline: auto;
  padding: 64px 0;
  max-width: 36rem;
}

.hero-copy h1 {
  margin: 0;
  font-size: clamp(2.15rem, 5vw, 3.75rem);
  color: var(--ivory);
  letter-spacing: -0.02em;
}

.hero-copy p {
  margin: 20px 0 0;
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  max-width: 34ch;
  color: var(--ivory);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0.7rem 1.4rem;
  border: 1px solid transparent;
  background: var(--forest);
  color: var(--ivory);
  font: inherit;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  cursor: pointer;
}

.button:hover { background: var(--forest-deep); color: var(--ivory); }

.button:active { transform: translateY(1px); }

.button.light {
  background: var(--ivory);
  color: var(--forest);
}

.button.light:hover { background: var(--paper); color: var(--forest-deep); }

.button.ghost {
  background: transparent;
  color: var(--forest);
  border-color: var(--forest);
}

.button:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }

.hero-copy .button { margin-top: 32px; }

.band {
  background: var(--paper-2);
  text-align: center;
  padding: 64px 24px;
}

.band h2 {
  margin: 0;
  font-size: clamp(1.65rem, 4vw, 3rem);
  font-style: italic;
  letter-spacing: -0.02em;
}

.band p {
  margin: 16px auto 0;
  max-width: 36ch;
  font-size: 1.05rem;
}

.section {
  width: min(1360px, calc(100% - 2.5rem));
  margin-inline: auto;
  padding: 56px 0;
}

.section-heading { text-align: center; max-width: 42rem; margin: 0 auto 32px; }

.section-heading h2,
.heading-row h2 { margin: 0; font-size: clamp(1.8rem, 3vw, 2.4rem); }

.section-heading p,
.heading-row p { margin: 12px 0 0; line-height: 1.6; }

.heading-row {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 24px;
  margin-bottom: 28px;
}

.collections {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 16px;
}

.collections a {
  text-align: center;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  min-width: 0;
}

.collections img,
.product-image {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: var(--paper-2);
}

.collections img { margin-bottom: 12px; }

.products {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px 18px;
}

.product { min-width: 0; text-decoration: none; display: block; }

.product h3 {
  margin: 14px 0 8px;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.35;
  color: var(--ink-strong);
}

.product .price { margin: 0; color: var(--muted); font-size: 14px; font-variant-numeric: tabular-nums; }

.product-image { overflow: hidden; display: grid; place-items: center; }
.product-image img,
.gallery img,
.thumbs img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery > img { aspect-ratio: 1; background: var(--paper-2); }
.cart-row img { width: 88px; height: 88px; object-fit: cover; background: var(--paper-2); }
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.pager { display: flex; gap: 8px; margin-top: 24px; }
.pager a { min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center; text-decoration: none; border: 1px solid var(--line); }
.pager a[aria-current="page"] { background: var(--forest); color: var(--ivory); }

.story {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  background: var(--forest);
  color: var(--ivory);
}

.story img { width: 100%; height: 100%; min-height: 360px; object-fit: cover; }

.story div {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  padding: 56px 10%;
}

.story p, .story h2 { color: var(--ivory); margin: 0; }

.story h2 { font-size: clamp(1.8rem, 3vw, 2.6rem); }

.story a { color: var(--ivory); min-height: 44px; display: inline-flex; align-items: center; }

.site-footer {
  background: var(--paper);
  border-top: 1px solid var(--line);
  margin-top: auto;
}

.footer-main {
  width: min(1360px, calc(100% - 2.5rem));
  margin-inline: auto;
  display: grid;
  grid-template-columns: 1.3fr 0.8fr 0.9fr;
  gap: 40px;
  padding: 64px 0;
}

.site-footer h2 {
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0 0 16px;
}

.site-footer ul { list-style: none; margin: 0; padding: 0; }

.site-footer li + li { margin-top: 8px; }

.site-footer a { font-size: 14px; text-decoration: none; }

.site-footer a:hover { text-decoration: underline; }

.footer-brand .logo { display: inline-block; margin-bottom: 16px; }

.footer-brand p { margin: 0; max-width: 42ch; line-height: 1.6; font-size: 14px; color: var(--muted); }

.footer-brand p + p { margin-top: 12px; }

.company-name {
  margin-top: 20px;
  color: var(--ink-strong);
  font-weight: 600;
  letter-spacing: 0.02em;
}

.footer-bottom {
  background: var(--paper-2);
  padding: 18px 4%;
  font-size: 13px;
  letter-spacing: 0.01em;
  color: var(--muted);
}

.page {
  width: min(1120px, calc(100% - 2.5rem));
  margin-inline: auto;
  padding: 48px 0 72px;
}

.page h1 { margin: 0 0 12px; font-size: clamp(2rem, 4vw, 3rem); }

.lede { max-width: 65ch; font-size: 17px; }

.layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 36px;
}

.side-nav { display: grid; gap: 4px; align-content: start; }

.side-nav a {
  text-decoration: none;
  min-height: 36px;
  display: flex;
  align-items: center;
  padding: 4px 0;
  font-size: 14px;
}

.side-nav a[aria-current="true"] { color: var(--forest); font-weight: 600; }

.catalog-tools { display: flex; justify-content: space-between; gap: 16px; align-items: end; margin-bottom: 20px; }

.field { display: grid; gap: 6px; margin-bottom: 14px; }

.field span, .check { font-size: 14px; font-weight: 500; color: var(--ink-strong); }

input, select, textarea {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid rgb(122 92 70 / 35%);
  background: var(--ivory);
  color: var(--ink-strong);
  font: inherit;
  border-radius: 0;
}

textarea { min-height: 140px; resize: vertical; }

.hint { font-size: 13px; color: var(--muted); letter-spacing: 0.01em; }

.form-error, .field-error {
  color: var(--danger);
  font-size: 14px;
  margin: 0;
}

.field[data-invalid="true"] input,
.field[data-invalid="true"] select,
.field[data-invalid="true"] textarea { border-color: var(--danger); }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }

.summary, .panel, .prose {
  background: var(--ivory);
  border: 1px solid var(--line);
  padding: 20px;
}

.prose { max-width: 72ch; }

.prose h2 { font-size: 1.5rem; margin: 28px 0 8px; }

.prose p, .prose li { font-size: 16px; line-height: 1.6; }

.prose ul { padding-left: 1.2rem; }

.split {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
  gap: 28px;
}

.gallery { display: grid; gap: 10px; }

.thumbs { display: grid; grid-template-columns: repeat(4, 72px); gap: 8px; }

.thumbs button {
  padding: 0;
  border: 1px solid transparent;
  background: var(--paper-2);
  cursor: pointer;
  min-height: 72px;
}

.thumbs button[aria-current="true"] { border-color: var(--forest); }

.specs { width: 100%; border-collapse: collapse; margin-top: 20px; }

.specs th, .specs td {
  text-align: left;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
  font-weight: 400;
}

.specs th { width: 34%; color: var(--ink-strong); font-weight: 600; }

.qty {
  display: flex;
  align-items: center;
  gap: 8px;
}

.qty input { width: 76px; text-align: center; }

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

.totals { display: grid; gap: 8px; margin: 16px 0; }

.totals div, .total-row span { display: flex; justify-content: space-between; gap: 16px; font-variant-numeric: tabular-nums; }

.totals .grand { font-size: 18px; color: var(--ink-strong); font-weight: 600; }

.status {
  background: var(--paper-2);
  padding: 12px 14px;
  margin: 12px 0;
}

.empty, .error-block {
  padding: 48px 0;
  max-width: 46ch;
}

.notice { font-size: 14px; }

table.fees { width: 100%; border-collapse: collapse; margin: 16px 0 24px; }

table.fees th, table.fees td {
  text-align: left;
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  font-variant-numeric: tabular-nums;
}

@media (max-width: 1023px) {
  .collections { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .footer-main, .layout, .split { grid-template-columns: minmax(0, 1fr); }
  .menu-toggle { display: inline-flex; }
  .logo { flex: 1; }
  .site-header nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex: none;
    flex-direction: column;
    gap: 0;
    padding: 8px 4% 16px;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
  }
  .site-header nav.is-open { display: flex; }
  .products { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 767px) {
  .products, .collections { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .story { grid-template-columns: minmax(0, 1fr); }
  .heading-row, .form-grid, .catalog-tools { display: grid; }
  .cart-row { grid-template-columns: 72px minmax(0, 1fr); }
  .cart-row .line-price { grid-column: 2; }
}

@media (max-width: 479px) {
  .site-header { gap: 8px; min-height: 72px; }
  .logo { overflow: hidden; text-overflow: ellipsis; }
  .header-actions { gap: 2px; }
  .products, .collections { grid-template-columns: minmax(0, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .button:active { transform: none; }
}
