/* ============================================================
   KAROOKA - Main Stylesheet
   ============================================================ */

/* ===== CSS VARIABLES ===== */
:root {
  /* Surfaces */
  --bg: #f8f8f6;
  --white: #ffffff;
  --black: #080808;

  /* Accents de marque */
  --indigo: #5b5ef4;
  --indigo-light: #818cf8;
  --cyan: #06b6d4;
  --green: #10b981;
  --red: #f43f5e;
  --amber: #f59e0b;
  --orange: #fb923c;

  /* Nuances de gris */
  --gray-100: #f1f1ef;
  --gray-200: #e4e4e0;
  --gray-300: #c9c9c4;
  --gray-400: #a0a09a;
  --gray-600: #6b6b65;
  --gray-800: #222220;

  /* Teintes : fonds de badges, surfaces colorees */
  --indigo-50: #f5f3ff;
  --indigo-100: #ede9fe;
  --cyan-50: #e0f2fe;
  --cyan-200: #7dd3fc;
  --green-50: #f0fdf4;
  --green-100: #dcfce7;
  --green-400: #34d399;
  --green-600: #16a34a;
  --green-700: #166534;
  --amber-50: #fffbeb;
  --amber-100: #fef3c7;
  --amber-600: #d97706;

  --radius: 16px;
  --radius-lg: 24px;
  --shadow: 0 4px 24px rgba(0,0,0,.06);
  --shadow-lg: 0 16px 48px rgba(0,0,0,.12);
  --transition: .25s cubic-bezier(.4, 0, .2, 1);
  --section-pad-v: clamp(3.5rem, 8vh, 7rem);
  --section-pad-h: clamp(1.5rem, 5vw, 5rem);
}

/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg);
  color: var(--black);
  line-height: 1.6;
  overflow-x: hidden;
}

/* ===== TYPOGRAPHY ===== */
h1, h2 { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800; line-height: 1.08; letter-spacing: -0.04em; }
h3, h4 { font-family: 'DM Sans', sans-serif; font-weight: 800; line-height: 1.1; letter-spacing: -0.03em; }
h1 { font-size: clamp(2.6rem, 7vw, 6.5rem); }
h2 { font-size: clamp(1.8rem, 4.5vw, 3.5rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.4rem); font-weight: 700; }
p { color: var(--gray-600); font-size: clamp(.92rem, 1.5vw, 1.05rem); }
a { text-decoration: none; color: inherit; }

/* ===== LAYOUT ===== */
section { padding: var(--section-pad-v) var(--section-pad-h); }
.container { max-width: 1100px; margin: 0 auto; }
.text-center { text-align: center; }
.text-center .section-sub { margin-left: auto; margin-right: auto; }
.text-center .section-tag { justify-content: center; }

/* ===== SECTION LABELS ===== */
.section-tag {
  display: inline-flex; align-items: center; gap: .4rem;
  font-size: .75rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
  color: var(--indigo); margin-bottom: clamp(1rem, 2vh, 1.5rem);
}
.section-tag::before {
  content: ''; width: 20px; height: 2px;
  background: var(--indigo); border-radius: 10px;
}
.section-title { margin-bottom: clamp(.6rem, 1.5vh, 1rem); }
.section-sub { max-width: 540px; margin-bottom: clamp(2rem, 5vh, 3.5rem); }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .65rem 1.5rem;
  border-radius: 100px; font-weight: 700; font-size: .9rem;
  cursor: pointer; transition: all var(--transition); border: none;
}
.btn-ghost { background: transparent; color: var(--gray-600); }
.btn-ghost:hover { color: var(--black); }
.btn-primary { background: var(--black); color: var(--white); box-shadow: 0 2px 12px rgba(0,0,0,.2); }
.btn-primary:hover { background: var(--gray-800); transform: translateY(-1px); box-shadow: 0 6px 20px rgba(0,0,0,.25); }
.btn-indigo { background: var(--indigo); color: var(--white); box-shadow: 0 2px 16px rgba(91,94,244,.35); }
.btn-indigo:hover { background: #4a4dd9; transform: translateY(-2px); box-shadow: 0 8px 32px rgba(91,94,244,.45); }
.btn-white { background: var(--white); color: var(--black); font-weight: 700; }
.btn-white:hover { background: var(--gray-100); }
.btn-outline { background: transparent; color: var(--black); border: 2px solid var(--gray-200); font-weight: 700; }
.btn-outline:hover { border-color: var(--black); }
.btn-lg { padding: .85rem 2rem; font-size: clamp(.88rem, 1.5vw, 1rem); }
.w-full { width: 100%; justify-content: center; }

/* ===== NAVBAR ===== */
nav#navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem clamp(1.5rem, 4vw, 4rem);
  background: rgba(248,248,246,.88);
  backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid var(--gray-200);
  /* Smart scroll: slides up/down */
  transform: translateY(0);
  transition: transform .4s cubic-bezier(.4,0,.2,1),
              box-shadow .3s ease,
              background .3s ease;
}
nav#navbar.nav-hidden {
  transform: translateY(-110%);
}
nav#navbar.nav-scrolled {
  background: rgba(248,248,246,.97);
  box-shadow: 0 2px 24px rgba(0,0,0,.07);
}
.nav-logo {
  font-size: 1.4rem; font-weight: 900; letter-spacing: -0.04em;
  color: var(--black); display: flex; align-items: center; gap: .5rem;
}
.nav-logo span { color: var(--indigo); }
.nav-logo svg { width: 30px; height: 30px; }
.nav-links { display: flex; align-items: center; gap: 2rem; }
.nav-links a {
  font-size: .88rem; font-weight: 600; color: var(--gray-600);
  transition: color .2s; position: relative; padding-bottom: 3px;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: -2px; left: 0;
  width: 0; height: 2px; background: var(--indigo); border-radius: 2px;
  transition: width .25s ease;
}
.nav-links a:hover { color: var(--black); }
.nav-links a:hover::after,
.nav-links a.active::after { width: 100%; }
.nav-links a.active { color: var(--black); font-weight: 700; }
.nav-cta { display: flex; align-items: center; gap: .75rem; }


/* ===== HERO ===== */
#hero {
  min-height: 100svh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center;
  padding: clamp(5rem, 12vh, 9rem) clamp(1.5rem, 5vw, 4rem) clamp(3rem, 6vh, 5rem);
  position: relative; overflow: hidden;
}
.hero-grid {
  position: absolute; inset: 0; z-index: -1;
  background-image:
    linear-gradient(var(--gray-200) 1px, transparent 1px),
    linear-gradient(90deg, var(--gray-200) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 50%, black 30%, transparent 100%);
  opacity: .4;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: .5rem;
  background: var(--white); border: 1px solid var(--gray-200);
  padding: .35rem .9rem; border-radius: 100px;
  font-size: .78rem; font-weight: 700; color: var(--indigo);
  margin-bottom: clamp(1.2rem, 3vh, 2rem);
  box-shadow: 0 2px 12px rgba(0,0,0,.05);
  opacity: 0; animation: fadeUp .6s .2s ease forwards;
}
.hero-badge span { color: var(--gray-400); font-weight: 500; }
.badge-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--green); animation: pulse 2s infinite;
}
.hero-title {
  max-width: min(900px, 90vw);
  /* Portee LOCALE : le h1 passe de 3 a 2 lignes, on compense la masse perdue.
     La regle h1 globale reste inchangee, elle sert toutes les autres pages. */
  font-size: clamp(3rem, 7.5vw, 7rem);
  /* Aucun delai : le h1 est l element LCP, Chrome ignore les elements a opacite nulle. */
  opacity: 0; animation: fadeUp .7s ease forwards;
  margin-bottom: clamp(.8rem, 2vh, 1.5rem);
}

