/* ===========================
   IdeaGenius — Main Stylesheet
   =========================== */

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

:root {
  --black:   #09090b;
  --dark:    #0f0f12;
  --card:    #18181b;
  --border:  #27272a;
  --purple:  #7c3aed;
  --purple-light: #a78bfa;
  --purple-glow: rgba(124,58,237,0.15);
  --green:   #10b981;
  --orange:  #f97316;
  --white:   #ffffff;
  --gray:    #71717a;
  --light:   #d4d4d8;
}

html { scroll-behavior: smooth; }
body {
  background: var(--black);
  color: var(--white);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
}
.purple { color: var(--purple-light); }
.green  { color: var(--green); }
.container { max-width: 1060px; margin: 0 auto; padding: 0 24px; }
.center { text-align: center; }

/* === NAV === */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(9,9,11,0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1060px; margin: 0 auto; padding: 16px 24px;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.nav-logo-icon { font-size: 24px; }
.nav-logo-text { font-size: 18px; font-weight: 800; color: var(--white); letter-spacing: -0.5px; }
.nav-logo-text span { color: var(--purple-light); }
.nav-links { display: flex; gap: 24px; align-items: center; }
.nav-links a { color: var(--gray); text-decoration: none; font-size: 14px; transition: color 0.2s; }
.nav-links a:hover { color: var(--white); }
.nav-cta {
  background: var(--purple); color: var(--white) !important;
  padding: 8px 18px; border-radius: 6px; font-weight: 600 !important;
  font-size: 13px !important; transition: background 0.2s !important;
}
.nav-cta:hover { background: #6d28d9 !important; }

/* === HERO === */
.hero {
  min-height: 100vh; display: flex; align-items: center;
  justify-content: center; padding: 120px 24px 80px; position: relative; overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; top: 20%; left: 50%;
  transform: translate(-50%, -50%);
  width: 600px; height: 600px;
  background: radial-gradient(circle, var(--purple-glow) 0%, transparent 70%);
  pointer-events: none;
}
.hero-inner { text-align: center; position: relative; z-index: 2; max-width: 760px; margin: 0 auto; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(124,58,237,0.1); border: 1px solid rgba(124,58,237,0.3);
  color: var(--purple-light); padding: 6px 16px; border-radius: 20px;
  font-size: 13px; font-weight: 600; margin-bottom: 28px;
}
.hero h1 { font-size: clamp(38px, 6vw, 68px); font-weight: 900; line-height: 1.1; letter-spacing: -2px; margin-bottom: 20px; }
.hero h1 .highlight {
  background: linear-gradient(135deg, var(--purple-light), #c084fc);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.hero-sub { font-size: 19px; color: var(--light); margin-bottom: 40px; max-width: 560px; margin-left: auto; margin-right: auto; line-height: 1.6; }
.hero-form { display: flex; gap: 12px; max-width: 480px; margin: 0 auto 16px; flex-wrap: wrap; justify-content: center; }
.hero-input {
  flex: 1; min-width: 240px; background: var(--card); border: 1px solid var(--border);
  border-radius: 8px; padding: 14px 18px; color: var(--white); font-size: 15px;
  outline: none; transition: border-color 0.2s;
}
.hero-input:focus { border-color: var(--purple); }
.hero-input::placeholder { color: var(--gray); }
.btn-primary {
  background: var(--purple); color: var(--white); border: none;
  border-radius: 8px; padding: 14px 28px; font-size: 15px; font-weight: 700;
  cursor: pointer; transition: all 0.2s; white-space: nowrap;
}
.btn-primary:hover { background: #6d28d9; transform: translateY(-1px); box-shadow: 0 4px 20px rgba(124,58,237,0.4); }
.hero-note { font-size: 13px; color: var(--gray); margin-bottom: 40px; }

.hero-stats {
  display: flex; align-items: center; justify-content: center;
  gap: 0; margin-top: 8px; flex-wrap: wrap;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  border-radius: 12px; padding: 20px 32px;
  max-width: 480px; margin-left: auto; margin-right: auto;
}
.hero-stat { display: flex; flex-direction: column; align-items: center; padding: 0 24px; }
.stat-num { font-size: 22px; font-weight: 900; color: var(--white); letter-spacing: -0.5px; }
.stat-label { font-size: 12px; color: var(--gray); margin-top: 2px; }
.hero-stat-divider { width: 1px; height: 36px; background: var(--border); }

/* === FILTERS === */
.filters-bar { padding: 0 0 32px; display: flex; gap: 10px; flex-wrap: wrap; align-items: center; justify-content: center; }
.filter-btn {
  background: var(--card); border: 1px solid var(--border); color: var(--gray);
  padding: 7px 16px; border-radius: 20px; font-size: 13px; cursor: pointer;
  transition: all 0.2s; font-weight: 500;
}
.filter-btn:hover, .filter-btn.active { background: var(--purple-glow); border-color: var(--purple); color: var(--purple-light); }
.filter-label { font-size: 13px; color: var(--gray); margin-right: 4px; }

/* === IDEAS SECTION === */
.ideas-section { padding: 100px 0 60px; background: var(--dark); }
.section-label { font-size: 12px; font-weight: 700; letter-spacing: 3px; text-transform: uppercase; color: var(--purple-light); margin-bottom: 12px; }
.ideas-section h2 { font-size: clamp(28px, 4vw, 42px); font-weight: 900; margin-bottom: 12px; letter-spacing: -1px; }
.ideas-section .sub { color: var(--light); font-size: 17px; margin-bottom: 40px; max-width: 500px; }

.ideas-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); gap: 20px; }

.idea-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 12px; padding: 24px; transition: border-color 0.2s, transform 0.2s;
  position: relative; overflow: hidden; display: flex; flex-direction: column;
}
.idea-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--purple), #c084fc); opacity: 0; transition: opacity 0.2s;
}
.idea-card:hover { border-color: #3f3f46; transform: translateY(-2px); }
.idea-card:hover::before { opacity: 1; }
.idea-card.hidden { display: none; }

.idea-meta { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; gap: 8px; flex-wrap: wrap; }
.idea-category {
  font-size: 11px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase;
  color: var(--purple-light); background: rgba(124,58,237,0.1); padding: 4px 10px; border-radius: 4px;
}
.idea-difficulty { font-size: 12px; color: var(--gray); }

.idea-card h3 { font-size: 17px; font-weight: 800; margin-bottom: 10px; letter-spacing: -0.3px; }
.idea-card p { color: var(--light); font-size: 14px; line-height: 1.6; margin-bottom: 14px; flex: 1; }

/* Source badge */
.idea-source {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11px; color: var(--gray); background: #1c1c1f;
  border: 1px solid var(--border); border-radius: 4px;
  padding: 4px 10px; margin-bottom: 14px; text-decoration: none;
  transition: color 0.2s, border-color 0.2s;
}
.idea-source:hover { color: var(--purple-light); border-color: var(--purple); }
.idea-source-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--orange); flex-shrink: 0; }

