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

body {
    font-family: 'Inter', 'Roboto', sans-serif;
    background-color: #f5f5f5;
    color: #1a1a1a; /* Noir */
    height: 100vh;
    overflow: hidden;
}

.app-container {
    display: flex;
    height: 100%;
}

/* Sidebar */
.sidebar {
    width: 260px;
    background-color: #ffffff;
    border-right: 2px solid #0a192f; /* Bleu foncé */
    display: flex;
    flex-direction: column;
    box-shadow: 4px 0 10px rgba(0,0,0,0.05);
}

.sidebar-header {
    padding: 24px 20px;
    border-bottom: 2px dashed #0a192f;
}

.sidebar-header h2 {
    font-weight: 500;
    color: #0a192f; /* Bleu foncé */
    letter-spacing: 1px;
}

/* Titre d'onglet dans la sidebar */
.sidebar-onglet {
    padding: 12px 20px;
    margin: 10px 15px;
    background-color: #0a192f; /* Bleu foncé */
    color: white;
    font-weight: 600;
    text-align: center;
    border-radius: 40px;
    font-size: 1.1rem;
    border: 1px solid #1a1a1a;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.sidebar-nav ul {
    list-style: none;
    padding: 20px 0;
}

.sidebar-nav li {
    padding: 12px 24px;
    margin: 4px 8px;
    border-radius: 30px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.sidebar-nav li a {
    text-decoration: none;
    color: #1a1a1a; /* Noir */
    font-weight: 500;
    display: block;
}

.sidebar-nav li:hover {
    background-color: #c0392b; /* Rouge */
    transform: translateX(5px);
}

.sidebar-nav li:hover a {
    color: white;
}

.sidebar-nav li.active {
    background-color: #0a192f; /* Bleu foncé */
    font-weight: 600;
}

.sidebar-nav li.active a {
    color: white;
}

.sidebar-footer {
    margin-top: auto;
    padding: 20px;
    border-top: 2px dashed #0a192f;
}

.global-progress p {
    margin-bottom: 10px;
    color: #1a1a1a;
    font-size: 0.95rem;
}

.progress-circle {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: conic-gradient(#c0392b 0deg 234deg, #d3d3d3 234deg 360deg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    font-weight: 600;
    color: #1a1a1a;
    background-color: #f0f0f0;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.progress-circle span {
    background: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.1);
}

/* Main content */
.main-content {
    flex: 1;
    padding: 30px 40px;
    overflow-y: auto;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    transition: background-image 0.3s ease;
}

/* Images de fond selon l'onglet */
.main-content.accueil-bg {
    background-image: url('/static/image1.png');
}
.main-content:not(.accueil-bg) {
    background-image: url('/static/image2.png');
}
/* Fallback si images non trouvées */
.main-content {
    background-color: #f5f5f5;
}

/* Grille des cartes */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 30px;
}

.card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(4px);
    border-radius: 24px;
    padding: 20px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.03), 0 2px 6px rgba(0,0,0,0.05);
    border: 1px solid #ddd;
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 30px rgba(10, 25, 47, 0.15);
    border-color: #0a192f;
}

.card-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 16px;
    color: #0a192f; /* Bleu foncé */
    border-left: 4px solid #c0392b; /* Rouge */
    padding-left: 12px;
}

.card-progress {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.progress-bar {
    flex: 1;
    height: 8px;
    background-color: #ddd;
    border-radius: 20px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #0a192f, #c0392b); /* Dégradé bleu -> rouge */
    width: 0%;
    border-radius: 20px;
    transition: width 0.3s ease;
}

.progress-text {
    font-weight: 600;
    color: #c0392b; /* Rouge */
    min-width: 45px;
}

.btn-notes {
    background: #f0f0f0;
    border: 1px solid #0a192f;
    color: #0a192f;
    padding: 8px 16px;
    border-radius: 40px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
    width: 100%;
    font-size: 0.9rem;
}

.btn-notes:hover {
    background: #0a192f;
    color: white;
    border-color: #0a192f;
}

.card-notes {
    margin-top: 20px;
    padding: 12px;
    background: #f9f9f9;
    border-radius: 16px;
    border-left: 3px solid #c0392b;
    font-size: 0.95rem;
    max-height: 200px;
    overflow-y: auto;
}

.note-item {
    padding: 8px 0;
    border-bottom: 1px dashed #0a192f;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.note-item:last-child {
    border-bottom: none;
}

.note-content {
    flex: 1;
}

.note-date {
    font-size: 0.8rem;
    color: #666;
    margin-left: 10px;
}

.add-note-form {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}

.add-note-form input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #0a192f;
    border-radius: 40px;
    font-family: inherit;
    background: white;
}

