/* littlebitlabs apps — design system matching Minimal (minimal-website-ssh)
   Zinc palette · Inter font · orange accent · violet CTAs */

/* ── Reset ───────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: #09090b;
  color: #f4f4f5;
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3, h4, h5, h6, p, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

/* ── Layout ──────────────────────────────────────────────── */
.wrap {
  max-width: 80rem;
  margin: 0 auto;
  padding: 0 1rem;
}
@media (min-width: 640px) { .wrap { padding: 0 1.5rem; } }

/* ── Typography helpers ──────────────────────────────────── */
.mono-label {
  font-size: 0.75rem;
  font-family: ui-monospace, 'Fira Code', monospace;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #71717a;
}
.orange { color: #E8650A; }
.em-violet { font-style: normal; color: #a78bfa; }
.zinc-400 { color: #a1a1aa; }

/* ── NAV ─────────────────────────────────────────────────── */
.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 40;
  height: 64px;
  transition: background 0.3s, border-color 0.3s;
}
.site-nav.scrolled {
  background: rgba(9,9,11,0.6);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 1px 0 rgba(255,255,255,0.04);
}
.nav-inner {
  max-width: 80rem; margin: 0 auto;
  padding: 0 1rem;
  height: 64px;
  display: flex; align-items: center; justify-content: space-between; gap: 1.5rem;
}
@media (min-width: 640px) { .nav-inner { padding: 0 1.5rem; } }

.nav-logo {
  font-weight: 700; font-size: 1.25rem;
  color: #fafafa; white-space: nowrap; flex-shrink: 0;
  display: flex; align-items: center; gap: 0.5rem;
}
.nav-logo:hover { color: #fff; }
.nav-logo-img { width: 28px; height: 28px; object-fit: contain; }

.nav-links {
  display: none;
  align-items: center; gap: 0;
  flex: 1; justify-content: flex-end;
}
@media (min-width: 1024px) { .nav-links { display: flex; } }

.nav-link {
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem; border-radius: 0.375rem;
  color: #e4e4e7; transition: color 0.15s;
}
.nav-link:hover { color: #fff; }
.nav-link.active {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* Mobile hamburger */
.nav-hamburger {
  display: flex; align-items: center; justify-content: center;
  padding: 0.5rem; min-width: 44px; min-height: 44px;
  color: #a1a1aa;
}
.nav-hamburger:hover { color: #f4f4f5; }
@media (min-width: 1024px) { .nav-hamburger { display: none; } }

/* Mobile full-screen overlay */
.nav-mobile {
  display: none;
  position: fixed; inset: 0; z-index: 50;
  background: #09090b;
  flex-direction: column;
  overflow: hidden;
}
.nav-mobile.open { display: flex; }

.nav-mobile-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 1rem; height: 56px; flex-shrink: 0;
  border-bottom: 1px solid rgba(39,39,42,0.5);
}
.nav-mobile-logo { font-weight: 700; font-size: 1.25rem; color: #fafafa; }
.nav-mobile-close {
  display: flex; align-items: center; justify-content: center;
  padding: 0.5rem; min-width: 44px; min-height: 44px;
  color: #a1a1aa;
}
.nav-mobile-close:hover { color: #f4f4f5; }

.nav-mobile-links { flex: 1; overflow-y: auto; }
.nav-mobile-link {
  display: flex; align-items: center;
  padding: 0 1rem; min-height: 52px;
  font-size: 1rem; font-weight: 500;
  color: #f4f4f5;
  border-bottom: 1px solid rgba(39,39,42,0.5);
  transition: color 0.15s;
}
.nav-mobile-link:hover, .nav-mobile-link.active { color: #fff; }

/* ── HERO ────────────────────────────────────────────────── */
.hero {
  min-height: 100svh;
  background: #09090b;
  display: flex; align-items: center;
  position: relative; overflow: hidden;
}
.hero-inner {
  max-width: 80rem; margin: 0 auto;
  padding: 0 1rem;
  width: 100%;
  padding-top: 112px; padding-bottom: 5rem;
  position: relative; z-index: 10;
}
@media (min-width: 640px) {
  .hero-inner { padding-left: 1.5rem; padding-right: 1.5rem; }
}

.hero-h1 {
  font-size: clamp(2.75rem, 7vw, 4.5rem);
  font-weight: 700; color: #fafafa;
  line-height: 1.05; letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
}
.hero-sub {
  font-size: clamp(1.125rem, 2.5vw, 1.5rem);
  color: #e4e4e7; font-weight: 500;
  line-height: 1.35; margin-bottom: 1.25rem;
}
.hero-body {
  font-size: 1.125rem; color: #a1a1aa;
  line-height: 1.7; margin-bottom: 2.5rem; max-width: 42rem;
}
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 2rem; margin-bottom: 3rem; }

.trust-strip {
  display: flex; flex-wrap: wrap; gap: 0;
  overflow-x: auto; white-space: nowrap;
}
.trust-item {
  font-size: 0.75rem;
  font-family: ui-monospace, monospace;
  text-transform: uppercase; letter-spacing: 0.1em;
  color: #52525b;
}
.trust-dot {
  margin: 0 1.25rem;
  color: #27272a;
}

/* ── SECTIONS ────────────────────────────────────────────── */
.section { padding: 5rem 0; }

.section-label { margin-bottom: 1rem; }
.section-h2 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700; color: #fafafa;
  line-height: 1.15; letter-spacing: -0.01em;
  margin-bottom: 3rem;
}
.section-desc {
  font-size: 1rem; color: #a1a1aa;
  line-height: 1.7; margin-bottom: 3rem; max-width: 42rem;
}

/* ── CARDS ───────────────────────────────────────────────── */
.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}
@media (min-width: 640px) { .card-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .card-grid { grid-template-columns: repeat(3, 1fr); } }

.card {
  border: 1px solid #27272a;
  border-radius: 0.75rem; padding: 1.5rem;
  display: flex; flex-direction: column;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
  color: inherit;
}
.card:hover {
  border-color: #3f3f46;
  background: rgba(39,39,42,0.4);
  box-shadow: 0 10px 15px -3px rgba(0,0,0,0.3);
}
.card-title {
  font-size: 1rem; font-weight: 700; color: #f4f4f5;
  margin-bottom: 0.5rem;
}
.card:hover .card-title { color: #fff; }
.card-tagline {
  font-size: 0.75rem; color: #a78bfa;
  margin-bottom: 0.75rem; line-height: 1.6;
}
.card-desc {
  font-size: 0.75rem; color: #71717a;
  line-height: 1.6; flex: 1;
}
.card-footer {
  margin-top: 1rem; padding-top: 1rem;
  border-top: 1px solid rgba(39,39,42,0.6);
}
.card-stat {
  font-size: 0.75rem;
  font-family: ui-monospace, monospace;
  color: #71717a;
}

/* 4-card grid for app detail pages */
.card-grid-4 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}
@media (min-width: 640px) { .card-grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .card-grid-4 { grid-template-columns: repeat(4, 1fr); } }

/* ── BUTTONS ─────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-weight: 600; border-radius: 0.5rem;
  transition: background 0.15s, color 0.15s;
}
.btn-violet {
  background: #7c3aed; color: #fff;
  font-size: 1rem; padding: 0.875rem 1.5rem;
}
.btn-violet:hover { background: #6d28d9; color: #fff; }
.btn-ghost {
  color: #a1a1aa; font-size: 1rem; padding: 0.875rem 0;
}
.btn-ghost:hover { color: #f4f4f5; }
.btn-sm {
  font-size: 0.875rem; padding: 0.625rem 1.25rem;
}

/* ── SCREENSHOT ──────────────────────────────────────────── */
.screenshot-wrap {
  max-width: 960px; margin: 0 auto;
  border: 1px solid #27272a; border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}

/* ── HIGHLIGHT BOX ───────────────────────────────────────── */
.highlight-box {
  border: 1px solid rgba(91,33,182,0.4);
  background: rgba(46,16,101,0.15);
  border-radius: 0.75rem;
  padding: 1.25rem 1.5rem;
  margin-bottom: 2.5rem;
}
.highlight-box-title {
  font-size: 1rem; font-weight: 600;
  color: #e4e4e7; margin-bottom: 0.5rem;
}
.highlight-box-body {
  font-size: 0.875rem; color: #d4d4d8; line-height: 1.7;
}

/* ── LEGAL PAGES ─────────────────────────────────────────── */
.legal-wrap {
  max-width: 720px; margin: 0 auto;
  padding: 0 1rem;
}
@media (min-width: 640px) { .legal-wrap { padding: 0 1.5rem; } }
.legal-page { background: #09090b; min-height: 100vh; padding-top: 88px; padding-bottom: 8rem; }
@media (min-width: 768px) { .legal-page { padding-top: 112px; } }

.legal-h2 { font-size: 1rem; font-weight: 600; color: #e4e4e7; margin-bottom: 0.75rem; }
.legal-h3 { font-size: 0.875rem; font-weight: 600; color: #a1a1aa; margin-bottom: 0.5rem; margin-top: 1.25rem; }
.legal-p { font-size: 0.875rem; color: #a1a1aa; line-height: 1.75; margin-bottom: 0.875rem; }
.legal-ul {
  font-size: 0.875rem; color: #a1a1aa; line-height: 1.75;
  margin-bottom: 0.875rem; padding-left: 1.25rem; list-style: disc;
}
.legal-ul li { margin-bottom: 0.375rem; }
.legal-a { color: #a78bfa; }
.legal-strong { color: #e4e4e7; }
.space-y-10 > * + * { margin-top: 2.5rem; }

/* ── 404 ─────────────────────────────────────────────────── */
.page-404 {
  min-height: 80vh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center; padding: 5rem 1.5rem;
}
.page-404-code {
  font-size: clamp(5rem, 15vw, 9rem);
  font-weight: 800; line-height: 1;
  color: #7c3aed;
  margin-bottom: 1.5rem;
}

/* ── APP HERO (shorter, page-level) ──────────────────────── */
.app-hero {
  background: #09090b;
  padding-top: 112px; padding-bottom: 5rem;
}
.app-hero-inner {
  max-width: 80rem; margin: 0 auto;
  padding: 0 1rem;
}
@media (min-width: 640px) { .app-hero-inner { padding: 0 1.5rem; } }

/* ── FOOTER ──────────────────────────────────────────────── */
.site-footer {
  background: #050507;
  border-top: 1px solid rgba(39,39,42,0.5);
}
.footer-inner { max-width: 80rem; margin: 0 auto; padding: 0 1rem; }
@media (min-width: 640px) { .footer-inner { padding: 0 1.5rem; } }
.footer-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2.5rem 1.5rem;
  padding: 4rem 0;
}
@media (min-width: 768px) { .footer-grid { grid-template-columns: repeat(3, 1fr); } }
.footer-col-heading {
  font-size: 0.75rem;
  font-family: ui-monospace, monospace;
  text-transform: uppercase; letter-spacing: 0.1em;
  color: #71717a; margin-bottom: 1.25rem;
}
.footer-links { display: flex; flex-direction: column; gap: 0.75rem; }
.footer-link { font-size: 0.875rem; color: #a1a1aa; transition: color 0.15s; }
.footer-link:hover { color: #f4f4f5; }
.footer-bottom {
  padding: 2rem 0;
  border-top: 1px solid rgba(39,39,42,0.5);
  display: flex; flex-wrap: wrap; align-items: center;
  justify-content: space-between; gap: 1rem;
}
.footer-copy { font-size: 0.75rem; color: #52525b; }
.footer-legal { display: flex; gap: 1.25rem; }
.footer-legal-link { font-size: 0.75rem; color: #52525b; transition: color 0.15s; }
.footer-legal-link:hover { color: #a1a1aa; }
