/* ---------- Design tokens ---------- */
:root {
  --bg: #18100e;
  --bg-elevated: #241a17;
  --bg-elevated-2: #2d211d;
  --text: #f3ede2;
  --text-muted: #b3a89b;
  --thread: #cf9f3f;
  --thread-dim: #8a7038;
  --ink: #3f9c86;
  --ink-dim: #3a6b5f;
  --border: #3d2f29;

  --font-display: "Fraunces", serif;
  --font-body: "IBM Plex Sans", sans-serif;
  --font-mono: "IBM Plex Mono", monospace;

  --container: 1140px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

h1, h2, h3 { font-family: var(--font-display); font-weight: 500; margin: 0; }

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

/* subtle grain overlay */
.noise {
  position: fixed; inset: 0; pointer-events: none; z-index: 1;
  opacity: 0.03; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; justify-content: space-between;
  padding: 22px 6vw;
  background: rgba(24, 16, 14, 0.85);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.nav__brand {
  font-family: var(--font-display);
  font-size: 1.25rem;
  letter-spacing: 0.06em;
}

.nav__links { display: flex; align-items: center; gap: 32px; }

.nav__links a {
  font-size: 0.95rem;
  color: var(--text-muted);
  transition: color 0.2s;
}

.nav__links a:hover { color: var(--text); }

.nav__cta {
  padding: 8px 18px;
  border: 1px solid var(--thread);
  border-radius: 999px;
  color: var(--text) !important;
}

.nav__toggle { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 6px; }
.nav__toggle span { width: 22px; height: 1.5px; background: var(--text); display: block; }

/* ---------- Section basics ---------- */
main { position: relative; z-index: 2; }

section { padding: 110px 6vw; max-width: var(--container); margin: 0 auto; }

.section__eyebrow {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--thread);
  margin: 0 0 14px;
}

.section__title {
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  margin-bottom: 16px;
  max-width: 640px;
}

.section__sub { color: var(--text-muted); max-width: 540px; margin: 0 0 40px; }

.reveal { opacity: 0; transform: translateY(24px); }

/* ---------- Hero ---------- */
.hero {
  padding-top: 140px;
  padding-bottom: 120px;
  max-width: var(--container);
}

.hero__eyebrow {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0 0 20px;
}

.hero__title {
  font-size: clamp(2.4rem, 6vw, 4.6rem);
  line-height: 1.08;
  max-width: 780px;
}

.stitch-wrap { position: relative; display: inline-block; color: var(--thread); }

.stitch-line {
  position: absolute;
  left: 0; bottom: -6px;
  width: 100%; height: 16px;
}

.stitch-line path {
  fill: none;
  stroke: var(--thread);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-dasharray: 900;
  stroke-dashoffset: 900;
}

.hero__sub {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 520px;
  margin: 28px 0 40px;
}

.hero__actions { display: flex; gap: 18px; flex-wrap: wrap; }

.btn {
  display: inline-block;
  padding: 14px 30px;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 500;
  transition: transform 0.2s, background 0.2s, border-color 0.2s;
}

.btn--primary { background: var(--thread); color: #1b1108; }
.btn--primary:hover { transform: translateY(-2px); }

.btn--ghost { border: 1px solid var(--border); color: var(--text); }
.btn--ghost:hover { border-color: var(--text-muted); transform: translateY(-2px); }

/* ---------- Services ---------- */
.services__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  margin-top: 20px;
}

.service-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 40px;
  transition: transform 0.25s, border-color 0.25s;
}

.service-card:hover { transform: translateY(-4px); }

.service-card--thread { border-top: 2px solid var(--thread); }
.service-card--ink { border-top: 2px solid var(--ink); }

.service-card__icon { width: 48px; height: 48px; margin-bottom: 24px; }
.service-card--thread .service-card__icon { color: var(--thread); }
.service-card--ink .service-card__icon { color: var(--ink); }
.service-card__icon svg { width: 100%; height: 100%; }

.service-card h3 { font-size: 1.4rem; margin-bottom: 12px; }
.service-card p { color: var(--text-muted); margin: 0 0 28px; }

.service-card__specs { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 12px; }

.service-card__specs li {
  font-size: 0.92rem;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
  display: flex; justify-content: space-between; gap: 16px;
}

.service-card__specs li:first-child { border-top: none; padding-top: 0; }

