:root {
  --cream: #fbf5ef;
  --blush: #f5dfe1;
  --rose: #b96f7c;
  --deep: #633f48;
  --brown: #4e3d38;
  --muted: #8a6d68;
  --white: #fffdfb;
  --line: #ead9d3;
  --shadow: 0 12px 35px rgba(99, 63, 72, 0.1);
  --header: 118px;
  --tab: 64px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--brown);
  font-family: "DM Sans", "Segoe UI", sans-serif;
  line-height: 1.5;
}
body.has-tab { padding-bottom: var(--tab); }
img { max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--rose); outline-offset: 3px; }
h1, h2, h3 { font-family: "Playfair Display", Georgia, serif; color: var(--deep); font-weight: 600; }
p { margin: 0 0 12px; }

.announce {
  background: var(--deep);
  color: #fbeeee;
  text-align: center;
  font-size: 13px;
  letter-spacing: 0.2px;
  padding: 9px 16px;
}
.announce a { text-decoration: underline; text-underline-offset: 2px; }

.bar {
  max-width: 1120px;
  margin: 0 auto;
  padding: 14px 22px;
  display: flex;
  align-items: center;
  gap: 18px;
}
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 253, 251, 0.94);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.logo {
  font-family: "Playfair Display", Georgia, serif;
  color: var(--deep);
  font-size: 24px;
  line-height: 1;
  margin-right: auto;
}
.logo small {
  display: block;
  margin-top: 5px;
  font-family: "DM Sans", sans-serif;
  font-size: 10px;
  letter-spacing: 2.4px;
  text-transform: uppercase;
  color: var(--rose);
  font-weight: 700;
}
.links { display: flex; gap: 22px; font-size: 14px; font-weight: 600; }
.tools a[aria-label="Search"] { display: none; }
.links a[aria-current="page"] { color: var(--rose); }
.links a:hover { color: var(--rose); }
.tools { display: flex; align-items: center; gap: 8px; }
.icon-btn, .menu-btn {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--white);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.menu-btn { display: none; }
.cart-count {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--rose);
  color: white;
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.cart-count[hidden] { display: none; }

.drawer {
  display: none;
  border-top: 1px solid var(--line);
  background: var(--white);
  padding: 8px 22px 18px;
}
.drawer.open { display: block; }
.drawer a {
  display: block;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-weight: 700;
}
.nav-search {
  display: flex;
  margin-left: 8px;
}
.nav-search input {
  width: 160px;
  border: 1px solid var(--line);
  background: var(--white);
  border-radius: 999px;
  padding: 9px 14px;
}

.wrap { max-width: 1120px; margin: 0 auto; }
.section { padding: 64px 22px; }
.section.alt { background: #fffaf6; }
.section-head { text-align: center; margin-bottom: 28px; }
.section-head h1, .section-head h2, .page-title h1 { font-size: clamp(34px, 5vw, 46px); margin: 8px 0; }
.section-head p, .page-title p { max-width: 620px; margin: 0 auto; color: var(--muted); }
.eyebrow {
  color: var(--rose);
  text-transform: uppercase;
  letter-spacing: 3px;
  font-size: 12px;
  font-weight: 700;
}
.row-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
  margin-bottom: 18px;
}
.row-head h2 { margin: 6px 0 0; font-size: 34px; }
.linkish { font-weight: 700; color: var(--deep); border-bottom: 1px solid var(--rose); }