.add-note-form button {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

/* Emploi du temps */
.schedule-container {
    background:rgba(255,255,255,0.6);
    backdrop-filter: blur(4px);
    border-radius: 24px;
    padding: 24px;
    margin-top: 20px;
}

.schedule-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.schedule-header h2 {
    color: #0a192f;
}

.btn-add-task {
    background: #0a192f;
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

.task-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.task-item {
    background: white;
    padding: 16px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.02);
    border: 1px solid #0a192f;
    cursor: grab;
}

.task-item.dragging {
    opacity: 0.5;
    cursor: grabbing;
}

.task-date {
    background: #0a192f;
    padding: 6px 12px;
    border-radius: 40px;
    font-weight: 500;
    color: white;
    min-width: 100px;
    text-align: center;
}

.task-details {
    flex: 1;
}

.task-title {
    font-weight: 600;
    color: #1a1a1a;
}

.task-meta {
    font-size: 0.85rem;
    color: #666;
}

.task-actions button {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 4px 8px;
    color: #c0392b;
    transition: color 0.2s;
}

.task-actions button:hover {
    color: #0a192f;
}

/* Cahiers */
.cahiers-container {
    background: none;
}

.cahiers-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.cahiers-header h1 {
    color: #1a1a1a;
}

.btn-nouveau-cahier {
    background: #0a192f;
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

.cahiers-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cahier-item {
    background: rgba(255, 255, 255, 0.9);
    padding: 16px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    gap: 16px;
    border: 1px solid #0a192f;
}

.cahier-titre {
    flex: 1;
    font-weight: 600;
    color: #1a1a1a;
}

.cahier-date {
    color: #666;
    font-size: 0.9rem;
}

.cahier-actions {
    display: flex;
    gap: 8px;
}

.cahier-actions button {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    padding: 4px 8px;
    color: #c0392b;
    transition: color 0.2s;
}

.cahier-actions button:hover {
    color: #0a192f;
}

/* Éditeur de cahier */
.cahier-editor-container {
    background: white;
    border-radius: 24px;
    padding: 24px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.05);
}

.editor-header {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    align-items: center;
}

#cahierTitre {
    flex: 1;
    padding: 12px;
    border: 2px solid #0a192f;
    border-radius: 40px;
    font-size: 1.1rem;
    font-family: inherit;
}

#btnSaveCahier {
    background: #c0392b;
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

#btnAnnuler {
    background: #0a192f;
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

#editor {
    border-radius: 16px;
    border: 2px solid #0a192f;
    background: #fff;
}

.empty-message {
    text-align: center;
    color: #666;
    padding: 40px;
    font-style: italic;
}

/* Vue lecture cahier */
.cahier-view-container {
    background: white;
    border-radius: 24px;
    padding: 24px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.05);
}

.view-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    border-bottom: 2px solid #0a192f;
    padding-bottom: 16px;
}

.view-header h2 {
    color: #0a192f;
    margin: 0;
}

#btnRetourListe {
    background: #c0392b;
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

.cahier-content {
    font-family: 'Inter', 'Roboto', sans-serif;
    line-height: 1.6;
    color: #1a1a1a;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 16px;
    border: 1px solid #0a192f;
    min-height: 300px;
}

.cahier-content h1,
.cahier-content h2,
.cahier-content h3 {
    color: #0a192f;
}

.cahier-content p {
    margin: 1em 0;
}

.cahier-content ul,
.cahier-content ol {
    margin: 1em 0;
    padding-left: 2em;
}

/* Documents avec modules pliables */
.documents-container {
    background: none;
}

.documents-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 20px;
}

.documents-header h1 {
    color: #1a1a1a;
    margin: 0;
}

