/* =========================================================
   GABS SÉCURITÉ
   STYLE PROFESSIONNEL
   ========================================================= */

:root {
    --bleu-fonce: #071827;
    --bleu: #0c2438;
    --bleu-clair: #123d5c;
    --or: #c9a227;
    --or-clair: #e2c45d;
    --blanc: #ffffff;
    --gris-clair: #f4f6f8;
    --gris: #667085;
    --texte: #1d2939;
    --bordure: #e4e7ec;
    --ombre: 0 15px 40px rgba(7, 24, 39, 0.10);
    --transition: all 0.3s ease;
}


/* =========================================================
   RESET
   ========================================================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Segoe UI", Arial, sans-serif;
    color: var(--texte);
    background: var(--blanc);
    line-height: 1.6;
}

a {
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

button,
input,
textarea {
    font-family: inherit;
}


/* =========================================================
   HEADER
   ========================================================= */

header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;

    background: rgba(7, 24, 39, 0.96);
    backdrop-filter: blur(10px);

    border-bottom: 1px solid rgba(255, 255, 255, 0.08);

    transition: var(--transition);
}

header.scrolled {
    background: rgba(7, 24, 39, 0.99);
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.20);
}

nav {
    width: min(1400px, 92%);
    height: 78px;
    margin: auto;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}


/* =========================================================
   LOGO
   ========================================================= */

.logo {
    color: var(--blanc);
    font-size: 23px;
    font-weight: 800;
    letter-spacing: 0.5px;
    white-space: nowrap;

    position: relative;
    padding-left: 34px;
}

.logo::before {
    content: "🛡";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);

    color: var(--or-clair);
    font-size: 23px;
}


/* =========================================================
   MENU
   ========================================================= */

nav ul {
    display: flex;
    align-items: center;
    gap: 35px;

    list-style: none;
}

nav ul li a {
    color: #e8edf2;
    font-size: 14px;
    font-weight: 500;

    position: relative;
    transition: var(--transition);
}

nav ul li a::after {
    content: "";
    position: absolute;

    left: 0;
    bottom: -8px;

    width: 0;
    height: 2px;

    background: var(--or);
    transition: var(--transition);
}

nav ul li a:hover {
    color: var(--or-clair);
}

nav ul li a:hover::after {
    width: 100%;
}


/* =========================================================
   AUTHENTIFICATION
   ========================================================= */

.auth-buttons {
    display: flex;
    align-items: center;
    gap: 12px;
}

.connexion-link {
    color: var(--blanc);
    font-size: 14px;
    font-weight: 600;

    padding: 10px 14px;

    transition: var(--transition);
}

.connexion-link:hover {
    color: var(--or-clair);
}


/* =========================================================
   BOUTON PRINCIPAL
   ========================================================= */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    background: var(--or);
    color: var(--bleu-fonce);

    padding: 13px 23px;

    border-radius: 6px;

    font-size: 14px;
    font-weight: 700;

    border: 1px solid var(--or);

    cursor: pointer;

    transition: var(--transition);
}

.btn:hover {
    background: var(--or-clair);
    border-color: var(--or-clair);

    transform: translateY(-2px);

    box-shadow: 0 8px 20px rgba(201, 162, 39, 0.25);
}


/* =========================================================
   HERO
   ========================================================= */

/* =========================================================
   CORRECTION VISIBILITÉ DU HERO
   ========================================================= */

.hero {
    position: relative;
    isolation: isolate;

    background:
        url("agent.webp")
        center center / cover no-repeat;
}

/* Voile sombre uniquement sur l'image */
.hero::before {
    content: "";
    position: absolute;
    inset: 0;

    background:
        linear-gradient(
            90deg,
            rgba(4, 17, 29, 0.88) 0%,
            rgba(4, 17, 29, 0.68) 45%,
            rgba(4, 17, 29, 0.20) 100%
        );

    z-index: -1;
}


/* =========================================================
   TEXTE DU HERO
   ========================================================= */

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-label {
    color: #e2c45d !important;

    font-size: 15px;
    font-weight: 700;

    letter-spacing: 2px;

    text-shadow:
        0 2px 5px rgba(0, 0, 0, 0.7);
}

.hero-content h1 {
    color: #ffffff !important;

    font-size: clamp(44px, 6vw, 72px);

    line-height: 1.08;

    font-weight: 800;

    text-shadow:
        0 3px 10px rgba(0, 0, 0, 0.65);
}

