/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --bg: #000000;
  --bg-card: #0a0a0a;
  --bg-elevated: #111111;
  --border: rgba(50, 50, 50, 0.6);
  --border-light: rgba(60, 60, 60, 0.3);
  --text: #ffffff;
  --text-muted: #999999;
  --text-dim: #666666;
  --accent-400: #e53e3e;
  --accent-500: #c6050e;
  --accent-600: #a50410;
  --accent-700: #8b0311;
  --accent-900: #5c020b;
  --red-400: #e53e3e;
  --red-500: #c6050e;
  --orange-400: #e53e3e;
  --yellow-400: #cc9900;
  --green-400: #22c55e;
  --blue-400: #e53e3e;
  --cyan-400: #e53e3e;
  --glow-accent: rgba(198, 5, 14, 0.15);
  --glow-accent-strong: rgba(198, 5, 14, 0.3);
}
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
::selection { background: var(--accent-900); color: white; }
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #222; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent-700); }

/* ===== UTILITIES ===== */
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.mono { font-family: 'JetBrains Mono', monospace; }
.gradient-text {
  background: linear-gradient(135deg, #ff4444, #c6050e);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.section { padding: 100px 0; position: relative; }
.section-title {
  font-size: 2.5rem;
  font-weight: 800;
  text-align: center;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}
.section-subtitle {
  text-align: center;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 60px;
  font-size: 1.05rem;
}

/* ===== NAVBAR ===== */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  border-bottom: 1px solid rgba(198, 5, 14, 0.12);
  background: linear-gradient(135deg, rgba(198, 5, 14, 0.04) 0%, rgba(0, 0, 0, 0.45) 50%, rgba(198, 5, 14, 0.04) 100%);
  backdrop-filter: blur(24px) saturate(1.6);
  -webkit-backdrop-filter: blur(24px) saturate(1.6);
  height: 64px;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.03);
}
.navbar .container {
  display: flex; align-items: center; justify-content: space-between; height: 100%;
}
.navbar-logo {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; color: var(--text);
}
.navbar-logo-icon {
  width: 32px; height: 32px;
  background: var(--bg-elevated);
  border: 1px solid #333;
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 0 15px var(--glow-accent);
  transition: box-shadow 0.3s;
}
.navbar-logo:hover .navbar-logo-icon {
  box-shadow: 0 0 25px var(--glow-accent-strong);
}
.navbar-logo-icon svg { width: 20px; height: 20px; color: var(--accent-500); }
.navbar-logo span { font-weight: 700; font-size: 1.2rem; letter-spacing: -0.02em; }
.navbar-links { display: flex; align-items: center; gap: 8px; }
.navbar-links a {
  color: var(--text-muted); text-decoration: none; font-size: 0.875rem;
  padding: 6px 14px; border-radius: 8px; transition: all 0.2s; font-weight: 500;
}
.navbar-links a:hover { color: var(--text); background: rgba(30, 30, 30, 0.5); }
.navbar-links a.btn-primary { color: #ffffff; }
.navbar-links a.btn-primary:hover { color: #ffffff; background: var(--accent-600); }
.btn-primary {
  background: var(--accent-500); color: #ffffff; padding: 8px 24px;
  border-radius: 10px; font-weight: 700; font-size: 0.875rem;
  text-decoration: none; transition: all 0.2s; border: none; cursor: pointer;
  box-shadow: 0 0 20px rgba(198, 5, 14, 0.3);
  display: inline-flex; align-items: center; gap: 8px;
}
.btn-primary:hover { box-shadow: 0 0 30px rgba(198, 5, 14, 0.5); transform: scale(1.02); }
.btn-outline {
  background: transparent; color: var(--text); padding: 8px 24px;
  border-radius: 10px; font-weight: 600; font-size: 0.875rem;
  text-decoration: none; transition: all 0.2s; border: 1px solid var(--border);
  cursor: pointer; display: inline-flex; align-items: center; gap: 8px;
}
.btn-outline:hover { border-color: var(--accent-500); background: rgba(198, 5, 14, 0.08); }

/* ===== HERO ===== */
.hero {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  text-align: center; position: relative; padding-top: 64px;
  overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse at top, rgba(198, 5, 14, 0.1) 0%, transparent 60%),
    radial-gradient(ellipse at bottom center, rgba(198, 5, 14, 0.05) 0%, transparent 50%);
}
.hero-grid {
  position: absolute; inset: 0; pointer-events: none; opacity: 0.08;
  background-image:
    linear-gradient(rgba(198, 5, 14, 0.3) 1px, transparent 1px),
    linear-gradient(90deg, rgba(198, 5, 14, 0.3) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse at center 30%, black 0%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center 30%, black 0%, transparent 70%);
}
.hero-glow {
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 1000px; height: 400px;
  background: radial-gradient(ellipse, rgba(198, 5, 14, 0.1) 0%, transparent 70%);
  pointer-events: none; filter: blur(60px);
}
.hero-shapes {
  position: absolute; inset: 0; pointer-events: none; overflow: hidden;
}
.hero-shape {
  position: absolute; border: 1px solid rgba(198, 5, 14, 0.1);
  border-radius: 8px; background: rgba(198, 5, 14, 0.015);
}
.hero-shape:nth-child(1) { width: 120px; height: 80px; top: 12%; left: 8%; transform: rotate(-8deg); }
.hero-shape:nth-child(2) { width: 180px; height: 100px; top: 8%; right: 5%; transform: rotate(5deg); border-color: rgba(198, 5, 14, 0.06); }
.hero-shape:nth-child(3) { width: 90px; height: 60px; top: 35%; left: 3%; transform: rotate(12deg); }
.hero-shape:nth-child(4) { width: 140px; height: 90px; bottom: 35%; right: 3%; transform: rotate(-4deg); border-color: rgba(198, 5, 14, 0.08); }
.hero-content { position: relative; z-index: 2; max-width: 800px; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 16px; border-radius: 100px;
  background: rgba(198, 5, 14, 0.1); border: 1px solid rgba(198, 5, 14, 0.25);
  font-size: 0.8rem; color: var(--accent-400); margin-bottom: 24px;
  font-weight: 500;
}
.hero-badge .pulse {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent-500);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.5; transform: scale(0.8); } }
.hero h1 {
  font-size: clamp(2.5rem, 6vw, 4.5rem); font-weight: 900;
  letter-spacing: -0.03em; line-height: 1.1; margin-bottom: 20px;
}
.hero p {
  font-size: 1.15rem; color: var(--text-muted); max-width: 560px; margin: 0 auto 36px;
}
.hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ===== LIVE DEMO SECTION ===== */
.demo-container {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 16px; overflow: hidden;
  box-shadow: 0 0 60px rgba(198, 5, 14, 0.04), 0 20px 60px rgba(0,0,0,0.5);
}
.demo-titlebar {
  display: flex; align-items: center; gap: 8px; padding: 12px 16px;
  border-bottom: 1px solid var(--border); background: rgba(17, 17, 17, 0.5);
}
.demo-dot { width: 12px; height: 12px; border-radius: 50%; }
.demo-dot.red { background: #c6050e; }
.demo-dot.yellow { background: #cc9900; }
.demo-dot.green { background: #22c55e; }
.demo-titlebar-text {
  flex: 1; text-align: center; font-size: 0.75rem; color: var(--text-dim);
  font-weight: 500;
}
.demo-body { display: grid; grid-template-columns: 1fr 1fr; height: 520px; overflow: hidden; }
@media (max-width: 768px) { .demo-body { grid-template-columns: 1fr; } }

/* Log Panel */
.demo-log {
  border-right: 1px solid var(--border); padding: 0;
  display: flex; flex-direction: column; overflow: hidden;
}
@media (max-width: 768px) { .demo-log { border-right: none; border-bottom: 1px solid var(--border); } }
.demo-panel-header {
  display: flex; align-items: center; gap: 8px; padding: 10px 14px;
  border-bottom: 1px solid var(--border); font-size: 0.75rem; font-weight: 600;
  color: var(--text-muted);
}
.demo-panel-header svg { width: 14px; height: 14px; color: var(--accent-500); }
.log-entries {
  flex: 1; overflow: hidden; padding: 8px 0; font-size: 0.72rem; position: relative;
  max-height: calc(520px - 36px);
}
.log-entry {
  display: flex; align-items: center; gap: 8px; padding: 4px 14px;
  opacity: 0; animation: logFadeIn 0.4s forwards;
  white-space: nowrap; overflow: hidden;
}
.log-entry .time { color: var(--text-dim); white-space: nowrap; min-width: 52px; flex-shrink: 0; }
.log-entry .agent {
  padding: 1px 6px; border-radius: 4px; font-weight: 600; font-size: 0.65rem;
  white-space: nowrap; text-transform: uppercase; letter-spacing: 0.04em; flex-shrink: 0;
}
.agent-system { background: rgba(198,5,14,0.15); color: var(--accent-400); }
.agent-recon { background: rgba(198,5,14,0.1); color: #ff6b6b; }
.agent-orch { background: rgba(198,5,14,0.12); color: #ff8585; }
.agent-exec { background: rgba(34,197,94,0.15); color: var(--green-400); }
.agent-hunter { background: rgba(198,5,14,0.18); color: var(--accent-400); }
.log-entry .msg { color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.log-badge {
  display: inline-flex; padding: 1px 5px; border-radius: 3px;
  font-size: 0.6rem; font-weight: 700; letter-spacing: 0.05em;
  margin-right: 4px;
}
.badge-deploy { background: rgba(198,5,14,0.2); color: var(--accent-400); }
.badge-spawn { background: rgba(198,5,14,0.12); color: #ff8585; }
.badge-recon { background: rgba(198,5,14,0.1); color: #ff6b6b; }
.badge-task { background: rgba(198,5,14,0.15); color: var(--accent-400); }
.badge-finding { background: rgba(198,5,14,0.2); color: var(--accent-400); }
.badge-complete { background: rgba(34,197,94,0.15); color: var(--green-400); }
.badge-kg { background: rgba(198,5,14,0.12); color: #ff8585; }
@keyframes logFadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }

/* Right Side: Tasks + Findings */
.demo-right { display: flex; flex-direction: column; overflow: hidden; }
.demo-tasks {
  flex: 1; border-bottom: 1px solid var(--border);
  display: flex; flex-direction: column;
}
.demo-findings { flex: 1; display: flex; flex-direction: column; }
.task-list, .finding-list { flex: 1; overflow: hidden; padding: 6px 10px; }
.task-item {
  display: flex; align-items: center; gap: 8px; padding: 6px 10px;
  border-radius: 6px; margin-bottom: 4px; font-size: 0.72rem;
  background: rgba(17, 17, 17, 0.5); border: 1px solid transparent;
  transition: opacity 0.3s, border-color 0.3s, background 0.3s;
}
.task-item.running {
  border-color: rgba(198, 5, 14, 0.3); background: rgba(198, 5, 14, 0.05);
}
.task-item.completed { opacity: 0.6; }
.task-status {
  width: 18px; height: 18px; border-radius: 50%; display: flex;
  align-items: center; justify-content: center; flex-shrink: 0;
}
.task-status.pending { background: rgba(50,50,50,0.5); }
.task-status.running { background: rgba(198,5,14,0.2); }
.task-status.done { background: rgba(34,197,94,0.15); }
.task-status.failed { background: rgba(198,5,14,0.15); }
.task-info { flex: 1; }
.task-info .task-name { color: var(--text); font-weight: 500; }
.task-info .task-desc { color: var(--text-dim); font-size: 0.65rem; }
.task-badge {
  font-size: 0.6rem; padding: 2px 6px; border-radius: 4px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.04em;
}

.finding-item {
  padding: 8px 10px; border-radius: 6px; margin-bottom: 4px;
  background: rgba(17, 17, 17, 0.5); border-left: 3px solid;
  font-size: 0.72rem;
  opacity: 0; animation: findingSlideIn 0.5s ease-out forwards;
}
@keyframes findingSlideIn {
  from { opacity: 0; transform: translateX(-8px); }
  to { opacity: 1; transform: translateX(0); }
}
.finding-item.critical { border-left-color: var(--accent-500); }
.finding-item.high { border-left-color: #e53e3e; }
.finding-item.medium { border-left-color: var(--yellow-400); }
.finding-item .finding-title { font-weight: 600; color: var(--text); margin-bottom: 2px; }
.finding-item .finding-meta {
  display: flex; align-items: center; gap: 6px; font-size: 0.62rem;
}
.severity-badge {
  padding: 1px 6px; border-radius: 3px; font-weight: 700;
  font-size: 0.6rem; text-transform: uppercase; letter-spacing: 0.05em;
}
.sev-critical { background: rgba(198,5,14,0.15); color: var(--accent-400); border: 1px solid rgba(198,5,14,0.3); }
.sev-high { background: rgba(198,5,14,0.12); color: #ff6b6b; border: 1px solid rgba(198,5,14,0.25); }
.sev-medium { background: rgba(204,153,0,0.15); color: var(--yellow-400); border: 1px solid rgba(204,153,0,0.3); }
.sev-verified { background: rgba(34,197,94,0.1); color: var(--green-400); border: 1px solid rgba(34,197,94,0.3); }

/* ===== PIPELINE / FLOW SECTION ===== */
.pipeline-section { overflow: hidden; }
.pipeline-wrapper { position: relative; padding: 40px 0; }
.pipeline-steps {
  display: flex; align-items: flex-start; justify-content: center; gap: 0;
  position: relative; flex-wrap: nowrap;
}
.pipeline-step {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  position: relative; z-index: 2; flex: 0 0 auto; width: 140px;
}
.pipeline-icon {
  width: 64px; height: 64px; border-radius: 16px;
  background: var(--bg-elevated); border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  position: relative; transition: all 0.3s;
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}
.pipeline-icon svg { width: 28px; height: 28px; }
.pipeline-icon.active {
  border-color: var(--accent-500);
  box-shadow: 0 0 30px var(--glow-accent), 0 4px 20px rgba(0,0,0,0.3);
}
.pipeline-step-label {
  margin-top: 12px; font-size: 0.8rem; font-weight: 700;
  color: var(--text); letter-spacing: -0.01em;
}
.pipeline-step-desc {
  margin-top: 4px; font-size: 0.68rem; color: var(--text-dim);
  max-width: 120px; line-height: 1.4;
}

/* Connector Lines */
.pipeline-connector {
  position: relative; width: 80px; height: 64px; display: flex;
  align-items: center; justify-content: center; z-index: 1;
  flex-shrink: 0;
}
.connector-line {
  width: 100%; height: 2px; position: relative; overflow: visible;
  background: repeating-linear-gradient(
    90deg,
    rgba(198, 5, 14, 0.7) 0px,
    rgba(198, 5, 14, 0.7) 6px,
    transparent 6px,
    transparent 12px
  );
  background-size: 12px 2px;
  animation: marchingAnts 0.6s linear infinite;
}
.connector-dot { display: none; }
@keyframes marchingAnts {
  0% { background-position: 0 0; }
  100% { background-position: 12px 0; }
}

.pipeline-icon.active::before {
  content: ''; position: absolute; inset: -4px; border-radius: 20px;
  border: 2px solid var(--accent-500); opacity: 0;
  animation: ringPulse 2s ease-in-out infinite;
}
@keyframes ringPulse {
  0%, 100% { opacity: 0; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.08); }
}

@media (max-width: 900px) {
  .pipeline-steps { flex-direction: column; align-items: center; gap: 0; }
  .pipeline-connector { width: 64px; height: 40px; transform: rotate(90deg); }
}

/* ===== FEATURES GRID ===== */
.features-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
}
@media (max-width: 900px) { .features-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .features-grid { grid-template-columns: 1fr; } }
.feature-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 14px; padding: 28px; transition: all 0.3s;
  position: relative; overflow: hidden;
}
.feature-card:hover {
  border-color: rgba(198, 5, 14, 0.3);
  box-shadow: 0 0 40px rgba(198, 5, 14, 0.06);
  transform: translateY(-2px);
}
.feature-icon {
  width: 44px; height: 44px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px;
}
.feature-icon svg { width: 22px; height: 22px; }
.feature-card h3 { font-size: 1rem; font-weight: 700; margin-bottom: 8px; }
.feature-card p { font-size: 0.85rem; color: var(--text-muted); line-height: 1.6; }

/* ===== HOW IT WORKS ===== */
.how-steps-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; max-width: 960px; margin: 0 auto;
}
@media (max-width: 700px) { .how-steps-grid { grid-template-columns: 1fr; max-width: 400px; } }

/* ===== CTA ===== */
.cta-section {
  text-align: center; padding: 100px 0 120px;
  position: relative;
}
.cta-section::before {
  content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 800px; height: 400px;
  background: radial-gradient(ellipse, rgba(198, 5, 14, 0.06), transparent 70%);
  pointer-events: none; filter: blur(40px);
}
.cta-section h2 { font-size: 2.5rem; font-weight: 900; margin-bottom: 16px; letter-spacing: -0.03em; }
.cta-section p { color: var(--text-muted); margin-bottom: 32px; font-size: 1.05rem; }

/* ===== FOOTER ===== */
footer {
  border-top: 1px solid var(--border); padding: 40px 0;
  text-align: center; color: var(--text-dim); font-size: 0.82rem;
}
footer a { color: var(--accent-400); text-decoration: none; }
footer a:hover { text-decoration: underline; }

/* ===== REQUEST DEMO MODAL ===== */
.modal-overlay {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(0, 0, 0, 0.7); backdrop-filter: blur(8px);
  display: none; align-items: center; justify-content: center;
  padding: 20px;
}
.modal-overlay.active { display: flex; }
.modal {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 16px; max-width: 520px; width: 100%;
  padding: 36px; position: relative;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5), 0 0 40px rgba(198, 5, 14, 0.08);
  max-height: 90vh; overflow-y: auto;
}
.modal-close {
  position: absolute; top: 16px; right: 16px;
  background: none; border: none; color: var(--text-dim);
  cursor: pointer; padding: 4px; border-radius: 6px;
  transition: all 0.2s;
}
.modal-close:hover { color: var(--text); background: rgba(30, 30, 30, 0.5); }
.modal h2 { font-size: 1.5rem; font-weight: 800; margin-bottom: 8px; }
.modal .modal-desc {
  font-size: 0.85rem; color: var(--text-muted); line-height: 1.6; margin-bottom: 28px;
}
.form-group { margin-bottom: 16px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 500px) { .form-row { grid-template-columns: 1fr; } }
.form-group label {
  display: block; font-size: 0.78rem; font-weight: 600; color: var(--text-muted);
  margin-bottom: 6px;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%; padding: 10px 14px; border-radius: 10px;
  background: var(--bg-elevated); border: 1px solid var(--border);
  color: var(--text); font-size: 0.85rem; font-family: inherit;
  transition: border-color 0.2s; outline: none;
  -webkit-appearance: none;
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: var(--text-dim); }
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus { border-color: var(--accent-500); }
.form-group select {
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23666666' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}
.form-group textarea { resize: vertical; min-height: 80px; }
.form-submit {
  width: 100%; margin-top: 8px;
}

/* ===== SPINNER ===== */
.spinner {
  width: 12px; height: 12px; border: 2px solid transparent;
  border-top-color: var(--accent-500); border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ===== THINKING INDICATOR ===== */
.thinking-dots { display: inline-flex; gap: 3px; }
.thinking-dots span {
  width: 4px; height: 4px; border-radius: 50%;
  background: var(--accent-500); animation: thinkBounce 1.2s ease-in-out infinite;
}
.thinking-dots span:nth-child(2) { animation-delay: 0.15s; }
.thinking-dots span:nth-child(3) { animation-delay: 0.3s; }
@keyframes thinkBounce {
  0%, 80%, 100% { transform: scale(0.6); opacity: 0.4; }
  40% { transform: scale(1); opacity: 1; }
}

/* ===== ANIMATED BOT ===== */
.animated-bot {
  width: 48px; height: 48px; position: relative;
}
.animated-bot .bot-body {
  width: 100%; height: 100%; background: var(--bg-elevated);
  border: 1px solid #333; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 0 20px var(--glow-accent);
}
.animated-bot svg { width: 28px; height: 28px; color: var(--accent-500); }

/* ===== SEPARATOR ===== */
.section-sep {
  height: 1px; background: linear-gradient(90deg, transparent, var(--border), transparent);
  max-width: 600px; margin: 0 auto;
}