.header-actions {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.upload-form-inline {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
    background: #f0f0f0;
    padding: 10px 15px;
    border-radius: 50px;
    border: 1px solid #0a192f;
}

.upload-form-inline input[type="text"],
.upload-form-inline select,
.upload-form-inline input[type="file"] {
    padding: 8px 12px;
    border: 1px solid #0a192f;
    border-radius: 40px;
    background: white;
    font-family: inherit;
    font-size: 0.9rem;
}

.upload-form-inline input[type="file"] {
    max-width: 200px;
}

.btn-nouveau-module {
    background: #0a192f;
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
    white-space: nowrap;
}

.btn-upload {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
    white-space: nowrap;
}

.btn-upload:hover {
    background: #a8231e;
}

.modules-list {
    margin-top: 20px;
}

.module-item {
    background: #fff;
    border-radius: 16px;
    padding: 15px;
    margin-bottom: 15px;
    border: 1px solid #0a192f;
}

.module-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 10px;
    padding-bottom: 5px;
    border-bottom: 1px dashed #0a192f;
    flex-wrap: wrap;
}

.module-info {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.module-nom {
    font-weight: 600;
    color: #0a192f;
    font-size: 1.1rem;
}

.module-description {
    color: #666;
    font-size: 0.9rem;
}

.module-actions {
    display: flex;
    gap: 8px;
    margin-left: auto;
}

.module-actions button {
    background: #f0f0f0;
    border: none;
    cursor: pointer;
    font-size: 0.95rem;
    padding: 6px 12px;
    border-radius: 20px;
    color: #1a1a1a;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.module-actions button:hover {
    background: #c0392b;
    color: white;
}

.btn-toggle-module {
    min-width: 100px;
    justify-content: center;
}

.module-documents {
    margin-left: 20px;
    padding-left: 15px;
    border-left: 2px solid #0a192f;
    margin-top: 10px;
    transition: all 0.3s ease;
}

.document-item {
    background: white;
    padding: 12px 15px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 15px;
    border: 1px solid #0a192f;
    margin-bottom: 8px;
}

.doc-titre {
    font-weight: 600;
    color: #1a1a1a;
    min-width: 150px;
}

.doc-nom {
    color: #666;
    font-size: 0.9rem;
    flex: 1;
}

.doc-date {
    color: #666;
    font-size: 0.85rem;
}

.doc-actions {
    display: flex;
    gap: 5px;
}

.doc-actions button {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    padding: 4px 8px;
    color: #c0392b;
    transition: color 0.2s;
}

.doc-actions button:hover {
    color: #0a192f;
}

/* Zone de visualisation PDF */
.pdf-viewer {
    margin-top: 20px;
    background: white;
    border-radius: 16px;
    padding: 20px;
    border: 1px solid #0a192f;
}

.pdf-viewer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.pdf-viewer-header h3 {
    color: #0a192f;
    margin: 0;
}

#closePdfViewer {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

embed {
    border-radius: 8px;
    border: 1px solid #0a192f;
}

/* Culture Générale */
.questions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.question-card {
    background: white;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.05);
    transition: transform 0.2s;
    border: 1px solid #0a192f;
}

.question-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(10,25,47,0.2);
}

.question-title {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: #0a192f;
    font-weight: 600;
}

.question-status {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 15px;
}

.question-status.repondu {
    background: #c0392b;
    color: white;
}

.question-status.deçu {
    background: #0a192f;
    color: white;
}

.btn-repondre {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
    width: 100%;
    transition: background 0.2s;
}

.btn-repondre:hover {
    background: #0a192f;
}

#reponse-editor-container {
    background: white;
    border-radius: 24px;
    padding: 20px;
    margin-top: 20px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    border: 1px solid #0a192f;
}

.reponse-editor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px dashed #0a192f;
}

#close-editor {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

#save-reponse {
    background: #0a192f;
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 40px;
    cursor: pointer;
    margin: 15px 0;
    font-weight: 600;
    display: block;
}

.historique-reponses {
    max-height: 300px;
    overflow-y: auto;
    border-top: 1px solid #0a192f;
    padding-top: 15px;
}

.reponse-item {
    background: #f9f9f9;
    border-radius: 8px;
    padding: 10px;
    margin-bottom: 10px;
    border-left: 3px solid #c0392b;
}

.reponse-date {
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 5px;
}

.reponse-contenu {
    font-size: 0.95rem;
}