.hero-content p {
    color: #ffffff !important;

    font-size: 19px;

    line-height: 1.7;

    max-width: 680px;

    text-shadow:
        0 2px 7px rgba(0, 0, 0, 0.8);
}


/* =========================================================
   BOUTONS HERO
   ========================================================= */

.hero-buttons {
    display: flex;

    align-items: center;

    gap: 15px;

    margin-top: 30px;
}

.hero-buttons .btn {
    background: #d4af37 !important;

    color: #071827 !important;

    border: 1px solid #d4af37 !important;

    font-weight: 700;

    box-shadow:
        0 6px 20px rgba(0, 0, 0, 0.25);
}

.hero-buttons .btn:hover {
    background: #e2c45d !important;

    color: #071827 !important;
}


/* Bouton Demander un devis */

.hero-buttons .btn-outline {
    display: inline-flex;

    align-items: center;

    justify-content: center;

    gap: 9px;

    padding: 13px 23px;

    color: #ffffff !important;

    background: rgba(7, 24, 39, 0.35) !important;

    border: 1px solid rgba(255, 255, 255, 0.75) !important;

    border-radius: 6px;

    font-size: 14px;

    font-weight: 700;

    text-shadow:
        0 2px 5px rgba(0, 0, 0, 0.7);

    transition: all 0.3s ease;
}

.hero-buttons .btn-outline:hover {
    background: #ffffff !important;

    color: #071827 !important;

    text-shadow: none;

    transform: translateY(-2px);
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 700px) {

    .hero-content h1 {
        color: #ffffff !important;

        font-size: 40px;
    }

    .hero-content p {
        color: #ffffff !important;

        font-size: 16px;
    }

    .hero-buttons {
        flex-direction: column;

        width: 100%;
    }

    .hero-buttons .btn,
    .hero-buttons .btn-outline {
        width: 100%;
    }
}


/* =========================================================
   SECTIONS GÉNÉRALES
   ========================================================= */

section {
    padding: 100px 7%;
}

section h2 {
    color: var(--bleu-fonce);

    font-size: 38px;

    line-height: 1.2;

    text-align: center;

    margin-bottom: 18px;

    font-weight: 800;
}

.section-description {
    max-width: 750px;

    margin: 0 auto 45px;

    text-align: center;

    color: var(--gris);

    font-size: 16px;
}


/* =========================================================
   À PROPOS
   ========================================================= */

#apropos {
    background: var(--blanc);

    text-align: center;
}

#apropos > p {
    max-width: 850px;

    margin: 0 auto;

    color: var(--gris);

    font-size: 17px;

    line-height: 1.8;
}


/* =========================================================
   IMAGE À PROPOS
   ========================================================= */

.apropos-image {
    width: 100%;

    max-width: 1400px;

    margin: 50px auto 0;

    position: relative;

    overflow: hidden;

    border-radius: 14px;

    box-shadow: var(--ombre);
}

.apropos-image::after {
    content: "";

    position: absolute;

    inset: 0;

    background:
        linear-gradient(
            90deg,
            rgba(7, 24, 39, 0.18),
            transparent
        );

    pointer-events: none;
}

.apropos-image img {
    width: 100%;

    height: 500px;

    object-fit: cover;

    transition: transform 0.7s ease;
}

.apropos-image:hover img {
    transform: scale(1.03);
}


/* =========================================================
   SERVICES
   ========================================================= */

.services {
    background: var(--gris-clair);
}

.cards {
    width: min(1250px, 100%);

    margin: 0 auto;

    display: grid;

    grid-template-columns:
        repeat(3, 1fr);

    gap: 25px;
}


/* =========================================================
   CARTE
   ========================================================= */

.card {
    background: var(--blanc);

    border: 1px solid var(--bordure);

    border-radius: 12px;

    padding: 35px 28px;

    text-align: center;

    box-shadow: 0 5px 20px rgba(7, 24, 39, 0.05);

    position: relative;

    transition: var(--transition);
}

.card::before {
    content: "";

    position: absolute;

    top: 0;
    left: 0;

    width: 100%;
    height: 3px;

    background: var(--or);

    transform: scaleX(0);

    transform-origin: center;

    transition: var(--transition);
}

.card:hover {
    transform: translateY(-8px);

    box-shadow: var(--ombre);

    border-color: rgba(201, 162, 39, 0.35);
}

.card:hover::before {
    transform: scaleX(1);
}


