:root {
  --bg: #0f0f1a;
  --bg-card: #1a1a2e;
  --bg-elevated: #222240;
  --text: #e8e8f0;
  --text-muted: #9898b0;
  --accent: #f5a623;
  --accent-hover: #ffb840;
  --purple: #6c5ce7;
  --purple-light: #a29bfe;
  --border: rgba(255, 255, 255, 0.08);
  --radius: 12px;
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  --font: 'Inter', system-ui, sans-serif;
  --font-display: 'Playfair Display', Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font); background: var(--bg); color: var(--text); line-height: 1.6; min-height: 100vh; }
.container { width: min(1140px, 92vw); margin: 0 auto; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }

.header { position: sticky; top: 0; z-index: 100; background: rgba(15, 15, 26, 0.85); backdrop-filter: blur(12px); border-bottom: 1px solid var(--border); }
.nav { display: flex; align-items: center; gap: 1.5rem; padding: 0.85rem 0; position: relative; flex-wrap: wrap; }
.logo { display: flex; align-items: center; gap: 0.5rem; color: var(--text); font-weight: 700; font-size: 1.1rem; }
.logo-icon { font-size: 1.5rem; }
.logo em { color: var(--accent); font-style: normal; }
.nav-links { display: flex; list-style: none; gap: 1.5rem; margin-left: auto; }
.nav-links a { color: var(--text-muted); font-size: 0.9rem; font-weight: 500; }
.nav-links a:hover { color: var(--text); }
.nav-actions { display: flex; gap: 0.5rem; align-items: center; }
.user-pill { font-size: 0.85rem; color: var(--purple-light); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem; padding: 0.55rem 1.2rem; border-radius: 8px; font-family: var(--font); font-size: 0.9rem; font-weight: 600; cursor: pointer; border: none; transition: all 0.2s; }
.btn-primary { background: linear-gradient(135deg, var(--accent), #e8940f); color: #1a1a2e; }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 4px 16px rgba(245, 166, 35, 0.35); }
.btn-ghost { background: transparent; color: var(--text-muted); border: 1px solid var(--border); }
.btn-outline { background: transparent; color: var(--text); border: 1px solid var(--border); }
.btn-lg { padding: 0.75rem 1.6rem; font-size: 1rem; }
.btn-block { width: 100%; }
.btn-sm { padding: 0.35rem 0.75rem; font-size: 0.8rem; }

.carousel {
  position: relative;
  height: clamp(380px, 52vh, 540px);
  overflow: hidden;
  border-radius: 20px;
  margin-bottom: 2.5rem;
  border: 1px solid var(--border);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  background: #12121f;
}
.carousel-track { position: absolute; inset: 0; }
.carousel-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.8s ease, visibility 0.8s;
}
.carousel-slide.active { opacity: 1; visibility: visible; z-index: 1; }
.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.08);
  transition: transform 7s linear;
}
.carousel-slide.active img { transform: scale(1); }
.carousel-slide::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(10,10,18,0.92) 0%, rgba(10,10,18,0.45) 48%, rgba(10,10,18,0.15) 100%),
    linear-gradient(180deg, rgba(10,10,18,0.15) 0%, rgba(10,10,18,0.55) 100%);
}
.carousel-caption {
  position: absolute;
  left: clamp(1.25rem, 4vw, 3rem);
  bottom: clamp(2.4rem, 6vh, 4rem);
  z-index: 2;
  max-width: min(560px, 86%);
  transform: translateY(16px);
  opacity: 0;
  transition: transform 0.55s ease, opacity 0.55s ease;
}
.carousel-slide.active .carousel-caption { transform: translateY(0); opacity: 1; }
.carousel-kicker {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.7rem;
}
.carousel-caption h2 {
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 4vw, 2.7rem);
  line-height: 1.15;
  margin-bottom: 0.65rem;
}
.carousel-caption p { color: #c9c9d8; font-size: 1.02rem; margin-bottom: 1.15rem; max-width: 42ch; }
.carousel-caption .price { margin-right: 0.75rem; }
.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 4;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.18);
  background: rgba(15,15,26,0.45);
  color: #fff;
  cursor: pointer;
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, border-color 0.2s;
}
.carousel-arrow:hover { background: rgba(245,166,35,0.9); color: #1a1a2e; border-color: transparent; }
.carousel-arrow.prev { left: 1rem; }
.carousel-arrow.next { right: 1rem; }
.carousel-chrome {
  position: absolute;
  right: clamp(1rem, 3vw, 2rem);
  bottom: 1.15rem;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.carousel-index {
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  color: rgba(255,255,255,0.7);
  font-weight: 600;
}
.carousel-dots { display: flex; gap: 0.4rem; }
.carousel-dots button {
  width: 28px;
  height: 4px;
  border: none;
  border-radius: 99px;
  background: rgba(255,255,255,0.28);
  cursor: pointer;
  padding: 0;
}
.carousel-dots button.active { background: var(--accent); }
.carousel-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  background: rgba(255,255,255,0.08);
  z-index: 5;
}
.carousel-progress span {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--purple), var(--accent));
}
.carousel-progress span.run { animation: carouselFill 6s linear forwards; }
@keyframes carouselFill { from { width: 0; } to { width: 100%; } }
@media (prefers-reduced-motion: reduce) {
  .carousel-slide img, .carousel-caption, .carousel-progress span { transition: none; animation: none; }
}

