@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600&family=Inter:wght@400;500;600&display=swap');

:root {
  --bg: #F7F4EE;
  --bg-alt: #EFEBE1;
  --card: #FFFFFF;
  --text: #22201B;
  --text-muted: #706A5C;
  --accent: #4E5B44;
  --accent-soft: #DEE4D4;
  --line: #DEDACD;
  --max-width: 1180px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  line-height: 1.5;
}

h1, h2, h3 { font-family: 'Fraunces', serif; font-weight: 500; margin: 0; }

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

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

/* thread divider — signature element */
.thread {
  width: 100%;
  height: 14px;
  display: block;
  margin: 0 auto;
}
.thread path {
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.4;
  stroke-linecap: round;
  opacity: 0.55;
}

/* header */
header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(247, 244, 238, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}
.logo {
  font-family: 'Fraunces', serif;
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}
nav { display: flex; gap: 2rem; align-items: center; }
nav a {
  font-size: 0.92rem;
  color: var(--text-muted);
  transition: color 0.15s ease;
}
nav a:hover, nav a:focus-visible { color: var(--accent); }
.cart-btn {
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 999px;
  padding: 0.5rem 1.1rem;
  font-size: 0.88rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.cart-btn:hover { border-color: var(--accent); }
.cart-count {
  background: var(--accent);
  color: #fff;
  border-radius: 999px;
  font-size: 0.72rem;
  min-width: 1.2rem;
  height: 1.2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 0.3rem;
}

/* hero */
.hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 3rem;
  align-items: center;
  padding: 4.5rem 0 3.5rem;
}
.hero h1 {
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  line-height: 1.08;
  max-width: 14ch;
}
.hero p {
  color: var(--text-muted);
  font-size: 1.05rem;
  max-width: 42ch;
  margin-top: 1.2rem;
}
.hero .cta {
  margin-top: 2rem;
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 0.85rem 1.7rem;
  border-radius: 4px;
  font-size: 0.92rem;
  letter-spacing: 0.01em;
}
.hero .cta:hover { opacity: 0.9; }
.hero-img {
  aspect-ratio: 4/5;
  border-radius: 6px;
  overflow: hidden;
  background: var(--bg-alt);
}
.hero-img img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* section headers */
.section { padding: 3.5rem 0; }
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 1.8rem;
}
.section-head h2 { font-size: 1.8rem; }
.section-head .eyebrow {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  display: block;
  margin-bottom: 0.4rem;
}

/* product grid */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 1.6rem;
}
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 6px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}
.card:hover { box-shadow: 0 8px 24px rgba(34,32,27,0.08); transform: translateY(-2px); }
.card .thumb { aspect-ratio: 4/5; background: var(--bg-alt); }
.card .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card-body { padding: 1rem 1.1rem 1.2rem; display: flex; flex-direction: column; gap: 0.35rem; flex: 1; }
.card-body h3 { font-size: 1.02rem; font-weight: 500; }
.card-body .desc { color: var(--text-muted); font-size: 0.85rem; flex: 1; }
.card-body .row { display: flex; align-items: center; justify-content: space-between; margin-top: 0.5rem; }
.price { font-family: 'Fraunces', serif; font-size: 1.05rem; }
.add-btn {
  border: 1px solid var(--accent);
  color: var(--accent);
  background: transparent;
  padding: 0.4rem 0.9rem;
  border-radius: 4px;
  font-size: 0.82rem;
  cursor: pointer;
}
.add-btn:hover { background: var(--accent); color: #fff; }

/* about strip */
.about {
  background: var(--bg-alt);
  padding: 3.5rem 0;
}
.about .wrap { max-width: 760px; text-align: center; }
.about h2 { font-size: 1.7rem; margin-bottom: 1rem; }
.about p { color: var(--text-muted); }

/* cart drawer */
.drawer {
  position: fixed;
  top: 0; right: 0;
  width: min(420px, 100vw);
  height: 100%;
  background: var(--card);
  box-shadow: -12px 0 32px rgba(0,0,0,0.12);
  transform: translateX(100%);
  transition: transform 0.25s ease;
  z-index: 40;
  display: flex;
  flex-direction: column;
}
.drawer.open { transform: translateX(0); }
.drawer-head {
  padding: 1.4rem 1.4rem 1rem;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.drawer-head h2 { font-size: 1.3rem; }
.drawer-close { background: none; border: none; font-size: 1.4rem; cursor: pointer; color: var(--text-muted); }
.drawer-items { flex: 1; overflow-y: auto; padding: 1rem 1.4rem; }
.drawer-item { display: flex; gap: 0.8rem; padding: 0.8rem 0; border-bottom: 1px solid var(--line); }
.drawer-item img { width: 56px; height: 70px; object-fit: cover; border-radius: 4px; background: var(--bg-alt); }
.drawer-item .info { flex: 1; }
.drawer-item .info h4 { font-size: 0.92rem; font-weight: 500; margin: 0 0 0.2rem; }
.drawer-item .qty-row { display: flex; align-items: center; gap: 0.5rem; margin-top: 0.3rem; }
.drawer-item button.qty { width: 22px; height: 22px; border: 1px solid var(--line); background: none; border-radius: 3px; cursor: pointer; }
.drawer-item .remove { color: var(--text-muted); font-size: 0.78rem; cursor: pointer; background: none; border: none; text-decoration: underline; margin-left: auto; }
.drawer-empty { color: var(--text-muted); text-align: center; padding: 2rem 0; font-size: 0.9rem; }
.drawer-foot { padding: 1.2rem 1.4rem 1.6rem; border-top: 1px solid var(--line); }
.drawer-foot .total-row { display: flex; justify-content: space-between; margin-bottom: 1rem; font-family: 'Fraunces', serif; font-size: 1.1rem; }
.drawer-foot input, .drawer-foot textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 0.6rem 0.7rem;
  font-family: inherit;
  font-size: 0.88rem;
  margin-bottom: 0.6rem;
  background: var(--bg);
}
.drawer-foot textarea { resize: vertical; min-height: 60px; }
.submit-btn {
  width: 100%;
  background: var(--accent);
  color: #fff;
  border: none;
  padding: 0.8rem;
  border-radius: 4px;
  font-size: 0.92rem;
  cursor: pointer;
}
.submit-btn:hover { opacity: 0.9; }
.form-note { font-size: 0.76rem; color: var(--text-muted); margin-top: 0.6rem; }
.overlay {
  position: fixed; inset: 0;
  background: rgba(34,32,27,0.35);
  opacity: 0; pointer-events: none;
  transition: opacity 0.25s ease;
  z-index: 30;
}
.overlay.open { opacity: 1; pointer-events: auto; }

/* footer */
footer {
  border-top: 1px solid var(--line);
  padding: 3rem 0 2.4rem;
  color: var(--text-muted);
  font-size: 0.85rem;
}
footer .cols {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}
footer h4 { font-family: 'Inter', sans-serif; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text); margin-bottom: 0.8rem; }
footer .brand-line { font-family: 'Fraunces', serif; font-size: 1.2rem; color: var(--text); margin-bottom: 0.5rem; }
footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.5rem; }
footer .bottom { border-top: 1px solid var(--line); padding-top: 1.4rem; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 0.5rem; }

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; }
  .hero-img { order: -1; max-width: 320px; margin: 0 auto; }
  nav { display: none; }
  footer .cols { grid-template-columns: 1fr; }
}
