/* ===== PERSONA MANAGER — STYLES ===== */

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

:root {
  --bg: #0F172A;
  --bg-alt: #0B1120;
  --surface: #1E293B;
  --surface-light: #334155;
  --surface-lighter: #475569;
  --primary: #6366F1;
  --primary-hover: #818CF8;
  --primary-dim: rgba(99, 102, 241, 0.15);
  --secondary: #10B981;
  --secondary-hover: #34D399;
  --accent: #F59E0B;
  --alert: #EF4444;
  --text: #F8FAFC;
  --text-secondary: #94A3B8;
  --text-muted: #64748B;
  --border: #334155;
  --border-light: #1E293B;
  --white: #FFFFFF;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.3), 0 1px 2px rgba(0,0,0,0.2);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.4), 0 2px 4px rgba(0,0,0,0.2);
  --shadow-lg: 0 10px 40px rgba(0,0,0,0.5), 0 4px 8px rgba(0,0,0,0.3);
  --shadow-glow: 0 0 40px rgba(99, 102, 241, 0.15);
  --radius: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', 'SF Mono', monospace;
  --max-w: 1200px;
  --max-w-text: 720px;
  --transition: 150ms ease;
  --transition-slow: 300ms ease;
}

html { scroll-behavior: smooth; font-size: 16px; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ===== LAYOUT ===== */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }
.container-text { max-width: var(--max-w-text); margin: 0 auto; padding: 0 24px; }

.section { padding: 80px 0; }
.section-alt { background: var(--surface); }
.section-header { text-align: center; max-width: 680px; margin: 0 auto 48px; }
.section-header h2 { font-size: 32px; font-weight: 700; margin-bottom: 12px; }
.section-header p { font-size: 16px; color: var(--text-secondary); }

/* ===== NAVBAR ===== */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-light);
  transition: box-shadow var(--transition);
}
.navbar.scrolled { box-shadow: var(--shadow-md); }
.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.navbar-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--text);
  font-weight: 600;
  font-size: 18px;
}
.logo-accent { color: var(--primary); }
.navbar-links {
  display: flex;
  list-style: none;
  gap: 32px;
}
.navbar-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color var(--transition);
}
.navbar-links a:hover { color: var(--text); }
.navbar-actions { display: flex; align-items: center; gap: 12px; }
.github-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: all var(--transition);
}
.github-btn:hover { background: var(--surface-light); color: var(--text); }
.mobile-menu-btn { display: none; background: none; border: none; color: var(--text); cursor: pointer; padding: 8px; }

.mobile-nav {
  display: none;
  flex-direction: column;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 16px;
  gap: 8px;
}
.mobile-nav.open { display: flex; }
.mobile-nav-link {
  padding: 12px 16px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 15px;
  border-radius: var(--radius);
  transition: background var(--transition);
}
.mobile-nav-link:hover { background: var(--surface-light); color: var(--text); }
.mobile-nav-link.cta { background: var(--primary); color: white; text-align: center; }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: all var(--transition);
  font-family: inherit;
}
.btn-sm { padding: 8px 16px; font-size: 13px; }
.btn-lg { padding: 14px 28px; font-size: 15px; }
.btn-full { width: 100%; }
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-hover); box-shadow: 0 4px 16px rgba(99, 102, 241, 0.3); }
.btn-outline { background: transparent; color: var(--text); border: 1px solid var(--border); }
.btn-outline:hover { background: var(--surface); border-color: var(--text-muted); }
.btn-outline-white { background: transparent; color: white; border: 1px solid rgba(255,255,255,0.3); }
.btn-outline-white:hover { background: rgba(255,255,255,0.1); }

