:root {
  --cream: #fbf4ea;
  --paper: #ffffff;
  --sand: #f1e8db;
  --ink: #2b2722;
  --ink-soft: #5f574d;
  --ink-faint: #877e72;
  --rule: #e4d9c9;
  --rule-strong: #2b2722;
  --rule-soft: #e9e0d3;
  --pine: #1f3527;
  --pine-line: #3a5444;
  --on-pine: #f6f2ea;
  --on-pine-soft: #b9c6ba;
  --espresso: #3a2a21;
  --on-espresso-soft: #d9c9b6;
  --sage: #56705c;
  --accent: #d9ecae;
  --tile-coffee: #efe5d6;
  --tile-kitchen: #e7e9df;
  --tile-home: #e2e9e3;
  --tile-textile: #f1e5db;

  --sans: "Nunito Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --serif: "Newsreader", "Times New Roman", serif;
  --radius: 8px;
  --gutter: clamp(16px, 2.6vw, 40px);
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-reveal: cubic-bezier(0.19, 1, 0.22, 1);
  --ease-wipe: cubic-bezier(0.77, 0, 0.175, 1);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--sans);
  font-optical-sizing: auto;
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; }
img { display: block; max-width: 100%; }

section[id], article[id] { scroll-margin-top: 84px; }

a:focus-visible,
button:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; border-radius: 4px; }

.wrap { max-width: 1440px; margin: 0 auto; padding: 0 var(--gutter); }

h1, h2, h3 { font-weight: 400; letter-spacing: -0.02em; margin: 0; }

.section-head { display: flex; justify-content: space-between; align-items: end; gap: 16px 32px; flex-wrap: wrap; margin-bottom: 28px; }
.section-head h2 { font-size: clamp(2rem, 4vw, 3.25rem); line-height: 1.02; letter-spacing: -0.03em; }

/* Underline that wipes in from the left and out to the right */
.uline { position: relative; text-decoration: none; }
.uline::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 550ms var(--ease-wipe);
}
.uline[aria-current="page"]::after { transform: scaleX(1); }

/* Bigger tap area for small text links without changing their layout */
.header-end .mobile-only::before,
.shop-tools .uline::before,
.product-actions .details::before,
.room-items a::before { content: ""; position: absolute; inset: -12px -6px; }


/* Top bar */
.topbar { background: var(--pine); color: var(--on-pine); font-size: 0.8125rem; }
.topbar .wrap { display: flex; align-items: center; gap: 16px; min-height: 36px; }
.topbar a { text-decoration: none; }
.topbar .spacer { flex: 1; }
.region { display: flex; align-items: center; gap: 2px; }
.region button {
  font: inherit;
  color: var(--on-pine-soft);
  background: none;
  border: 0;
  padding: 8px 6px;
  cursor: pointer;
  transition: color 160ms ease, transform 160ms var(--ease-out);
}
.region button:active { transform: scale(0.95); }
.region button[aria-pressed="true"] { color: var(--on-pine); text-decoration: underline; text-underline-offset: 4px; }
.region span { color: var(--on-pine-soft); }

/* Header */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(251, 244, 234, 0.97); border-bottom: 1px solid var(--rule); }
.site-header .wrap { display: flex; align-items: center; gap: 40px; min-height: 68px; }
.wordmark { font-family: var(--serif); font-weight: 500; font-size: 1.625rem; letter-spacing: -0.035em; text-decoration: none; padding: 8px 0; }
.nav { display: flex; gap: 28px; }
.nav a { font-size: 0.9375rem; font-weight: 500; padding: 6px 0; }
.header-end { margin-left: auto; display: flex; align-items: center; gap: 20px; }
.header-end .mobile-only { display: none; font-weight: 500; font-size: 0.9375rem; }

/* Pills */
.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 999px;
  border: 1px solid var(--rule);
  background: var(--paper);
  color: var(--ink);
  font: 600 0.875rem/1 var(--sans);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease, transform 160ms var(--ease-out);
}
.pill:active { transform: scale(0.97); }
.pill.dark { background: var(--pine); border-color: var(--pine); color: var(--on-pine); }
.pill.ghost { background: transparent; border-color: rgba(246, 242, 234, 0.35); color: var(--on-pine); }
.pill.light { background: var(--on-pine); border-color: var(--on-pine); color: var(--pine); }
.pill.small { min-height: 36px; padding: 0 14px; font-size: 0.8125rem; }

/* Hero band */
.hero { background: var(--espresso); color: var(--on-pine); }
.hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(28px, 4vw, 64px);
  padding-top: clamp(40px, 6vw, 80px);
  padding-bottom: clamp(40px, 6vw, 80px);
}
.hero h1 { font-size: clamp(3.25rem, 7.4vw, 6.75rem); line-height: 0.95; letter-spacing: -0.045em; font-weight: 300; }
.hero .lede { font-size: clamp(1.0625rem, 1.4vw, 1.25rem); line-height: 1.5; color: var(--on-espresso-soft); max-width: 40ch; margin: 24px 0 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 32px; }
.chips .label { font-size: 0.8125rem; color: var(--on-espresso-soft); align-self: center; margin-right: 6px; }
.hero .media { aspect-ratio: 5 / 4; border-radius: 2px; }
.hero .media img { object-position: 30% 70%; }

