/* Reset CSS de base : box-sizing border-box évite les problèmes de calcul de largeur/padding */
/* J'ai mis ça au début pour être sûr que tous les éléments héritent de ce comportement */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* Variables CSS (custom properties) : super pratique pour gérer le thème */
/* C'est mieux que des constantes SCSS car on peut les modifier dynamiquement en JS si besoin */
:root {
  --red: #D72638;       /* Couleur principale de la marque */
  --red-light: #FF3B4E; /* Version plus claire pour les hover */
  --red-dim: rgba(215,38,56,0.12); /* Version transparente pour les fonds */
  --bg: #0A0A0B;        /* Fond principal (presque noir) */
  --bg2: #111113;       /* Fond secondaire (légèrement plus clair) */
  --bg3: #18181C;       /* Fond tertiaire (pour les cartes) */
  --border: rgba(255,255,255,0.07); /* Bordures subtiles */
  --text: #F0EEE8;      /* Texte principal */
  --muted: #6B6870;     /* Texte secondaire (gris) */
  --accent: #FF3B4E;    /* Accent pour les éléments importants */
}

/* scroll-behavior smooth permet un défilement fluide quand on clique sur les ancres */
/* C'est une propriété CSS native, pas besoin de JS pour ça */
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'DM Sans', sans-serif;
  overflow-x: hidden; /* Évite le scroll horizontal accidentel sur mobile */
}

/* NOISE OVERLAY : effet de texture subtile sur toute la page */
/* J'ai utilisé un SVG inline avec un filtre de bruit fractal pour éviter de charger une image externe */
/* pointer-events: none est important pour ne pas bloquer les clics sur les éléments en dessous */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
  opacity: 0.5;
}

/* NAV : barre de navigation fixe en haut de page */
/* backdrop-filter crée l'effet de flou derrière la navbar (style macOS/iOS) */
/* J'ai mis un fallback -webkit- pour Safari qui a parfois du retard sur les standards */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 0 6vw;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(10,10,11,0.85);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.6rem;
  letter-spacing: 0.08em;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-logo span {
  color: var(--red);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--text); }

.nav-cta {
  background: var(--red);
  color: #fff !important;
  padding: 8px 20px;
  border-radius: 4px;
  font-weight: 600 !important;
  transition: background 0.2s !important;
}

.nav-cta:hover { background: var(--red-light) !important; color: #fff !important; }

/* HERO */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 120px 6vw 80px;
  position: relative;
  overflow: hidden;
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(215,38,56,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(215,38,56,0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 50%, black, transparent);
  mask-image: radial-gradient(ellipse 80% 60% at 50% 50%, black, transparent);
}

.hero-glow {
  position: absolute;
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 600px;
  background: radial-gradient(ellipse, rgba(215,38,56,0.18) 0%, transparent 70%);
  pointer-events: none;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--red-dim);
  border: 1px solid rgba(215,38,56,0.3);
  color: var(--red-light);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  padding: 6px 14px;
  border-radius: 2px;
  margin-bottom: 2rem;
  width: fit-content;
  animation: fadeUp 0.6s ease both;
}

.hero-badge::before {
  content: '';
  width: 6px; height: 6px;
  background: var(--red);
  border-radius: 50%;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.3); }
}

.hero h1 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(4rem, 10vw, 9rem);
  line-height: 0.9;
  letter-spacing: 0.02em;
  animation: fadeUp 0.6s 0.1s ease both;
}

.hero h1 em {
  font-style: normal;
  color: var(--red);
  display: block;
}

.hero-sub {
  font-size: clamp(1rem, 1.5vw, 1.25rem);
  color: var(--muted);
  max-width: 520px;
  line-height: 1.7;
  margin-top: 1.5rem;
  font-weight: 300;
  animation: fadeUp 0.6s 0.2s ease both;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  margin-top: 2.5rem;
  flex-wrap: wrap;
  animation: fadeUp 0.6s 0.3s ease both;
}

.btn-primary {
  background: var(--red);
  color: #fff;
  padding: 14px 32px;
  border: none;
  border-radius: 4px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  letter-spacing: 0.02em;
  transition: all 0.2s;
}

.btn-primary:hover {
  background: var(--red-light);
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(215,38,56,0.35);
}

