/* AI Manager — dark glassmorphism */
:root {
  --bg: #0a0a0f;
  --bg2: #0f172a;
  --text: #e2e8f0;
  --muted: #94a3b8;
  --accent: #00ffaa;
  --accent2: #8b5cf6;
  --glass: rgba(15, 23, 42, 0.65);
  --border: rgba(0, 255, 170, 0.2);
  --radius: 16px;
  --font: "Inter", system-ui, sans-serif;
  --font-display: "Space Grotesk", var(--font);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

.bg-glow {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse 80% 50% at 20% 10%, rgba(139, 92, 246, 0.15), transparent),
    radial-gradient(ellipse 60% 40% at 80% 60%, rgba(0, 255, 170, 0.08), transparent),
    var(--bg);
}

.container { width: min(1140px, 92vw); margin: 0 auto; }

header.site-header {
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(12px);
  background: rgba(10, 10, 15, 0.85);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 0;
}
.logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  -webkit-background-clip: text;
  color: transparent;
}
nav a {
  color: var(--muted);
  text-decoration: none;
  margin-left: 1.5rem;
  font-size: 0.9rem;
  transition: color 0.2s;
}
nav a:hover { color: var(--accent); }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0.85rem 1.5rem;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  font-size: 0.95rem;
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary {
  background: linear-gradient(135deg, var(--accent), #00c896);
  color: #0a0a0f;
  box-shadow: 0 0 24px rgba(0, 255, 170, 0.35);
}
.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

section { padding: 5rem 0; }
section.reveal { opacity: 0; transform: translateY(24px); transition: 0.7s ease; }
section.reveal.visible { opacity: 1; transform: none; }

h1, h2, h3 { font-family: var(--font-display); line-height: 1.15; }
h1 { font-size: clamp(2rem, 5vw, 3.25rem); margin: 0 0 1rem; }
h2 { font-size: clamp(1.75rem, 3vw, 2.5rem); margin: 0 0 1rem; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 640px; }

.tags { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1.5rem 0; }
.tag {
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  font-size: 0.8rem;
  background: var(--glass);
  border: 1px solid var(--border);
  backdrop-filter: blur(8px);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  padding: 4rem 0 6rem;
}
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } }

.chat-demo {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(16px);
  overflow: hidden;
  box-shadow: 0 24px 48px rgba(0,0,0,0.4);
}
.chat-header {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; gap: 0.5rem;
  font-size: 0.85rem;
}
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); animation: pulse 1.5s infinite; }
@keyframes pulse { 50% { opacity: 0.4; } }
.chat-body { padding: 1rem; min-height: 220px; max-height: 320px; overflow-y: auto; }
.msg { margin-bottom: 0.75rem; padding: 0.65rem 0.9rem; border-radius: 12px; font-size: 0.9rem; max-width: 90%; }
.msg.user { background: rgba(139, 92, 246, 0.25); margin-left: auto; }
.msg.bot { background: rgba(0, 255, 170, 0.1); border: 1px solid var(--border); }
.chat-toast {
  margin: 0.5rem 1rem 1rem;
  padding: 0.5rem 0.75rem;
  background: rgba(0, 255, 170, 0.15);
  border-radius: 8px;
  font-size: 0.8rem;
  color: var(--accent);
  display: none;
}
.chat-toast.show { display: block; animation: fadeIn 0.4s; }
@keyframes fadeIn { from { opacity: 0; } }

.grid-4 { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.25rem; }
.grid-8 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1rem; }

.card {
  background: var(--glass);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--radius);
  padding: 1.5rem;
  backdrop-filter: blur(12px);
  transition: border-color 0.25s, transform 0.25s;
}
.card:hover {
  border-color: var(--border);
  transform: translateY(-4px);
}
.card h3 { margin: 0 0 0.5rem; font-size: 1.1rem; }
.card p { margin: 0; color: var(--muted); font-size: 0.9rem; }

.steps { counter-reset: step; }
.step {
  display: flex; gap: 1.25rem; margin-bottom: 1.5rem;
  padding: 1.25rem;
  background: var(--glass);
  border-radius: var(--radius);
  border: 1px solid rgba(255,255,255,0.05);
}
.step-num {
  flex-shrink: 0;
  width: 40px; height: 40px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--accent2), var(--accent));
  color: #0a0a0f;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}

