/* ===========================
   CLAWTALK — Theme CSS
   =========================== */

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #0A0A0F;
  --bg-secondary: #0F0F1A;
  --bg-card: #111118;
  --fg: #EAEAF0;
  --fg-muted: #8B8B9E;
  --accent: #C8FF00;
  --accent-dim: rgba(200, 255, 0, 0.12);
  --accent-border: rgba(200, 255, 0, 0.25);
  --border: rgba(234, 234, 240, 0.08);
  --border-strong: rgba(234, 234, 240, 0.15);
}

html { font-size: 16px; }

body {
  background: var(--bg);
  color: var(--fg);
  font-family: 'DM Sans', system-ui, sans-serif;
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: 'Space Mono', monospace;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.section-label {
  font-family: 'Space Mono', monospace;
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
}

/* --- Layout --- */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* --- Header --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border);
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--fg);
  font-family: 'Space Mono', monospace;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.02em;
}

.logo svg { flex-shrink: 0; }

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  color: var(--fg-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 0.15s;
}

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

/* --- Hero --- */
.hero {
  padding: 6rem 0 5rem;
  border-bottom: 1px solid var(--border);
}

.hero-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--accent-dim);
  border: 1px solid var(--accent-border);
  border-radius: 100px;
  padding: 0.375rem 0.875rem;
  font-size: 0.75rem;
  font-family: 'Space Mono', monospace;
  color: var(--accent);
  margin-bottom: 1.75rem;
  width: fit-content;
}

.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.hero h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 1.25rem;
  color: var(--fg);
}

.hero-lede {
  font-size: 1.0625rem;
  color: var(--fg-muted);
  line-height: 1.7;
  max-width: 480px;
  margin-bottom: 2.5rem;
}

.hero-stats {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.stat { display: flex; flex-direction: column; gap: 0.2rem; }

.stat-value {
  font-family: 'Space Mono', monospace;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent);
}

.stat-label {
  font-size: 0.7rem;
  color: var(--fg-muted);
  max-width: 90px;
  line-height: 1.3;
}

.stat-divider {
  width: 1px;
  height: 32px;
  background: var(--border-strong);
  flex-shrink: 0;
}

/* --- Hero Visual: Connection Diagram --- */
.hero-visual {
  display: flex;
  align-items: center;
  justify-content: center;
}

