:root {
  --cream: #f7f0e6;
  --linen: #efe4d4;
  --paper: #fffaf4;
  --terracotta: #c46a3a;
  --terracotta-dk: #8c3e22;
  --sage: #6b8f71;
  --sage-dk: #3f5d4a;
  --ink: #2c241c;
  --ink-soft: #5a4e42;
  --gold: #d4a056;
  --blush: #e8c4a8;
  --line: rgba(44, 36, 28, 0.12);
  --shadow: 0 16px 40px rgba(44, 36, 28, 0.14);
  --radius: 20px;
  --font-display: "Fraunces", "Times New Roman", serif;
  --font-body: "Nunito", "Segoe UI", sans-serif;
  --max: 1120px;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--terracotta-dk); }
button, input { font: inherit; }
.wrap { width: min(100% - 32px, var(--max)); margin-inline: auto; }

/* Test-mode banner */
.test-banner {
  display: none;
  background: #2c241c;
  color: #fffaf4;
  text-align: center;
  font-weight: 800;
  font-size: 0.88rem;
  letter-spacing: 0.01em;
  padding: 9px 16px;
  line-height: 1.35;
}
.test-banner.show { display: block; }


/* Shipping banner */
.ship-banner {
  background: var(--sage-dk);
  color: #fffaf4;
  text-align: center;
  font-weight: 800;
  font-size: 0.9rem;
  letter-spacing: 0.01em;
  padding: 8px 16px;
  line-height: 1.35;
}
.ship-banner a { color: inherit; text-decoration: none; }
.ship-banner a:hover { text-decoration: underline; }

/* Header */
.header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(247, 240, 230, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; gap: 12px;
  min-height: 68px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; flex: 1; min-width: 0; }
.brand-mark {
  width: 44px; height: 44px;
  flex-shrink: 0;
  border-radius: 50%;
  object-fit: cover;
  background: var(--paper);
}
.brand-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  white-space: nowrap;
}
@media (min-width: 400px) {
  .brand-name { font-size: 1.15rem; }
}
.nav { display: none; gap: 18px; }
.nav a { text-decoration: none; color: var(--ink-soft); font-weight: 650; font-size: 0.95rem; }
.nav a:hover { color: var(--terracotta-dk); }
.icon-btn {
  appearance: none; border: 0; background: var(--paper);
  width: 44px; height: 44px; border-radius: 14px;
  display: grid; place-items: center; cursor: pointer;
  box-shadow: 0 1px 0 var(--line);
  color: var(--ink);
  position: relative;
}
.cart-count {
  position: absolute; top: -4px; right: -4px;
  background: var(--terracotta); color: #fff;
  min-width: 20px; height: 20px; border-radius: 999px;
  font-size: 11px; font-weight: 800; display: none;
  place-items: center; padding: 0 5px;
}
.cart-count.show { display: grid; }
.menu { display: none; position: absolute; left: 0; right: 0; top: 100%;
  background: var(--paper); border-bottom: 1px solid var(--line);
  padding: 12px 16px 20px; flex-direction: column; gap: 12px; }
.menu a { text-decoration: none; color: var(--ink); font-weight: 700; padding: 8px 4px; }
.menu.open { display: flex; }

/* Hero */
.hero { padding: 28px 0 12px; }
.hero-grid { display: grid; gap: 22px; }
.eyebrow { color: var(--sage-dk); font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; font-size: 0.75rem; }
.hero h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.1rem, 8vw, 3.6rem);
  line-height: 1.08;
  letter-spacing: -0.03em;
  margin: 8px 0 14px;
}
.hero p.lede { font-size: 1.08rem; color: var(--ink-soft); max-width: 38ch; margin: 0 0 22px; }
.hero-art {
  border-radius: 28px; overflow: hidden;
  box-shadow: var(--shadow);
  aspect-ratio: 4/3;
  background: var(--linen);
}
.hero-art img { width: 100%; height: 100%; object-fit: cover; }
.cta-row { display: flex; flex-wrap: wrap; gap: 10px; }
.btn {
  appearance: none; border: 0; cursor: pointer; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 20px; border-radius: 999px; font-weight: 800;
  transition: transform .15s ease, background .15s ease;
}
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--terracotta); color: #fff; }
.btn-primary:hover { background: var(--terracotta-dk); }
.btn-ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn-wide { width: 100%; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }

/* Collections */
.section { padding: 40px 0; }
.section-head { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; margin-bottom: 18px; }
.section h2 {
  font-family: var(--font-display); font-size: clamp(1.6rem, 4vw, 2.2rem);
  letter-spacing: -0.03em; margin: 0;
}
.kicker { color: var(--sage-dk); font-weight: 700; font-size: 0.92rem; }
.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
.card {
  background: var(--paper);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  display: flex; flex-direction: column;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease;
}
.card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.card-img { aspect-ratio: 1; background: var(--linen); }
.card-img img { width: 100%; height: 100%; object-fit: contain; }
.card-body { padding: 14px 14px 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.tag { font-size: 0.75rem; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; color: var(--sage-dk); }
.card h3 { margin: 0; font-size: 1.05rem; line-height: 1.25; }
.price { font-weight: 800; color: var(--terracotta-dk); }
.card-actions { margin-top: 8px; display: flex; gap: 8px; }

/* Pages */
.prose { background: var(--paper); border-radius: 24px; padding: 22px 20px; border: 1px solid var(--line); }
.prose h2 { font-family: var(--font-display); margin-top: 0; }
.prose p { color: var(--ink-soft); }
.prose h3 { font-family: var(--font-display); font-size: 1.25rem; margin: 1.2em 0 0.5em; }
.prose ul { color: var(--ink-soft); padding-left: 1.25em; margin: 0.4em 0 0; }
.prose li { margin: 0.55em 0; }
.contact-email a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.placeholder-note {
  background: #fff3d6;
  border: 1px dashed #c48a2a;
  color: #6a4a12;
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 16px;
}
.contact-email { font-size: 1.15rem; font-weight: 800; }
.soon { color: var(--ink-soft); font-weight: 600; font-size: 0.95rem; }

/* Footer */
footer {
  margin-top: 20px;
  padding: 32px 0 48px;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 0.95rem;
}
.footer-grid { display: grid; gap: 18px; }
.footer-brand { font-family: var(--font-display); color: var(--ink); font-size: 1.2rem; font-weight: 600; }
footer nav { display: flex; flex-wrap: wrap; gap: 12px 18px; }
footer a { color: inherit; text-decoration: none; font-weight: 700; }
footer a:hover { color: var(--terracotta-dk); }

/* Modal + drawers */
.overlay {
  position: fixed; inset: 0; background: rgba(44, 36, 28, 0.45);
  z-index: 60; opacity: 0; pointer-events: none; transition: opacity .2s ease;
}
.overlay.open { opacity: 1; pointer-events: auto; }
.modal, .drawer, .panel {
  position: fixed; z-index: 70; background: var(--paper);
  box-shadow: var(--shadow);
}
.modal {
  left: 50%; top: 50%; transform: translate(-50%, -46%) scale(0.98);
  width: min(100% - 24px, 720px); max-height: min(90vh, 860px);
  border-radius: 24px; overflow: auto;
  opacity: 0; pointer-events: none; transition: .2s ease;
}
.modal.open { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%) scale(1); }
.modal-grid { display: grid; }
.modal-media { background: var(--linen); display: flex; flex-direction: column; }
.modal-img { background: var(--linen); aspect-ratio: 1; }
.modal-img img { width: 100%; height: 100%; object-fit: contain; }
.gallery { display: flex; gap: 8px; padding: 10px 12px 12px; flex-wrap: wrap; }
.gallery button { border: 2px solid transparent; padding: 0; width: 56px; height: 56px; border-radius: 10px; overflow: hidden; background: #fff; cursor: pointer; }
.gallery button img { width: 100%; height: 100%; object-fit: contain; display: block; }
.gallery button[aria-current="true"], .gallery button:hover { border-color: var(--terracotta); }
.modal-body { padding: 20px; }
.modal-body h2 { font-family: var(--font-display); margin: 6px 0 8px; font-size: 1.6rem; }
.close {
  position: absolute; top: 10px; right: 10px;
  width: 40px; height: 40px; border: 0; border-radius: 12px;
  background: rgba(247,240,230,0.92); cursor: pointer; font-size: 1.2rem;
}
.qty {
  display: inline-flex; align-items: center; border: 1.5px solid var(--line);
  border-radius: 999px; overflow: hidden;
}
.qty button { width: 40px; height: 40px; border: 0; background: transparent; cursor: pointer; font-weight: 800; }
.qty input {
  width: 42px; border: 0; text-align: center; background: transparent; font-weight: 800;
  -moz-appearance: textfield;
}
.qty input::-webkit-outer-spin-button,
.qty input::-webkit-inner-spin-button { appearance: none; }
.row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 16px; }

.drawer {
  top: 0; right: 0; height: 100%; width: min(100%, 420px);
  transform: translateX(100%); transition: transform .22s ease;
  display: flex; flex-direction: column;
}
.drawer.open { transform: translateX(0); }
.drawer-head, .panel-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 16px 8px;
}
.drawer-head h2, .panel-head h2 { font-family: var(--font-display); margin: 0; font-size: 1.4rem; }
.cart-items { flex: 1; overflow: auto; padding: 8px 16px 16px; display: flex; flex-direction: column; gap: 12px; }
.cart-item { display: grid; grid-template-columns: 72px 1fr auto; gap: 10px; align-items: center; }
.cart-item img { width: 72px; height: 72px; object-fit: cover; border-radius: 12px; background: var(--linen); }
.cart-item h3 { margin: 0; font-size: 0.95rem; }
.remove { border: 0; background: none; color: var(--ink-soft); cursor: pointer; font-size: 0.8rem; text-decoration: underline; padding: 0; }
.cart-foot { border-top: 1px solid var(--line); padding: 16px; }
.total { display: flex; justify-content: space-between; font-weight: 800; margin-bottom: 12px; }
.empty { color: var(--ink-soft); padding: 24px 8px; text-align: center; }

.panel {
  left: 50%; top: 50%; transform: translate(-50%, -46%);
  width: min(100% - 24px, 440px);
  border-radius: 24px; padding: 8px 8px 20px;
  opacity: 0; pointer-events: none; transition: .2s ease;
}
.panel.open { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%); }
.panel .inner { padding: 0 16px; }
.pay-links { display: flex; flex-direction: column; gap: 8px; margin: 12px 0; }

@media (min-width: 640px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .modal-grid { grid-template-columns: 1fr 1fr; }
  .modal-img { aspect-ratio: auto; min-height: 100%; }
}
@media (min-width: 900px) {
  .header-inner { min-height: 76px; }
  .brand-mark { width: 52px; height: 52px; }
  .brand-name { font-size: 1.28rem; }
  .section-head { flex-direction: row; align-items: baseline; justify-content: space-between; }
  .nav { display: flex; }
  #menu-btn { display: none; }
  .hero-grid { grid-template-columns: 1.05fr 1fr; align-items: center; padding: 28px 0 20px; }
  .grid { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1.4fr 1fr; align-items: start; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
