/* ============================================================
   DESIGN TOKENS (identiques aux frontends IA-INSIGHT)
   ============================================================ */
:root {
  --bg:         #0d1017;
  --card:       #111725;
  --card-2:     #141c2b;
  --accent:     #2ce5a7;
  --accent-2:   #7ad7ff;
  --accent-rgb: 44, 229, 167;
  --text:       #ecf1ff;
  --muted:      #a8b3c6;
  --border:     #1f2a3f;
  --shadow:     0 20px 50px rgba(0, 0, 0, 0.35);
  --radius:     16px;
  --radius-sm:  10px;
  --font:       'Space Grotesk', system-ui, -apple-system, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  background:
    radial-gradient(circle at 18% 18%, rgba(44,229,167,.13), transparent 34%),
    radial-gradient(circle at 82% 4%,  rgba(122,215,255,.11), transparent 30%),
    var(--bg);
  color: var(--text);
  min-height: 100vh;
  font-size: 15px;
  line-height: 1.6;
}

a { color: var(--accent-2); text-decoration: none; }

.eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 8px;
}

.grad {
  background: linear-gradient(135deg, var(--accent) 20%, var(--accent-2) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(13,16,23,.82);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.nav-logo {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: .04em;
  color: var(--text);
  white-space: nowrap;
}
.logo-img    { width: 32px; height: 32px; display: block; }
.logo-accent { color: var(--accent); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 26px;
}
.nav-links > a:not(.nav-cta) {
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
  transition: color .15s;
}
.nav-links > a:not(.nav-cta):hover { color: var(--accent); }
.nav-cta { padding: 9px 16px; font-size: 13px; }

.nav-phone {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent) !important;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  transition: opacity .15s;
}
.nav-phone:hover { opacity: .8; }

.nav-burger {
  display: none;
  background: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-size: 18px;
  padding: 6px 12px;
  cursor: pointer;
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  overflow: hidden;
  padding: 96px 20px 72px;
  text-align: center;
}
.hero-inner { max-width: 860px; margin: 0 auto; position: relative; z-index: 1; }
.hero h1 {
  font-size: clamp(32px, 5.5vw, 54px);
  font-weight: 700;
  line-height: 1.12;
  margin: 0 0 20px;
}
.hero-lede {
  font-size: 17px;
  color: var(--muted);
  max-width: 640px;
  margin: 0 auto 32px;
}
.hero-glow {
  position: absolute;
  inset: auto 0 -240px 0;
  height: 420px;
  background: radial-gradient(ellipse at 50% 100%, rgba(44,229,167,.14), transparent 60%);
  pointer-events: none;
}
.hero-cta {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 52px;
}
.hero-stats {
  display: flex;
  justify-content: center;
  gap: 48px;
  flex-wrap: wrap;
}
.stat { display: flex; flex-direction: column; gap: 2px; }
.stat-num {
  font-size: 30px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--text) 30%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.stat-label { font-size: 12.5px; color: var(--muted); max-width: 180px; }

/* ============================================================
   SECTIONS
   ============================================================ */
.section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 72px 20px;
}
.section-alt {
  max-width: none;
  background: rgba(255,255,255,.015);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.section-alt > * { max-width: 1100px; margin-left: auto; margin-right: auto; }

.section-head { text-align: center; max-width: 680px; margin: 0 auto 44px; }
.section-head h2 {
  font-size: clamp(26px, 3.6vw, 36px);
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 12px;
}
.section-lede { color: var(--muted); font-size: 15.5px; margin: 0; }

/* ============================================================
   GRIDS & CARDS
   ============================================================ */
.grid { display: grid; gap: 20px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: 0 4px 20px rgba(0,0,0,.2);
  transition: transform .2s, border-color .2s;
}
.card h3 { font-size: 18px; font-weight: 600; margin: 0 0 8px; }
.card p  { font-size: 13.5px; color: var(--muted); margin: 0 0 14px; }
.card p.eyebrow {
  font-size: 11px;
  color: var(--accent);
  margin: 0 0 8px;
}

.feature:hover, .service:hover { transform: translateY(-3px); border-color: rgba(44,229,167,.35); }
.feature-icon { font-size: 26px; margin-bottom: 12px; }

.pill {
  display: inline-block;
  font-size: 11.5px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
}
.pill.green {
  background: rgba(44,229,167,.12);
  color: var(--accent);
  border: 1px solid rgba(44,229,167,.25);
}
.pill-sm { font-size: 10.5px; padding: 2px 8px; }

/* Steps */
.step-num {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .1em;
  color: var(--accent);
  display: block;
  margin-bottom: 10px;
}

/* ============================================================
   PILOTAGE / DASHBOARD
   ============================================================ */
.dash-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}
.dash-copy h2 {
  font-size: clamp(26px, 3.6vw, 36px);
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 12px;
}
.dash-copy .section-lede { margin-bottom: 20px; }
.dash-copy .checklist { margin-bottom: 26px; }
.dash-copy .checklist li { border-bottom: none; padding: 5px 0 5px 24px; }