/* ===== MOT ROTATIF DU H1 =====
   Trois couches superposees :
   - le GABARIT, invisible, en flux, qui fixe seul la largeur ;
   - le MOT CANONIQUE, hors flux, vrai noeud de texte (SEO, lecteurs d ecran, sans-JS) ;
   - la COUCHE PEINTE, hors flux, seule chose animee. */
.rot {
  position: relative; display: inline-block; color: var(--indigo);
  contain: layout style;   /* jamais `paint` : le translateY sortant serait rogne net */
}

/* GABARIT INVISIBLE. Il porte le mot le PLUS LARGE de la serie et fixe SEUL la largeur du
   slot. C est ce qui libere le choix editorial du mot canonique : il n a plus besoin d etre
   le plus large. Rendu via un pseudo-element, donc invisible aux robots ; visibility:hidden
   le retire de l arbre d accessibilite. Il suit automatiquement le clamp et l axe optique de
   la police variable : aucune constante en pixels a maintenir.
   REGLE : --rot-sizer vaut le mot le plus large AU RENDU, jamais le plus long en signes.
   Mesure a 60px : "marge" 5 signes = 168px, "performance" 11 signes = 344px. */
.rot__sizer { visibility: hidden; white-space: nowrap; }
.rot__sizer::before { content: var(--rot-sizer); }

/* Les deux couches se superposent au gabarit et se centrent dessus : un mot plus court que
   le gabarit reste centre, la ligne ne bouge donc jamais. */
.rot__word, .rot__paint { position: absolute; inset: 0; place-items: center; }

/* Mot canonique : hors flux, mais VRAI noeud de texte. C est lui que lisent les robots et
   les lecteurs d ecran, et lui qui s affiche sans JS ou en mouvement reduit. */
.rot__word { display: grid; }
/* opacity uniquement : visibility ou display le sortiraient de l arbre d accessibilite */
.rot.is-live .rot__word { opacity: 0; }

/* Couche peinte : mot + souligne solidaires. Seule chose reellement animee. */
.rot__paint {
  display: none;
  user-select: none; pointer-events: none;
  transition: opacity 220ms cubic-bezier(0,0,.2,1), transform 220ms cubic-bezier(0,0,.2,1);
}
.rot.is-live .rot__paint { display: grid; }

.rot__word i, .rot__paint i {
  font-style: normal; position: relative; display: inline-block; white-space: nowrap;
  /* margin-right negatif : annule la chasse fantome laissee a droite par letter-spacing
     -0.04em, sinon le trait degrade parait systematiquement quelques pixels trop long. */
  margin-right: -.04em;
}
.rot__paint i::before { content: var(--rot-word); }

/* Souligne degrade : porte par le MOT, jamais par le gabarit. Il se fond et se translate
   AVEC son mot, donc le changement de largeur se produit a opacite nulle, invisible. */
.rot__word i::after, .rot__paint i::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -.06em;
  height: .075em; border-radius: 10px; opacity: .5;
  background: linear-gradient(90deg, var(--indigo), var(--cyan));
}

/* Deplacement en em et non en px : l amplitude suit le clamp du titre. */
.rot.is-out .rot__paint {
  opacity: 0; transform: translateY(-.12em);
  transition-duration: 180ms; transition-timing-function: cubic-bezier(.4,0,1,1);
}
.rot__paint.is-enter { opacity: 0; transform: translateY(.12em); transition: none; }

/* Bouton pause, obligatoire au-dela de 5s d animation automatique (WCAG 2.2.2).
   visibility et non l attribut [hidden] : la place reste reservee, donc aucun saut
   de mise en page ni a l apparition ni au gel. */
.rot-pause {
  visibility: hidden;
  min-width: 24px; min-height: 24px; padding: 6px;   /* cible >= 24px (WCAG 2.5.8) */
  border: 0; background: none; color: var(--gray-400);
  opacity: .4; cursor: pointer; line-height: 0;
  transition: opacity var(--transition);
}
.rot-pause.is-available { visibility: visible; }
.rot-pause:hover, .rot-pause:focus-visible { opacity: 1; }
.rot-pause svg { fill: currentColor; }

.sr-only {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0;
}
.hero-sub {
  max-width: min(580px, 90vw);
  font-size: clamp(1rem, 2vw, 1.2rem); color: var(--gray-600);
  opacity: 0; animation: fadeUp .7s .5s ease forwards;
  margin-bottom: clamp(1.5rem, 4vh, 2.5rem);
}
.hero-actions {
  display: flex; gap: .75rem; justify-content: center; flex-wrap: wrap;
  opacity: 0; animation: fadeUp .7s .65s ease forwards;
  margin-bottom: clamp(2rem, 5vh, 4rem);
}
.hero-trust {
  display: flex; align-items: center; gap: .75rem;
  font-size: .8rem; color: var(--gray-400); font-weight: 600;
  opacity: 0; animation: fadeUp .7s .8s ease forwards;
}
.hero-trust .avatars { display: flex; }
.hero-trust .avatar {
  width: 26px; height: 26px; border-radius: 50%;
  border: 2px solid var(--white); margin-left: -8px;
  background: linear-gradient(135deg, var(--indigo-light), var(--cyan));
  font-size: 9px; color: white; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}
.hero-trust .avatar:first-child { margin-left: 0; }