.reponse-contenu img {
    max-width: 100%;
    height: auto;
}

/* Notifications */
.notification {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #c0392b;
    color: white;
    padding: 12px 24px;
    border-radius: 40px;
    box-shadow: 0 4px 12px rgba(192, 57, 43, 0.3);
    animation: slideIn 0.3s ease;
    z-index: 1000;
}

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* En-tête du contenu principal */
.content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 0 20px 0;
    margin-bottom: 20px;
    border-bottom: 2px dashed #0a192f;
}

.header-left h1 {
    font-size: 1.8rem;
    color: #0a192f;
    font-weight: 600;
    margin: 0;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.horloge {
    font-size: 1.2rem;
    font-weight: 600;
    color: #1a1a1a;
    background: #f0f0f0;
    padding: 8px 16px;
    border-radius: 40px;
    border: 1px solid #0a192f;
}

.notifications {
    position: relative;
    cursor: pointer;
    font-size: 1.5rem;
}

.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #c0392b;
    color: white;
    border-radius: 50%;
    padding: 2px 6px;
    font-size: 0.7rem;
    font-weight: bold;
    min-width: 18px;
    text-align: center;
}

.profile {
    cursor: pointer;
}

.profile-img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid #0a192f;
    object-fit: cover;
}

/* Zone de contenu dynamique */
.content-area {
    min-height: calc(100vh - 200px);
}

/* Responsive */
@media (max-width: 768px) {
    .app-container {
        flex-direction: column;
    }
    .sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 2px solid #0a192f;
    }
    .main-content {
        padding: 20px;
    }
    .cards-grid {
        grid-template-columns: 1fr;
    }
    .header-actions {
        flex-direction: column;
        width: 100%;
    }
    .upload-form-inline {
        width: 100%;
    }
    .upload-form-inline input[type="file"] {
        max-width: none;
    }
    .content-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .header-right {
        width: 100%;
        justify-content: flex-end;
    }
}
/* Révisions vidéo */
.revisions-container {
    background: rgba(255,255,255,0.9);
    border-radius: 24px;
    padding: 24px;
}

.revisions-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.revisions-header h1 {
    color: #0a192f;
}

.btn-ajouter-video {
    background: #c0392b;
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

.videos-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.video-item {
    background: white;
    border-radius: 16px;
    padding: 20px;
    border: 1px solid #0a192f;
}

.video-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px dashed #0a192f;
}

.video-titre {
    font-weight: 600;
    color: #0a192f;
    font-size: 1.1rem;
    flex: 1;
}

.video-date {
    color: #666;
    font-size: 0.9rem;
}

.btn-supprimer-video {
    background: #c0392b;
    border: none;
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    cursor: pointer;
}

.video-player {
    margin-bottom: 15px;
}

.video-notes-section {
    margin-top: 10px;
}

.btn-toggle-notes {
    background: #0a192f;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
    margin-bottom: 10px;
}

.video-notes {
    background: #f9f9f9;
    border-radius: 16px;
    padding: 15px;
    border: 1px solid #0a192f;
}

.notes-list {
    max-height: 200px;
    overflow-y: auto;
    margin-bottom: 10px;
    padding: 5px;
}

.note-input {
    width: 100%;
    padding: 10px;
    border: 1px solid #0a192f;
    border-radius: 8px;
    font-family: inherit;
    margin-bottom: 10px;
    min-height: 80px;
    resize: vertical;
}

