/* MoonLabs LLC — lunar theme */

@font-face {
  font-family: 'Space Grotesk';
  src: url('../fonts/space-grotesk-latin.woff2') format('woff2');
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #06060d;
  --bg-soft: #0b0c18;
  --surface: rgba(255, 255, 255, 0.028);
  --line: rgba(255, 255, 255, 0.09);
  --text: #eceef7;
  --muted: #a2a6c2;
  --faint: #6d7190;
  --moon: #f5f1e6;
  --accent: #b9a8ff;
  --accent-dim: rgba(185, 168, 255, 0.14);
  --font-display: 'Space Grotesk', system-ui, sans-serif;
  --font-body: system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --wrap: 1140px;
  --radius: 18px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

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

::selection { background: var(--accent); color: #0a0a14; }

a { color: inherit; }

img { display: block; max-width: 100%; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 24px;
}

/* ---------- sky & stars ---------- */

.sky {
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(1100px 700px at 78% -10%, rgba(120, 110, 220, 0.13), transparent 60%),
    radial-gradient(900px 600px at 10% 110%, rgba(90, 100, 200, 0.08), transparent 60%),
    linear-gradient(180deg, #07070f 0%, #06060d 40%, #05050b 100%);
}

.stars,
.stars::before,
.stars::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: '';
  background-repeat: repeat;
  pointer-events: none;
}

.stars {
  background-image:
    radial-gradient(1.5px 1.5px at 22px 34px, rgba(255,255,255,.9), transparent 55%),
    radial-gradient(1px 1px at 130px 80px, rgba(255,255,255,.55), transparent 55%),
    radial-gradient(1px 1px at 70px 150px, rgba(255,255,255,.7), transparent 55%),
    radial-gradient(1.5px 1.5px at 190px 190px, rgba(255,255,255,.4), transparent 55%),
    radial-gradient(1px 1px at 240px 60px, rgba(255,255,255,.8), transparent 55%),
    radial-gradient(1px 1px at 20px 230px, rgba(255,255,255,.5), transparent 55%);
  background-size: 280px 280px;
  animation: twinkle 7s ease-in-out infinite alternate;
}

.stars::before {
  background-image:
    radial-gradient(1px 1px at 40px 60px, rgba(255,255,255,.55), transparent 55%),
    radial-gradient(1.5px 1.5px at 160px 30px, rgba(255,255,255,.75), transparent 55%),
    radial-gradient(1px 1px at 300px 140px, rgba(255,255,255,.45), transparent 55%),
    radial-gradient(1px 1px at 90px 210px, rgba(255,255,255,.65), transparent 55%),
    radial-gradient(1px 1px at 220px 260px, rgba(255,255,255,.5), transparent 55%),
    radial-gradient(1.5px 1.5px at 350px 330px, rgba(255,255,255,.7), transparent 55%);
  background-size: 420px 420px;
  animation: twinkle 9s ease-in-out infinite alternate-reverse;
}

.stars::after {
  background-image:
    radial-gradient(1px 1px at 60px 100px, rgba(255,255,255,.4), transparent 55%),
    radial-gradient(1px 1px at 260px 40px, rgba(255,255,255,.55), transparent 55%),
    radial-gradient(1px 1px at 420px 200px, rgba(255,255,255,.45), transparent 55%),
    radial-gradient(1px 1px at 140px 320px, rgba(255,255,255,.6), transparent 55%),
    radial-gradient(1px 1px at 500px 380px, rgba(255,255,255,.4), transparent 55%);
  background-size: 560px 560px;
  animation: twinkle 11s ease-in-out infinite alternate;
}

@keyframes twinkle {
  from { opacity: 0.45; }
  to { opacity: 1; }
}

/* ---------- header ---------- */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: rgba(6, 6, 13, 0.55);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s ease, background 0.3s ease;
}

.site-header.scrolled {
  border-bottom-color: var(--line);
  background: rgba(6, 6, 13, 0.82);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 19px;
  letter-spacing: 0.01em;
  text-decoration: none;
}

.brand svg { display: block; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
  list-style: none;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 15px;
  transition: color 0.2s ease;
}

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

.nav-cta {
  display: inline-block;
  padding: 8px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text) !important;
  font-size: 14px;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.nav-cta:hover {
  border-color: rgba(245, 241, 230, 0.5);
  background: rgba(245, 241, 230, 0.06);
}

/* ---------- hero ---------- */

.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 140px 0 100px;
  overflow: hidden;
}

