/* ============================================
   STYLES POUR LA PAGE D'ACCUEIL
   ============================================ */

/* CORRECTION : Styles pour stabiliser le menu de navigation */
.nav-bar {
    position: relative;
    z-index: 1000;
}

.navbar-nav .nav-item.dropdown {
    position: relative;
}

.navbar-nav .dropdown-menu {
    border: none;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    margin-top: 0;
    border-radius: 0 0 5px 5px;
}

/* Éviter les transitions problématiques */
.navbar-nav .nav-link-responsive {
    transition: all 0.2s ease !important;
}

/* Correction spécifique pour le hover sur desktop */
@media (min-width: 992px) {
    .navbar-nav .nav-item.dropdown:hover .dropdown-menu {
        display: block;
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }
    
    .navbar-nav .dropdown-menu {
        display: block;
        opacity: 0;
        visibility: hidden;
        transform: translateY(10px);
        transition: all 0.3s ease;
    }
    
    .nav-link-responsive:hover {
        background-color: rgba(255,255,255,0.1) !important;
        transform: none !important;
    }
}

/* Styles pour mobile */
@media (max-width: 991px) {
    .navbar-nav .dropdown-menu {
        position: static !important;
        transform: none !important;
        float: none;
        width: 100%;
    }
    
    .nav-item.dropdown.show .dropdown-menu {
        display: block !important;
    }
}

/* Désactiver les transitions problématiques */
.navbar-collapse {
    transition: none !important;
}

.navbar-toggler {
    border: none;
    padding: 4px 8px;
}

.navbar-toggler:focus {
    outline: none;
    box-shadow: none;
}

/* --- NAVIGATION RESPONSIVE --- */
.navbar-brand {
    font-size: 0.8rem !important;
}

.nav-link-responsive {
    font-size: 0.75rem !important;
    white-space: nowrap;
    padding: 8px 4px !important;
    transition: all 0.3s ease;
}

.dropdown-menu {
    border: none;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    border-radius: 8px;
}

.dropdown-item {
    font-size: 0.75rem;
    padding: 8px 15px;
    white-space: normal;
}

.nav-register-btn {
    background-color: white;
    border-radius: 4px;
    padding: 0 !important;
    margin-left: 10px;
}

.nav-register-btn .nav-link {
    color: black !important;
    padding: 8px 15px !important;
    font-size: 0.75rem;
}

/* --- SECTIONS PRINCIPALES --- */
.section-title {
    color: #1B1464;
    font-weight: 700;
    margin-bottom: 30px;
    text-align: center;
}

.section-title-alt {
    color: #1B1464;
    font-weight: 700;
    margin-bottom: 40px;
    text-align: center;
    padding-bottom: 15px;
    border-bottom: 3px solid #FF9A12;
}

/* --- CONTENU SIMPLIFIÉ --- */
.content-section {
    background: white;
    padding: 50px 0;
}

.simple-text {
    color: #555;
    line-height: 1.8;
    font-size: 1rem;
    text-align: justify;
    margin-bottom: 25px;
}

.content-title {
    color: #1B1464;
    font-weight: 600;
    margin-bottom: 20px;
    font-size: 1.5rem;
}

