/* OpenGraphMemory - Knowledge Graph Theme */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

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

:root {
  --bg: #04060b;
  --bg-card: #080c14;
  --bg-card-hover: #0c1220;
  --bg-surface: #0a0f1a;
  --text: #c8d6e5;
  --text-dim: #5a6d82;
  --text-bright: #e8f0f8;
  --border: #141c2b;
  --border-hover: #1e2a3d;
  --accent: #4e8eff;
  --accent-dim: rgba(78, 142, 255, 0.08);
  --accent-glow: rgba(78, 142, 255, 0.15);
  --node-1: #4e8eff;
  --node-2: #22d3a7;
  --node-3: #a78bfa;
  --node-4: #f59e0b;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: 'JetBrains Mono', 'Fira Code', monospace;
}

html { font-size: 16px; -webkit-font-smoothing: antialiased; }
body { font-family: var(--font); background: var(--bg); color: var(--text); line-height: 1.6; min-height: 100vh; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* Nav */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 100; background: rgba(4, 6, 11, 0.9); backdrop-filter: blur(24px); border-bottom: 1px solid var(--border); }
.nav-inner { max-width: 1120px; margin: 0 auto; padding: 0 2rem; height: 56px; display: flex; align-items: center; justify-content: space-between; }
.nav-brand { display: flex; align-items: center; gap: 10px; }
.nav-logo { width: 26px; height: 26px; background: var(--accent); border-radius: 5px; display: flex; align-items: center; justify-content: center; }
.nav-logo svg { width: 14px; height: 14px; color: #fff; }
.nav-title { font-size: 0.82rem; font-weight: 600; color: var(--text-bright); letter-spacing: -0.01em; }
.nav-sep { color: var(--text-dim); font-size: 0.7rem; margin: 0 4px; }
.nav-project { font-size: 0.82rem; font-weight: 500; color: var(--text-dim); }
.nav-links { display: flex; align-items: center; gap: 1.5rem; }
.nav-link { font-size: 0.8rem; color: var(--text-dim); transition: color 200ms; font-weight: 450; }
.nav-link:hover { color: var(--text); }

/* Hero */
.hero { padding: 120px 2rem 0; max-width: 1120px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; min-height: 85vh; }
.hero-content { }
.hero-visual { position: relative; }
.hero-badge { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border: 1px solid var(--border); border-radius: 100px; font-size: 0.72rem; color: var(--text-dim); margin-bottom: 1.5rem; font-weight: 450; }
.hero-badge-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--node-2); animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.3; } }
.hero h1 { font-size: clamp(2.2rem, 4vw, 3rem); font-weight: 650; letter-spacing: -0.04em; line-height: 1.08; margin-bottom: 1.25rem; color: var(--text-bright); }
.hero h1 span { color: var(--accent); }
.hero .lead { font-size: 1rem; color: var(--text-dim); line-height: 1.7; margin-bottom: 2rem; max-width: 480px; }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.btn { display: inline-flex; align-items: center; gap: 7px; padding: 9px 18px; border-radius: 6px; font-size: 0.82rem; font-weight: 500; font-family: var(--font); transition: all 200ms; cursor: pointer; border: none; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: #3d7be6; }
.btn-ghost { background: transparent; color: var(--text-dim); border: 1px solid var(--border); }
.btn-ghost:hover { color: var(--text); border-color: var(--border-hover); }
.btn svg { width: 14px; height: 14px; }

/* Knowledge Graph SVG */
.graph-visual { width: 100%; max-width: 500px; aspect-ratio: 1; position: relative; margin: 0 auto; }
.graph-visual svg { width: 100%; height: 100%; display: block; }
.graph-node { transition: all 300ms; }
.graph-node:hover { filter: brightness(1.3); }
.graph-edge { stroke-dasharray: 4 4; animation: dash 20s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -200; } }
.graph-pulse { animation: graph-pulse 3s ease-in-out infinite; }
@keyframes graph-pulse { 0%,100% { r: 4; opacity: 0.8; } 50% { r: 6; opacity: 0.4; } }

/* Section */
.section { padding: 80px 2rem; max-width: 1120px; margin: 0 auto; }
.section-label { font-size: 0.7rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.1em; color: var(--accent); margin-bottom: 0.75rem; font-family: var(--mono); }
.section-title { font-size: clamp(1.6rem, 3vw, 2rem); font-weight: 620; letter-spacing: -0.03em; line-height: 1.15; margin-bottom: 0.75rem; color: var(--text-bright); }
.section-desc { font-size: 0.92rem; color: var(--text-dim); max-width: 480px; line-height: 1.7; margin-bottom: 3rem; }

/* Ecosystem Cards */
.eco-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.eco-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 1.5rem; position: relative; overflow: hidden; transition: border-color 200ms; }
.eco-card:hover { border-color: var(--border-hover); }
.eco-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px; }
.eco-card:nth-child(1)::before { background: var(--node-1); }
.eco-card:nth-child(2)::before { background: var(--node-2); }
.eco-card:nth-child(3)::before { background: var(--node-3); }
.eco-card .tag { font-size: 0.65rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-dim); margin-bottom: 0.75rem; font-family: var(--mono); }
.eco-card h3 { font-size: 1rem; font-weight: 620; color: var(--text-bright); margin-bottom: 0.5rem; letter-spacing: -0.01em; }
.eco-card p { font-size: 0.8rem; color: var(--text-dim); line-height: 1.6; }
.eco-card .link { display: inline-flex; align-items: center; gap: 4px; font-size: 0.78rem; color: var(--accent); margin-top: 1rem; font-weight: 500; }
.eco-card .link svg { width: 12px; height: 12px; }

