/* ====================================================================
   Logo et Header avec Images AEZ
   Optimisation pour aez_logo.jpeg et couverture.png
   ==================================================================== */

/* ==================== Logo Image dans Navbar ==================== */

.navbar-brand {
    padding: 0.5rem 1.5rem !important;
    transition: all 0.3s ease;
}

.navbar-brand img {
    height: 50px;
    width: auto;
    max-width: 100%;
    transition: all 0.3s ease;
    filter: brightness(1);
}

/* Effet hover sur le logo */
.navbar-brand:hover img {
    transform: scale(1.05);
    filter: brightness(1.1);
}

/* Badge sur le logo */
.navbar-brand::after {
    content: '✓';
    position: absolute;
    top: -6px;
    right: -6px;
    width: 24px;
    height: 24px;
    background: linear-gradient(135deg, rgb(214, 64, 0) 0%, rgb(255, 87, 34) 100%);
    color: white;
    border-radius: 50%;
    font-size: 14px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(214, 64, 0, 0.4);
    animation: pulse-badge 2s ease-in-out infinite;
    z-index: 10;
}

@keyframes pulse-badge {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* ==================== Header avec couverture.png ==================== */

/* L'image couverture.png est déjà très complète, donc on réduit l'overlay */
.hero-header {
    min-height: 450px !important;
    position: relative;
    background-size: cover !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
}

/* Overlay très léger pour ne pas masquer l'image */
.hero-header::before,
.hero-header::after {
    display: none !important;
}

/* Zone de contenu centrée en bas */
.hero-header .container {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: 400px;
}

/* Ajuster le texte pour ne pas interférer avec l'image */
.hero-header h1,
.hero-header p {
    background: rgba(255, 255, 255, 0.95);
    padding: 1rem 2rem;
    border-radius: 0.75rem;
    color: #1F2937 !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(10px);
}

.hero-header h1 {
    display: inline-block;
    margin-bottom: 1rem !important;
}

.hero-header p {
    display: inline-block;
    margin-bottom: 1.5rem !important;
}

/* Boutons avec fond pour visibilité */
.hero-header .btn {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2) !important;
}

/* ==================== Alternative: Header sans texte ==================== */

/* Si vous voulez laisser juste l'image couverture.png parler */
/*
.hero-header h1,
.hero-header p,
.hero-header .btn,
.hero-header small {
    display: none;
}

.hero-header {
    min-height: 500px !important;
}
*/

/* ==================== Responsive ==================== */

@media (max-width: 991px) {
    .navbar-brand img {
        height: 40px;
    }

    .navbar-brand::after {
        width: 20px;
        height: 20px;
        font-size: 12px;
    }

    .hero-header {
        min-height: 350px !important;
    }

    .hero-header .container {
        min-height: 300px;
    }

    .hero-header h1 {
        font-size: 1.75rem !important;
        padding: 0.75rem 1.5rem;
    }

    .hero-header p {
        font-size: 1rem !important;
        padding: 0.75rem 1.5rem;
    }
}

@media (max-width: 575px) {
    .navbar-brand img {
        height: 35px;
    }

    .navbar-brand::after {
        display: none;
    }

    .hero-header {
        min-height: 300px !important;
    }

    .hero-header h1 {
        font-size: 1.5rem !important;
        padding: 0.5rem 1rem;
    }

    .hero-header p {
        font-size: 0.9375rem !important;
        padding: 0.5rem 1rem;
    }

    .hero-header .btn {
        padding: 0.625rem 1.25rem !important;
        font-size: 0.875rem !important;
    }
}

/* ==================== Optimisation Image Couverture ==================== */

/* L'image couverture.png contient déjà du texte et des infos */
/* On peut réduire le contenu textuel du header pour éviter la redondance */

.hero-header-minimal h1 {
    font-size: 2rem !important;
}

.hero-header-minimal p {
    display: none; /* Cache le paragraphe si redondant avec l'image */
}

/* ==================== Logo Loading ==================== */

.navbar-brand img {
    /* Optimisation du chargement */
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

/* Placeholder pendant le chargement */
.navbar-brand {
    min-height: 50px;
    background: #f8f9fa;
    border-radius: 0.5rem;
}

/* ==================== Print Styles ==================== */

@media print {
    .navbar-brand img {
        height: 40px;
    }

    .navbar-brand::after {
        display: none;
    }
}

/* ==================== Accessibility ==================== */

.navbar-brand img {
    /* Alt text important pour l'accessibilité */
    max-width: 100%;
    height: auto;
}

.navbar-brand:focus {
    outline: 2px solid rgb(214, 64, 0);
    outline-offset: 2px;
}

/* ==================== Animation d'entrée du logo ==================== */

@keyframes logoFadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.navbar-brand img {
    animation: logoFadeIn 0.6s ease-out;
}

/* ==================== Hero Header - Version Simple ==================== */

/* Pour laisser l'image couverture.png être la vedette */
.hero-simple {
    min-height: 400px !important;
    padding: 2rem 0 !important;
}

.hero-simple .container {
    min-height: 350px;
    justify-content: center;
}

/* Juste les boutons en bas */
.hero-simple h1,
.hero-simple p {
    display: none;
}

.hero-simple .btn {
    margin-top: auto;
}