.btn-secondary {
  background: transparent;
  color: var(--text);
  padding: 14px 32px;
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  transition: all 0.2s;
}

.btn-secondary:hover {
  border-color: rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.04);
}

.hero-stats {
  display: flex;
  gap: 3rem;
  margin-top: 4rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--border);
  animation: fadeUp 0.6s 0.4s ease both;
}

.stat-item { display: block; }
.stat-num {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 2.4rem;
  color: var(--text);
  letter-spacing: 0.04em;
}
.stat-num span { color: var(--red); }
.stat-label {
  font-size: 0.8rem;
  color: var(--muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-top: 2px;
}

/* DASHBOARD MOCKUP */
.hero-visual {
  position: absolute;
  right: -2vw;
  top: 50%;
  transform: translateY(-50%);
  width: 46vw;
  max-width: 680px;
  animation: fadeLeft 0.8s 0.3s ease both;
}

@keyframes fadeLeft {
  from { opacity: 0; transform: translateY(-50%) translateX(40px); }
  to { opacity: 1; transform: translateY(-50%) translateX(0); }
}

.mockup {
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: -40px 40px 120px rgba(0,0,0,0.6), 0 0 0 1px rgba(255,255,255,0.04);
}

.mockup-bar {
  background: var(--bg2);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 6px;
  border-bottom: 1px solid var(--border);
}

.mockup-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
}

.mockup-body {
  padding: 20px;
}

.mock-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.mock-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.1rem;
  letter-spacing: 0.08em;
  color: var(--text);
}

.mock-tag {
  background: var(--red-dim);
  color: var(--red-light);
  font-size: 0.7rem;
  font-family: 'JetBrains Mono', monospace;
  padding: 3px 8px;
  border-radius: 2px;
}

.mock-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}

.mock-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px;
}

.mock-card-label {
  font-size: 0.65rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 6px;
}

.mock-card-val {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.5rem;
  letter-spacing: 0.04em;
}

.mock-card-val.red { color: var(--red); }
.mock-card-val.green { color: #34D399; }

.mock-chart {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px;
  height: 100px;
  display: flex;
  align-items: flex-end;
  gap: 6px;
  margin-bottom: 16px;
}

.mock-bar {
  flex: 1;
  border-radius: 3px 3px 0 0;
  background: var(--red-dim);
  border: 1px solid rgba(215,38,56,0.2);
  transition: height 0.3s;
}

.mock-bar.active { background: var(--red); border-color: var(--red); }

.mock-table { width: 100%; border-collapse: collapse; }
.mock-table th {
  font-size: 0.65rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  text-align: left;
  padding: 6px 8px;
  border-bottom: 1px solid var(--border);
}
.mock-table td {
  font-size: 0.75rem;
  padding: 7px 8px;
  border-bottom: 1px solid rgba(255,255,255,0.03);
  color: var(--text);
}
.mock-table td:last-child { color: var(--red-light); font-family: 'JetBrains Mono', monospace; font-size: 0.7rem; }

.status-dot {
  display: inline-block;
  width: 6px; height: 6px;
  border-radius: 50%;
  margin-right: 5px;
}
.status-dot.ok { background: #34D399; }
.status-dot.warn { background: #FBBF24; }
.status-dot.red { background: var(--red); }

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* SECTIONS COMMUNES */
section { padding: 100px 6vw; }

.section-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.72rem;
  color: var(--red);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.section-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  line-height: 1;
  letter-spacing: 0.03em;
  margin-bottom: 1.2rem;
}

.section-desc {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 500px;
  line-height: 1.7;
  font-weight: 300;
}

/* FEATURES */
.features { background: var(--bg2); }

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5px;
  margin-top: 4rem;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}

.feature-card {
  background: var(--bg3);
  padding: 2.5rem;
  position: relative;
  transition: background 0.3s;
}

.feature-card:hover { background: #1C1C21; }

.feature-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-right: 1.5px solid var(--border);
  border-bottom: 1.5px solid var(--border);
  pointer-events: none;
}

.feature-icon {
  width: 44px; height: 44px;
  background: var(--red-dim);
  border: 1px solid rgba(215,38,56,0.25);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  margin-bottom: 1.2rem;
}

.feature-name {
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.6rem;
  letter-spacing: 0.01em;
}

.feature-desc {
  color: var(--muted);
  font-size: 0.875rem;
  line-height: 1.65;
  font-weight: 300;
}

/* PRICING */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 4rem;
  max-width: 1000px;
}