.dash-mock {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.mock-kpi {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  box-shadow: 0 4px 20px rgba(0,0,0,.2);
}
.mock-accent {
  border-color: rgba(44,229,167,.4);
  box-shadow: 0 0 0 1px rgba(44,229,167,.2), 0 8px 30px rgba(44,229,167,.06);
}
.mock-eyebrow {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
}
.mock-big {
  font-size: 28px;
  font-weight: 700;
  color: var(--text);
}
.mock-big small { font-size: 13px; font-weight: 500; color: var(--muted); }
.mock-green { color: var(--accent); }
.mock-sub { font-size: 12px; color: var(--muted); }

.mock-alert {
  grid-column: 1 / -1;
  background: rgba(251,191,36,.08);
  border: 1px solid rgba(251,191,36,.25);
  border-radius: var(--radius-sm);
  color: #fcd34d;
  font-size: 13px;
  font-weight: 600;
  padding: 10px 16px;
}

@media (max-width: 900px) {
  .dash-split { grid-template-columns: 1fr; gap: 32px; }
}

/* ============================================================
   TARIFS
   ============================================================ */
.billing-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 24px;
}
.toggle-label { font-size: 14px; color: var(--muted); font-weight: 600; transition: color .15s; }
.toggle-label.active { color: var(--text); }

.switch {
  width: 46px;
  height: 24px;
  border-radius: 999px;
  border: 1px solid rgba(44,229,167,.4);
  background: rgba(44,229,167,.1);
  cursor: pointer;
  position: relative;
  padding: 0;
}
.switch .knob {
  position: absolute;
  top: 2px; left: 3px;
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--accent);
  transition: left .18s;
}
.switch[aria-checked="true"] .knob { left: 24px; }

.price-card { position: relative; display: flex; flex-direction: column; }
.price-card.featured {
  border-color: rgba(44,229,167,.5);
  box-shadow: 0 0 0 1px rgba(44,229,167,.3), 0 12px 40px rgba(44,229,167,.08);
  transform: scale(1.02);
}
.ribbon {
  position: absolute;
  top: -12px; left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #0d1017;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  padding: 4px 14px;
  border-radius: 999px;
  white-space: nowrap;
}
.card p.price { font-size: 38px; font-weight: 700; color: var(--text); margin: 6px 0 4px; }
.price-unit { font-size: 13px; font-weight: 500; color: var(--muted); }
.price-custom { font-size: 30px; }

.checklist {
  list-style: none;
  padding: 0;
  margin: 0 0 22px;
  flex: 1;
}
.checklist li {
  font-size: 13.5px;
  color: var(--muted);
  padding: 6px 0 6px 24px;
  position: relative;
  border-bottom: 1px solid rgba(255,255,255,.04);
}
.checklist li::before {
  content: '✓';
  position: absolute;
  left: 2px;
  color: var(--accent);
  font-weight: 700;
}
.checklist.compact li { border-bottom: none; padding: 3px 0 3px 24px; }

.pricing-note {
  text-align: center;
  font-size: 13px;
  color: var(--muted);
  margin-top: 28px;
}

.service-price { font-size: 14px; color: var(--muted); margin: 4px 0 16px; }
.service-price strong { color: var(--accent); font-size: 17px; }