/* Floating cards */
.hero-cards { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.float-card {
  position: absolute; background: var(--white);
  border: 1px solid var(--gray-200); border-radius: var(--radius);
  padding: .8rem 1.2rem; box-shadow: var(--shadow);
  font-size: .8rem; font-weight: 600;
  display: flex; align-items: center; gap: .6rem;
  animation: floatAnim 6s ease-in-out infinite;
  opacity: 0; transition: opacity .5s;
}
.float-card.visible { opacity: 1; }
.float-card .icon {
  width: 26px; height: 26px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center; font-size: 13px;
}
.card-1 { top: 18%; left: 5%; animation-delay: 0s; }
.card-2 { top: 20%; right: 5%; animation-delay: 1s; }
.card-3 { bottom: 20%; left: 6%; animation-delay: 2s; }
.card-4 { bottom: 18%; right: 6%; animation-delay: 1.5s; }
.metric-up { color: var(--green); }
.metric-down { color: var(--red); }

@media (max-width: 768px) {
  .float-card { display: none; }
}

/* ===== DASHBOARD PREVIEW ===== */
.dashboard-wrap {
  width: 100%; max-width: 1100px; margin: 0 auto;
  padding: 0 clamp(1rem, 4vw, 2rem) clamp(4rem, 8vh, 8rem);
  opacity: 0; animation: fadeUp .9s 1s ease forwards;
}
.dashboard {
  background: var(--white); border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); overflow: hidden;
}
.dash-bar {
  background: var(--gray-100); padding: .7rem 1.2rem;
  display: flex; align-items: center; gap: .5rem;
  border-bottom: 1px solid var(--gray-200);
}
.dash-dot { width: 10px; height: 10px; border-radius: 50%; }
.dash-dot.r { background: #ff5f57; }
.dash-dot.y { background: #febc2e; }
.dash-dot.g { background: #28c840; }
.dash-url {
  flex: 1; background: var(--white); border-radius: 6px;
  padding: .25rem 1rem; font-size: .75rem; color: var(--gray-400); margin-left: .8rem;
}
.dash-content { display: grid; grid-template-columns: 200px 1fr; min-height: clamp(280px, 45vh, 400px); }
.dash-sidebar {
  background: var(--gray-100); border-right: 1px solid var(--gray-200);
  padding: 1.2rem 1rem;
}
.dash-nav-item {
  display: flex; align-items: center; gap: .7rem;
  padding: .5rem .8rem; border-radius: 8px;
  font-size: .8rem; font-weight: 600; color: var(--gray-600);
  margin-bottom: .2rem; cursor: pointer;
  transition: all var(--transition); user-select: none;
}
.dash-nav-item:hover { background: rgba(91,94,244,.08); color: var(--indigo); }
.dash-nav-item.active { background: var(--white); color: var(--black); box-shadow: 0 1px 4px rgba(0,0,0,.06); }
.dash-nav-item.active svg { stroke: var(--indigo); }
.dash-nav-item svg { width: 15px; height: 15px; transition: stroke .2s; }

.dash-main { padding: 1.2rem; position: relative; overflow: hidden; }
.dash-view { display: none; flex-direction: column; gap: .8rem; }
.dash-view.active { display: flex; animation: viewIn .3s ease; }
@keyframes viewIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

.dash-kpi-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: .8rem; }
.kpi-card {
  background: var(--gray-100); border-radius: 10px;
  padding: clamp(.7rem, 1.5vh, 1rem);
  border: 1px solid var(--gray-200); cursor: pointer;
  transition: all var(--transition);
}
.kpi-card:hover { border-color: var(--indigo-light); box-shadow: 0 4px 16px rgba(91,94,244,.1); transform: translateY(-2px); }
.kpi-label { font-size: .65rem; font-weight: 700; color: var(--gray-400); text-transform: uppercase; letter-spacing: .05em; margin-bottom: .25rem; }
.kpi-value { font-size: clamp(1.1rem, 2vw, 1.4rem); font-weight: 800; letter-spacing: -.03em; }
.kpi-change { font-size: .68rem; font-weight: 700; margin-top: .2rem; }
.kpi-change.up { color: var(--green); }
.kpi-change.down { color: var(--red); }
.dash-chart-row { display: grid; grid-template-columns: 2fr 1fr; gap: .8rem; flex: 1; }
.chart-box {
  background: var(--gray-100); border-radius: 10px;
  padding: clamp(.7rem, 1.5vh, 1rem);
  border: 1px solid var(--gray-200); min-height: clamp(120px, 20vh, 160px);
  position: relative; overflow: hidden;
}
.chart-title { font-size: .72rem; font-weight: 700; color: var(--gray-600); margin-bottom: .4rem; }
.chart-bar-wrap { display: flex; align-items: flex-end; gap: 5px; height: clamp(55px, 10vh, 80px); padding: 0 .3rem; }
.chart-bar {
  flex: 1; border-radius: 4px 4px 0 0;
  background: linear-gradient(to top, var(--indigo), var(--indigo-light));
  transition: height .4s cubic-bezier(.4,0,.2,1), opacity .3s;
}
.chart-bar.forecast { background: transparent; border: 2px dashed rgba(6,182,212,.5); }
.ai-badge {
  position: absolute; top: .7rem; right: .7rem;
  background: linear-gradient(135deg, var(--indigo), var(--cyan));
  color: white; font-size: .62rem; font-weight: 800;
  padding: .18rem .55rem; border-radius: 100px;
}
.progress-bar-wrap { background: var(--gray-200); border-radius: 100px; height: 5px; overflow: hidden; margin-top: .2rem; }
.progress-bar {
  height: 100%; border-radius: 100px;
  background: linear-gradient(90deg, var(--indigo), var(--cyan));
  width: 0; transition: width 1.5s cubic-bezier(.4,0,.2,1);
}
.analytics-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }
.ai-view-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }
.ai-insight-card {
  background: linear-gradient(135deg, var(--indigo-50), var(--cyan-50));
  border: 1px solid #c4b5fd; border-radius: 10px;
  padding: clamp(.7rem, 1.5vh, 1rem);
  cursor: pointer; transition: all var(--transition);
}
.ai-insight-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(91,94,244,.15); }
.ai-insight-card h4 { font-size: .82rem; font-weight: 800; color: var(--black); margin-bottom: .25rem; }
.ai-insight-card p { font-size: .72rem; color: var(--gray-600); }
.ai-score { font-size: 1.6rem; font-weight: 900; letter-spacing: -.04em; color: var(--indigo); margin: .25rem 0; }
.ai-tag {
  display: inline-block; font-size: .62rem; font-weight: 800; text-transform: uppercase;
  letter-spacing: .06em; padding: .12rem .45rem; border-radius: 100px;
  background: var(--indigo); color: white; margin-bottom: .4rem;
}
.ai-tag.warning { background: var(--amber); }
.ai-tag.success { background: var(--green); }
.report-list { display: flex; flex-direction: column; gap: .5rem; }
.report-item {
  display: flex; align-items: center; gap: .7rem;
  background: var(--gray-100); border: 1px solid var(--gray-200);
  border-radius: 10px; padding: .65rem .9rem; cursor: pointer;
  transition: all var(--transition);
}
.report-item:hover { border-color: var(--indigo-light); background: var(--indigo-50); }
.report-icon { width: 32px; height: 32px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 14px; flex-shrink: 0; }
.report-info { flex: 1; }
.report-name { font-size: .8rem; font-weight: 700; color: var(--black); }
.report-meta { font-size: .68rem; color: var(--gray-400); font-weight: 600; }
.report-status { font-size: .67rem; font-weight: 800; padding: .18rem .55rem; border-radius: 100px; background: #dcfce7; color: #16a34a; }
.report-status.pending { background: #fef3c7; color: #d97706; }
.report-btn { font-size: .72rem; font-weight: 700; color: var(--indigo); background: none; border: none; cursor: pointer; padding: .3rem .6rem; border-radius: 6px; transition: background .2s; }
.report-btn:hover { background: #ede9fe; }
.int-view-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; }
.int-card {
  display: flex; flex-direction: column; align-items: center; gap: .3rem;
  background: var(--gray-100); border: 1px solid var(--gray-200);
  border-radius: 10px; padding: .65rem; cursor: pointer;
  transition: all var(--transition); text-align: center;
}
.int-card:hover { border-color: var(--indigo-light); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(91,94,244,.1); }
.int-card-dot { width: 8px; height: 8px; border-radius: 50%; }
.int-card-logo {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2px;
}
.int-card-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  transition: filter var(--transition), opacity var(--transition);
}
.int-card.inactive .int-card-logo img {
  filter: grayscale(1) opacity(0.4);
}
.int-card.inactive:hover .int-card-logo img {
  filter: grayscale(0) opacity(1);
}
.int-card-name { font-size: .72rem; font-weight: 700; color: var(--black); }
.int-card-status { font-size: .62rem; font-weight: 700; color: var(--green); }
.int-card-status.inactive { color: var(--gray-400); }
.int-add-btn {
  display: flex; align-items: center; justify-content: center;
  background: none; border: 2px dashed var(--gray-200);
  border-radius: 10px; padding: .65rem; cursor: pointer;
  font-size: .72rem; font-weight: 700; color: var(--gray-400);
  transition: all var(--transition); gap: .3rem;
}
.int-add-btn:hover { border-color: var(--indigo); color: var(--indigo); background: var(--indigo-50); }

/* ===== MARQUEE ===== */
.marquee-wrap {
  overflow: hidden; padding: 1.5rem 0;
  border-top: 1px solid var(--gray-200); border-bottom: 1px solid var(--gray-200);
}
.marquee-track { display: flex; gap: 3rem; animation: marquee 25s linear infinite; white-space: nowrap; }
.marquee-item {
  font-size: clamp(.85rem, 1.5vw, 1rem); font-weight: 800; letter-spacing: -.02em;
  color: var(--gray-400); display: flex; align-items: center; gap: 1rem; flex-shrink: 0;
}
.marquee-item .sep { color: var(--indigo); }

/* ===== STATS BAND ===== */
#stats {
  padding: clamp(2.5rem, 6vh, 5rem) var(--section-pad-h);
  background: var(--black); color: var(--white);
}
.stats-grid {
  max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 2rem; text-align: center;
}
.stat-num {
  font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 900; letter-spacing: -.04em;
  background: linear-gradient(135deg, #fff 40%, var(--indigo-light));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.stat-label { font-size: clamp(.75rem, 1.2vw, .88rem); color: rgba(255,255,255,.5); font-weight: 600; margin-top: .3rem; }

/* ===================================================
   FEATURES - STICKY HORIZONTAL CINEMATIC SCROLL
   =================================================== */
#features {
  position: relative;
  height: 600vh; /* tall container - scroll distance */
  background: var(--bg);
}

/* Sticky viewport that stays fixed during scroll */
.features-sticky {
  position: sticky;
  top: 0;
  height: 100svh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* Top label bar */
.features-header-bar {
  position: absolute;
  top: 0; left: 0; right: 0; z-index: 10;
  display: flex; align-items: flex-start; justify-content: space-between;
  padding: clamp(1rem, 3vh, 2.5rem) clamp(1.5rem, 5vw, 4rem);
  padding-top: calc(clamp(1rem, 3vh, 2.5rem) + 70px);
}
.features-label { display: flex; flex-direction: column; gap: .3rem; }
.features-label .section-tag { margin-bottom: 0; }
.features-label h2 { font-size: clamp(1.4rem, 3vw, 2.2rem); }

/* Counter pill */
.feat-counter {
  font-size: clamp(.85rem, 1.5vw, 1.1rem);
  font-weight: 900; letter-spacing: -.02em;
  color: var(--gray-400);
  display: flex; align-items: center; gap: .3rem;
}
.feat-counter-current {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 900; color: var(--black);
  line-height: 1; transition: color .4s;
}
.feat-counter-sep { margin: 0 .1rem; }
.feat-counter-total { font-size: clamp(1rem, 2vw, 1.5rem); }

/* Track that slides horizontally */
.features-track {
  display: flex;
  height: 100%;
  width: max-content;
  will-change: transform;
  transition: transform .05s linear;
}

/* Individual panel - each is one full viewport wide */
.feat-panel {
  width: 100vw;
  height: 100svh;
  display: flex;
  align-items: center;
  padding: clamp(1rem, 3vw, 4rem);
  padding-top: calc(clamp(1rem, 3vw, 4rem) + 140px);
  position: relative;
  overflow: hidden;
}

/* Giant background number (drop-cap style, à la popwebdesign) */
.feat-panel-num {
  position: absolute;
  bottom: -8%;
  right: 3%;
  font-size: clamp(12rem, 28vw, 26rem);
  font-weight: 900;
  letter-spacing: -.06em;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 2px var(--gray-200);
  text-stroke: 2px var(--gray-200);
  pointer-events: none;
  user-select: none;
  transition: -webkit-text-stroke-color .4s;
}

/* Panel layout: text left, visual right */
.feat-panel-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 6rem);
  align-items: center;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
}