/* Media frames: clip reveal + slow scroll drift */
.media { position: relative; overflow: hidden; background: var(--sand); }
.media-inner { position: absolute; inset: 0; }
.media img { position: absolute; left: 0; top: -8%; width: 100%; height: 116%; object-fit: cover; will-change: transform; }

/* Category row */
.categories { background: var(--paper); padding: clamp(40px, 5vw, 64px) 0 clamp(36px, 4vw, 52px); }
.cat-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.cat { display: flex; flex-direction: column; gap: 2px; text-decoration: none; transition: transform 160ms var(--ease-out); }
.cat:active { transform: scale(0.97); }
.cat-photo { display: block; aspect-ratio: 4 / 5; overflow: hidden; border-radius: 2px; background: var(--sand); margin-bottom: 12px; }
.cat-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform 500ms var(--ease-out); }
.cat-name { font-size: 1.0625rem; font-weight: 700; }
.cat-count { font-size: 0.8125rem; color: var(--ink-faint); }

/* Shop grid */
.shop { padding: clamp(64px, 8vw, 112px) 0; }
.tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.tabs button { font: 600 0.875rem/1 var(--sans); }
.tabs button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--cream); }
.shop .section-head { align-items: center; }
.shop-tools { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 28px; }
.shop-tools .uline { font-size: 0.875rem; font-weight: 600; }
.grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 40px 16px; }
.product { display: flex; flex-direction: column; }
.product-art { position: relative; aspect-ratio: 4 / 5; display: flex; flex-direction: column; justify-content: space-between; padding: clamp(14px, 1.6vw, 22px); background: var(--tile-coffee); border-radius: 4px; margin-bottom: 14px; overflow: hidden; }
.product-art img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.art-brand { font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.01em; }
.art-spec { font-size: clamp(1.5rem, 2.3vw, 2.25rem); font-weight: 300; line-height: 1.02; letter-spacing: -0.035em; max-width: 9ch; }
.product-art[data-cat="kitchen"] { background: var(--tile-kitchen); }
.product-art[data-cat="home"] { background: var(--tile-home); }
.product-art[data-cat="textiles"] { background: var(--tile-textile); }
.tag { position: absolute; top: clamp(14px, 1.6vw, 22px); right: clamp(14px, 1.6vw, 22px); background: var(--paper); border-radius: 3px; padding: 3px 8px; font-size: 0.75rem; font-weight: 600; }
.tag.set { background: var(--accent); color: var(--pine); }
.product .brand { margin: 0 0 2px; font-size: 0.8125rem; color: var(--ink-faint); }
.product h3 { font-size: 1.125rem; font-weight: 600; letter-spacing: -0.01em; line-height: 1.25; }
.product .desc { font-size: 0.875rem; color: var(--ink-soft); margin: 8px 0 14px; line-height: 1.5; }
.product-actions { margin-top: auto; display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.product-actions .details { font-size: 0.8125rem; color: var(--ink-soft); }

/* Room sets */
.rooms { padding: 0 0 clamp(64px, 8vw, 112px); }
.rooms .section-head p { margin: 0; max-width: 46ch; color: var(--ink-soft); }
.room-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.room { display: flex; flex-direction: column; background: var(--paper); border-radius: var(--radius); padding: 22px 22px 24px; }
.room-meta { font-size: 0.875rem; color: var(--ink-faint); margin-top: 4px; }
.room h3 { font-size: clamp(1.5rem, 2.2vw, 1.875rem); line-height: 1.08; letter-spacing: -0.025em; }
.room-copy { margin: 10px 0 18px; font-size: 0.9375rem; color: var(--ink-soft); line-height: 1.5; }
.room .media { aspect-ratio: 4 / 3; border-radius: 2px; }
.room-items { list-style: none; margin: 18px 0 0; padding: 0; }
.room-items li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--rule); font-size: 0.875rem; }
.room-items .qty { color: var(--ink-faint); }
.room-items a { flex: none; white-space: nowrap; font-weight: 600; }
.room-buy { margin-top: auto; padding-top: 14px; display: grid; gap: 8px; }
.room-buy .pill { width: 100%; }
.room-buy small { color: var(--ink-faint); font-size: 0.8125rem; line-height: 1.4; }

