@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    overflow-x: clip;
}

[id] {
    scroll-margin-top: 96px;
}

/* Variables CSS modernes et professionnelles Micro-Clean */
:root {
    /* Identité */
    --blue: #7BAAD8;
    --green: #5EA942;

    /* Gradient hero */
    --hero-gradient: linear-gradient(135deg, #7BAAD8 0%, #5EA942 100%);
    --hero-gradient-light: linear-gradient(135deg, #EFF6FF 0%, #F0FDF4 100%);

    /* UI */
    --blue-dark: #5F8FB7;
    --blue-light: #E8F4FA;

    /* CTA = Button */
    --cta-bg: #5EA942;
    --cta-hover: #4C8A36;
    --cta-text: #FFFFFF;

    /* Neutres */
    --gray-light: #F5F5F5;
    --section-bg-alt: #F6FAFD; /* Bleu à peine perceptible, presque blanc */
    --text-main: #1A1A1A;
    --text-secondary: #4A4A4A;

    /* Aliases pour compatibilité */
    --primary: #7BAAD8;
    --secondary: #5EA942;
    --primary-dark: #5F8FB7;
    --primary-light: #E8F4FA;
    --secondary-dark: #4C8A36;
    --secondary-light: #DCFCE7;
    --accent: #5EA942;
    --accent-dark: #4C8A36;
    --accent-light: #DCFCE7;

    /* Neutres modernes */
    --background: #FFFFFF;
    --surface: #F8FAFC;
    --text-primary: #1A1A1A;
    --text-muted: #94A3B8;
    --border: #E2E8F0;

    /* Ombres modernes et subtiles */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.06);
    --shadow-xl: 0 24px 48px rgba(0, 0, 0, 0.07);

    /* Rayons modernes */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 14px;
    --radius-xl: 20px;

    /* Familles de polices */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-secondary: 'Manrope', 'Inter', sans-serif;
    --font-tertiary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Familles de polices */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--background);
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Titres avec hiérarchie appropriée */
h1 {
    font-size: clamp(2rem, 4.5vw, 2.75rem);
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 1rem;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

h2 {
    font-size: clamp(1.6rem, 3.2vw, 2.25rem);
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    letter-spacing: -0.01em;
}

h3 {
    font-size: clamp(1.15rem, 2.4vw, 1.6rem);
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

/* Contenu principal */
p {
    font-size: 18px;
    line-height: 1.7;
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
}

/* Boutons */
.btn-outline {
    background-color: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background-color: var(--primary-light);
    color: var(--primary-dark);
}

/* Boutons */
.btn {
    background-color: var(--cta-bg);
    color: var(--cta-text);
    padding: 12px 32px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 18px;
    font-weight: 600;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-block;
    text-align: center;
    text-decoration: none;
    box-shadow: var(--shadow-sm);
}

.btn:hover {
    background-color: var(--cta-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Container et grille */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Utilitaires d'espacement */
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mt-5 { margin-top: 3rem; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.mb-5 { margin-bottom: 3rem; }

.pt-1 { padding-top: 0.5rem; }
.pt-2 { padding-top: 1rem; }
.pt-3 { padding-top: 1.5rem; }
.pt-4 { padding-top: 2rem; }
.pt-5 { padding-top: 3rem; }

.pb-1 { padding-bottom: 0.5rem; }
.pb-2 { padding-bottom: 1rem; }
.pb-3 { padding-bottom: 1.5rem; }
.pb-4 { padding-bottom: 2rem; }
.pb-5 { padding-bottom: 3rem; }

/* Navigation */
nav {
    background: #FFFFFF;
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 0.9rem 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.08);
}

.nav-logo {
    display: flex;
    align-items: center;
}

.logo {
    height: 90px;
    width: auto;
    transition: opacity 0.3s ease;
}

.logo:hover {
    opacity: 0.8;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

nav ul {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin: 0;
    padding: 0;
}

nav a {
    text-decoration: none;
    color: #1F4E79;
    font-weight: 500;
    transition: color 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    position: relative;
    font-family: var(--font-primary);
}

nav a:hover {
    color: var(--blue-dark);
}

nav a.active {
    color: var(--blue-dark);
    font-weight: 600;
}

nav a:not(.nav-cta)::after {
    content: '';
    position: absolute;
    bottom: 2px;
    left: 12px;
    width: 0;
    height: 2px;
    background: var(--green);
    border-radius: 2px;
    transition: width 0.3s ease;
}

nav a:not(.nav-cta):hover::after,
nav a:not(.nav-cta).active::after {
    width: calc(100% - 24px);
}

nav a.nav-cta {
    padding: 10px 22px;
    border-radius: 999px;
    background-color: var(--cta-bg);
    color: #fff;
    font-weight: 600;
    box-shadow: 0 6px 16px rgba(188, 227, 255, 0.4);
    white-space: nowrap;
}

nav a.nav-cta:hover {
    background-color: var(--cta-hover);
    color: #fff;
}

@media (max-width: 720px) {
    nav a.nav-cta {
        display: none;
    }
}

@media (max-width: 1000px) {
    nav a.nav-section {
        display: none;
    }
}

/* Bouton hamburger */
.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0 10px;
}

.nav-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: #1A3A5C;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

@media (max-width: 768px) {
    nav {
        padding: 0.7rem 16px;
    }

    .logo {
        height: 60px;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-right {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #FFFFFF;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 8px 20px 20px;
        display: none;
        box-shadow: 0 20px 30px rgba(0, 0, 0, 0.25);
    }

    .nav-right ul {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
    }

    .nav-right ul li {
        width: 100%;
    }

    .nav-right ul li a {
        display: block;
        padding: 13px 0;
        font-size: 1.05rem;
        border-bottom: 1px solid rgba(13, 27, 42, 0.08);
    }

    .nav-right a.nav-section {
        display: block;
    }

    .nav-right a.nav-cta {
        display: inline-flex;
        margin-top: 16px;
        align-self: flex-start;
    }

    .nav-open .nav-right {
        display: flex;
    }

    .nav-open .nav-toggle span:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }

    .nav-open .nav-toggle span:nth-child(2) {
        opacity: 0;
    }

    .nav-open .nav-toggle span:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }
}

/* Footer */
footer {
    background-color: #cfe2f2;
    padding: 4rem 0;
    text-align: center;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
    text-align: left;
}

.footer-section h4 {
    color: #0D1B2A;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 0.75rem;
    font-family: var(--font-primary);
}

.footer-section p {
    color: #0D1B2A;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.footer-bottom {
    border-top: 1px solid rgba(13, 27, 42, 0.12);
    padding-top: 2rem;
    text-align: center;
}

.footer-bottom p {
    color: #0D1B2A;
    font-size: 14px;
    font-weight: 500;
}

.footer-bottom .footer-credits {
    margin-top: 0.75rem;
    font-size: 12px;
    font-weight: 400;
    color: #0D1B2A;
}

.footer-bottom .footer-credits a {
    color: #0D1B2A;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-bottom .footer-credits a:hover {
    color: #5F8FB7;
    text-decoration: none;
}

.footer-legal {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 0.5rem 1rem;
    max-width: 1200px;
    margin: 0 auto 2rem;
    padding: 0 20px;
    text-align: center;
}

.footer-legal a {
    color: #0D1B2A;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-legal a:hover {
    color: #5F8FB7;
    text-decoration: none;
}

.footer-legal span {
    color: #1A3A5C;
    opacity: 0.6;
    font-size: 14px;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeInUp 0.6s ease-out;
}

/* Utilitaires pour icônes */
.icon {
    width: 32px;
    height: 32px;
    display: inline-block;
    vertical-align: middle;
    margin-right: 0.5rem;
}

/* Utilitaires de texte */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.font-primary { font-family: var(--font-primary); }
.font-secondary { font-family: var(--font-secondary); }
.font-tertiary { font-family: var(--font-tertiary); }

.color-blue { color: var(--blue); }
.color-green { color: var(--green); }
.color-dark { color: var(--text-main); }
.color-secondary { color: var(--text-secondary); }

.bg-light { background-color: var(--gray-light); }
.bg-blue { background-color: var(--blue-light); }

.rounded-sm { border-radius: var(--radius-sm); }
.rounded-md { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }

/* Styles pour le logo */
.nav-logo {
    display: flex;
    align-items: center;
    margin-right: 1rem;
}

.footer-logo {
    height: 80px;
    width: auto;
    margin-bottom: 1rem;
    display: block;
    border: none;
    background: none;
    padding: 0;
    opacity: 0.95;
    transition: opacity 0.3s ease;
}

.footer-logo:hover {
    opacity: 0.8;
}

/* Style moderne pour tous les liens */
a {
    text-decoration: none;
    color: var(--blue);
    transition: all 0.3s ease;
    position: relative;
}

a:hover {
    color: var(--blue-dark);
}

a:not(.btn):not(nav a):not(.footer-section a):not(.footer-credits a):not(.footer-legal a)::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--blue);
    transition: width 0.3s ease;
}

a:not(.btn):not(nav a):not(.footer-section a):not(.footer-credits a):not(.footer-legal a):hover::after {
    width: 100%;
}

/* Footer links styling */
.footer-section a {
    color: #0D1B2A;
    text-decoration: none;
    transition: color 0.3s ease;
    padding: 0;
}

.footer-section a:hover {
    color: #5F8FB7;
    text-decoration: none;
}

.footer-section p {
    margin-bottom: 0.3rem;
    font-size: 14px;
    line-height: 1.6;
}

/* Image overlay pour la section hero */
.hero-image-wrapper {
    position: relative;
    display: block;
    max-width: 640px;
    margin: 2rem auto 0;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.hero-image-wrapper .image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

.hero-image-wrapper img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: var(--radius-lg);
}

/* Image overlays et services */
.service-image {
    position: relative;
    margin: 2rem 0;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.service-main-image {
    width: 100%;
    height: 300px;
    object-fit: cover;
    display: block;
}

.image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

.service-types {
    position: relative;
    margin: 3rem 0;
}

/* ============================================================================
   ALTERNATING SECTION BACKGROUNDS
   ============================================================================ */
main > section {
    position: relative;
    z-index: 1;
}

main > section:nth-child(even) {
    background-color: var(--section-bg-alt);
    box-shadow: 0 0 0 100vmax var(--section-bg-alt);
    clip-path: inset(0 -100vmax);
}

/* Dégradé animé (effet "aurora" premium) + grain subtil */
@keyframes gradientShift {
    0% { background-position: 0 0, 0% 50%; }
    50% { background-position: 0 0, 100% 50%; }
    100% { background-position: 0 0, 0% 50%; }
}

main .hero,
main .legal-hero,
main .contact-hero,
main .cta-gradient,
main .contact-cta {
    background-color: #5EA942;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.08'/%3E%3C/svg%3E"),
        linear-gradient(135deg, #7BAAD8 0%, #5EA942 50%, #7BAAD8 100%);
    background-size: 180px 180px, 200% 200%;
    background-repeat: repeat, no-repeat;
    background-position: 0 0, 0% 50%;
    animation: gradientShift 16s ease infinite;
}

@media (prefers-reduced-motion: reduce) {
    main .hero,
    main .legal-hero,
    main .contact-hero,
    main .cta-gradient,
    main .contact-cta {
        animation: none;
    }
}

/* Barre de progression du scroll */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0%;
    background: linear-gradient(90deg, var(--blue), var(--green));
    z-index: 3000;
}

/* Bouton retour en haut */
.back-to-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--cta-bg);
    color: #fff;
    border: none;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease, background-color 0.3s ease;
    z-index: 1500;
    display: flex;
    align-items: center;
    justify-content: center;
}

.back-to-top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: var(--cta-hover);
    transform: translateY(-2px);
}

