:root {
  --bg: #0e0e11;
  --surface: #17171c;
  --surface-2: #1e1e24;
  --border: #2a2a32;
  --text: #ece9e3;
  --muted: #9a968c;
  --accent: #e0b34d;
  --accent-soft: rgba(224, 179, 77, 0.14);
  --live: #4ec98a;
  --radius: 16px;
  --maxw: 1080px;
  --font-head: "Bricolage Grotesque", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
}

:root[data-theme="light"] {
  --bg: #f6f4ef;
  --surface: #ffffff;
  --surface-2: #f0ede6;
  --border: #e0dbd0;
  --text: #1a1917;
  --muted: #6d6a62;
  --accent: #b8862a;
  --accent-soft: rgba(184, 134, 42, 0.12);
  --live: #1f9d5f;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.grid-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 46px 46px;
  opacity: 0.35;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 20%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 20%, transparent 80%);
  pointer-events: none;
}

/* HEADER */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 20px 24px;
  backdrop-filter: blur(8px);
}

.wordmark {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 19px;
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 9px;
}
.wordmark-thin { font-weight: 500; color: var(--muted); display: inline-flex; align-items: center; }
.lab-icon { width: 14px; height: 18px; margin-left: 5px; }
.lab-icon .glass { fill: none; stroke: var(--accent); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.lab-icon .liquid { fill: var(--accent); opacity: 0.9; }
.lab-icon .bub { fill: var(--bg); }
.wordmark-mark {
  width: 16px; height: 16px;
  border: 2.5px solid var(--accent);
  border-radius: 4px;
  transform: rotate(45deg);
  display: inline-block;
}

.nav { display: flex; align-items: center; gap: 26px; }
.nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.15s;
}
.nav a:hover { color: var(--text); }

.theme-toggle {
  width: 34px; height: 34px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface);
  cursor: pointer;
  position: relative;
}
.theme-toggle::before {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: 15px; height: 15px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: inset -4px -4px 0 0 var(--surface);
}
:root[data-theme="light"] .theme-toggle::before {
  box-shadow: none;
  background: var(--accent);
}

/* HERO */
.hero {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 90px 24px 70px;
  text-align: center;
}
.eyebrow {
  font-family: var(--font-mono);
  font-size: 12.5px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent);
  margin-bottom: 22px;
}
.hero-title {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: clamp(2.4rem, 6.5vw, 4.6rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
}
.hero-sub {
  max-width: 560px;
  margin: 26px auto 0;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.18rem);
}
.hero-cta {
  margin-top: 38px;
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

/* BUTTONS */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  padding: 12px 22px;
  border-radius: 11px;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.12s, background 0.15s, border-color 0.15s;
}
.btn:active { transform: translateY(1px); }
.btn-sm { padding: 10px 16px; font-size: 14px; }
.btn-primary { background: var(--accent); color: #1a1400; }
.btn-primary:hover { background: #ecc264; }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

/* SECTIONS */
.section {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 60px 24px;
}
.section-label {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 28px;
  letter-spacing: 0.04em;
}

/* PRODUCTS */
.products {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.product {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 0.2s, transform 0.2s;
}
.product--live:hover { border-color: var(--accent); transform: translateY(-3px); }
.product--soon { opacity: 0.82; }
.product-shot {
  display: block;
  border-bottom: 1px solid var(--border);
  background: #000;
}
.product-shot img,
.product-shot video {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1200 / 588;
  object-fit: cover;
  transition: opacity 0.2s;
}
.product-shot:hover img,
.product-shot:hover video { opacity: 0.9; }
.product-body { padding: 26px 30px 30px; }
.product-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.product-name {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.6rem;
  letter-spacing: -0.02em;
}
.badge {
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 600;
  padding: 5px 11px;
  border-radius: 999px;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.badge-live { background: rgba(78,201,138,0.12); color: var(--live); }
.badge-live .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--live);
  box-shadow: 0 0 0 0 rgba(78,201,138,0.5);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(78,201,138,0.5); }
  70% { box-shadow: 0 0 0 6px rgba(78,201,138,0); }
  100% { box-shadow: 0 0 0 0 rgba(78,201,138,0); }
}
.badge-soon { background: var(--surface-2); color: var(--muted); border: 1px solid var(--border); }
.product-claim { font-weight: 600; margin-bottom: 8px; }
.product-desc { color: var(--muted); font-size: 15px; margin-bottom: 22px; }
.product-links { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.link-muted {
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
  border-bottom: 1px solid transparent;
}
.link-muted:hover { color: var(--text); border-bottom-color: var(--muted); }

/* TEAM */
.team {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.member {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
}
.avatar {
  width: 56px; height: 56px;
  border-radius: 14px;
  object-fit: cover;
  background: var(--accent-soft);
  border: 1px solid var(--border);
  display: block;
  margin-bottom: 18px;
}
.member-name {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.01em;
}
.member-role {
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 4px 0 12px;
}
.member-bio { color: var(--muted); font-size: 14.5px; margin-bottom: 20px; }
.member-bio em { color: var(--text); font-style: normal; }

.socials { display: flex; gap: 10px; }
.socials a {
  width: 36px; height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: 9px;
  color: var(--muted);
  transition: color 0.15s, border-color 0.15s, background 0.15s;
}
.socials a:hover { color: var(--accent); border-color: var(--accent); background: var(--accent-soft); }
.socials svg {
  width: 18px; height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.mw-mark {
  display: inline-block;
  width: 18px; height: 18px;
  background-color: currentColor;
  -webkit-mask-image: url("assets/makerworld-logo.png");
  mask-image: url("assets/makerworld-logo.png");
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
}

/* CONTACT */
.contact { text-align: center; padding-top: 40px; padding-bottom: 90px; }
.contact-title {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: clamp(1.8rem, 4.5vw, 3rem);
  letter-spacing: -0.03em;
  margin-bottom: 30px;
}
.contact-links { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* FOOTER */
.site-footer {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 28px 24px 48px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: var(--muted);
  font-size: 14px;
  flex-wrap: wrap;
}
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--accent); }

/* RESPONSIVE */
@media (max-width: 760px) {
  .products, .team { grid-template-columns: 1fr; }
  .nav { gap: 16px; }
  .nav a { display: none; }
  .hero { padding-top: 60px; }
}