/* ============================================================
   TRUST
   ============================================================ */
.trust-item h4 { font-size: 15px; margin: 0 0 8px; }
.trust-item p  { font-size: 12.5px; margin: 0; }

/* ============================================================
   FAQ
   ============================================================ */
.faq-list { max-width: 760px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.faq-item summary {
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  position: relative;
  padding-right: 28px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+';
  position: absolute;
  right: 0; top: 0;
  color: var(--accent);
  font-size: 20px;
  font-weight: 400;
  transition: transform .18s;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item p { margin: 12px 0 0; }

/* ============================================================
   BOUTONS
   ============================================================ */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 11px 20px;
  border-radius: 12px;
  border: none;
  background: linear-gradient(135deg, rgba(44,229,167,.25), rgba(44,229,167,.15));
  color: var(--accent);
  font: 600 14px var(--font);
  cursor: pointer;
  box-shadow: 0 0 0 1px rgba(44,229,167,.3);
  transition: box-shadow .15s, transform .1s;
}
.btn-primary:hover { box-shadow: 0 0 0 1px rgba(44,229,167,.6), 0 4px 16px rgba(44,229,167,.15); transform: translateY(-1px); }

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 11px 20px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.03);
  color: var(--text);
  font: 600 14px var(--font);
  cursor: pointer;
  transition: border-color .15s, transform .1s;
}
.btn-secondary:hover { border-color: rgba(44,229,167,.4); transform: translateY(-1px); }

.btn-lg    { padding: 14px 26px; font-size: 15px; }
.btn-block { width: 100%; justify-content: center; }

/* ============================================================
   CTA FINAL
   ============================================================ */
.cta-final { padding-bottom: 96px; }
.cta-card {
  text-align: center;
  padding: 56px 32px;
  background:
    radial-gradient(circle at 50% 0%, rgba(44,229,167,.1), transparent 55%),
    var(--card);
  border-color: rgba(44,229,167,.3);
}
.cta-card h2 { font-size: clamp(24px, 3.4vw, 34px); margin: 0 0 14px; line-height: 1.25; }
.cta-card .section-lede { margin-bottom: 30px; }
.cta-card .hero-cta { margin-bottom: 36px; }

.contact-strip {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}
.contact-chip {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255,255,255,.03);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 18px;
  text-align: left;
  transition: border-color .15s, transform .1s;
}
.contact-chip:hover { border-color: rgba(44,229,167,.45); transform: translateY(-1px); }
.contact-icon { font-size: 20px; }
.contact-info { display: flex; flex-direction: column; gap: 1px; }
.contact-value { font-size: 14.5px; font-weight: 700; color: var(--text); }
.contact-hint  { font-size: 11.5px; color: var(--muted); }

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  border-top: 1px solid var(--border);
  padding: 48px 20px 28px;
}
.footer-inner {
  max-width: 1100px;
  margin: 0 auto 32px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
}
.footer-brand p { font-size: 13px; color: var(--muted); margin: 12px 0 0; max-width: 280px; }
.footer-col { display: flex; flex-direction: column; gap: 8px; }
.footer-col h5 {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 4px;
}
.footer-col a { font-size: 13.5px; color: var(--muted); transition: color .15s; }
.footer-col a:hover { color: var(--accent); }
.footer-legal { text-align: center; font-size: 12px; color: rgba(168,179,198,.5); margin: 0; }

/* ============================================================
   CHATBOT
   ============================================================ */
#chat-widget { position: fixed; bottom: 22px; right: 22px; z-index: 100; }

#chat-toggle {
  position: relative;
  width: 56px; height: 56px;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #0d1017;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 30px rgba(44,229,167,.35);
  transition: transform .15s, box-shadow .15s;
}
#chat-toggle:hover { transform: translateY(-2px) scale(1.04); box-shadow: 0 12px 36px rgba(44,229,167,.45); }

.chat-badge {
  position: absolute; top: -2px; right: -2px;
  background: #f87171; color: #fff;
  font: 700 11px var(--font);
  width: 18px; height: 18px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}