/* =========================================================
   ICÔNES
   ========================================================= */

.card > i {
    width: 65px;
    height: 65px;

    margin: 0 auto 22px;

    display: flex;

    align-items: center;
    justify-content: center;

    background: rgba(201, 162, 39, 0.12);

    color: var(--or);

    border-radius: 50%;

    font-size: 27px;

    transition: var(--transition);
}

.card:hover > i {
    background: var(--bleu);

    color: var(--or-clair);

    transform: scale(1.08);
}

.card h3 {
    color: var(--bleu-fonce);

    font-size: 20px;

    margin-bottom: 14px;
}

.card p {
    color: var(--gris);

    font-size: 14px;

    line-height: 1.7;

    margin-bottom: 25px;
}


/* =========================================================
   BOUTON DES CARTES
   ========================================================= */

.card-btn {
    display: inline-flex;

    align-items: center;

    gap: 7px;

    color: var(--bleu);

    font-size: 14px;

    font-weight: 700;

    transition: var(--transition);
}

.card-btn::after {
    content: "→";

    font-size: 17px;

    transition: var(--transition);
}

.card-btn:hover {
    color: var(--or);
}

.card-btn:hover::after {
    transform: translateX(5px);
}


/* =========================================================
   FORMATIONS
   ========================================================= */

.card-formations {
    grid-column: span 3;

    padding: 40px;
}

.card-formations > i {
    background: var(--bleu);
    color: var(--or-clair);
}

.formation-links {
    max-width: 900px;

    margin: 25px auto;

    display: grid;

    grid-template-columns: repeat(4, 1fr);

    gap: 12px;
}

.formation-btn {
    min-height: 90px;

    padding: 15px;

    display: flex;

    flex-direction: column;

    align-items: center;
    justify-content: center;

    gap: 8px;

    border: 1px solid var(--bordure);

    border-radius: 8px;

    background: #fafbfc;

    color: var(--bleu);

    font-size: 13px;

    font-weight: 600;

    transition: var(--transition);
}

.formation-btn i {
    color: var(--or);

    font-size: 22px;
}

.formation-btn:hover {
    background: var(--bleu);

    color: var(--blanc);

    border-color: var(--bleu);

    transform: translateY(-3px);
}

.formation-btn:hover i {
    color: var(--or-clair);
}


/* =========================================================
   ENGAGEMENTS
   ========================================================= */

.stats {
    background:
        linear-gradient(
            135deg,
            var(--bleu-fonce),
            var(--bleu)
        );

    color: var(--blanc);

    position: relative;
}

.stats h2 {
    color: var(--blanc);
}

.stat-box {
    max-width: 1050px;

    margin: 45px auto 0;

    display: grid;

    grid-template-columns: repeat(3, 1fr);

    gap: 0;

    background: rgba(255, 255, 255, 0.04);

    border: 1px solid rgba(255, 255, 255, 0.10);

    border-radius: 12px;

    overflow: hidden;
}

.stat-box > div {
    text-align: center;

    padding: 40px 25px;

    border-right: 1px solid rgba(255, 255, 255, 0.10);
}

.stat-box > div:last-child {
    border-right: none;
}

.stat-box strong {
    display: block;

    color: var(--or-clair);

    font-size: 36px;

    font-weight: 800;

    margin-bottom: 8px;
}

.stat-box p {
    color: #d5dde5;

    font-size: 14px;
}


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

#contact {
    background: var(--gris-clair);
}

#contact form {
    width: min(700px, 100%);

    margin: 40px auto 0;

    background: var(--blanc);

    padding: 35px;

    border-radius: 12px;

    box-shadow: var(--ombre);
}

#contact input,
#contact textarea {
    width: 100%;

    border: 1px solid var(--bordure);

    border-radius: 7px;

    padding: 14px 15px;

    margin-bottom: 15px;

    font-size: 14px;

    color: var(--texte);

    outline: none;

    transition: var(--transition);
}

#contact input {
    height: 48px;
}

#contact textarea {
    min-height: 150px;

    resize: vertical;
}

#contact input:focus,
#contact textarea:focus {
    border-color: var(--or);

    box-shadow:
        0 0 0 3px rgba(201, 162, 39, 0.10);
}

#contact form .btn {
    width: 100%;

    margin-top: 5px;
}


/* =========================================================
   FOOTER
   ========================================================= */

