/* ============================================================
   FlowSale AI — Global Stylesheet
   Brand tokens, reset, typography, nav, footer, layout
   ============================================================ */

/* ── RESET ────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { cursor: pointer; font-family: inherit; border: none; background: none; }

/* ── DESIGN TOKENS ────────────────────────────────────────── */
:root {
  /* Brand colours */
  --blue:          #2563eb;
  --blue-dark:     #1d4ed8;
  --blue-light:    #dbeafe;
  --blue-faint:    #eff6ff;
  --purple:        #7c3aed;
  --purple-dark:   #6d28d9;
  --purple-light:  #ede9fe;
  --purple-faint:  #f5f3ff;
  --green:         #059669;
  --green-light:   #d1fae5;
  --amber:         #d97706;
  --amber-light:   #fef3c7;

  /* Neutrals */
  --dark:          #0f172a;
  --dark-2:        #1e293b;
  --dark-3:        #334155;
  --text:          #334155;
  --muted:         #64748b;
  --border:        #e2e8f0;
  --bg:            #ffffff;
  --bg-alt:        #f8fafc;
  --red:           #ef4444;

  /* Shape */
  --radius:        12px;
  --radius-lg:     20px;
  --radius-xl:     28px;

  /* Shadow */
  --shadow:        0 1px 3px rgba(0,0,0,.06), 0 4px 16px rgba(0,0,0,.06);
  --shadow-lg:     0 8px 32px rgba(0,0,0,.12);
  --shadow-xl:     0 24px 64px rgba(0,0,0,.16);

  /* Motion */
  --transition:    all .25s ease;
}

/* ── TYPOGRAPHY ───────────────────────────────────────────── */
h1 { font-size: clamp(2rem, 5vw, 3.5rem);    font-weight: 800; letter-spacing: -.02em;  line-height: 1.15; color: var(--dark); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.5rem); font-weight: 700; letter-spacing: -.015em; line-height: 1.25; color: var(--dark); }
h3 { font-size: 1.1rem;  font-weight: 600; line-height: 1.4; color: var(--dark); }
h4 { font-size: .95rem;  font-weight: 600; color: var(--dark); }
p  { color: var(--muted); line-height: 1.75; }

.lead {
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  color: var(--muted);
  line-height: 1.75;
}

/* ── LAYOUT ───────────────────────────────────────────────── */
.container  { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 24px; }
.section    { padding: 96px 0; }
.section-sm { padding: 64px 0; }
.section-alt  { background: var(--bg-alt); }
.section-dark { background: var(--dark); }

.section-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 64px;
}
.section-header p { margin-top: 16px; font-size: 1.05rem; }

.section-label {
  display: inline-block;
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--purple);
  margin-bottom: 12px;
}
.section-label.blue   { color: var(--blue); }
.section-label.white  { color: rgba(255,255,255,.65); }
.section-label.green  { color: var(--green); }

/* ── NAVBAR ───────────────────────────────────────────────── */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}

.nav-inner {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 64px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.logo-icon { width: 36px; height: 36px; flex-shrink: 0; }

.logo-text {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--dark);
  letter-spacing: -.01em;
  white-space: nowrap;
}
.logo-text span { color: var(--purple); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.nav-links a {
  padding: 8px 14px;
  border-radius: 8px;
  font-size: .9rem;
  font-weight: 500;
  color: var(--dark-3);
  transition: var(--transition);
}
.nav-links a:hover,
.nav-links a.active { color: var(--purple); background: var(--purple-faint); }

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 20px;
  background: var(--purple);
  color: #fff !important;
  border-radius: 10px;
  font-size: .9rem;
  font-weight: 600;
  transition: var(--transition);
  white-space: nowrap;
  flex-shrink: 0;
}
.nav-cta:hover { background: var(--purple-dark); transform: translateY(-1px); }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  margin-left: auto;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--dark);
  border-radius: 2px;
  transition: var(--transition);
}

/* Mobile nav */
.mobile-nav {
  border-top: 1px solid var(--border);
  padding: 12px 0 16px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.mobile-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: .95rem;
  font-weight: 500;
  color: var(--dark-3);
  transition: var(--transition);
}
.mobile-nav a:hover { color: var(--purple); background: var(--purple-faint); }
.mobile-nav .mobile-cta {
  margin-top: 8px;
  background: var(--purple);
  color: #fff;
  justify-content: center;
  font-weight: 600;
}
.mobile-nav .mobile-cta:hover { background: var(--purple-dark); }

/* ── HERO SHARED ──────────────────────────────────────────── */
.hero {
  background: linear-gradient(135deg, var(--dark) 0%, #1e1040 100%);
  padding: 96px 0 80px;
  overflow: hidden;
  position: relative;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 80% at 70% 40%, rgba(124,58,237,.22) 0%, transparent 70%);
  pointer-events: none;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border: 1px solid rgba(124,58,237,.45);
  border-radius: 100px;
  font-size: .78rem;
  font-weight: 600;
  color: #c4b5fd;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 24px;
}

