.theme-toggle {
    right: 16px;
    position: fixed;
    cursor: pointer;
}

.theme-toggle button {
    background: none;
    border: none;
    font-size: 1.2em;
    cursor: pointer;
}

body.dark-mode nav a {
    color: white;
}

body.dark-mode .burger-menu span {
    background-color: white;
}

body.dark-mode footer {
    border-top-color: rgba(255, 255, 255, 0.5);
}

body.dark-mode footer a {
    color: white;
}

nav ul{
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    margin-bottom: 48px;
    padding-top: 8px;
    list-style: none;
}

nav ul li a {
    display: inline-block;
    transition: transform 0.2s ease, background-color 0.2s ease;
}

nav ul li a:hover {
    transform: translateY(-4px);
}

.menu-deroulant-content {
    display: none;
    position: static;
    flex-direction: column;
    min-width: 160px;
    z-index: 10;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);

    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px); /* Flou pour Safari */
}

.menu-deroulant-content li {
    padding: 8px 15px;
    color: white;
    display: block;
}

.menu-deroulant:hover .menu-deroulant-content {
    display: block;
}

.fleche-nav {
  display: inline-block;
  margin-left: 5px;
  transition: transform 0.3s ease;
}

.menu-deroulant:hover .fleche-nav {
  transform: rotate(180deg);
}

/* Pour le responsive */
.burger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    height: 26px;
    width: 29px;
    position: fixed;
    top: 16px;
    left: 16px;
    z-index: 20;
    cursor: pointer;
}

.burger-menu span {
    display: block;
    height: 4px;
    width: 100%;
    background-color: #000;
    border-radius: 4px;
    transition: all 0.35s ease;
    transform-origin: center;
}

.burger-menu.active span:nth-child(1) {
    transform: translate(0, 11px) rotate(45deg);
}

.burger-menu.active span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.burger-menu.active span:nth-child(3) {
    transform: translate(0, -11px) rotate(-45deg);
}

#to-the-top-button {
    bottom: 16px;
    right: 16px;
    position: fixed;
}

#to-the-top-img {
    width: 48px;
    height: 48px;
    transition: transform 0.2s ease, background-color 0.2s ease;
}

#to-the-top-img:hover {
    transform: translateY(-4px);
}

footer {
    border-top: 1px solid rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 48px;
    padding-bottom: 8px;
}

footer table {
    display: flex;
    flex-direction: column;
    align-items: center;
}

footer a:hover {
    text-decoration: underline;
}

#copyright {
    text-align: center;
    font-size: 0.9em;
}

/* Responsive */

@media (max-width: 800px){

    nav ul {
        position: fixed;
        top: 0;
        left: -100%;
        height: 100vh;
        width: 70%;
        max-width: 300px;
        background: rgba(0, 0, 0, 0.9);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 30px;
        transition: left 0.3s ease;
        z-index: 15;
    }

    nav ul li a,
    nav ul li h1 {
        color: white;
        font-size: 1.2rem;
    }

    nav ul.active {
        left: 0;
    }

    .burger-menu {
        display: flex;
    }

    .menu-deroulant:hover .menu-deroulant-content {
        display: none;
    }

    .menu-deroulant.open .menu-deroulant-content {
        display: flex;
        max-height: 300px;
    }

    .menu-deroulant-content li {
        width: 100%;
        text-align: center;
    }

    .menu-deroulant-content a {
    text-decoration: none;
    display: block;
    padding: 10px 0;
    }

    .menu-deroulant-content a:hover {
    background: rgba(255, 255, 255, 0.1);
    }

    .theme-toggle {
        top: 16px;
        right: 16px;
    }
}