.feat-panel-text {}
.feat-panel-icon {
  width: clamp(48px, 6vw, 72px);
  height: clamp(48px, 6vw, 72px);
  border-radius: clamp(12px, 1.5vw, 20px);
  display: flex; align-items: center; justify-content: center;
  font-size: clamp(22px, 3vw, 36px);
  margin-bottom: clamp(.8rem, 2vh, 1.5rem);
  box-shadow: 0 8px 24px rgba(0,0,0,.12);
}
.feat-panel-title {
  font-size: clamp(2rem, 5vw, 4rem);
  font-weight: 900; letter-spacing: -.04em; line-height: 1.05;
  margin-bottom: clamp(.6rem, 1.5vh, 1rem);
}
.feat-panel-desc {
  font-size: clamp(.9rem, 1.5vw, 1.1rem);
  color: var(--gray-600); line-height: 1.75;
  max-width: 400px;
  margin-bottom: clamp(1rem, 2.5vh, 2rem);
}
.feat-panel-tags { display: flex; flex-wrap: wrap; gap: .5rem; }
.feat-panel-tag {
  font-size: .72rem; font-weight: 700;
  padding: .3rem .8rem; border-radius: 100px;
  background: var(--white); border: 1px solid var(--gray-200);
  color: var(--gray-600);
}

/* Visual side */
.feat-panel-visual {
  display: flex; align-items: center; justify-content: center;
}
.feat-visual-card {
  width: 100%;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: clamp(16px, 2.5vw, 28px);
  padding: clamp(1.2rem, 2.5vw, 2rem);
  box-shadow: var(--shadow-lg);
}
.feat-visual-label {
  font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em;
  color: var(--gray-400); margin-bottom: .8rem;
}
.feat-visual-kpi {
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 900; letter-spacing: -.04em; margin-bottom: .4rem;
}
.feat-visual-sub { font-size: .78rem; color: var(--gray-400); font-weight: 600; margin-bottom: 1rem; }
.feat-mini-bars { display: flex; align-items: flex-end; gap: 5px; height: clamp(50px, 9vh, 80px); }
.feat-mini-bar {
  flex: 1; border-radius: 4px 4px 0 0;
  transition: height .6s cubic-bezier(.4,0,.2,1);
}
.feat-gauge-wrap { position: relative; width: clamp(100px, 15vw, 150px); margin: .5rem auto 0; }
.feat-gauge-wrap svg { width: 100%; }
.feat-stat-row { display: flex; flex-direction: column; gap: .6rem; }
.feat-stat-item { display: flex; flex-direction: column; gap: .2rem; }
.feat-stat-label { font-size: .7rem; font-weight: 700; color: var(--gray-400); }
.feat-stat-bar-wrap { background: var(--gray-100); border-radius: 100px; height: 6px; overflow: hidden; }
.feat-stat-bar { height: 100%; border-radius: 100px; transition: width 1s ease; }
.feat-stat-val { font-size: .75rem; font-weight: 800; }

