body { 
    background: url('https://wallpapercat.com/w/full/7/0/6/26427-3840x2160-desktop-4k-black-hole-wallpaper-image.jpg');
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    background-attachment: fixed;
    height: 100vh;
    margin: 0;
    font-family: 'Spectral', serif;
    text-align: justify;
}


a {
    text-decoration: none;
    color: #fff;
}

.cours {
    color: #fff;
    margin: 25px;
}

.cours .link {
    color:#cbaedd;
}

.cours .link:hover {
    text-shadow: 0 0 5px #9b4dca, 
    0 0 10px #9b4dca,
    0 0 15px #9b4dca;
    color: #fff;
}

.cours .resume {
    grid-row: 2;
    grid-column: 1;
    background-color: rgba(20, 20, 20, 0.9);
    border-radius: 25px;
    padding: 15px;
}

.cours .titre {
    grid-column: 1;
    grid-row: 1;
    margin-left: 10px;
    padding: 0px 10px;
    font-weight: bold;
    background-color: #cbaedd;
    border-radius: 10px;
    width: fit-content;
}

.cours .main_img {
    display: block;
    margin: auto;
    width: 100%; /* Adapte l'image à la largeur de l'écran */
    max-width: 400px;
    align-items: center;
    border-radius: 25px;
    border: 2px solid #000;
    margin-top: 10px;
}

.imgdesc {
    display: block;
    margin: auto;
    width: 100%; /* Adapte la largeur */
    max-width: 400px;
    align-items: center;
    text-align: center;
    font-style: italic;
    font-size: 10px;
}

.content div {
    margin-top: 10px;
    grid-row: 2;
    grid-column: 1;
    background-color: rgba(20, 20, 20, 0.9);
    border-radius: 25px;
    padding: 15px;
}

.section h2 {
    color: #cbaedd;
    background-color: #fff;
    border-radius: 25px;
    padding: 10px;
}

.credit {
    background-color: #505050;
    border-radius: 25px;
    padding: 10px;
    margin-top: 10px;
    width: fit-content;
}

.cours button {
    margin-top: 10px;
    grid-column: 3;
    grid-row: 3;
    font-family: "Playwrite IT Moderna", serif;
    font-optical-sizing: auto;
    font-weight: 400;
    font-style: normal;
    padding: 13px 20px;
    color: #fff;
    border: none;
    cursor: pointer;
    outline: none;
    background-color: #cbaedd;
    border-radius: 10px;
}

/* Styling for sources */
.source-container {
    margin-top: 20px;
    background-color: rgba(20, 20, 20, 0.9);
    border-radius: 25px;
    padding: 15px;
    color: #fff;
    font-size: 14px;
}

.source-container h3 {
    color: #cbaedd;
    font-size: 18px;
    margin-bottom: 10px;
    font-weight: bold;
}

.source-container p {
    font-size: 14px;
    margin-bottom: 8px;
}

.source-container a {
    color: #cbaedd;
    font-size: 14px;
}

.source-container a:hover {
    text-shadow: 0 0 5px #9b4dca, 
    0 0 10px #9b4dca,
    0 0 15px #9b4dca;
    color: #fff;
}

.source-container a:focus {
    outline: 2px solid #cbaedd;
}

/* Responsive styles for smartphones */
@media screen and (max-width: 768px) {
    body {
        background-size: cover;
        text-align: left;
        padding: 10px; /* Ajoute des marges internes pour éviter que le contenu touche les bords */
    }

    .cours .main_img, .imgdesc {
        width: 100%;
        max-width: 100%; /* S'assure qu'elle occupe toute la largeur */
    }

    .cours .resume, .content div {
        padding: 10px; /* Réduit les marges pour un meilleur affichage sur mobile */
        font-size: 14px;
    }

    .cours .titre {
        font-size: 18px;
        margin: 10px 0;
    }

    button {
        width: 100%; /* Boutons s'étendent sur toute la largeur */
        padding: 10px;
        font-size: 16px;
    }

    .section h2 {
        font-size: 20px;
    }

    .source-container {
        font-size: 12px;
    }
}

.item {
    padding: 5px;
    background-color: #cbaedd69;
    border-radius: 5px;
}

li {
    margin-left: 20px;
}

ul.item {
    background: local;
    background-color: rgba(20, 20, 20, 0.9);
}

.block_imgs {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: space-evenly;
}

.block_img {
    max-width: 400px;
    max-height: 200px;
}

embed {
    display: block;
    width: 1fr;
    align-self: center; /* Centrage vertical */
    justify-self: center; /* Centrage horizontal */
}

/* Responsive styles for smartphones */
@media screen and (max-width: 768px) {
    body {
        background-size: cover;
        text-align: left;
        padding: 10px; /* Ajoute des marges internes pour éviter que le contenu touche les bords */
    }

    .cours .main_img, .imgdesc {
        width: 100%;
        max-width: 100%; /* S'assure qu'elles occupent toute la largeur */
    }

    .cours .resume, .content div {
        padding: 10px; /* Réduit les marges pour un meilleur affichage sur mobile */
        font-size: 14px;
    }

    .cours .titre {
        font-size: 18px;
        margin: 10px 0;
    }

    button {
        width: 100%; /* Boutons s'étendent sur toute la largeur */
        padding: 10px;
        font-size: 16px;
    }

    .section h2 {
        font-size: 20px;
    }

    .source-container {
        font-size: 12px;
    }

    /* Ajustements pour la mise en page */
    .block_imgs {
        flex-direction: column; /* Affiche les images en colonne sur mobile */
        align-items: center;
        justify-content: center;
    }

    .block_img {
        max-width: 100%; /* Assure que les images ne dépassent pas de l'écran */
        max-height: auto;
    }

    .cours .titre {
        font-size: 16px;
    }

    /* Ajuste l'espacement dans les sections */
    .item {
        padding: 5px;
        background-color: #cbaedd69;
        border-radius: 5px;
        font-size: 12px; /* Plus petit texte pour les items */
    }

    li {
        margin-left: 10px;
    }

    ul.item {
        background-color: rgba(20, 20, 20, 0.9);
    }
}