/* moon backdrop: dimmed, feathered into the night sky */
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

.hero-moon {
  position: absolute;
  left: 50%;
  top: 50%;
  width: clamp(520px, 95vmin, 1020px);
  height: auto;
  transform: translate(-50%, -36%);
  filter: brightness(0.5) saturate(0.85) contrast(1.03);
  -webkit-mask-image: radial-gradient(closest-side, #000 58%, transparent 96%);
  mask-image: radial-gradient(closest-side, #000 58%, transparent 96%);
}

/* scrim so copy stays readable over the moon */
.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(640px 420px at 50% 54%, rgba(6, 6, 13, 0.55), transparent 72%),
    linear-gradient(180deg, rgba(6, 6, 13, 0.35) 0%, transparent 26%, transparent 66%, var(--bg) 100%);
}

.hero-inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 26px;
}

.eyebrow::before,
.eyebrow::after {
  content: '';
  width: 34px;
  height: 1px;
}

.eyebrow::before { background: linear-gradient(90deg, transparent, var(--accent)); }
.eyebrow::after { background: linear-gradient(90deg, var(--accent), transparent); }

.hero h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(44px, 6.4vw, 84px);
  line-height: 1.02;
  letter-spacing: -0.025em;
  margin-bottom: 28px;
}

.hero h1 .moonlit {
  background: linear-gradient(115deg, #ffffff 20%, var(--moon) 45%, var(--accent) 90%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-sub {
  max-width: 54ch;
  color: var(--muted);
  font-size: clamp(16px, 1.6vw, 19px);
  margin: 0 auto 40px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 14px 26px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.btn-primary {
  background: var(--moon);
  color: #0b0b16;
  box-shadow: 0 0 0 0 rgba(245, 241, 230, 0.25), 0 10px 40px -12px rgba(245, 241, 230, 0.45);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 0 1px rgba(245, 241, 230, 0.35), 0 16px 50px -12px rgba(245, 241, 230, 0.5);
}

.btn-ghost {
  border: 1px solid var(--line);
  color: var(--text);
}

.btn-ghost:hover {
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.04);
  transform: translateY(-2px);
}

/* ---------- sections ---------- */

.section {
  padding: 110px 0;
  position: relative;
}

.section-head {
  max-width: 640px;
  margin-bottom: 64px;
}

.section-head h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(32px, 4vw, 52px);
  letter-spacing: -0.02em;
  line-height: 1.08;
  margin-bottom: 18px;
}

.section-head p {
  color: var(--muted);
  font-size: 17px;
}

.kicker {
  display: block;
  font-size: 13px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

/* ---------- products ---------- */

.products-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}

.product-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
  transform: translateY(-6px);
  border-color: rgba(185, 168, 255, 0.4);
  box-shadow: 0 30px 70px -30px rgba(120, 105, 230, 0.35);
}

.product-shot {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  aspect-ratio: 16 / 10;
}

.product-shot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.5s ease;
}

.product-card:hover .product-shot img { transform: scale(1.03); }

.product-body {
  padding: 28px 28px 30px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}

.product-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.tag {
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 12px;
}

.product-body h3 {
  font-family: var(--font-display);
  font-size: 27px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.product-body p {
  color: var(--muted);
  font-size: 15.5px;
  flex: 1;
}

.product-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  color: var(--moon);
  font-weight: 600;
  font-size: 15px;
}

.product-link .arrow { transition: transform 0.25s ease; }

.product-card:hover .product-link .arrow { transform: translate(3px, -3px); }

/* ---------- studio ---------- */

.studio-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.studio-copy p {
  color: var(--muted);
  margin-bottom: 20px;
  max-width: 52ch;
}

.studio-copy p strong { color: var(--text); font-weight: 600; }