.hero { position: relative; padding: 3rem 0 4rem; }
.hero-bg { position: absolute; inset: 0; background: radial-gradient(ellipse 80% 60% at 20% 40%, rgba(108, 92, 231, 0.25), transparent), radial-gradient(ellipse 60% 50% at 80% 20%, rgba(245, 166, 35, 0.15), transparent); pointer-events: none; }
.hero-inner { position: relative; display: grid; grid-template-columns: 1fr 340px; gap: 3rem; align-items: center; }
.hero-badge { display: inline-block; padding: 0.3rem 0.8rem; background: rgba(108, 92, 231, 0.2); border: 1px solid rgba(108, 92, 231, 0.4); border-radius: 999px; font-size: 0.8rem; font-weight: 600; color: var(--purple-light); margin-bottom: 1rem; }
.hero h1 { font-family: var(--font-display); font-size: clamp(2rem, 5vw, 3rem); line-height: 1.15; margin-bottom: 1rem; }
.gradient-text { background: linear-gradient(135deg, var(--accent), var(--purple-light)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-lead { color: var(--text-muted); font-size: 1.05rem; max-width: 520px; margin-bottom: 1.75rem; }
.hero-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.hero-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); padding: 0; overflow: hidden; box-shadow: var(--shadow); }
.hero-card .idea-cover { height: 140px; }
.hero-card-inner { padding: 1.5rem; }
.pill-hot { background: rgba(245, 166, 35, 0.15); color: var(--accent); padding: 0.2rem 0.6rem; border-radius: 999px; font-size: 0.75rem; font-weight: 600; }
.price { font-size: 1.25rem; font-weight: 700; color: var(--accent); }

.stats { padding: 2rem 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--bg-card); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.stat-card { text-align: center; }
.stat-value { display: block; font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 700; color: var(--accent); }
.stat-label { display: block; color: var(--text-muted); font-size: 0.85rem; margin-top: 0.25rem; }