/* ===== HERO ===== */
.hero {
  position: relative;
  overflow: hidden;
  padding: 100px 0 80px;
  min-height: 80vh;
  display: flex;
  align-items: center;
}
.hero-bg-gradient {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 50% at 50% -20%, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
              radial-gradient(ellipse 60% 40% at 80% 60%, rgba(16, 185, 129, 0.1) 0%, transparent 50%);
  pointer-events: none;
}
.hero-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
  position: relative;
  z-index: 1;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--primary-dim);
  color: var(--primary-hover);
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 20px;
}
.hero h1 {
  font-size: 52px;
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 20px;
  background: linear-gradient(135deg, var(--text) 0%, var(--text-secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-sub {
  font-size: 18px;
  color: var(--text-secondary);
  margin-bottom: 32px;
  max-width: 520px;
}
.hero-actions { display: flex; gap: 12px; margin-bottom: 32px; flex-wrap: wrap; }
.hero-trust { display: flex; gap: 20px; flex-wrap: wrap; }
.trust-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-muted);
}
.trust-item i { color: var(--secondary); }

/* Hero Visual */
.hero-visual {
  position: relative;
}
.persona-cards {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.persona-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  transition: all var(--transition-slow);
}
.persona-card:hover { transform: translateX(4px); border-color: var(--primary); }
.persona-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.env-badge {
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.env-badge.dev { background: rgba(99, 102, 241, 0.2); color: var(--primary-hover); }
.env-badge.staging { background: rgba(245, 158, 11, 0.2); color: var(--accent); }
.env-badge.prod { background: rgba(16, 185, 129, 0.2); color: var(--secondary); }
.status { display: flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 50%; }
.status.synced { background: rgba(16, 185, 129, 0.2); color: var(--secondary); }
.status.drift { background: rgba(245, 158, 11, 0.2); color: var(--accent); animation: pulse 2s infinite; }
.persona-card-title { font-weight: 600; font-size: 15px; margin-bottom: 4px; }
.persona-card-meta { font-size: 12px; color: var(--text-muted); margin-bottom: 12px; display: flex; gap: 12px; }
.persona-vars { display: flex; flex-direction: column; gap: 6px; }
.var-item {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 12px;
  padding: 6px 10px;
  background: var(--bg);
  border-radius: 4px;
}
.var-item.changed { background: rgba(245, 158, 11, 0.1); border: 1px solid rgba(245, 158, 11, 0.3); }
.var-key { color: var(--text-muted); }
.var-val { color: var(--text-secondary); }
.drift-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
  padding: 10px 16px;
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: var(--radius);
  color: var(--accent);
  font-size: 13px;
  font-weight: 500;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* ===== STATS ===== */
.stats-section { padding: 60px 0; background: var(--bg-alt); }
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.stat-card {
  text-align: center;
  padding: 32px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: all var(--transition);
}
.stat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-glow); }
.stat-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  background: var(--primary-dim);
  color: var(--primary);
  border-radius: 50%;
  margin-bottom: 16px;
}
.stat-num { font-size: 40px; font-weight: 700; color: var(--primary); margin-bottom: 8px; }
.stat-label { font-size: 14px; color: var(--text-secondary); }

/* ===== HOW IT WORKS ===== */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.step-card {
  position: relative;
  padding: 32px 24px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  text-align: center;
  transition: all var(--transition);
}
.step-card:hover { border-color: var(--primary); transform: translateY(-4px); }
.step-num {
  position: absolute;
  top: -12px;
  left: 24px;
  font-size: 12px;
  font-weight: 700;
  color: var(--primary);
  background: var(--bg);
  padding: 2px 8px;
  border-radius: 4px;
}
.step-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  background: var(--primary-dim);
  color: var(--primary);
  border-radius: var(--radius-lg);
  margin-bottom: 20px;
}
.step-card h3 { font-size: 18px; font-weight: 600; margin-bottom: 8px; }
.step-card p { font-size: 14px; color: var(--text-secondary); }

/* ===== FEATURES ===== */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.feature-card {
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: all var(--transition);
}
.feature-card:hover { border-color: var(--primary); transform: translateY(-2px); }
.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: var(--primary-dim);
  color: var(--primary);
  border-radius: var(--radius);
  margin-bottom: 16px;
}
.feature-card h3 { font-size: 17px; font-weight: 600; margin-bottom: 8px; }
.feature-card p { font-size: 14px; color: var(--text-secondary); margin-bottom: 16px; }
.feature-code {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 14px;
  overflow-x: auto;
}
.feature-code code {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--secondary);
}