/* Panel background colors */
.feat-panel:nth-child(1) { background: #fafaf8; }
.feat-panel:nth-child(2) { background: #f8f5ff; }
.feat-panel:nth-child(3) { background: #f0fdf4; }
.feat-panel:nth-child(4) { background: #fffbeb; }
.feat-panel:nth-child(5) { background: #fff1f2; }
.feat-panel:nth-child(6) { background: #f0f9ff; }

/* Scroll progress bar */
.feat-progress-wrap {
  position: absolute; bottom: clamp(1rem, 3vh, 2.5rem);
  left: clamp(1.5rem, 5vw, 4rem); right: clamp(1.5rem, 5vw, 4rem);
  z-index: 10; display: flex; align-items: center; gap: 1rem;
}
.feat-progress-track {
  flex: 1; height: 2px; background: var(--gray-200); border-radius: 100px; overflow: hidden;
}
.feat-progress-fill {
  height: 100%; background: linear-gradient(90deg, var(--indigo), var(--cyan));
  border-radius: 100px; width: 0;
  transition: width .1s linear;
}
.feat-scroll-hint {
  font-size: .75rem; font-weight: 700; color: var(--gray-400);
  display: flex; align-items: center; gap: .4rem;
  animation: slideHint 2s ease infinite;
}

/* ===== HOW IT WORKS ===== */
#how {
  background: var(--white);
  border-top: 1px solid var(--gray-200);
  border-bottom: 1px solid var(--gray-200);
  padding: var(--section-pad-v) var(--section-pad-h);
}
.steps-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1.5rem, 4vw, 3rem); }
.step { display: flex; flex-direction: column; position: relative; }
.step-num {
  font-size: clamp(3rem, 7vw, 5rem); font-weight: 900; letter-spacing: -.04em;
  color: var(--gray-200); line-height: 1; margin-bottom: .8rem;
}
.step-icon {
  width: clamp(40px, 5vw, 52px); height: clamp(40px, 5vw, 52px); border-radius: 12px;
  background: linear-gradient(135deg, var(--indigo), var(--cyan));
  display: flex; align-items: center; justify-content: center;
  font-size: clamp(16px, 2.5vw, 22px); margin-bottom: 1.2rem;
  box-shadow: 0 4px 16px rgba(91,94,244,.3);
}
.step-title { font-size: clamp(1rem, 2vw, 1.2rem); font-weight: 800; margin-bottom: .5rem; }
.step-desc { font-size: clamp(.85rem, 1.3vw, .92rem); color: var(--gray-600); line-height: 1.7; }
.step-connector {
  position: absolute; top: clamp(1.5rem, 3.5vw, 2.5rem); right: -1.5rem;
  width: 3rem; height: 2px;
  background: linear-gradient(90deg, var(--indigo), var(--cyan)); opacity: .3;
}
.step:last-child .step-connector { display: none; }

/* ===== INTEGRATIONS ===== */
#integrations { padding: var(--section-pad-v) var(--section-pad-h); }
.integrations-grid { display: flex; flex-wrap: wrap; gap: .75rem; justify-content: center; max-width: 900px; margin: 0 auto; }
.int-badge {
  display: flex; align-items: center; gap: .6rem;
  background: var(--white); border: 1px solid var(--gray-200);
  border-radius: 100px; padding: .45rem 1.1rem;
  font-size: .83rem; font-weight: 700; box-shadow: 0 1px 6px rgba(0,0,0,.04);
  transition: all .2s;
}
.int-badge:hover { transform: translateY(-2px); box-shadow: 0 4px 16px rgba(0,0,0,.08); border-color: var(--indigo-light); }
.int-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.int-badge-logo {
  width: 16px;
  height: 16px;
  object-fit: contain;
  flex-shrink: 0;
  display: block;
}

/* ===== AI SECTION ===== */
#ai-section {
  background: linear-gradient(135deg, #0a0a20 0%, #12124a 50%, #0a1a2e 100%);
  color: var(--white);
  padding: var(--section-pad-v) var(--section-pad-h);
  position: relative; overflow: hidden;
}
#ai-section::before {
  content: ''; position: absolute; top: -50%; left: -20%;
  width: 600px; height: 600px; border-radius: 50%;
  background: radial-gradient(circle, rgba(91,94,244,.2) 0%, transparent 70%);
  pointer-events: none;
}
#ai-section::after {
  content: ''; position: absolute; bottom: -30%; right: -10%;
  width: 400px; height: 400px; border-radius: 50%;
  background: radial-gradient(circle, rgba(6,182,212,.15) 0%, transparent 70%);
  pointer-events: none;
}
#ai-section p { color: rgba(255,255,255,.65); }
#ai-section .section-tag { color: var(--cyan); }
#ai-section .section-tag::before { background: var(--cyan); }
.ai-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 6vw, 6rem); align-items: center; position: relative; z-index: 1;
  max-width: 1100px; margin: 0 auto;
}
.ai-features { display: flex; flex-direction: column; gap: 1.2rem; margin-top: 1.5rem; }
.ai-feat {
  display: flex; gap: 1rem; background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08); border-radius: var(--radius); padding: 1.1rem;
  transition: all .3s;
}
.ai-feat:hover { background: rgba(255,255,255,.07); border-color: rgba(91,94,244,.4); }
.ai-feat-icon {
  width: 38px; height: 38px; border-radius: 10px;
  background: linear-gradient(135deg, var(--indigo), var(--cyan));
  display: flex; align-items: center; justify-content: center;
  font-size: 17px; flex-shrink: 0;
}
.ai-feat h4 { font-size: .95rem; font-weight: 700; color: white; margin-bottom: .25rem; }
.ai-feat p { font-size: .83rem; }
.ai-visual { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.ai-widget {
  background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius); padding: 1.1rem; transition: all .3s;
}
.ai-widget:hover { background: rgba(255,255,255,.08); transform: translateY(-3px); }
.ai-widget:first-child { grid-column: span 2; }
.ai-widget-label { font-size: .67rem; font-weight: 700; color: rgba(255,255,255,.4); text-transform: uppercase; letter-spacing: .08em; margin-bottom: .4rem; }
.ai-widget-value { font-size: clamp(1.3rem, 2.5vw, 1.8rem); font-weight: 900; letter-spacing: -.04em; }
.ai-widget-bar { height: 4px; border-radius: 2px; background: rgba(255,255,255,.1); margin-top: .7rem; overflow: hidden; }
.ai-widget-fill { height: 100%; border-radius: 2px; background: linear-gradient(90deg, var(--indigo), var(--cyan)); }
.ai-mini-chart { display: flex; align-items: flex-end; gap: 3px; height: 36px; margin-top: .7rem; }
.ai-bar { flex: 1; border-radius: 3px 3px 0 0; background: rgba(91,94,244,.4); }
.ai-bar.highlight { background: linear-gradient(to top, var(--indigo), var(--cyan)); }
.ai-bar.forecast-bar { background: transparent; border: 1px dashed rgba(6,182,212,.4); }

/* ===== TESTIMONIALS ===== */
#testimonials { background: var(--gray-100); padding: var(--section-pad-v) var(--section-pad-h); }
.testi-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; max-width: 1100px; margin: 0 auto; }
.testi-card {
  background: var(--white); border-radius: var(--radius-lg); padding: clamp(1.2rem, 2.5vh, 1.8rem);
  border: 1px solid var(--gray-200); transition: transform .3s, box-shadow .3s;
}
.testi-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.testi-stars { color: #fbbf24; font-size: .95rem; margin-bottom: .7rem; letter-spacing: 2px; }
.testi-text { font-size: clamp(.83rem, 1.3vw, .92rem); color: var(--gray-800); font-style: italic; margin-bottom: 1.1rem; line-height: 1.7; }
.testi-author { display: flex; align-items: center; gap: .75rem; }
.testi-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: .75rem; font-weight: 900; color: white;
  background: linear-gradient(135deg, var(--indigo), var(--cyan));
  flex-shrink: 0;
}
.testi-name { font-size: .85rem; font-weight: 800; }
.testi-role { font-size: .72rem; color: var(--gray-400); font-weight: 600; }