.hero {
  max-width: 1120px;
  margin: 0 auto;
  padding: 64px 22px 36px;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
}
.hero h1 {
  font-size: clamp(46px, 7vw, 76px);
  line-height: 0.98;
  margin: 12px 0 18px;
}
.lede { font-size: 17px; line-height: 1.75; max-width: 560px; }
.buttons { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 26px; }
.btn, .add {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 12px 18px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 14px;
  border: 1px solid var(--rose);
  transition: 0.2s background, 0.2s color;
}
.btn.primary, .add { background: var(--deep); color: white; border-color: var(--deep); }
.btn.primary:hover, .add:hover { background: var(--rose); border-color: var(--rose); }
.btn.secondary { background: transparent; color: var(--deep); }
.btn.secondary:hover { background: var(--blush); }
.btn.full { width: 100%; }
.hero-points {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
}
.hero-points li, .pill {
  background: white;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 13px;
  font-weight: 700;
  color: var(--deep);
}
.hero-art {
  min-height: 420px;
  border-radius: 42% 42% 18% 18%;
  background:
    radial-gradient(circle at 30% 30%, rgba(255,255,255,.55), transparent 42%),
    linear-gradient(145deg, #f1d6d9, #ead4c8);
  box-shadow: var(--shadow);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.hero-art:before, .hero-art:after {
  content: "";
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.75);
}
.hero-art:before { width: 230px; height: 230px; }
.hero-art:after { width: 320px; height: 320px; }
.yarn-mark {
  position: relative;
  z-index: 1;
  width: 236px;
  height: 236px;
  border-radius: 50%;
  overflow: hidden;
  background: #fffdf5;
  box-shadow: 0 10px 28px rgba(99, 63, 72, 0.14);
  margin-bottom: 92px;
}
.yarn-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.hero-float {
  position: absolute;
  z-index: 2;
  left: 18px;
  right: 18px;
  bottom: 18px;
  display: grid;
  gap: 8px;
}
.hero-float a {
  background: rgba(255, 253, 251, 0.92);
  border-radius: 14px;
  padding: 10px 12px;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-weight: 700;
  color: var(--deep);
  font-size: 14px;
}

.collections { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.collection {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 22px 18px;
  min-height: 180px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 4px 18px rgba(99, 63, 72, 0.04);
}
.collection:hover { border-color: #e3c4c8; }
.collection .emoji { font-size: 32px; }
.collection h3 { margin: 10px 0 6px; font-size: 24px; }
.collection p { color: var(--muted); font-size: 14px; flex: 1; }
.collection small { font-weight: 700; color: var(--rose); }

.grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 22px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 4px 18px rgba(99, 63, 72, 0.04);
}
.product-img {
  height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 58px;
}
.card-body { padding: 15px 15px 16px; display: flex; flex-direction: column; flex: 1; }
.tag {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1.4px;
  color: var(--rose);
  font-weight: 700;
}
.card h3 { font-size: 20px; margin: 6px 0 8px; }
.card h3 a:hover { color: var(--rose); }
.price { font-weight: 700; color: var(--deep); margin-bottom: 12px; }
.add { margin-top: auto; border-radius: 12px; width: 100%; }

.filters { display: flex; gap: 8px; flex-wrap: wrap; margin: 14px 0; }
.filter, .sort {
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--deep);
  border-radius: 999px;
  padding: 9px 14px;
  font-weight: 700;
}
.filter.active, .filter:hover { background: var(--deep); color: white; border-color: var(--deep); }
.shop-bar {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
  margin: 8px 0 18px;
}
.search {
  flex: 1;
  min-width: 220px;
  border: 1px solid var(--line);
  background: var(--white);
  border-radius: 999px;
  padding: 12px 16px;
}
.count-line { color: var(--muted); font-size: 14px; margin: 0 0 14px; }

.pair {
  background: var(--blush);
  border-radius: 28px;
  padding: 36px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  align-items: center;
}
.pair h2 { font-size: 40px; margin: 8px 0 12px; }
.pair-items { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.mini {
  background: rgba(255,255,255,.75);
  border: 1px solid rgba(185, 111, 124, 0.18);
  border-radius: 18px;
  padding: 16px 10px;
  text-align: center;
}
.mini span { font-size: 30px; display: block; margin-bottom: 6px; }
.mini b { font-size: 13px; }

.steps, .custom { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.feature, .step {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 24px;
}
.step .num {
  width: 36px; height: 36px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--blush); color: var(--deep); font-weight: 800;
}
.feature h3, .step h3 { margin: 12px 0 6px; }
.feature p, .step p { color: var(--muted); font-size: 14px; margin: 0; }
.center { text-align: center; margin-top: 26px; }

.about {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 40px;
  align-items: center;
}
.about-box {
  background: var(--blush);
  border-radius: 30px;
  min-height: 260px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.about-box .big {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 78px;
  color: white;
  line-height: 1;
}
.about-box p { color: white; letter-spacing: 2px; font-size: 12px; margin: 8px 0 0; }
.about-logo {
  width: 210px;
  height: 210px;
  border-radius: 50%;
  object-fit: cover;
  background: #fffdf5;
  box-shadow: 0 8px 24px rgba(99, 63, 72, 0.12);
}
.prose { max-width: 720px; }
.prose h1 { font-size: clamp(36px, 5vw, 52px); margin: 8px 0 12px; }
.prose p, .prose li { line-height: 1.75; }
.prose ol { padding-left: 18px; }
.note-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 16px 18px;
  margin-top: 16px;
}

.product-layout {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 36px;
  align-items: start;
}
.stage {
  min-height: 420px;
  border-radius: 32px;
  display: grid;
  place-items: center;
  font-size: 120px;
  border: 1px solid var(--line);
}
.product-copy h1 { font-size: clamp(36px, 5vw, 54px); margin: 8px 0; }
.product-price { font-size: 28px; font-weight: 800; color: var(--deep); margin: 8px 0 14px; }
.qty-row { display: flex; gap: 10px; align-items: center; margin: 18px 0; }
.qty {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 999px;
  overflow: hidden;
  background: white;
}
.qty button {
  width: 42px; height: 42px; border: 0; background: transparent; font-size: 20px;
}
.qty input {
  width: 48px; border: 0; text-align: center; background: transparent;
}

.cart-layout { display: grid; grid-template-columns: 1.4fr 0.8fr; gap: 22px; align-items: start; }
.cart-line, .summary {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 22px;
}
.cart-line {
  display: grid;
  grid-template-columns: 84px 1fr;
  gap: 14px;
  padding: 14px;
  margin-bottom: 12px;
  align-items: center;
}
.line-head { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.thumb {
  width: 84px; height: 84px; border-radius: 16px;
  display: grid; place-items: center; font-size: 36px;
}
.line-title { font-family: "Playfair Display", Georgia, serif; font-size: 22px; color: var(--deep); }
.muted { color: var(--muted); font-size: 14px; }
.remove {
  border: 0; background: transparent; color: var(--rose); font-weight: 700; padding: 6px 0;
}
.summary { padding: 20px; position: sticky; top: 130px; }
.summary h2 { margin-top: 0; }
.summary label { display: block; font-size: 13px; font-weight: 700; margin: 12px 0 6px; }
.summary input, .summary textarea, .order-text {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 11px 12px;
  background: var(--cream);
}
.total-row {
  display: flex; justify-content: space-between; align-items: baseline;
  margin: 16px 0; font-size: 18px;
}
.total-row b { font-size: 26px; color: var(--deep); }
.order-text { min-height: 140px; margin: 12px 0; }
.stack { display: grid; gap: 8px; }
.empty {
  background: white;
  border: 1px dashed var(--line);
  border-radius: 18px;
  padding: 28px;
  text-align: center;
  color: var(--muted);
}
.empty-state { text-align: center; padding: 30px 10px 10px; }
.empty-state h1 { font-size: 42px; }

.site-footer { background: var(--deep); color: #f9ece8; padding: 48px 22px 28px; }
.footer-grid {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 28px;
}
.site-footer h2, .site-footer h3 { color: white; margin: 0 0 10px; }
.site-footer a { display: block; padding: 4px 0; color: #f3d7dc; }
.site-footer a:hover { color: white; }
.site-footer p { color: #f0d5da; }
.legal {
  max-width: 1120px;
  margin: 26px auto 0;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,.15);
  font-size: 12px;
  color: #e7c4cb;
}

.tabbar {
  display: none;
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 45;
  background: rgba(255,253,251,.96);
  border-top: 1px solid var(--line);
  padding: 6px 8px calc(6px + env(safe-area-inset-bottom));
  grid-template-columns: repeat(3, 1fr);
}
.tabbar a {
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  padding: 6px 0 4px;
  position: relative;
}
.tabbar a[aria-current="page"] { color: var(--rose); }
.tabbar svg { display: block; margin: 0 auto 2px; }
.tab-count {
  position: absolute;
  top: 0; left: 50%;
  margin-left: 8px;
  background: var(--rose);
  color: white;
  border-radius: 999px;
  font-size: 10px;
  min-width: 16px;
  height: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.tab-count[hidden] { display: none; }

#toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%) translateY(12px);
  background: var(--deep);
  color: white;
  border-radius: 999px;
  padding: 12px 16px;
  font-weight: 700;
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: 0.2s ease;
  z-index: 60;
  max-width: calc(100% - 32px);
}
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); pointer-events: auto; }
#toast a { text-decoration: underline; margin-left: 8px; }
body.has-tab #toast { bottom: calc(var(--tab) + 12px); }

@media (max-width: 980px) {
  .hero, .pair, .about, .product-layout, .cart-layout, .footer-grid { grid-template-columns: 1fr; }
  .collections, .grid, .steps, .custom { grid-template-columns: repeat(2, 1fr); }
  .pair-items { grid-template-columns: repeat(3, 1fr); }
  .links, .nav-search { display: none; }
  .menu-btn, .tools a[aria-label="Search"] { display: inline-flex; }
  .hero { padding-top: 36px; }
  .hero-art { min-height: 340px; }
  .summary { position: static; }
  .tabbar { display: grid; }
  body { padding-bottom: var(--tab); }
}

@media (max-width: 560px) {
  .bar, .section, .hero { padding-left: 15px; padding-right: 15px; }
  .section { padding-top: 42px; padding-bottom: 42px; }
  .grid, .collections, .steps, .custom, .pair-items { grid-template-columns: 1fr 1fr; }
  .product-img { height: 132px; font-size: 44px; }
  .card-body { padding: 12px; }
  .card h3 { font-size: 17px; }
  .pair { padding: 22px; }
  .yarn-mark { width: 196px; height: 196px; }
  .stage { min-height: 260px; font-size: 88px; }
  .thumb { width: 72px; height: 72px; }
  .announce { font-size: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
.product-img img.ph { width: 100%; height: 180px; object-fit: cover; display: block; }
.stage img.ph { width: 100%; height: 420px; object-fit: cover; display: block; border-radius: 32px; }
.thumb img.ph { width: 100%; height: 84px; object-fit: cover; display: block; border-radius: 16px; }
@media (max-width: 560px) {
  .product-img img.ph { height: 132px; }
  .stage img.ph { height: 260px; }
  .thumb img.ph { height: 72px; }
}