/* Guide card */
.guide-card { background: var(--sage); color: var(--on-pine); border-radius: var(--radius); padding: clamp(32px, 5vw, 64px); display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 24px 48px; align-items: end; }
.guide-card h2 { font-size: clamp(1.875rem, 3.6vw, 3rem); line-height: 1.04; letter-spacing: -0.03em; }
.guide-card p { margin: 14px 0 0; color: #e2e9e1; max-width: 44ch; }
.guide-card .actions { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.guide-card .actions .uline { font-size: 0.9375rem; }

/* How it works tiles */
.how { padding: clamp(64px, 8vw, 112px) 0; }
.steps { list-style: none; counter-reset: step; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.steps li { counter-increment: step; border-top: 1px solid var(--rule-strong); padding-top: 14px; font-size: 1.0625rem; line-height: 1.55; color: var(--ink-soft); max-width: 38ch; }
.steps li::before { content: counter(step) ". "; color: var(--ink); font-weight: 700; }

/* Footer */
.site-footer { background: var(--pine); color: var(--on-pine-soft); padding: clamp(48px, 6vw, 80px) 0 32px; font-size: 0.875rem; }
.footer-top { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 2fr); gap: 40px; padding-bottom: 48px; }
.footer-line { margin: 0; font-size: 0.9375rem; line-height: 1.6; color: var(--on-pine-soft); max-width: 36ch; }
.footer-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.footer-cols h2 { font-size: 0.9375rem; font-weight: 700; letter-spacing: 0; color: var(--on-pine); margin-bottom: 12px; }
.footer-cols ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.site-footer a { color: var(--on-pine); }
.disclosure { border-top: 1px solid var(--pine-line); padding: 20px 0 0; font-size: 0.8125rem; color: #a7b5a7; }
.disclosure p { margin: 0 0 6px; }

/* Privacy page */
.policy { padding: clamp(56px, 8vw, 104px) 0 32px; }
.policy .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 24px; }
.policy h1 { font-size: clamp(2.5rem, 5vw, 4rem); line-height: 1; letter-spacing: -0.035em; font-weight: 300; }
.policy .updated { color: var(--ink-faint); margin: 12px 0 0; font-size: 0.875rem; }
.policy article { max-width: 64ch; }
.policy article > p:first-child { margin-top: 0; }
.policy h2 { font-size: 1.5rem; margin: 40px 0 10px; padding-top: 14px; border-top: 1px solid var(--rule); }
.policy p, .policy li { color: var(--ink-soft); line-height: 1.65; }
.policy li { margin-bottom: 8px; }
.policy strong { color: var(--ink); font-weight: 700; }

/* Responsive */
@media (max-width: 1100px) {
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .room-cards { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 800px) {
  .nav { display: none; }
  .header-end .mobile-only { display: inline; }
  .site-header .wrap { min-height: 60px; gap: 16px; }
  .hero .wrap { grid-template-columns: 1fr; }
  .hero .media { aspect-ratio: 4 / 3; }
  .cat-row { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 12px; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 10px; }
  .product .desc { display: none; }
  .product-actions { margin-top: 12px; }
  .product-art .tag.set { display: none; }
  .room-cards { grid-template-columns: 1fr; }
  .guide-card { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .policy .wrap { grid-template-columns: 1fr; }
  .topbar .msg { display: none; }
}

@media (max-width: 520px) {
  .footer-cols { grid-template-columns: 1fr 1fr; }
  .header-end .pill { padding: 0 14px; }
  .chips .label { width: 100%; }
}

/* Hover movement only where a real pointer can hover; on phones a tap would leave it stuck. */
@media (hover: hover) and (pointer: fine) {
  .uline:hover::after { transform: scaleX(1); transform-origin: left; }
  .pill:hover { border-color: var(--ink); }
  .pill.dark:hover { background: #2b4636; border-color: #2b4636; }
  .pill.ghost:hover { border-color: var(--on-pine); background: rgba(246, 242, 234, 0.08); }
  .pill.light:hover { background: var(--paper); }
  .tabs button[aria-pressed="true"]:hover { border-color: var(--ink); }
  .cat:hover .cat-photo img { transform: scale(1.03); }
  .cat:hover .cat-name { text-decoration: underline; text-underline-offset: 4px; }
}

/* Motion: headings rise line by line out of masks; photos reveal with a wipe. */
.line-mask { display: block; overflow: clip; padding-bottom: 0.08em; margin-bottom: -0.08em; }
.line { display: block; }

@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal-text] .line { transform: translateY(105%); transition: transform 1000ms var(--ease-reveal); transition-delay: calc(var(--i, 0) * 90ms); }
  .js [data-reveal-text].is-in .line { transform: none; }
  .js [data-reveal-text]:not(.is-split) { visibility: hidden; }

  /* The clip sits on the inner layer: a fully clipped target never reports as intersecting. */
  .js [data-reveal-media] { background: transparent; }
  .js [data-reveal-media] .media-inner {
    clip-path: inset(100% 0 0 0);
    transform: scale(1.12);
    transition: clip-path 1100ms var(--ease-reveal), transform 1500ms var(--ease-reveal);
  }
  .js [data-reveal-media].is-in .media-inner { clip-path: inset(0 0 0 0); transform: none; }
  .js .no-anim, .js .no-anim .media-inner { transition: none !important; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-property: color, background-color, border-color, opacity !important; }
  .pill:active, .cat:active, .region button:active { transform: none; }
}