/* ===== PRICING ===== */
#pricing { padding: var(--section-pad-v) var(--section-pad-h); }
.pricing-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; max-width: 1100px; margin: 0 auto; }
.price-card {
  background: var(--white); border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg); padding: clamp(1.3rem, 3vh, 2rem);
  transition: transform .3s, box-shadow .3s; position: relative;
}
.price-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.price-card.featured {
  background: var(--black); color: var(--white);
  border-color: transparent; box-shadow: 0 20px 60px rgba(0,0,0,.2);
}
.price-card.featured p { color: rgba(255,255,255,.6); }
.popular-badge {
  position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
  background: linear-gradient(90deg, var(--indigo), var(--cyan));
  color: white; font-size: .68rem; font-weight: 800;
  padding: .28rem .9rem; border-radius: 100px; white-space: nowrap;
}
.price-name { font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--gray-400); margin-bottom: .7rem; }
.price-card.featured .price-name { color: rgba(255,255,255,.5); }
.price-amount { font-size: clamp(2rem, 4vw, 3rem); font-weight: 900; letter-spacing: -.04em; line-height: 1; margin-bottom: .3rem; }
.price-period { font-size: .82rem; color: var(--gray-400); margin-bottom: 1.2rem; }
.price-card.featured .price-period { color: rgba(255,255,255,.4); }
.price-divider { height: 1px; background: var(--gray-200); margin: 1.2rem 0; }
.price-card.featured .price-divider { background: rgba(255,255,255,.1); }
.price-features { list-style: none; display: flex; flex-direction: column; gap: .6rem; margin-bottom: 1.5rem; }
.price-features li { display: flex; align-items: center; gap: .6rem; font-size: .85rem; }
.price-features li::before { content: '✓'; color: var(--green); font-weight: 900; font-size: .85rem; }
.price-card.featured .price-features li::before { color: #34d399; }

/* ===== CTA ===== */
#cta {
  padding: var(--section-pad-v) var(--section-pad-h);
  background: var(--black);
  text-align: center; color: var(--white); position: relative; overflow: hidden;
}
#cta::before {
  content: 'K'; position: absolute; bottom: -15%; right: -2%;
  font-size: clamp(200px, 40vw, 500px); font-weight: 900;
  color: rgba(255,255,255,.02); line-height: 1; pointer-events: none;
}
.cta-title { max-width: 700px; margin: 0 auto clamp(.8rem, 2vh, 1.5rem); }
.cta-sub { max-width: 480px; margin: 0 auto clamp(1.5rem, 4vh, 3rem); color: rgba(255,255,255,.5); font-size: clamp(.95rem, 1.8vw, 1.1rem); }
.cta-actions { display: flex; justify-content: center; gap: 1rem; flex-wrap: wrap; }

/* ===== FOOTER ===== */
footer {
  background: var(--black); color: rgba(255,255,255,.4);
  padding: clamp(1.5rem, 4vh, 3rem) var(--section-pad-h);
  border-top: 1px solid rgba(255,255,255,.07);
}
.footer-inner {
  max-width: 1100px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1.5rem;
}
.footer-logo { font-size: 1.2rem; font-weight: 900; color: white; letter-spacing: -.03em; }
.footer-logo span { color: var(--indigo-light); }
.footer-links { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.footer-links a { font-size: .8rem; font-weight: 600; transition: color .2s; }
.footer-links a:hover { color: white; }
.footer-copy { font-size: .75rem; }

/* ===== ANIMATIONS ===== */
@keyframes fadeUp { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }
@keyframes floatAnim { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .7; transform: scale(1.3); } }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes slideHint { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(8px); } }

/* Scroll reveal */
.reveal { opacity: 0; transform: translateY(40px); transition: opacity .7s ease, transform .7s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-left { opacity: 0; transform: translateX(-40px); transition: opacity .7s ease, transform .7s ease; }
.reveal-left.visible { opacity: 1; transform: translateX(0); }
.reveal-right { opacity: 0; transform: translateX(40px); transition: opacity .7s ease, transform .7s ease; }
.reveal-right.visible { opacity: 1; transform: translateX(0); }
.reveal-scale { opacity: 0; transform: scale(.92); transition: opacity .6s ease, transform .6s ease; }
.reveal-scale.visible { opacity: 1; transform: scale(1); }
.delay-1 { transition-delay: .1s; }
.delay-2 { transition-delay: .2s; }
.delay-3 { transition-delay: .3s; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .feat-panel-inner { grid-template-columns: 1fr; gap: 1.5rem; }
  .feat-panel-visual { display: none; }
  .feat-panel-num { font-size: clamp(8rem, 20vw, 16rem); }
  .feat-panel-desc { max-width: 600px; }
  .ai-grid { grid-template-columns: 1fr; gap: 2.5rem; }
}
@media (max-width: 768px) {
  nav#navbar { padding: .9rem 1.5rem; }
  .nav-links { display: none; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
  .dash-content { grid-template-columns: 1fr; }
  .dash-sidebar { display: none; }
  .dash-kpi-row { grid-template-columns: repeat(2, 1fr); }
  .dash-chart-row { grid-template-columns: 1fr; }
  .steps-grid { grid-template-columns: 1fr; gap: 2rem; }
  .step-connector { display: none; }
  .testi-grid { grid-template-columns: 1fr; }
  .pricing-grid { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; text-align: center; }
  .features-header-bar { flex-direction: column; gap: .5rem; }
  .feat-counter { align-self: flex-start; }
  #features { height: 700vh; }
}

/* ============================================================
   FLOATING CONTACT BUTTON (FAB)
   ============================================================ */

#contact-fab {
  position: fixed;
  bottom: 2.5rem;
  right: 2.5rem;
  z-index: 500;
  width: 72px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* Pulsing rings */
.fab-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid var(--indigo);
  opacity: 0;
  animation: fabPulse 3s ease-out infinite;
}
.fab-ring-2 { animation-delay: 1.2s; }

@keyframes fabPulse {
  0%   { transform: scale(1);    opacity: .6; }
  100% { transform: scale(2.2);  opacity: 0;  }
}

/* Rotating orbit text */
.fab-orbit {
  position: absolute;
  inset: -24px;
  animation: fabOrbit 10s linear infinite;
  pointer-events: none;
}
.fab-orbit svg { width: 100%; height: 100%; }
.fab-orbit-text {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  fill: var(--gray-400);
}

@keyframes fabOrbit {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* Core circle */
.fab-core {
  position: relative; z-index: 2;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--black);
  border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 32px rgba(0,0,0,.25);
  transition: transform .35s cubic-bezier(.34,1.56,.64,1),
              background .3s ease,
              box-shadow .3s ease;
  overflow: hidden;
}
.fab-core:hover {
  transform: scale(1.15);
  background: var(--indigo);
  box-shadow: 0 12px 40px rgba(91,94,244,.45);
}

/* Icon swap on hover */
.fab-icon {
  position: absolute;
  width: 22px; height: 22px;
  color: white;
  transition: opacity .25s ease, transform .3s cubic-bezier(.34,1.56,.64,1);
}
.fab-icon-mail  { opacity: 1;  transform: translateY(0) scale(1); }
.fab-icon-arrow { opacity: 0;  transform: translateY(6px) scale(.7); }

.fab-core:hover .fab-icon-mail  { opacity: 0;  transform: translateY(-6px) scale(.7); }
.fab-core:hover .fab-icon-arrow { opacity: 1;  transform: translateY(0) scale(1); }

/* Orbit speed on hover */
#contact-fab:hover .fab-orbit { animation-duration: 4s; }
#contact-fab:hover .fab-ring  { animation-duration: 1.8s; }

/* ============================================================
   CONTACT MODAL
   ============================================================ */

#contact-modal {
  position: fixed; inset: 0; z-index: 2000;
  display: flex; align-items: flex-end; justify-content: flex-end;
  padding: 1.5rem;
  pointer-events: none;
  opacity: 0;
  transition: opacity .3s ease;
}
#contact-modal.open {
  pointer-events: all;
  opacity: 1;
}

