/* LoomForm — quiet luxury home textiles */
:root {
  --bg: #f6f3ee;
  --bg-alt: #efeae3;
  --bg-deep: #e8e1d6;
  --ink: #2a2622;
  --ink-muted: #6b645c;
  --ink-soft: #8a8278;
  --accent: #8f6b52;
  --accent-deep: #6e4f3b;
  --sage: #7d8b76;
  --terracotta: #c47a5a;
  --brass: #a8926a;
  --border: #ddd5c8;
  --white: #fffcf8;
  --radius: 12px;
  --radius-lg: 18px;
  --max: 1120px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --display: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --shadow: 0 16px 40px rgba(42, 38, 34, 0.07);
  --shadow-sm: 0 6px 18px rgba(42, 38, 34, 0.05);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); text-underline-offset: 0.18em; }
a:hover { opacity: 0.8; }
.wrap { width: min(100% - 2rem, var(--max)); margin-inline: auto; }
h1, h2, h3, .display {
  font-family: var(--display);
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.2;
  color: var(--ink);
}
h1 { font-size: clamp(2.1rem, 4.5vw, 3.25rem); margin: 0 0 0.75rem; }
h2 { font-size: clamp(1.6rem, 3vw, 2.15rem); margin: 0 0 0.75rem; }
h3 { font-size: 1.25rem; margin: 0 0 0.4rem; }
p { margin: 0 0 1rem; }
.muted { color: var(--ink-muted); }
.eyebrow {
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin: 0 0 0.6rem;
}

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(255, 252, 248, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.site-header .inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; padding: 0.9rem 0;
}
.logo {
  font-family: var(--display);
  font-size: 1.45rem;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: 0.01em;
  color: var(--ink);
}
.logo span { font-weight: 400; color: var(--ink-muted); }
.nav {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.85rem 1.1rem;
  font-size: 0.875rem;
}
.nav a { text-decoration: none; color: var(--ink-muted); font-weight: 500; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--ink); opacity: 1; }
.nav-cta {
  background: var(--ink) !important;
  color: var(--white) !important;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  text-decoration: none !important;
}
.nav-cta:hover { opacity: 0.88 !important; }
.nav-toggle {
  display: none;
  border: 1px solid var(--border);
  background: var(--white);
  border-radius: 8px;
  padding: 0.4rem 0.65rem;
  font-size: 0.8rem;
  color: var(--ink);
  cursor: pointer;
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 0.4rem;
  padding: 0.75rem 1.25rem;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.btn:hover { opacity: 0.9; }
.btn-primary { background: var(--ink); color: var(--white); }
.btn-secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--border);
}
.btn-ghost {
  background: transparent;
  color: var(--ink-muted);
  border-color: transparent;
  text-decoration: underline;
  text-underline-offset: 0.2em;
  padding-inline: 0.4rem;
}
.btn-block { width: 100%; }

/* Hero */
.hero {
  padding: 3.5rem 0 3rem;
  background:
    radial-gradient(ellipse at 20% 0%, rgba(196, 122, 90, 0.12), transparent 50%),
    radial-gradient(ellipse at 90% 20%, rgba(125, 139, 118, 0.12), transparent 45%),
    var(--bg);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 2.5rem;
  align-items: center;
}
.hero-lead {
  font-size: 1.08rem;
  color: var(--ink-muted);
  max-width: 36rem;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 1.4rem 0 1rem; }