.principles {
  display: grid;
  gap: 14px;
}

.principle {
  display: flex;
  gap: 18px;
  padding: 22px 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  transition: border-color 0.25s ease, background 0.25s ease;
}

.principle:hover {
  border-color: rgba(185, 168, 255, 0.32);
  background: rgba(255, 255, 255, 0.045);
}

.principle .num {
  font-family: var(--font-display);
  font-size: 14px;
  color: var(--accent);
  padding-top: 3px;
  min-width: 26px;
}

.principle h3 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 5px;
}

.principle p {
  color: var(--muted);
  font-size: 14.5px;
}

/* ---------- contact ---------- */

.contact-panel {
  position: relative;
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 6px);
  padding: clamp(40px, 6vw, 80px);
  text-align: center;
  background:
    radial-gradient(600px 300px at 50% -20%, rgba(185, 168, 255, 0.12), transparent 70%),
    var(--surface);
  overflow: hidden;
}

.contact-panel h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(30px, 4.4vw, 54px);
  letter-spacing: -0.02em;
  line-height: 1.08;
  margin-bottom: 18px;
}

.contact-panel p {
  color: var(--muted);
  max-width: 46ch;
  margin: 0 auto 36px;
}

.contact-meta {
  margin-top: 34px;
  display: flex;
  justify-content: center;
  gap: 28px;
  flex-wrap: wrap;
  color: var(--faint);
  font-size: 14px;
}

.contact-meta a {
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  transition: color 0.2s ease, border-color 0.2s ease;
}

.contact-meta a:hover {
  color: var(--moon);
  border-color: var(--moon);
}

/* ---------- footer ---------- */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 56px 0 44px;
  margin-top: 40px;
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  flex-wrap: wrap;
}

.footer-brand p {
  color: var(--faint);
  font-size: 14px;
  margin-top: 12px;
  max-width: 30ch;
}

.footer-cols {
  display: flex;
  gap: 72px;
  flex-wrap: wrap;
}

.footer-col h4 {
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--faint);
  margin-bottom: 14px;
  font-weight: 600;
}

.footer-col ul { list-style: none; display: grid; gap: 9px; }

.footer-col a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14.5px;
  transition: color 0.2s ease;
}

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

.phases {
  display: flex;
  gap: 10px;
  margin-top: 20px;
  align-items: center;
}

.phases span {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #1a1b2e;
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.phases span:nth-child(2) { background: linear-gradient(90deg, #1a1b2e 50%, #d8d4c6 50%); }
.phases span:nth-child(3) { background: linear-gradient(90deg, #1a1b2e 22%, #e3dfd0 22%); }
.phases span:nth-child(4) {
  background: var(--moon);
  box-shadow: 0 0 12px rgba(245, 241, 230, 0.5);
}

.footer-bottom {
  margin-top: 44px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  color: var(--faint);
  font-size: 13.5px;
}

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

/* ---------- legal pages ---------- */

.legal {
  padding: 160px 0 100px;
  max-width: 760px;
}

.legal h1 {
  font-family: var(--font-display);
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.legal .updated {
  color: var(--faint);
  font-size: 14px;
  margin-bottom: 48px;
}

.legal h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 600;
  margin: 44px 0 14px;
}

.legal p, .legal li {
  color: var(--muted);
  font-size: 16px;
  margin-bottom: 14px;
}

.legal ul { padding-left: 22px; }

.legal a {
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--line);
  text-underline-offset: 3px;
}

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

/* ---------- reveal on scroll ---------- */

html.js .reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

html.js .reveal.in {
  opacity: 1;
  transform: none;
}

/* ---------- responsive ---------- */

@media (max-width: 900px) {
  .hero { min-height: auto; padding-top: 150px; }
  .hero-moon { width: 150vmin; transform: translate(-50%, -30%); }
  .products-grid { grid-template-columns: 1fr; }
  .studio-grid { grid-template-columns: 1fr; gap: 44px; }
  .nav-links { gap: 18px; }
  .nav-links li:not(:last-child) { display: none; }
  .section { padding: 80px 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html.js .reveal { opacity: 1; transform: none; }
}