.modal-backdrop {
  position: absolute; inset: 0;
  background: rgba(8,8,8,.4);
  backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity .35s ease;
}
#contact-modal.open .modal-backdrop { opacity: 1; }

.modal-panel {
  position: relative; z-index: 1;
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: clamp(1.5rem, 3vw, 2.5rem);
  width: min(520px, 95vw);
  box-shadow: 0 32px 80px rgba(0,0,0,.2);
  transform: translateY(40px) scale(.96);
  transition: transform .4s cubic-bezier(.34,1.2,.64,1);
  max-height: 92vh;
  overflow-y: auto;
}
#contact-modal.open .modal-panel {
  transform: translateY(0) scale(1);
}

.modal-close {
  position: absolute; top: 1.2rem; right: 1.2rem;
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--gray-100); border: none; cursor: pointer;
  font-size: .85rem; font-weight: 700; color: var(--gray-600);
  display: flex; align-items: center; justify-content: center;
  transition: all .2s;
}
.modal-close:hover { background: var(--gray-200); color: var(--black); transform: rotate(90deg); }

.modal-header { margin-bottom: clamp(1.2rem, 2.5vh, 1.8rem); }
.modal-tag {
  display: inline-flex; align-items: center; gap: .4rem;
  font-size: .72rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
  color: var(--indigo); margin-bottom: .8rem;
}
.modal-tag::before { content: ''; width: 16px; height: 2px; background: var(--indigo); border-radius: 10px; }
.modal-title { font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 900; letter-spacing: -.03em; margin-bottom: .5rem; line-height: 1.15; }
.modal-sub { font-size: .88rem; color: var(--gray-400); }

/* Form */
.modal-form { display: flex; flex-direction: column; gap: 1rem; }
.modal-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.modal-field { display: flex; flex-direction: column; gap: .35rem; }
.modal-field label {
  font-size: .75rem; font-weight: 800; color: var(--gray-600);
  text-transform: uppercase; letter-spacing: .06em;
}
.modal-field input,
.modal-field textarea {
  width: 100%;
  padding: .7rem 1rem;
  border: 1.5px solid var(--gray-200);
  border-radius: 10px;
  font-size: .9rem; font-family: inherit;
  background: var(--bg);
  color: var(--black);
  transition: border-color .2s, box-shadow .2s;
  outline: none; resize: none;
}
.modal-field input:focus,
.modal-field textarea:focus {
  border-color: var(--indigo);
  box-shadow: 0 0 0 3px rgba(91,94,244,.12);
  background: var(--white);
}
.modal-field input::placeholder,
.modal-field textarea::placeholder { color: var(--gray-400); }

.modal-footer-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; flex-wrap: wrap; margin-top: .5rem;
}
.modal-privacy { font-size: .75rem; color: var(--gray-400); font-weight: 600; }
.modal-submit { position: relative; overflow: hidden; }
.modal-submit .submit-arrow { transition: transform .2s; }
.modal-submit:hover .submit-arrow { transform: translate(3px, -3px); }

/* Success state */
.modal-success {
  display: none;
  flex-direction: column; align-items: center; text-align: center;
  padding: 2rem 1rem;
}
.modal-success.show { display: flex; }
.modal-form.hide { display: none; }
.success-icon { font-size: 3rem; margin-bottom: 1rem; animation: bounceIn .5s cubic-bezier(.34,1.56,.64,1); }
.modal-success h4 { font-size: 1.4rem; font-weight: 900; margin-bottom: .5rem; }
.modal-success p { color: var(--gray-400); font-size: .9rem; }

@keyframes bounceIn {
  from { transform: scale(0); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

/* Mobile */
@media (max-width: 768px) {
  #contact-fab { bottom: 1.5rem; right: 1.5rem; }
  #contact-modal { padding: .75rem; align-items: flex-end; justify-content: stretch; }
  .modal-panel { width: 100%; border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
  .modal-row { grid-template-columns: 1fr; }
  .fab-orbit { display: none; }
  #contact-fab { width: 58px; height: 58px; }
  .fab-core { width: 48px; height: 48px; }
}

/* ============================================================
   CUSTOM CURSOR FOLLOWER
   ============================================================ */

/* Native cursor is kept - only the ring follower is layered on top */

#kk-cursor {
  position: fixed;
  top: 0; left: 0;
  pointer-events: none;
  z-index: 9999;
  will-change: transform;
}

/* Outer ring - follows with lerp lag */
#kk-cursor-ring {
  position: absolute;
  width: 36px; height: 36px;
  border: 1.5px solid var(--indigo);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  opacity: .45;
  transition:
    width  .5s cubic-bezier(.23,1,.32,1),
    height .5s cubic-bezier(.23,1,.32,1),
    border-color .3s ease,
    background-color .3s ease,
    opacity .3s ease;
}

/* Inner dot - hidden, native arrow cursor is preserved */
#kk-cursor-dot { display: none; }

/* ── Hover state (over links, buttons) */
#kk-cursor.is-hover #kk-cursor-ring {
  width: 54px; height: 54px;
  opacity: .25;
  background: rgba(91,94,244,.06);
}

/* ── Click flash */
#kk-cursor.is-click #kk-cursor-ring {
  width: 24px; height: 24px;
  opacity: .7;
  transition: width .1s ease, height .1s ease, opacity .1s ease;
}

/* ── Dark section (white ring) */
#kk-cursor.is-dark #kk-cursor-ring { border-color: rgba(255,255,255,.6); }

/* ── Hidden (over inputs, textareas) */
#kk-cursor.is-hidden #kk-cursor-ring { opacity: 0 !important; }

/* ── Menu open (cyan accent) */
body.menu-is-open #kk-cursor-ring { border-color: var(--cyan); }

/* Hide on touch/mobile */
@media (pointer: coarse) {
  #kk-cursor { display: none; }
}

/* ============================================================
   MENU TOGGLE BUTTON (replaces .nav-burger)
   ============================================================ */

.menu-toggle {
  display: flex; align-items: center; gap: .45rem;
  background: none; border: none;
  font-size: .86rem; font-weight: 800; letter-spacing: .01em;
  color: var(--black);
  padding: .4rem 0;
  cursor: pointer;
  transition: color .2s ease;
  white-space: nowrap;
  flex-shrink: 0;
}
.menu-toggle:hover { color: var(--indigo); }