footer {
    background: #04111d;

    color: #aeb9c4;

    text-align: center;

    padding: 50px 20px 30px;
}

footer h3 {
    color: var(--blanc);

    font-size: 22px;

    margin-bottom: 10px;
}

footer h3::before {
    content: "🛡 ";

    color: var(--or);
}

footer p {
    font-size: 13px;

    margin-bottom: 8px;
}

footer p:last-child {
    color: #778594;

    margin-top: 25px;

    padding-top: 20px;

    border-top: 1px solid rgba(255, 255, 255, 0.08);
}


/* =========================================================
   ANIMATIONS
   ========================================================= */

section {
    opacity: 0;

    transform: translateY(30px);

    transition:
        opacity 0.7s ease,
        transform 0.7s ease;
}

section.visible {
    opacity: 1;

    transform: translateY(0);
}

.card {
    opacity: 0;

    transform: translateY(25px);

    transition:
        opacity 0.6s ease,
        transform 0.6s ease,
        box-shadow 0.3s ease;
}

.card.card-visible {
    opacity: 1;

    transform: translateY(0);
}


/* =========================================================
   RESPONSIVE TABLETTE
   ========================================================= */

@media (max-width: 1000px) {

    nav {
        width: 94%;
    }

    nav ul {
        gap: 20px;
    }

    .cards {
        grid-template-columns: repeat(2, 1fr);
    }

    .card-formations {
        grid-column: span 2;
    }

    .formation-links {
        grid-template-columns: repeat(2, 1fr);
    }

    .hero-content h1 {
        font-size: 55px;
    }
}


/* =========================================================
   RESPONSIVE MOBILE
   ========================================================= */

@media (max-width: 700px) {

    nav {
        height: auto;

        min-height: 70px;

        padding: 12px 0;

        flex-wrap: wrap;

        justify-content: center;
    }

    .logo {
        width: 100%;

        text-align: center;

        padding-left: 0;
    }

    .logo::before {
        display: none;
    }

    nav ul {
        width: 100%;

        justify-content: center;

        gap: 16px;

        flex-wrap: wrap;
    }

    nav ul li a {
        font-size: 12px;
    }

    .auth-buttons {
        width: 100%;

        justify-content: center;
    }

    .connexion-link {
        font-size: 13px;
    }

    .auth-buttons .btn {
        padding: 9px 14px;

        font-size: 12px;
    }


    /* HERO */

    .hero {
        min-height: 800px;

        background-position: center;
    }

    .hero-content {
        padding-top: 120px;

        text-align: center;
    }

    .hero-content h1 {
        font-size: 40px;

        letter-spacing: -0.8px;
    }

    .hero-content p {
        font-size: 16px;
    }


    /* SECTIONS */

    section {
        padding: 70px 5%;
    }

    section h2 {
        font-size: 30px;
    }


    /* ABOUT */

    .apropos-image img {
        height: 300px;
    }


    /* SERVICES */

    .cards {
        grid-template-columns: 1fr;
    }

    .card-formations {
        grid-column: span 1;

        padding: 30px 20px;
    }

    .formation-links {
        grid-template-columns: 1fr;
    }


    /* STATS */

    .stat-box {
        grid-template-columns: 1fr;
    }

    .stat-box > div {
        border-right: none;

        border-bottom:
            1px solid rgba(255, 255, 255, 0.10);
    }

    .stat-box > div:last-child {
        border-bottom: none;
    }


    /* CONTACT */

    #contact form {
        padding: 25px 20px;
    }
}


/* =========================================================
   PETITS ÉCRANS
   ========================================================= */

@media (max-width: 400px) {

    .hero-content h1 {
        font-size: 34px;
    }

    nav ul {
        gap: 10px;
    }

    .connexion-link {
        padding: 7px;
    }
    .hero-label {
    display: inline-flex;
    align-items: center;
    gap: 9px;

    color: var(--or-clair);

    font-size: 14px;
    font-weight: 700;

    letter-spacing: 2px;

    margin-bottom: 20px;
}

.hero-label i {
    font-size: 18px;
}

.hero-buttons {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 9px;

    padding: 13px 23px;

    border: 1px solid rgba(255, 255, 255, 0.55);
    border-radius: 6px;

    color: white;

    font-size: 14px;
    font-weight: 600;

    transition: all 0.3s ease;
}

.btn-outline:hover {
    background: white;
    color: var(--bleu-fonce);

    transform: translateY(-2px);
}
}