/* ===== SDK PREVIEW ===== */
.sdk-preview {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 40px;
  align-items: center;
}
.code-block {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.code-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: var(--surface-light);
  border-bottom: 1px solid var(--border);
}
.code-lang { font-size: 12px; font-weight: 600; color: var(--text-muted); font-family: var(--font-mono); }
.copy-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 12px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  transition: all var(--transition);
}
.copy-btn:hover { background: var(--surface); color: var(--text); }
.code-block pre { padding: 20px; overflow-x: auto; margin: 0; }
.code-block code {
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.7;
  color: var(--text-secondary);
}
.code-comment { color: var(--text-muted); }
.code-cmd { color: var(--accent); }
.code-keyword { color: var(--primary-hover); }
.code-string { color: var(--secondary); }
.code-prop { color: var(--accent); }
.code-bool { color: var(--primary-hover); }
.code-func { color: var(--accent); }
.sdk-features { display: flex; flex-direction: column; gap: 16px; }
.sdk-feature {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 15px;
  color: var(--text-secondary);
}
.sdk-feature i { color: var(--secondary); flex-shrink: 0; }

/* ===== PRICING ===== */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  max-width: 1000px;
  margin: 0 auto;
}
.pricing-card {
  position: relative;
  padding: 32px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  transition: all var(--transition);
}
.pricing-card:hover { transform: translateY(-4px); }
.pricing-card.popular {
  border-color: var(--primary);
  box-shadow: var(--shadow-glow);
}
.pricing-card.enterprise { background: var(--bg); }
.popular-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary);
  color: white;
  padding: 4px 14px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
}
.pricing-header { margin-bottom: 20px; }
.pricing-header h3 { font-size: 20px; font-weight: 700; margin-bottom: 4px; }
.pricing-desc { font-size: 14px; color: var(--text-muted); }
.pricing-amount { margin-bottom: 24px; }
.price { font-size: 48px; font-weight: 700; }
.period { font-size: 16px; color: var(--text-muted); }
.pricing-features { list-style: none; margin-bottom: 24px; }
.pricing-features li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  font-size: 14px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-light);
}
.pricing-features li:last-child { border-bottom: none; }
.pricing-features i { color: var(--secondary); flex-shrink: 0; }
.pricing-note { text-align: center; font-size: 14px; color: var(--text-muted); margin-top: 32px; }

/* ===== CTA FOOTER ===== */
.cta-footer {
  padding: 80px 0 40px;
  background: linear-gradient(180deg, var(--surface) 0%, var(--bg) 100%);
  text-align: center;
}
.cta-footer h2 { font-size: 36px; font-weight: 700; margin-bottom: 12px; }
.cta-footer > .container > p { font-size: 18px; color: var(--text-secondary); margin-bottom: 32px; }
.cta-actions { display: flex; justify-content: center; gap: 16px; margin-bottom: 64px; flex-wrap: wrap; }
.footer-links {
  display: flex;
  justify-content: center;
  gap: 48px;
  margin-bottom: 48px;
  flex-wrap: wrap;
}
.footer-col { text-align: left; }
.footer-col h4 { font-size: 13px; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 16px; }
.footer-col a { display: block; color: var(--text-secondary); text-decoration: none; font-size: 14px; margin-bottom: 10px; transition: color var(--transition); }
.footer-col a:hover { color: var(--text); }
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 32px;
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
  gap: 16px;
}
.footer-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-secondary);
  font-weight: 600;
}
.copyright { font-size: 13px; color: var(--text-muted); }
.social-links { display: flex; gap: 16px; }
.social-links a { color: var(--text-muted); transition: color var(--transition); }
.social-links a:hover { color: var(--text); }

/* ===== ANIMATIONS ===== */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .hero-container { grid-template-columns: 1fr; gap: 48px; }
  .hero-visual { order: -1; }
  .steps-grid { grid-template-columns: repeat(2, 1fr); }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .sdk-preview { grid-template-columns: 1fr; }
  .pricing-grid { grid-template-columns: 1fr; max-width: 400px; }
}

@media (max-width: 768px) {
  .navbar-links, .navbar-actions { display: none; }
  .mobile-menu-btn { display: block; }
  .hero h1 { font-size: 36px; }
  .hero-sub { font-size: 16px; }
  .stats-grid { grid-template-columns: 1fr; }
  .steps-grid { grid-template-columns: 1fr; }
  .features-grid { grid-template-columns: 1fr; }
  .section { padding: 60px 0; }
  .section-header h2 { font-size: 28px; }
  .cta-footer h2 { font-size: 28px; }
  .footer-links { gap: 32px; }
  .footer-bottom { flex-direction: column; text-align: center; }
}

/* ===== UTILITIES ===== */
.text-center { text-align: center; }
.mt-4 { margin-top: 16px; }
.mb-4 { margin-bottom: 16px; }