.hero h1 { color: #fff; }
.hero .lead { color: rgba(255,255,255,.65); max-width: 600px; margin-top: 16px; }

.hero-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 36px;
  flex-wrap: wrap;
}

.hero-meta {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-top: 32px;
  flex-wrap: wrap;
}
.hero-meta-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .85rem;
  color: rgba(255,255,255,.55);
}
.hero-meta-item i { color: #4ade80; }

/* ── STATS BAR ────────────────────────────────────────────── */
.stats-bar {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  padding: 0;
}
.stats-inner {
  display: flex;
  justify-content: space-around;
  align-items: stretch;
  flex-wrap: wrap;
}
.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 28px 24px;
  text-align: center;
  flex: 1;
  min-width: 120px;
  border-right: 1px solid var(--border);
}
.stat-item:last-child { border-right: none; }
.stat-value {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--dark);
  letter-spacing: -.03em;
  line-height: 1;
}
.stat-label {
  font-size: .75rem;
  color: var(--muted);
  margin-top: 6px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .06em;
}

/* ── BUTTONS ──────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 10px;
  font-size: .95rem;
  font-weight: 600;
  transition: var(--transition);
  cursor: pointer;
  border: none;
  font-family: inherit;
}
.btn-primary {
  background: var(--purple);
  color: #fff;
}
.btn-primary:hover { background: var(--purple-dark); transform: translateY(-1px); box-shadow: 0 8px 24px rgba(124,58,237,.35); }

.btn-secondary {
  background: rgba(255,255,255,.1);
  color: #fff;
  border: 1px solid rgba(255,255,255,.2);
}
.btn-secondary:hover { background: rgba(255,255,255,.18); }

.btn-outline {
  background: transparent;
  color: var(--purple);
  border: 2px solid var(--purple);
}
.btn-outline:hover { background: var(--purple); color: #fff; }

.btn-white {
  background: #fff;
  color: var(--purple);
}
.btn-white:hover { background: var(--purple-faint); transform: translateY(-1px); }

/* ── CTA SECTION ──────────────────────────────────────────── */
.cta-section {
  background: linear-gradient(135deg, var(--purple) 0%, #1d4ed8 100%);
  padding: 88px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 80% at 50% 50%, rgba(255,255,255,.07) 0%, transparent 70%);
  pointer-events: none;
}
.cta-section h2 { color: #fff; }
.cta-section p { color: rgba(255,255,255,.7); max-width: 560px; margin: 16px auto 0; }
.cta-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 36px;
  flex-wrap: wrap;
}
.cta-note {
  margin-top: 20px;
  font-size: .82rem;
  color: rgba(255,255,255,.5);
}

/* ── FOOTER ───────────────────────────────────────────────── */
.footer {
  background: var(--dark);
  padding: 72px 0 0;
  color: rgba(255,255,255,.55);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 56px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.footer-brand .nav-logo { margin-bottom: 16px; }
.footer-brand p { font-size: .88rem; line-height: 1.7; color: rgba(255,255,255,.45); max-width: 260px; }
.footer-brand .logo-text { color: #fff; }
.footer-brand .logo-text span { color: #a78bfa; }

.footer-col h4 {
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: rgba(255,255,255,.35);
  margin-bottom: 16px;
}

.footer-links { display: flex; flex-direction: column; gap: 10px; }
.footer-links a {
  font-size: .88rem;
  color: rgba(255,255,255,.55);
  transition: var(--transition);
}
.footer-links a:hover { color: #a78bfa; }

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
  font-size: .8rem;
  flex-wrap: wrap;
  gap: 8px;
}
.footer-flag { color: rgba(255,255,255,.3); }

/* ── DATA-REVEAL ANIMATION ───────────────────────────────── */
[data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .5s ease, transform .5s ease;
}
[data-reveal].visible {
  opacity: 1;
  transform: none;
}

/* ── UTILITY ──────────────────────────────────────────────── */
.text-center  { text-align: center; }
.text-purple  { color: var(--purple); }
.text-blue    { color: var(--blue); }
.text-white   { color: #fff; }
.mb-8   { margin-bottom: 8px; }
.mb-16  { margin-bottom: 16px; }
.mb-24  { margin-bottom: 24px; }
.mt-16  { margin-top: 16px; }
.mt-32  { margin-top: 32px; }

/* ── RESPONSIVE ───────────────────────────────────────────── */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px; }
}

@media (max-width: 768px) {
  .section    { padding: 64px 0; }
  .section-sm { padding: 48px 0; }
  .section-header { margin-bottom: 40px; }

  .nav-links, .nav-cta { display: none; }
  .hamburger { display: flex; }

  .hero { padding: 64px 0 56px; }
  .hero-actions { flex-direction: column; align-items: flex-start; }

  .stats-inner { justify-content: flex-start; }
  .stat-item { border-right: none; border-bottom: 1px solid var(--border); }
  .stat-item:last-child { border-bottom: none; }

  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer-brand { grid-column: 1 / -1; }

  .cta-actions { flex-direction: column; align-items: center; }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .footer-grid { grid-template-columns: 1fr; }
}
