/* ========================================
   VARIABLES CSS (Thème clair par défaut)
   ======================================== */
:root {
    --primary-dark: #0A2F44;
    --primary-green: #1E7A5E;
    --secondary-beige: #F4F1E1;
    --accent-orange: #E67E22;
    --accent-blue: #3498db;
    --text-dark: #1a2a3a;
    --text-light: #5a6e7a;
    --text-white: #ffffff;
    --bg-light: #ffffff;
    --bg-gray: #f8f9fa;
    --shadow: 0 10px 30px rgba(0,0,0,0.08);
    --shadow-hover: 0 20px 40px rgba(0,0,0,0.12);
    --border-radius: 16px;
    --transition: all 0.3s ease;
}

/* Dark mode variables */
[data-theme="dark"] {
    --primary-dark: #1a3a4a;
    --primary-green: #2a9d8f;
    --secondary-beige: #2a2a2a;
    --accent-orange: #f4a261;
    --text-dark: #e0e0e0;
    --text-light: #b0b0b0;
    --bg-light: #1e1e2e;
    --bg-gray: #2a2a3a;
    --shadow: 0 10px 30px rgba(0,0,0,0.3);
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: 'Lora', serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.7;
    transition: var(--transition);
}

h1, h2, h3, h4, .nav-brand, .btn, .kpi-card, .stat-card {
    font-family: 'Poppins', sans-serif;
}

/* Skip link */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--accent-orange);
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    z-index: 1000;
}
.skip-link:focus { top: 0; }

/* ========== NAVIGATION ========== */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--bg-light);
    box-shadow: var(--shadow);
    z-index: 1000;
    transition: var(--transition);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-green);
}
.nav-brand i { margin-right: 8px; color: var(--accent-orange); }

.nav-menu {
    display: flex;
    gap: 2rem;
    list-style: none;
}
.nav-menu a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    transition: var(--transition);
}
.nav-menu a:hover { color: var(--accent-orange); }

.dark-mode-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    color: var(--text-dark);
    padding: 8px;
    border-radius: 50%;
    transition: var(--transition);
}
.dark-mode-btn:hover { background: var(--bg-gray); }

.nav-toggle { display: none; background: none; border: none; font-size: 1.5rem; cursor: pointer; color: var(--text-dark); }

/* ========== HERO ========== */
.hero {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-green) 100%);
    color: white;
    padding: 120px 2rem 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    animation: fadeInUp 0.8s ease;
}
.hero h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    animation: fadeInUp 0.8s ease 0.1s both;
}
.hero-subtitle {
    font-size: 1.3rem;
    opacity: 0.95;
    margin-bottom: 2rem;
    animation: fadeInUp 0.8s ease 0.2s both;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 4rem;
    margin: 2rem 0;
    flex-wrap: wrap;
}
.hero-stat {
    text-align: center;
    animation: fadeInUp 0.8s ease 0.3s both;
}
.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    display: block;
}
.stat-label { font-size: 0.9rem; opacity: 0.9; }

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 2rem;
}
.btn {
    padding: 12px 28px;
    border-radius: 40px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.btn-primary {
    background: var(--accent-orange);
    color: white;
}
.btn-primary:hover { background: #d35400; transform: translateY(-2px); }
.btn-secondary {
    background: transparent;
    border: 2px solid white;
    color: white;
}
.btn-secondary:hover { background: white; color: var(--primary-dark); }

.hero-wave svg { position: absolute; bottom: 0; left: 0; width: 100%; }

/* ========== MAIN LAYOUT ========== */
main {
    max-width: 1400px;
    margin: 3rem auto;
    padding: 0 2rem;
    display: flex;
    gap: 2rem;
}

.toc {
    width: 280px;
    position: sticky;
    top: 100px;
    height: fit-content;
    background: var(--bg-gray);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
}
.toc-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 1rem;
    font-weight: 600;
}
.toc-list {
    list-style: none;
}
.toc-list li { margin-bottom: 0.75rem; }
.toc-list a {
    text-decoration: none;
    color: var(--text-light);
    font-size: 0.9rem;
    transition: var(--transition);
}
.toc-list a:hover { color: var(--accent-orange); padding-left