.hero-meta { font-size: 0.85rem; color: var(--ink-soft); margin: 0; }
.hero-visual {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  min-height: 280px;
}
.swatch {
  border-radius: var(--radius-lg);
  min-height: 140px;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(42, 38, 34, 0.05);
  position: relative;
  overflow: hidden;
}
.swatch::after {
  content: attr(data-label);
  position: absolute;
  left: 0.85rem; bottom: 0.75rem;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(42, 38, 34, 0.55);
  font-weight: 600;
}
.swatch-tall { grid-row: span 2; min-height: 100%; }
.swatch-a { background: linear-gradient(160deg, #f2ebe3, #e3d5c5 55%, #d8c3ad); }
.swatch-b { background: linear-gradient(145deg, #d7cfc3, #c9b7a4); }
.swatch-c { background: linear-gradient(160deg, #b7c0b0, #8a9a84); }
.swatch-d { background: linear-gradient(150deg, #d4a48c, #c47a5a); }

.trust-bar {
  border-block: 1px solid var(--border);
  background: var(--white);
  padding: 1rem 0;
}
.trust-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--ink-muted);
}
.trust-row strong { display: block; color: var(--ink); font-weight: 600; margin-bottom: 0.15rem; }

/* Sections */
.section { padding: 3.25rem 0; }
.section-alt { background: var(--bg-alt); }
.section-head {
  display: flex; flex-wrap: wrap; align-items: end;
  justify-content: space-between; gap: 1rem;
  margin-bottom: 1.75rem;
}
.section-head p { margin: 0; max-width: 28rem; }

/* Product grid */
.filters {
  display: flex; flex-wrap: wrap; gap: 0.5rem;
  margin-bottom: 1.5rem;
}
.filter-btn {
  border: 1px solid var(--border);
  background: var(--white);
  color: var(--ink-muted);
  border-radius: 999px;
  padding: 0.4rem 0.85rem;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
}
.filter-btn.is-active, .filter-btn:hover {
  background: var(--ink);
  color: var(--white);
  border-color: var(--ink);
}
.product-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}
.product-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.product-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}
.product-card a.card-link {
  text-decoration: none; color: inherit; display: flex; flex-direction: column; height: 100%;
}
.product-media {
  aspect-ratio: 4 / 5;
  background: var(--bg-deep);
  position: relative;
}
.product-media .swatch-fill {
  width: 100%; height: 100%;
  display: block;
}
.product-badge {
  position: absolute; top: 0.75rem; left: 0.75rem;
  background: rgba(255, 252, 248, 0.92);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.25rem 0.55rem;
  color: var(--ink-muted);
  font-weight: 600;
}
.product-body { padding: 1rem 1.05rem 1.15rem; display: flex; flex-direction: column; gap: 0.35rem; flex: 1; }
.product-cat { font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-soft); margin: 0; }
.product-name { font-family: var(--display); font-size: 1.2rem; margin: 0; line-height: 1.25; }
.product-tagline { font-size: 0.85rem; color: var(--ink-muted); margin: 0; }
.product-meta {
  margin-top: auto; padding-top: 0.85rem;
  display: flex; align-items: center; justify-content: space-between; gap: 0.5rem;
}
.price { font-weight: 650; font-size: 1rem; }
.ship-note { font-size: 0.72rem; color: var(--ink-soft); }

/* Product detail */
.pdp {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
  align-items: start;
  padding: 2.5rem 0 3rem;
}
.pdp-media {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-deep);
  aspect-ratio: 4 / 5;
  box-shadow: var(--shadow-sm);
}
.pdp-media .swatch-fill { width: 100%; height: 100%; }
.pdp-price-row {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.75rem;
  margin: 0.75rem 0 1rem;
}
.pdp-price { font-size: 1.5rem; font-weight: 650; }
.pdp-ship {
  font-size: 0.85rem; color: var(--ink-muted);
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.25rem 0.7rem;
}
.detail-list {
  margin: 1rem 0 1.5rem;
  padding: 0;
  list-style: none;
}
.detail-list li {
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.92rem;
  color: var(--ink-muted);
}
.detail-list li::before {
  content: "·";
  color: var(--accent);
  margin-right: 0.55rem;
  font-weight: 700;
}
.pdp-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

/* Forms */
.form-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  max-width: 560px;
}
.form-row { margin-bottom: 1rem; }
.form-row label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
  color: var(--ink);
}
.form-row input,
.form-row select,
.form-row textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.7rem 0.85rem;
  font: inherit;
  background: var(--bg);
  color: var(--ink);
}
.form-row textarea { min-height: 120px; resize: vertical; }
.form-hint { font-size: 0.8rem; color: var(--ink-soft); margin-top: 0.35rem; }
.form-success {
  display: none;
  background: #eef3ea;
  border: 1px solid #c9d6c2;
  color: #3d5240;
  border-radius: 10px;
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
  font-size: 0.92rem;
}
.form-success.is-visible { display: block; }

/* FAQ */
.faq { max-width: 720px; }
.faq details {
  border-bottom: 1px solid var(--border);
  padding: 1rem 0;
}
.faq summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  float: right;
  color: var(--accent);
  font-weight: 500;
}
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: 0.75rem 0 0; color: var(--ink-muted); font-size: 0.95rem; }

/* About / content */
.prose { max-width: 680px; }
.prose p { color: var(--ink-muted); }
.split {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 2rem;
  align-items: start;
}
.note-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.35rem;
  box-shadow: var(--shadow-sm);
}
.note-card h3 { margin-bottom: 0.5rem; }
.note-card ul { margin: 0; padding-left: 1.1rem; color: var(--ink-muted); }
.note-card li { margin-bottom: 0.35rem; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--white);
  padding: 2.5rem 0 1.75rem;
  margin-top: 2rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 1.5rem;
  margin-bottom: 1.75rem;
}
.footer-brand p { color: var(--ink-muted); font-size: 0.9rem; max-width: 22rem; }
.footer-col h4 {
  margin: 0 0 0.75rem;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  font-weight: 650;
  font-family: var(--font);
}
.footer-col a {
  display: block;
  text-decoration: none;
  color: var(--ink-muted);
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
}
.footer-col a:hover { color: var(--ink); opacity: 1; }
.chat-placeholder {
  border: 1px dashed var(--border);
  background: var(--bg-alt);
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
  font-size: 0.82rem;
  color: var(--ink-muted);
}
.chat-placeholder code {
  font-size: 0.78em;
  background: var(--white);
  border: 1px solid var(--border);
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
}
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 1rem;
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.75rem;
  font-size: 0.8rem; color: var(--ink-soft);
}