/* Animated dot before "Menu" */
.menu-toggle-dot {
  width: 7px; height: 7px; min-width: 7px;
  border-radius: 50%;
  background: var(--indigo);
  display: inline-block;
  animation: pulse 2.2s ease infinite;
  transition: background .3s ease, transform .3s ease;
}
.menu-toggle:hover .menu-toggle-dot { transform: scale(1.4); }
body.menu-is-open .menu-toggle-dot {
  background: var(--cyan);
  animation: none;
  transform: scale(1);
}

.menu-toggle-label {
  transition: opacity .2s ease;
}


/* On desktop: show menu-toggle alongside nav-links */
@media (min-width: 769px) {
  .menu-toggle { display: flex; }
}
/* On mobile: always visible */
@media (max-width: 768px) {
  .menu-toggle { display: flex; }
  .nav-links, .nav-cta { display: none; }
}

/* ============================================================
   FULL-SCREEN MENU OVERLAY (like IMK)
   ============================================================ */

#screen-menu {
  position: fixed; inset: 0; z-index: 1050;
  background: #0d0d1a;
  display: flex; flex-direction: column;
  padding: clamp(5rem,10vh,7rem) var(--section-pad-h) clamp(2rem,4vh,3rem);
  /* clip from bottom → top on open */
  clip-path: inset(0 0 100% 0);
  transition:
    clip-path .65s cubic-bezier(.77,0,.18,1);
  pointer-events: none;
  overflow: hidden;
}
#screen-menu.is-open {
  clip-path: inset(0 0 0% 0);
  pointer-events: all;
}

.sm-inner {
  flex: 1;
  display: flex; flex-direction: column; justify-content: space-between;
  max-width: 1200px; margin: 0 auto; width: 100%;
}

/* ── Two-column nav links */
.sm-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-content: center;
  flex: 1;
  padding: clamp(1rem,4vh,3rem) 0;
  gap: 0 2rem;
}

.sm-link {
  display: block;
  font-size: clamp(2rem, 6.5vw, 5.5rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1.1;
  padding: .2em 0;
  color: rgba(255,255,255,.22);
  transition: color .3s ease, transform .3s cubic-bezier(.23,1,.32,1);
  /* Animate in */
  opacity: 0;
  transform: translateY(30px);
}
.sm-link:hover {
  color: #ffffff;
  transform: translateX(10px) !important;
}

/* Staggered reveal when open */
#screen-menu.is-open .sm-link {
  animation: smLinkReveal .65s cubic-bezier(.23,1,.32,1) forwards;
}
#screen-menu.is-open .sm-link:nth-child(1) { animation-delay: .08s; }
#screen-menu.is-open .sm-link:nth-child(2) { animation-delay: .14s; }
#screen-menu.is-open .sm-link:nth-child(3) { animation-delay: .20s; }
/* Right column: children of second .sm-col */
#screen-menu.is-open .sm-col:nth-child(2) .sm-link:nth-child(1) { animation-delay: .11s; }
#screen-menu.is-open .sm-col:nth-child(2) .sm-link:nth-child(2) { animation-delay: .17s; }
#screen-menu.is-open .sm-col:nth-child(2) .sm-link:nth-child(3) { animation-delay: .23s; }

@keyframes smLinkReveal {
  to {
    opacity: 1;
    transform: translateY(0);
    color: rgba(255,255,255,.55);
  }
}

/* Active link highlight */
.sm-link.sm-active { color: rgba(255,255,255,.85) !important; }

/* ── Divider */
.sm-divider {
  width: 100%; height: 1px;
  background: rgba(255,255,255,.08);
  margin: 0 0 clamp(1.2rem,3vh,2rem);
}

/* ── Footer row */
.sm-footer {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 1.5rem;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .4s ease, transform .4s ease;
}
#screen-menu.is-open .sm-footer {
  opacity: 1; transform: translateY(0);
  transition-delay: .35s;
}

.sm-footer-info { display: flex; flex-direction: column; gap: .2rem; }
.sm-footer-label {
  font-size: .65rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: .1em;
  color: rgba(255,255,255,.3);
}
.sm-footer-link {
  font-size: .82rem; font-weight: 600;
  color: rgba(255,255,255,.55);
  transition: color .2s;
}
.sm-footer-link:hover { color: white; }

.sm-socials { display: flex; gap: .6rem; margin-top: .2rem; }
.sm-social {
  width: 36px; height: 36px;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: .75rem; font-weight: 800; color: rgba(255,255,255,.5);
  transition: all .2s ease;
}
.sm-social:hover {
  background: rgba(255,255,255,.08);
  border-color: rgba(255,255,255,.3);
  color: white;
}

.sm-cta {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .4s ease .4s, transform .4s ease .4s;
}
#screen-menu.is-open .sm-cta {
  opacity: 1; transform: translateY(0);
}

/* ── Close button (inside screen-menu) */
.sm-close {
  position: absolute; top: 1.5rem; right: clamp(1.5rem, 4vw, 4rem);
  display: flex; align-items: center; gap: .5rem;
  background: none; border: none; cursor: pointer;
  font-size: .86rem; font-weight: 800;
  color: rgba(255,255,255,.5);
  transition: color .2s ease;
  padding: .4rem 0;
}
.sm-close:hover { color: white; }
.sm-close-x {
  font-size: 1rem; line-height: 1;
  transition: transform .3s cubic-bezier(.34,1.56,.64,1);
}
.sm-close:hover .sm-close-x { transform: rotate(90deg); }

/* Responsive */
@media (max-width: 640px) {
  .sm-nav { grid-template-columns: 1fr; }
  .sm-footer { flex-direction: column; align-items: flex-start; gap: 1rem; }
  .sm-cta { width: 100%; text-align: center; justify-content: center; }
}

/* ============================================================
   KAROOKA - PREFERENCE SYSTEME : MOUVEMENT REDUIT
   ============================================================ */
/* ⚠ NE JAMAIS remplacer ce bloc par le reset que l on copie-colle partout
   (`* { animation: none !important }`). Dans CE projet, .hero-badge, .hero-title,
   .hero-sub, .hero-actions et .hero-trust sont declares `opacity: 0` et ne
   deviennent visibles QUE par l animation fadeUp. Les couper rendrait le hero
   entierement blanc, de maniere silencieuse et indetectable sans activer la preference.
   On conserve donc les animations avec une duree quasi nulle et fill-mode forwards :
   elles atteignent instantanement leur etat final, donc opacity 1. */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-delay: 0ms !important;
    /* neutralise les boucles infinies : pulse, floatAnim, marquee, slideHint, fabPulse, fabOrbit */
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    transition-delay: 0ms !important;
    scroll-behavior: auto !important;
  }
  /* Filets de securite : ces elements dependent d une animation ou du JS pour apparaitre. */
  .hero-badge, .hero-title, .hero-sub, .hero-actions, .hero-trust { opacity: 1 !important; }
  .reveal, .reveal-left, .reveal-right, .reveal-scale { opacity: 1 !important; transform: none !important; }
  /* Le mot rotatif se fige sur le mot canonique, strictement identique au HTML servi,
     au <title> et a l image de partage : aucun ecart de message entre les deux modes. */
  .rot__paint { display: none !important; }
  .rot.is-live .rot__word { opacity: 1 !important; }
  .rot-pause { display: none !important; }
}