.btn-ajouter-note {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

.note-item {
    background: white;
    border-radius: 8px;
    padding: 10px;
    margin-bottom: 8px;
    border-left: 3px solid #c0392b;
}

.note-contenu {
    font-size: 0.95rem;
    margin-bottom: 5px;
}

.note-date {
    font-size: 0.8rem;
    color: #666;
}
/* Révisions vidéo */
.revisions-container {
    display: flex;
    gap: 20px;
    height: 100%;
}

.revisions-left {
    flex: 1;
    background: white;
    border-radius: 16px;
    padding: 20px;
    border: 1px solid #0a192f;
}

.revisions-right {
    flex: 2;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.revisions-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.revisions-header h2 {
    color: #0a192f;
    margin: 0;
}

.btn-ajouter-video {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

.videos-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.video-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f9f9f9;
    padding: 10px 15px;
    border-radius: 12px;
    border: 1px solid #0a192f;
}

.video-titre {
    font-weight: 600;
    color: #1a1a1a;
}

.video-actions {
    display: flex;
    gap: 8px;
}

.video-actions button {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    padding: 4px 8px;
    color: #c0392b;
    transition: color 0.2s;
}

.video-actions button:hover {
    color: #0a192f;
}

.video-player-container {
    background: white;
    border-radius: 16px;
    padding: 20px;
    border: 1px solid #0a192f;
}

.video-player-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.video-player-header span {
    font-weight: 600;
    color: #0a192f;
    font-size: 1.1rem;
}

#closeVideoPlayer {
    background: #c0392b;
    border: none;
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    cursor: pointer;
}

.notes-container {
    background: white;
    border-radius: 16px;
    padding: 20px;
    border: 1px solid #0a192f;
}

.notes-container h3 {
    color: #0a192f;
    margin-top: 0;
    margin-bottom: 15px;
}

.btn-save-note {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    margin: 10px 0;
}

#videoNotesList {
    max-height: 200px;
    overflow-y: auto;
    margin-top: 10px;
}
/* Formations */
.formations-container {
    background: rgba(255,255,255,0.6);
    border-radius: 24px;
    padding: 24px;
    border: 1px solid #0a192f;
}

.formations-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.formations-header h1 {
    color: hsl(216, 65%, 11%);
    margin: 0;
}

.btn-ajouter-formation {
    background: #c0392b;
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

.formations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.formation-card {
    background:rgba(255,255,255,0.6);
    border-radius: 16px;
    padding: 15px;
    border: 1px solid #0a192f;
    transition: transform 0.2s;
}

.formation-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.formation-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.formation-titre {
    font-weight: 600;
    color: #0a192f;
    font-size: 1.1rem;
}

.btn-supprimer-formation {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: #c0392b;
}

.btn-ouvrir-formation {
    background: #0a192f;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    width: 100%;
    font-weight: 600;
}

/* Détail formation */
.formation-detail {
    background: white;
    border-radius: 24px;
    padding: 24px;
    border: 1px solid #0a192f;
}

.formation-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #0a192f;
}

.formation-detail-header h2 {
    color: #0a192f;
    margin: 0;
}

#btnRetourFormations {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 600;
}

#btnEditerFormation {
    background: #0a192f;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
}

.formation-detail-content {
    display: flex;
    gap: 20px;
}

.formation-notes {
    flex: 1;
    background: #f9f9f9;
    border-radius: 16px;
    padding: 20px;
    border: 1px solid #0a192f;
}

.formation-notes h3 {
    color: #0a192f;
    margin-top: 0;
    margin-bottom: 15px;
}

.btn-save-notes {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    margin-top: 10px;
}

.formation-video {
    flex: 1;
    background: #f9f9f9;
    border-radius: 16px;
    padding: 20px;
    border: 1px solid #0a192f;
}

.video-player {
    width: 100%;
    height: 315px;
    background: black;
    border-radius: 8px;
    overflow: hidden;
}

.video-player iframe {
    width: 100%;
    height: 100%;
}
.formation-video-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.formation-video-list {
    background: #f9f9f9;
    border-radius: 16px;
    padding: 15px;
    border: 1px solid #0a192f;
}

.formation-video-list h3 {
    margin-top: 0;
    color: #0a192f;
}

#btnAjouterVideoFormation {
    background: #c0392b;
    border: none;
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    cursor: pointer;
    margin-bottom: 10px;
}

.formation-video-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px;
    border-bottom: 1px dashed #0a192f;
    cursor: pointer;
}

.formation-video-item:hover {
    background: #e0e0e0;
}

.formation-video-item .video-titre {
    flex: 1;
}

.btn-supprimer-video-formation {
    background: none;
    border: none;
    cursor: pointer;
    color: #c0392b;
    font-size: 1.2rem;
}

.formation-video-player {
    background: #f9f9f9;
    border-radius: 16px;
    padding: 15px;
    border: 1px solid #0a192f;
}
/* Projets - bureau en bois */
.projets-bureau {
    background: rgba(255, 255, 255, 0.2); /* léger voile pour lisibilité */
    backdrop-filter: blur(2px);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}

.projets-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.projets-header h1 {
    color: #fff;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    font-size: 2rem;
}