.connection-diagram {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.node {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.node-inner {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 2px solid var(--border-strong);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.3s;
}

.node-inner.has-agent {
  border-color: var(--accent);
  background: var(--accent-dim);
}

.node span {
  font-family: 'Space Mono', monospace;
  font-size: 0.65rem;
  color: var(--fg-muted);
  text-align: center;
}

.node-lines {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.line {
  width: 48px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent-border), var(--accent));
  border-radius: 1px;
}

.nodes-right {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

/* --- How It Works --- */
.how-it-works {
  padding: 5rem 0;
  border-bottom: 1px solid var(--border);
}

.how-it-works h2 {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  margin-bottom: 3.5rem;
  max-width: 500px;
}

.steps {
  display: flex;
  align-items: center;
  gap: 0;
}

.step {
  flex: 1;
  padding: 2rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.step-number {
  font-family: 'Space Mono', monospace;
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 1rem;
  opacity: 0.6;
}

.step-content h3 {
  font-size: 1rem;
  margin-bottom: 0.75rem;
  color: var(--fg);
}

.step-content p {
  font-size: 0.875rem;
  color: var(--fg-muted);
  line-height: 1.6;
}

.step-connector {
  width: 40px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.step-connector::after {
  content: '';
  display: block;
  width: 100%;
  height: 2px;
  background: var(--border-strong);
}

/* --- Features --- */
.features {
  padding: 5rem 0;
  border-bottom: 1px solid var(--border);
  background: var(--bg-secondary);
}

.features h2 {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  margin-bottom: 3rem;
  max-width: 480px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.feature-card {
  padding: 1.75rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  transition: border-color 0.2s, transform 0.2s;
}

.feature-card:hover {
  border-color: var(--accent-border);
  transform: translateY(-2px);
}

.feature-icon {
  width: 44px;
  height: 44px;
  background: var(--accent-dim);
  border: 1px solid var(--accent-border);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

.feature-card h3 {
  font-size: 0.9375rem;
  margin-bottom: 0.625rem;
  color: var(--fg);
  font-family: 'Space Mono', monospace;
  letter-spacing: -0.01em;
}

.feature-card p {
  font-size: 0.875rem;
  color: var(--fg-muted);
  line-height: 1.6;
}

/* --- Stack --- */
.stack {
  padding: 5rem 0;
  border-bottom: 1px solid var(--border);
}

.stack h2 {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  margin-bottom: 3rem;
  max-width: 520px;
}

.stack-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.stack-card {
  padding: 2rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  transition: border-color 0.2s;
}

.stack-card:hover { border-color: var(--accent-border); }

.stack-logo {
  margin-bottom: 1.5rem;
}

.stack-card h3 {
  font-size: 1rem;
  margin-bottom: 0.75rem;
  color: var(--fg);
  font-family: 'Space Mono', monospace;
}

.stack-card p {
  font-size: 0.875rem;
  color: var(--fg-muted);
  line-height: 1.6;
  margin-bottom: 1.25rem;
}

.stack-tag {
  display: inline-block;
  font-family: 'Space Mono', monospace;
  font-size: 0.7rem;
  color: var(--accent);
  background: var(--accent-dim);
  border: 1px solid var(--accent-border);
  border-radius: 100px;
  padding: 0.25rem 0.75rem;
}

/* --- Closing --- */
.closing {
  padding: 7rem 0;
  background: var(--bg-secondary);
}

.closing-inner {
  max-width: 700px;
}

.closing-label {
  font-family: 'Space Mono', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.5rem;
}

.closing h2 {
  font-size: clamp(1.75rem, 3.5vw, 2.75rem);
  margin-bottom: 1.5rem;
  line-height: 1.15;
}

.closing p {
  font-size: 1rem;
  color: var(--fg-muted);
  line-height: 1.75;
  margin-bottom: 1rem;
}

.closing-tagline {
  font-size: 1.0625rem !important;
  color: var(--fg) !important;
  font-weight: 500;
  margin-top: 1.5rem !important;
}

/* --- Footer --- */
footer {
  border-top: 1px solid var(--border);
  padding: 3rem 0 2rem;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 3rem;
  margin-bottom: 2.5rem;
}

.footer-brand p {
  font-size: 0.875rem;
  color: var(--fg-muted);
  margin-top: 0.75rem;
  max-width: 260px;
}

.footer-links {
  display: flex;
  gap: 3rem;
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-col-label {
  font-family: 'Space Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin-bottom: 0.25rem;
}

.footer-col a, .footer-col span {
  font-size: 0.875rem;
  color: var(--fg-muted);
  text-decoration: none;
  transition: color 0.15s;
}

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

.footer-bottom {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--border);
  padding-top: 1.5rem;
  font-size: 0.75rem;
  color: var(--fg-muted);
  font-family: 'Space Mono', monospace;
}

/* --- Responsive --- */
@media (max-width: 900px) {
  .hero-container { grid-template-columns: 1fr; gap: 3rem; }
  .hero-visual { display: none; }
  .steps { flex-direction: column; }
  .step-connector { width: auto; height: 24px; }
  .step-connector::after { width: 2px; height: 100%; }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .stack-grid { grid-template-columns: 1fr; }
  .nav-links { display: none; }
}

@media (max-width: 600px) {
  .container { padding: 0 1.25rem; }
  .features-grid { grid-template-columns: 1fr; }
  .hero-stats { flex-wrap: wrap; gap: 1rem; }
  .footer-inner { flex-direction: column; gap: 2rem; }
  .footer-links { flex-direction: column; gap: 1.5rem; }
  .footer-bottom { flex-direction: column; gap: 0.5rem; }
}