/* firecracker-farm GitHub Pages — dark theme */

/* ── Custom properties ── */
:root {
  --bg: #0d1117;
  --surface: #161b22;
  --surface-raised: #1c2129;
  --border: #30363d;
  --border-accent: #58a6ff;
  --text: #c9d1d9;
  --text-muted: #8b949e;
  --text-bright: #f0f6fc;
  --accent: #58a6ff;
  --accent-glow: rgba(88, 166, 255, 0.15);
  --orange: #d29922;
  --green: #3fb950;
  --red: #f85149;
  --purple: #bc8cff;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  --mono: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
  --max-w: 1140px;
  --radius: 8px;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img, svg { display: block; max-width: 100%; }

/* ── Layout ── */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 1.5rem; }
section { padding: 5rem 0; }
.section-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-bright);
  margin-bottom: 0.5rem;
}
.section-subtitle {
  color: var(--text-muted);
  font-size: 1.125rem;
  margin-bottom: 3rem;
  max-width: 640px;
}

/* ── Hero ── */
.hero {
  text-align: center;
  padding: 7rem 0 5rem;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -40%; left: 50%; transform: translateX(-50%);
  width: 800px; height: 800px;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}
.hero > * { position: relative; z-index: 1; }
.hero-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 2.75rem;
  font-weight: 700;
  color: var(--text-bright);
  margin-bottom: 1rem;
}
.hero-logo svg { flex-shrink: 0; }
.hero-tagline {
  font-size: 1.25rem;
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto 2.5rem;
}
.hero-install {
  display: inline-block;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem 1.5rem;
  font-family: var(--mono);
  font-size: 0.9rem;
  color: var(--green);
  margin-bottom: 2rem;
  user-select: all;
  cursor: text;
}
.hero-install span { color: var(--text-muted); }
.hero-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  transition: opacity 0.15s;
}
.btn:hover { text-decoration: none; opacity: 0.85; }
.btn-primary { background: var(--accent); color: var(--bg); }
.btn-secondary { background: var(--surface); color: var(--text); border: 1px solid var(--border); }

/* ── Hero graphic ── */
.hero-graphic { margin: 3rem auto 0; max-width: 600px; }

/* ── Features ── */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: border-color 0.2s;
}
.feature-card:hover { border-color: var(--accent); }
.feature-icon {
  width: 40px; height: 40px;
  margin-bottom: 1rem;
  color: var(--accent);
}
.feature-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: 0.5rem;
}
.feature-card p { color: var(--text-muted); font-size: 0.95rem; }

/* ── Comparison table ── */
.comparison-intro { color: var(--text-muted); max-width: 700px; margin-bottom: 2rem; font-size: 1.05rem; }
.comparison-table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
.comparison-table th,
.comparison-table td {
  padding: 0.85rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
.comparison-table th {
  font-weight: 600;
  color: var(--text-bright);
  background: var(--surface);
  position: sticky; top: 0;
}
.comparison-table td { color: var(--text); }
.comparison-table .highlight {
  background: var(--accent-glow);
  border-left: 2px solid var(--accent);
  border-right: 2px solid var(--accent);
}
.comparison-table .highlight-top { border-top: 2px solid var(--accent); }
.comparison-table .highlight-bottom { border-bottom: 2px solid var(--accent); }
.comparison-table tr:last-child td { border-bottom: none; }
.callout {
  background: var(--surface);
  border-left: 3px solid var(--orange);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1rem 1.25rem;
  margin-top: 2rem;
  color: var(--text-muted);
  font-size: 0.95rem;
}
.callout strong { color: var(--orange); }

/* ── Architecture ── */
.arch-container {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  overflow-x: auto;
  display: flex;
  justify-content: center;
}
.arch-container svg { max-width: 100%; height: auto; }

/* ── OpenClaw example ── */
.example-intro { color: var(--text-muted); max-width: 700px; margin-bottom: 2rem; font-size: 1.05rem; }
.example-benefits {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 2.5rem;
}
.benefit {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
}
.benefit-icon { color: var(--green); flex-shrink: 0; margin-top: 0.2rem; }
.benefit p { color: var(--text-muted); font-size: 0.95rem; }
.benefit strong { color: var(--text-bright); }

.sandbox-compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-top: 2.5rem;
}
.sandbox-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}
.sandbox-card.preferred { border-color: var(--green); }
.sandbox-card h4 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}
.sandbox-card.preferred h4 { color: var(--green); }
.sandbox-card ul {
  list-style: none;
  padding: 0;
}
.sandbox-card li {
  color: var(--text-muted);
  font-size: 0.9rem;
  padding: 0.25rem 0;
  padding-left: 1.25rem;
  position: relative;
}
.sandbox-card li::before {
  position: absolute;
  left: 0;
}
.sandbox-card.docker li::before { content: '✕'; color: var(--red); }
.sandbox-card.preferred li::before { content: '✓'; color: var(--green); }

/* ── Code blocks ── */
.terminal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  overflow-x: auto;
}
.terminal pre {
  font-family: var(--mono);
  font-size: 0.875rem;
  line-height: 1.7;
  color: var(--text);
  margin: 0;
}
.terminal .comment { color: var(--text-muted); }
.terminal .cmd { color: var(--green); }
.terminal .flag { color: var(--orange); }
.terminal .arg { color: var(--purple); }

/* ── Quick start ── */
.quickstart-steps { display: flex; flex-direction: column; gap: 2rem; }
.quickstart-step { display: flex; gap: 1.25rem; align-items: flex-start; }
.step-number {
  flex-shrink: 0;
  width: 36px; height: 36px;
  background: var(--accent);
  color: var(--bg);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
}
.step-content { flex: 1; min-width: 0; }
.step-content h3 {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: 0.5rem;
}
.step-content .terminal { margin-top: 0.5rem; }

/* ── FAQ ── */
#faq { background: var(--surface); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.faq-item {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  margin-bottom: 1.5rem;
}
.faq-question {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: 1rem;
}
.faq-answer p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 0.75rem;
}
.faq-answer p:last-child { margin-bottom: 0; }
.faq-answer code {
  background: var(--surface-raised);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-family: var(--mono);
  font-size: 0.85rem;
  color: var(--accent);
}

/* ── Footer ── */
.footer {
  border-top: 1px solid var(--border);
  padding: 3rem 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
}
.footer-links {
  display: flex;
  gap: 2rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}
.footer-links a { color: var(--text-muted); }
.footer-links a:hover { color: var(--accent); }
.footer p { margin-top: 0.5rem; }

/* ── Responsive ── */
@media (max-width: 768px) {
  .hero { padding: 4rem 0 3rem; }
  .hero-logo { font-size: 2rem; }
  .features-grid { grid-template-columns: 1fr; }
  .example-benefits { grid-template-columns: 1fr; }
  .sandbox-compare { grid-template-columns: 1fr; }
  .comparison-table { font-size: 0.8rem; }
  .comparison-table th,
  .comparison-table td { padding: 0.6rem 0.5rem; }
  section { padding: 3rem 0; }
  .section-title { font-size: 1.5rem; }
}
@media (min-width: 769px) and (max-width: 1024px) {
  .features-grid { grid-template-columns: repeat(2, 1fr); }
}