.niche-panel { display: grid; grid-template-columns: 280px 1fr; gap: 1.5rem; }
@media (max-width: 768px) { .niche-panel { grid-template-columns: 1fr; } }
select, input, textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(0,0,0,0.3);
  color: var(--text);
  font: inherit;
}

.integrations {
  display: flex; flex-wrap: wrap; gap: 0.75rem; justify-content: center;
}
.int-badge {
  padding: 0.5rem 1rem;
  border-radius: 10px;
  background: var(--glass);
  border: 1px solid var(--border);
  font-size: 0.85rem;
}

.compare-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 1rem;
  align-items: start;
}
@media (max-width: 768px) { .compare-grid { grid-template-columns: 1fr; } }
.compare-vs {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--accent2);
  align-self: center;
  text-align: center;
}
.compare-list { list-style: none; padding: 0; margin: 0; }
.compare-list li {
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  font-size: 0.9rem;
  color: var(--muted);
}
.compare-list li::before { content: "• "; color: var(--accent); }

.metrics-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  text-align: center;
}
.metric-big {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  -webkit-background-clip: text;
  color: transparent;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.25rem;
}
.price-card { position: relative; }
.price-card.featured {
  border-color: var(--accent);
  box-shadow: 0 0 32px rgba(0, 255, 170, 0.15);
}
.price-card .badge {
  position: absolute; top: -10px; right: 1rem;
  background: var(--accent); color: #0a0a0f;
  font-size: 0.7rem; font-weight: 700;
  padding: 0.25rem 0.6rem; border-radius: 6px;
}
.price { font-size: 1.75rem; font-weight: 700; margin: 0.5rem 0; }
.price ul { list-style: none; padding: 0; margin: 1rem 0; font-size: 0.85rem; color: var(--muted); }
.price ul li { padding: 0.35rem 0; }

.faq-item { border-bottom: 1px solid rgba(255,255,255,0.08); }
.faq-q {
  width: 100%; text-align: left;
  background: none; border: none; color: var(--text);
  padding: 1.25rem 0; font-size: 1rem; font-weight: 600;
  cursor: pointer; display: flex; justify-content: space-between;
}
.faq-a {
  max-height: 0; overflow: hidden;
  transition: max-height 0.35s ease;
  color: var(--muted); font-size: 0.95rem;
}
.faq-item.open .faq-a { max-height: 400px; padding-bottom: 1rem; }

.cta-form {
  max-width: 480px;
  margin: 2rem auto 0;
  display: flex; flex-direction: column; gap: 1rem;
}
.form-msg { text-align: center; font-size: 0.9rem; min-height: 1.5rem; }
.form-msg.ok { color: var(--accent); }

footer {
  padding: 2rem 0;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
}

.dashboard-page .dash-wrap { max-width: 720px; margin: 4rem auto; padding: 2rem; }
.dashboard-page .metrics { display: flex; gap: 1rem; margin: 2rem 0; }
.dashboard-page .metric-card {
  flex: 1; text-align: center; padding: 1.5rem;
  background: var(--glass); border-radius: var(--radius);
}
.dashboard-page .metric-card span { display: block; font-size: 2rem; font-weight: 700; color: var(--accent); }
.dashboard-page .muted { color: var(--muted); }
.dashboard-page .accent { color: var(--accent); }

#aim-widget-btn {
  position: fixed; bottom: 24px; right: 24px; z-index: 9999;
  width: 56px; height: 56px; border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  border: none; cursor: pointer;
  box-shadow: 0 8px 24px rgba(0,255,170,0.4);
  font-size: 1.5rem;
}
#aim-widget-panel {
  position: fixed; bottom: 90px; right: 24px; z-index: 9998;
  width: 340px; max-height: 420px;
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: var(--radius); display: none; flex-direction: column;
  box-shadow: 0 16px 48px rgba(0,0,0,0.5);
}
#aim-widget-panel.open { display: flex; }