/* Page hero small */
.page-hero { padding: 2.5rem 0 1.25rem; }
.page-hero p { max-width: 36rem; color: var(--ink-muted); margin: 0; }

/* Utility */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); border: 0;
}
.center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }

@media (max-width: 900px) {
  .hero-grid, .pdp, .split, .footer-grid { grid-template-columns: 1fr; }
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .trust-row { grid-template-columns: 1fr 1fr; }
  .swatch-tall { grid-row: auto; min-height: 140px; }
}
@media (max-width: 640px) {
  .nav-toggle { display: inline-flex; }
  .nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    padding-bottom: 0.75rem;
  }
  .site-header .inner { flex-wrap: wrap; }
  .nav.is-open { display: flex; }
  .product-grid { grid-template-columns: 1fr; }
  .trust-row { grid-template-columns: 1fr; text-align: left; }
}

/* Product images (SVG placeholders) */
.product-media .product-img,
.pdp-media .product-img,
.pdp-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.pdp-media {
  position: relative;
}
.pdp-media .swatch-fill,
.pdp-media [data-pdp-media] {
  width: 100%;
  height: 100%;
}
.pdp-note {
  margin-top: 1rem;
  padding: 0.85rem 1rem;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.88rem;
  color: var(--ink-muted);
}
.pdp-note strong { color: var(--ink); }
.pdp-cta-label {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  font-weight: 650;
  margin: 1.25rem 0 0.55rem;
}

/* On-site FAQ chat widget */
.lf-chat {
  position: fixed;
  right: 1.1rem;
  bottom: 1.1rem;
  z-index: 60;
  font-family: var(--font);
}
.lf-chat-launch {
  border: none;
  background: var(--ink);
  color: var(--white);
  border-radius: 999px;
  padding: 0.85rem 1.2rem;
  font-weight: 650;
  font-size: 0.9rem;
  cursor: pointer;
  box-shadow: var(--shadow);
}
.lf-chat-launch.is-open { opacity: 0.85; }
.lf-chat-panel {
  position: absolute;
  right: 0;
  bottom: 3.4rem;
  width: min(360px, calc(100vw - 1.5rem));
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  max-height: min(520px, calc(100vh - 6rem));
}
.lf-chat-panel[hidden] { display: none !important; }
.lf-chat-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.9rem 1rem;
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
}
.lf-chat-head strong { display: block; font-size: 0.95rem; }
.lf-chat-head span { font-size: 0.75rem; color: var(--ink-soft); }
.lf-chat-close {
  border: none;
  background: transparent;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  color: var(--ink-muted);
}
.lf-chat-log {
  padding: 0.85rem 1rem;
  overflow-y: auto;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  min-height: 180px;
}
.lf-msg {
  max-width: 92%;
  padding: 0.55rem 0.75rem;
  border-radius: 12px;
  font-size: 0.86rem;
  line-height: 1.45;
}
.lf-msg-bot {
  background: var(--bg-alt);
  color: var(--ink);
  align-self: flex-start;
  border: 1px solid var(--border);
}
.lf-msg-user {
  background: var(--ink);
  color: var(--white);
  align-self: flex-end;
}
.lf-chat-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  padding: 0 1rem 0.55rem;
}
.lf-chip {
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--ink-muted);
  border-radius: 999px;
  padding: 0.28rem 0.6rem;
  font-size: 0.72rem;
  cursor: pointer;
}
.lf-chip:hover { border-color: var(--ink-muted); color: var(--ink); }
.lf-chat-form {
  display: flex;
  gap: 0.4rem;
  padding: 0.65rem 0.85rem;
  border-top: 1px solid var(--border);
}
.lf-chat-form input {
  flex: 1;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.55rem 0.85rem;
  font: inherit;
  background: var(--bg);
}
.lf-chat-form button {
  border: none;
  background: var(--accent);
  color: var(--white);
  border-radius: 999px;
  padding: 0.55rem 0.9rem;
  font-weight: 650;
  cursor: pointer;
}
.lf-chat-foot {
  margin: 0;
  padding: 0 1rem 0.75rem;
  font-size: 0.72rem;
  color: var(--ink-soft);
}
.lf-chat-foot a { color: var(--accent-deep); }
.chat-placeholder.is-ready {
  border-style: solid;
  background: var(--bg);
}
