:root {
  --ink: #1d1b19;
  --muted: #6f6962;
  --cream: #f7f2eb;
  --paper: #fffdf9;
  --line: #ded6cc;
  --gold: #b78a56;
  --max-width: 1180px;
  --radius: 18px;
  --shadow: 0 18px 48px rgba(29, 27, 25, 0.09);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.65;
}
a { color: inherit; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}
.container { width: min(calc(100% - 40px), var(--max-width)); margin: 0 auto; }
.section { padding: 96px 0; }
.hero { padding: 150px 0 100px; background: var(--cream); }
.factory-hero {
  color: var(--paper);
  background:
    linear-gradient(90deg, rgba(18, 23, 22, 0.86), rgba(18, 23, 22, 0.38)),
    url('/images/factory/factory-hero.webp') center / cover;
}
.factory-hero .eyebrow { color: #e4b984; }
.factory-hero .lede { color: rgba(255, 253, 249, 0.84); }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px; border: 1px solid var(--ink); border-radius: 999px; text-decoration: none; font-weight: 700; }
.btn-primary { color: var(--paper); background: var(--ink); }
.btn-secondary { background: transparent; }
.product-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.product-card { overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); box-shadow: 0 8px 24px rgba(29, 27, 25, .04); }
.product-card img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; background: var(--cream); }
.product-card__body { padding: 22px; }
.whatsapp-link { color: #1f7a4d; font-weight: 700; }

.catalog-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 28px 0 30px;
}

.catalog-filter {
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: var(--paper);
  cursor: pointer;
  font-weight: 750;
}

.catalog-filter[aria-pressed="true"],
.catalog-filter:hover {
  border-color: var(--ink);
  color: var(--paper);
  background: var(--ink);
}

.catalog-status {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 0.92rem;
}

.catalog-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.catalog-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
}

.catalog-card img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background: var(--cream);
}

.catalog-card__body { padding: 15px 16px 18px; }
.catalog-card__collection {
  margin-bottom: 5px;
  color: var(--gold);
  font-size: 0.73rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.catalog-card h3 { margin-bottom: 0; font-size: 1rem; }

.factory-gallery .product-card img { aspect-ratio: 4 / 3; }

img {
  max-width: 100%;
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  color: inherit;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  line-height: 1.16;
  letter-spacing: -0.025em;
}

h1 {
  margin-bottom: 24px;
  font-size: clamp(2.75rem, 7vw, 5.75rem);
}

h2 {
  margin-bottom: 20px;
  font-size: clamp(2rem, 4vw, 3.5rem);
}

h3 {
  margin-bottom: 10px;
  font-size: 1.25rem;
}

.eyebrow {
  margin-bottom: 14px;
  color: var(--gold);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.lede {
  max-width: 720px;
  color: var(--muted);
  font-size: clamp(1.05rem, 2vw, 1.3rem);
}

.site-header {
  position: fixed;
  z-index: 1000;
  top: 0;
  right: 0;
  left: 0;
  border-bottom: 1px solid rgba(222, 214, 204, 0.8);
  background: rgba(255, 253, 249, 0.92);
  backdrop-filter: blur(18px);
}

.site-header__inner {
  display: flex;
  min-height: 76px;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.site-logo {
  flex: 0 0 auto;
  font-size: 1.05rem;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-decoration: none;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.site-nav a {
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 700;
  text-decoration: none;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--ink);
}

.site-nav .btn {
  color: var(--paper);
}

.menu-toggle {
  display: none;
  width: 48px;
  height: 48px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  cursor: pointer;
}

.hero__inner {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  align-items: center;
  gap: 72px;
}

.hero__actions,
.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.btn-primary:hover {
  border-color: var(--gold);
  background: var(--gold);
}

.btn-secondary:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.split-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: center;
  gap: clamp(40px, 7vw, 88px);
}

.split-layout--top {
  align-items: start;
}

.split-layout__media {
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--cream);
  box-shadow: var(--shadow);
}

.split-layout__media img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.metric-card {
  min-height: 180px;
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: 0 8px 24px rgba(29, 27, 25, 0.04);
}

.metric-card__value {
  display: block;
  margin-bottom: 8px;
  color: var(--gold);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 850;
  line-height: 1;
}

.metric-card p,
.product-card p {
  margin-bottom: 0;
  color: var(--muted);
}

.product-card h2,
.product-card h3 {
  margin-bottom: 8px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  margin-bottom: 28px;
  color: var(--muted);
  font-size: 0.9rem;
}

.breadcrumb a:hover {
  color: var(--gold);
}

.quote-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px 20px;
  padding: clamp(24px, 5vw, 44px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow);
}

.quote-form label {
  display: block;
  margin-bottom: 7px;
  font-weight: 750;
}

.quote-form input,
.quote-form textarea,
.quote-form select {
  width: 100%;
  min-height: 48px;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
  background: var(--paper);
}

.quote-form textarea {
  min-height: 150px;
  resize: vertical;
}

.quote-form__full,
.quote-form > p,
.quote-form > .btn {
  grid-column: 1 / -1;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-footer {
  padding: 56px 0 36px;
  border-top: 1px solid var(--line);
  background: var(--cream);
}

.site-footer__inner {
  display: grid;
  grid-template-columns: 1.25fr repeat(2, minmax(140px, 0.75fr));
  gap: 40px;
}

.site-footer h2,
.site-footer h3 {
  font-size: 1rem;
  letter-spacing: 0;
}

.site-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer a {
  color: var(--muted);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--gold);
}

.site-footer__legal {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.88rem;
}

@media (max-width: 820px) {
  .section { padding: 68px 0; }
  .hero { padding-top: 120px; }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .catalog-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }

  .menu-toggle {
    display: inline-flex;
  }

  .site-nav {
    position: absolute;
    top: calc(100% + 1px);
    right: 20px;
    left: 20px;
    display: none;
    align-items: stretch;
    flex-direction: column;
    gap: 0;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--paper);
    box-shadow: var(--shadow);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 12px 14px;
  }

  .site-nav .btn {
    margin-top: 6px;
  }

  .hero__inner,
  .split-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .metric-grid {
    grid-template-columns: 1fr;
  }

  .site-footer__inner {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .container { width: min(calc(100% - 28px), var(--max-width)); }
  .product-grid { grid-template-columns: 1fr; }
  .catalog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .btn { width: 100%; }

  .site-header__inner {
    min-height: 68px;
  }

  .site-nav {
    right: 14px;
    left: 14px;
  }

  .hero {
    padding-bottom: 72px;
  }

  .quote-form,
  .site-footer__inner {
    grid-template-columns: 1fr;
  }

  .quote-form > * {
    grid-column: 1;
  }
}
