.sidebar {
    width: 240px;
    height: calc(100vh - 60px); /* Toute la hauteur moins le header */
    background-color: #f4f4f4;
    border-right: 2px solid var(--bleu-escrime);
    position: sticky;
    top: 60px;
    display: flex;
    flex-direction: column;
}

.sidebar-sticky {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
}

.sidebar-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-item {
    margin-bottom: 0.5rem;
}

.sidebar-link {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    text-decoration: none;
    color: var(--noir);
    font-weight: 600;
    border-radius: 4px;
    transition: 0.2s;
}

.sidebar-link:hover {
    background-color: #e9e9e9;
    color: var(--bleu-escrime);
}

.sidebar-link.active {
    background-color: var(--bleu-escrime);
    color: white;
}

.icon {
    margin-right: 12px;
    font-size: 1.2rem;
}

.sidebar-footer {
    text-align: center;
    padding-top: 2rem;
}

.sidebar-logo {
    max-width: 100px;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

/* Cache la sidebar sur les écrans de moins de 768px */
@media (max-width: 768px) {
    .sidebar {
        display: none !important; /* Le !important garantit qu'elle disparaît */
    }

    .main-layout {
        flex-direction: column; /* Le contenu prend toute la largeur */
    }
}