/* Dusk Mind — product website styles. Matches the app's twilight palette. */

/* ── Reset & base ── */
:root {
  --bg: #0c0a12;
  --bg-2: #100d18;
  --surface: #17131f;
  --surface-2: #1d1828;
  --surface-3: #251f33;
  --line: rgba(196, 178, 255, .09);
  --line-2: rgba(196, 178, 255, .16);
  --text: #ece8f5;
  --text-2: #b7aecb;
  --muted: #847b98;
  --accent: #b391ff;
  --accent-2: #ff8a7a;
  --amber: #ffc46b;
  --grad: linear-gradient(120deg, #ffc46b 0%, #ff6f7d 45%, #9b6bff 100%);
  --grad-soft: linear-gradient(120deg, rgba(255,196,107,.16), rgba(255,111,125,.12) 45%, rgba(155,107,255,.18));
  --ok: #6ee7b7;
  --radius: 16px;
  --ui: "Segoe UI Variable Text", "Segoe UI", -apple-system, BlinkMacSystemFont, "Inter", system-ui, sans-serif;
  --mono: "Cascadia Code", "JetBrains Mono", "SF Mono", Menlo, Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 var(--ui);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: var(--accent); text-decoration: none; transition: color .2s; }
a:hover { color: var(--amber); }

/* ── Sky background ── */
.sky { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; }
.glow { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .4; animation: drift 26s ease-in-out infinite alternate; }
.g1 { width: 620px; height: 420px; left: 30%; top: -260px; background: #6b3fd6; opacity: .25; }
.g2 { width: 520px; height: 360px; right: -140px; top: -180px; background: #ff6f7d; opacity: .12; animation-delay: -8s; }
.g3 { width: 480px; height: 320px; left: -160px; bottom: -220px; background: #ffb35c; opacity: .06; animation-delay: -16s; }
@keyframes drift { to { transform: translate(60px, 40px) scale(1.12); } }

/* ── Nav ── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 48px; height: 64px;
  background: rgba(12, 10, 18, .85);
  backdrop-filter: blur(16px) saturate(1.4);
  border-bottom: 1px solid var(--line);
}
.nav-logo {
  display: flex; align-items: center; gap: 10px;
  font-size: 18px; font-weight: 700; color: var(--text);
}
.nav-logo:hover { color: var(--text); }
.nav-icon { width: 24px; height: 24px; flex: none; }
.nav-links { display: flex; gap: 32px; }
.nav-links a { color: var(--text-2); font-size: 14px; font-weight: 500; transition: color .2s; }
.nav-links a:hover { color: var(--text); }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 24px; border-radius: 10px; font-weight: 600; font-size: 14px;
  cursor: pointer; transition: all .2s; border: none; text-decoration: none;
}
.btn-primary {
  background: var(--grad); color: #0c0a12; box-shadow: 0 4px 20px rgba(155,107,255,.3);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 28px rgba(155,107,255,.45); }
.btn-ghost { border: 1px solid var(--line-2); color: var(--text-2); background: transparent; }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn-nav { padding: 8px 20px; font-size: 13px; }
.btn-lg { padding: 14px 36px; font-size: 16px; border-radius: 12px; }
.btn-full { width: 100%; }
.btn-ghost-full { border: 1px solid var(--line-2); color: var(--text-2); background: transparent; }
.btn-ghost-full:hover { border-color: var(--accent); color: var(--accent); }

/* ── Hero ── */
.hero {
  position: relative; z-index: 1;
  max-width: 1200px; margin: 0 auto; padding: 140px 48px 60px;
  display: grid; gap: 48px;
}
.hero-inner { text-align: center; }
.badge {
  display: inline-block; padding: 5px 16px; border-radius: 20px;
  background: var(--grad-soft); color: var(--amber); font-size: 13px; font-weight: 600;
  border: 1px solid rgba(255,196,107,.2);
}
.hero h1 {
  font-size: clamp(36px, 5vw, 64px); font-weight: 800; line-height: 1.1;
  margin: 24px 0; letter-spacing: -.02em;
}
.gradient-text { background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-sub { font-size: 18px; color: var(--text-2); max-width: 640px; margin: 0 auto 32px; line-height: 1.7; }
.hero-actions { display: flex; align-items: center; justify-content: center; gap: 20px; flex-wrap: wrap; }
.hero-divider { color: var(--muted); font-size: 14px; }
.hero-note { margin-top: 24px; color: var(--muted); font-size: 13px; }

/* ── Mockup ── */
.hero-mockup { max-width: 960px; margin: 0 auto; }
.mockup-frame {
  border-radius: 14px; overflow: hidden;
  background: #17131f; border: 1px solid var(--line-2);
  box-shadow: 0 32px 80px rgba(0,0,0,.5), 0 0 0 1px rgba(196,178,255,.06);
}
.mockup-titlebar {
  display: flex; align-items: center; gap: 8px;
  padding: 14px 16px; background: #0f0c17; border-bottom: 1px solid var(--line);
}
.dot { width: 12px; height: 12px; border-radius: 50%; }
.dot.red { background: #ff5f57; }
.dot.yellow { background: #febc2e; }
.dot.green { background: #28c840; }
.mockup-title { margin-left: 12px; color: var(--muted); font-size: 13px; }
.mockup-body { display: flex; height: 380px; }
.mockup-sidebar {
  width: 200px; padding: 16px; border-right: 1px solid var(--line); background: rgba(15,12,23,.5);
}
.mockup-sidebar-item {
  padding: 8px 12px; border-radius: 8px; font-size: 13px; color: var(--text-2); margin-bottom: 4px;
  display: flex; align-items: center; gap: 8px; cursor: default;
}
.mockup-sidebar-item.active { background: var(--surface-3); color: var(--text); }
.mockup-sidebar-group { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 12px 12px 4px; font-weight: 600; }
.mockup-chat { flex: 1; padding: 20px; display: flex; flex-direction: column; gap: 16px; }
.chat-msg { padding: 12px 16px; border-radius: 12px; font-size: 14px; line-height: 1.5; max-width: 75%; }
.chat-user { background: var(--surface-3); align-self: flex-end; color: var(--text); }
.chat-assistant { background: transparent; color: var(--text-2); }
.chat-assistant pre { margin: 8px 0; padding: 12px; background: #0f0c17; border-radius: 8px; overflow-x: auto; }
.chat-assistant code { font-family: var(--mono); font-size: 13px; color: var(--accent); }

/* ── Sections ── */
.features, .how-it-works, .pricing, .faq, .cta {
  position: relative; z-index: 1; max-width: 1100px; margin: 0 auto; padding: 80px 48px;
}
.section-header { text-align: center; margin-bottom: 56px; }
.section-header h2 { font-size: clamp(28px, 3.5vw, 44px); font-weight: 800; margin-bottom: 12px; letter-spacing: -.02em; }
.section-header p { color: var(--text-2); font-size: 17px; max-width: 520px; margin: 0 auto; }

/* ── Feature grid ── */
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.feature-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; transition: all .25s;
}
.feature-card:hover { border-color: rgba(179,145,255,.3); transform: translateY(-2px); box-shadow: 0 12px 40px rgba(0,0,0,.3); }
.feature-icon { font-size: 32px; margin-bottom: 16px; }
.feature-card h3 { font-size: 17px; font-weight: 700; margin-bottom: 8px; }
.feature-card p { color: var(--text-2); font-size: 14px; line-height: 1.6; }

/* ── Steps ── */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 32px; }
.step { text-align: center; padding: 32px 24px; }
.step-num {
  width: 56px; height: 56px; border-radius: 50%; margin: 0 auto 20px;
  background: var(--grad-soft); border: 1px solid var(--line-2);
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; font-weight: 800; color: var(--accent);
}
.step h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.step p { color: var(--text-2); font-size: 14px; line-height: 1.6; }

/* ── Pricing ── */
.pricing-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; max-width: 800px; margin: 0 auto; }
.pricing-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: 20px;
  padding: 36px; text-align: center; position: relative; transition: all .25s;
}
.pricing-card:hover { border-color: rgba(179,145,255,.25); }
.pricing-card.featured { border-color: rgba(179,145,255,.35); box-shadow: 0 0 60px rgba(155,107,255,.15); }
.pricing-badge {
  position: absolute; top: -14px; left: 50%; transform: translateX(-50%);
  background: var(--grad); color: #0c0a12; padding: 4px 20px; border-radius: 20px;
  font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em;
}
.pricing-card h3 { font-size: 20px; font-weight: 700; margin-bottom: 16px; }
.price { display: flex; align-items: baseline; justify-content: center; gap: 2px; margin-bottom: 24px; }
.currency { font-size: 24px; color: var(--text-2); }
.amount { font-size: 56px; font-weight: 800; background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.period { font-size: 14px; color: var(--muted); margin-left: 4px; }
.pricing-features { list-style: none; text-align: left; margin-bottom: 28px; }
.pricing-features li { padding: 8px 0; font-size: 14px; color: var(--text-2); border-bottom: 1px solid var(--line); }
.pricing-features li:last-child { border-bottom: none; }
.pricing-note { margin-top: 16px; font-size: 13px; color: var(--muted); }

/* ── FAQ ── */
.faq-list { max-width: 720px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q {
  width: 100%; text-align: left; padding: 20px 0; background: none; border: none; color: var(--text);
  font-size: 16px; font-weight: 600; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.faq-q:hover { color: var(--accent); }
.faq-arrow { font-size: 14px; color: var(--muted); flex: none; transition: transform .2s; }
.faq-item.open .faq-arrow { transform: rotate(180deg); }
.faq-a {
  max-height: 0; overflow: hidden; transition: max-height .35s ease;
}
.faq-a p { padding: 0 0 20px; color: var(--text-2); font-size: 14px; line-height: 1.7; }

/* ── CTA ── */
.cta { text-align: center; padding: 80px 48px 100px; }
.cta h2 { font-size: clamp(28px, 3vw, 40px); font-weight: 800; margin-bottom: 12px; }
.cta p { color: var(--text-2); font-size: 17px; margin-bottom: 32px; }

/* ── Footer ── */
.footer { position: relative; z-index: 1; border-top: 1px solid var(--line); padding: 48px; }
.footer-inner { max-width: 1100px; margin: 0 auto; display: grid; gap: 32px; }
.footer-brand .nav-logo { font-size: 16px; margin-bottom: 8px; }
.footer-brand p { color: var(--muted); font-size: 13px; }
.footer-links { display: flex; gap: 24px; justify-content: center; }
.footer-links a { color: var(--text-2); font-size: 14px; }
.footer-legal { text-align: center; color: var(--muted); font-size: 13px; }
.footer-legal a { color: var(--muted); }

/* ══ Scroll Reveal ══ */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity .7s cubic-bezier(.22,1,.36,1), transform .7s cubic-bezier(.22,1,.36,1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ══ Staggered entrances ══ */
.feature-card:nth-child(1) { transition-delay: .05s; }
.feature-card:nth-child(2) { transition-delay: .1s; }
.feature-card:nth-child(3) { transition-delay: .15s; }
.feature-card:nth-child(4) { transition-delay: .2s; }
.feature-card:nth-child(5) { transition-delay: .25s; }
.feature-card:nth-child(6) { transition-delay: .3s; }
.feature-card:nth-child(7) { transition-delay: .35s; }
.feature-card:nth-child(8) { transition-delay: .4s; }

.step:nth-child(1) { transition-delay: .05s; }
.step:nth-child(2) { transition-delay: .15s; }
.step:nth-child(3) { transition-delay: .25s; }

.pricing-cards > div:nth-child(1) { transition-delay: .05s; }
.pricing-cards > div:nth-child(2) { transition-delay: .15s; }

/* ══ Animated gradient text ══ */
@keyframes gradient-shift {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
.gradient-text {
  background-size: 300% 300%;
  animation: gradient-shift 6s ease infinite;
}

/* ══ Feature card glow on hover ══ */
.feature-card::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: var(--grad);
  opacity: 0;
  z-index: -1;
  filter: blur(12px);
  transition: opacity .35s ease;
}
.feature-card { position: relative; overflow: visible; }
.feature-card:hover::before { opacity: .25; }

/* ══ Typing cursor ══ */
@keyframes blink {
  0%, 100% { border-color: transparent; }
  50% { border-color: var(--accent); }
}
.typing-cursor::after {
  content: '';
  display: inline-block;
  width: 2px;
  height: 1em;
  margin-left: 2px;
  background: var(--accent);
  animation: blink .8s infinite;
  vertical-align: text-bottom;
}

/* ══ Parallax sky glows (transition instead of keyframes) ══ */
.sky { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; }
.glow { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .4; transition: transform .6s cubic-bezier(.22,1,.36,1); will-change: transform; }

/* ══ Pricing card float on hover ══ */
.pricing-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 60px rgba(0,0,0,.35);
}

/* ══ CTA button pulse ══ */
@keyframes subtle-pulse {
  0%, 100% { box-shadow: 0 4px 20px rgba(155,107,255,.3); }
  50% { box-shadow: 0 4px 36px rgba(155,107,255,.55); }
}
.cta .btn-primary { animation: subtle-pulse 3s ease-in-out infinite; }

/* ══ Badge shimmer ══ */
@keyframes shimmer {
  0%   { background-position: -200% center; }
  100% { background-position: 200% center; }
}
.badge {
  background-size: 200% auto;
  background-image: linear-gradient(90deg, var(--amber) 0%, #fff 50%, var(--amber) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: shimmer 4s linear infinite;
}

/* ══ Step number ring pulse ══ */
@keyframes ring-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(155,107,255,.3); }
  70%  { box-shadow: 0 0 0 16px rgba(155,107,255,0); }
  100% { box-shadow: 0 0 0 0 rgba(155,107,255,0); }
}
.step-num { animation: ring-pulse 3s ease-out infinite; }

/* ══ Responsive ── */
@media (max-width: 768px) {
  .nav { padding: 0 20px; }
  .nav-links { display: none; }
  .hero { padding: 120px 24px 40px; }
  .features, .how-it-works, .pricing, .faq, .cta { padding: 60px 24px; }
  .mockup-body { flex-direction: column; height: auto; }
  .mockup-sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--line); }
  .hero-actions { flex-direction: column; }
  .footer-inner { grid-template-columns: 1fr; text-align: center; }
  .footer-links { flex-wrap: wrap; justify-content: center; }
}