.section { padding: 4rem 0; }
.section-dark { background: var(--bg-card); }
.section-title { font-family: var(--font-display); font-size: clamp(1.5rem, 3vw, 2rem); margin-bottom: 1rem; }
.section-text { color: var(--text-muted); margin-bottom: 1rem; max-width: 560px; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; }
.feature-card { background: var(--bg-elevated); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.25rem; margin-bottom: 1rem; }
.section-header { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem; margin-bottom: 2rem; }
.search-bar { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.search-bar input, .search-bar select, .contact-form input, .contact-form textarea, .modal-form input, .modal-form textarea, .modal-form select {
  background: var(--bg-elevated); border: 1px solid var(--border); border-radius: 8px; color: var(--text); font-family: var(--font); padding: 0.6rem 0.9rem;
}
.ideas-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.25rem; }
.idea-card { background: var(--bg-elevated); border: 1px solid var(--border); border-radius: var(--radius); padding: 0; overflow: hidden; transition: transform 0.2s; cursor: pointer; display: flex; flex-direction: column; }
.idea-card:hover { transform: translateY(-3px); border-color: rgba(245, 166, 35, 0.3); }
.idea-cover { width: 100%; height: 168px; object-fit: cover; display: block; background: #1a1a2e; }
.idea-cover-placeholder { height: 168px; background: linear-gradient(135deg, rgba(108,92,231,0.35), rgba(245,166,35,0.2)); }
.idea-card-inner { padding: 1.15rem 1.25rem 1.25rem; display: flex; flex-direction: column; flex: 1; }
.idea-modal-cover { width: 100%; height: 200px; object-fit: cover; border-radius: 8px; margin-bottom: 1rem; display: block; }
.idea-tag { font-size: 0.7rem; font-weight: 600; text-transform: uppercase; padding: 0.15rem 0.5rem; border-radius: 4px; background: rgba(108, 92, 231, 0.2); color: var(--purple-light); }
.idea-card-top { display: flex; justify-content: space-between; margin-bottom: 0.75rem; }
.idea-card p { color: var(--text-muted); font-size: 0.85rem; margin-bottom: 0.75rem; }
.lock-hint { font-size: 0.75rem; color: var(--accent); margin-bottom: 0.85rem; }
.idea-teaser { color: var(--text-muted); margin: 0.75rem 0 1rem; }
.idea-meta { margin: 1rem 0; }
.idea-lock {
  background: var(--bg-elevated);
  border: 1px dashed var(--border);
  border-radius: 8px;
  padding: 1.1rem 1rem;
  text-align: center;
  color: var(--text-muted);
  margin: 1rem 0;
}
.idea-lock span { display: block; font-size: 1.4rem; margin-bottom: 0.4rem; }
.idea-body { margin: 1rem 0; padding: 1rem; background: var(--bg-elevated); border-radius: 8px; border: 1px solid rgba(245, 166, 35, 0.25); }
.idea-body h3 { font-size: 0.95rem; color: var(--accent); margin-bottom: 0.6rem; }
.idea-body-text { white-space: pre-wrap; font-size: 0.92rem; line-height: 1.55; }
.field-hint { display: block; font-size: 0.75rem; color: var(--text-muted); font-weight: 400; margin-bottom: 0.25rem; }
.purchase-card { background: var(--bg-elevated); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.25rem; margin-bottom: 1rem; }
.purchase-card h3 { margin-bottom: 0.35rem; }
.purchase-card .idea-teaser { margin-top: 0.35rem; }
.idea-card-footer { display: flex; justify-content: space-between; align-items: center; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; margin-top: 2rem; }
.step { text-align: center; }
.step-num { display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; border-radius: 50%; background: linear-gradient(135deg, var(--purple), var(--accent)); color: #fff; font-weight: 700; margin-bottom: 1rem; }

.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; }
.contact-form { display: flex; flex-direction: column; gap: 1rem; }
.contact-form label, .modal-form label { display: flex; flex-direction: column; gap: 0.35rem; font-size: 0.85rem; color: var(--text-muted); }

.footer { border-top: 1px solid var(--border); padding: 2rem 0; color: var(--text-muted); font-size: 0.85rem; }
.footer-inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 0.5rem; }

.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.7); display: flex; align-items: center; justify-content: center; z-index: 200; padding: 1rem; }
.modal-overlay[hidden] { display: none; }
.modal { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); padding: 2rem; width: min(440px, 100%); position: relative; max-height: 90vh; overflow-y: auto; }
.modal.modal-idea { width: min(640px, 100%); }
.modal-close { position: absolute; top: 0.75rem; right: 1rem; background: none; border: none; color: var(--text-muted); font-size: 1.5rem; cursor: pointer; }
.modal-form { display: flex; flex-direction: column; gap: 0.85rem; }
.modal-note { margin-top: 1rem; font-size: 0.8rem; color: var(--text-muted); text-align: center; }

.toast { position: fixed; bottom: 2rem; left: 50%; transform: translateX(-50%); background: var(--bg-elevated); border: 1px solid var(--accent); padding: 0.75rem 1.5rem; border-radius: 8px; z-index: 300; }
.toast[hidden] { display: none; }

.dash-tabs { display: flex; gap: 0.5rem; margin-bottom: 1.5rem; }
.dash-tabs button { background: var(--bg-elevated); border: 1px solid var(--border); color: var(--text-muted); padding: 0.5rem 1rem; border-radius: 8px; cursor: pointer; }
.dash-tabs button.active { border-color: var(--accent); color: var(--accent); }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 0.75rem; border-bottom: 1px solid var(--border); font-size: 0.9rem; }
th { color: var(--text-muted); font-weight: 500; }

.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; margin-left: auto; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--text); }

@media (max-width: 900px) {
  .hero-inner, .two-col, .contact-grid, .steps { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .carousel { height: min(68vw, 420px); border-radius: 16px; }
  .carousel-arrow { width: 38px; height: 38px; }
  .carousel-arrow.prev { left: 0.6rem; }
  .carousel-arrow.next { right: 0.6rem; }
}
@media (max-width: 768px) {
  .nav-toggle { display: flex; }
  .nav-links, .nav-actions { display: none; width: 100%; flex-direction: column; }
  .nav.open .nav-links, .nav.open .nav-actions { display: flex; }
  .nav-links { margin-left: 0; }
}