.content-subtitle {
    color: #1B1464;
    font-weight: 600;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

/* --- CARTES SIMPLES --- */
.simple-card {
    background: white;
    padding: 30px 20px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    height: 100%;
    transition: transform 0.3s ease;
}

.simple-card:hover {
    transform: translateY(-5px);
}

/* --- FORMATIONS CQP --- */
.formation-card {
    background: white;
    padding: 30px;
    margin-bottom: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

.formation-badge {
    background: #FF9A12;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    display: inline-block;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 15px;
}

.formation-list {
    color: #555;
    padding-left: 20px;
    line-height: 1.8;
}

.formation-list li {
    margin-bottom: 10px;
}

/* --- BOOTCAMPS --- */
.bootcamp-section {
    margin-bottom: 40px;
}

.bootcamp-title {
    color: #1B1464;
    font-weight: 600;
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.bootcamp-text {
    color: #555;
    line-height: 1.8;
    margin-bottom: 15px;
}

.program-day {
    color: #555;
    margin-bottom: 10px;
    padding-left: 20px;
}

.program-day strong {
    color: #1B1464;
}

/* --- ENTREPRISES --- */
.enterprise-offer {
    margin-bottom: 30px;
}

.offer-title {
    color: #1B1464;
    font-weight: 600;
    margin-bottom: 10px;
    font-size: 1.2rem;
}

.offer-description {
    color: #555;
    line-height: 1.8;
    margin-bottom: 10px;
}

.highlight-box {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 8px;
    margin-bottom: 20px;
}

/* --- BOUTONS --- */
.btn-primary-custom {
    background: #1B1464;
    border: none;
    border-radius: 25px;
    padding: 12px 40px;
    font-weight: 600;
    color: white;
    text-decoration: none;
    display: inline-block;
    transition: transform 0.3s ease;
}

.btn-primary-custom:hover {
    transform: translateY(-2px);
    color: white;
}

/* --- ANIMATIONS --- */
@keyframes fadeIn {
    from { 
        opacity: 0; 
        transform: translateY(-10px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

.dropdown-menu {
    animation: fadeIn 0.3s ease;
}

/* --- NAVBAR TOGGLER --- */
.navbar-toggler {
    border: 1px solid rgba(255,255,255,0.3);
    padding: 4px 8px;
}

.navbar-toggler-icon {
    width: 1.2em;
    height: 1.2em;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

/* --- GRANDS ÉCRANS (min 1400px) --- */
@media (min-width: 1400px) {
    .nav-link-responsive {
        font-size: 0.8rem !important;
        padding: 10px 15px !important;
    }
    
    .navbar-brand {
        font-size: 0.7rem !important;
    }
}

/* --- ÉCRANS MOYENS (max 1199px) --- */
@media (max-width: 1199px) {
    .nav-link-responsive {
        font-size: 0.8rem !important;
        padding: 6px 2px !important;
    }
    
    .dropdown-item {
        font-size: 0.7rem;
        padding: 6px 12px;
    }
}

/* --- TABLETTES (max 991px) --- */
@media (max-width: 991px) {
    .navbar-collapse {
        background: #fff;
        padding: 15px;
        margin-top: 10px;
        border-radius: 8px;
    }
    
    .nav-link-responsive {
        font-size: 0.9rem;
        padding: 10px 15px !important;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        white-space: normal;
    }
    
    .nav-link-responsive:last-child {
        border-bottom: none;
    }
    
    .dropdown-menu {
        background: #495057;
        margin: 5px 0;
        border-left: 3px solid #FF9A12;
    }
    
    .dropdown-item {
        color: #fff !important;
        font-size: 0.85rem;
        padding: 8px 20px;
        border-bottom: 1px solid rgba(255,255,255,0.05);
    }
    
    .dropdown-item:hover {
        background: #FF9A12;
        color: #000 !important;
    }
    
    .nav-register-btn {
        margin: 15px 0 0 0;
        text-align: center;
    }
    
    .nav-register-btn .nav-link {
        display: block;
        font-size: 0.9rem;
        padding: 12px 20px !important;
    }
    
    .agrement.hide-desktop {
        display: block !important;
        text-align: center;
        margin-bottom: 10px;
    }
}

/* --- MOBILES (max 767px) --- */
@media (max-width: 767px) {
    .nav-link-responsive {
        font-size: 0.85rem;
        padding: 12px 15px !important;
    }
    
    .dropdown-item {
        font-size: 0.8rem;
        padding: 10px 25px;
    }
    
    .navbar-brand {
        font-size: 0.75rem !important;
        text-align: center;
        display: block;
    }
    
    .agrement.hide-desktop p {
        font-size: 0.8rem;
        margin-bottom: 5px !important;
    }
    
    .content-section {
        padding: 30px 0;
    }
    
    .simple-card {
        padding: 20px 15px;
    }
    
    .formation-card {
        padding: 20px;
    }
}

/* --- PETITS MOBILES (max 575px) --- */
@media (max-width: 575px) {
    .nav-link-responsive {
        font-size: 0.8rem;
        padding: 10px 12px !important;
    }
    
    .dropdown-item {
        font-size: 0.75rem;
        padding: 8px 20px;
    }
    
    .navbar-brand {
        font-size: 0.7rem !important;
    }
    
    .nav-register-btn .nav-link {
        font-size: 0.85rem;
        padding: 10px 15px !important;
    }
    
    .btn-primary-custom {
        padding: 10px 30px;
        font-size: 0.9rem;
    }
}

/* --- TRÈS PETITS ÉCRANS (max 400px) --- */
@media (max-width: 400px) {
    .nav-link-responsive {
        font-size: 0.75rem;
        padding: 8px 10px !important;
    }
    
    .navbar-brand {
        font-size: 0.65rem !important;
    }
    
    .agrement.hide-desktop p {
        font-size: 0.75rem;
    }
}

  /* ==== SECTION INTRO (style Alpha Digital) ==== */
    .intro-section {
        background-color: #ffffff;
        overflow: hidden;
    }

    .intro-title {
        font-size: 2.8rem;
        font-weight: 800;
        color: #1B1464;
        line-height: 1.2;
    }

    .intro-title span {
        color: #FF9A12;
    }

    .intro-image {
        width: 100%;
        max-width: 500px;
        border-radius: 12px;
        object-fit: cover;
        box-shadow: 0 6px 25px rgba(0,0,0,0.15);
        transition: transform 0.4s ease, box-shadow 0.4s ease;
    }

    .intro-image:hover {
        transform: scale(1.03);
        box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    }

    .content-text p {
        font-size: 1.1rem;
        line-height: 1.8;
        color: #444;
        margin-bottom: 20px;
        text-align: justify;
    }

    .director-name {
        text-align: center;
        padding: 25px 20px;
        background: linear-gradient(135deg, rgba(27, 20, 100, 0.03) 0%, rgba(255, 154, 18, 0.03) 100%);
        border-radius: 8px;
        margin-top: 10px;
    }

    .director-name strong {
        font-size: 1.3rem;
        display: block;
        margin-bottom: 8px;
        color: #1B1464;
    }

    .director-name span {
        color: #666;
        font-size: 1rem;
        font-style: italic;
    }

    /* ==== Responsive ==== */
    @media (max-width: 991px) {
        .intro-title {
            font-size: 2.2rem;
            text-align: center;
        }
        .intro-image {
            max-width: 380px;
            margin-top: 25px;
        }
    }

    @media (max-width: 575px) {
        .intro-title {
            font-size: 1.8rem;
        }
        .intro-image {
            max-width: 280px;
        }
    }