/* Pipeline */
.pipeline { display: flex; align-items: stretch; gap: 0; margin: 2rem 0; }
.pipeline-step { flex: 1; background: var(--bg-card); border: 1px solid var(--border); padding: 1.5rem; position: relative; }
.pipeline-step:first-child { border-radius: 10px 0 0 10px; }
.pipeline-step:last-child { border-radius: 0 10px 10px 0; }
.pipeline-step + .pipeline-step { border-left: none; }
.pipeline-step .num { font-size: 0.65rem; font-weight: 600; color: var(--accent); font-family: var(--mono); margin-bottom: 0.5rem; }
.pipeline-step h4 { font-size: 0.88rem; font-weight: 600; color: var(--text-bright); margin-bottom: 0.3rem; }
.pipeline-step p { font-size: 0.75rem; color: var(--text-dim); line-height: 1.5; }
.pipeline-arrow { display: flex; align-items: center; color: var(--text-dim); font-size: 0.9rem; padding: 0 0.25rem; }

/* Features */
.features-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.feature-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 1.5rem; transition: border-color 200ms; }
.feature-card:hover { border-color: var(--border-hover); }
.feature-card .icon { width: 32px; height: 32px; border-radius: 6px; display: flex; align-items: center; justify-content: center; margin-bottom: 0.9rem; background: var(--accent-dim); color: var(--accent); }
.feature-card .icon svg { width: 16px; height: 16px; }
.feature-card h4 { font-size: 0.88rem; font-weight: 620; margin-bottom: 0.4rem; color: var(--text-bright); }
.feature-card p { font-size: 0.78rem; color: var(--text-dim); line-height: 1.6; }

/* Code Block */
.code-block { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.code-header { display: flex; align-items: center; justify-content: space-between; padding: 8px 14px; border-bottom: 1px solid var(--border); background: var(--bg-surface); }
.code-header span { font-size: 0.7rem; color: var(--text-dim); font-family: var(--mono); }
.code-dots { display: flex; gap: 5px; }
.code-dots span { width: 9px; height: 9px; border-radius: 50%; background: var(--border); }
.code-body { padding: 1.25rem; font-family: var(--mono); font-size: 0.78rem; line-height: 1.9; color: var(--text-dim); overflow-x: auto; }
.code-body .c { color: #3a4a5c; }
.code-body .k { color: var(--node-3); }
.code-body .s { color: var(--node-2); }

/* Tech */
.tech-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.tech-chip { display: inline-flex; align-items: center; gap: 5px; padding: 5px 12px; background: var(--bg-card); border: 1px solid var(--border); border-radius: 100px; font-size: 0.72rem; font-weight: 450; color: var(--text-dim); }
.tech-chip .dot { width: 5px; height: 5px; border-radius: 50%; }

/* Harness Integration */
.harness-visual { margin-bottom: 2.5rem; background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 2rem; overflow-x: auto; }
.harness-visual svg { width: 100%; max-width: 900px; height: auto; display: block; margin: 0 auto; min-width: 600px; }
.harness-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.harness-item { display: flex; align-items: flex-start; gap: 12px; padding: 1.25rem; background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; transition: border-color 200ms; }
.harness-item:hover { border-color: var(--border-hover); }
.harness-icon { width: 36px; height: 36px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 0.72rem; font-weight: 700; flex-shrink: 0; font-family: var(--mono); }
.harness-item h4 { font-size: 0.88rem; font-weight: 620; color: var(--text-bright); margin-bottom: 0.25rem; }
.harness-item p { font-size: 0.78rem; color: var(--text-dim); line-height: 1.5; }
.harness-item code { background: var(--accent-dim); padding: 1px 5px; border-radius: 3px; font-family: var(--mono); font-size: 0.72rem; color: var(--accent); }

/* Footer */
.footer { border-top: 1px solid var(--border); padding: 2.5rem 2rem; margin-top: 3rem; }
.footer-inner { max-width: 1120px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; }
.footer-left { font-size: 0.78rem; color: var(--text-dim); }
.footer-links { display: flex; gap: 1.25rem; }
.footer-link { font-size: 0.78rem; color: var(--text-dim); transition: color 200ms; }
.footer-link:hover { color: var(--text); }

/* Responsive */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: auto; padding-top: 100px; }
  .hero-visual { display: block; max-width: 400px; margin: 0 auto; }
  .eco-grid, .features-grid, .harness-list { grid-template-columns: 1fr; }
  .pipeline { flex-direction: column; }
  .pipeline-step + .pipeline-step { border-left: 1px solid var(--border); border-top: none; }
  .pipeline-step:first-child { border-radius: 10px 10px 0 0; }
  .pipeline-step:last-child { border-radius: 0 0 10px 10px; }
  .nav-links { display: none; }
}