/* Grain global subtil (film grain) */
body::after {
    content: '';
    position: fixed;
    inset: 0;
    z-index: 9999;
    pointer-events: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)'/%3E%3C/svg%3E");
    background-size: 160px 160px;
    opacity: 0.05;
}

/* Sections séparées par l'espace uniquement (pas de lignes) */

/* Ensure content inside sections doesn't get affected by z-index */
main > section > .container,
main > section > div,
main > section > * {
    position: relative;
    z-index: 2;
}

/* ============================================================================
   UNIFIED BUTTON/CTA STYLES
   ============================================================================ */
.btn {
    background-color: var(--cta-bg);
    color: var(--cta-text);
    padding: 14px 30px;
    border: none;
    border-radius: 999px;
    font-size: 1rem;
    font-weight: 600;
    font-family: var(--font-primary);
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-align: center;
    text-decoration: none;
    box-shadow: 0 8px 20px rgba(188, 227, 255, 0.4);
}

.btn::after {
    content: '→';
    transition: transform 0.3s ease;
}

.btn:hover::after {
    transform: translateX(4px);
}

.btn:hover,
.btn:focus {
    background-color: var(--cta-hover);
    color: var(--cta-text);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    outline: none;
}

.btn:active {
    transform: translateY(0);
    box-shadow: var(--shadow-sm);
}

/* Outline button variant */
.btn-outline {
    background-color: transparent;
    color: var(--cta-bg);
    border: 2px solid var(--cta-bg);
    padding: 12px 34px;
}

.btn-outline:hover,
.btn-outline:focus {
    background-color: var(--cta-bg);
    color: var(--cta-text);
    border-color: var(--cta-bg);
}

/* CTA Section */
.cta {
    background: var(--hero-gradient);
    color: white;
    padding: 4rem 2rem;
    border-radius: var(--radius-xl);
    text-align: center;
    margin: 3rem 0;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
}

.cta h2 {
    color: white;
    margin-bottom: 1rem;
    font-family: var(--font-primary);
}

.cta p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 1.5rem;
}

.cta .btn {
    background-color: white;
    color: var(--cta-bg);
    padding: 14px 36px;
}

.cta .btn:hover {
    background-color: var(--white, #FFFFFF);
    color: var(--cta-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}