button[aria-expanded=true] .fa-chevron-right {
    display: none;
}

button[aria-expanded=false] .fa-chevron-down {
    display: none;
}

.subsections.collapsed {
    display: none;
}

.section-title-input {
    background-color: transparent;
    border: 1px solid transparent;
    transition: border-color 0.3s;
}

.section-title-input:hover,
.section-title-input:focus {
    border-color: #ced4da;
    background-color: white;
}

.section-content-input {
    font-size: 0.9em;
    resize: vertical;
}


/* Style pour le modal de création de section */
#createSectionModal .modal-content {
    border-radius: 8px;
    overflow: hidden;
}

#createSectionModal .modal-header {
    padding: 1.2rem 1.5rem;
}

#createSectionModal .form-control {
    transition: all 0.3s ease;
    border-radius: 6px;
}

#createSectionModal .form-control:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.15);
}

#createSectionModal .btn {
    font-weight: 500;
    padding: 0.5rem 1.5rem;
    border-radius: 6px;
    transition: all 0.3s ease;
}

#createSectionModal .btn-primary {
    background-color: #0A1F44;
    border-color: #0A1F44;
}

#createSectionModal .btn-primary:hover {
    background-color: #0069d9;
    border-color: #0062cc;
    transform: translateY(-1px);
}

#createSectionModal .btn-outline-secondary:hover {
    background-color: #f8f9fa;
    color: #6c757d;
    transform: translateY(-1px);
}

#createSectionModal .close {
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

#createSectionModal .close:hover {
    opacity: 1;
}

/* Animation d'entrée du modal */
.modal.fade .modal-dialog {
    transform: scale(0.8);
    transition: transform 0.3s ease;
}

.modal.show .modal-dialog {
    transform: scale(1);
}






.sidebar {
    height: calc(100vh - 100px);
    overflow-y: auto;
    position: sticky;
    top: 20px;
    border-right: 1px solid #dee2e6;
}

.sidebar {
    left: 0;
    top: 0;

}

.section-item {
    cursor: pointer;
    padding: 8px 12px;
    margin: 4px 0;
    border-radius: 4px;
    transition: background-color 0.2s;
    margin-bottom: 0.5rem;
    background: white;
    border: 1px solid #edf2f7;
    transition: all 0.3s ease;
}

.section-item:hover {
    background-color: #f8fafc;
    transform: translateX(4px);
}

.section-item.active {
    border-left: 3px solid #0A1F44;
    background-color: rgb(245, 213, 208);
}

.section-toggle i {
    transition: transform 0.3s ease;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.main-content {
    height: calc(100vh - 100px);
    overflow-y: auto;
    padding: 20px;
}

.section-toggle.collapsed i {
    transform: rotate(-90deg);
}

.subsections {
    padding-left: 20px;
    margin-top: 5px;
}

.subsections.collapsed {
    display: none;
}

.section-toggle {
    cursor: pointer;
    width: 20px;
    text-align: center;
}

.section-toggle.collapsed i {
    transform: rotate(-90deg);
}

.section-content-area {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 20px;
    margin-bottom: 20px;
}

.empty-state {
    text-align: center;
    padding: 40px;
    color: #6c757d;
}

.section-number {
    min-width: 35px;
    text-align: center;
    background-color: #e8f4ff;
    border: 1px solid #cce5ff;
}

.subsections {
    max-height: 1000px;
    transition: max-height 0.3s ease-in-out;
}

.subsections.collapsed {
    max-height: 0;
}

/* Animation pour les transitions */
.section-item {
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Style spécial pour le niveau actif */
.section-item.active .section-number {
    background-color: #3490dc;
    color: white;
    border-color: #2779bd;
}

/* Effet de hover amélioré */
.section-item:hover .section-number {
    transform: scale(1.05);
    transition: transform 0.2s ease;
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 20px;
}

#sommaire-row {
    background-color: #f8f9fa;
    border: 2px solidrgb(163, 156, 156);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    padding: 2rem;
    min-height: 100vh;
    position: relative;
    width: 100%;
    overflow-x: hidden;
    border-radius: 8px;
    margin: 15px;
}


/* Conteneur du bouton toggle */
.toggle-container {
    display: flex;
    align-items: center;
    position: relative;
}

/* Conteneur du toggle */
.toggle-container .toggle-slider {
    position: relative;
    cursor: pointer;
    width: 50px;
    /* Largeur du bouton */
    height: 24px;
    /* Hauteur du bouton */
    background-color: #ccc;
    border-radius: 50px;
    transition: background-color 0.4s;
}

/* Le cercle à l'intérieur du slider */
.toggle-slider::before {
    content: "";
    position: absolute;
    top: 4px;
    left: 4px;
    width: 16px;
    height: 16px;
    background-color: white;
    border-radius: 50%;
    transition: transform 0.4s;
}

/* Cacher l'input (le checkbox) */
.toggle-input {
    opacity: 0;
    width: 0;
    height: 0;
}

/* Lorsque le checkbox est coché, changer l'apparence du toggle */
.toggle-input:checked+.toggle-slider {
    background-color: #4CAF50;
    /* Couleur du fond quand coché */
}

/* Déplacer le cercle à l'intérieur lorsque le checkbox est coché */
.toggle-input:checked+.toggle-slider::before {
    transform: translateX(26px);
}

.toggle-text {
    margin-left: 10px;
    font-size: 16px;
    color: #4CAF50;
    font-weight: bold;

}

.toggle-input:checked+.toggle-slider+.toggle-text {
    color: #4CAF50;
    font-weight: bold;
}