.chat-panel {
  position: absolute;
  bottom: 70px; right: 0;
  width: 360px;
  max-width: calc(100vw - 44px);
  height: 480px;
  max-height: calc(100vh - 120px);
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  display: flex; flex-direction: column;
  overflow: hidden;
}
.chat-panel.hidden { display: none; }

.chat-header {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  background: var(--card-2);
}
.chat-title  { font-size: 14px; font-weight: 700; margin: 0; }
.chat-status { font-size: 11px; color: var(--muted); margin: 1px 0 0; display: flex; align-items: center; gap: 5px; }
.chat-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 6px rgba(44,229,167,.8);
}
#chat-close {
  margin-left: auto;
  background: none; border: none;
  color: var(--muted); font-size: 15px;
  cursor: pointer; padding: 4px 8px;
  border-radius: 6px;
  transition: color .15s;
}
#chat-close:hover { color: var(--text); }

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex; flex-direction: column; gap: 10px;
}
.chat-msg {
  max-width: 85%;
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 13.5px;
  line-height: 1.5;
}
.chat-msg.bot {
  align-self: flex-start;
  background: rgba(255,255,255,.05);
  border: 1px solid var(--border);
  border-bottom-left-radius: 4px;
  color: var(--text);
}
.chat-msg.bot a { color: var(--accent); font-weight: 600; }
.chat-msg.user {
  align-self: flex-end;
  background: linear-gradient(135deg, rgba(44,229,167,.25), rgba(44,229,167,.15));
  box-shadow: 0 0 0 1px rgba(44,229,167,.3);
  border-bottom-right-radius: 4px;
  color: var(--text);
}

.chat-typing { display: inline-flex; gap: 4px; padding: 2px 0; }
.chat-typing i {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--muted);
  animation: chat-bounce 1s infinite;
}
.chat-typing i:nth-child(2) { animation-delay: .15s; }
.chat-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes chat-bounce { 0%, 60%, 100% { transform: none; } 30% { transform: translateY(-4px); } }

.chat-quick {
  display: flex; flex-wrap: wrap; gap: 6px;
  padding: 0 16px 10px;
}
.chat-chip {
  background: rgba(44,229,167,.08);
  border: 1px solid rgba(44,229,167,.3);
  border-radius: 999px;
  color: var(--accent);
  font: 600 12px var(--font);
  padding: 6px 12px;
  cursor: pointer;
  transition: background .15s;
}
.chat-chip:hover { background: rgba(44,229,167,.16); }

.chat-form {
  display: flex; gap: 8px;
  padding: 12px 14px;
  border-top: 1px solid var(--border);
  background: var(--card-2);
}
.chat-form input {
  flex: 1;
  background: rgba(255,255,255,.04);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font: 13.5px var(--font);
  padding: 9px 12px;
}
.chat-form input:focus { outline: none; border-color: rgba(44,229,167,.4); }
.chat-form button {
  background: linear-gradient(135deg, rgba(44,229,167,.25), rgba(44,229,167,.15));
  box-shadow: 0 0 0 1px rgba(44,229,167,.3);
  border: none; border-radius: 10px;
  color: var(--accent);
  padding: 0 14px;
  cursor: pointer;
}

@media (max-width: 540px) {
  #chat-widget { bottom: 16px; right: 16px; }
  .chat-panel { height: 70vh; }
}

/* ============================================================
   REVEAL ON SCROLL
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .6s ease, transform .6s ease;
}
.reveal.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 900px) {
  .grid-3 { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .price-card.featured { transform: none; }
  .footer-inner { grid-template-columns: 1fr 1fr; }

  .nav-burger { display: block; }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    flex-direction: column;
    align-items: flex-start;
    background: rgba(13,16,23,.97);
    border-bottom: 1px solid var(--border);
    padding: 16px 20px 20px;
    gap: 16px;
  }
  .nav-links.open { display: flex; }
}

@media (max-width: 540px) {
  .grid-4 { grid-template-columns: 1fr; }
  .hero { padding-top: 64px; }
  .hero-stats { gap: 28px; }
  .footer-inner { grid-template-columns: 1fr; }
}