.btn-nouveau-projet {
    background: #8B5A2B; /* bois foncé */
    border: 2px solid #5a3e1b;
    color: white;
    padding: 10px 20px;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

.projets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
}

.projet-carte {
    background: #f4e6c1; /* papier ancien */
    border: 8px solid #8B5A2B; /* cadre bois */
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.3), inset 0 2px 4px rgba(255,255,255,0.6);
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
    position: relative;
}

.projet-carte:hover {
    transform: translateY(-8px) rotate(0.5deg);
    box-shadow: 0 20px 30px rgba(0,0,0,0.4);
}

.projet-icone {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 10px;
}

.projet-contenu {
    flex: 1;
}

.projet-titre {
    font-size: 1.4rem;
    color: #3e2a1f;
    margin: 10px 0 5px;
    font-weight: bold;
    border-bottom: 2px dashed #8B5A2B;
    padding-bottom: 5px;
}

.projet-description {
    color: #5a4a3a;
    font-style: italic;
    font-size: 0.95rem;
    line-height: 1.4;
    margin: 10px 0;
    max-height: 80px;
    overflow: hidden;
}

.projet-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
}

.btn-voir-projet {
    background: #8B5A2B;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600;
    flex: 1;
    margin-right: 10px;
}

.btn-supprimer-projet {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 12px;
    border-radius: 30px;
    cursor: pointer;
    font-size: 1rem;
}

.empty-message {
    color: white;
    text-shadow: 1px 1px 2px black;
    text-align: center;
    font-size: 1.2rem;
    grid-column: 1 / -1;
}
/* Projet détail */
.projet-detail-container {
    background: white;
    border-radius: 24px;
    padding: 30px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    border: 1px solid #0a192f;
}

.projet-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #0a192f;
}

.projet-titre-icone {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 1.8rem;
}

.projet-titre-icone h2 {
    color: #0a192f;
    margin: 0;
}

#btnRetourProjets {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
}

#btnEditerProjet {
    background: #0a192f;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
}

.projet-meta {
    display: flex;
    gap: 20px;
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 30px;
}

.projet-section {
    margin-bottom: 30px;
    border-top: 1px solid #e6d5b8;
    padding-top: 20px;
}

.projet-section h3 {
    color: #0a192f;
    margin-top: 0;
    margin-bottom: 15px;
}

.taches-container {
    background: #f9f9f9;
    border-radius: 16px;
    padding: 15px;
}

.tache-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px dashed #d4c3a2;
}

.tache-item:last-child {
    border-bottom: none;
}

.tache-checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.tache-description {
    flex: 1;
    font-size: 1rem;
}

.tache-description.complete {
    text-decoration: line-through;
    color: #999;
}

.supprimer-tache {
    background: none;
    border: none;
    cursor: pointer;
    color: #c0392b;
}

.ajouter-tache {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.ajouter-tache input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #0a192f;
    border-radius: 40px;
}

.ajouter-tache button {
    background: #0a192f;
    border: none;
    color: white;
    padding: 8px 20px;
    border-radius: 40px;
    cursor: pointer;
}

.fichiers-container {
    background: #f9f9f9;
    border-radius: 16px;
    padding: 15px;
}

.fichier-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px dashed #d4c3a2;
}

.fichier-titre {
    font-weight: 600;
    min-width: 150px;
}

.fichier-nom {
    color: #666;
    flex: 1;
}

.telecharger-fichier, .supprimer-fichier {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
}

.telecharger-fichier {
    color: #0a192f;
}

.supprimer-fichier {
    color: #c0392b;
}

.ajouter-fichier {
    margin-top: 15px;
}

#uploadFichierForm {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

#uploadFichierForm input[type="text"] {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #0a192f;
    border-radius: 40px;
}

#uploadFichierForm input[type="file"] {
    padding: 5px;
}

#uploadFichierForm button {
    background: #c0392b;
    border: none;
    color: white;
    padding: 8px 20px;
    border-radius: 40px;
    cursor: pointer;
}

.btn-sauvegarder {
    background: #0a192f;
    border: none;
    color: white;
    padding: 12px 24px;
    border-radius: 40px;
    cursor: pointer;
    font-size: 1.1rem;
    margin-top: 20px;
    width: 100%;
}