.service-card__specs span {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ---------- Catalog ---------- */
.catalog__filters {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
  margin-bottom: 40px;
}

.catalog__divider {
  width: 1px; height: 22px; background: var(--border); margin: 0 6px;
}

.chip {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: none;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
}

.chip:hover { border-color: var(--text-muted); color: var(--text); }
.chip.is-active { background: var(--text); color: var(--bg); border-color: var(--text); }

.chip--thread.is-active { background: var(--thread); border-color: var(--thread); color: #1b1108; }
.chip--ink.is-active { background: var(--ink); border-color: var(--ink); color: #08201a; }

.catalog__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 24px;
}

.product-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  transition: transform 0.25s, opacity 0.25s;
}

.product-card:hover { transform: translateY(-4px); }

.product-card.is-hidden { display: none; }

.product-card__visual {
  aspect-ratio: 4 / 3;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
  background:
    repeating-linear-gradient(135deg, transparent 0 10px, rgba(255,255,255,0.03) 10px 20px);
  border-bottom: 1px solid var(--border);
}

.product-card__body { padding: 18px 20px 22px; }

.product-card__body h4 { font-family: var(--font-body); font-size: 1.02rem; font-weight: 600; margin: 0 0 8px; }

.product-card__tags { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }

.tag {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  padding: 3px 9px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.tag--stick { background: rgba(207, 159, 63, 0.15); color: var(--thread); }
.tag--dtf { background: rgba(63, 156, 134, 0.15); color: var(--ink); }

.product-card__price { color: var(--text-muted); font-size: 0.9rem; }

/* ---------- References ---------- */
.references__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.reference-tile {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: repeating-linear-gradient(45deg, var(--bg-elevated) 0 14px, var(--bg-elevated-2) 14px 28px);
}

.reference-tile__overlay {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 20px;
  background: linear-gradient(to top, rgba(0,0,0,0.75), transparent 60%);
  opacity: 0; transition: opacity 0.25s;
}

.reference-tile:hover .reference-tile__overlay { opacity: 1; }

.reference-tile__overlay strong { font-size: 1rem; }
.reference-tile__overlay span {
  font-family: var(--font-mono); font-size: 0.72rem; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.05em;
}

/* ---------- Process ---------- */
.process__steps {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px;
}

.process__steps li {
  border-top: 1px solid var(--border);
  padding-top: 20px;
}

.process__num {
  font-family: var(--font-mono);
  color: var(--thread);
  font-size: 0.85rem;
}

.process__steps h3 { font-size: 1.1rem; margin: 12px 0 8px; }
.process__steps p { color: var(--text-muted); font-size: 0.92rem; margin: 0; }

/* ---------- Contact ---------- */
.contact {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 60px;
  align-items: start;
}

.contact__direct { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.contact__direct a { color: var(--text); border-bottom: 1px solid var(--border); width: fit-content; padding-bottom: 2px; }
.contact__direct a:hover { border-color: var(--thread); }

.contact__form {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 36px;
  display: flex; flex-direction: column; gap: 20px;
}

.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

.contact__form label { display: flex; flex-direction: column; gap: 8px; font-size: 0.85rem; color: var(--text-muted); }

.contact__form input,
.contact__form select,
.contact__form textarea {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.95rem;
  resize: vertical;
}

.contact__form input:focus,
.contact__form select:focus,
.contact__form textarea:focus {
  outline: 2px solid var(--thread);
  outline-offset: 1px;
}

.form__note { font-size: 0.85rem; color: var(--ink); min-height: 1.2em; margin: 0; }

/* ---------- Footer ---------- */
.footer {
  display: flex; justify-content: space-between;
  padding: 32px 6vw;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .services__grid { grid-template-columns: 1fr; }
  .process__steps { grid-template-columns: 1fr 1fr; }
  .contact { grid-template-columns: 1fr; }
  .form__row { grid-template-columns: 1fr; }

  .nav__toggle { display: flex; }
  .nav__links {
    position: absolute; top: 100%; left: 0; right: 0;
    background: var(--bg-elevated);
    flex-direction: column; align-items: flex-start;
    padding: 24px 6vw; gap: 20px;
    border-bottom: 1px solid var(--border);
    display: none;
  }
  .nav__links.is-open { display: flex; }
}

@media (max-width: 560px) {
  .process__steps { grid-template-columns: 1fr; }
  section { padding: 80px 6vw; }
}
