/* === RESET & BASE STYLES === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
}

/* === VARIABLES === */
:root {
    /* Colors */
    --primary-color: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary-color: #10b981;
    --accent-color: #f59e0b;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --text-light: #9ca3af;
    --background-light: #f8fafc;
    --background-dark: #0f172a;
    --border-color: #e5e7eb;
    --white: #ffffff;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    
    /* Typography */
    --font-size-xs: 0.75rem;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.25rem;
    --font-size-2xl: 1.5rem;
    --font-size-3xl: 1.875rem;
    --font-size-4xl: 2.25rem;
    --font-size-5xl: 3rem;
    
    /* Spacing */
    --container-max-width: 1200px;
    --section-padding: 5rem 0;
    --border-radius: 0.5rem;
    --border-radius-lg: 1rem;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

/* === UTILITY CLASSES === */
.container {
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding: 0 1rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: var(--border-radius);
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    font-family: inherit;
    font-size: var(--font-size-base);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: var(--white);
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: var(--white);
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: var(--white);
}

.btn-large {
    padding: 1rem 2rem;
    font-size: var(--font-size-lg);
    font-weight: 700;
}

.btn-cta {
    background: var(--accent-color);
    color: var(--white);
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-cta:hover {
    background: #d97706;
    transform: translateY(-1px);
}

.highlight {
    background: linear-gradient(120deg, var(--accent-color) 0%, var(--accent-color) 100%);
    background-repeat: no-repeat;
    background-size: 100% 0.2em;
    background-position: 0 88%;
    color: var(--text-primary);
    font-weight: 700;
}

/* === HEADER === */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar {
    padding: 1rem 0;
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-size: var(--font-size-2xl);
    font-weight: 800;
    color: var(--primary-color);
    letter-spacing: -0.5px;
}

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

.nav-menu a {
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-menu a:hover {
    color: var(--primary-color);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: 0.3s;
}

/* === HERO SECTION === */
.hero {
    padding: 8rem 0 6rem;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    margin-top: 80px;
}

.hero-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: var(--font-size-5xl);
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.hero-subtitle {
    font-size: var(--font-size-xl);
    color: var(--text-secondary);
    margin-bottom: 3rem;
    font-weight: 500;
}

.hero-benefits {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 3rem;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.benefit-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 600;
    color: var(--text-primary);
}

.benefit-item i {
    color: var(--success);
    font-size: var(--font-size-lg);
}

.hero-cta {
    margin-top: 2rem;
}

/* === PROBLEM SECTION === */
.problem-section {
    padding: var(--section-padding);
    background: var(--white);
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: var(--font-size-4xl);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: var(--font-size-lg);
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.stat-highlight {
    margin: 2rem 0;
}

.stat-number {
    font-size: 4rem;
    font-weight: 800;
    color: var(--danger);
    display: block;
    line-height: 1;
}

.stat-text {
    font-size: var(--font-size-lg);
    color: var(--text-secondary);
    margin-top: 0.5rem;
}

.problems-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.problem-card {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    border-left: 4px solid var(--danger);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.problem-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.problem-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #fee2e2, #fecaca);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.problem-icon i {
    font-size: var(--font-size-xl);
    color: var(--danger);
}

.problem-card h3 {
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.problem-card p {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* === SOLUTION SECTION === */
.solution-section {
    padding: var(--section-padding);
    background: var(--background-light);
}

.solution-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.feature-item {
    display: flex;
    gap: 1.5rem;
    background: var(--white);
    padding: 2rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.feature-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.feature-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.feature-icon i {
    font-size: var(--font-size-xl);
    color: var(--white);
}

.feature-text h4 {
    font-size: var(--font-size-lg);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.feature-text p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* === BENEFITS SECTION === */
.benefits-section {
    padding: var(--section-padding);
    background: var(--white);
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.benefit-card {
    text-align: center;
    padding: 2.5rem 2rem;
    background: var(--white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.benefit-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.benefit-card i {
    font-size: 3rem;
    color: var(--success);
    margin-bottom: 1.5rem;
    display: block;
}

.benefit-card h3 {
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.benefit-card p {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* === CTA SECTION === */
.cta-section {
    padding: var(--section-padding);
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: var(--white);
}

.cta-content {
    text-align: center;
}

.cta-content h2 {
    font-size: var(--font-size-4xl);
    font-weight: 700;
    margin-bottom: 1rem;
}

.cta-content p {
    font-size: var(--font-size-lg);
    margin-bottom: 2rem;
    opacity: 0.9;
}

.cta-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
}

/* === FOOTER === */
.footer {
    background: var(--background-dark);
    color: var(--white);
    padding: 3rem 0 1.5rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-brand h3 {
    font-size: var(--font-size-2xl);
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.footer-brand p {
    color: var(--text-light);
    line-height: 1.6;
}

.footer-column h4 {
    font-size: var(--font-size-lg);
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--white);
}

.footer-column ul {
    list-style: none;
}

.footer-column ul li {
    margin-bottom: 0.5rem;
}

.footer-column ul li a {
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-column ul li a:hover {
    color: var(--primary-color);
}

.footer-column ul li i {
    margin-right: 0.5rem;
    color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #374151;
    color: var(--text-light);
}

/* === MODAL === */
.modal {
    display: none;
    position: fixed;
    z-index: 1001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: var(--white);
    margin: 5% auto;
    padding: 2rem;
    border-radius: var(--border-radius-lg);
    width: 90%;
    max-width: 500px;
    position: relative;
    box-shadow: var(--shadow-xl);
}

.close {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-size: var(--font-size-2xl);
    font-weight: bold;
    cursor: pointer;
    color: var(--text-secondary);
}

.close:hover {
    color: var(--text-primary);
}

.modal-content h3 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-size: var(--font-size-2xl);
}

.form-group {
    margin-bottom: 1rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: var(--font-size-base);
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

/* === RESPONSIVE DESIGN === */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .hamburger {
        display: flex;
    }
    
    .hero-title {
        font-size: var(--font-size-3xl);
    }
    
    .hero-benefits {
        align-items: flex-start;
        text-align: left;
    }
    
    .section-header h2 {
        font-size: var(--font-size-3xl);
    }
    
    .problems-grid {
        grid-template-columns: 1fr;
    }
    
    .solution-features {
        grid-template-columns: 1fr;
    }
    
    .benefits-grid {
        grid-template-columns: 1fr;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .feature-item {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .modal-content {
        margin: 10% auto;
        width: 95%;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 0.5rem;
    }
    
    .hero {
        padding: 6rem 0 4rem;
    }
    
    .hero-title {
        font-size: var(--font-size-2xl);
    }
    
    .btn-large {
        padding: 0.75rem 1.5rem;
        font-size: var(--font-size-base);
    }
    
    .stat-number {
        font-size: 3rem;
    }
    
    .problem-card,
    .benefit-card {
        padding: 1.5rem;
    }
}

/* === FIX fond qui remonte avec le 40% === */
.problem-section {
  position: relative;
  overflow: hidden; /* évite les débordements d'animation */
  background: var(--white);
}

.stat-highlight {
  position: relative;
  z-index: 2;
  animation: moveUp 1.2s ease-out forwards; /* animation de montée */
}

@keyframes moveUp {
  0% {
    transform: translateY(60px);
    opacity: 0;
  }
  100% {
    transform: translateY(0);
    opacity: 1;
  }
}

/* crée un fond blanc dynamique qui accompagne le mouvement */
.problem-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--white);
  z-index: 1;
  animation: bgFollow 1.2s ease-out forwards;
}

@keyframes bgFollow {
  0% {
    transform: translateY(60px);
  }
  100% {
    transform: translateY(0);
  }
}

/* garde le texte et les cartes au-dessus du fond */
.problem-section > * {
  position: relative;
  z-index: 3;
}
/* === FIX FINAL : fond dynamique qui suit les animations du 40%, sans rien casser === */

.problem-section {
  position: relative;
  background: var(--white);
  overflow: visible; /* conserve les animations qui débordent */
  z-index: 1;
}

/* le fond suit le mouvement global du contenu */
.problem-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--white);
  z-index: 0;
  transform: translateY(0);
  transition: transform 1s ease-out;
}

/* active une légère animation de fond quand le 40% apparaît */
@keyframes bgFollow {
  0% { transform: translateY(60px); opacity: 0.8; }
  100% { transform: translateY(0); opacity: 1; }
}

/* déclenche le fond qui “remonte” en même temps que le 40% */
.problem-section.animate::before {
  animation: bgFollow 1.2s ease-out forwards;
}

/* garde le texte et les éléments visibles au-dessus du fond */
.problem-section > * { position: relative; z-index: 2; }

/* si le 40% a déjà une animation, on la garde mais on la synchronise */
.stat-highlight {
  position: relative;
  z-index: 3;
  animation: fadeInUp 1.2s ease-out both;
}

/* animation légère déjà existante conservée */
@keyframes fadeInUp {
  0% { opacity: 0; transform: translateY(40px); }
  100% { opacity: 1; transform: translateY(0); }
}