.idea-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 16px; }
.idea-tag { font-size: 11px; color: var(--gray); background: #27272a; padding: 3px 8px; border-radius: 4px; }

.idea-footer { display: flex; justify-content: space-between; align-items: center; padding-top: 14px; border-top: 1px solid var(--border); gap: 8px; }
.idea-audience { font-size: 12px; color: var(--gray); }
.idea-monetization { font-size: 12px; color: var(--green); font-weight: 600; }

/* Vote + action bar */
.idea-actions { display: flex; align-items: center; justify-content: space-between; margin-top: 14px; gap: 8px; }
.vote-btn {
  display: flex; align-items: center; gap: 6px;
  background: transparent; border: 1px solid var(--border);
  color: var(--gray); padding: 7px 14px; border-radius: 6px;
  font-size: 13px; font-weight: 600; cursor: pointer; transition: all 0.2s;
}
.vote-btn:hover, .vote-btn.voted { background: rgba(124,58,237,0.1); border-color: var(--purple); color: var(--purple-light); }
.vote-count { font-weight: 700; }
.build-btn {
  display: flex; align-items: center; gap: 6px;
  background: var(--purple); color: var(--white);
  padding: 7px 16px; border-radius: 6px; border: none;
  font-size: 13px; font-weight: 700; cursor: pointer;
  text-decoration: none; transition: all 0.2s;
}
.build-btn:hover { background: #6d28d9; }
.bookmark-btn {
  background: transparent; border: 1px solid var(--border);
  color: var(--gray); width: 34px; height: 34px; border-radius: 6px;
  font-size: 15px; cursor: pointer; transition: all 0.2s;
  display: flex; align-items: center; justify-content: center;
}
.bookmark-btn:hover, .bookmark-btn.saved { background: rgba(249,115,22,0.1); border-color: var(--orange); color: var(--orange); }

/* === LEADERBOARD === */
.leaderboard-section { padding: 80px 0; background: var(--black); }
.leaderboard-section h2 { font-size: clamp(24px, 3vw, 36px); font-weight: 900; margin-bottom: 8px; letter-spacing: -1px; }
.leaderboard-section .sub { color: var(--light); font-size: 16px; margin-bottom: 36px; }
.leaderboard-list { display: flex; flex-direction: column; gap: 12px; max-width: 720px; margin: 0 auto; }
.lb-item {
  display: flex; align-items: center; gap: 16px;
  background: var(--card); border: 1px solid var(--border);
  border-radius: 10px; padding: 16px 20px; transition: border-color 0.2s;
}
.lb-item:hover { border-color: #3f3f46; }
.lb-rank { font-size: 20px; font-weight: 900; color: var(--purple-light); min-width: 32px; text-align: center; }
.lb-rank.gold { color: #fbbf24; }
.lb-rank.silver { color: #94a3b8; }
.lb-rank.bronze { color: #d97706; }
.lb-info { flex: 1; }
.lb-title { font-size: 15px; font-weight: 700; margin-bottom: 2px; }
.lb-category { font-size: 12px; color: var(--gray); }
.lb-votes { font-size: 14px; font-weight: 700; color: var(--purple-light); white-space: nowrap; }

/* === HOW IT WORKS === */
.how-section { padding: 100px 0; background: var(--dark); }
.how-section h2 { font-size: clamp(28px, 4vw, 42px); font-weight: 900; margin-bottom: 12px; letter-spacing: -1px; }
.how-section .sub { color: var(--light); font-size: 17px; margin-bottom: 56px; }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 32px; }
.step { text-align: center; }
.step-num {
  width: 48px; height: 48px; background: var(--purple-glow);
  border: 1px solid rgba(124,58,237,0.3); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; font-weight: 900; color: var(--purple-light); margin: 0 auto 16px;
}
.step h3 { font-size: 17px; font-weight: 700; margin-bottom: 8px; }
.step p { color: var(--gray); font-size: 14px; line-height: 1.6; }

/* === NEWSLETTER === */
.newsletter { padding: 100px 0; background: var(--black); }
.newsletter-inner {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 16px; padding: 56px 48px; text-align: center; position: relative; overflow: hidden;
}
.newsletter-inner::before {
  content: ''; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 400px; height: 200px;
  background: radial-gradient(circle, var(--purple-glow) 0%, transparent 70%); pointer-events: none;
}
.newsletter h2 { font-size: clamp(26px, 3vw, 38px); font-weight: 900; margin-bottom: 12px; letter-spacing: -1px; }
.newsletter p { color: var(--light); font-size: 17px; margin-bottom: 36px; max-width: 480px; margin-left: auto; margin-right: auto; }
.newsletter-form { display: flex; gap: 12px; max-width: 440px; margin: 0 auto 16px; flex-wrap: wrap; justify-content: center; }
.newsletter-note { font-size: 13px; color: var(--gray); }

/* === FOOTER === */
footer { padding: 40px 0; background: var(--black); border-top: 1px solid var(--border); }
.footer-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.footer-brand { font-size: 15px; font-weight: 700; color: var(--white); }
.footer-brand span { color: var(--purple-light); }
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: var(--gray); text-decoration: none; font-size: 13px; transition: color 0.2s; }
.footer-links a:hover { color: var(--white); }
.footer-copy { color: #3f3f46; font-size: 12px; }

/* === BUILD MODAL === */
.modal-overlay {
  display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.8);
  z-index: 200; align-items: center; justify-content: center; padding: 24px;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 16px; padding: 36px; max-width: 540px; width: 100%; position: relative;
  max-height: 90vh; overflow-y: auto;
}
.modal-close { position: absolute; top: 16px; right: 16px; background: none; border: none; color: var(--gray); font-size: 20px; cursor: pointer; }
.modal h3 { font-size: 22px; font-weight: 900; margin-bottom: 8px; letter-spacing: -0.5px; }
.modal-category { font-size: 12px; color: var(--purple-light); font-weight: 700; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 16px; }
.modal p { color: var(--light); font-size: 15px; line-height: 1.6; margin-bottom: 24px; }
.modal-section { margin-bottom: 20px; }
.modal-section h4 { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--purple-light); margin-bottom: 10px; }
.modal-tags { display: flex; gap: 8px; flex-wrap: wrap; }
.modal-tag {
  background: #27272a; color: var(--light);
  padding: 6px 12px; border-radius: 6px; font-size: 13px;
}
.modal-tag.tech { background: rgba(124,58,237,0.1); color: var(--purple-light); border: 1px solid rgba(124,58,237,0.2); }
.modal-monetization { font-size: 22px; font-weight: 900; color: var(--green); }
.modal-actions { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; }
.modal-actions .btn-primary { flex: 1; text-align: center; }
.modal-link { flex: 1; display: flex; align-items: center; justify-content: center; gap: 8px; background: #27272a; color: var(--light); border: none; border-radius: 8px; padding: 14px; font-size: 14px; font-weight: 600; cursor: pointer; text-decoration: none; transition: background 0.2s; }
.modal-link:hover { background: #3f3f46; }

/* === BOOKMARK PROMPT ANIMATION === */
@keyframes slideUp {
  from { opacity: 0; transform: translate(-50%, 16px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}

/* === RESPONSIVE === */
@media (max-width: 600px) {
  .nav-links { display: none; }
  .newsletter-inner { padding: 40px 24px; }
  .footer-inner { flex-direction: column; text-align: center; }
  .modal { padding: 24px; }
}