.pricing-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
  position: relative;
  transition: border-color 0.3s;
}

.pricing-card:hover { border-color: rgba(255,255,255,0.15); }

.pricing-card.featured {
  border-color: var(--red);
  background: linear-gradient(135deg, rgba(215,38,56,0.06), var(--bg2));
}

.pricing-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--red);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 14px;
  border-radius: 2px;
  white-space: nowrap;
}

.pricing-plan {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.pricing-price {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 3.5rem;
  letter-spacing: 0.04em;
  line-height: 1;
  margin-bottom: 0.3rem;
}

.pricing-price sup {
  font-size: 1.5rem;
  vertical-align: top;
  margin-top: 0.5rem;
  display: inline-block;
}

.pricing-period {
  font-size: 0.8rem;
  color: var(--muted);
  margin-bottom: 1.5rem;
}

.pricing-features {
  list-style: none;
  margin-bottom: 2rem;
}

.pricing-features li {
  font-size: 0.875rem;
  color: var(--muted);
  padding: 7px 0;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 300;
}

.pricing-features li::before {
  content: '✓';
  color: var(--red);
  font-weight: 700;
  font-size: 0.8rem;
  flex-shrink: 0;
}

/* Utility classes to avoid inline styles */
.mockup-dot.red { background: #FF5F57; }
.mockup-dot.amber { background: #FEBC2E; }
.mockup-dot.green { background: #28C840; }

.mock-bar.h40 { height: 40%; }
.mock-bar.h60 { height: 60%; }
.mock-bar.h45 { height: 45%; }
.mock-bar.h75 { height: 75%; }
.mock-bar.h90 { height: 90%; }
.mock-bar.h55 { height: 55%; }
.mock-bar.h65 { height: 65%; }

.btn-full { width: 100%; display: inline-block; }
.pricing-price.small { font-size: 2.5rem; }
.cta-desc-center { margin: 0 auto; text-align: center; }

.pricing-features li.dim::before { content: '–'; color: var(--muted); }
.pricing-features li.dim { opacity: 0.4; }

/* TESTIMONIALS */
.testimonials { background: var(--bg2); }

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 4rem;
}

.testimonial-card {
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
}

.testimonial-quote {
  font-size: 0.95rem;
  line-height: 1.75;
  color: #C0BDB8;
  font-weight: 300;
  margin-bottom: 1.5rem;
  font-style: italic;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.author-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--red-dim);
  border: 1px solid rgba(215,38,56,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1rem;
  color: var(--red-light);
}

.author-name {
  font-weight: 600;
  font-size: 0.875rem;
}

.author-role {
  font-size: 0.75rem;
  color: var(--muted);
  margin-top: 1px;
}

/* CTA */
.cta-section {
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 400px;
  background: radial-gradient(ellipse, rgba(215,38,56,0.12), transparent 70%);
  pointer-events: none;
}

.cta-section .section-title { font-size: clamp(3rem, 6vw, 5.5rem); }

.cta-input-row {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  margin-top: 2.5rem;
  flex-wrap: wrap;
}

.cta-input {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 14px 20px;
  color: var(--text);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  width: 300px;
  outline: none;
  transition: border-color 0.2s;
}

.cta-input:focus { border-color: var(--red); }
.cta-input::placeholder { color: var(--muted); }

/* FOOTER */
footer {
  border-top: 1px solid var(--border);
  padding: 2.5rem 6vw;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-logo {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.3rem;
  letter-spacing: 0.08em;
}

.footer-logo span { color: var(--red); }

.footer-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.footer-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.8rem;
  transition: color 0.2s;
}

.footer-links a:hover { color: var(--text); }

.footer-copy {
  font-size: 0.75rem;
  color: var(--muted);
  font-family: 'JetBrains Mono', monospace;
}

/* SCROLL REVEAL */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

/* RESPONSIVE */
@media (max-width: 900px) {
  .hero-visual { display: none; }
  .hero h1 { font-size: clamp(3.5rem, 14vw, 6rem); }
  .hero-stats { gap: 1.5rem; flex-wrap: wrap; }
  .nav-links { display: none; }
}
